]> git.lizzy.rs Git - rust.git/commitdiff
auto merge of #11720 : sfackler/rust/macro-export-source, r=alexcrichton
authorbors <bors@rust-lang.org>
Fri, 24 Jan 2014 08:06:31 +0000 (00:06 -0800)
committerbors <bors@rust-lang.org>
Fri, 24 Jan 2014 08:06:31 +0000 (00:06 -0800)
The old method of serializing the AST gives totally bogus spans if the
expansion of an imported macro causes compilation errors. The best
solution seems to be to serialize the actual textual macro definition
and load it the same way the std-macros are. I'm not totally confident
that getting the source from the CodeMap will always do the right thing,
but it seems to work in simple cases.

1  2 
src/librustc/metadata/csearch.rs
src/librustpkg/util.rs
src/libsyntax/ext/base.rs

Simple merge
Simple merge
Simple merge