Rollup merge of #69166 - JohnTitor:ice-const-enum, r=matthewjasper
Check `has_typeck_tables` before calling `typeck_tables_of` Fixes #68684 r? @matthewjasper
This commit is contained in:
commit
09d6a657b1
2 changed files with 19 additions and 1 deletions
15
src/test/ui/consts/issue-68684.rs
Normal file
15
src/test/ui/consts/issue-68684.rs
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
// check-pass
|
||||
|
||||
enum _Enum {
|
||||
A(),
|
||||
}
|
||||
|
||||
type _E = _Enum;
|
||||
|
||||
const fn _a() -> _Enum {
|
||||
_E::A()
|
||||
}
|
||||
|
||||
const _A: _Enum = _a();
|
||||
|
||||
fn main() {}
|
||||
Loading…
Add table
Add a link
Reference in a new issue