about summary refs log tree commit diff
path: root/src/comp/syntax/ext
AgeCommit message (Collapse)AuthorLines
2012-03-13fixup serialize_variantNiko Matsakis-388/+0
2012-03-13get new decorator extensions workingNiko Matsakis-0/+388
2012-03-02Move src/comp to src/rustcGraydon Hoare-1861/+0
2012-02-23Finish cleanup of core::strMarijn Haverbeke-1/+1
Closes #1849
2012-02-23(core::str) mostly rename len -> len_charsKevin Cantu-1/+1
2012-02-22Clean up small things in syntax submodulesMarijn Haverbeke-1/+1
2012-02-21rustc: Generate crates with #astBrian Anderson-0/+18
2012-02-15make mut a keyword synonymous with mutableNiko Matsakis-4/+4
first step towards issue #1273
2012-02-14Bug fix to accept $ in 0th pos, (ie #ast{$(x) + ...}).Kevin Atkinson-4/+5
Note: part from Niko Matsakis commit: rewrite assert to accept a $ in 0th pos.
2012-02-14Use file_substr rather than <anon> when re-parsing quasi-quotesKevin Atkinson-18/+23
for better error messages.
2012-02-14Change file_substr to allow for external strings.Kevin Atkinson-4/+3
2012-02-12(core::str) rename byte_len -> len_bytes and rename char_len -> lenKevin Cantu-1/+1
2012-02-09Remove some pointless importsMarijn Haverbeke-16/+0
2012-02-05Fix macro backtraces.Kevin Atkinson-28/+48
In addition add information about the macro doing the expansion, and move the printing of the expansion backtrace from codemap::span_to_str to the diagnostic code. The backtrace is now more verbose and includes information on the macro doing the expansion, in addition to the expansion site.
2012-02-05Remove support for $(...) form of quasi-quotes, use #ast{...} instead.Kevin Atkinson-16/+4
2012-02-03Fix various drift issues in the qq branch.Graydon Hoare-2/+3
2012-02-03Fix q-q so that non-expression q-q actually work when there is embed anti-q.Kevin Atkinson-7/+21
2012-02-03Allow anti-quotes to also be ast::ty rather than just ast::expr.Kevin Atkinson-13/+66
2012-02-03Implement quasi-quoting of multiple syntatic categories.Kevin Atkinson-22/+112
2012-02-03Formatting cleanups.Kevin Atkinson-10/+12
2012-02-03Store info about file "substr".Kevin Atkinson-1/+3
That is when a string that is part of a file needs to be parsed for a reason, record that the string is a substr of the file rather than using "<anon>" or "-" as the file name. This will eventually allow pointing to the right location, for now it just uses a more meaningful string for the filename.
2012-02-03Implement quasi-quotes in more macro form: #ast{...}.Kevin Atkinson-4/+25
The #(...) form is still supported for now.
2012-02-03Make macro arg optional in syntax, again untested.Kevin Atkinson-1/+15
2012-02-03Add support for recognizing macro body, completely untested.Kevin Atkinson-13/+21
2012-02-03Change the type for the macro body to also store the span.Kevin Atkinson-9/+9
Note: the body is the part of the macro syntax between the {}.
2012-02-03When replacing $(...) with $0 preserve spacing for better error messages.Kevin Atkinson-7/+19
That is: x + $(foo) + y becomes: x + $0 + y not: x + $0 + y
2012-02-03Expand result of quasi-quote.Kevin Atkinson-3/+9
2012-02-03Implement anti-quotes.Kevin Atkinson-8/+77
2012-02-03Implement "replace" function.Kevin Atkinson-1/+23
2012-02-03Implement basic quasi-quoter. No anti-quotes yet.Kevin Atkinson-7/+39
2012-02-03Rename AST builders to use uniform naming scheme. Also add a few more.Kevin Atkinson-46/+68
2012-02-03Add support for parsing quasi-quotes, doesn't do anything useful yet.Kevin Atkinson-1/+12
2012-02-03Move useful ast building functions into their own module.Kevin Atkinson-39/+49
2012-01-31Change option::t to optionTim Chevalier-21/+21
Now that core exports "option" as a synonym for option::t, search-and- replace option::t with option. The only place that still refers to option::t are the modules in libcore that use option, because fixing this requires a new snapshot (forthcoming).
2012-01-31Require alts to be exhaustiveTim Chevalier-5/+8
middle::check_alt does the work. Lots of changes to add default cases into alts that were previously inexhaustive.
2012-01-25Keep source file around after parsing.Kevin Atkinson-1/+1
Specifically box the string (to avoid unnecessary copies) and store it in codemap::filemap. Remove the hack in driver::diagnostic that rereads the source from the file and instead just get the source from the filemap. (This commit is also a prerequisite for issue #1612)
2012-01-23s/block()/fn()/gNiko Matsakis-2/+2
2012-01-23When replacing a pattern variable in macro expansion use the span ofKevin Atkinson-6/+6
the replacement and not the span of the pattern variable. Fixes issue #1448, and #1387.
2012-01-23Allow ast_fold_precursor to change the span.Kevin Atkinson-39/+48
This involved changing the prototype for the callbacks to thread the span though. A wrapper function, fold::wrap, can be used to wrap the old style callbacks.
2012-01-23Change "file" of injected string from "-" to "<anon>", less confusingKevin Atkinson-1/+1
that way.
2012-01-19rustc: ";" to "," in enumsPatrick Walton-9/+9
2012-01-19rustc: "tag" -> "enum"Patrick Walton-3/+3
2012-01-18Remove '.' after nullary tags in patternsTim Chevalier-80/+80
Does what it says on the tin. The next commit will remove support for this syntax.
2012-01-13Change builtin macro defs to use #macro()Graydon Hoare-4/+4
2012-01-13deprecate fn exprs and the fn() type, preferring fn@ and native fnNiko Matsakis-1/+1
2012-01-13Remove all remaining uses of objs from the compilerMarijn Haverbeke-45/+51
2012-01-12Make driver::session::session no longer an objectMarijn Haverbeke-5/+5
Rather, it is now a struct where properties like opts are accessed directly, and the error-reporting methods are part of a static impl (with the same name as the type).
2012-01-11Major clean-up of std::ioMarijn Haverbeke-1/+1
Use ifaces instead of objs, stop wrapping everything in two (or three) layers of no-value-added indirection, and remove some of the more pointless/outdated idioms from the code.
2012-01-11add a log_str() function and allow '%?' in fmt strings to use itNiko Matsakis-0/+2
2012-01-05Switch to new param kind bound syntaxMarijn Haverbeke-1/+1
And remove support for the old syntax