Allow supplying an error destination via the compiler driver
Allows replacing stderr with a buffer from the client. Also, some refactoring around run_compiler.
This commit is contained in:
parent
322b5530ba
commit
e8a4db25ac
6 changed files with 56 additions and 33 deletions
|
|
@ -99,8 +99,10 @@ impl EmitterWriter {
|
|||
pub fn new(dst: Box<Write + Send>,
|
||||
code_map: Option<Rc<CodeMapper>>)
|
||||
-> EmitterWriter {
|
||||
EmitterWriter { dst: Raw(dst),
|
||||
cm: code_map}
|
||||
EmitterWriter {
|
||||
dst: Raw(dst),
|
||||
cm: code_map,
|
||||
}
|
||||
}
|
||||
|
||||
fn preprocess_annotations(&self, msp: &MultiSpan) -> Vec<FileWithAnnotatedLines> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue