diff options
| author | Kevin Atkinson <kevina@cs.utah.edu> | 2012-02-10 03:03:21 -0700 |
|---|---|---|
| committer | Kevin Atkinson <kevina@cs.utah.edu> | 2012-02-10 12:32:51 -0700 |
| commit | a7c362a6093b389e3a5f77e2ca91b05c57032498 (patch) | |
| tree | da5c430e410e40b27bfd8d83c05c4efd322e91ea /src/comp/syntax/parse | |
| parent | 7f1ea3ef6a92eb82ae66c47954ed955eba6028b1 (diff) | |
| download | rust-a7c362a6093b389e3a5f77e2ca91b05c57032498.tar.gz rust-a7c362a6093b389e3a5f77e2ca91b05c57032498.zip | |
Change file_substr to allow for external strings.
Diffstat (limited to 'src/comp/syntax/parse')
| -rw-r--r-- | src/comp/syntax/parse/parser.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/comp/syntax/parse/parser.rs b/src/comp/syntax/parse/parser.rs index 8e2897407a3..2352ac2f9db 100644 --- a/src/comp/syntax/parse/parser.rs +++ b/src/comp/syntax/parse/parser.rs @@ -2,7 +2,7 @@ import std::{io, fs}; import either::{left, right}; import std::map::{hashmap, new_str_hash}; import token::can_begin_expr; -import codemap::span; +import codemap::{span,fss_none}; import util::interner; import ast::{node_id, spanned}; import ast_util::{mk_sp, ident_to_path}; @@ -2607,7 +2607,7 @@ fn parse_crate_from_source_file(input: str, cfg: ast::crate_cfg, fn parse_expr_from_source_str(name: str, source: @str, cfg: ast::crate_cfg, sess: parse_sess) -> @ast::expr { - let p = new_parser_from_source_str(sess, cfg, name, none, source); + let p = new_parser_from_source_str(sess, cfg, name, fss_none, source); let r = parse_expr(p); sess.chpos = p.reader.chpos; sess.byte_pos = sess.byte_pos + p.reader.pos; @@ -2629,7 +2629,7 @@ fn parse_from_source_str<T>(f: fn (p: parser) -> T, fn parse_crate_from_source_str(name: str, source: @str, cfg: ast::crate_cfg, sess: parse_sess) -> @ast::crate { - let p = new_parser_from_source_str(sess, cfg, name, none, source); + let p = new_parser_from_source_str(sess, cfg, name, fss_none, source); let r = parse_crate_mod(p, cfg); sess.chpos = p.reader.chpos; sess.byte_pos = sess.byte_pos + p.reader.pos; |
