Skip to content

Commit f581b55

Browse files
Remove mention of simd_shuffle promotion from comments
1 parent d194676 commit f581b55

File tree

2 files changed

+7
-9
lines changed

2 files changed

+7
-9
lines changed

src/librustc_mir/const_eval/eval_queries.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ fn eval_body_using_ecx<'mir, 'tcx>(
7272
Ok(ret)
7373
}
7474

75-
/// The `InterpCx` is only meant to be used to do field and index projections into constants for
76-
/// `simd_shuffle` and const patterns in match arms.
75+
/// The `InterpCx` is only meant to be used to do field and index projections into promoteds
76+
/// and const patterns in match arms.
7777
///
7878
/// The function containing the `match` that is currently being analyzed may have generic bounds
7979
/// that inform us about the generic bounds of the constant. E.g., using an associated constant

src/librustc_mir/transform/promote_consts.rs

+5-7
Original file line numberDiff line numberDiff line change
@@ -105,11 +105,10 @@ pub enum Candidate {
105105
/// Promotion of the `x` in `[x; 32]`.
106106
Repeat(Location),
107107

108-
/// Currently applied to function calls where the callee has the unstable
109-
/// `#[rustc_args_required_const]` attribute as well as the SIMD shuffle
110-
/// intrinsic. The intrinsic requires the arguments are indeed constant and
111-
/// the attribute currently provides the semantic requirement that arguments
112-
/// must be constant.
108+
/// Function calls where the callee has the unstable
109+
/// `#[rustc_args_required_const]` attribute. The attribute requires that
110+
/// the arguments be constant, usually because they are encoded as an
111+
/// immediate operand in a platform intrinsic.
113112
Argument { bb: BasicBlock, index: usize },
114113
}
115114

@@ -718,8 +717,7 @@ pub fn validate_candidates(
718717
.filter(|&candidate| {
719718
validator.explicit = candidate.forces_explicit_promotion();
720719

721-
// FIXME(eddyb) also emit the errors for shuffle indices
722-
// and `#[rustc_args_required_const]` arguments here.
720+
// FIXME(eddyb) also emit the errors for `#[rustc_args_required_const]` arguments here.
723721

724722
let is_promotable = validator.validate_candidate(candidate).is_ok();
725723
match candidate {

0 commit comments

Comments
 (0)