diff options
| author | bjorn3 <17426603+bjorn3@users.noreply.github.com> | 2025-01-22 14:13:14 +0000 |
|---|---|---|
| committer | bjorn3 <17426603+bjorn3@users.noreply.github.com> | 2025-01-23 09:38:58 +0000 |
| commit | a77776cc1d7c599f4ff9355ffe01bad2e2b5bbad (patch) | |
| tree | da03459bc81a07b8a732063c119fd595852a977d /src/doc/rustc-dev-guide/examples/rustc-driver-interacting-with-the-ast.rs | |
| parent | 974db1a6e444e2b053f49a8d3242db335669acef (diff) | |
| download | rust-a77776cc1d7c599f4ff9355ffe01bad2e2b5bbad.tar.gz rust-a77776cc1d7c599f4ff9355ffe01bad2e2b5bbad.zip | |
Remove RunCompiler
It has become nothing other than a wrapper around run_compiler.
Diffstat (limited to 'src/doc/rustc-dev-guide/examples/rustc-driver-interacting-with-the-ast.rs')
| -rw-r--r-- | src/doc/rustc-dev-guide/examples/rustc-driver-interacting-with-the-ast.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/doc/rustc-dev-guide/examples/rustc-driver-interacting-with-the-ast.rs b/src/doc/rustc-dev-guide/examples/rustc-driver-interacting-with-the-ast.rs index 6c06bbed50b..c894b60444a 100644 --- a/src/doc/rustc-dev-guide/examples/rustc-driver-interacting-with-the-ast.rs +++ b/src/doc/rustc-dev-guide/examples/rustc-driver-interacting-with-the-ast.rs @@ -18,7 +18,7 @@ use std::path::Path; use rustc_ast_pretty::pprust::item_to_string; use rustc_data_structures::sync::Lrc; -use rustc_driver::{Compilation, RunCompiler}; +use rustc_driver::{Compilation, run_compiler}; use rustc_interface::interface::{Compiler, Config}; use rustc_middle::ty::TyCtxt; @@ -94,5 +94,5 @@ impl rustc_driver::Callbacks for MyCallbacks { } fn main() { - RunCompiler::new(&["main.rs".to_string()], &mut MyCallbacks).run(); + run_compiler(&["main.rs".to_string()], &mut MyCallbacks); } |
