Skip to content

Commit dc16682

Browse files
authored
Rollup merge of #142528 - fee1-dead-contrib:push-rlxklunqkwmv, r=RalfJung
clarify `rustc_do_not_const_check` comment ~~Given that we have used this attribute for other reasons before it seems appropriate to make this a "usually".~~ Add function name as a pointer cc ```@rust-lang/wg-const-eval```
2 parents 2c4abc0 + a0db28f commit dc16682

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

compiler/rustc_feature/src/builtin_attrs.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -887,7 +887,7 @@ pub static BUILTIN_ATTRIBUTES: &[BuiltinAttribute] = &[
887887
rustc_legacy_const_generics, Normal, template!(List: "N"), ErrorFollowing,
888888
EncodeCrossCrate::Yes,
889889
),
890-
// Do not const-check this function's body. It will always get replaced during CTFE.
890+
// Do not const-check this function's body. It will always get replaced during CTFE via `hook_special_const_fn`.
891891
rustc_attr!(
892892
rustc_do_not_const_check, Normal, template!(Word), WarnFollowing,
893893
EncodeCrossCrate::Yes, "`#[rustc_do_not_const_check]` skips const-check for this function's body",

src/tools/rust-analyzer/crates/hir-expand/src/inert_attr_macro.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -486,7 +486,7 @@ pub const INERT_ATTRIBUTES: &[BuiltinAttribute] = &[
486486
rustc_legacy_const_generics, Normal, template!(List: "N"), ErrorFollowing,
487487
INTERNAL_UNSTABLE
488488
),
489-
// Do not const-check this function's body. It will always get replaced during CTFE.
489+
// Do not const-check this function's body. It will always get replaced during CTFE via `hook_special_const_fn`.
490490
rustc_attr!(
491491
rustc_do_not_const_check, Normal, template!(Word), WarnFollowing, INTERNAL_UNSTABLE
492492
),

0 commit comments

Comments
 (0)