Michael Goulet
c5d0f6c05c
Don't manually walk through param indices when adding implicit Sized and ConstParamHasTy
2023-09-01 19:26:55 +00:00
Oli Scherer
5d850e0f50
Permit recursive weak type aliases
2023-08-30 11:55:03 +00:00
Esteban Küber
b86285af16
Do not emit invalid suggestion in E0191 when spans overlap
...
Fix #115019 .
2023-08-22 15:51:12 +00:00
Michael Goulet
e4cf708d2f
Don't add associated type bound for non-types
2023-08-11 21:33:08 +00:00
bors
f88a8b71ce
Auto merge of #114545 - fee1-dead-contrib:lower-impl-effect, r=oli-obk
...
correctly lower `impl const` to bind to host effect param
r? `@oli-obk`
2023-08-08 19:23:41 +00:00
León Orell Valerian Liehr
5468336d6b
Store the laziness of type aliases in the DefKind
2023-08-07 15:54:31 +02:00
Deadbeef
92f4c59e48
lower impl const to bind to host effect param
2023-08-06 13:34:53 +00:00
Deadbeef
4fec845c3f
Remove constness from TraitPredicate
2023-08-02 15:38:00 +00:00
Michael Goulet
ac6f2f0d2e
Fix a comment
2023-08-01 23:10:38 +00:00
Matthias Krüger
c64ef5e070
inline format!() args from rustc_codegen_llvm to the end (4)
...
r? @WaffleLapkin
2023-07-25 23:20:28 +02:00
Michael Goulet
846cc63e38
Make it clearer that edition functions are >=, not ==
2023-07-19 16:38:35 +00:00
Matthias Krüger
0baf4406da
Rollup merge of #113698 - compiler-errors:rpitit-check, r=spastorino
...
Make it clearer that we're just checking for an RPITIT
Tiny nit to use `is_impl_trait_in_trait` more, to make it clearer that we're just checking whether a def-id is an RPITIT, rather than doing something meaningful with the `opt_rpitit_info`.
r? `@spastorino`
2023-07-14 19:33:29 +02:00
Michael Goulet
14672eba8b
Make it clearer that we're just checking for an RPITIT
2023-07-14 15:18:48 +00:00
Mahdi Dibaiee
e55583c4b8
refactor(rustc_middle): Substs -> GenericArg
2023-07-14 13:27:35 +01:00
Mark Rousskov
cc907f80b9
Re-format let-else per rustfmt update
2023-07-12 21:49:27 -04:00
Santiago Pastorino
20429af7a3
Replace RPITIT current impl with new strategy that lowers as a GAT
2023-07-08 18:21:34 -03:00
Boxy
12138b8e5e
Move TyCtxt::mk_x
to Ty::new_x
where applicable
2023-07-05 20:27:07 +01:00
Oli Scherer
3219993fa8
Only use a single loop over the associated types
2023-07-05 07:46:05 +00:00
Oli Scherer
243687a37c
Prefer retain
over hand-rolling an inefficient version of it
2023-07-05 07:46:05 +00:00
Oli Scherer
62fbbac2d9
tidy: move a large function out of an even larger file
2023-07-05 07:46:04 +00:00
Oli Scherer
a49b736568
Lint now-unnecessary associated type bounds
2023-07-05 07:42:53 +00:00
Oli Scherer
ca581f9161
Don't require associated types with Self: Sized
bounds in dyn Trait
objects
2023-07-05 07:42:53 +00:00
Boxy
d30f56dbf2
Replace const_error
methods with Const::new_error
2023-07-04 14:46:32 +01:00
Boxy
ddbc774e74
Replace mk_const
with Const::new_x
methods
2023-07-04 14:26:33 +01:00
Michael Goulet
0c73b41cd6
remove TypeWellFormedFromEnv
2023-07-03 21:40:04 +00:00
León Orell Valerian Liehr
838f85d6f7
Don't perform selection if IATs are not enabled
2023-07-03 14:33:38 +02:00
bors
7383ab7378
Auto merge of #113154 - lcnr:better-probe-check, r=compiler-errors
...
change snapshot tracking in fulfillment contexts
use the exact snapshot number to prevent misuse even when created inside of a snapshot
2023-07-01 01:53:10 +00:00
Santiago Pastorino
d70deac161
Intern OpaqueTy on ItemKind::OpaqueTy
2023-06-29 14:05:10 -03:00
lcnr
d04775d739
change snapshot tracking in fulfillment contexts
2023-06-29 10:02:26 +02:00
Michael Goulet
de0e7d32fd
pass PredicateFilter to compute_bounds
2023-06-27 18:28:27 +00:00
Michael Goulet
374173cd99
TypeWellFormedInEnv
2023-06-26 23:12:04 +00:00
Michael Goulet
fbdef58414
Migrate predicates_of and caller_bounds to Clause
2023-06-26 23:12:03 +00:00
Michael Goulet
bfe6e5c418
Rollup merge of #112983 - spastorino:new-rpitit-23, r=compiler-errors
...
Fix return type notation associated type suggestion when -Zlower-impl-trait-in-trait-to-assoc-ty
This avoid suggesting the associated types generated for RPITITs when the one the code refers to doesn't exist and rustc looks for a suggestion.
r? `@compiler-errors`
2023-06-23 19:47:22 -07:00
Santiago Pastorino
6d997876c1
Fix associated type suggestion when -Zlower-impl-trait-in-trait-to-assoc-ty
2023-06-23 18:23:52 -03:00
Santiago Pastorino
d77e55bbb9
Fix return type notation errors with -Zlower-impl-trait-in-trait-to-assoc-ty
2023-06-23 17:34:33 -03:00
Guillaume Gomez
009d72b3ae
Rollup merge of #112853 - GuillaumeGomez:type_alias_type, r=oli-obk
...
Add `lazy_type_alias` feature gate
Add the `type_alias_type` to be able to have the weak alias used without restrictions.
Part of #112792 .
cc `@compiler-errors`
r? `@oli-obk`
2023-06-21 15:45:16 +02:00
Guillaume Gomez
60ec8405eb
Add lazy_type_alias
feature gate
2023-06-21 13:45:00 +02:00
Michael Goulet
21226eefb2
Fully fledged Clause type
2023-06-19 15:46:08 +00:00
Michael Goulet
fca56a8d2c
s/Clause/ClauseKind
2023-06-19 14:57:42 +00:00
Matthias Krüger
3436069c34
Rollup merge of #112734 - dswij:bounds-predicates-clause, r=compiler-errors
...
Make `Bound::predicates` use `Clause`
Part of #107250
`Bound::predicates` returns an iterator over `Binder<_, Clause>` instead of `Predicate`.
I tried updating `explicit_predicates_of` as well, but it seems that it needs a lot more change than I thought. Will do it in a separate PR instead.
2023-06-18 08:06:43 +02:00
Michael Goulet
4343d36079
Move some bounds computation out of astconv into its own file
2023-06-17 21:27:13 +00:00
Michael Goulet
6594c75449
Move ConstEvaluatable to Clause
2023-06-17 21:27:13 +00:00
Michael Goulet
52d3fc93f2
Move WF goal to clause
2023-06-17 21:20:20 +00:00
dswij
f874345784
Bound::predicates
to return Clause
2023-06-17 17:16:30 +08:00
Oli Scherer
79c2c986a2
Pacify tidy
2023-06-16 19:39:48 +00:00
Oli Scherer
f3b7dd6388
Add AliasKind::Weak
for type aliases.
...
Only use it when the type alias contains an opaque type.
Also does wf-checking on such type aliases.
2023-06-16 19:39:48 +00:00
León Orell Valerian Liehr
a995255cf5
iat selection: normalize self ty & completely erase bound vars
2023-06-11 00:19:47 +02:00
bors
e94bda3bf1
Auto merge of #111047 - compiler-errors:rtn-no-ty-ct-params, r=spastorino
...
Emit an error when return-type-notation is used with type/const params
These are not intended to be supported initially, even though the compiler supports them internally...
2023-06-07 09:03:33 +00:00
Michael Goulet
b0eaaca314
Remove redundant InferCtxtExt::fresh_item_substs
2023-06-05 20:05:08 +00:00
Michael Goulet
bbc536d3ac
Emit an error when RTN is used with ty/ct params
2023-06-05 19:52:04 +00:00