diff options
| author | Brian Anderson <banderson@mozilla.com> | 2011-07-30 15:50:16 -0700 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2011-08-02 10:39:09 -0700 |
| commit | 5f4b7e1ba7121955ce4805cd55a51bc856d1f5b2 (patch) | |
| tree | 5d790b7fe89820389d627f072743d2b1bd24e6b9 /src/comp/syntax/parse/eval.rs | |
| parent | 2d5b651f4981b85d0e3864d8df6bd0953578e1f4 (diff) | |
| download | rust-5f4b7e1ba7121955ce4805cd55a51bc856d1f5b2.tar.gz rust-5f4b7e1ba7121955ce4805cd55a51bc856d1f5b2.zip | |
Compiler accepts input from stdin when source file is called "-"
Diffstat (limited to 'src/comp/syntax/parse/eval.rs')
| -rw-r--r-- | src/comp/syntax/parse/eval.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/comp/syntax/parse/eval.rs b/src/comp/syntax/parse/eval.rs index 08a60404172..c5bf0f2586b 100644 --- a/src/comp/syntax/parse/eval.rs +++ b/src/comp/syntax/parse/eval.rs @@ -9,6 +9,7 @@ import syntax::parse::parser::parser; import syntax::parse::parser::new_parser_from_file; import syntax::parse::parser::parse_inner_attrs_and_next; import syntax::parse::parser::parse_mod_items; +import syntax::parse::parser::SOURCE_FILE; export eval_crate_directives_to_mod; export mode_parse; @@ -55,7 +56,7 @@ fn eval_crate_directive(cx: ctx, cdir: @ast::crate_directive, prefix: str, if cx.mode == mode_depend { cx.deps += ~[full_path]; ret; } let p0 = new_parser_from_file(cx.sess, cx.cfg, full_path, cx.chpos, - cx.byte_pos); + cx.byte_pos, SOURCE_FILE); let inner_attrs = parse_inner_attrs_and_next(p0); let mod_attrs = attrs + inner_attrs.inner; let first_item_outer_attrs = inner_attrs.next; |
