Eduard Burtescu
da7dcee8f1
tests: remove old compile-fail test asserting the removal of const
.
2014-10-03 14:26:07 +03:00
Brian Koropoff
521ca31071
Add some more test coverage of by-ref unboxed closures
2014-10-03 00:57:21 -07:00
P1start
a667a6917b
Move the lint for the stability lints to the method name only
...
Closes #17337 .
2014-10-03 20:39:57 +13:00
P1start
f56c67ba86
Change rustc pretty-printing to print [T, ..n] instead of [T, .. n]
2014-10-03 20:39:56 +13:00
P1start
042cdeefc7
Correct error message for invalid ref
/mut
bindings
...
Closes #15914 .
2014-10-03 20:39:56 +13:00
P1start
45044124e4
Improve the non_snake_case
lint to give better suggestions
2014-10-03 20:39:56 +13:00
P1start
94bcd3539c
Set the non_uppercase_statics
lint to warn by default
2014-10-03 20:39:56 +13:00
Alex Crichton
7e22af3582
syntax: Enable parsing of const
globals
...
This rewrites them to the current `ItemStatic` production of the compiler, but I
want to get this into a snapshot. It will be illegal to use a `static` in a
pattern of a `match` statement, so all those current uses will need to be
rewritten to `const` once it's implemented. This requires that the stage0
snapshot is able to parse `const`.
cc #17718
2014-10-02 19:37:06 -07:00
Alex Crichton
7ae802f57b
rollup merge of #17666 : eddyb/take-garbage-out
...
Conflicts:
src/libcollections/lib.rs
src/libcore/lib.rs
src/librustdoc/lib.rs
src/librustrt/lib.rs
src/libserialize/lib.rs
src/libstd/lib.rs
src/test/run-pass/issue-8898.rs
2014-10-02 14:53:18 -07:00
Alex Crichton
fba72d3825
rollup merge of #17721 : jakub-/resolved-issues
2014-10-02 14:51:05 -07:00
Alex Crichton
d596aa25e1
rollup merge of #17702 : nick29581/enable-dots-test
2014-10-02 14:50:30 -07:00
Alex Crichton
51820b610e
rollup merge of #17646 : bkoropoff/cast-ice
2014-10-02 14:50:08 -07:00
Jakub Wieczorek
52d2f2a938
Add tests for a few resolved issues
2014-10-02 22:21:50 +02:00
Aaron Turon
d2ea0315e0
Revert "Use slice syntax instead of slice_to, etc."
...
This reverts commit 40b9f5ded50ac4ce8c9323921ec556ad611af6b7.
2014-10-02 11:48:07 -07:00
Aaron Turon
7bf56df4c8
Revert "Put slicing syntax behind a feature gate."
...
This reverts commit 95cfc35607ccf5f02f02de56a35a9ef50fa23a82.
2014-10-02 11:47:51 -07:00
Eduard Burtescu
58bea31ca0
tests: remove uses of Gc.
2014-10-02 17:02:15 +03:00
bors
84a4a07bbd
auto merge of #17434 : P1start/rust/borrowck-messages, r=nikomatsakis
...
This was originally part of #17215 .
Closes #15506 .
Closes #15630 .
Closes #17263 .
This also partially implements #15838 .
2014-10-02 11:32:25 +00:00
Nick Cameron
45fd7cd359
Enable a test for .. in range patterns.
2014-10-02 17:35:20 +13:00
P1start
02c6ebde7e
Change the use of moved value
error to be more accurate
...
Previously it output `partially moved` to eagerly. This updates it to be more
accurate and output `collaterally moved` for use of values that were invalidated
by moves out of different fields in the same struct.
Closes #15630 .
2014-10-02 15:51:05 +13:00
Nick Cameron
95cfc35607
Put slicing syntax behind a feature gate.
...
[breaking-change]
If you are using slicing syntax you will need to add #![feature(slicing_syntax)] to your crate.
2014-10-02 13:23:36 +13:00
Nick Cameron
40b9f5ded5
Use slice syntax instead of slice_to, etc.
2014-10-02 13:19:45 +13:00
P1start
35ff2def5d
Clarify some borrowck errors
...
Closes #17263 .
2014-10-02 11:21:59 +13:00
P1start
a8577be6f4
Output a note when lifetimes cannot be elided from functions
2014-10-02 11:09:29 +13:00
Florian Hahn
49e976d771
Limit recursion depth for macro expansions, closes #17628
2014-10-01 11:46:04 +02:00
bors
2f15dcd4d3
auto merge of #17584 : pcwalton/rust/range-patterns-dotdotdot, r=nick29581
...
This breaks code that looks like:
match foo {
1..3 => { ... }
}
Instead, write:
match foo {
1...3 => { ... }
}
Closes #17295 .
r? @nick29581
2014-10-01 03:17:24 +00:00
Brian Koropoff
93408be788
Add regression test for issue #17444
2014-09-30 20:07:09 -07:00
Kevin Ballard
8a60952100
Move if let
behind a feature gate
2014-09-30 18:54:03 +02:00
Kevin Ballard
976438f78f
Produce a better error for irrefutable if let
patterns
...
Modify ast::ExprMatch to include a new value of type ast::MatchSource,
making it easy to tell whether the match was written literally or
produced via desugaring. This allows us to customize error messages
appropriately.
2014-09-30 18:54:02 +02:00
Patrick Walton
416144b827
librustc: Forbid ..
in range patterns.
...
This breaks code that looks like:
match foo {
1..3 => { ... }
}
Instead, write:
match foo {
1...3 => { ... }
}
Closes #17295 .
[breaking-change]
2014-09-30 09:11:26 -07:00
Nick Cameron
1c36d1c71d
Emit an error rather than ICEing for a missing built-in bound lang item.
...
closes #17392
2014-09-30 11:30:08 +13:00
Alex Crichton
d3e171861f
Test fixes from the rollup
2014-09-29 10:13:31 -07:00
Alex Crichton
915511ec6d
rollup merge of #17614 : nick29581/slice3
2014-09-29 08:14:39 -07:00
Alex Crichton
29216b5e5c
rollup merge of #17613 : bkoropoff/issue-17593
2014-09-29 08:14:36 -07:00
Alex Crichton
0358f31127
rollup merge of #17598 : bkoropoff/issue-17441
2014-09-29 08:14:27 -07:00
Alex Crichton
7784a8d397
rollup merge of #17592 : kmcallister/inline-asm-loc
2014-09-29 08:14:23 -07:00
Alex Crichton
b7c002aac1
rollup merge of #17586 : Sawyer47/test-16465
2014-09-29 08:14:19 -07:00
Alex Crichton
655b7269c8
rollup merge of #17519 : pcwalton/unboxed-closure-move-syntax
2014-09-29 08:10:44 -07:00
bors
b9478ee251
auto merge of #17321 : apoelstra/rust/error-on-unknown-impl, r=alexcrichton
...
Followup to RFC 57.
Fixes #7607
Fixes #8767
Fixes #12729
Fixes #15060
2014-09-29 05:13:08 +00:00
Brian Koropoff
69d570fbec
Add regression test for issue #17441
2014-09-28 17:57:35 -07:00
Nick Cameron
2c589df6a2
Test for ..
in range patterns
2014-09-29 11:45:20 +13:00
Brian Koropoff
cab84be812
Correctly populate trait impl map when checking for impl overlaps
...
Also fix an existing compile-fail test which was intended to cover
this case.
This closes issue #17593
2014-09-28 14:28:48 -07:00
Andrew Poelstra
bb5807919a
Cleanup error messages for anonymous impl for types not declared in the current module
...
Followup to RFC 57.
Fixes #7607
Fixes #8767
Fixes #12729
Fixes #15060
2014-09-28 12:58:10 -05:00
bors
7eb9337dac
auto merge of #17527 : sfackler/rust/cfg-syntax, r=alexcrichton
...
We'll need a snapshot before we can convert the codebase over and turn on the deprecation warnings.
cc #17490
This is sitting on top of #17506
2014-09-28 08:57:57 +00:00
Steven Fackler
9519abecfb
Convert cfg syntax to new system
...
This removes the ability to use `foo(bar)` style cfgs. Switch them to
`foo_bar` or `foo="bar"` instead.
[breaking-change]
2014-09-27 22:59:26 -07:00
bors
9a68da7401
auto merge of #17517 : pczarn/rust/hashmap-lifetimes, r=alexcrichton
...
Fixes #17500
2014-09-27 18:57:46 +00:00
Keegan McAllister
9d60de93e2
Translate inline assembly errors back to source locations
...
Fixes #17552 .
2014-09-27 11:10:37 -07:00
Piotr Jawniak
b39921c49e
Add test for #16465
...
Closes #16465
2014-09-27 09:17:04 +02:00
Patrick Walton
2257e231a7
librustc: Eliminate the ref
syntax for unboxed closure capture clauses
...
in favor of `move`.
This breaks code that used `move` as an identifier, because it is now a
keyword. Change such identifiers to not use the keyword `move`.
Additionally, this breaks code that was counting on by-value or
by-reference capture semantics for unboxed closures (behind the feature
gate). Change `ref |:|` to `|:|` and `|:|` to `move |:|`.
Part of RFC #63 ; part of issue #12831 .
[breaking-change]
2014-09-26 09:03:19 -07:00
Niko Matsakis
3694f42b8c
Move checking of whether fields are Sized or not into wf / trait code.
2014-09-25 07:09:13 -04:00
Niko Matsakis
2ec305d1bc
Move checks for closure bounds out of kind.rs
2014-09-25 07:09:08 -04:00