about summary refs log tree commit diff
path: root/compiler/rustc_mir_dataflow/src/framework/mod.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2022-08-22 11:39:53 +0000
committerbors <bors@rust-lang.org>2022-08-22 11:39:53 +0000
commita8a33cf27166d3eabaffc58ed3799e054af3b0c6 (patch)
tree38f1b1f29bc4b05bcf97c9f2c2fb7b3266f4f80d /compiler/rustc_mir_dataflow/src/framework/mod.rs
parentee8c31e64d229cac4eba6d8f03bb70e16f34a14b (diff)
parenta01ac5a6996f4fad346a6ff07edb197f74612aa8 (diff)
downloadrust-a8a33cf27166d3eabaffc58ed3799e054af3b0c6.tar.gz
rust-a8a33cf27166d3eabaffc58ed3799e054af3b0c6.zip
Auto merge of #99702 - SparrowLii:transtive_relation, r=oli-obk
get rid of `RefCell` in `TransitiveRelation`

This is one of the jobs in `Pending refactorings` in #48685. The parallel-compiler's work has been suspended for quite some time, but I think I can pick it up gradually. I think this PR should be a start.

Regarding the refactoring of `TransitiveRelation`, `@nikomatsakis`  has proposed [two(three?) schemes](https://github.com/rust-lang/rust/pull/48587#issuecomment-369336651). In order to satisfy both compilation efficiency and robustness, I think adding the `freeze` method may be the best solution, although it requires relatively more code changes.
Diffstat (limited to 'compiler/rustc_mir_dataflow/src/framework/mod.rs')
-rw-r--r--compiler/rustc_mir_dataflow/src/framework/mod.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/rustc_mir_dataflow/src/framework/mod.rs b/compiler/rustc_mir_dataflow/src/framework/mod.rs
index f9fd6c9c56b..d9aff94fef2 100644
--- a/compiler/rustc_mir_dataflow/src/framework/mod.rs
+++ b/compiler/rustc_mir_dataflow/src/framework/mod.rs
@@ -256,6 +256,7 @@ pub trait Analysis<'tcx>: AnalysisDomain<'tcx> {
     ///     .iterate_to_fixpoint()
     ///     .into_results_cursor(body);
     /// ```
+    #[inline]
     fn into_engine<'mir>(
         self,
         tcx: TyCtxt<'tcx>,
@@ -413,7 +414,7 @@ where
     }
 
     /* Extension methods */
-
+    #[inline]
     fn into_engine<'mir>(
         self,
         tcx: TyCtxt<'tcx>,