2011-08-08 14:17:33 -07:00
|
|
|
import base::*;
|
2012-03-12 20:04:27 -07:00
|
|
|
import io::writer_util;
|
2011-08-08 14:17:33 -07:00
|
|
|
|
2012-01-31 23:50:12 -07:00
|
|
|
fn expand_syntax_ext(cx: ext_ctxt, sp: codemap::span, arg: ast::mac_arg,
|
2012-01-31 20:30:26 -07:00
|
|
|
_body: ast::mac_body) -> @ast::expr {
|
2012-05-14 15:32:32 -07:00
|
|
|
let args = get_mac_args_no_max(cx,sp,arg,0u,"log_syntax");
|
2011-08-08 14:17:33 -07:00
|
|
|
cx.print_backtrace();
|
2012-05-14 15:32:32 -07:00
|
|
|
io::stdout().write_line(
|
|
|
|
str::connect(vec::map(args,
|
|
|
|
{|&&ex| print::pprust::expr_to_str(ex)}), ", ")
|
|
|
|
);
|
2011-08-08 14:17:33 -07:00
|
|
|
|
|
|
|
//trivial expression
|
2012-06-25 20:00:46 -07:00
|
|
|
ret @{id: cx.next_id(), node: ast::expr_rec([]/~, option::none),
|
|
|
|
span: sp};
|
2011-08-12 07:15:18 -07:00
|
|
|
}
|