summary refs log tree commit diff
path: root/src/test/compile-fail
AgeCommit message (Collapse)AuthorLines
2015-02-19Round 5 test fixes and rebase conflictsAlex Crichton-1/+1
2015-02-18Fix from niko for cfail testsAlex Crichton-12/+13
2015-02-18Round 4 test fixes and rebase conflictsAlex Crichton-9/+6
2015-02-18Exempt phantom fns from the object safety checkNiko Matsakis-0/+28
2015-02-18Round 3 test fixes and conflictsAlex Crichton-12/+9
2015-02-18rollup merge of #22286: nikomatsakis/variance-4bAlex Crichton-259/+1293
Conflicts: src/librustc/middle/infer/combine.rs src/librustc_typeck/check/wf.rs
2015-02-18rollup merge of #22502: nikomatsakis/deprecate-bracket-bracketAlex Crichton-5/+3
Conflicts: src/libcollections/slice.rs src/libcollections/str.rs src/librustc/middle/lang_items.rs src/librustc_back/rpath.rs src/librustc_typeck/check/regionck.rs src/libstd/ffi/os_str.rs src/libsyntax/diagnostic.rs src/libsyntax/parse/parser.rs src/libsyntax/util/interner.rs src/test/run-pass/regions-refcell.rs
2015-02-18rollup merge of #22210: aturon/stab-final-borrowAlex Crichton-2/+1
Conflicts: src/libcollections/btree/map.rs src/libcollections/str.rs src/libcollections/vec.rs src/libcore/borrow.rs src/libcore/hash/mod.rs src/libstd/collections/hash/map.rs src/libstd/collections/hash/set.rs
2015-02-18Stabilize std::borrowAaron Turon-2/+1
This commit stabilizes `std::borrow`, making the following modifications to catch up the API with language changes: * It renames `BorrowFrom` to `Borrow`, as was originally intended (but blocked for technical reasons), and reorders the parameters accordingly. * It moves the type parameter of `ToOwned` to an associated type. This is somewhat less flexible, in that each borrowed type must have a unique owned type, but leads to a significant simplification for `Cow`. Flexibility can be regained by using newtyped slices, which is advisable for other reasons anyway. * It removes the owned type parameter from `Cow`, making the type much less verbose. * Deprecates the `is_owned` and `is_borrowed` predicates in favor of direct matching. The above API changes are relatively minor; the basic functionality remains the same, and essentially the whole module is now marked `#[stable]`. [breaking-change]
2015-02-18Declare `&foo[]` to be obsolete syntax. Modify the obsolete mechanism toNiko Matsakis-5/+3
support warnings.
2015-02-18rollup merge of #22497: nikomatsakis/suffixesAlex Crichton-168/+171
Conflicts: src/librustc_trans/trans/tvec.rs
2015-02-18rollup merge of #22480: alexcrichton/hashv3Alex Crichton-1/+1
This commit is an implementation of [RFC 823][rfc] which is another pass over the `std::hash` module for stabilization. The contents of the module were not entirely marked stable, but some portions which remained quite similar to the previous incarnation are now marked `#[stable]`. Specifically: [rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0823-hash-simplification.md * `std::hash` is now stable (the name) * `Hash` is now stable * `Hash::hash` is now stable * `Hasher` is now stable * `SipHasher` is now stable * `SipHasher::new` and `new_with_keys` are now stable * `Hasher for SipHasher` is now stable * Many `Hash` implementations are now stable All other portions of the `hash` module remain `#[unstable]` as they are less commonly used and were recently redesigned. This commit is a breaking change due to the modifications to the `std::hash` API and more details can be found on the [RFC][rfc]. Closes #22467 [breaking-change]
2015-02-18rollup merge of #22452: nikomatsakis/issue-22040-18956-SelfAlex Crichton-0/+131
The big change here is that we update the object-safety rules to prohibit references to `Self` in the supertrait listing. See #22040 for the motivation. The other change is to handle the interaction of defaults that reference `Self` and object types (where `Self` is erased). We force users to give an explicit type in that scenario. r? @aturon
2015-02-18rollup merge of #22436: nikomatsakis/issue-22246-bound-lifetimes-of-assoc-typesAlex Crichton-0/+273
Take 2. This PR includes a bunch of refactoring that was part of an experimental branch implementing [implied bounds]. That particular idea isn't ready to go yet, but the refactoring proved useful for fixing #22246. The implied bounds branch also exposed #22110 so a simple fix for that is included here. I still think some more refactoring would be a good idea here -- in particular I think most of the code in wf.rs is kind of duplicating the logic in implicator and should go, but I decided to post this PR and call it a day before diving into that. I'll write a bit more details about the solutions I adopted in the various bugs. I patched the two issues I was concerned about, which was the handling of supertraits and HRTB (the latter turned out to be fine, so I added a comment explaining why.) r? @pnkfelix (for now, anyway) cc @aturon [implied bounds]: http://smallcultfollowing.com/babysteps/blog/2014/07/06/implied-bounds/
2015-02-18Update tests to use #[feature(rustc_attrs)]Niko Matsakis-0/+10
2015-02-18rollup merge of #22118: fhahn/separate-parse-fail-2Alex Crichton-1635/+5
After making `rustc` fail on errors at a stop point, like `-Z parse-only`, in #22117, the files in this PR also fail during the parse stage and should be moved as well. Sorry for spliting this move up in two PRs.
2015-02-18Add deprecated versions of the old markers and integrate them back into the ↵Niko Matsakis-0/+35
variance analysis.
2015-02-18Add rustc_attrs feature to test.Niko Matsakis-0/+1
2015-02-18Extend the implicator so it produces general obligations and also soNiko Matsakis-0/+272
that it produces "outlives" relations for associated types. Add several tests relating to #22246.
2015-02-18For now, accept the `i`, `u`, `is`, and `us` suffixes, but warn whenNiko Matsakis-6/+8
they are used without a feature-gate. This is both kinder to existing code and should make it easier to land this PR, since we don't have to catch EVERY SINGLE SUFFIX.
2015-02-18std: Stabilize the `hash` moduleAlex Crichton-1/+1
This commit is an implementation of [RFC 823][rfc] which is another pass over the `std::hash` module for stabilization. The contents of the module were not entirely marked stable, but some portions which remained quite similar to the previous incarnation are now marked `#[stable]`. Specifically: [rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0823-hash-simplification.md * `std::hash` is now stable (the name) * `Hash` is now stable * `Hash::hash` is now stable * `Hasher` is now stable * `SipHasher` is now stable * `SipHasher::new` and `new_with_keys` are now stable * `Hasher for SipHasher` is now stable * Many `Hash` implementations are now stable All other portions of the `hash` module remain `#[unstable]` as they are less commonly used and were recently redesigned. This commit is a breaking change due to the modifications to the `std::hash` API and more details can be found on the [RFC][rfc]. Closes #22467 [breaking-change]
2015-02-18Missing test.Niko Matsakis-0/+32
2015-02-18Add regression test for #20533. Fixes #20533.Niko Matsakis-0/+54
2015-02-18Fallout: tests. As tests frequently elide things, lots of changesNiko Matsakis-259/+400
here. Some of this may have been poorly rebased, though I tried to be careful and preserve the spirit of the test.
2015-02-18Extend coherence check to understand subtyping.Niko Matsakis-0/+50
2015-02-18Report errors for type parameters that are not constrained, either byNiko Matsakis-0/+16
variance or an associated type.
2015-02-18Introduce the new phantomdata/phantomfn markers and integrate themNiko Matsakis-0/+696
into variance inference; fix various bugs in variance inference so that it considers the correct set of constraints; modify infer to consider the results of variance inference for type arguments.
2015-02-18Update suffixes en masse in tests using `perl -p -i -e`Niko Matsakis-142/+142
2015-02-18Convert required suffixes into a use of `as`.Niko Matsakis-6/+7
2015-02-18Remove `i`, `is`, `u`, or `us` suffixes that are not necessary.Niko Matsakis-21/+21
2015-02-17Test fixes and rebase conflictsAlex Crichton-4/+3
2015-02-17rollup merge of #22319: huonw/send-is-not-staticAlex Crichton-135/+48
Conflicts: src/libstd/sync/task_pool.rs src/libstd/thread.rs src/libtest/lib.rs src/test/bench/shootout-reverse-complement.rs src/test/bench/shootout-spectralnorm.rs
2015-02-17Test fixes and rebase conflictsAlex Crichton-23/+21
2015-02-17rollup merge of #22435: aturon/final-stab-threadAlex Crichton-40/+40
Conflicts: src/test/bench/rt-messaging-ping-pong.rs src/test/bench/rt-parfib.rs src/test/bench/task-perf-spawnalot.rs
2015-02-17rollup merge of #22459: alexcrichton/feature-namesAlex Crichton-9/+8
Conflicts: src/rustbook/main.rs
2015-02-18Update tests for the Send - 'static change.Huon Wilson-135/+23
2015-02-17Fallout from stabilizationAaron Turon-40/+40
2015-02-17rollup merge of #22024: alexcrichton/asciiAlex Crichton-0/+5
* Move the type parameter on the `AsciiExt` trait to an associated type named `Owned`. * Move `ascii::escape_default` to using an iterator. This is a breaking change due to the removal of the type parameter on the `AsciiExt` trait as well as the modifications to the `escape_default` function to returning an iterator. Manual implementations of `AsciiExt` (or `AsciiExt` bounds) should be adjusted to remove the type parameter and using the new `escape_default` should be relatively straightforward. [breaking-change]
2015-02-17Traits that reference `Self` in the supertrait list are not object-safe. ↵Niko Matsakis-0/+82
Fixes #22040.
2015-02-17std: Rename io/path features with old_ prefixAlex Crichton-9/+8
This commit renames the features for the `std::old_io` and `std::old_path` modules to `old_io` and `old_path` to help facilitate migration to the new APIs. This is a breaking change as crates which mention the old feature names now need to be renamed to use the new feature names. [breaking-change]
2015-02-17rustc: Track stability of trait implementationsAlex Crichton-0/+5
Previously an implementation of a stable trait allows implementations of unstable methods. This updates the stability pass to ensure that all items of an impl block of a trait are indeed stable on the trait itself.
2015-02-18Add tests for the removal of the 'static superbound from Send.Huon Wilson-0/+25
2015-02-17When converting parameters for an object type, be careful of defaults that ↵Niko Matsakis-0/+49
reference `Self`. Fixes #18956.
2015-02-17Fix failing testsManish Goregaokar-0/+4
2015-02-17Rollup merge of #22383 - pnkfelix:pass-features-along-during-expansion, r=huonwManish Goregaokar-0/+134
Pass features along during expansion Use the set of passed features to detect uses of feature-gated macros without the corresponding feature enabled. Fix #22234. ---- Also, the framework this add (passing along a reference to the features in the expansion context) is a necessary precursor for landing a properly feature-gated desugaring-based overloaded-`box` and placement-`in` (#22181). ---- This is fixing a bug, but since there might be code out there that is unknowingly taking advantage of that bug, I feel obligated to mark this as a: [breaking-change]
2015-02-17Rollup merge of #22364 - Manishearth:rfc-572-forbid-attr, r=nikomatsakisManish Goregaokar-2/+54
fixes #22203 r? @nikomatsakis This breaks code that might be using attributes randomly, so it's technically a [breaking-change]
2015-02-17Rollup merge of #22418 - japaric:diagnostics, r=nikomatsakisManish Goregaokar-8/+32
closes #22388 r? @nikomatsakis cc @insaneinside
2015-02-17Fix tests for rustc_*Manish Goregaokar-0/+30
2015-02-16Auto merge of #22230 - nikomatsakis:object-lifetime-defaults-2, r=pnkfelixbors-74/+495
Implement rules described in rust-lang/rfcs#599. Fixes https://github.com/rust-lang/rust/issues/22211. ~~Based atop PR https://github.com/rust-lang/rust/pull/22182, so the first few commits (up to and including "Pacify the mercilous nrc") have already been reviewed.~~
2015-02-16Move remaning compile-fail tests that are rejected by the parser to parse-failFlorian Hahn-1635/+5