Only inherit const stability for methods of impl const Trait blocks
This commit is contained in:
@@ -929,7 +929,7 @@ impl Visitor<'tcx> for Validator<'mir, 'tcx> {
|
||||
if callee_is_unstable_unmarked {
|
||||
trace!("callee_is_unstable_unmarked");
|
||||
// We do not use `const` modifiers for intrinsic "functions", as intrinsics are
|
||||
// `extern` funtions, and these have way to get marked `const`. So instead we
|
||||
// `extern` funtions, and these have no way to get marked `const`. So instead we
|
||||
// use `rustc_const_(un)stable` attributes to mean that the intrinsic is `const`
|
||||
if self.ccx.is_const_stable_const_fn() || is_intrinsic {
|
||||
self.check_op(ops::FnCallUnstable(callee, None));
|
||||
|
||||
Reference in New Issue
Block a user