diff options
| author | Jeffrey Seyfried <jeffrey.seyfried@gmail.com> | 2017-03-02 01:29:40 +0000 |
|---|---|---|
| committer | Jeffrey Seyfried <jeffrey.seyfried@gmail.com> | 2017-03-03 02:15:39 +0000 |
| commit | 0d554139ad7a54bbd59a5166cc3e9ff7842c5266 (patch) | |
| tree | 965d2d7db4fdb713e86ec4f8e32c0b543c175451 /src/libsyntax/util/parser_testing.rs | |
| parent | a02c18aa524cf330237ec9d8dba202ad91904a88 (diff) | |
| download | rust-0d554139ad7a54bbd59a5166cc3e9ff7842c5266.tar.gz rust-0d554139ad7a54bbd59a5166cc3e9ff7842c5266.zip | |
Fix fallout in unit tests.
Diffstat (limited to 'src/libsyntax/util/parser_testing.rs')
| -rw-r--r-- | src/libsyntax/util/parser_testing.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libsyntax/util/parser_testing.rs b/src/libsyntax/util/parser_testing.rs index e703dc6b419..51eb295b502 100644 --- a/src/libsyntax/util/parser_testing.rs +++ b/src/libsyntax/util/parser_testing.rs @@ -9,17 +9,17 @@ // except according to those terms. use ast::{self, Ident}; -use parse::{ParseSess,PResult,filemap_to_tts}; +use parse::{ParseSess, PResult, filemap_to_stream}; use parse::{lexer, new_parser_from_source_str}; use parse::parser::Parser; use ptr::P; -use tokenstream; +use tokenstream::TokenStream; use std::iter::Peekable; /// Map a string to tts, using a made-up filename: -pub fn string_to_tts(source_str: String) -> Vec<tokenstream::TokenTree> { +pub fn string_to_stream(source_str: String) -> TokenStream { let ps = ParseSess::new(); - filemap_to_tts(&ps, ps.codemap().new_filemap("bogofile".to_string(), None, source_str)) + filemap_to_stream(&ps, ps.codemap().new_filemap("bogofile".to_string(), None, source_str)) } /// Map string to parser (via tts) |
