about summary refs log tree commit diff
path: root/src/comp/syntax/print
AgeCommit message (Collapse)AuthorLines
2012-01-13rustc: Replace the lexer's error handling with diagnostic implBrian Anderson-2/+4
2012-01-13distinguish "any closure" and "stack closure" (block)Niko Matsakis-5/+6
2012-01-13make "native fn" the type for bare functions, remove fn exprsNiko Matsakis-4/+11
2012-01-13deprecate fn exprs and the fn() type, preferring fn@ and native fnNiko Matsakis-6/+6
2012-01-13Obj system? What obj system?Marijn Haverbeke-76/+0
Removes the obj system from the compiler. Closes #1484
2012-01-13Remove all remaining uses of objs from the compilerMarijn Haverbeke-157/+156
2012-01-11Major clean-up of std::ioMarijn Haverbeke-11/+10
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-10rustc: Accept "enum" in addition to "tag"Patrick Walton-2/+2
2012-01-10rename sendfn to fn~, lambda to fn@Niko Matsakis-2/+2
2012-01-09Remove proto_sugar and 'lambda' as keyword, commit to fn@.Graydon Hoare-2/+1
2012-01-09Make the parser accept 'if' as an alternative to 'when' in alt patterns.Austin Seipp-1/+1
Also fix the pretty printer, making it output 'if' instead of 'when'. Issue #1396
2012-01-06Fix pretty-printing of ty params in iface methodsMarijn Haverbeke-3/+5
2012-01-05fix pretty printer to correctly insert parens for disambNiko Matsakis-35/+5
2012-01-05require a non-semi expr acting as a stmt to have unit return typeNiko Matsakis-0/+5
2012-01-05make parser handle parenthesized block-sugar exprs properlyNiko Matsakis-32/+34
2012-01-03Allow tail expressions even in no_value blocks. Type checkerNiko Matsakis-2/+30
will guarantee they have unit type.
2011-12-30add cap clause to pretty printer, with a testNiko Matsakis-2/+34
2011-12-29split proto from fn_decl, as not all fn_decls know the proto.Niko Matsakis-9/+11
this will address the (crashing) new test added.
2011-12-28Change representation of type params to handle interface boundsMarijn Haverbeke-6/+12
Issue #1227
2011-12-23Parse `iface` items and interface references in `impl` items.Marijn Haverbeke-10/+28
The (temporary) syntax is iface seq<T> { fn len() -> uint; fn iter(f: block(T)); } // The 'blah<T>' can be left of to default the name of the // impl to seq<T>. The 'of seq<T>' can be left off when // not implementing a named interface. impl blah<T> of seq<T> for [T] { fn len() -> uint { vec::len(self) } fn iter(f: block(T)) { for x in self { f(x); } } }
2011-12-23Make ast::ty_method hold a fn_decl, rather than duplicating its fieldsMarijn Haverbeke-14/+10
2011-12-22Register new snapshots, purge log_err and log_full in favour of log(...).Graydon Hoare-2/+2
2011-12-22Merge all 3 log syntaxes, tidy up residual misuses.Graydon Hoare-6/+6
2011-12-22Merge branch 'master' of github.com:graydon/rustGraydon Hoare-37/+37
2011-12-22Register snapshots and switch logging over to use of log_full or #error / ↵Graydon Hoare-22/+22
#debug.
2011-12-22Unify some data structures in syntax::ast that were doing the same thingMarijn Haverbeke-37/+37
As a preparation to removing some duplication in typeck.
2011-12-21More flailing on log syntax due to call-expr ambiguity in previous attempt.Graydon Hoare-1/+5
2011-12-21Switch log_expr to carrying a full expr:u32 for level. Add log_full variant ↵Graydon Hoare-6/+13
that parses that expr, prepare for snapshot.
2011-12-21update pprinter to understand ret type of block, add warningsNiko Matsakis-0/+5
2011-12-21Make { || ... } sugar for any type of closure, inferredNiko Matsakis-18/+13
2011-12-19Add type argument field to expr_pathMarijn Haverbeke-1/+6
This way, you can explicitly provide type parameters when calling a generic method. Issue #1227
2011-12-18Only look for a matching method when normal field access failsMarijn Haverbeke-5/+3
We should probalby warn when defining a method foo on {foo: int} etc. This should reduce the amount of useless typevars that are allocated. Issue #1227
2011-12-16Change syntax for implMarijn Haverbeke-9/+6
Move the name of the bundle to the front, allow type parameters (not handled yet), and add a 'for' keyword: impl utils for int { fn str() -> str { int::str(self) } fn times(f: block()) { ... } }
2011-12-16Make uses of self in impls compileMarijn Haverbeke-4/+0
Get rid of expr_self_call, introduces def_self. `self` is now, syntactically, simply a variable. A method implicitly brings a `self` binding into scope. Issue #1227
2011-12-16Parse and resolve implementations.Marijn Haverbeke-0/+16
Issue #1227
2011-12-14change syntax from lambda[send] to sendfnNiko Matsakis-1/+1
2011-12-14push changes through to get things compiling, if not running.Niko Matsakis-0/+1
2011-12-14first attempt, not happy with itNiko Matsakis-1/+1
2011-12-13Copy first batch of material from libstd to libcore.Graydon Hoare-2/+4
2011-12-08Allow binding of nested patternsMarijn Haverbeke-1/+7
See src/test/run-pass/nested-patterns.rs for some examples. The syntax is boundvar@subpattern Which will match the subpattern as usual, but also bind boundvar to the whole matched value. Closes #838
2011-12-07Change literal representation to not truncateMarijn Haverbeke-22/+19
Also shuffles around the organization of numeric literals and types, separating by int/uint/float instead of machine-vs-non-machine types. This simplifies some code. Closes #974 Closes #1252
2011-12-02Allow literal patterns to contain arbitrary literal expressionsMarijn Haverbeke-3/+3
This removes the need for the unary minus hacks, and allows some other neat things like matching on 1 >> 4. Issue #954
2011-11-30Box ast::path valuesMarijn Haverbeke-9/+9
It seems inefficient to copy them around. Let's measure whether that's actually > the case
2011-11-23Add some changes that *should* have been in e98286b594Marijn Haverbeke-0/+1
Forgot to amend the commit after fixing the failure.
2011-11-23Rollback return-by-referenceMarijn Haverbeke-21/+2
It's proving too inflexible, so I'm ripping out the extra complexity in the hope that regions will, at some point, provide something similar. Closes #918
2011-11-22rustc: Allow trailing comma in record fieldsHaitao Li-2/+2
2011-11-18Update stdlib, compiler, and tests to new kind systemMarijn Haverbeke-5/+4
This involved adding 'copy' to more generics than I hoped, but an experiment with making it implicit showed that that way lies madness -- unless enforced, you will not remember to mark functions that don't copy as not requiring copyable kind. Issue #1177
2011-11-18Add a pass-by-copy parameter passing conventionMarijn Haverbeke-1/+2
This is intended to solve the problem of how to pass arguments to constructor functions -- you want to move in rvalues, but not have to explicitly copy stuff that is not an rvalue. The by-copy passing convention will ensure the callee gets its own copy of the value. For rvalues, it'll just pass off the value. For lvalues, it'll make a copy. Issue #1177
2011-11-18Preparation for kind system overhaulMarijn Haverbeke-3/+3
This goes before a snapshot, so that subsequenct patches can make the transition without breaking the build. Disables kind checking pass, makes parser accept both new and old-style kind annotation. Issue #1177
2011-11-17remove compile-command from local variable blocksNiko Matsakis-2/+0