File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -129,13 +129,13 @@ pub(crate) fn codegen_constant<'tcx>(
129
129
} ;
130
130
let const_val = match const_. val {
131
131
ConstKind :: Value ( const_val) => const_val,
132
- ConstKind :: Unevaluated ( ty :: Unevaluated { def , substs , promoted } )
133
- if fx. tcx . is_static ( def. did ) =>
132
+ ConstKind :: Unevaluated ( uv )
133
+ if fx. tcx . is_static ( uv . def . did ) =>
134
134
{
135
- assert ! ( substs. is_empty( ) ) ;
136
- assert ! ( promoted. is_none( ) ) ;
135
+ assert ! ( uv . substs( fx . tcx ) . is_empty( ) ) ;
136
+ assert ! ( uv . promoted. is_none( ) ) ;
137
137
138
- return codegen_static_ref ( fx, def. did , fx. layout_of ( const_. ty ) ) . to_cvalue ( fx) ;
138
+ return codegen_static_ref ( fx, uv . def . did , fx. layout_of ( const_. ty ) ) . to_cvalue ( fx) ;
139
139
}
140
140
ConstKind :: Unevaluated ( unevaluated) => {
141
141
match fx. tcx . const_eval_resolve ( ParamEnv :: reveal_all ( ) , unevaluated, None ) {
You can’t perform that action at this time.
0 commit comments