Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit c5fc260

Browse files
committed
Rename rustc_mir to rustc_const_eval.
1 parent fd9c04f commit c5fc260

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+66
-66
lines changed

Cargo.lock

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -3605,6 +3605,7 @@ dependencies = [
36053605
"either",
36063606
"itertools 0.9.0",
36073607
"polonius-engine",
3608+
"rustc_const_eval",
36083609
"rustc_data_structures",
36093610
"rustc_errors",
36103611
"rustc_graphviz",
@@ -3613,7 +3614,6 @@ dependencies = [
36133614
"rustc_infer",
36143615
"rustc_lexer",
36153616
"rustc_middle",
3616-
"rustc_mir",
36173617
"rustc_mir_dataflow",
36183618
"rustc_serialize",
36193619
"rustc_session",
@@ -3708,6 +3708,30 @@ dependencies = [
37083708
"tracing",
37093709
]
37103710

3711+
[[package]]
3712+
name = "rustc_const_eval"
3713+
version = "0.0.0"
3714+
dependencies = [
3715+
"either",
3716+
"gsgdt",
3717+
"rustc_apfloat",
3718+
"rustc_ast",
3719+
"rustc_attr",
3720+
"rustc_data_structures",
3721+
"rustc_errors",
3722+
"rustc_hir",
3723+
"rustc_index",
3724+
"rustc_infer",
3725+
"rustc_macros",
3726+
"rustc_middle",
3727+
"rustc_mir_dataflow",
3728+
"rustc_session",
3729+
"rustc_span",
3730+
"rustc_target",
3731+
"rustc_trait_selection",
3732+
"tracing",
3733+
]
3734+
37113735
[[package]]
37123736
name = "rustc_data_structures"
37133737
version = "0.0.0"
@@ -3746,6 +3770,7 @@ dependencies = [
37463770
"rustc_ast",
37473771
"rustc_ast_pretty",
37483772
"rustc_codegen_ssa",
3773+
"rustc_const_eval",
37493774
"rustc_data_structures",
37503775
"rustc_error_codes",
37513776
"rustc_errors",
@@ -3756,7 +3781,6 @@ dependencies = [
37563781
"rustc_lint",
37573782
"rustc_metadata",
37583783
"rustc_middle",
3759-
"rustc_mir",
37603784
"rustc_parse",
37613785
"rustc_plugin_impl",
37623786
"rustc_save_analysis",
@@ -3919,6 +3943,7 @@ dependencies = [
39193943
"rustc_builtin_macros",
39203944
"rustc_codegen_llvm",
39213945
"rustc_codegen_ssa",
3946+
"rustc_const_eval",
39223947
"rustc_data_structures",
39233948
"rustc_errors",
39243949
"rustc_expand",
@@ -3927,7 +3952,6 @@ dependencies = [
39273952
"rustc_lint",
39283953
"rustc_metadata",
39293954
"rustc_middle",
3930-
"rustc_mir",
39313955
"rustc_mir_build",
39323956
"rustc_mir_transform",
39333957
"rustc_monomorphize",
@@ -4073,30 +4097,6 @@ dependencies = [
40734097
"tracing",
40744098
]
40754099

4076-
[[package]]
4077-
name = "rustc_mir"
4078-
version = "0.0.0"
4079-
dependencies = [
4080-
"either",
4081-
"gsgdt",
4082-
"rustc_apfloat",
4083-
"rustc_ast",
4084-
"rustc_attr",
4085-
"rustc_data_structures",
4086-
"rustc_errors",
4087-
"rustc_hir",
4088-
"rustc_index",
4089-
"rustc_infer",
4090-
"rustc_macros",
4091-
"rustc_middle",
4092-
"rustc_mir_dataflow",
4093-
"rustc_session",
4094-
"rustc_span",
4095-
"rustc_target",
4096-
"rustc_trait_selection",
4097-
"tracing",
4098-
]
4099-
41004100
[[package]]
41014101
name = "rustc_mir_build"
41024102
version = "0.0.0"
@@ -4148,12 +4148,12 @@ dependencies = [
41484148
"itertools 0.9.0",
41494149
"rustc_ast",
41504150
"rustc_attr",
4151+
"rustc_const_eval",
41514152
"rustc_data_structures",
41524153
"rustc_errors",
41534154
"rustc_hir",
41544155
"rustc_index",
41554156
"rustc_middle",
4156-
"rustc_mir",
41574157
"rustc_mir_dataflow",
41584158
"rustc_serialize",
41594159
"rustc_session",

compiler/rustc_borrowck/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ rustc_index = { path = "../rustc_index" }
2121
rustc_infer = { path = "../rustc_infer" }
2222
rustc_lexer = { path = "../rustc_lexer" }
2323
rustc_middle = { path = "../rustc_middle" }
24-
rustc_mir = { path = "../rustc_mir" }
24+
rustc_const_eval = { path = "../rustc_const_eval" }
2525
rustc_mir_dataflow = { path = "../rustc_mir_dataflow" }
2626
rustc_serialize = { path = "../rustc_serialize" }
2727
rustc_session = { path = "../rustc_session" }

compiler/rustc_borrowck/src/diagnostics/conflict_errors.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1695,7 +1695,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
16951695
Some((method_did, method_substs)),
16961696
) = (
16971697
&self.body[loan.reserve_location.block].terminator,
1698-
rustc_mir::util::find_self_call(
1698+
rustc_const_eval::util::find_self_call(
16991699
tcx,
17001700
self.body,
17011701
loan.assigned_place.local,

compiler/rustc_borrowck/src/diagnostics/mod.rs

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -899,12 +899,13 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
899899
kind: TerminatorKind::Call { fn_span, from_hir_call, .. }, ..
900900
}) = &self.body[location.block].terminator
901901
{
902-
let (method_did, method_substs) = if let Some(info) = rustc_mir::util::find_self_call(
903-
self.infcx.tcx,
904-
&self.body,
905-
target_temp,
906-
location.block,
907-
) {
902+
let (method_did, method_substs) = if let Some(info) =
903+
rustc_const_eval::util::find_self_call(
904+
self.infcx.tcx,
905+
&self.body,
906+
target_temp,
907+
location.block,
908+
) {
908909
info
909910
} else {
910911
return normal_ret;

compiler/rustc_borrowck/src/diagnostics/mutability_errors.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ use rustc_span::{BytePos, Span};
1616

1717
use crate::diagnostics::BorrowedContentSource;
1818
use crate::MirBorrowckCtxt;
19+
use rustc_const_eval::util::collect_writes::FindAssignments;
1920
use rustc_errors::{Applicability, DiagnosticBuilder};
20-
use rustc_mir::util::collect_writes::FindAssignments;
2121

2222
#[derive(Copy, Clone, Debug, Eq, PartialEq)]
2323
pub(crate) enum AccessKind {

compiler/rustc_borrowck/src/type_check/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ use rustc_trait_selection::traits::query::type_op::custom::CustomTypeOp;
4141
use rustc_trait_selection::traits::query::Fallible;
4242
use rustc_trait_selection::traits::{self, ObligationCause, PredicateObligations};
4343

44-
use rustc_mir::transform::{
44+
use rustc_const_eval::transform::{
4545
check_consts::ConstCx, promote_consts::is_const_fn_in_array_repeat_expression,
4646
};
4747
use rustc_mir_dataflow::impls::MaybeInitializedPlaces;

compiler/rustc_mir/Cargo.toml renamed to compiler/rustc_const_eval/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[package]
2-
name = "rustc_mir"
2+
name = "rustc_const_eval"
33
version = "0.0.0"
44
edition = "2018"
55

0 commit comments

Comments
 (0)