librustc_codegen_utils => 2018
This commit is contained in:
@@ -16,18 +16,10 @@
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
extern crate flate2;
|
||||
#[macro_use]
|
||||
extern crate log;
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate rustc;
|
||||
extern crate rustc_target;
|
||||
extern crate rustc_metadata;
|
||||
extern crate rustc_mir;
|
||||
extern crate rustc_incremental;
|
||||
extern crate syntax;
|
||||
extern crate syntax_pos;
|
||||
#[macro_use] extern crate rustc_data_structures;
|
||||
|
||||
use rustc::ty::TyCtxt;
|
||||
@@ -42,7 +34,7 @@ pub mod symbol_names_test;
|
||||
/// error in codegen. This is used to write compile-fail tests
|
||||
/// that actually test that compilation succeeds without
|
||||
/// reporting an error.
|
||||
pub fn check_for_rustc_errors_attr(tcx: TyCtxt) {
|
||||
pub fn check_for_rustc_errors_attr(tcx: TyCtxt<'_, '_, '_>) {
|
||||
if let Some((def_id, _)) = tcx.entry_fn(LOCAL_CRATE) {
|
||||
if tcx.has_attr(def_id, "rustc_error") {
|
||||
tcx.sess.span_fatal(tcx.def_span(def_id), "compilation successful");
|
||||
|
||||
Reference in New Issue
Block a user