File tree 1 file changed +9
-9
lines changed
compiler/rustc_const_eval/src/const_eval
1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -140,21 +140,21 @@ pub(crate) fn const_to_valtree_inner<'tcx>(
140
140
ty:: Never
141
141
| ty:: Error ( _)
142
142
| ty:: Foreign ( ..)
143
- | ty:: Infer ( ty:: FreshIntTy ( _) )
144
- | ty:: Infer ( ty:: FreshFloatTy ( _) )
145
- | ty:: Projection ( ..)
146
- | ty:: Param ( _)
147
- | ty:: Bound ( ..)
148
- | ty:: Placeholder ( ..)
149
143
// FIXME(oli-obk): we could look behind opaque types
150
144
| ty:: Opaque ( ..)
151
- | ty:: Infer ( _)
152
145
// FIXME(oli-obk): we can probably encode closures just like structs
153
146
| ty:: Closure ( ..)
154
147
| ty:: Generator ( ..)
155
- // FIXME: we could look behind type aliases.
156
- | ty:: TyAlias ( ..)
157
148
| ty:: GeneratorWitness ( ..) => Err ( ValTreeCreationError :: NonSupportedType ) ,
149
+
150
+ ty:: Infer ( _)
151
+ | ty:: TyAlias ( ..)
152
+ | ty:: Projection ( ..)
153
+ | ty:: Param ( _)
154
+ | ty:: Bound ( ..)
155
+ | ty:: Placeholder ( ..) => {
156
+ bug ! ( "{:?} should have errored and never gotten converted to valtree" , ty. kind( ) )
157
+ }
158
158
}
159
159
}
160
160
You can’t perform that action at this time.
0 commit comments