about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2022-01-05 11:26:08 +0100
committerGitHub <noreply@github.com>2022-01-05 11:26:08 +0100
commitd83dd85253c70949155cd92694991475220b5e55 (patch)
treeab0bd47ed8df557510360100dbdd80f7ae1796e9 /compiler/rustc_codegen_llvm/src
parent42a3acfdb189cea6c19e6cbc7f1e0786986fecc5 (diff)
parentffbeebbf7a6dc5fba40b439fc0ebe80ac72af309 (diff)
downloadrust-d83dd85253c70949155cd92694991475220b5e55.tar.gz
rust-d83dd85253c70949155cd92694991475220b5e55.zip
Rollup merge of #92545 - dtolnay:rustlog, r=petrochenkov
Extract init_env_logger to crate

I've been doing some work on rustc_ast_pretty using an out-of-tree main.rs and Cargo.toml with the following:

```toml
[dependencies]
rustc_ast = { path = "../rust/compiler/rustc_ast" }
rustc_ast_pretty = { path = "../rust/compiler/rustc_ast_pretty" }
rustc_span = { path = "../rust/compiler/rustc_span" }
```

Rustc_ast_pretty helpfully uses `tracing::debug!` but I found that in order to enable the debug output, my test crate must depend on rustc_driver which is an enormously bigger dependency than what I have been using so far, and slows down iteration time because an enormous dependency tree between rustc_ast and rustc_driver must now be rebuilt after every ast change.

I pulled out the tracing initialization to a new minimal rustc_log crate so that projects depending on the other rustc crates, like rustc_ast_pretty, can access the `debug!` messages in them without building all the rest of rustc.
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
0 files changed, 0 insertions, 0 deletions