From 87048a46fc75dc343637e3c7d3d654fc10d5e589 Mon Sep 17 00:00:00 2001 From: Jubilee Young Date: Fri, 24 May 2024 01:33:13 -0700 Subject: [PATCH] compiler: unnest rustc_const_eval::check_consts --- .../rustc_const_eval/src/{transform => }/check_consts/check.rs | 0 .../rustc_const_eval/src/{transform => }/check_consts/mod.rs | 0 .../rustc_const_eval/src/{transform => }/check_consts/ops.rs | 0 .../src/{transform => }/check_consts/post_drop_elaboration.rs | 0 .../src/{transform => }/check_consts/qualifs.rs | 0 .../src/{transform => }/check_consts/resolver.rs | 0 compiler/rustc_const_eval/src/lib.rs | 2 +- compiler/rustc_const_eval/src/transform/mod.rs | 1 - compiler/rustc_mir_transform/src/lib.rs | 2 +- compiler/rustc_mir_transform/src/promote_consts.rs | 2 +- 10 files changed, 3 insertions(+), 4 deletions(-) rename compiler/rustc_const_eval/src/{transform => }/check_consts/check.rs (100%) rename compiler/rustc_const_eval/src/{transform => }/check_consts/mod.rs (100%) rename compiler/rustc_const_eval/src/{transform => }/check_consts/ops.rs (100%) rename compiler/rustc_const_eval/src/{transform => }/check_consts/post_drop_elaboration.rs (100%) rename compiler/rustc_const_eval/src/{transform => }/check_consts/qualifs.rs (100%) rename compiler/rustc_const_eval/src/{transform => }/check_consts/resolver.rs (100%) delete mode 100644 compiler/rustc_const_eval/src/transform/mod.rs diff --git a/compiler/rustc_const_eval/src/transform/check_consts/check.rs b/compiler/rustc_const_eval/src/check_consts/check.rs similarity index 100% rename from compiler/rustc_const_eval/src/transform/check_consts/check.rs rename to compiler/rustc_const_eval/src/check_consts/check.rs diff --git a/compiler/rustc_const_eval/src/transform/check_consts/mod.rs b/compiler/rustc_const_eval/src/check_consts/mod.rs similarity index 100% rename from compiler/rustc_const_eval/src/transform/check_consts/mod.rs rename to compiler/rustc_const_eval/src/check_consts/mod.rs diff --git a/compiler/rustc_const_eval/src/transform/check_consts/ops.rs b/compiler/rustc_const_eval/src/check_consts/ops.rs similarity index 100% rename from compiler/rustc_const_eval/src/transform/check_consts/ops.rs rename to compiler/rustc_const_eval/src/check_consts/ops.rs diff --git a/compiler/rustc_const_eval/src/transform/check_consts/post_drop_elaboration.rs b/compiler/rustc_const_eval/src/check_consts/post_drop_elaboration.rs similarity index 100% rename from compiler/rustc_const_eval/src/transform/check_consts/post_drop_elaboration.rs rename to compiler/rustc_const_eval/src/check_consts/post_drop_elaboration.rs diff --git a/compiler/rustc_const_eval/src/transform/check_consts/qualifs.rs b/compiler/rustc_const_eval/src/check_consts/qualifs.rs similarity index 100% rename from compiler/rustc_const_eval/src/transform/check_consts/qualifs.rs rename to compiler/rustc_const_eval/src/check_consts/qualifs.rs diff --git a/compiler/rustc_const_eval/src/transform/check_consts/resolver.rs b/compiler/rustc_const_eval/src/check_consts/resolver.rs similarity index 100% rename from compiler/rustc_const_eval/src/transform/check_consts/resolver.rs rename to compiler/rustc_const_eval/src/check_consts/resolver.rs diff --git a/compiler/rustc_const_eval/src/lib.rs b/compiler/rustc_const_eval/src/lib.rs index b14780c0d98c2..3a7c87c1cad94 100644 --- a/compiler/rustc_const_eval/src/lib.rs +++ b/compiler/rustc_const_eval/src/lib.rs @@ -14,10 +14,10 @@ #![feature(yeet_expr)] #![feature(if_let_guard)] +pub mod check_consts; pub mod const_eval; mod errors; pub mod interpret; -pub mod transform; pub mod util; use std::sync::atomic::AtomicBool; diff --git a/compiler/rustc_const_eval/src/transform/mod.rs b/compiler/rustc_const_eval/src/transform/mod.rs deleted file mode 100644 index b4516a412ef01..0000000000000 --- a/compiler/rustc_const_eval/src/transform/mod.rs +++ /dev/null @@ -1 +0,0 @@ -pub mod check_consts; diff --git a/compiler/rustc_mir_transform/src/lib.rs b/compiler/rustc_mir_transform/src/lib.rs index 30d4b480f5890..e4670633914e4 100644 --- a/compiler/rustc_mir_transform/src/lib.rs +++ b/compiler/rustc_mir_transform/src/lib.rs @@ -111,7 +111,7 @@ mod unreachable_enum_branching; mod unreachable_prop; mod validate; -use rustc_const_eval::transform::check_consts::{self, ConstCx}; +use rustc_const_eval::check_consts::{self, ConstCx}; use rustc_mir_dataflow::rustc_peek; rustc_fluent_macro::fluent_messages! { "../messages.ftl" } diff --git a/compiler/rustc_mir_transform/src/promote_consts.rs b/compiler/rustc_mir_transform/src/promote_consts.rs index 34aa31baab79d..e37f90ae7f400 100644 --- a/compiler/rustc_mir_transform/src/promote_consts.rs +++ b/compiler/rustc_mir_transform/src/promote_consts.rs @@ -30,7 +30,7 @@ use std::assert_matches::assert_matches; use std::cell::Cell; use std::{cmp, iter, mem}; -use rustc_const_eval::transform::check_consts::{qualifs, ConstCx}; +use rustc_const_eval::check_consts::{qualifs, ConstCx}; /// A `MirPass` for promotion. ///