]> git.lizzy.rs Git - rust.git/log
rust.git
9 years agoauto merge of #19800 : sfackler/rust/core-hash, r=alexcrichton
bors [Wed, 17 Dec 2014 16:43:20 +0000 (16:43 +0000)]
auto merge of #19800 : sfackler/rust/core-hash, r=alexcrichton

r? @alexcrichton

9 years agoauto merge of #19799 : alexcrichton/rust/stop-panicking, r=huonw
bors [Wed, 17 Dec 2014 14:33:12 +0000 (14:33 +0000)]
auto merge of #19799 : alexcrichton/rust/stop-panicking, r=huonw

Fix a panic where the compiler was looking at stale or old metadata.

See #19798, #19772, #19757, #19744, #19718, #19691.

9 years agoauto merge of #19789 : nick29581/rust/assoc-ufcs2, r=nikomatsakis
bors [Wed, 17 Dec 2014 08:13:07 +0000 (08:13 +0000)]
auto merge of #19789 : nick29581/rust/assoc-ufcs2, r=nikomatsakis

Closes #18433

9 years agoauto merge of #19761 : nick29581/rust/coerce-double, r=nikomatsakis
bors [Wed, 17 Dec 2014 02:42:57 +0000 (02:42 +0000)]
auto merge of #19761 : nick29581/rust/coerce-double, r=nikomatsakis

Part of #18469

[breaking-change]

A receiver will only ever get a single auto-reference. Previously arrays and strings would get two, e.g., [T] would be auto-ref'ed to &&[T]. This is usually apparent when a trait is implemented for `&[T]` and has a method takes self by reference. The usual solution is to implement the trait for `[T]` (the DST form).

r? @nikomatsakis (or anyone else, really)

9 years agoauto merge of #19921 : FlaPer87/rust/snapshot, r=nikomatsakis
bors [Tue, 16 Dec 2014 17:51:23 +0000 (17:51 +0000)]
auto merge of #19921 : FlaPer87/rust/snapshot, r=nikomatsakis

r? @nikomatsakis

9 years agoauto merge of #19647 : nielsegberts/rust/master, r=pnkfelix
bors [Tue, 16 Dec 2014 14:50:58 +0000 (14:50 +0000)]
auto merge of #19647 : nielsegberts/rust/master, r=pnkfelix

The names expected and actual are not used anymore in the output. It also
removes the confusion that the argument order is the opposite of junit.

Bug #7330 is relevant.

9 years agoCreate a snapshot on top of 1b97cd3
Flavio Percoco [Tue, 16 Dec 2014 13:39:00 +0000 (14:39 +0100)]
Create a snapshot on top of 1b97cd3

9 years agoauto merge of #19782 : gereeter/rust/cleanup-btree-node, r=Gankro
bors [Tue, 16 Dec 2014 11:02:56 +0000 (11:02 +0000)]
auto merge of #19782 : gereeter/rust/cleanup-btree-node, r=Gankro

Before:
```
test btree::map::bench::find_rand_100                      ... bench:        12 ns/iter (+/- 0)
test btree::map::bench::find_rand_10_000                   ... bench:        13 ns/iter (+/- 1)
test btree::map::bench::find_seq_100                       ... bench:        11 ns/iter (+/- 0)
test btree::map::bench::find_seq_10_000                    ... bench:        11 ns/iter (+/- 1)
test btree::map::bench::insert_rand_100                    ... bench:       106 ns/iter (+/- 1)
test btree::map::bench::insert_rand_10_000                 ... bench:       326 ns/iter (+/- 8)
test btree::map::bench::insert_seq_100                     ... bench:       198 ns/iter (+/- 1)
test btree::map::bench::insert_seq_10_000                  ... bench:       312 ns/iter (+/- 3)
test btree::map::bench::iter_1000                          ... bench:     16563 ns/iter (+/- 173)
test btree::map::bench::iter_100000                        ... bench:   1686508 ns/iter (+/- 108592)
test btree::map::bench::iter_20                            ... bench:       365 ns/iter (+/- 25)
```

After:
```
test btree::map::bench::find_rand_100                      ... bench:        12 ns/iter (+/- 0)
test btree::map::bench::find_rand_10_000                   ... bench:        12 ns/iter (+/- 0)
test btree::map::bench::find_seq_100                       ... bench:        11 ns/iter (+/- 0)
test btree::map::bench::find_seq_10_000                    ... bench:        11 ns/iter (+/- 0)
test btree::map::bench::insert_rand_100                    ... bench:        89 ns/iter (+/- 1)
test btree::map::bench::insert_rand_10_000                 ... bench:       121 ns/iter (+/- 3)
test btree::map::bench::insert_seq_100                     ... bench:       149 ns/iter (+/- 0)
test btree::map::bench::insert_seq_10_000                  ... bench:       228 ns/iter (+/- 1)
test btree::map::bench::iter_1000                          ... bench:     16965 ns/iter (+/- 220)
test btree::map::bench::iter_100000                        ... bench:   1687836 ns/iter (+/- 18746)
test btree::map::bench::iter_20                            ... bench:       366 ns/iter (+/- 21)
```

9 years agoauto merge of #19777 : nikomatsakis/rust/warn-on-shadowing, r=acrichto
bors [Tue, 16 Dec 2014 08:42:40 +0000 (08:42 +0000)]
auto merge of #19777 : nikomatsakis/rust/warn-on-shadowing, r=acrichto

per rfc 459
cc https://github.com/rust-lang/rust/issues/19390

One question is: should we start by warning, and only switch to hard error later? I think we discussed something like this in the meeting.

r? @alexcrichton

9 years agoMove hash module from collections to core
Steven Fackler [Sat, 13 Dec 2014 02:43:07 +0000 (18:43 -0800)]
Move hash module from collections to core

9 years agoauto merge of #19478 : nick29581/rust/assoc-ice-test, r=nikomatsakis
bors [Tue, 16 Dec 2014 06:22:40 +0000 (06:22 +0000)]
auto merge of #19478 : nick29581/rust/assoc-ice-test, r=nikomatsakis

closes #19121

r?

This won't actually pass until https://github.com/rust-lang/rust/pull/19391 lands

9 years agoTest for associated types ICE
Nick Cameron [Tue, 2 Dec 2014 23:06:39 +0000 (15:06 -0800)]
Test for associated types ICE

closes #19121

9 years agoRemove the double auto-ref on arrays/strings as receivers
Nick Cameron [Fri, 12 Dec 2014 00:23:21 +0000 (13:23 +1300)]
Remove the double auto-ref on arrays/strings as receivers

Part of #18469

[breaking-change]

A receiver will only ever get a single auto-reference. Previously arrays and strings would get two, e.g., [T] would be auto-ref'ed to &&[T]. This is usually apparent when a trait is implemented for `&[T]` and has a method takes self by reference. The usual solution is to implement the trait for `[T]` (the DST form).

9 years agoauto merge of #19747 : alexcrichton/rust/slice-one-trait, r=brson
bors [Tue, 16 Dec 2014 01:32:33 +0000 (01:32 +0000)]
auto merge of #19747 : alexcrichton/rust/slice-one-trait, r=brson

This commit collapses the various prelude traits for slices into just one trait:

* SlicePrelude/SliceAllocPrelude => SliceExt
* CloneSlicePrelude/CloneSliceAllocPrelude => CloneSliceExt
* OrdSlicePrelude/OrdSliceAllocPrelude => OrdSliceExt
* PartialEqSlicePrelude => PartialEqSliceExt

9 years agoReview changes
Nick Cameron [Tue, 16 Dec 2014 00:48:18 +0000 (13:48 +1300)]
Review changes

9 years agoPath types to associated types with form `T::A`
Nick Cameron [Thu, 4 Dec 2014 19:58:52 +0000 (11:58 -0800)]
Path types to associated types with form `T::A`

Closes #18433

9 years agoauto merge of #19448 : japaric/rust/binops-by-value, r=nikomatsakis
bors [Mon, 15 Dec 2014 22:11:44 +0000 (22:11 +0000)]
auto merge of #19448 : japaric/rust/binops-by-value, r=nikomatsakis

- The following operator traits now take their arguments by value: `Add`, `Sub`, `Mul`, `Div`, `Rem`, `BitAnd`, `BitOr`, `BitXor`, `Shl`, `Shr`. This breaks all existing implementations of these traits.

- The binary operation `a OP b` now "desugars" to `OpTrait::op_method(a, b)` and consumes both arguments.

- `String` and `Vec` addition have been changed to reuse the LHS owned value, and to avoid internal cloning. Only the following asymmetric operations are available: `String + &str` and `Vec<T> + &[T]`, which are now a short-hand for the "append" operation.

[breaking-change]

---

This passes `make check` locally. I haven't touch the unary operators in this PR, but converting them to by value should be very similar to this PR. I can work on them after this gets the thumbs up.

@nikomatsakis r? the compiler changes
@aturon r? the library changes. I think the only controversial bit is the semantic change of the `Vec`/`String` `Add` implementation.
cc #19148

9 years agoauto merge of #19882 : steveklabnik/rust/fix_download, r=nikomatsakis
bors [Mon, 15 Dec 2014 19:12:44 +0000 (19:12 +0000)]
auto merge of #19882 : steveklabnik/rust/fix_download, r=nikomatsakis

Thank you, @Ap0ph1s.

9 years agoauto merge of #19785 : brson/rust/rollup, r=brson
bors [Mon, 15 Dec 2014 15:33:11 +0000 (15:33 +0000)]
auto merge of #19785 : brson/rust/rollup, r=brson

9 years agoRemove all shadowed lifetimes.
Niko Matsakis [Fri, 12 Dec 2014 16:09:32 +0000 (11:09 -0500)]
Remove all shadowed lifetimes.

9 years agoEmit warning when lifetime names are shadowed.
Niko Matsakis [Fri, 12 Dec 2014 16:09:24 +0000 (11:09 -0500)]
Emit warning when lifetime names are shadowed.

This is not technically a [breaking-change], but it will be soon, so
you should update your code. Typically, shadowing is accidental, and
the shadowing lifetime can simply be removed. This frequently occurs
in constructor patterns:

```rust
// Old:
impl<'a> SomeStruct<'a> { fn new<'a>(..) -> SomeStruct<'a> { ... } }

// Should be:
impl<'a> SomeStruct<'a> { fn new(..) -> SomeStruct<'a> { ... } }
```

Otherwise, you should rename the inner lifetime to something
else. Note though that lifetime elision frequently applies:

```rust
// Old
impl<'a> SomeStruct<'a> {
    fn get<'a>(x: &'a self) -> &'a T { &self.field }
}

// Should be:
impl<'a> SomeStruct<'a> {
    fn get(x: &self) -> &T { &self.field }
}
``

9 years agoFix windows download links
Steve Klabnik [Mon, 15 Dec 2014 14:55:56 +0000 (09:55 -0500)]
Fix windows download links

Thank you, @Ap0ph1s.

9 years agorollup merge of #19814: jbranchaud/fix-a-typo-in-ownership-guide
Brian Anderson [Sun, 14 Dec 2014 02:24:45 +0000 (18:24 -0800)]
rollup merge of #19814: jbranchaud/fix-a-typo-in-ownership-guide

9 years agorollup merge of #19812: frewsxcv/expansion-include-enum
Brian Anderson [Sun, 14 Dec 2014 02:24:42 +0000 (18:24 -0800)]
rollup merge of #19812: frewsxcv/expansion-include-enum

In preparation for [removing the `std::cmp::Ordering` reexport](https://github.com/rust-lang/rust/issues/19253), this needs to be done to prevent errors like:

```
note: in expansion of #[deriving]
note: expansion site
error: unresolved name `std::cmp::Equal`
#[deriving(Clone, PartialEq, PartialOrd, Eq, Ord, Show)]
                                             ^~~
```

9 years agorollup merge of #19804: kballard/vim-new-unicode-escapes
Brian Anderson [Sun, 14 Dec 2014 02:24:18 +0000 (18:24 -0800)]
rollup merge of #19804: kballard/vim-new-unicode-escapes

9 years agorollup merge of #19802: jbranchaud/add-btreeset-new-doctest
Brian Anderson [Sun, 14 Dec 2014 02:24:15 +0000 (18:24 -0800)]
rollup merge of #19802: jbranchaud/add-btreeset-new-doctest

9 years agorollup merge of #19793: tomjakubowski/metadata-const-attrs
Brian Anderson [Sun, 14 Dec 2014 02:24:13 +0000 (18:24 -0800)]
rollup merge of #19793: tomjakubowski/metadata-const-attrs

Fix #19773

Together with #19774 (which this is rebased on):

Fix #18156, fix #19722, fix #19185

r? @alexcrichton (since this was your suggestion!)

9 years agorollup merge of #19787: akiss77/fix-i8-c_char
Brian Anderson [Sun, 14 Dec 2014 02:24:05 +0000 (18:24 -0800)]
rollup merge of #19787: akiss77/fix-i8-c_char

On AArch64, libc::c_char is u8. There are some places in the code where i8 is assumed, which causes compilation errors.

(AArch64 is not officially supported yet, but this change does not hurt any other targets and makes the code future-proof.)

9 years agorollup merge of #19784: csouth3/vim-syntax-iter
Brian Anderson [Sun, 14 Dec 2014 02:23:41 +0000 (18:23 -0800)]
rollup merge of #19784: csouth3/vim-syntax-iter

Vim still incorrectly highlights just `ExactSize` as a valid trait name, but the trait has been renamed to `ExactSizeIterator`.

9 years agorollup merge of #19779: Noctune/master
Brian Anderson [Sun, 14 Dec 2014 02:23:30 +0000 (18:23 -0800)]
rollup merge of #19779: Noctune/master

The old PartialOrd impl for raw pointers would always return Some(_), so It might as well implement Ord too.

9 years agorollup merge of #19775: SimonSapin/gedit-new-unicode-escape
Brian Anderson [Sun, 14 Dec 2014 02:23:19 +0000 (18:23 -0800)]
rollup merge of #19775: SimonSapin/gedit-new-unicode-escape

9 years agorollup merge of #19774: tomjakubowski/rustdoc-consts-statics
Brian Anderson [Sun, 14 Dec 2014 02:23:13 +0000 (18:23 -0800)]
rollup merge of #19774: tomjakubowski/rustdoc-consts-statics

Build `clean::ConstantItem` values in the `inline` module and
pretty-print the AST for inlined const items.

Doc strings are still missing from inlined constants (see #19773).

Partially address #18156, #19722, #19185

Fix #15821

r? @alexcrichton

9 years agorollup merge of #19771: jbranchaud/add-btreeset-iter-doctests
Brian Anderson [Sun, 14 Dec 2014 02:23:09 +0000 (18:23 -0800)]
rollup merge of #19771: jbranchaud/add-btreeset-iter-doctests

9 years agorollup merge of #19763: csouth3/remove-featuregates
Brian Anderson [Sun, 14 Dec 2014 02:23:00 +0000 (18:23 -0800)]
rollup merge of #19763: csouth3/remove-featuregates

This is a revival of #19517 (per request of @alexcrichton) now that the new snapshots have landed.  We can now remove the last feature gates for if_let, while_let, and tuple_indexing scattered throughout the test sources since these features have been added to Rust.

Closes #19473.

9 years agorollup merge of #19754: steveklabnik/remove_sundown
Brian Anderson [Sun, 14 Dec 2014 02:22:55 +0000 (18:22 -0800)]
rollup merge of #19754: steveklabnik/remove_sundown

9 years agorollup merge of #19746: steveklabnik/gh9266
Brian Anderson [Sun, 14 Dec 2014 02:22:44 +0000 (18:22 -0800)]
rollup merge of #19746: steveklabnik/gh9266

Fixes #9266

9 years agorollup merge of #19738: steveklabnik/gh19717
Brian Anderson [Sun, 14 Dec 2014 02:22:25 +0000 (18:22 -0800)]
rollup merge of #19738: steveklabnik/gh19717

Fixes #19717

9 years agorollup merge of #19735: sethpollack/patch-1
Brian Anderson [Sun, 14 Dec 2014 02:22:23 +0000 (18:22 -0800)]
rollup merge of #19735: sethpollack/patch-1

9 years agorollup merge of #19714: steveklabnik/gh16219
Brian Anderson [Sun, 14 Dec 2014 02:22:14 +0000 (18:22 -0800)]
rollup merge of #19714: steveklabnik/gh16219

These should be properly annotated instead.

Fixes #16219.

9 years agorollup merge of #19710: steveklabnik/gh15449
Brian Anderson [Sun, 14 Dec 2014 02:22:09 +0000 (18:22 -0800)]
rollup merge of #19710: steveklabnik/gh15449

Fixes #15499.

9 years agorollup merge of #19709: steveklabnik/po4a_fix
Brian Anderson [Sun, 14 Dec 2014 02:22:06 +0000 (18:22 -0800)]
rollup merge of #19709: steveklabnik/po4a_fix

This line was declared twice, which causes the build of i10n docs to
fail.

9 years agoauto merge of #19778 : aochagavia/rust/ice, r=alexcrichton
bors [Mon, 15 Dec 2014 11:17:44 +0000 (11:17 +0000)]
auto merge of #19778 : aochagavia/rust/ice, r=alexcrichton

Fixes #19734

9 years agoauto merge of #19750 : murarth/rust/rusti-support, r=brson
bors [Mon, 15 Dec 2014 08:32:45 +0000 (08:32 +0000)]
auto merge of #19750 : murarth/rust/rusti-support, r=brson

Makes a couple changes that support the implementation of a REPL:

* Implementation of wrapper code for LLVM ExecutionEngine API
* Fixing a change I made earlier to reset compiler state in `phase_1_[...]`
  instead of `compile_input` as the latter is not used in a REPL

9 years agostd: Collapse SlicePrelude traits
Alex Crichton [Thu, 11 Dec 2014 17:44:17 +0000 (09:44 -0800)]
std: Collapse SlicePrelude traits

This commit collapses the various prelude traits for slices into just one trait:

* SlicePrelude/SliceAllocPrelude => SliceExt
* CloneSlicePrelude/CloneSliceAllocPrelude => CloneSliceExt
* OrdSlicePrelude/OrdSliceAllocPrelude => OrdSliceExt
* PartialEqSlicePrelude => PartialEqSliceExt

9 years agoauto merge of #19742 : vhbit/rust/copy-for-bitflags, r=alexcrichton
bors [Mon, 15 Dec 2014 00:07:35 +0000 (00:07 +0000)]
auto merge of #19742 : vhbit/rust/copy-for-bitflags, r=alexcrichton

9 years agoauto merge of #19703 : nikomatsakis/rust/unsafe-trait, r=acrichto
bors [Sun, 14 Dec 2014 19:07:29 +0000 (19:07 +0000)]
auto merge of #19703 : nikomatsakis/rust/unsafe-trait, r=acrichto

This PR allows declaring traits and impls as `unsafe`. An `unsafe` trait requires an `unsafe` impl. An `unsafe` impl does not permit unsafe code within its interior (unless that code is contained within an unsafe block or unsafe fn, as normal). The commits are standalone.

r? @alexcrichton
cc #13231

9 years agoAdd a bunch of new tests per Alex's suggestion.
Niko Matsakis [Wed, 10 Dec 2014 22:24:10 +0000 (17:24 -0500)]
Add a bunch of new tests per Alex's suggestion.

9 years agoImplement `unsafe trait` semantics.
Niko Matsakis [Wed, 10 Dec 2014 15:59:20 +0000 (10:59 -0500)]
Implement `unsafe trait` semantics.

9 years agoParse `unsafe impl` but don't do anything particularly interesting with the results.
Niko Matsakis [Wed, 10 Dec 2014 11:15:06 +0000 (06:15 -0500)]
Parse `unsafe impl` but don't do anything particularly interesting with the results.

9 years agoParse `unsafe trait` but do not do anything with it beyond parsing and integrating...
Niko Matsakis [Wed, 10 Dec 2014 00:59:20 +0000 (19:59 -0500)]
Parse `unsafe trait` but do not do anything with it beyond parsing and integrating into rustdoc etc.

9 years agoRename FnStyle trait to Unsafety.
Niko Matsakis [Tue, 9 Dec 2014 15:36:46 +0000 (10:36 -0500)]
Rename FnStyle trait to Unsafety.

9 years agoauto merge of #19725 : vadimcn/rust/inst-path, r=alexcrichton
bors [Sun, 14 Dec 2014 16:07:32 +0000 (16:07 +0000)]
auto merge of #19725 : vadimcn/rust/inst-path, r=alexcrichton

Change default installation directory to %SYSTEMDRIVE%\Rust.
Modify user PATH, rather than system PATH.

9 years agoauto merge of #19338 : nikomatsakis/rust/unboxed-closure-purge-the-proc, r=acrichto
bors [Sun, 14 Dec 2014 11:37:27 +0000 (11:37 +0000)]
auto merge of #19338 : nikomatsakis/rust/unboxed-closure-purge-the-proc, r=acrichto

They are replaced with unboxed closures.

cc @pcwalton @aturon

This is a [breaking-change]. Mostly, uses of `proc()` simply need to be converted to `move||` (unboxed closures), but in some cases the adaptations required are more complex (particularly for library authors). A detailed write-up can be found here: http://smallcultfollowing.com/babysteps/blog/2014/11/26/purging-proc/

The commits are ordered to emphasize the more important changes, but are not truly standalone.

9 years agoauto merge of #19690 : barosl/rust/struct-variant-as-a-function-ice, r=alexcrichton
bors [Sun, 14 Dec 2014 09:22:24 +0000 (09:22 +0000)]
auto merge of #19690 : barosl/rust/struct-variant-as-a-function-ice, r=alexcrichton

Unlike a tuple variant constructor which can be called as a function, a struct variant constructor is not a function, so cannot be called.

If the user tries to assign the constructor to a variable, an ICE occurs, because there is no way to use it later. So we should stop the constructor from being used like that.

A similar mechanism already exists for a normal struct, as it prohibits a struct from being resolved. This commit does the same for a struct variant.

This commit also includes some changes to the existing tests.

Fixes #19452.

9 years agoStop using diagnostics to avoid merge conflicts.
Niko Matsakis [Sat, 13 Dec 2014 10:06:36 +0000 (05:06 -0500)]
Stop using diagnostics to avoid merge conflicts.

9 years agoTemporarily remove issue #14039; it is fixed and re-added by PR #19438
Niko Matsakis [Thu, 4 Dec 2014 01:02:19 +0000 (20:02 -0500)]
Temporarily remove issue #14039; it is fixed and re-added by PR #19438

9 years agoAdd some tests for obsolete code, sugar used in appropriate ways.
Niko Matsakis [Thu, 27 Nov 2014 11:59:21 +0000 (06:59 -0500)]
Add some tests for obsolete code, sugar used in appropriate ways.

9 years agoUpdate emacs and vi modes.
Niko Matsakis [Wed, 26 Nov 2014 15:03:11 +0000 (10:03 -0500)]
Update emacs and vi modes.

9 years agoUpdate guide/intro to take into account the removal of `proc`.
Niko Matsakis [Wed, 26 Nov 2014 15:02:46 +0000 (10:02 -0500)]
Update guide/intro to take into account the removal of `proc`.

cc @steveklabnick

9 years agoDelete tests that are either no longer relevant or which have
Niko Matsakis [Thu, 27 Nov 2014 11:44:05 +0000 (06:44 -0500)]
Delete tests that are either no longer relevant or which have
duplicate tests around object types.

9 years agoMostly rote conversion of `proc()` to `move||` (and occasionally `Thunk::new`)
Niko Matsakis [Wed, 26 Nov 2014 13:12:18 +0000 (08:12 -0500)]
Mostly rote conversion of `proc()` to `move||` (and occasionally `Thunk::new`)

9 years agoRewrite WorkItem not to use `proc()`.
Niko Matsakis [Wed, 26 Nov 2014 15:07:58 +0000 (10:07 -0500)]
Rewrite WorkItem not to use `proc()`.

9 years agoPatch rustdoc to include missing types, make the match exhaustive
Niko Matsakis [Wed, 26 Nov 2014 15:11:27 +0000 (10:11 -0500)]
Patch rustdoc to include missing types, make the match exhaustive
to prevent such oversights in the future.

9 years agoRemove `proc` types/expressions from the parser, compiler, and
Niko Matsakis [Wed, 26 Nov 2014 15:07:22 +0000 (10:07 -0500)]
Remove `proc` types/expressions from the parser, compiler, and
language. Recommend `move||` instead.

9 years agoAdjust feature gates to allow for parenthetical notation to be used
Niko Matsakis [Tue, 25 Nov 2014 16:45:50 +0000 (11:45 -0500)]
Adjust feature gates to allow for parenthetical notation to be used
with the fn traits

9 years agoPurge the hack that allows `FnOnce` to be used with a by-value self method. Besides...
Niko Matsakis [Thu, 20 Nov 2014 17:12:38 +0000 (12:12 -0500)]
Purge the hack that allows `FnOnce` to be used with a by-value self method.  Besides being yucky, it will cause problems if we try to make all traits implement themselves, which would make a lot of things in life easier. Also, it was inextricably linked to `Box`, which was not the intention.  We can work around its absence, so better to reimplement it later in a more thorough fashion.

9 years agoRewrite threading infrastructure, introducing `Thunk` to represent
Niko Matsakis [Wed, 26 Nov 2014 15:10:52 +0000 (10:10 -0500)]
Rewrite threading infrastructure, introducing `Thunk` to represent
boxed `FnOnce` closures.

9 years agoauto merge of #19677 : japaric/rust/deprecate-tupleN, r=alexcrichton
bors [Sun, 14 Dec 2014 07:07:31 +0000 (07:07 +0000)]
auto merge of #19677 : japaric/rust/deprecate-tupleN, r=alexcrichton

r? @alexcrichton or anyone else
closes #18006

9 years agolibcollections: convert `BTreeSet` binops to by value
Jorge Aparicio [Sat, 13 Dec 2014 21:34:36 +0000 (16:34 -0500)]
libcollections: convert `BTreeSet` binops to by value

9 years agolibcollections: convert `TreeSet` binops to by value
Jorge Aparicio [Sat, 13 Dec 2014 21:29:02 +0000 (16:29 -0500)]
libcollections: convert `TreeSet` binops to by value

9 years agolibcollections: convert `TrieSet` binops to by value
Jorge Aparicio [Sat, 6 Dec 2014 00:39:57 +0000 (19:39 -0500)]
libcollections: convert `TrieSet` binops to by value

9 years agoTest binops move semantics
Jorge Aparicio [Wed, 3 Dec 2014 07:34:49 +0000 (02:34 -0500)]
Test binops move semantics

9 years agolibcollections: add commutative version of `Vec`/`String` addition
Jorge Aparicio [Wed, 3 Dec 2014 07:22:41 +0000 (02:22 -0500)]
libcollections: add commutative version of `Vec`/`String` addition

9 years agoAddress Niko's comments
Jorge Aparicio [Wed, 3 Dec 2014 05:39:53 +0000 (00:39 -0500)]
Address Niko's comments

9 years agolibcore: fix doctests
Jorge Aparicio [Tue, 2 Dec 2014 00:10:12 +0000 (19:10 -0500)]
libcore: fix doctests

9 years agolibstd: fix unit tests
Jorge Aparicio [Mon, 1 Dec 2014 22:55:28 +0000 (17:55 -0500)]
libstd: fix unit tests

9 years agolibcoretest: fix unit tests
Jorge Aparicio [Mon, 1 Dec 2014 23:04:46 +0000 (18:04 -0500)]
libcoretest: fix unit tests

9 years agolibcollections: fix unit tests
Jorge Aparicio [Mon, 1 Dec 2014 23:02:39 +0000 (18:02 -0500)]
libcollections: fix unit tests

9 years agoFix compile-fail tests
Jorge Aparicio [Mon, 1 Dec 2014 22:52:10 +0000 (17:52 -0500)]
Fix compile-fail tests

9 years agoFix run-pass tests
Jorge Aparicio [Mon, 1 Dec 2014 22:33:22 +0000 (17:33 -0500)]
Fix run-pass tests

9 years agoTest that binops consume their arguments
Jorge Aparicio [Mon, 1 Dec 2014 21:52:13 +0000 (16:52 -0500)]
Test that binops consume their arguments

9 years agolibrustdoc: convert `Counts` binops to by value
Jorge Aparicio [Mon, 1 Dec 2014 21:47:48 +0000 (16:47 -0500)]
librustdoc: convert `Counts` binops to by value

9 years agolibrustc: convert `TypeContents` binops to by value
Jorge Aparicio [Mon, 1 Dec 2014 21:34:57 +0000 (16:34 -0500)]
librustc: convert `TypeContents` binops to by value

9 years agolibsyntax: convert `LockstepIterSize` binops to by value
Jorge Aparicio [Mon, 1 Dec 2014 20:09:03 +0000 (15:09 -0500)]
libsyntax: convert `LockstepIterSize` binops to by value

9 years agolibsyntax: convert `BytePos`/`CharPos` binops to by value
Jorge Aparicio [Mon, 1 Dec 2014 19:59:55 +0000 (14:59 -0500)]
libsyntax: convert `BytePos`/`CharPos` binops to by value

9 years agolibtime: convert `Timespec` binops to by value
Jorge Aparicio [Mon, 1 Dec 2014 19:54:31 +0000 (14:54 -0500)]
libtime: convert `Timespec` binops to by value

9 years agolibstd: convert `Duration` binops to by value
Jorge Aparicio [Mon, 1 Dec 2014 19:32:36 +0000 (14:32 -0500)]
libstd: convert `Duration` binops to by value

9 years agolibstd: convert `BitFlags` binops to by value
Jorge Aparicio [Mon, 1 Dec 2014 19:29:47 +0000 (14:29 -0500)]
libstd: convert `BitFlags` binops to by value

9 years agolibcollections: make `EnumSet` binops by value
Jorge Aparicio [Mon, 1 Dec 2014 19:10:04 +0000 (14:10 -0500)]
libcollections: make `EnumSet` binops by value

9 years agolibcollections: String + &str
Jorge Aparicio [Mon, 1 Dec 2014 19:08:56 +0000 (14:08 -0500)]
libcollections: String + &str

9 years agolibcollections: Vec<T> + &[T]
Jorge Aparicio [Mon, 1 Dec 2014 19:01:15 +0000 (14:01 -0500)]
libcollections: Vec<T> + &[T]

9 years agolibcore: fix move semantics fallout
Jorge Aparicio [Mon, 1 Dec 2014 20:52:17 +0000 (15:52 -0500)]
libcore: fix move semantics fallout

9 years agolibcore: convert binop traits to by value
Jorge Aparicio [Mon, 1 Dec 2014 18:00:23 +0000 (13:00 -0500)]
libcore: convert binop traits to by value

9 years agoTell regionck which binops are by value
Jorge Aparicio [Mon, 1 Dec 2014 20:34:36 +0000 (15:34 -0500)]
Tell regionck which binops are by value

9 years agoTell expr_use_visitor which binops are by value
Jorge Aparicio [Mon, 1 Dec 2014 19:47:06 +0000 (14:47 -0500)]
Tell expr_use_visitor which binops are by value

9 years agoTell trans which binops are by value
Jorge Aparicio [Mon, 1 Dec 2014 18:18:18 +0000 (13:18 -0500)]
Tell trans which binops are by value

9 years agoTell typeck which binops are by value
Jorge Aparicio [Mon, 1 Dec 2014 17:23:56 +0000 (12:23 -0500)]
Tell typeck which binops are by value

9 years agosyntax/ast_util: add `is_by_value_binop()`
Jorge Aparicio [Mon, 1 Dec 2014 16:34:28 +0000 (11:34 -0500)]
syntax/ast_util: add `is_by_value_binop()`

9 years agoauto merge of #19669 : alfie/rust/master, r=sanxiyn
bors [Sun, 14 Dec 2014 01:07:31 +0000 (01:07 +0000)]
auto merge of #19669 : alfie/rust/master, r=sanxiyn

9 years agoGet rid of all the remaining uses of `refN`/`valN`/`mutN`/`TupleN`
Jorge Aparicio [Sat, 13 Dec 2014 15:04:55 +0000 (10:04 -0500)]
Get rid of all the remaining uses of `refN`/`valN`/`mutN`/`TupleN`