Commit Graph

37115 Commits

Author SHA1 Message Date
Niko Matsakis
626db33bc8 Move regression test for #20971 into run-fail, since it panics. 2015-01-21 14:35:41 -05:00
Niko Matsakis
fe0868b89b Add regression tests for #20763. Fixes #20763. 2015-01-16 17:22:28 -05:00
Niko Matsakis
1138579bf4 Add regression test for #20797. Fixes #20797. 2015-01-16 17:19:41 -05:00
Niko Matsakis
b7ef34d098 Add regression test for #20971. Fixes #20791. 2015-01-16 16:43:22 -05:00
Niko Matsakis
bd621f0ccb Project region bounds out of the trait when deciding whether a
projection type outlives a given region. Fixes #20890.
2015-01-16 16:43:22 -05:00
bors
ee2bfae011 auto merge of #20972 : FlaPer87/rust/oibit-send-and-friends, r=nikomatsakis
This PR adds rules for negative implementations. It follows pretty much what the [RFC](https://github.com/rust-lang/rfcs/blob/master/text/0019-opt-in-builtin-traits.md) says with 1 main difference:

Instead of positive implementations override negative implementations, this have been implemented in a way that a negative implementation of `Trait` for `T` will overlap with a positive implementation, causing a coherence error.

@nikomatsakis r?

cc #13231

[breaking-change]
2015-01-16 13:10:59 +00:00
Flavio Percoco
cb85223903 fix pretty test fallout 2015-01-16 11:47:48 +01:00
Flavio Percoco
7cd762a967 Docs fallout 2015-01-16 08:18:57 +01:00
Flavio Percoco
2adc8b529a populate impls *before* clonning the impls vec 2015-01-16 08:18:56 +01:00
Flavio Percoco
59775bb955 fix latest changes fallout 2015-01-16 08:18:56 +01:00
Flavio Percoco
aa642b3486 addressed comments 2015-01-16 08:18:56 +01:00
Flavio Percoco
038aa0e8e9 Allow negative impls just for Send and Sync 2015-01-16 08:18:56 +01:00
Flavio Percoco
921ba5a09f Don't use NoSend/NoSync in tests 2015-01-16 08:18:56 +01:00
Flavio Percoco
094397a88b Fix coherence for negative implementations 2015-01-16 08:18:56 +01:00
Flavio Percoco
9d42581cf9 add a run-pass test that used to fail 2015-01-16 08:18:56 +01:00
Flavio Percoco
c6ab9a6370 Don't use NoSend/NoSync in libstd 2015-01-16 08:18:56 +01:00
Flavio Percoco
bb04121138 Don't use NoSend/NoSync in liballoc 2015-01-16 08:18:56 +01:00
Flavio Percoco
388e30f78e Remove NoSend/NoSync 2015-01-16 08:18:56 +01:00
Flavio Percoco
9eec782774 Check for negative impls for Send and Sync 2015-01-16 08:18:56 +01:00
Flavio Percoco
5aab863ba2 Don't assemble bound impls if candidate's ambiguous 2015-01-16 08:18:56 +01:00
Flavio Percoco
39fe05f58c Negative impls are considered safe 2015-01-16 08:18:55 +01:00
Flavio Percoco
e644ca0d6a push_impls_of_trait is not needed, use map 2015-01-16 08:18:55 +01:00
Flavio Percoco
199e0cd804 Add test for missing default impl 2015-01-16 08:18:55 +01:00
Flavio Percoco
683d20c3c5 Record negative trait_impls separatedly 2015-01-16 08:18:55 +01:00
bors
f3d71be65c Merge pull request #21214 from sleepynate/spacing-in-book
Fix commented graphs in src/doc/trpl/ownership.md

Reviewed-by: huonw
2015-01-16 06:31:03 +00:00
bors
ea9b00fdad Merge pull request #21211 from fenhl/patch-1
Fix std::sync::condvar::Condvar::notify_one docs

Reviewed-by: alexcrichton
2015-01-16 06:31:02 +00:00
bors
317da0bf2a Merge pull request #21181 from nick29581/save-fix
Two minor fixes for save-analysis

Reviewed-by: huonw
2015-01-16 06:31:02 +00:00
bors
b565501ad8 auto merge of #21213 : alexcrichton/rust/rollup, r=alexcrichton 2015-01-16 03:02:54 +00:00
Alex Crichton
42198c18f4 Test fixes and rebase conflicts 2015-01-15 18:53:30 -08:00
nathan dotz
3626a308f3 Fix commented graphs in src/doc/trpl/ownership.md 2015-01-15 18:15:18 -05:00
Fenhl
5f34815a22 Fix sync::condvar::Condvar::notify_one docs 2015-01-15 22:43:12 +00:00
bors
8903c21d61 auto merge of #21052 : nick29581/rust/methods-ext, r=sfackler
Allows modifiers to be used on methods, associated types, etc.

r? @sfackler
2015-01-15 22:42:58 +00:00
Alex Crichton
5f32992b31 rollup merge of #21206: steveklabnik/expressions
Suggested here: http://stackoverflow.com/a/27962076/24817
2015-01-15 14:12:08 -08:00
Alex Crichton
002d840d17 rollup merge of #21199: dotdash/decode_lamba
Currently, we build a closure that does nothing but pass its argument
through to another function, this is rather wasteful and creates lots of
unnecessary closures.
2015-01-15 14:12:07 -08:00
Alex Crichton
6dc94f744e rollup merge of #21197: michaelwoerister/linestablesonly-forloop
Fixes #21067.
2015-01-15 14:12:06 -08:00
Alex Crichton
09c0342116 rollup merge of #21191: Zoxc/lto
Fixes #21184
2015-01-15 14:12:04 -08:00
Alex Crichton
782c391789 rollup merge of #21190: FlaPer87/remove_duplicated_func
small cleanup

r? @nikomatsakis
2015-01-15 14:12:03 -08:00
Alex Crichton
b64de7ea76 rollup merge of #21172: brson/tuple
This outer attribute doesn't actually apply to anything is seems
to be incorrect in what it is saying.
2015-01-15 14:12:03 -08:00
Alex Crichton
7c967afe02 rollup merge of #21170: Diggsey/issue-21058
While it's unstable and will probably be replaced or "reformed" at some point, it's useful in the mean time to be able to introspect the type system when debugging, and not be limited to sized types.

Fixes #21058
2015-01-15 14:12:02 -08:00
Alex Crichton
132850c818 rollup merge of #21169: aidanhs/aphs-contributing-style-link 2015-01-15 14:12:01 -08:00
Alex Crichton
ef5a4bb4cb rollup merge of #21168: aidanhs/aphs-doc-vec-heap
...to make it slightly clearer that there's not much point in boxing a vec.

On a different note, I read the contribution guidelines (https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#pull-request-procedure) which say I should update the copyright date for this file. But I can see that nobody else has done this so far this year, despite there being a fair number of commits.

Does that instruction need removing?
2015-01-15 14:12:00 -08:00
Alex Crichton
0419b4ab12 rollup merge of #21167: FlaPer87/coherence-impls
Fixes #21080

r? @nikomatsakis

[breaking-change]
2015-01-15 14:12:00 -08:00
Alex Crichton
7be39b0c03 rollup merge of #21164: richo/doc/servo-link
Tiny docfix to make the urls point to the canonical endpoint.
2015-01-15 14:11:59 -08:00
Alex Crichton
c3c47f5f55 rollup merge of #21161: japaric/ufcs-hash
expansion now uses `::std:#️⃣:Hash::hash(&*__self_0_0, __arg_0)` instead of
`(*__self_0_0).hash(__arg_0)`

closes #21160

r? @alexcrichton
2015-01-15 14:11:58 -08:00
Alex Crichton
9d4d5ca6e7 rollup merge of #21156: nick29581/plugins-fix
Closes #21130

r? @Aatch
2015-01-15 14:11:57 -08:00
Alex Crichton
7101ae4686 rollup merge of #21151: brson/beta 2015-01-15 14:11:56 -08:00
Alex Crichton
8c81800170 rollup merge of #21148: bombless/patch-1 2015-01-15 14:11:55 -08:00
Alex Crichton
9b7bc456ea rollup merge of #21144: nagisa/asm-str-fix
Fixes #21045
2015-01-15 14:11:55 -08:00
Alex Crichton
b86a84867a rollup merge of #21141: tcard/master
Really small correction.

This anti-example in the Closures section is supposed to fail because of a borrow, but it was failing at the type inference because of insufficient type information.

This makes it fail for the expected reason.
2015-01-15 14:11:54 -08:00
Alex Crichton
7e2ef2cbc6 rollup merge of #21133: iKevinY/mobile-rustdoc
Just a couple of tweaks to improve the appearance of pages like [The Rust Reference](http://doc.rust-lang.org/reference.html) on mobile to advance the progress of #20850. Changing the viewport wasn't quite good enough to make it mobile-friendly, as large tables forced the page to become wider than the screen width. Using `overflow-x`, tables that are too large become horizontally scrollable instead of forcing the *entire page* to become horizontally scrollable.

Also, there was at least one case where an extremely long piece of inline code was wider than the actual width of the screen (`std::ptr::copy_nonoverlapping_memory`), so I changed `word-wrap` to allow inline code to break in the middle of words instead of only text within `pre` tags.

This isn't a change included in this PR, but rather something up for discussion. Currently, code blocks that contain long lines simply wrap onto the next line. What if rather than wrapping, they were horizontally scrollable instead? I'm not sure what the general preference is regarding this.

r? @steveklabnik
2015-01-15 14:11:53 -08:00