Evaluate fixed-length array length expressions lazily. This is in preparation for polymorphic array lengths (aka `[T; T::A]`) and const generics. We need deferred const-evaluation to break cycles when array types show up in positions which require knowing the array type to typeck the array length, e.g. the array type is in a `where` clause. The final step - actually passing bounds in scope to array length expressions from the parent - is not done because it still produces cycles when *normalizing* `ParamEnv`s, and @nikomatsakis' in-progress lazy normalization work is needed to deal with that uniformly. However, the changes here are still useful to unlock work on const generics, which @EpicatSupercell manifested interest in, and I might be mentoring them for that, but we need this baseline first. r? @nikomatsakis cc @oli-obk |
||
|---|---|---|
| .. | ||
| codegen | ||
| codegen-units | ||
| compile-fail | ||
| compile-fail-fulldeps | ||
| debuginfo | ||
| incremental | ||
| mir-opt | ||
| parse-fail | ||
| pretty | ||
| run-fail | ||
| run-fail-fulldeps | ||
| run-make | ||
| run-pass | ||
| run-pass-fulldeps | ||
| run-pass-valgrind | ||
| rustdoc | ||
| ui | ||
| ui-fulldeps | ||
| COMPILER_TESTS.md | ||