summary refs log tree commit diff
path: root/src/comp
AgeCommit message (Collapse)AuthorLines
2012-01-19Handle predicates that recurse in a check() expressionTim Chevalier-9/+10
typestate was using the enclosing function ID for the "this function returns" constraint, which meant confusion and panic in the case where a predicate p includes "check p()". Fixed it to use a fresh ID. Closes #933
2012-01-19Additional ; to , changes, disable "tag" and ";" in parser. Close #1430. ↵Graydon Hoare-6/+6
Close #1428.
2012-01-19rustc: Stop parsing "tag"Patrick Walton-2/+2
2012-01-19rustc: Make the pretty printer output commas after enum variants. Update all ↵Patrick Walton-1/+1
tests accordingly.
2012-01-19rustc: Fix fun_to_strBrian Anderson-0/+14
2012-01-19rustc: ";" to "," in enumsPatrick Walton-450/+450
2012-01-19rustc: Remove trailing whitespacePatrick Walton-1/+1
2012-01-19Compute typestates for FRU exprs correctly, plus a bit of cleanupTim Chevalier-50/+36
The code in Issue 948 was causing typestate to diverge because it was using the prestate for the whole expression -- not the post- state for the fields list -- as the prestate for the record base expression. Fixed. Closes #948
2012-01-19Handle log expressions with a _|_-typed levelTim Chevalier-0/+6
If we have log(foo, quux) where foo:_|_, just translate foo and ignore the rest of the expression. Closes #1459
2012-01-19rustc: Fix long linesPatrick Walton-5/+6
2012-01-19rustc: "tag" -> "enum"Patrick Walton-183/+183
2012-01-19Use fn~ to simplify the core::test interfaceBrian Anderson-10/+1
2012-01-19In trans, allow _|_-typed things to be the argument to failTim Chevalier-1/+1
Rationale: _|_-typed things diverge, so it's safe to use them in any context. Closes #1465
2012-01-19Partial fix for #1561, doesn't actually "fix" the problem but you get output ↵Graydon Hoare-3/+3
now. There's still something wrong with #error here, possibly cross-crate issue.
2012-01-19Rename fn*() to fn() as originally planned.Niko Matsakis-8/+10
2012-01-19treat fn*() as fn&()Niko Matsakis-11/+5
This is not my ideal way of going about things. I'd prefer not to have expressions typed as fn*(), for example, but I couldn't get that to work together with inferring the modes of arguments and other corner cases.
2012-01-19rustc: Refactor lint check and avoid a segv faultHaitao Li-23/+16
The segv fault issue is #1566
2012-01-19rustc: Name the lint-style check module `lint`Haitao Li-69/+89
Issue #1543
2012-01-19rustc: Add a usage pass to collect one-off analysesHaitao Li-30/+70
This patch starts from move the analysis which checkes of probably incorrectly usage of `int|uint` in native fn. Issue #1543
2012-01-19rustc: Use io::println for time-passes dataHaitao Li-2/+2
Issue #1561
2012-01-19Remove support for the '.' after a nullary tag in a patternTim Chevalier-95/+90
(Commit also includes lots of changes to remove '.'s that a git merge messed up, or else it was monkeys.)
2012-01-18Remove '.' after nullary tags in patternsTim Chevalier-1214/+1214
Does what it says on the tin. The next commit will remove support for this syntax.
2012-01-18Allow any alternative (not just a block) to follow a nullary tag patternTim Chevalier-3/+1
2012-01-18allow dotless nullary patterns inside or-patternsTim Chevalier-1/+2
2012-01-18Another minor parser fix for nullary-tag patternsTim Chevalier-1/+1
2012-01-18Allow nullary tag names to be qualifiedTim Chevalier-3/+2
2012-01-18rustc: Assert that the parser doesn't assign node id 0Brian Anderson-0/+2
It is reserved for indicating the crate, but doesn't exist in the AST
2012-01-18Fix --out-dir a bit more in driver.Graydon Hoare-3/+5
2012-01-18remove align_mode and rewrite GEP_tup_like to align correctlyNiko Matsakis-97/+64
Although the old version of GEP_tup_like was incorrect in some cases, I do not believe we ever used it in an incorrect fashion. In particular, it could go wrong with extended index sequences like [0, 1, 3], but as near as I can tell we only ever use it with short sequences like [0, i].
2012-01-18correct use of GEP_tup_like in closure constrNiko Matsakis-28/+36
also, streamline type_is_tup_like() to the cases which actually work
2012-01-18rustc: Accept commas to separate tag variantsPatrick Walton-3/+12
2012-01-19rustc: Use integer from ctypes consistentlyHaitao Li-47/+54
2012-01-19Use ctypes in native function declarationsHaitao Li-207/+234
2012-01-19rustc: Warn when int or uint is used in a native type declHaitao Li-0/+29
Issue #1403
2012-01-17use 64-bit memset on 64-bit platforms. Fixes #1546. Fixes #843.Niko Matsakis-22/+12
Actually, we don't "fix" #843 so much as close it: as with memmove, we simply use an alignment of 1 with dynamically sized types.
2012-01-17roll back commit 1c7a62Niko Matsakis-18/+16
2012-01-17rustc: Allow std to be built as a test runnerBrian Anderson-3/+16
2012-01-17Rename some readmes and fix some dist logic.Graydon Hoare-0/+0
2012-01-17Update crates with correct crate_type attributeBrian Anderson-1/+1
2012-01-17rustc: --test overrides the crate_type attributeBrian Anderson-13/+30
2012-01-17Merge pull request #1544 from kevina/issue-1393Graydon Hoare-4/+4
Minor cleanups to custom discriminator code.
2012-01-17encode variant names and have log print them out.Niko Matsakis-5/+20
2012-01-17Allow omission of the '.' after nullary tag patternsTim Chevalier-182/+387
This commit allows patterns like: alt x { some(_) { ... } none { } } without the '.' after none. The parser suspends judgment about whether a bare ident is a tag or a new bound variable; instead, the resolver disambiguates. This means that any code after resolution that pattern-matches on patterns needs to call pat_util::normalize_pat, which consults an environment to do this disambiguation. In addition, local variables are no longer allowed to shadow tag names, so this required changing some code (e.g. renaming variables named "mut", and renaming ast::sub to subtract). The parser currently accepts patterns with and without the '.'. Once the compiler and libraries are changed, it will no longer accept the '.'.
2012-01-17Fail slightly more gracefully when given an -o filename that doesn't have an ↵Tim Chevalier-1/+4
extension
2012-01-17Prevent pretty-printer from trying to consume stdin twiceMarijn Haverbeke-15/+15
Why this didn't fail on my machine, I don't know.
2012-01-17Try to fix pretty-printer failureMarijn Haverbeke-9/+8
I can't reproduce it on my side, unfortunately.
2012-01-17Fix --pretty normal, reorganize some code in driver.rsMarijn Haverbeke-48/+63
There is now only one path doing crate expanding and typechecking, which should make it less likely for the pretty-printing code to be broken by changes to the compilation pipeline. Closes #1536
2012-01-17Use a memset upcall to zero things without static alignmentMarijn Haverbeke-16/+18
This fixes issues #843 and #1546. The cost of an upcall is unfortunate, though. I assume there must be a way to simply manually compute the pointer or size, using something akin to the formula in `align_to` in `rust_util.h`. I could not get this to work, unfortunately.
2012-01-16rustc: Move some attribute accessors from rustdoc to rustcBrian Anderson-0/+50
2012-01-16Minor cleanups to custom discriminator code.Kevin Atkinson-4/+4
Mostly updates to the comments and docs from Pull Request #1537.