mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-24 15:54:15 +00:00
Change error in fn_queries
to delay_span_bug
This should be caught by the new check in `rustc_passes`. At some point, this function will be removed entirely.
This commit is contained in:
parent
61d86fa06c
commit
11bfc60a4b
@ -50,7 +50,7 @@ pub fn is_min_const_fn(tcx: TyCtxt<'_>, def_id: DefId) -> bool {
|
|||||||
None => {
|
None => {
|
||||||
if let Some(stab) = tcx.lookup_stability(def_id) {
|
if let Some(stab) = tcx.lookup_stability(def_id) {
|
||||||
if stab.level.is_stable() {
|
if stab.level.is_stable() {
|
||||||
tcx.sess.span_err(
|
tcx.sess.delay_span_bug(
|
||||||
tcx.def_span(def_id),
|
tcx.def_span(def_id),
|
||||||
"stable const functions must have either `rustc_const_stable` or \
|
"stable const functions must have either `rustc_const_stable` or \
|
||||||
`rustc_const_unstable` attribute",
|
`rustc_const_unstable` attribute",
|
||||||
|
Loading…
Reference in New Issue
Block a user