Skip to content

Commit

Permalink
delete more useless pub
Browse files Browse the repository at this point in the history
  • Loading branch information
bvanjoi committed Oct 13, 2023
1 parent fdaff05 commit 1703f14
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 14 deletions.
2 changes: 0 additions & 2 deletions library/core/tests/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,6 @@
#![deny(unsafe_op_in_unsafe_fn)]
#![deny(fuzzy_provenance_casts)]

extern crate test;

mod alloc;
mod any;
mod array;
Expand Down
2 changes: 0 additions & 2 deletions library/core/tests/num/flt2dec/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ use core::num::flt2dec::{
};
use core::num::fmt::{Formatted, Part};

pub use test::Bencher;

mod estimator;
mod strategy {
mod dragon;
Expand Down
1 change: 1 addition & 0 deletions library/std/src/sys/common/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
// Progress on this is tracked in #84187.

#![allow(dead_code)]
#![allow(unused_imports)]

pub mod alloc;
pub mod small_c_string;
Expand Down
2 changes: 1 addition & 1 deletion src/tools/clippy/tests/ui/enum_glob_use.fixed
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ mod in_fn_test {
}

mod blurg {
pub use std::cmp::Ordering::*; // ok, re-export
// ok, re-export
}

fn main() {
Expand Down
11 changes: 10 additions & 1 deletion src/tools/clippy/tests/ui/enum_glob_use.stderr
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
error: unused import: `std::cmp::Ordering::*`
--> $DIR/enum_glob_use.rs:22:13
|
LL | pub use std::cmp::Ordering::*; // ok, re-export
| ^^^^^^^^^^^^^^^^^^^^^
|
= note: `-D unused-imports` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(unused_imports)]`

error: usage of wildcard import for enum variants
--> $DIR/enum_glob_use.rs:5:5
|
Expand All @@ -19,5 +28,5 @@ error: usage of wildcard import for enum variants
LL | use crate::Enum::*;
| ^^^^^^^^^^^^^^ help: try: `crate::Enum::Foo`

error: aborting due to 3 previous errors
error: aborting due to 4 previous errors

1 change: 1 addition & 0 deletions src/tools/miri/tests/utils/mod.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#![allow(dead_code)]
#![allow(unused_imports)]

#[macro_use]
mod macros;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,6 @@ fn generate_syntax_kinds(grammar: KindsSrc<'_>) -> String {
[ident] => { $crate::SyntaxKind::IDENT };
[shebang] => { $crate::SyntaxKind::SHEBANG };
}
pub use T;
};

sourcegen::add_preamble("sourcegen_ast", sourcegen::reformat(ast.to_string()))
Expand Down
7 changes: 0 additions & 7 deletions src/tools/rustfmt/src/config/options.rs
Original file line number Diff line number Diff line change
Expand Up @@ -142,13 +142,6 @@ pub enum HexLiteralCase {
Lower,
}

#[config_type]
pub enum ReportTactic {
Always,
Unnumbered,
Never,
}

/// What Rustfmt should emit. Mostly corresponds to the `--emit` command line
/// option.
#[config_type]
Expand Down

0 comments on commit 1703f14

Please sign in to comment.