about summary refs log tree commit diff
path: root/src/rustc/syntax/fold.rs
AgeCommit message (Collapse)AuthorLines
2012-03-29rustc: Move fold to rustsyntaxBrian Anderson-772/+0
2012-03-28Allow explicit self-calls within classesTim Chevalier-22/+17
Allow writing self.f() within a class that has a method f. In a future commit, this syntax will be required. For now, you can write either self.f() or f(). I added a "privacy" field to all methods (whether class methods or not), which allowed me to refactor the AST somewhat (getting rid of the class_item type; now there's just class_member).
2012-03-27Support an alternate for syntax that calls a higher-order functionMarijn Haverbeke-0/+1
The last argument of the call must be a block, and the type of this argument must a function returning bool. `break` and `cont` are supported in the body of the block, and return `false` or `true` from the function. When the end of the function is reached, `true` is implicitly returned. for vec::all([1, 2, 3]) {|elt| if elt == 2 { break; } log(error, elt); } Issue #1619
2012-03-26Bulk-edit mutable -> mut.Graydon Hoare-3/+3
2012-03-21add mut decls to rustc and make them mandatoryNiko Matsakis-1/+1
2012-03-20Implement an initial version of placement new.Niko Matsakis-0/+5
2012-03-20rustc: Fix a few more instances of node ID stomping, due to AST folding ↵Patrick Walton-3/+5
incorrectly passing stuff through unchanged
2012-03-20Class methods WIPTim Chevalier-3/+3
In particular, use the ast::method type to represent a class method, and try to reuse as much iface code as possible. (This makes sense now since I'll be allowing polymorphic class methods.)
2012-03-15switch over to using new serialize/deserialize codeNiko Matsakis-14/+12
2012-03-15Make sure resource destructors are properly monomorphizedMarijn Haverbeke-2/+2
2012-03-13get new decorator extensions workingNiko Matsakis-0/+1
2012-03-12rustc: Add node IDs to AST types so we can associate them with region ↵Patrick Walton-1/+1
environments
2012-03-12Revert "rustc: Add node IDs to AST types so we can associate them with ↵Patrick Walton-1/+1
region environments" This reverts commit 96e1bbd4a0abd2c8e76e7e02b396c5319dea7a8d.
2012-03-12rustc: Add node IDs to AST types so we can associate them with region ↵Patrick Walton-1/+1
environments
2012-03-09Add an infinite loop constructTim Chevalier-1/+4
Add a loop {} construct for infinite loops, and use it in test cases. See #1906 for details.
2012-03-08rustc: Change the address-of operator to an explicit production so that we ↵Patrick Walton-0/+1
can parse the mutability
2012-03-08Explicitly store self_ids use for self locals in methodsMarijn Haverbeke-1/+2
This makes it possible to move them between crates without confusion, and to instantiate them at a point where the monomorphizing substitutions are known. Issue #1944
2012-03-08rustc: Add region-annoted type parameters to the AST; stub associated patternsPatrick Walton-0/+1
2012-03-07Fix #1941: inlining of items that themselves contain nested itemsNiko Matsakis-0/+1
The fix is to drop nested items from the encoded AST. Nested items may themselves be inlined, but that is an independent question.
2012-03-04Translate simple classesTim Chevalier-5/+7
Programs using classes with fields only (no methods) compile and run, as long as nothing refers to a class in a different crate (todo). Also changed the AST representation of classes to have a separate record for constructor info (instead of inlining the fields in the item_class node), and fixed up spans and pretty-printing for classes.
2012-03-02Move src/comp to src/rustcGraydon Hoare-0/+761