]> git.lizzy.rs Git - rust.git/commit
Move call site of `dep_graph_future()`.
authorNicholas Nethercote <nnethercote@mozilla.com>
Fri, 30 Aug 2019 06:53:34 +0000 (16:53 +1000)
committerNicholas Nethercote <nnethercote@mozilla.com>
Wed, 11 Sep 2019 00:59:05 +0000 (10:59 +1000)
commitd264a56068d7fd881b2e082c4d80d81d22c4ce79
treebac2a2f1e0ec73b957d0c7771b7eb37ee407e766
parentcd0c21b0e5b68e29c63c3c98db9147cb0e5a3bc8
Move call site of `dep_graph_future()`.

`Compiler::register_plugins()` calls `passes::register_plugins()`, which
calls `Compiler::dep_graph_future()`. This is the only way in which a
`passes` function calls a `Compiler` function.

This commit moves the `dep_graph_future()` call out of
`passes::register_plugins()` and into `Compiler::register_plugins()`,
which is a more sensible spot for it. This will delay the loading of the
dep graph slightly -- from the middle of plugin registration to the end
of plugin registration -- but plugin registration is fast enough
(especially compared to expansion) that the impact should be neglible.
src/librustc_interface/passes.rs
src/librustc_interface/queries.rs