bors
7b3e036252
auto merge of #6282 : alexcrichton/rust/issue-5517-add-test, r=thestinger
...
It appears the cause of #5517 was fixed in 0dc6c414
, so adding a test so the issue can be closed.
2013-05-07 09:03:42 -07:00
bors
7b2020f2c3
auto merge of #6245 : youknowone/rust/match-range-static, r=graydon
...
Fix unintended error problem of:
````
static s: int = 1;
static e: int = 42;
fn main() {
match 7 {
s..e => (),
^~ error: expected `=>` but found `..`
_ => (),
}
}
````
2013-05-07 00:18:37 -07:00
bors
3225870191
auto merge of #6236 : alexcrichton/rust/more-map-methods, r=thestinger
...
Closes #5392 and #5393
I implemented the pop/swap methods for TrieMap/TreeMap/SmallIntMap, and I also updated all of them such that pop isn't just a remove/insert, but rather it's all done in one operation.
One thing I did notice is that with default methods it'd be really nice to define `insert` and `remove` in terms of `pop` and `swap` (or vice versa, just to have them available).
2013-05-06 23:06:36 -07:00
Alex Crichton
393a409b5d
Add pop() and swap() to the Map trait
2013-05-07 01:16:04 -04:00
bors
d2f0235a2c
auto merge of #6228 : brson/rust/run-destroy, r=brson
...
These cause valgrind errors in subprocesses. I don't *think* these errors
lead to actual test failures but they are very confusing.
2013-05-06 20:12:37 -07:00
Alex Crichton
d0827e3d36
Add a test for issue 5517
2013-05-06 19:17:55 -04:00
Niko Matsakis
2e4790ca06
Merge remote-tracking branch 'mozilla/incoming' into issue-5910-dyna-freeze
2013-05-06 16:10:31 -04:00
Brian Anderson
de8071234f
Move core::run tests of process killing into standalone run-pass tests
...
These cause valgrind errors in subprocesses. I don't *think* these errors
lead to actual test failures but they are very confusing.
2013-05-06 12:50:08 -07:00
bors
a5891bebc1
auto merge of #6265 : sanxiyn/rust/xc-packed, r=nikomatsakis
2013-05-06 11:30:48 -07:00
Seo Sanghyeon
502817a9c1
Fix cross-crate packed structs
2013-05-06 23:35:27 +09:00
Brendan Zabarauskas
0e2242f6d6
Add assert_approx_eq! macro
2013-05-06 21:51:48 +10:00
Brendan Zabarauskas
0211833008
Move FuzzyEq trait into core::cmp and rename it to 'ApproxEq'
2013-05-06 21:51:07 +10:00
Niko Matsakis
7b36e34c89
Fix two more write guard failures
2013-05-05 21:05:37 -04:00
Niko Matsakis
4300d4d2fa
Merge remote-tracking branch 'mozilla/incoming' into issue-5910-dyna-freeze
...
Conflicts:
src/libcore/core.rc
src/libcore/hashmap.rs
src/libcore/num/f32.rs
src/libcore/num/f64.rs
src/libcore/num/float.rs
src/libcore/num/int-template.rs
src/libcore/num/num.rs
src/libcore/num/strconv.rs
src/libcore/num/uint-template.rs
src/libcore/ops.rs
src/libcore/os.rs
src/libcore/prelude.rs
src/libcore/rt/mod.rs
src/libcore/unstable/lang.rs
src/librustc/driver/session.rs
src/librustc/middle/astencode.rs
src/librustc/middle/borrowck/check_loans.rs
src/librustc/middle/borrowck/gather_loans.rs
src/librustc/middle/borrowck/loan.rs
src/librustc/middle/borrowck/preserve.rs
src/librustc/middle/liveness.rs
src/librustc/middle/mem_categorization.rs
src/librustc/middle/region.rs
src/librustc/middle/trans/base.rs
src/librustc/middle/trans/inline.rs
src/librustc/middle/trans/reachable.rs
src/librustc/middle/typeck/check/_match.rs
src/librustc/middle/typeck/check/regionck.rs
src/librustc/util/ppaux.rs
src/libstd/arena.rs
src/libstd/ebml.rs
src/libstd/json.rs
src/libstd/serialize.rs
src/libstd/std.rc
src/libsyntax/ast_map.rs
src/libsyntax/parse/parser.rs
src/test/compile-fail/borrowck-uniq-via-box.rs
src/test/compile-fail/regions-infer-borrow-scope-within-loop.rs
src/test/run-pass/borrowck-nested-calls.rs
2013-05-05 15:11:04 -04:00
Jeong YunWon
cb918e1a83
Allow non-literal static range pattern for match arms
...
Fix unintended error problem of:
static s: int = 1;
static e: int = 42;
fn main() {
match 7 {
s..e => (),
^~ error: expected `=>` but found `..`
_ => (),
}
}
2013-05-05 11:05:06 +09:00
Daniel Micay
86efd97a10
add gitattributes and fix whitespace issues
2013-05-03 20:01:42 -04:00
Niko Matsakis
be08c3e514
rustc: add rooting, write-guards to slices etc
2013-05-03 16:27:16 -04:00
bors
b37a685958
auto merge of #6201 : pcwalton/rust/inhtwama-serializer, r=graydon
...
This PR removes mutable fields from the serializer and makes the encoder and decoder use INHTWAMA properly (i.e. `&mut self`).
r? @graydon
2013-05-02 20:39:36 -07:00
bors
73733c96db
auto merge of #6195 : luqmana/rust/newtype-drop, r=catamorphism
...
Follow up with test case for #6125 .
2013-05-02 18:09:35 -07:00
Patrick Walton
dc5df61bc1
librustc: Update the serializer to work properly with INHTWAMA, removing mutable fields in the process
2013-05-02 17:00:51 -07:00
Graydon Hoare
32ebaacbc6
re-xfail some tests that fail on x86
2013-05-02 14:12:55 -07:00
Luqman Aden
cce97ab8cb
Add test for drop for newtype structs.
2013-05-02 11:33:57 -07:00
Brendan Zabarauskas
e596128bd8
Remove 'Local Variable' comments
2013-05-02 13:22:04 +10:00
Niko Matsakis
3159335ac3
avoid broken += operator, bogus use of const
2013-05-01 11:03:12 -04:00
Niko Matsakis
5ab33a2975
correct incorrect handling of overloaded operators, exposing various other bits of rot
2013-05-01 08:49:48 -04:00
bors
89f419370c
auto merge of #6115 : jbclements/rust/test-case-fixes, r=jbclements
...
In developing the grammar a few weeks ago, I fixed up a bunch of test cases that had rotted to the point that they didn't parse.
2013-04-30 21:12:36 -07:00
John Clements
fc661079a4
fixed up syntax
2013-04-30 16:31:56 -07:00
John Clements
c75b7630bc
renamed issue-2185 to issue-3429
2013-04-30 16:31:55 -07:00
John Clements
89bb02adf9
typestate is not planned for upcoming versions of rust....
2013-04-30 16:31:55 -07:00
John Clements
d1921fb3ca
fixed this test case too
2013-04-30 16:31:55 -07:00
John Clements
3931ce448e
fixed the test case, hope it's still testing something
2013-04-30 16:31:55 -07:00
John Clements
527f7716b7
after syntax fixes, these tests appear to pass
2013-04-30 16:31:55 -07:00
John Clements
3a5361aec9
more commits on issue 2185
2013-04-30 16:31:55 -07:00
John Clements
178305ffec
fixed up issue-2185, but now it has a trait failure
2013-04-30 16:31:55 -07:00
John Clements
d6bb587c12
with syntax fixes, this test case now appears to pass
2013-04-30 16:31:55 -07:00
John Clements
add60bb081
Test now passes
2013-04-30 16:31:54 -07:00
John Clements
7e89a514a5
This test case now parses
...
I've done a slapdash job of fixing up the syntax; it didn't pass before,
and it doesn't pass now, but at least it parses...
2013-04-30 16:31:54 -07:00
John Clements
325263fe22
this test still doesn't pass, but at least it parses...
2013-04-30 16:31:54 -07:00
John Clements
dd310d6c3b
Got test cases to pass, after some major surgery
2013-04-30 16:31:45 -07:00
bors
9329bd669d
auto merge of #6136 : jld/rust/simplifycfg-unrevert, r=thestinger
...
Also add the clearly marked test case that should have been there all along, and un-xfail the not-so-obvious doc test that was affected.
2013-04-30 15:24:36 -07:00
Niko Matsakis
dc21daeeb8
borrowck: fix critical bug prevent us from ever using write guards :)
2013-04-30 16:34:22 -04:00
bors
9d966aef06
auto merge of #6134 : jld/rust/issue-6117, r=catamorphism
...
Cases like `Either<@int,()>` have a null case with at most one value but
a nonzero number of fields; if we misreport this, then bad things can
happen inside of, for example, pattern matching.
Closes #6117 .
2013-04-30 13:30:39 -07:00
bors
9b54fbd40f
auto merge of #6118 : brson/rust/too-much-recursion, r=thestinger
...
I don't understand how this is still passing on the bots. This condition
should trigger an abort now.
2013-04-30 12:12:37 -07:00
Jed Davis
41d06dbd28
Reverse accidental src/llvm reversion in 876483dcf
, and add test.
...
The test is reduced from a doc test, but making it separate ensures that
(1) unrelated changes to the docs won't leave this case uncovered, and
(2) the nature of any future failures will be more obvious to whoever
sees the tree on fire as a result.
2013-04-30 12:05:06 -07:00
Jed Davis
8408012ca4
The null case of a nullable-poiner enum might not be nullary.
...
Cases like `Either<@int,()>` have a null case with at most one value but
a nonzero number of fields; if we misreport this, then bad things can
happen inside of, for example, pattern matching.
Closes #6117 .
2013-04-30 11:36:22 -07:00
John Clements
9455eaf77b
changed to impl trait for type stx
2013-04-30 10:12:05 -07:00
John Clements
77da055345
This test case is obsolete for two reasons
...
First, it refers to a feature (trait bounds on type parameters) that's
apparently no longer in the language. Second, if I understand the issue
correctly, it should never have been a "run-pass" test because it was
supposed to fail.
2013-04-30 10:12:04 -07:00
John Clements
78942a2d16
this issue is a dup of another one that has a correct test case
...
this test case has rotted wrt modern syntax. fortunately, this issue
was a dup of another one, and that one still ICEs.
2013-04-30 10:12:04 -07:00
John Clements
5d8db6fd37
remove (non-parsing) test related to impl d for d feature
2013-04-30 10:12:03 -07:00
John Clements
229ebf0bca
deleted two tests intended to test RUST_CC_ZEAL, an apparently defunct flag for the cycle collector
2013-04-30 10:12:03 -07:00