diff options
| author | Ralf Jung <post@ralfj.de> | 2021-04-19 14:17:07 +0200 |
|---|---|---|
| committer | Ralf Jung <post@ralfj.de> | 2021-04-19 14:58:11 +0200 |
| commit | 46d09f7a4b2fe6675f06394a187cef46728412d3 (patch) | |
| tree | fc776c77646e24b7d931eef41f5e900698f56ce6 /compiler/rustc_mir | |
| parent | 04db4abbfceb39374ff21ccce563791c3112a153 (diff) | |
| download | rust-46d09f7a4b2fe6675f06394a187cef46728412d3.tar.gz rust-46d09f7a4b2fe6675f06394a187cef46728412d3.zip | |
remove E0723 error code
Diffstat (limited to 'compiler/rustc_mir')
| -rw-r--r-- | compiler/rustc_mir/src/transform/check_consts/validation.rs | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/compiler/rustc_mir/src/transform/check_consts/validation.rs b/compiler/rustc_mir/src/transform/check_consts/validation.rs index ce5e41d3e7c..cf7d404a077 100644 --- a/compiler/rustc_mir/src/transform/check_consts/validation.rs +++ b/compiler/rustc_mir/src/transform/check_consts/validation.rs @@ -1,6 +1,6 @@ //! The `Visitor` responsible for actually checking a `mir::Body` for invalid operations. -use rustc_errors::{struct_span_err, Applicability, Diagnostic, ErrorReported}; +use rustc_errors::{Applicability, Diagnostic, ErrorReported}; use rustc_hir::def_id::DefId; use rustc_hir::{self as hir, HirId, LangItem}; use rustc_index::bit_set::BitSet; @@ -234,13 +234,11 @@ impl Validator<'mir, 'tcx> { if self.is_const_stable_const_fn() { let hir_id = tcx.hir().local_def_id_to_hir_id(def_id); if crate::const_eval::is_parent_const_impl_raw(tcx, hir_id) { - struct_span_err!( - self.ccx.tcx.sess, - self.span, - E0723, - "trait methods cannot be stable const fn" - ) - .emit(); + self.ccx + .tcx + .sess + .struct_span_err(self.span, "trait methods cannot be stable const fn") + .emit(); } } |
