The callbacks have precisely two states: the default, and the one present throughout almost all of the rustc run (the filled in value which has access to TyCtxt). We used to store this as a thread local, and reset it on each thread to the non-default value. But this is somewhat wasteful, since there is no reason to set it globally -- while the callbacks themselves access TLS, they do not do so in a manner that fails in when we do not have TLS to work with.
25 lines
465 B
Rust
25 lines
465 B
Rust
#![feature(bool_to_option)]
|
|
#![feature(box_syntax)]
|
|
#![feature(set_stdio)]
|
|
#![feature(nll)]
|
|
#![feature(arbitrary_self_types)]
|
|
#![feature(generator_trait)]
|
|
#![feature(generators)]
|
|
#![cfg_attr(unix, feature(libc))]
|
|
#![recursion_limit = "256"]
|
|
|
|
#[cfg(unix)]
|
|
extern crate libc;
|
|
|
|
mod callbacks;
|
|
pub mod interface;
|
|
mod passes;
|
|
mod proc_macro_decls;
|
|
mod queries;
|
|
pub mod util;
|
|
|
|
pub use interface::{run_compiler, Config};
|
|
pub use queries::Queries;
|
|
|
|
#[cfg(test)]
|
|
mod tests;
|