]> git.lizzy.rs Git - rust.git/log
rust.git
9 years agodon't use type_parameter_def during astconv
Ariel Ben-Yehuda [Mon, 6 Jul 2015 15:46:03 +0000 (18:46 +0300)]
don't use type_parameter_def during astconv

astconv is called when converting the type-parameter, which leads to
a crash.

Fixes #26812.

9 years agoAuto merge of #26817 - cmr:vecdeque-docs, r=Gankro
bors [Mon, 6 Jul 2015 05:01:21 +0000 (05:01 +0000)]
Auto merge of #26817 - cmr:vecdeque-docs, r=Gankro

None

9 years agoAuto merge of #26811 - steveklabnik:rollup, r=steveklabnik
bors [Sun, 5 Jul 2015 23:42:50 +0000 (23:42 +0000)]
Auto merge of #26811 - steveklabnik:rollup, r=steveklabnik

- Successful merges: #26464, #26789, #26800, #26806, #26808
- Failed merges: #26796

9 years agoAuto merge of #26464 - Gankro:send, r=alexcrichton
bors [Sun, 5 Jul 2015 22:10:21 +0000 (22:10 +0000)]
Auto merge of #26464 - Gankro:send, r=alexcrichton

Vec contains `Unique<T>` and some usizes, this is already derived.

9 years agoAuto merge of #26473 - Eljay:missing_docs, r=alexcrichton
bors [Sun, 5 Jul 2015 20:37:26 +0000 (20:37 +0000)]
Auto merge of #26473 - Eljay:missing_docs, r=alexcrichton

Fixes #24249

I've tagged all items that were missing docs to allow them to compile for now, the ones in core/num should probably be documented at least.

This is also a breaking change for any crates using `#[deny(missing_docs)]` that have undocumented constants, not sure there is any way to avoid this without making it a separate lint?

9 years agoRollup merge of #26808 - tshepang:closures, r=steveklabnik
Steve Klabnik [Sun, 5 Jul 2015 19:12:21 +0000 (15:12 -0400)]
Rollup merge of #26808 - tshepang:closures, r=steveklabnik

9 years agoreference: 'inherits' is more clear than 'implies'
Tshepang Lekhonkhobe [Sun, 5 Jul 2015 19:43:28 +0000 (21:43 +0200)]
reference: 'inherits' is more clear than 'implies'

9 years agoRollup merge of #26806 - cmr:stabilize-drain, r=Gankro
Steve Klabnik [Sun, 5 Jul 2015 19:12:20 +0000 (15:12 -0400)]
Rollup merge of #26806 - cmr:stabilize-drain, r=Gankro

None

9 years agoRollup merge of #26800 - tshepang:comma, r=Gankro
Steve Klabnik [Sun, 5 Jul 2015 19:12:20 +0000 (15:12 -0400)]
Rollup merge of #26800 - tshepang:comma, r=Gankro

9 years agoRollup merge of #26789 - tshepang:improve-array-examples, r=alexcrichton
Steve Klabnik [Sun, 5 Jul 2015 19:12:20 +0000 (15:12 -0400)]
Rollup merge of #26789 - tshepang:improve-array-examples, r=alexcrichton

9 years agoRollup merge of #26464 - Gankro:send, r=alexcrichton
Steve Klabnik [Sun, 5 Jul 2015 19:12:19 +0000 (15:12 -0400)]
Rollup merge of #26464 - Gankro:send, r=alexcrichton

Vec contains `Unique<T>` and some usizes, this is already derived.

9 years agoAuto merge of #25754 - geofft:remove-compiletest-jit, r=alexcrichton
bors [Sun, 5 Jul 2015 19:05:14 +0000 (19:05 +0000)]
Auto merge of #25754 - geofft:remove-compiletest-jit, r=alexcrichton

jit support was removed from rustc in 6b34ba242d7372b779bf50682b9401b61183828e
(December 2013), so passing `--jit` wouldn't even work.

9 years agoAuto merge of #26798 - steveklabnik:rollup, r=steveklabnik
bors [Sun, 5 Jul 2015 17:31:11 +0000 (17:31 +0000)]
Auto merge of #26798 - steveklabnik:rollup, r=steveklabnik

- Successful merges: #26785, #26787, #26788, #26791, #26792, #26795
- Failed merges: #26796

9 years agocollections: vec_deque: add some notes on how to use VecDeque as a queue effectively
Corey Richardson [Sun, 5 Jul 2015 16:18:57 +0000 (12:18 -0400)]
collections: vec_deque: add some notes on how to use VecDeque as a queue effectively

9 years agoreference: remove stray comma
Tshepang Lekhonkhobe [Sun, 5 Jul 2015 15:58:46 +0000 (17:58 +0200)]
reference: remove stray comma

9 years agoRollup merge of #26795 - tshepang:typo, r=steveklabnik
Steve Klabnik [Sun, 5 Jul 2015 11:35:16 +0000 (07:35 -0400)]
Rollup merge of #26795 - tshepang:typo, r=steveklabnik

9 years agoreference: fix typo
Tshepang Lekhonkhobe [Sun, 5 Jul 2015 14:36:43 +0000 (16:36 +0200)]
reference: fix typo

9 years agoRollup merge of #26792 - tshepang:follow-idiom, r=steveklabnik
Steve Klabnik [Sun, 5 Jul 2015 11:35:15 +0000 (07:35 -0400)]
Rollup merge of #26792 - tshepang:follow-idiom, r=steveklabnik

9 years agoreference: improve lambda example
Tshepang Lekhonkhobe [Sun, 5 Jul 2015 12:49:08 +0000 (14:49 +0200)]
reference: improve lambda example

9 years agoRollup merge of #26791 - tshepang:misc-ref-fixes, r=steveklabnik
Steve Klabnik [Sun, 5 Jul 2015 11:35:15 +0000 (07:35 -0400)]
Rollup merge of #26791 - tshepang:misc-ref-fixes, r=steveklabnik

One is for grammar, and the other is for clarity

9 years agoreference: tiny fixes
Tshepang Lekhonkhobe [Sun, 5 Jul 2015 12:45:24 +0000 (14:45 +0200)]
reference: tiny fixes

One is for grammar, and the other is for clarity

9 years agoRollup merge of #26788 - tshepang:not-exclamation-marks, r=steveklabnik
Steve Klabnik [Sun, 5 Jul 2015 11:35:15 +0000 (07:35 -0400)]
Rollup merge of #26788 - tshepang:not-exclamation-marks, r=steveklabnik

The sentences are also so short that they don't need periods at the end

9 years agoRollup merge of #26787 - tshepang:tuple-usage, r=steveklabnik
Steve Klabnik [Sun, 5 Jul 2015 11:35:15 +0000 (07:35 -0400)]
Rollup merge of #26787 - tshepang:tuple-usage, r=steveklabnik

9 years agoRollup merge of #26785 - tshepang:inference, r=steveklabnik
Steve Klabnik [Sun, 5 Jul 2015 11:35:14 +0000 (07:35 -0400)]
Rollup merge of #26785 - tshepang:inference, r=steveklabnik

…at and integer types

9 years agoreference: improve examples of the different array types
Tshepang Lekhonkhobe [Sun, 5 Jul 2015 11:30:46 +0000 (13:30 +0200)]
reference: improve examples of the different array types

9 years agoreference: that looks like exclamations marks for some fonts
Tshepang Lekhonkhobe [Sun, 5 Jul 2015 11:11:26 +0000 (13:11 +0200)]
reference: that looks like exclamations marks for some fonts

The sentences are also so short that they don't need periods at the end

9 years agoreference: make tuple usage examples more meaningful
Tshepang Lekhonkhobe [Sun, 5 Jul 2015 11:01:42 +0000 (13:01 +0200)]
reference: make tuple usage examples more meaningful

9 years agoreference: improve readability of type inference explanations for float and integer...
Tshepang Lekhonkhobe [Sun, 5 Jul 2015 10:31:44 +0000 (12:31 +0200)]
reference: improve readability of type inference explanations for float and integer types

9 years agocollections: vec_deque: rename "ringbuf" to "VecDeque" in doc comments
Corey Richardson [Sun, 5 Jul 2015 07:49:36 +0000 (03:49 -0400)]
collections: vec_deque: rename "ringbuf" to "VecDeque" in doc comments

9 years agoAuto merge of #26776 - bluss:num-inline, r=eddyb
bors [Sat, 4 Jul 2015 20:59:56 +0000 (20:59 +0000)]
Auto merge of #26776 - bluss:num-inline, r=eddyb

Add missing #[inline] to min_value/max_value on integers

Spotted a compiled function call to num::usize::min_value, I'd prefer
the 0 to be inlined.

9 years agoAdd missing #[inline] to min_value/max_value on integers
Ulrik Sverdrup [Sat, 4 Jul 2015 20:54:59 +0000 (22:54 +0200)]
Add missing #[inline] to min_value/max_value on integers

Spotted a compiled function call to num::usize::min_value, I'd prefer
the 0 to be inlined.

9 years agoAuto merge of #26694 - eddyb:method-nan, r=arielb1
bors [Sat, 4 Jul 2015 18:49:28 +0000 (18:49 +0000)]
Auto merge of #26694 - eddyb:method-nan, r=arielb1

`MethodCallee` now has no information about the method, other than its `DefId`.
The previous bits of information can be recovered as follows:
```rust
let method_item = tcx.impl_or_trait_item(callee.def_id);
let container = method_item.container();
```
The method is inherent if `container` is a `ty::ImplContainer`:
* the `impl` the method comes from is `container.id()`

The method is a trait method if `container` is a `ty::TraitContainer:
* the `trait` the method is part of is `container.id()`
* a `ty::TraitRef` can be constructed by putting together:
 * `container.id()` as the `trait` ID
 * `callee.substs.clone().method_to_trait()` as the `trait` substs (including `Self`)
* the above `trait_ref` is a valid `T: Trait<A, B, C>` predicate
* selecting `trait_ref` could result in one of the following:
 * `traits::VtableImpl(data)`: static dispatch to `data.impl_def_id`
 * `traits::VtableObject(data)`: dynamic dispatch, with the vtable index:
`traits::get_vtable_index_of_object_method(tcx, data, callee.def_id)`
 * other variants of `traits::Vtable`: various other `impl` sources

9 years agoAuto merge of #26771 - bluss:str-prefix, r=Gankro
bors [Sat, 4 Jul 2015 17:16:51 +0000 (17:16 +0000)]
Auto merge of #26771 - bluss:str-prefix, r=Gankro

core: Use memcmp in is_prefix_of / is_suffix_of

The basic str equality in core::str calls memcmp, re-use the same
function in StrSearcher's is_prefix_of, is_suffix_of.

9 years agorustc: remove MethodOrigin and use the container to distinguish inherent methods.
Eduard Burtescu [Sat, 4 Jul 2015 04:07:10 +0000 (07:07 +0300)]
rustc: remove MethodOrigin and use the container to distinguish inherent methods.

9 years agorustc: compute the vtable base of a supertrait during selection. Fixes #26339.
Eduard Burtescu [Sat, 4 Jul 2015 02:46:54 +0000 (05:46 +0300)]
rustc: compute the vtable base of a supertrait during selection. Fixes #26339.

9 years agoAuto merge of #26770 - arielb1:str-mut-idx, r=eddyb
bors [Sat, 4 Jul 2015 14:44:45 +0000 (14:44 +0000)]
Auto merge of #26770 - arielb1:str-mut-idx, r=eddyb

r? @eddyb

This doesn't seem to make any code valid because the `IndexMut` impls are missing.

9 years agostr: Correct documentation on is_char_boundary
Ulrik Sverdrup [Sat, 4 Jul 2015 13:20:34 +0000 (15:20 +0200)]
str: Correct documentation on is_char_boundary

Documentation claims it panics on out of bounds -- it regards out of
bounds as just not a char boundary.

core::str module is aware of how it works and uses it appropriately.
Maybe we should rename it to `is_valid_index`, `is_slicable_index`, or
something similar.

9 years agoRemove outdated errors for mutating strings
Ariel Ben-Yehuda [Sat, 4 Jul 2015 12:30:00 +0000 (15:30 +0300)]
Remove outdated errors for mutating strings

9 years agocore: Use memcmp in is_prefix_of / is_suffix_of
Ulrik Sverdrup [Sat, 4 Jul 2015 13:10:20 +0000 (15:10 +0200)]
core: Use memcmp in is_prefix_of / is_suffix_of

The basic str equality in core::str calls memcmp, re-use the same
function in StrSearcher's is_prefix_of, is_suffix_of.

9 years agoAuto merge of #26728 - arielb1:assoc-maybe, r=nrc
bors [Sat, 4 Jul 2015 11:10:16 +0000 (11:10 +0000)]
Auto merge of #26728 - arielb1:assoc-maybe, r=nrc

r? @nrc

9 years agorequire reimplementations of all items when a defaulted associated type is overriden
Ariel Ben-Yehuda [Tue, 30 Jun 2015 17:30:47 +0000 (20:30 +0300)]
require reimplementations of all items when a defaulted associated type is overriden

This is a
[breaking-change]
but it follows the RFC (not sure whether it will be accepted).

9 years agoClean-up check_impl_items_against_trait
Ariel Ben-Yehuda [Tue, 30 Jun 2015 15:25:06 +0000 (18:25 +0300)]
Clean-up check_impl_items_against_trait

9 years agoAuto merge of #26763 - steveklabnik:fix_feature_gates, r=sfackler
bors [Sat, 4 Jul 2015 04:52:35 +0000 (04:52 +0000)]
Auto merge of #26763 - steveklabnik:fix_feature_gates, r=sfackler

These aren't actually needed

9 years agorustc: remove MethodOrigin::Object and use traits::VtableObject instead.
Eduard Burtescu [Fri, 3 Jul 2015 02:22:54 +0000 (05:22 +0300)]
rustc: remove MethodOrigin::Object and use traits::VtableObject instead.

9 years agorustc_trans: remove some outdated and unused logic from callee.
Eduard Burtescu [Thu, 2 Jul 2015 11:34:53 +0000 (14:34 +0300)]
rustc_trans: remove some outdated and unused logic from callee.

9 years agorustc_lint: use traits::select for methods in unconditional_recursion.
Eduard Burtescu [Thu, 2 Jul 2015 10:33:01 +0000 (13:33 +0300)]
rustc_lint: use traits::select for methods in unconditional_recursion.

9 years agorustc_trans: explicit impl population is unnecessary in fulfill_obligation.
Eduard Burtescu [Thu, 2 Jul 2015 06:11:36 +0000 (09:11 +0300)]
rustc_trans: explicit impl population is unnecessary in fulfill_obligation.

9 years agorustc: simplify ty::MethodOrigin and avoid trait item indices.
Eduard Burtescu [Thu, 2 Jul 2015 05:52:36 +0000 (08:52 +0300)]
rustc: simplify ty::MethodOrigin and avoid trait item indices.

9 years agorustc: remove unused MethodStaticClosure variant of MethodOrigin.
Eduard Burtescu [Tue, 30 Jun 2015 10:41:13 +0000 (13:41 +0300)]
rustc: remove unused MethodStaticClosure variant of MethodOrigin.

9 years agoAuto merge of #26754 - SaschaNaz:patch-1, r=steveklabnik
bors [Sat, 4 Jul 2015 03:19:07 +0000 (03:19 +0000)]
Auto merge of #26754 - SaschaNaz:patch-1, r=steveklabnik

9 years agoAuto merge of #26370 - nikomatsakis:better-object-defaults-warn, r=nikomatsakis
bors [Sat, 4 Jul 2015 00:23:30 +0000 (00:23 +0000)]
Auto merge of #26370 - nikomatsakis:better-object-defaults-warn, r=nikomatsakis

This is an implementation of RFC rust-lang/rfcs#1156. It includes the code to implement the new rules, but that code is currently disabled. It also includes code to issue warnings when the change will cause breakage. These warnings try hard to be targeted but are also somewhat approximate. They could, with some effort, be made *more* targeted by adjusting the code in ty_relate that propagates the "will change" flag to consider the specific operation. Might be worth doing.

r? @pnkfelix (I think you understand region inference best)

9 years agoFix some merge conflicts
Niko Matsakis [Wed, 24 Jun 2015 14:17:31 +0000 (10:17 -0400)]
Fix some merge conflicts

9 years agoNow that I made the warning smarter, these tests no longer require modification
Niko Matsakis [Wed, 17 Jun 2015 18:11:58 +0000 (14:11 -0400)]
Now that I made the warning smarter, these tests no longer require modification

9 years agoAdjust tests to silence warnings (or record them, as appropriate).
Niko Matsakis [Wed, 17 Jun 2015 14:12:18 +0000 (10:12 -0400)]
Adjust tests to silence warnings (or record them, as appropriate).

9 years agoAfter inferring regions, scan for any bounds that are due to a lifetime
Niko Matsakis [Wed, 17 Jun 2015 14:08:26 +0000 (10:08 -0400)]
After inferring regions, scan for any bounds that are due to a lifetime
bound that is likely to change. In that case, it will change to 'static,
so then scan down the graph to see whether there are any hard
constraints that would prevent 'static from being a valid value
here. Report a warning.

9 years agoAdd a boolean flag to ExistentialBounds tracking whether the
Niko Matsakis [Wed, 17 Jun 2015 13:11:34 +0000 (09:11 -0400)]
Add a boolean flag to ExistentialBounds tracking whether the
region-bound is expected to change in Rust 1.3, but don't use it for
anything in this commit. Note that this is not a "significant" part of
the type (it's not part of the formal model) so we have to normalize
this away or trans starts to get confused because two equal types wind
up with distinct LLVM types.

9 years agoCode up the new lifetime default rules, but leave them disabled
Niko Matsakis [Wed, 17 Jun 2015 14:02:32 +0000 (10:02 -0400)]
Code up the new lifetime default rules, but leave them disabled
for now.

9 years agoAuto merge of #26378 - arielb1:unused-mut, r=pnkfelix
bors [Fri, 3 Jul 2015 21:31:46 +0000 (21:31 +0000)]
Auto merge of #26378 - arielb1:unused-mut, r=pnkfelix

This makes it somewhat more aggressive, so this is kind-of a [breaking-change] for these compiling with `#[deny(unused_mut)]`.

r? @pnkfelix

9 years agoAuto merge of #26762 - rick68:patch-9, r=alexcrichton
bors [Fri, 3 Jul 2015 19:59:52 +0000 (19:59 +0000)]
Auto merge of #26762 - rick68:patch-9, r=alexcrichton

Remove the tagged attribute `stable` from all private functions.

9 years agoremove some feature gates from the docs
Steve Klabnik [Fri, 3 Jul 2015 19:45:06 +0000 (15:45 -0400)]
remove some feature gates from the docs

These aren't actually needed

9 years agoUpdate atomic.rs
Wei-Ming Yang [Fri, 3 Jul 2015 19:24:25 +0000 (03:24 +0800)]
Update atomic.rs

Remove the tagged attribute `stable` from all private functions

9 years agoAuto merge of #26759 - dotdash:drop_dst, r=pnkfelix
bors [Fri, 3 Jul 2015 13:59:42 +0000 (13:59 +0000)]
Auto merge of #26759 - dotdash:drop_dst, r=pnkfelix

Fixes #26709

9 years agoFix ICE caused by Drop implementations for unsized types
Björn Steinbrink [Fri, 3 Jul 2015 10:19:36 +0000 (12:19 +0200)]
Fix ICE caused by Drop implementations for unsized types

Fixes #26709

9 years agoMYSY2 -> MSYS2
Kagami Sascha Rosylight [Fri, 3 Jul 2015 08:16:13 +0000 (17:16 +0900)]
MYSY2 -> MSYS2

9 years agoAuto merge of #26752 - frewsxcv:patch-25, r=alexcrichton
bors [Fri, 3 Jul 2015 07:13:57 +0000 (07:13 +0000)]
Auto merge of #26752 - frewsxcv:patch-25, r=alexcrichton

9 years agoFix 'Relaaxed' typo in code comment
Corey Farwell [Fri, 3 Jul 2015 07:13:02 +0000 (00:13 -0700)]
Fix 'Relaaxed' typo in code comment

9 years agoAuto merge of #26740 - steveklabnik:gh26737, r=gankro
bors [Fri, 3 Jul 2015 02:32:27 +0000 (02:32 +0000)]
Auto merge of #26740 - steveklabnik:gh26737, r=gankro

Fixes #26737.

9 years agoAuto merge of #26610 - aturon:fix_make_unique, r=alexcrichton
bors [Fri, 3 Jul 2015 01:00:31 +0000 (01:00 +0000)]
Auto merge of #26610 - aturon:fix_make_unique, r=alexcrichton

This commit resolves the race condition in the `get_mut` and
`make_unique` functions, which arose through interaction with weak
pointers. The basic strategy is to "lock" the weak pointer count when
trying to establish uniqueness, by reusing the field as a simple
spinlock. The overhead for normal use of `Arc` is expected to be minimal
-- it will be *none* when only strong pointers are used, and only
requires a move from atomic increment to CAS for usage of weak pointers.

The commit also removes the `unsafe` and deprecated status of these functions.

Closes #24880

r? @alexcrichton

cc @metajack @SimonSapin @Ms2ger

9 years agoAuto merge of #26733 - nhowell:update-jquery, r=steveklabnik
bors [Thu, 2 Jul 2015 23:28:20 +0000 (23:28 +0000)]
Auto merge of #26733 - nhowell:update-jquery, r=steveklabnik

r? @steveklabnik

9 years agoAuto merge of #26725 - tshepang:patch-2, r=bluss
bors [Thu, 2 Jul 2015 21:56:28 +0000 (21:56 +0000)]
Auto merge of #26725 - tshepang:patch-2, r=bluss

9 years agoFix race condition in Arc's get_mut and make_unqiue
Aaron Turon [Fri, 26 Jun 2015 21:32:34 +0000 (14:32 -0700)]
Fix race condition in Arc's get_mut and make_unqiue

This commit resolves the race condition in the `get_mut` and
`make_unique` functions, which arose through interaction with weak
pointers. The basic strategy is to "lock" the weak pointer count when
trying to establish uniqueness, by reusing the field as a simple
spinlock. The overhead for normal use of `Arc` is expected to be minimal
-- it will be *none* when only strong pointers are used, and only
requires a move from atomic increment to CAS for usage of weak pointers.

The commit also removes the `unsafe` and deprecated status of these
functions.

Along the way, the commit also improves several memory orderings, and
adds commentary about why various orderings suffice.

9 years agoAuto merge of #26738 - dotdash:trans_args, r=luqmana
bors [Thu, 2 Jul 2015 20:23:45 +0000 (20:23 +0000)]
Auto merge of #26738 - dotdash:trans_args, r=luqmana

The current split between create_datums_for_fn_args, copy_args_to_allocas and
store_arg involves a detour via rvalue datums which cause additional work in
form of insertvalue/extractvalue pairs for fat pointer arguments, and an extra
alloca and memcpy for tupled args in rust-call functions.

By merging those three functions into just one that actually covers the whole
process of creating the final argument datums, we can skip all that.  Also,
this allows to easily merge in the handling of rust-call functions, allowing to
make create_datum_for_fn_args_under_call_abi obsolete.

cc #26600 -- The insertvalue instructions kicked us off of fast-isel.

9 years agoAuto merge of #26682 - posix4e:netbsd, r=alexcrichton
bors [Thu, 2 Jul 2015 18:50:46 +0000 (18:50 +0000)]
Auto merge of #26682 - posix4e:netbsd, r=alexcrichton

This is dependent on https://github.com/rust-lang/rust-installer/pull/38. Once it is merged we most likely need to update the commit.

9 years agoAdd more description for from_raw_parts's unsafety
Steve Klabnik [Thu, 2 Jul 2015 17:00:58 +0000 (13:00 -0400)]
Add more description for from_raw_parts's unsafety

Fixes #26737.

9 years agoDirectly construct lvalue datums for function arguments
Björn Steinbrink [Thu, 2 Jul 2015 16:18:22 +0000 (18:18 +0200)]
Directly construct lvalue datums for function arguments

The current split between create_datums_for_fn_args,
copy_args_to_allocas and store_arg involves a detour via rvalue datums
which cause additional work in form of insertvalue/extractvalue pairs
for fat pointer arguments, and an extra alloca and memcpy for tupled
args in rust-call functions.

By merging those three functions into just one that actually covers the
whole process of creating the final argument datums, we can skip all
that. Also, this allows to easily merge in the handling of rust-call
functions, allowing to make create_datum_for_fn_args_under_call_abi
obsolete.

cc #26600 -- The insertvalue instructions kicked us off of fast-isel.

9 years agoAvoid a needless vector copy in type_of_rust_fn
Björn Steinbrink [Thu, 2 Jul 2015 16:16:16 +0000 (18:16 +0200)]
Avoid a needless vector copy in type_of_rust_fn

9 years agoSkip the pointless tupling/untupling of argument types in trans_closure
Björn Steinbrink [Thu, 2 Jul 2015 16:11:24 +0000 (18:11 +0200)]
Skip the pointless tupling/untupling of argument types in trans_closure

The tupling only happens for actual closures, same for the untupling.
The only code that actually sees the tupled types is some debugging
output for which it is actually rather confusing to have the types
tupled, because neither the function signature in Rust nor the
function signature for LLVM has them tupled.

9 years agoAuto merge of #26724 - tshepang:patch-1, r=bluss
bors [Thu, 2 Jul 2015 15:57:30 +0000 (15:57 +0000)]
Auto merge of #26724 - tshepang:patch-1, r=bluss

Also, the info is repeated in the following paragraph

9 years agoAuto merge of #26713 - GuillaumeGomez:patch-3, r=Manishearth
bors [Thu, 2 Jul 2015 14:23:02 +0000 (14:23 +0000)]
Auto merge of #26713 - GuillaumeGomez:patch-3, r=Manishearth

r? @Manishearth

9 years agoAuto merge of #26715 - steveklabnik:gh26497, r=huonw
bors [Thu, 2 Jul 2015 12:28:11 +0000 (12:28 +0000)]
Auto merge of #26715 - steveklabnik:gh26497, r=huonw

Add an example, plus some text that covers the buffering nature of
channels.

Fixes #26497

9 years agoAuto merge of #26712 - GuillaumeGomez:patch-2, r=Manishearth
bors [Thu, 2 Jul 2015 10:51:50 +0000 (10:51 +0000)]
Auto merge of #26712 - GuillaumeGomez:patch-2, r=Manishearth

Part of #24407.
cc @michaelsproul
r? @Manishearth

9 years agoAuto merge of #26727 - remram44:coerceunsized-weak, r=eddyb
bors [Thu, 2 Jul 2015 09:19:27 +0000 (09:19 +0000)]
Auto merge of #26727 - remram44:coerceunsized-weak, r=eddyb

This is a simple addition, shouldn't change behavior.

Fixes #26704

I don't know if the coercion for `Rc` is tested, if it is this probably needs the same test with `Weak`.

9 years agoAuto merge of #26722 - arielb1:log-deadlock, r=eddyb
bors [Thu, 2 Jul 2015 07:47:29 +0000 (07:47 +0000)]
Auto merge of #26722 - arielb1:log-deadlock, r=eddyb

These are RefCell deadlocks that cause the rustc task to die with the stderr
lock held, causing a real deadlock.

Fixes #26717.

r? @eddyb

9 years agoAuto merge of #26718 - nham:test-8640, r=alexcrichton
bors [Thu, 2 Jul 2015 06:14:54 +0000 (06:14 +0000)]
Auto merge of #26718 - nham:test-8640, r=alexcrichton

This doesn't add a test for the main problem in #8640 since it seems that
was already fixed (including a test) in PR https://github.com/rust-lang/rust/pull/19522. This just adds a test
for a program mentioned in the comments that used to erroneously compile.

Closes #8640.

9 years agoAuto merge of #26691 - nrc:mem, r=alexcrichton
bors [Thu, 2 Jul 2015 04:42:50 +0000 (04:42 +0000)]
Auto merge of #26691 - nrc:mem, r=alexcrichton

Reports the resident set size after each pass (linux-only).

r? @huonw or @alexcrichton

9 years agorustdoc: Update jQuery from 2.1.0 to 2.1.4
Nick Howell [Thu, 2 Jul 2015 03:52:40 +0000 (23:52 -0400)]
rustdoc: Update jQuery from 2.1.0 to 2.1.4

9 years agoAuto merge of #26677 - jroesch:fulfillment-context-refactor, r=nrc
bors [Thu, 2 Jul 2015 03:10:25 +0000 (03:10 +0000)]
Auto merge of #26677 - jroesch:fulfillment-context-refactor, r=nrc

This patch implements the next chunk of flattening out the type checking context. In a series of patches I moved around the necessary state and logic in order to delete the `Typer` and `ClosureTyper` traits. My next goal is to clean the interfaces and start to move the normalization code behind them.

r? @nrc I hope my PR is coherent, doing this too late at night ;)

9 years agoUpdate librustc_driver/test.rs
Jared Roesch [Thu, 2 Jul 2015 02:29:17 +0000 (19:29 -0700)]
Update librustc_driver/test.rs

9 years agoAdd netbsd amd64 support
Alex Newman [Wed, 1 Jul 2015 03:37:11 +0000 (20:37 -0700)]
Add netbsd amd64 support

9 years agoAuto merge of #26688 - nrc:map-parent-2, r=manishearth
bors [Thu, 2 Jul 2015 01:40:28 +0000 (01:40 +0000)]
Auto merge of #26688 - nrc:map-parent-2, r=manishearth

r? @Manishearth

9 years agoImplement CoerceUnsized for arc::Weak
Remi Rampin [Wed, 1 Jul 2015 21:58:05 +0000 (17:58 -0400)]
Implement CoerceUnsized for arc::Weak

9 years agoAdd test to dst-coerce-rc.rs
Remi Rampin [Wed, 1 Jul 2015 21:54:54 +0000 (17:54 -0400)]
Add test to dst-coerce-rc.rs

9 years agoReport memory use in time-passes
Nick Cameron [Sun, 28 Jun 2015 01:37:33 +0000 (18:37 -0700)]
Report memory use in time-passes

Reports the resident set size after each pass (linux-only).

9 years agodoc: add missing space
Tshepang Lekhonkhobe [Wed, 1 Jul 2015 21:08:50 +0000 (23:08 +0200)]
doc: add missing space

9 years agodoc: there is just one trait in here
Tshepang Lekhonkhobe [Wed, 1 Jul 2015 21:05:06 +0000 (23:05 +0200)]
doc: there is just one trait in here

Also, the info is repeated in the following paragraph

9 years agoRefactoring
Nick Cameron [Tue, 30 Jun 2015 20:58:48 +0000 (08:58 +1200)]
Refactoring

9 years agoFix deadlocks with RUST_LOG=rustc::middle::ty
Ariel Ben-Yehuda [Wed, 1 Jul 2015 20:07:26 +0000 (23:07 +0300)]
Fix deadlocks with RUST_LOG=rustc::middle::ty

These are RefCell deadlocks that cause the rustc task to die with the stderr
lock held, causing a real deadlock.

Fixes #26717.

9 years agoAddress nits
Jared Roesch [Wed, 1 Jul 2015 20:08:25 +0000 (13:08 -0700)]
Address nits

9 years agoImplement CoerceUnsized for rc::Weak
Remi Rampin [Wed, 1 Jul 2015 19:51:17 +0000 (15:51 -0400)]
Implement CoerceUnsized for rc::Weak

Fixes #26704

9 years agoAuto merge of #26658 - alexcrichton:windows-net-no-inherit, r=aturon
bors [Wed, 1 Jul 2015 19:28:15 +0000 (19:28 +0000)]
Auto merge of #26658 - alexcrichton:windows-net-no-inherit, r=aturon

This was added after Windows 7 SP1, so it's not always available. Instead use
the `SetHandleInformation` function to flag a socket as not inheritable. This is
not atomic with respect to creating new processes, but it mirrors what Unix does
with respect to possibly using the atomic option in the future.

Closes #26543