Skip to content

Commit

Permalink
fix unqualified_local_imports in rustc_const_eval
Browse files Browse the repository at this point in the history
  • Loading branch information
RalfJung committed Sep 23, 2024
1 parent 4c43757 commit 1eb51e7
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 8 deletions.
12 changes: 6 additions & 6 deletions compiler/rustc_const_eval/src/const_eval/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ mod fn_queries;
mod machine;
mod valtrees;

pub use dummy_machine::*;
pub use error::*;
pub use eval_queries::*;
pub use fn_queries::*;
pub use machine::*;
pub(crate) use valtrees::{eval_to_valtree, valtree_to_const_value};
pub use self::dummy_machine::*;
pub use self::error::*;
pub use self::eval_queries::*;
pub use self::fn_queries::*;
pub use self::machine::*;
pub(crate) use self::valtrees::{eval_to_valtree, valtree_to_const_value};

// We forbid type-level constants that contain more than `VALTREE_MAX_NODES` nodes.
const VALTREE_MAX_NODES: usize = 100000;
Expand Down
2 changes: 1 addition & 1 deletion compiler/rustc_const_eval/src/interpret/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ mod util;
mod validity;
mod visitor;

use eval_context::{from_known_layout, mir_assign_valid_types};
#[doc(no_inline)]
pub use rustc_middle::mir::interpret::*; // have all the `interpret` symbols in one place: here

pub use self::call::FnArg;
pub use self::eval_context::{InterpCx, format_interp_error};
use self::eval_context::{from_known_layout, mir_assign_valid_types};
pub use self::intern::{
HasStaticRootDefId, InternKind, InternResult, intern_const_alloc_for_constprop,
intern_const_alloc_recursive,
Expand Down
5 changes: 4 additions & 1 deletion compiler/rustc_const_eval/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
// tidy-alphabetical-start
#![allow(internal_features)]
#![allow(rustc::diagnostic_outside_of_impl)]
#![cfg_attr(not(bootstrap), feature(unqualified_local_imports))]
#![cfg_attr(not(bootstrap), warn(unqualified_local_imports))]
#![doc(rust_logo)]
#![feature(assert_matches)]
#![feature(box_patterns)]
Expand All @@ -25,10 +27,11 @@ pub mod util;

use std::sync::atomic::AtomicBool;

pub use errors::ReportErrorExt;
use rustc_middle::ty;
use rustc_middle::util::Providers;

pub use self::errors::ReportErrorExt;

rustc_fluent_macro::fluent_messages! { "../messages.ftl" }

pub fn provide(providers: &mut Providers) {
Expand Down

0 comments on commit 1eb51e7

Please sign in to comment.