summary refs log tree commit diff
path: root/src/libsyntax/parse
AgeCommit message (Collapse)AuthorLines
2014-01-08Renamed Option::map_default and mutate_default to map_or and mutate_or_setMarvin Löbel-2/+2
2014-01-03librustc: Remove `@mut` support from the parserPatrick Walton-8/+4
2014-01-03libsyntax: De-`@mut` `CodeMap::files`Patrick Walton-1/+4
2014-01-03libsyntax: De-`@mut` `name_idx`Patrick Walton-7/+8
2014-01-03librustc: De-`@mut` the span handlerPatrick Walton-10/+10
2014-01-03libsyntax: De-`@mut` `StringReader`, `TtReader`, and `reader`Patrick Walton-59/+58
2014-01-03libsyntax: De-`@mut` `TtReader::cur_span`Patrick Walton-2/+2
2014-01-03libsyntax: De-`@mut` `TtReader::cur_tok`Patrick Walton-2/+5
2014-01-03libsyntax: De-`@mut` `StringReader::peek_span`Patrick Walton-9/+10
2014-01-03libsyntax: De-`@mut` `StringReader::peek_tok`Patrick Walton-10/+13
2014-01-03libsyntax: De-`@mut` `StringReader::curr`Patrick Walton-76/+80
2014-01-03libsyntax: De-`@mut` `StringReader::col`Patrick Walton-7/+7
2014-01-03libsyntax: De-`@mut` `StringReader::last_pos`Patrick Walton-48/+54
2014-01-03libsyntax: De-`@mut` `StringReader::pos`Patrick Walton-13/+14
2014-01-03librustc: De-`@mut` the parse sessionPatrick Walton-28/+28
2014-01-03libsyntax: De-`@mut` `ParseSess::included_mod_stack`Patrick Walton-16/+29
2014-01-03auto merge of #11149 : alexcrichton/rust/remove-either, r=brsonbors-13/+13
Had to change some stuff in typeck to bootstrap (getting methods in fmt off of Either), but other than that not so painful. Closes #9157
2014-01-03Remove std::eitherAlex Crichton-13/+13
2014-01-02libsyntax: Fix test and merge fallout.Patrick Walton-3/+3
2014-01-02libsyntax: Long linePatrick Walton-1/+2
2014-01-02libsyntax: Remove increasingly inaccurate commentPatrick Walton-1/+0
2014-01-02libsyntax: De-`@mut` `Parser::open_braces`Patrick Walton-5/+9
2014-01-02libsyntax: De-`@mut` `Parser::mod_path_stack`Patrick Walton-4/+3
2014-01-02libsyntax: De-`@mut` `Parser::obsolete_set`Patrick Walton-2/+2
2014-01-02libsyntax: De-`@mut` `Parser::restriction`Patrick Walton-7/+7
2014-01-02libsyntax: De-`@mut` `Parser::tokens_consumed`Patrick Walton-3/+3
2014-01-02libsyntax: De-`@mut` `Parser::buffer_start` and `Parser::buffer_end`Patrick Walton-13/+13
2014-01-02libsyntax: De-`@mut` `Parser::buffer`Patrick Walton-3/+3
2014-01-02libsyntax: De-`@mut` `Parser::last_token`Patrick Walton-3/+3
2014-01-02libsyntax: De-`@mut` `Parser::last_span`Patrick Walton-30/+28
2014-01-02libsyntax: De-`@mut` `Parser::span`Patrick Walton-49/+51
2014-01-02libsyntax: De-`@mut` `token` in the parserPatrick Walton-223/+221
2014-01-02libsyntax: De-`@mut` `quote_depth` in the parserPatrick Walton-4/+4
2014-01-02libsyntax: Make the parser mutablePatrick Walton-442/+459
2014-01-02auto merge of #10696 : fhahn/rust/issue9543-remove-extern-mod-foo, r=pcwaltonbors-2/+15
This patch for #9543 throws an `obsolete syntax` error for `extern mod foo (name="bar")` . I was wondering if [this](https://github.com/fhahn/rust/compare/mozilla:master...fhahn:issue9543-remove-extern-mod-foo?expand=1#diff-da9d34ca1d0f6beee2838cf02e07345cR4444) is the correct place to do this? I think the wording of the error message could probably be improved as well. If this approach is OK, I'm going to run the whole test suite tomorrow and update the old syntax to the new one.
2014-01-01Remove `extern mod foo (name="bar")` syntax, closes #9543Florian Hahn-2/+15
2014-01-01syntax::codemap: Add static DUMMY_SPklutzy-1/+1
It replaces `dummy_sp()`.
2014-01-01syntax::diagnostic: Remove unnecessary traitsklutzy-11/+11
This removes trait `handler` and `span_handler`, and renames `HandlerT` to `Handler`, `CodemapT` to `SpanHandler`.
2013-12-20auto merge of #11077 : alexcrichton/rust/crate-id, r=cmrbors-0/+24
Right now the --crate-id and related flags are all process *after* the entire crate is parsed. This is less than desirable when used with makefiles because it means that just to learn the output name of the crate you have to parse the entire crate (unnecessary). This commit changes the behavior to lift the handling of these flags much sooner in the compilation process. This allows us to not have to parse the entire crate and only have to worry about parsing the crate attributes themselves. The related methods have all been updated to take an array of attributes rather than a crate. Additionally, this ceases duplication of the "what output are we producing" logic in order to correctly handle things in the case of --test. Finally, this adds tests for all of this functionality to ensure that it does not regress.
2013-12-20rustc: Improve crate id extractionAlex Crichton-0/+24
Right now the --crate-id and related flags are all process *after* the entire crate is parsed. This is less than desirable when used with makefiles because it means that just to learn the output name of the crate you have to parse the entire crate (unnecessary). This commit changes the behavior to lift the handling of these flags much sooner in the compilation process. This allows us to not have to parse the entire crate and only have to worry about parsing the crate attributes themselves. The related methods have all been updated to take an array of attributes rather than a crate. Additionally, this ceases duplication of the "what output are we producing" logic in order to correctly handle things in the case of --test. Finally, this adds tests for all of this functionality to ensure that it does not regress.
2013-12-19Accept trailing commas in struct patternsAlex Crichton-2/+7
We decided in the 12/10/13 weekly meeting that trailing commas should be accepted pretty much anywhere. They are currently not allowed in struct patterns, and this commit adds support for that. Closes #10392
2013-12-18auto merge of #10915 : alexcrichton/rust/fixes, r=ILyoanbors-0/+6
Just a little cleanup.
2013-12-17Remove obsolete mutability from ast::TySeo Sanghyeon-9/+8
2013-12-15Forbid multiple imports in use statementsAlex Crichton-0/+6
Closes #10911
2013-12-15libsyntax: Implement the new `box` syntax for unique pointers.Patrick Walton-7/+25
2013-12-11auto merge of #10897 : boredomist/rust/remove-self-lifetime, r=brsonbors-9/+10
Also remove all instances of 'self within the codebase. This fixes #10889. To make reviewing easier the following files were modified with more than a dumb text replacement: - `src/test/compile-fail/lifetime-no-keyword.rs` - `src/test/compile-fail/lifetime-obsoleted-self.rs` - `src/test/compile-fail/regions-free-region-ordering-incorrect.rs` - `src/libsyntax/parse/lexer.rs`
2013-12-11Make 'self lifetime illegal.Erik Price-9/+10
Also remove all instances of 'self within the codebase. This fixes #10889.
2013-12-11auto merge of #10891 : ↵bors-271/+161
chris-morgan/rust/macroize-(or-should-that-be-macroify)-syntax--parse--token-so-that-we-don't-make-mistakes-and-to-reduce-the-maintenance-burden, r=huonw I also renumbered things at the same time; ``in`` was shifted into its alphabetical position and the reserved keywords were reordered (a couple of them were out of order). Unused special identifiers are also removed in the second part.
2013-12-11auto merge of #10808 : kballard/rust/use-braces, r=alexcrichtonbors-0/+15
This fixes #10806.
2013-12-10Support imports of the form `use {foo,bar}`Kevin Ballard-0/+15
This fixes #10806.