summary refs log tree commit diff
path: root/src/test/ui/const-generics
AgeCommit message (Collapse)AuthorLines
2022-12-09Auto merge of #104449 - oli-obk:unhide_unknown_spans, r=estebank,RalfJungbors-17/+28
Start emitting labels even if their pointed to file is not available locally r? `@estebank` cc `@RalfJung` fixes #97699
2022-12-06normalize before matching on `ConstKind`Boxy-0/+12
2022-12-06Change CTFE backtraces to use `note` instead of `label` to preserve their orderOli Scherer-17/+28
labels are reordered within the file in which they are reported, which can mess up the stack trace
2022-12-06Remove now-redundant file/line info from const backtracesOli Scherer-6/+6
2022-12-06Rollup merge of #105339 - BoxyUwU:wf_ct_kind_expr, r=TaKO8KiMatthias Krüger-0/+42
support `ConstKind::Expr` in `is_const_evaluatable` and `WfPredicates::compute` Fixes #105205 Currently we haven't implemented a way to evaluate `ConstKind::Expr(Expr::Binop(Add, 1, 2))` so I just left that with a `FIXME` and a `delay_span_bug` since I have no idea how to do that and it would make this a much larger (and more complicated) PR :P
2022-12-06Rollup merge of #105338 - estebank:other-impls, r=compiler-errorsYuki Okushi-6/+2
Tweak "the following other types implement trait" When *any* of the suggested impls is an exact match, *only* show the exact matches. This is particularly relevant for integer types. r? `@compiler-errors`
2022-12-05support `Expr` in `is_const_evaluatable` and `compute`Boxy-0/+42
2022-12-05Tweak "the following other types implement trait"Esteban Küber-6/+2
When *any* of the suggested impls is an exact match, *only* show the exact matches. This is particularly relevant for integer types. fix fmt
2022-12-03Skip recording resolution for duplicated generic params.Camille GILLOT-0/+15
2022-11-27Auto merge of #104048 - cjgillot:split-lifetime, r=compiler-errorsbors-1/+1
Separate lifetime ident from lifetime resolution in HIR Drive-by: change how suggested generic args are computed. Fixes https://github.com/rust-lang/rust/issues/103815 I recommend reviewing commit-by-commit.
2022-11-25`super_relate_consts` do not spurriously fail on assoc constsBoxy-0/+20
2022-11-25fmtBoxy-1/+1
2022-11-25handle assoc consts in fulfill `ConstEquate`Boxy-151/+61
2022-11-25handle nested obligations in `satisfied_from_param_env`Boxy-8/+79
2022-11-25Add expand_abstract_constkadmin-21/+1
Adds the ability to directly expand a const to an expr without having to deal with intermediate steps.
2022-11-25Add empty ConstKind::Abstractkadmin-33/+175
Initial pass at expr/abstract const/s Address comments Switch to using a list instead of &[ty::Const], rm `AbstractConst` Remove try_unify_abstract_consts Update comments Add edits Recurse more More edits Prevent equating associated consts Move failing test to ui Changes this test from incremental to ui, and mark it as failing and a known bug. Does not cause the compiler to ICE, so should be ok.
2022-11-24Change how suggested lifetime args are computed.Camille GILLOT-1/+1
2022-11-22Add failing test for projections used as const genericGuillaume Gomez-0/+31
2022-11-20Factor out conservative_is_privately_uninhabitedCameron Steffen-2/+2
2022-11-14Show a note where a macro failed to matchNilstrieb-0/+6
This shows a small note on what the macro matcher was currently processing to aid with "no rules expected the token X" errors.
2022-11-11Visit opaque types during type collection too.Camille GILLOT-26/+5
2022-11-02Rollup merge of #99801 - ↵Matthias Krüger-0/+33
Neo-Zhixing:fix/generic_const_exprs_parent_opaque_predicates, r=oli-obk fix(generic_const_exprs): Fix predicate inheritance for children of opaque types Fixes #99705 We currently have a special case to perform predicate inheritance when the const item is in the generics. I think we're also going to need this for opaque return types. When evaluating the predicates applied to the associated item, it'll inherit from its parent, the opaque type, which will never have predicates applied. This PR bypass the opaque typed parent and inherit predicates directly from the function itself.
2022-11-01fix(generic_const_exprs): Fix predicate inheritance for children of opaque typesZhixing Zhang-0/+33
2022-10-27Correct inconsistent error messages in testsByron Zhong-1/+1
2022-10-22Auto merge of #103227 - lcnr:bye-bye-unevaluated-const, r=oli-obkbors-20/+24
stop using `ty::UnevaluatedConst` directly best reviewed commit by commit. simplifies #99798 because we now don't have to expand `ty::UnevaluatedConst` to `ty::Const`. I also remember some other places where using `ty::UnevaluatedConst` directly was annoying and caused issues, though I don't quite remember what they were rn '^^ r? `@oli-obk` cc `@JulianKnodt`
2022-10-18Clean up query descriptionsnils-2/+2
Use the same tense everywhere and prefer display over debug, as these descriptions are user facing.
2022-10-18`const_evaluatable_unchecked` to const evallcnr-20/+24
2022-10-13fix small word dupe typosRageking8-2/+2
2022-10-08Rollup merge of #102782 - Hosshii:issue-102124, r=Mark-SimulacrumMichael Howell-0/+20
Add regression test for #102124 closes #102124, which was already fixed on nightly.
2022-10-07Add regression test for #102124Hosshii-0/+20
2022-10-07fix a ICE #102768Takayuki Maeda-0/+47
2022-10-04Normalize substs before resolving instance in NoopMethodCall lintMichael Goulet-0/+23
2022-10-01bless ui testsMaybe Waffle-16/+16
2022-09-26Auto merge of #102184 - chenyukang:fix-102087-add-binding-sugg, r=nagisabors-0/+5
Suggest Default::default() when binding isn't initialized Fixes #102087
2022-09-26fix #102087, Suggest Default::default() when binding isn't initializedyukang-0/+5
2022-09-23Always print '_, even for erased lifetimes.Camille GILLOT-4/+4
2022-09-22Rollup merge of #102119 - steffahn:fix-pararmeter, r=dtolnayDylan DPC-1/+1
Fix a typo “pararmeter” in error message Issue reported on IRLO: https://internals.rust-lang.org/t/fixing-a-typo/17427
2022-09-22Bless test output changesFrank Steffahn-1/+1
2022-09-21Make error messages great again (and fix clippy and add test)Deadbeef-11/+6
2022-09-17bless tests againDeadbeef-6/+11
2022-09-16bless testsDeadbeef-1/+4
2022-09-10Rollup merge of #101578 - lcnr:resolve-hack, r=jackh726Dylan DPC-2/+2
remove bound var hack in `resolve` somehow dropped that change from #98900. r? `@jackh726`
2022-09-09reviewlcnr-10/+10
2022-09-09rename `codegen_fulfill_obligation`lcnr-2/+2
2022-09-08update ui testslcnr-10/+10
2022-09-01Auto merge of #100707 - dzvon:fix-typo, r=davidtwcobors-1/+1
Fix a bunch of typo This PR will fix some typos detected by [typos]. I only picked the ones I was sure were spelling errors to fix, mostly in the comments. [typos]: https://github.com/crate-ci/typos
2022-08-31Rollup merge of #100838 - ↵Matthias Krüger-3/+10
hkmatsumoto:move-gen-args-to-trait-when-appropriate, r=davidtwco Suggest moving redundant generic args of an assoc fn to its trait Closes #89064
2022-08-31Fix a bunch of typoDezhi Wu-1/+1
This PR will fix some typos detected by [typos]. I only picked the ones I was sure were spelling errors to fix, mostly in the comments. [typos]: https://github.com/crate-ci/typos
2022-08-29Rollup merge of #100437 - compiler-errors:better-const-mismatch-err, r=oli-obkMatthias Krüger-42/+164
Improve const mismatch `FulfillmentError` Fixes #100414
2022-08-28Support method callsHirochika Matsumoto-3/+10