Auto merge of #62910 - petrochenkov:buildwarn2, r=Mark-Simulacrum
cleanup: Remove lint annotations in specific crates that are already enforced by rustbuild Remove some random unnecessary lint `allow`s. Deny `unused_lifetimes` through rustbuild. r? @Mark-Simulacrum
This commit is contained in:
commit
4560cb830f
@ -5,7 +5,8 @@
|
||||
//! parent directory, and otherwise documentation can be found throughout the `build`
|
||||
//! directory in each respective module.
|
||||
|
||||
#![deny(warnings)]
|
||||
// NO-RUSTC-WRAPPER
|
||||
#![deny(warnings, rust_2018_idioms, unused_lifetimes)]
|
||||
|
||||
use std::env;
|
||||
|
||||
|
@ -15,7 +15,8 @@
|
||||
//! switching compilers for the bootstrap and for build scripts will probably
|
||||
//! never get replaced.
|
||||
|
||||
#![deny(warnings)]
|
||||
// NO-RUSTC-WRAPPER
|
||||
#![deny(warnings, rust_2018_idioms, unused_lifetimes)]
|
||||
|
||||
use std::env;
|
||||
use std::ffi::OsString;
|
||||
@ -126,8 +127,11 @@ fn main() {
|
||||
|
||||
if env::var_os("RUSTC_DENY_WARNINGS").is_some() &&
|
||||
env::var_os("RUSTC_EXTERNAL_TOOL").is_none() {
|
||||
// When extending this list, search for `NO-RUSTC-WRAPPER` and add the new lints
|
||||
// there as well, some code doesn't go through this `rustc` wrapper.
|
||||
cmd.arg("-Dwarnings");
|
||||
cmd.arg("-Drust_2018_idioms");
|
||||
cmd.arg("-Dunused_lifetimes");
|
||||
// cfg(not(bootstrap)): Remove this during the next stage 0 compiler update.
|
||||
// `-Drustc::internal` is a new feature and `rustc_version` mis-reports the `stage`.
|
||||
let cfg_not_bootstrap = stage != "0" && crate_name != Some("rustc_version");
|
||||
|
@ -2,7 +2,8 @@
|
||||
//!
|
||||
//! See comments in `src/bootstrap/rustc.rs` for more information.
|
||||
|
||||
#![deny(warnings)]
|
||||
// NO-RUSTC-WRAPPER
|
||||
#![deny(warnings, rust_2018_idioms, unused_lifetimes)]
|
||||
|
||||
use std::env;
|
||||
use std::process::Command;
|
||||
|
@ -103,8 +103,9 @@
|
||||
//! More documentation can be found in each respective module below, and you can
|
||||
//! also check out the `src/bootstrap/README.md` file for more information.
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(warnings)]
|
||||
// NO-RUSTC-WRAPPER
|
||||
#![deny(warnings, rust_2018_idioms, unused_lifetimes)]
|
||||
|
||||
#![feature(core_intrinsics)]
|
||||
#![feature(drain_filter)]
|
||||
|
||||
@ -1312,7 +1313,7 @@ fn chmod(path: &Path, perms: u32) {
|
||||
fn chmod(_path: &Path, _perms: u32) {}
|
||||
|
||||
|
||||
impl<'a> Compiler {
|
||||
impl Compiler {
|
||||
pub fn with_stage(mut self, stage: u32) -> Compiler {
|
||||
self.stage = stage;
|
||||
self
|
||||
|
@ -1,4 +1,5 @@
|
||||
#![deny(rust_2018_idioms)]
|
||||
// NO-RUSTC-WRAPPER
|
||||
#![deny(warnings, rust_2018_idioms, unused_lifetimes)]
|
||||
|
||||
use std::fs::File;
|
||||
use std::path::{Path, PathBuf};
|
||||
|
@ -62,8 +62,6 @@
|
||||
#![warn(missing_docs)]
|
||||
#![warn(missing_debug_implementations)]
|
||||
#![deny(intra_doc_link_resolution_failure)] // rustdoc is run without -D warnings
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![allow(explicit_outlives_requirements)]
|
||||
|
||||
#![cfg_attr(not(test), feature(generator_trait))]
|
||||
|
@ -1838,6 +1838,7 @@ impl PartialEq for String {
|
||||
macro_rules! impl_eq {
|
||||
($lhs:ty, $rhs: ty) => {
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[allow(unused_lifetimes)]
|
||||
impl<'a, 'b> PartialEq<$rhs> for $lhs {
|
||||
#[inline]
|
||||
fn eq(&self, other: &$rhs) -> bool { PartialEq::eq(&self[..], &other[..]) }
|
||||
@ -1846,6 +1847,7 @@ macro_rules! impl_eq {
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[allow(unused_lifetimes)]
|
||||
impl<'a, 'b> PartialEq<$lhs> for $rhs {
|
||||
#[inline]
|
||||
fn eq(&self, other: &$lhs) -> bool { PartialEq::eq(&self[..], &other[..]) }
|
||||
|
@ -8,7 +8,6 @@
|
||||
#![feature(trusted_len)]
|
||||
#![feature(try_reserve)]
|
||||
#![feature(unboxed_closures)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
use std::hash::{Hash, Hasher};
|
||||
use std::collections::hash_map::DefaultHasher;
|
||||
|
@ -11,9 +11,6 @@
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/",
|
||||
test(no_crate_inject, attr(deny(warnings))))]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![feature(core_intrinsics)]
|
||||
#![feature(dropck_eyepatch)]
|
||||
#![feature(raw_vec_internals)]
|
||||
|
@ -217,7 +217,7 @@ where
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
impl<'a, 'b, A, B, const N: usize> PartialEq<[B; N]> for [A; N]
|
||||
impl<A, B, const N: usize> PartialEq<[B; N]> for [A; N]
|
||||
where
|
||||
A: PartialEq<B>,
|
||||
[A; N]: LengthAtMost32,
|
||||
@ -234,7 +234,7 @@ where
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
impl<'a, 'b, A, B, const N: usize> PartialEq<[B]> for [A; N]
|
||||
impl<A, B, const N: usize> PartialEq<[B]> for [A; N]
|
||||
where
|
||||
A: PartialEq<B>,
|
||||
[A; N]: LengthAtMost32,
|
||||
@ -250,7 +250,7 @@ where
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
impl<'a, 'b, A, B, const N: usize> PartialEq<[A; N]> for [B]
|
||||
impl<A, B, const N: usize> PartialEq<[A; N]> for [B]
|
||||
where
|
||||
B: PartialEq<A>,
|
||||
[A; N]: LengthAtMost32,
|
||||
@ -266,7 +266,7 @@ where
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
impl<'a, 'b, A, B, const N: usize> PartialEq<&'b [B]> for [A; N]
|
||||
impl<'b, A, B, const N: usize> PartialEq<&'b [B]> for [A; N]
|
||||
where
|
||||
A: PartialEq<B>,
|
||||
[A; N]: LengthAtMost32,
|
||||
@ -282,7 +282,7 @@ where
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
impl<'a, 'b, A, B, const N: usize> PartialEq<[A; N]> for &'b [B]
|
||||
impl<'b, A, B, const N: usize> PartialEq<[A; N]> for &'b [B]
|
||||
where
|
||||
B: PartialEq<A>,
|
||||
[A; N]: LengthAtMost32,
|
||||
@ -298,7 +298,7 @@ where
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
impl<'a, 'b, A, B, const N: usize> PartialEq<&'b mut [B]> for [A; N]
|
||||
impl<'b, A, B, const N: usize> PartialEq<&'b mut [B]> for [A; N]
|
||||
where
|
||||
A: PartialEq<B>,
|
||||
[A; N]: LengthAtMost32,
|
||||
@ -314,7 +314,7 @@ where
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
impl<'a, 'b, A, B, const N: usize> PartialEq<[A; N]> for &'b mut [B]
|
||||
impl<'b, A, B, const N: usize> PartialEq<[A; N]> for &'b mut [B]
|
||||
where
|
||||
B: PartialEq<A>,
|
||||
[A; N]: LengthAtMost32,
|
||||
|
@ -62,8 +62,6 @@
|
||||
#![warn(missing_docs)]
|
||||
#![warn(missing_debug_implementations)]
|
||||
#![deny(intra_doc_link_resolution_failure)] // rustdoc is run without -D warnings
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![allow(explicit_outlives_requirements)]
|
||||
|
||||
#![feature(allow_internal_unstable)]
|
||||
|
@ -775,7 +775,7 @@ where
|
||||
{}
|
||||
|
||||
#[stable(feature = "pin", since = "1.33.0")]
|
||||
impl<'a, P, U> DispatchFromDyn<Pin<U>> for Pin<P>
|
||||
impl<P, U> DispatchFromDyn<Pin<U>> for Pin<P>
|
||||
where
|
||||
P: DispatchFromDyn<U>,
|
||||
{}
|
||||
|
@ -172,7 +172,7 @@ impl<T: ?Sized> From<&T> for Unique<T> {
|
||||
}
|
||||
|
||||
#[unstable(feature = "ptr_internals", issue = "0")]
|
||||
impl<'a, T: ?Sized> From<NonNull<T>> for Unique<T> {
|
||||
impl<T: ?Sized> From<NonNull<T>> for Unique<T> {
|
||||
#[inline]
|
||||
fn from(p: NonNull<T>) -> Self {
|
||||
unsafe { Unique::new_unchecked(p.as_ptr()) }
|
||||
|
@ -32,7 +32,6 @@
|
||||
#![feature(const_fn)]
|
||||
#![feature(iter_partition_in_place)]
|
||||
#![feature(iter_is_partitioned)]
|
||||
#![warn(rust_2018_idioms)]
|
||||
|
||||
extern crate test;
|
||||
|
||||
|
@ -8,9 +8,6 @@
|
||||
html_playground_url = "https://play.rust-lang.org/",
|
||||
test(attr(deny(warnings))))]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![feature(nll)]
|
||||
#![feature(rustc_private)]
|
||||
#![feature(unicode_internals)]
|
||||
|
@ -274,8 +274,6 @@
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/",
|
||||
test(attr(allow(unused_variables), deny(warnings))))]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
#![feature(nll)]
|
||||
|
||||
use LabelText::*;
|
||||
|
@ -10,7 +10,6 @@
|
||||
#![panic_runtime]
|
||||
|
||||
#![allow(unused_features)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
#![feature(core_intrinsics)]
|
||||
#![feature(libc)]
|
||||
|
@ -17,8 +17,6 @@
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/",
|
||||
issue_tracker_base_url = "https://github.com/rust-lang/rust/issues/")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
#![feature(core_intrinsics)]
|
||||
#![feature(lang_items)]
|
||||
#![feature(libc)]
|
||||
|
@ -5,6 +5,7 @@ use std::mem;
|
||||
use std::ops::{Deref, DerefMut};
|
||||
|
||||
/// Type lambda application, with a lifetime.
|
||||
#[allow(unused_lifetimes)]
|
||||
pub trait ApplyL<'a> {
|
||||
type Out;
|
||||
}
|
||||
|
@ -17,8 +17,6 @@
|
||||
test(no_crate_inject, attr(deny(warnings))),
|
||||
test(attr(allow(dead_code, deprecated, unused_variables, unused_mut))))]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
#![feature(nll)]
|
||||
#![feature(staged_api)]
|
||||
#![feature(const_fn)]
|
||||
|
@ -7,4 +7,3 @@
|
||||
#![allow(unused_features)]
|
||||
#![feature(nll)]
|
||||
#![feature(staged_api)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
// Error messages for EXXXX errors.
|
||||
// Each message should start and end with a new line, and be wrapped to 80 characters.
|
||||
// In vim you can `:set tw=80` and use `gq` to wrap paragraphs. Use `:set tw=0` to disable.
|
||||
|
@ -28,9 +28,6 @@
|
||||
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![feature(arbitrary_self_types)]
|
||||
#![feature(box_patterns)]
|
||||
#![feature(box_syntax)]
|
||||
@ -81,8 +78,7 @@ extern crate libc;
|
||||
|
||||
// Use the test crate here so we depend on getopts through it. This allow tools to link to both
|
||||
// librustc_driver and libtest.
|
||||
#[allow(unused_extern_crates)]
|
||||
extern crate test;
|
||||
extern crate test as _;
|
||||
|
||||
#[macro_use]
|
||||
mod macros;
|
||||
|
@ -1628,7 +1628,7 @@ impl RustcOptGroup {
|
||||
// *unstable* options, i.e., options that are only enabled when the
|
||||
// user also passes the `-Z unstable-options` debugging flag.
|
||||
mod opt {
|
||||
// The `fn opt_u` etc below are written so that we can use them
|
||||
// The `fn flag*` etc below are written so that we can use them
|
||||
// in the future; do not warn about them not being used right now.
|
||||
#![allow(dead_code)]
|
||||
|
||||
|
@ -1,35 +1,25 @@
|
||||
#![allow(warnings)]
|
||||
use crate::ty::context::TyCtxt;
|
||||
use crate::ty::query::plumbing::CycleError;
|
||||
use crate::ty::query::Query;
|
||||
use crate::ty::tls;
|
||||
|
||||
use std::mem;
|
||||
use std::process;
|
||||
use std::{fmt, ptr};
|
||||
|
||||
use rustc_data_structures::fx::FxHashSet;
|
||||
use rustc_data_structures::sync::{Lock, LockGuard, Lrc, Weak};
|
||||
use rustc_data_structures::OnDrop;
|
||||
use rustc_data_structures::jobserver;
|
||||
use rustc_data_structures::sync::Lrc;
|
||||
use syntax_pos::Span;
|
||||
|
||||
use crate::ty::tls;
|
||||
use crate::ty::query::Query;
|
||||
use crate::ty::query::plumbing::CycleError;
|
||||
#[cfg(not(parallel_compiler))]
|
||||
use crate::ty::query::{
|
||||
plumbing::TryGetJob,
|
||||
config::QueryDescription,
|
||||
};
|
||||
use crate::ty::context::TyCtxt;
|
||||
use std::ptr;
|
||||
|
||||
#[cfg(parallel_compiler)]
|
||||
use {
|
||||
rustc_rayon_core as rayon_core,
|
||||
parking_lot::{Mutex, Condvar},
|
||||
std::sync::atomic::Ordering,
|
||||
std::thread,
|
||||
std::iter,
|
||||
std::iter::FromIterator,
|
||||
rustc_data_structures::{jobserver, OnDrop},
|
||||
rustc_data_structures::fx::FxHashSet,
|
||||
rustc_data_structures::stable_hasher::{StableHasher, HashStable},
|
||||
rustc_data_structures::sync::Lock,
|
||||
rustc_rayon_core as rayon_core,
|
||||
syntax_pos::DUMMY_SP,
|
||||
rustc_data_structures::stable_hasher::{StableHasherResult, StableHasher, HashStable},
|
||||
std::{mem, process, thread},
|
||||
std::iter::FromIterator,
|
||||
};
|
||||
|
||||
/// Indicates the state of a query for a given key in a query map.
|
||||
@ -81,7 +71,7 @@ impl<'tcx> QueryJob<'tcx> {
|
||||
span: Span,
|
||||
) -> Result<(), CycleError<'tcx>> {
|
||||
tls::with_related_context(tcx, move |icx| {
|
||||
let mut waiter = Lrc::new(QueryWaiter {
|
||||
let waiter = Lrc::new(QueryWaiter {
|
||||
query: icx.query.clone(),
|
||||
span,
|
||||
cycle: Lock::new(None),
|
||||
@ -138,6 +128,7 @@ impl<'tcx> QueryJob<'tcx> {
|
||||
self.latch.set();
|
||||
}
|
||||
|
||||
#[cfg(parallel_compiler)]
|
||||
fn as_ptr(&self) -> *const QueryJob<'tcx> {
|
||||
self as *const _
|
||||
}
|
||||
@ -431,7 +422,7 @@ fn remove_cycle<'tcx>(
|
||||
let usage = usage.as_ref().map(|(span, query)| (*span, query.info.query.clone()));
|
||||
|
||||
// Create the cycle error
|
||||
let mut error = CycleError {
|
||||
let error = CycleError {
|
||||
usage,
|
||||
cycle: stack.iter().map(|&(s, ref q)| QueryInfo {
|
||||
span: s,
|
||||
@ -463,9 +454,6 @@ fn remove_cycle<'tcx>(
|
||||
/// Must only be called when a deadlock is about to happen.
|
||||
#[cfg(parallel_compiler)]
|
||||
pub unsafe fn handle_deadlock() {
|
||||
use syntax;
|
||||
use syntax_pos;
|
||||
|
||||
let registry = rayon_core::Registry::current();
|
||||
|
||||
let gcx_ptr = tls::GCX_PTR.with(|gcx_ptr| {
|
||||
@ -473,11 +461,6 @@ pub unsafe fn handle_deadlock() {
|
||||
});
|
||||
let gcx_ptr = &*gcx_ptr;
|
||||
|
||||
let syntax_globals = syntax::GLOBALS.with(|syntax_globals| {
|
||||
syntax_globals as *const _
|
||||
});
|
||||
let syntax_globals = &*syntax_globals;
|
||||
|
||||
let syntax_pos_globals = syntax_pos::GLOBALS.with(|syntax_pos_globals| {
|
||||
syntax_pos_globals as *const _
|
||||
});
|
||||
|
@ -32,7 +32,6 @@
|
||||
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||
#![forbid(unsafe_code)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
#![feature(nll)]
|
||||
|
||||
|
@ -6,5 +6,3 @@
|
||||
#![unstable(feature = "sanitizer_runtime_lib",
|
||||
reason = "internal implementation detail of sanitizers",
|
||||
issue = "0")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
@ -1,8 +1,6 @@
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||
|
||||
#![allow(non_camel_case_types)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![feature(in_band_lifetimes)]
|
||||
#![feature(nll)]
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
register_long_diagnostics! {
|
||||
|
||||
E0511: r##"
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_upper_case_globals)]
|
||||
|
||||
use crate::attributes;
|
||||
use crate::llvm;
|
||||
use crate::llvm_util;
|
||||
|
@ -12,7 +12,6 @@
|
||||
#![feature(crate_visibility_modifier)]
|
||||
#![feature(extern_types)]
|
||||
#![feature(in_band_lifetimes)]
|
||||
#![allow(unused_attributes)]
|
||||
#![feature(libc)]
|
||||
#![feature(nll)]
|
||||
#![feature(rustc_diagnostic_macros)]
|
||||
@ -22,8 +21,6 @@
|
||||
#![feature(static_nobundle)]
|
||||
#![feature(trusted_len)]
|
||||
#![feature(mem_take)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
use back::write::{create_target_machine, create_informational_target_machine};
|
||||
use syntax_pos::symbol::Symbol;
|
||||
|
@ -1,3 +1,6 @@
|
||||
#![allow(non_camel_case_types)]
|
||||
#![allow(non_upper_case_globals)]
|
||||
|
||||
use super::debuginfo::{
|
||||
DIBuilder, DIDescriptor, DIFile, DILexicalBlock, DISubprogram, DIType,
|
||||
DIBasicType, DIDerivedType, DICompositeType, DIScope, DIVariable,
|
||||
|
@ -1,7 +1,4 @@
|
||||
#![allow(non_upper_case_globals)]
|
||||
#![allow(non_camel_case_types)]
|
||||
#![allow(non_snake_case)]
|
||||
#![deny(bare_trait_objects)]
|
||||
|
||||
pub use self::IntPredicate::*;
|
||||
pub use self::RealPredicate::*;
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_upper_case_globals)]
|
||||
|
||||
pub use crate::llvm::Type;
|
||||
|
||||
use crate::llvm;
|
||||
|
@ -781,12 +781,6 @@ impl CrateInfo {
|
||||
}
|
||||
}
|
||||
|
||||
fn is_codegened_item(tcx: TyCtxt<'_>, id: DefId) -> bool {
|
||||
let (all_mono_items, _) =
|
||||
tcx.collect_and_partition_mono_items(LOCAL_CRATE);
|
||||
all_mono_items.contains(&id)
|
||||
}
|
||||
|
||||
pub fn provide_both(providers: &mut Providers<'_>) {
|
||||
providers.backend_optimization_level = |tcx, cratenum| {
|
||||
let for_speed = match tcx.sess.opts.optimize {
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
register_long_diagnostics! {
|
||||
|
||||
E0668: r##"
|
||||
|
@ -11,10 +11,6 @@
|
||||
#![feature(nll)]
|
||||
#![feature(trusted_len)]
|
||||
#![feature(mem_take)]
|
||||
#![allow(unused_attributes)]
|
||||
#![allow(dead_code)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
|
@ -5,8 +5,6 @@
|
||||
//! This API is completely unstable and subject to change.
|
||||
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||
#![deny(warnings)]
|
||||
#![feature(box_syntax)]
|
||||
|
||||
use std::any::Any;
|
||||
use std::sync::mpsc;
|
||||
|
@ -10,15 +10,11 @@
|
||||
#![feature(core_intrinsics)]
|
||||
#![feature(never_type)]
|
||||
#![feature(nll)]
|
||||
#![allow(unused_attributes)]
|
||||
#![feature(rustc_diagnostic_macros)]
|
||||
#![feature(in_band_lifetimes)]
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate rustc;
|
||||
|
||||
|
@ -39,6 +39,7 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
#[allow(unused_lifetimes)]
|
||||
pub trait GraphSuccessors<'graph> {
|
||||
type Item;
|
||||
type Iter: Iterator<Item = Self::Item>;
|
||||
@ -54,6 +55,7 @@ where
|
||||
) -> <Self as GraphPredecessors<'_>>::Iter;
|
||||
}
|
||||
|
||||
#[allow(unused_lifetimes)]
|
||||
pub trait GraphPredecessors<'graph> {
|
||||
type Item;
|
||||
type Iter: Iterator<Item = Self::Item>;
|
||||
|
@ -26,7 +26,6 @@
|
||||
#![cfg_attr(unix, feature(libc))]
|
||||
#![cfg_attr(test, feature(test))]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![cfg_attr(not(bootstrap), allow(rustc::default_hash_types))]
|
||||
|
||||
#[macro_use]
|
||||
|
@ -283,6 +283,7 @@ impl<T> Erased for T {}
|
||||
/// Helper trait for erasing the concrete type of what an owner dereferences to,
|
||||
/// for example `Box<T> -> Box<Erased>`. This would be unneeded with
|
||||
/// higher kinded types support in the language.
|
||||
#[allow(unused_lifetimes)]
|
||||
pub unsafe trait IntoErased<'a> {
|
||||
/// Owner with the dereference type substituted to `Erased`.
|
||||
type Erased;
|
||||
@ -293,6 +294,7 @@ pub unsafe trait IntoErased<'a> {
|
||||
/// Helper trait for erasing the concrete type of what an owner dereferences to,
|
||||
/// for example `Box<T> -> Box<Erased + Send>`. This would be unneeded with
|
||||
/// higher kinded types support in the language.
|
||||
#[allow(unused_lifetimes)]
|
||||
pub unsafe trait IntoErasedSend<'a> {
|
||||
/// Owner with the dereference type substituted to `Erased + Send`.
|
||||
type Erased: Send;
|
||||
@ -303,6 +305,7 @@ pub unsafe trait IntoErasedSend<'a> {
|
||||
/// Helper trait for erasing the concrete type of what an owner dereferences to,
|
||||
/// for example `Box<T> -> Box<Erased + Send + Sync>`. This would be unneeded with
|
||||
/// higher kinded types support in the language.
|
||||
#[allow(unused_lifetimes)]
|
||||
pub unsafe trait IntoErasedSendSync<'a> {
|
||||
/// Owner with the dereference type substituted to `Erased + Send + Sync`.
|
||||
type Erased: Send + Sync;
|
||||
|
@ -16,9 +16,6 @@
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
pub extern crate getopts;
|
||||
#[cfg(unix)]
|
||||
extern crate libc;
|
||||
|
@ -5,12 +5,9 @@
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||
|
||||
#![feature(crate_visibility_modifier)]
|
||||
#![allow(unused_attributes)]
|
||||
#![cfg_attr(unix, feature(libc))]
|
||||
#![feature(nll)]
|
||||
#![feature(optin_builtin_traits)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
pub use emitter::ColorConfig;
|
||||
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
use std::path::{Path, PathBuf};
|
||||
use std::ffi::CString;
|
||||
use std::fs;
|
||||
|
@ -8,9 +8,6 @@
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#[macro_use] extern crate rustc;
|
||||
#[macro_use] extern crate log;
|
||||
|
||||
|
@ -12,7 +12,6 @@ use rustc_data_structures::OnDrop;
|
||||
use rustc_data_structures::sync::Lrc;
|
||||
use rustc_data_structures::fx::{FxHashSet, FxHashMap};
|
||||
use rustc_metadata::cstore::CStore;
|
||||
use std::io::Write;
|
||||
use std::path::PathBuf;
|
||||
use std::result;
|
||||
use std::sync::{Arc, Mutex};
|
||||
|
@ -6,11 +6,6 @@
|
||||
#![feature(generators)]
|
||||
#![cfg_attr(unix, feature(libc))]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![allow(unused_imports)]
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#[cfg(unix)]
|
||||
|
@ -2,7 +2,7 @@ use crate::interface::{Compiler, Result};
|
||||
use crate::util;
|
||||
use crate::proc_macro_decls;
|
||||
|
||||
use log::{debug, info, warn, log_enabled};
|
||||
use log::{info, warn, log_enabled};
|
||||
use rustc::dep_graph::DepGraph;
|
||||
use rustc::hir;
|
||||
use rustc::hir::lowering::lower_crate;
|
||||
@ -10,46 +10,39 @@ use rustc::hir::def_id::{CrateNum, LOCAL_CRATE};
|
||||
use rustc::lint;
|
||||
use rustc::middle::{self, reachable, resolve_lifetime, stability};
|
||||
use rustc::middle::cstore::CrateStore;
|
||||
use rustc::middle::privacy::AccessLevels;
|
||||
use rustc::ty::{self, AllArenas, Resolutions, TyCtxt, GlobalCtxt};
|
||||
use rustc::ty::steal::Steal;
|
||||
use rustc::traits;
|
||||
use rustc::util::common::{time, ErrorReported};
|
||||
use rustc::util::profiling::ProfileCategory;
|
||||
use rustc::session::{CompileResult, CrateDisambiguator, Session};
|
||||
use rustc::session::Session;
|
||||
use rustc::session::config::{self, CrateType, Input, OutputFilenames, OutputType};
|
||||
use rustc::session::search_paths::PathKind;
|
||||
use rustc_allocator as allocator;
|
||||
use rustc_ast_borrowck as borrowck;
|
||||
use rustc_codegen_ssa::back::link::emit_metadata;
|
||||
use rustc_codegen_utils::codegen_backend::CodegenBackend;
|
||||
use rustc_codegen_utils::link::filename_for_metadata;
|
||||
use rustc_data_structures::{box_region_allow_access, declare_box_region_type, parallel};
|
||||
use rustc_data_structures::fingerprint::Fingerprint;
|
||||
use rustc_data_structures::stable_hasher::StableHasher;
|
||||
use rustc_data_structures::sync::{Lrc, ParallelIterator, par_iter};
|
||||
use rustc_incremental;
|
||||
use rustc_incremental::DepGraphFuture;
|
||||
use rustc_metadata::creader::CrateLoader;
|
||||
use rustc_metadata::cstore::{self, CStore};
|
||||
use rustc_mir as mir;
|
||||
use rustc_passes::{self, ast_validation, hir_stats, loops, rvalue_promotion, layout_test};
|
||||
use rustc_passes::{self, ast_validation, hir_stats, layout_test};
|
||||
use rustc_plugin as plugin;
|
||||
use rustc_plugin::registry::Registry;
|
||||
use rustc_privacy;
|
||||
use rustc_resolve::{Resolver, ResolverArenas};
|
||||
use rustc_traits;
|
||||
use rustc_typeck as typeck;
|
||||
use syntax::{self, ast, attr, diagnostics, visit};
|
||||
use syntax::{self, ast, diagnostics, visit};
|
||||
use syntax::early_buffered_lints::BufferedEarlyLint;
|
||||
use syntax::ext::base::{NamedSyntaxExtension, ExtCtxt};
|
||||
use syntax::mut_visit::MutVisitor;
|
||||
use syntax::parse::{self, PResult};
|
||||
use syntax::util::node_count::NodeCounter;
|
||||
use syntax::util::lev_distance::find_best_match_for_name;
|
||||
use syntax::symbol::Symbol;
|
||||
use syntax::feature_gate::AttributeType;
|
||||
use syntax_pos::{FileName, edition::Edition, hygiene};
|
||||
use syntax_pos::FileName;
|
||||
use syntax_ext;
|
||||
|
||||
use rustc_serialize::json;
|
||||
@ -61,12 +54,11 @@ use std::ffi::OsString;
|
||||
use std::fs;
|
||||
use std::io::{self, Write};
|
||||
use std::iter;
|
||||
use std::path::{Path, PathBuf};
|
||||
use std::path::PathBuf;
|
||||
use std::sync::mpsc;
|
||||
use std::cell::RefCell;
|
||||
use std::rc::Rc;
|
||||
use std::mem;
|
||||
use std::ops::Generator;
|
||||
|
||||
pub fn parse<'a>(sess: &'a Session, input: &Input) -> PResult<'a, ast::Crate> {
|
||||
sess.diagnostic()
|
||||
|
@ -2,30 +2,18 @@ use crate::interface::{Compiler, Result};
|
||||
use crate::passes::{self, BoxedResolver, ExpansionResult, BoxedGlobalCtxt, PluginInfo};
|
||||
|
||||
use rustc_incremental::DepGraphFuture;
|
||||
use rustc_data_structures::sync::Lrc;
|
||||
use rustc::session::config::{Input, OutputFilenames, OutputType};
|
||||
use rustc::session::Session;
|
||||
use rustc::session::config::{OutputFilenames, OutputType};
|
||||
use rustc::util::common::{time, ErrorReported};
|
||||
use rustc::util::profiling::ProfileCategory;
|
||||
use rustc::lint;
|
||||
use rustc::hir;
|
||||
use rustc::hir::def_id::LOCAL_CRATE;
|
||||
use rustc::ty;
|
||||
use rustc::ty::steal::Steal;
|
||||
use rustc::dep_graph::DepGraph;
|
||||
use rustc_passes::hir_stats;
|
||||
use rustc_plugin::registry::Registry;
|
||||
use rustc_serialize::json;
|
||||
use std::cell::{Ref, RefMut, RefCell};
|
||||
use std::ops::Deref;
|
||||
use std::rc::Rc;
|
||||
use std::sync::mpsc;
|
||||
use std::any::Any;
|
||||
use std::mem;
|
||||
use syntax::parse::{self, PResult};
|
||||
use syntax::util::node_count::NodeCounter;
|
||||
use syntax::{self, ast, attr, diagnostics, visit};
|
||||
use syntax_pos::hygiene;
|
||||
use syntax::{self, ast};
|
||||
|
||||
/// Represent the result of a query.
|
||||
/// This result can be stolen with the `take` method and returned with the `give` method.
|
||||
|
@ -203,8 +203,6 @@ pub fn spawn_thread_pool<F: FnOnce() -> R + Send, R: Send>(
|
||||
f: F,
|
||||
) -> R {
|
||||
use rayon::{ThreadPool, ThreadPoolBuilder};
|
||||
use syntax;
|
||||
use syntax_pos;
|
||||
|
||||
let gcx_ptr = &Lock::new(0);
|
||||
|
||||
|
@ -19,9 +19,6 @@
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate rustc;
|
||||
|
||||
|
@ -1,4 +1,3 @@
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![feature(nll)]
|
||||
#![feature(static_nobundle)]
|
||||
|
||||
|
@ -6,5 +6,3 @@
|
||||
#![unstable(feature = "sanitizer_runtime_lib",
|
||||
reason = "internal implementation detail of sanitizers",
|
||||
issue = "0")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
@ -1,5 +1,4 @@
|
||||
#![feature(proc_macro_hygiene)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![cfg_attr(not(bootstrap), allow(rustc::default_hash_types))]
|
||||
|
||||
#![recursion_limit="128"]
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
use syntax::{register_diagnostics, register_long_diagnostics};
|
||||
|
||||
register_long_diagnostics! {
|
||||
|
@ -15,9 +15,6 @@
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
extern crate libc;
|
||||
extern crate proc_macro;
|
||||
|
||||
|
@ -1,7 +1,5 @@
|
||||
//! This pass type-checks the MIR to ensure it is not broken.
|
||||
|
||||
#![allow(unreachable_code)]
|
||||
|
||||
use crate::borrow_check::borrow_set::BorrowSet;
|
||||
use crate::borrow_check::location::LocationTable;
|
||||
use crate::borrow_check::nll::constraints::{OutlivesConstraintSet, OutlivesConstraint};
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
register_long_diagnostics! {
|
||||
|
||||
|
||||
|
@ -26,9 +26,6 @@ Rust MIR: a lowered representation of Rust. Also: an experiment!
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#[macro_use] extern crate log;
|
||||
#[macro_use] extern crate rustc;
|
||||
#[macro_use] extern crate rustc_data_structures;
|
||||
|
@ -6,5 +6,3 @@
|
||||
#![unstable(feature = "sanitizer_runtime_lib",
|
||||
reason = "internal implementation detail of sanitizers",
|
||||
issue = "0")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
use syntax::{register_diagnostics, register_long_diagnostics};
|
||||
|
||||
register_long_diagnostics! {
|
||||
|
@ -13,9 +13,6 @@
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate rustc;
|
||||
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
use syntax::{register_diagnostics, register_long_diagnostics};
|
||||
|
||||
register_long_diagnostics! {
|
||||
|
@ -59,8 +59,6 @@
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
pub use registry::Registry;
|
||||
|
||||
mod error_codes;
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
register_long_diagnostics! {
|
||||
|
||||
E0445: r##"
|
||||
|
@ -1,8 +1,5 @@
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![feature(in_band_lifetimes)]
|
||||
#![feature(nll)]
|
||||
#![feature(rustc_diagnostic_macros)]
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
use syntax::{register_diagnostics, register_long_diagnostics};
|
||||
|
||||
// Error messages for EXXXX errors. Each message should start and end with a
|
||||
|
@ -10,9 +10,6 @@
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
pub use rustc::hir::def::{Namespace, PerNS};
|
||||
|
||||
use Determinacy::*;
|
||||
|
@ -1,12 +1,8 @@
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||
#![feature(nll)]
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
#![allow(unused_attributes)]
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
|
||||
mod dumper;
|
||||
mod dump_visitor;
|
||||
#[macro_use]
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_upper_case_globals)]
|
||||
|
||||
use crate::abi::call::{FnType, ArgType};
|
||||
|
||||
fn classify_ret_ty<Ty>(ret: &mut ArgType<'_, Ty>) {
|
||||
|
@ -13,9 +13,6 @@
|
||||
#![feature(nll)]
|
||||
#![feature(slice_patterns)]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#[macro_use] extern crate log;
|
||||
|
||||
pub mod abi;
|
||||
|
@ -1,9 +1,6 @@
|
||||
//! New recursive solver modeled on Chalk's recursive solver. Most of
|
||||
//! the guts are broken up into modules; see the comments in those modules.
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![feature(crate_visibility_modifier)]
|
||||
#![feature(in_band_lifetimes)]
|
||||
#![feature(nll)]
|
||||
|
@ -6,5 +6,3 @@
|
||||
#![unstable(feature = "sanitizer_runtime_lib",
|
||||
reason = "internal implementation detail of sanitizers",
|
||||
issue = "0")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
@ -1,7 +1,5 @@
|
||||
// ignore-tidy-filelength
|
||||
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
register_long_diagnostics! {
|
||||
|
||||
E0023: r##"
|
||||
|
@ -73,9 +73,6 @@ This API is completely unstable and subject to change.
|
||||
|
||||
#![recursion_limit="256"]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#[macro_use] extern crate log;
|
||||
#[macro_use] extern crate syntax;
|
||||
|
||||
|
@ -1,6 +1,3 @@
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/",
|
||||
html_playground_url = "https://play.rust-lang.org/")]
|
||||
|
||||
|
@ -8,8 +8,6 @@ Core encoding and decoding interfaces.
|
||||
html_playground_url = "https://play.rust-lang.org/",
|
||||
test(attr(allow(unused_variables), deny(warnings))))]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
#![feature(box_syntax)]
|
||||
#![feature(core_intrinsics)]
|
||||
#![feature(specialization)]
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![deny(warnings)]
|
||||
|
||||
use std::env;
|
||||
|
||||
fn main() {
|
||||
|
@ -209,9 +209,8 @@
|
||||
#![warn(missing_docs)]
|
||||
#![warn(missing_debug_implementations)]
|
||||
#![deny(intra_doc_link_resolution_failure)] // rustdoc is run without -D warnings
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![allow(explicit_outlives_requirements)]
|
||||
#![allow(unused_lifetimes)]
|
||||
|
||||
// Tell the compiler to link to either panic_abort or panic_unwind
|
||||
#![needs_panic_runtime]
|
||||
|
@ -123,7 +123,6 @@ pub fn expand_register_diagnostic<'cx>(ecx: &'cx mut ExtCtxt<'_>,
|
||||
MacEager::items(smallvec![])
|
||||
}
|
||||
|
||||
#[allow(deprecated)]
|
||||
pub fn expand_build_diagnostic_array<'cx>(ecx: &'cx mut ExtCtxt<'_>,
|
||||
span: Span,
|
||||
token_tree: &[TokenTree])
|
||||
@ -149,7 +148,7 @@ pub fn expand_build_diagnostic_array<'cx>(ecx: &'cx mut ExtCtxt<'_>,
|
||||
ecx.span_bug(span, &format!(
|
||||
"error writing metadata for triple `{}` and crate `{}`, error: {}, \
|
||||
cause: {:?}",
|
||||
target_triple, crate_name, e.description(), e.cause()
|
||||
target_triple, crate_name, e.description(), e.source()
|
||||
));
|
||||
}
|
||||
});
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
// Error messages for EXXXX errors.
|
||||
// Each message should start and end with a new line, and be wrapped to 80 characters.
|
||||
// In vim you can `:set tw=80` and use `gq` to wrap paragraphs. Use `:set tw=0` to disable.
|
||||
|
@ -122,7 +122,6 @@ struct Diagnostic {
|
||||
}
|
||||
|
||||
#[derive(RustcEncodable)]
|
||||
#[allow(unused_attributes)]
|
||||
struct DiagnosticSpan {
|
||||
file_name: String,
|
||||
byte_start: u32,
|
||||
|
@ -7,9 +7,6 @@
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/",
|
||||
test(attr(deny(warnings))))]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![feature(bind_by_move_pattern_guards)]
|
||||
#![feature(box_syntax)]
|
||||
#![feature(const_fn)]
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(non_snake_case)]
|
||||
|
||||
use syntax::register_long_diagnostics;
|
||||
|
||||
// Error messages for EXXXX errors.
|
||||
|
@ -3,9 +3,6 @@
|
||||
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![feature(crate_visibility_modifier)]
|
||||
#![feature(decl_macro)]
|
||||
#![feature(mem_take)]
|
||||
|
@ -6,9 +6,6 @@
|
||||
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![deny(unused_lifetimes)]
|
||||
|
||||
#![feature(const_fn)]
|
||||
#![feature(crate_visibility_modifier)]
|
||||
#![feature(nll)]
|
||||
|
@ -35,8 +35,6 @@
|
||||
test(attr(deny(warnings))))]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
#![cfg_attr(windows, feature(libc))]
|
||||
|
||||
use std::io::prelude::*;
|
||||
|
@ -17,7 +17,6 @@
|
||||
// this crate, which relies on this attribute (rather than the value of `--crate-name` passed by
|
||||
// cargo) to detect this crate.
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
#![crate_name = "test"]
|
||||
#![unstable(feature = "test", issue = "27812")]
|
||||
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/", test(attr(deny(warnings))))]
|
||||
|
@ -1,8 +1,6 @@
|
||||
#![no_std]
|
||||
#![unstable(feature = "panic_unwind", issue = "32837")]
|
||||
|
||||
#![deny(rust_2018_idioms)]
|
||||
|
||||
#![feature(link_cfg)]
|
||||
#![feature(nll)]
|
||||
#![feature(staged_api)]
|
||||
|
@ -2,8 +2,7 @@
|
||||
|
||||
extern crate rustc;
|
||||
extern crate rustc_interface;
|
||||
#[allow(unused_extern_crates)]
|
||||
extern crate rustc_driver;
|
||||
extern crate rustc_driver as _;
|
||||
extern crate syntax;
|
||||
|
||||
use rustc::session::DiagnosticOutput;
|
||||
|
@ -5,7 +5,6 @@
|
||||
// libsyntax is not compiled for it.
|
||||
|
||||
#![deny(plugin_as_library)]
|
||||
#![allow(unused_extern_crates)]
|
||||
|
||||
extern crate attr_plugin_test; //~ ERROR compiler plugin used as an ordinary library
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
error: compiler plugin used as an ordinary library
|
||||
--> $DIR/plugin-as-extern-crate.rs:10:1
|
||||
--> $DIR/plugin-as-extern-crate.rs:9:1
|
||||
|
|
||||
LL | extern crate attr_plugin_test;
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
@ -6,7 +6,6 @@
|
||||
#![deny(non_snake_case)] // To trigger a hard error
|
||||
|
||||
// Shouldn't generate a warning about unstable features
|
||||
#[allow(unused_extern_crates)]
|
||||
extern crate stability_cfg2;
|
||||
|
||||
pub fn BOGUS() { } //~ ERROR
|
||||
|
@ -1,5 +1,5 @@
|
||||
error: function `BOGUS` should have a snake case name
|
||||
--> $DIR/enable-unstable-lib-feature.rs:12:8
|
||||
--> $DIR/enable-unstable-lib-feature.rs:11:8
|
||||
|
|
||||
LL | pub fn BOGUS() { }
|
||||
| ^^^^^ help: convert the identifier to snake case: `bogus`
|
||||
|
@ -1,4 +1,4 @@
|
||||
#![allow(unused_extern_crates, non_camel_case_types)]
|
||||
#![allow(non_camel_case_types)]
|
||||
|
||||
extern crate alloc;
|
||||
|
||||
|
@ -1,5 +1,4 @@
|
||||
#![feature(rustc_private)]
|
||||
#![allow(unused_extern_crates)]
|
||||
|
||||
extern crate alloc;
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
error[E0259]: the name `alloc` is defined multiple times
|
||||
--> $DIR/E0259.rs:6:1
|
||||
--> $DIR/E0259.rs:5:1
|
||||
|
|
||||
LL | extern crate alloc;
|
||||
| ------------------- previous import of the extern crate `alloc` here
|
||||
|
@ -1,5 +1,3 @@
|
||||
#![allow(unused_extern_crates)]
|
||||
|
||||
extern crate alloc;
|
||||
|
||||
mod alloc {
|
||||
|
@ -1,5 +1,5 @@
|
||||
error[E0260]: the name `alloc` is defined multiple times
|
||||
--> $DIR/E0260.rs:5:1
|
||||
--> $DIR/E0260.rs:3:1
|
||||
|
|
||||
LL | extern crate alloc;
|
||||
| ------------------- previous import of the extern crate `alloc` here
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user