summary refs log tree commit diff
path: root/src/test/run-pass
AgeCommit message (Collapse)AuthorLines
2012-03-28test: Un-XFAIL regions-mock-trans.rs and regions-mock-trans-impls.rsPatrick Walton-4/+0
2012-03-28rustc: Universally quantify regions when calling functions. Un-XFAIL ↵Patrick Walton-2/+0
regions-addr-of-ret.rs.
2012-03-28Allow references to "self" within classesTim Chevalier-1/+1
Allow writing self.f within a class that has a field f. Currently, the compiler accepts either self.f or f. In a future commit I'll require writing self.f and not f. Not sure whether self.f() works if f is a method (making sure that works next).
2012-03-27Enforce mutability declarations in classes; correct shapes for classesTim Chevalier-4/+17
1. Enforce mutability declarations on class fields. Don't allow any mutation of class fields not declared as mutable (except inside the constructor). 2. Handle classes correctly in shape (treat classes like records).
2012-03-27Support returning from loop blocksMarijn Haverbeke-0/+57
The code is somewhat invasive, but it seems hard to do this in a clean way, since the design itself involves a bunch of 'action at a distance'. Issue #1819
2012-03-26Bulk-edit mutable -> mut.Graydon Hoare-93/+93
2012-03-26rustc: Begin eliminating ext's dependency on the sessionBrian Anderson-8/+6
2012-03-26Enforce privacy declarations for class fields and methodsTim Chevalier-0/+34
2012-03-26Disallow ret inside of block functionsMarijn Haverbeke-1/+1
Also adds proper checking for cont/break being inside a loop. Closes #1854 Issue #1619
2012-03-24add test that was failing from tedhNiko Matsakis-0/+11
2012-03-24Avoid unifying vars when possible; handle bot (more) correctlyNiko Matsakis-7/+7
2012-03-24test: Rename run-pass/simple-regions.rs to run-pass/regions-simple.rsPatrick Walton-0/+0
This groups all the region tests under regions-*.
2012-03-23Allow methods to call other methods in the same classTim Chevalier-4/+25
2012-03-23Add another test for cross-crate method callsTim Chevalier-0/+13
2012-03-23xfail-test regions testsNiko Matsakis-0/+6
2012-03-23Handle self correctly when translating classesTim Chevalier-1/+0
This change uses the same code for handling the "self" reference for classes as is already used for impls/ifaces. This allows removing the extra maybe_self_id argument (which was just for classes) to trans_closure that I added before. I also rewrote the translation for class ctors so that it doesn't generate new AST nodes (instead translating directly). Also changed visit so that it visits class ctors correctly with visit_fn, and changed typestate to not do return-checking when visiting a class ctor.
2012-03-23test: Add a test case that ensures `ret &EXPR` works.Patrick Walton-0/+8
2012-03-23test: Fix unresolved name in regions-mock-trans-impls.rsPatrick Walton-1/+1
2012-03-23test: Add a version of the "mock-trans" regions test case that uses implsPatrick Walton-0/+46
2012-03-23test: Fix leak in regions-mock-transPatrick Walton-1/+4
2012-03-23test: Fix whitespace at EOLPatrick Walton-1/+1
2012-03-23test: Add a trans.rs-workalike test case for regionsPatrick Walton-0/+41
2012-03-23rustc: Redo region inference to be a bit less brokenPatrick Walton-0/+1
2012-03-23Keep an explicit map of things that have to be spilledMarijn Haverbeke-0/+6
This prevents us from spilling locals more than once. Closes #2040
2012-03-23Replace most uses of intrinsics in core with builtinsMarijn Haverbeke-29/+0
Issue #1981
2012-03-22Make cross-crate calls to class methods workTim Chevalier-3/+2
2012-03-22rt: Run resource destructors during cycle collectionBrian Anderson-0/+69
2012-03-22make --enforce-mut-vars always on, add mut annotations to remaining filesNiko Matsakis-202/+213
2012-03-21methods workTim Chevalier-6/+35
Cross-crate method calls don't work yet. Added run-pass/class-method-cross-crate to test that, but it's xfailed References to fields within methods don't work yet. Added run-pass/class-methods to test that, but it's also xfailed
2012-03-21add test for commit 9502fb99e0d535c8ced17ac61e63ebbd67b7dba7Niko Matsakis-0/+22
2012-03-21Adjust arena definition to be compatible with placement newNiko Matsakis-0/+9
2012-03-20Implement an initial version of placement new.Niko Matsakis-2/+23
2012-03-20Conditionalize test to only run double/byte/double test on x64 for now.Graydon Hoare-6/+13
2012-03-20Xfail struct-return test. x64 ABI is not quite right yet.Graydon Hoare-0/+1
2012-03-20Class methods WIPTim Chevalier-1/+7
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-20Some tests for passing and returning structures by value on x64. Close ↵Graydon Hoare-0/+39
#1402. Close #1970.
2012-03-20core: Rename unsafe::leak to unsafe::forget. Closes #2031Brian Anderson-1/+1
2012-03-16Encode both private and public class fields in metadataTim Chevalier-3/+0
This is necessary to calculate the correct offsets for field references. Simple cross-crate class tests (still with fields only) now pass.
2012-03-16rustc: Unify impl self types in the opposite order so variance is correctBrian Anderson-0/+12
2012-03-16Classes WIPTim Chevalier-0/+31
Cross-crate metadata for classes works well enough that programs with classes in other crates compile successfully, but output wrong results. Checking in work so far to avoid merge hassles. (Tests are xfailed.)
2012-03-16allow binding of fn~, make result fn@. fixes 1899.Niko Matsakis-0/+4
2012-03-15test: Add a test case for self regions and typeclass implementationsPatrick Walton-0/+11
2012-03-14core:: Eliminate str::sbuf. Replace with *u8Brian Anderson-2/+2
2012-03-14std: Rename the hashmap constructors to conform to new standardsBrian Anderson-4/+4
Instead of using the new_ prefix just name them after their type
2012-03-14fixup auto_serialize's treatment of nullary variantsNiko Matsakis-0/+15
2012-03-14test: Remove unsafe from the region testsPatrick Walton-14/+10
2012-03-14test: Add a test case for the "self" region in enumsPatrick Walton-0/+16
2012-03-14fix auto_serialize for enums with type parametersNiko Matsakis-0/+21
2012-03-14adjust auto_serialize to generate fns named serialize_T()Niko Matsakis-15/+16
We used to generate a module T with a serialize() and deserialize() fn, but this was suboptimal for a number of reasons: - it required moving serialization into core so that uint etc worked - it was harder to override the serialization behavior locally (this is now trivial)
2012-03-13merge all auto_serialize tests into oneNiko Matsakis-119/+98