Ms2ger
7aa2735393
Remove unnecessary to_string() call.
2015-01-28 09:42:16 +01:00
Ms2ger
4ad677e5b6
Remove a custom variant of iter::Cloned.
2015-01-28 09:42:16 +01:00
Ms2ger
f88c94d8d2
Simplify the implementation of segments_name_eq.
2015-01-28 09:39:28 +01:00
bors
06410ef9fb
Auto merge of #21158 - alkor:issue-21131, r=nick29581
...
Closes #21131
2015-01-28 07:32:53 +00:00
Jorge Aparicio
57dd4ea78d
fix #[cfg(test)] warnings
2015-01-27 22:58:45 -05:00
Brian Anderson
7122305053
Merge remote-tracking branch 'rust-lang/master'
...
Conflicts:
src/libcore/cell.rs
src/librustc_driver/test.rs
src/libstd/old_io/net/tcp.rs
src/libstd/old_io/process.rs
2015-01-27 15:05:04 -08:00
Brian Anderson
abc56a011a
Make '-A warnings' apply to all warnings, including feature gate warnings
2015-01-26 16:29:27 -08:00
Alex Crichton
5d836cdf86
std: Rename Writer::write to Writer::write_all
...
In preparation for upcoming changes to the `Writer` trait (soon to be called
`Write`) this commit renames the current `write` method to `write_all` to match
the semantics of the upcoming `write_all` method. The `write` method will be
repurposed to return a `usize` indicating how much data was written which
differs from the current `write` semantics. In order to head off as much
unintended breakage as possible, the method is being deprecated now in favor of
a new name.
[breaking-change]
2015-01-26 16:01:58 -08:00
Alex Crichton
3a07f859b8
Fallout of io => old_io
2015-01-26 16:01:16 -08:00
Brian Anderson
5a6fb8eb98
Merge remote-tracking branch 'rust-lang/master'
...
Conflicts:
src/librustc/lint/builtin.rs
src/librustc/lint/context.rs
2015-01-26 15:42:32 -08:00
bors
8ec3a833d5
Auto merge of #21617 - alexcrichton:less-quotes, r=nikomatsakis
...
This ends up propagating all the way out to the output of dep-info which then
makes Cargo think that files are not existent (it thinks the files have quotes
in their name) when they in fact do.
2015-01-26 19:44:12 +00:00
bors
16286f5cf9
Auto merge of #21614 - kvark:typedef, r=huonw
...
Fixes #21497
I don't know if this can be tested with built-in tests.
2015-01-26 15:39:13 +00:00
Oliver Schneider
82b0b0fcc7
fallout
2015-01-26 16:27:28 +01:00
bors
7615e187c6
Auto merge of #21605 - huonw:omg-muscle-memory, r=eddyb
...
I'm beginning to suspect it's impossible to avoid accidentally writing
`#[deriving]` at least once in every program, and it results in
non-intuitive error messages: "Foo doesn't have any method in scope
`clone`" despite there being a `#[deriv...(Clone)]` attribute!
Also, lots of documentation around the internet uses `#[deriving]` so
providing this guidance is very helpful (lots of people ask in #rust
about this error).
2015-01-26 07:49:01 +00:00
Brian Anderson
d179ba3b8e
Merge remote-tracking branch 'rust-lang/master'
...
Conflicts:
src/libcore/cmp.rs
src/libcore/fmt/mod.rs
src/libcore/iter.rs
src/libcore/marker.rs
src/libcore/num/f32.rs
src/libcore/num/f64.rs
src/libcore/result.rs
src/libcore/str/mod.rs
src/librustc/lint/builtin.rs
src/librustc/lint/context.rs
src/libstd/sync/mpsc/mod.rs
src/libstd/sync/poison.rs
2015-01-25 22:14:06 -08:00
Eduard Burtescu
9690be5ece
Adjust most comments and messages to not use "unboxed".
2015-01-26 04:15:09 +02:00
Eduard Burtescu
e0afa82c67
Remove every mention of "onceness".
2015-01-26 04:15:09 +02:00
Eduard Burtescu
50a370aa2d
Remove dead code related to old closures.
2015-01-26 04:15:09 +02:00
Eduard Burtescu
11ef6f1349
Remove "unboxed" attribute in code referring to new closures.
2015-01-26 04:15:09 +02:00
bors
102ab57d80
Auto merge of #21582 - FlaPer87:rollup, r=brson
...
- Successful merges: #21108 , #21445 , #21498 , #21504 , #21532 , #21535 , #21539 , #21540 , #21541 , #21550 , #21560 , #21573 , #21579
- Failed merges:
2015-01-25 13:33:18 +00:00
Brian Anderson
63fcbcf3ce
Merge remote-tracking branch 'rust-lang/master'
...
Conflicts:
mk/tests.mk
src/liballoc/arc.rs
src/liballoc/boxed.rs
src/liballoc/rc.rs
src/libcollections/bit.rs
src/libcollections/btree/map.rs
src/libcollections/btree/set.rs
src/libcollections/dlist.rs
src/libcollections/ring_buf.rs
src/libcollections/slice.rs
src/libcollections/str.rs
src/libcollections/string.rs
src/libcollections/vec.rs
src/libcollections/vec_map.rs
src/libcore/any.rs
src/libcore/array.rs
src/libcore/borrow.rs
src/libcore/error.rs
src/libcore/fmt/mod.rs
src/libcore/iter.rs
src/libcore/marker.rs
src/libcore/ops.rs
src/libcore/result.rs
src/libcore/slice.rs
src/libcore/str/mod.rs
src/libregex/lib.rs
src/libregex/re.rs
src/librustc/lint/builtin.rs
src/libstd/collections/hash/map.rs
src/libstd/collections/hash/set.rs
src/libstd/sync/mpsc/mod.rs
src/libstd/sync/mutex.rs
src/libstd/sync/poison.rs
src/libstd/sync/rwlock.rs
src/libsyntax/feature_gate.rs
src/libsyntax/test.rs
2015-01-25 01:20:55 -08:00
Alex Crichton
0dac568578
syntax: Don't put quotes around filenames in codemap
...
This ends up propagating all the way out to the output of dep-info which then
makes Cargo think that files are not existent (it thinks the files have quotes
in their name) when they in fact do.
2015-01-24 22:43:11 -08:00
Dzmitry Malyshau
e5632157b1
Associated types support for deriving::generic::TraitDef
2015-01-25 00:54:30 -05:00
Huon Wilson
ae4e1a190b
Tell the compiler to tell us that deriving
is dead.
...
I'm beginning to suspect it's impossible to avoid accidentally writing
`#[deriving]` at least once in every program, and it results in
non-intuitive error messages: "Foo doesn't have any method in scope
`clone`" despite there being a `#[deriv...(Clone)]` attribute!
Also, lots of documentation around the internet uses `#[deriving]` so
providing this guidance is very helpful (lots of people ask in #rust
about this error).
Fixes #21166 .
2015-01-25 10:44:56 +11:00
bors
76fbb35831
Auto merge of #21079 - huonw:chained-cmp-tweaks, r=pnkfelix
...
First commit is mindless groundwork for the second one, to make the spans (arguably) nicer.
### before
```
require-parens-for-chained-comparison.rs:14:20: 14:22 error: Chained comparison operators require parentheses
require-parens-for-chained-comparison.rs:14 false == false == false;
^~
require-parens-for-chained-comparison.rs:17:16: 17:17 error: Chained comparison operators require parentheses
require-parens-for-chained-comparison.rs:17 false == 0 < 2;
^
require-parens-for-chained-comparison.rs:20:8: 20:9 error: Chained comparison operators require parentheses
require-parens-for-chained-comparison.rs:20 f<X>();
^
require-parens-for-chained-comparison.rs:20:8: 20:9 help: Use ::< instead of < if you meant to specify type arguments.
require-parens-for-chained-comparison.rs:20 f<X>();
^
```
### after
```
require-parens-for-chained-comparison.rs:14:11: 14:22 error: chained comparison operators require parentheses
require-parens-for-chained-comparison.rs:14 false == false == false;
^~~~~~~~~~~
require-parens-for-chained-comparison.rs:17:11: 17:17 error: chained comparison operators require parentheses
require-parens-for-chained-comparison.rs:17 false == 0 < 2;
^~~~~~
require-parens-for-chained-comparison.rs:20:6: 20:9 error: chained comparison operators require parentheses
require-parens-for-chained-comparison.rs:20 f<X>();
^~~
require-parens-for-chained-comparison.rs:20:6: 20:9 help: use `::<...>` instead of `<...>` if you meant to specify type arguments
require-parens-for-chained-comparison.rs:20 f<X>();
^~~
```
2015-01-24 17:07:43 +00:00
Huon Wilson
ec790d6fcc
Tweak chained comparison errors.
...
Lower case and give a more precise span: from operator to operator, not
just the last one.
2015-01-25 00:35:06 +11:00
Huon Wilson
2e888d0341
Add the span of the operator itself to ast::BinOp.
2015-01-25 00:33:50 +11:00
bors
0430a43d63
Auto merge of #21542 - vadimcn:fix-exported-macro-paths, r=alexcrichton
...
... so that `super::foo` gets serialized as `super:: foo`, rather than `super :: foo`.
2015-01-24 13:04:39 +00:00
Flavio Percoco Premoli
82299c07de
Rollup merge of #21504 - blackbeam:has_test_signature_fix, r=alexcrichton
...
Fix for `error: functions used as tests must have signature fn() -> ()` and `error: functions used as benches must have signature `fn(&mut Bencher) -> ()` in case of explicit return type declaration.
2015-01-24 10:42:40 +01:00
Vadim Chugunov
f09c680b4c
Fix tidy.
2015-01-23 18:32:00 -08:00
Brian Anderson
9758c488a9
Deprecated attributes don't take 'feature' names and are paired with stable/unstable
...
Conflicts:
src/libcore/atomic.rs
src/libcore/finally.rs
src/test/auxiliary/inherited_stability.rs
src/test/auxiliary/lint_stability.rs
2015-01-23 15:50:03 -08:00
Brian Anderson
cd6d9eab5d
Set unstable feature names appropriately
...
* `core` - for the core crate
* `hash` - hashing
* `io` - io
* `path` - path
* `alloc` - alloc crate
* `rand` - rand crate
* `collections` - collections crate
* `std_misc` - other parts of std
* `test` - test crate
* `rustc_private` - everything else
2015-01-23 13:28:40 -08:00
Alexander Korolkov
8a22454731
Rephrase error message on invalid fragment specifiers in macros.
...
Also, print help on valid fragment specifiers.
2015-01-23 18:51:12 +03:00
Vadim Chugunov
27a261be3e
Suppress space after idents with "ModName" style in serialization of exported macros.
...
Fixes issue #20701
2015-01-22 17:45:43 -08:00
Brian Anderson
d3c0bb416e
Put #[staged_api] behind the 'staged_api' gate
2015-01-22 13:47:56 -08:00
Brian Anderson
2b879a08b5
Make test harness use unstable APIs without allow(unstable)
2015-01-22 13:47:53 -08:00
Daniel Grunwald
db013f9f45
Fix some grammar inconsistencies for the '..' range notation.
...
Grammar changes:
* allow 'for _ in 1..i {}' (fixes #20241 )
* allow 'for _ in 1.. {}' as infinite loop
* prevent use of range notation in contexts where only operators of high
precedence are expected (fixes #20811 )
Parser code cleanup:
* remove RESTRICTION_NO_DOTS
* make AS_PREC const and follow naming convention
* make min_prec inclusive
2015-01-22 19:55:15 +01:00
blackbeam
3dbac7882e
libsyntax: fix for has_test_signature
2015-01-22 12:29:49 +03:00
Alex Crichton
90af72378d
Make diagnostic ordering deterministic
2015-01-21 20:25:19 -08:00
Brian Anderson
41278c5441
Remove 'since' from unstable attributes
2015-01-21 19:25:55 -08:00
Brian Anderson
11f4d62a06
Add a lint for library features
...
Does a sanity check of the version numbers.
2015-01-21 16:16:21 -08:00
Brian Anderson
7b73ec4698
Tie stability attributes to feature gates
2015-01-21 16:16:21 -08:00
Brian Anderson
94ca8a3610
Add 'feature' and 'since' to stability attributes
2015-01-21 16:16:18 -08:00
Alex Crichton
ecbee2e568
More test fixes and rebase conflicts
2015-01-21 12:49:02 -08:00
Alex Crichton
df1cddf20a
rollup merge of #20179 : eddyb/blind-items
...
Conflicts:
src/librustc/diagnostics.rs
src/librustdoc/clean/mod.rs
src/librustdoc/html/format.rs
src/libsyntax/parse/parser.rs
2015-01-21 11:56:00 -08:00
Alex Crichton
886c6f3534
rollup merge of #21258 : aturon/stab-3-index
...
Conflicts:
src/libcore/ops.rs
src/librustc_typeck/astconv.rs
src/libstd/io/mem.rs
src/libsyntax/parse/lexer/mod.rs
2015-01-21 11:53:49 -08:00
Brian Anderson
90aa581cff
Remove unused stability levels from compiler
2015-01-21 10:34:16 -08:00
Eduard Burtescu
139346adb6
tests: fix fallout of merging ast::ViewItem into ast::Item.
2015-01-21 20:05:16 +02:00
Alex Crichton
9c999c797c
rollup merge of #21463 : sanxiyn/demut
2015-01-21 09:21:09 -08:00
Alex Crichton
87c3ee861e
rollup merge of #21457 : alexcrichton/issue-21436
...
Conflicts:
src/liballoc/boxed.rs
src/librustc/middle/traits/error_reporting.rs
src/libstd/sync/mpsc/mod.rs
2015-01-21 09:20:35 -08:00