summary refs log tree commit diff
path: root/src/test/compile-fail
AgeCommit message (Collapse)AuthorLines
2015-07-30Fix testsBrian Anderson-0/+3
Conflicts: src/test/compile-fail/associated-types-overridden-default.rs src/test/compile-fail/issue-23595-1.rs src/test/compile-fail/issue-23595-2.rs
2015-07-29Feature gate associated type defaultsBrian Anderson-0/+15
There are multiple issues with them as designed and implemented. cc #27364 Conflicts: src/libsyntax/feature_gate.rs src/test/auxiliary/xcrate_associated_type_defaults.rs
2015-07-06Fix some merge conflictsNiko Matsakis-1/+1
2015-07-06Now that I made the warning smarter, these tests no longer require modificationNiko Matsakis-2/+4
2015-07-06Adjust tests to silence warnings (or record them, as appropriate).Niko Matsakis-5/+7
2015-07-06After inferring regions, scan for any bounds that are due to a lifetimeNiko Matsakis-0/+64
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.
2015-06-22Suggest missing trait bounds when a method exists but the bounds aren't ↵Gulshan Singh-0/+18
satisfied
2015-06-22Do not consider fields matched by wildcard patterns to be usedSeo Sanghyeon-4/+6
2015-06-22Auto merge of #26394 - arielb1:implement-rfc401-part2, r=nrcbors-0/+6
This makes them compliant with the new version of RFC 401 (i.e. RFC 1052). Fixes #26391. I *hope* the tests I have are enough. This is a [breaking-change] r? @nrc
2015-06-21Make expr_is_lval more robustAriel Ben-Yehuda-0/+36
Previously it also tried to find out the best way to translate the expression, which could ICE during type-checking. Fixes #23173 Fixes #24322 Fixes #25757
2015-06-20Rollup merge of #26451 - nham:fix_18058, r=arielb1Manish Goregaokar-0/+14
Fixes #18058.
2015-06-20Auto merge of #26407 - arielb1:paren-binding, r=eddybbors-2/+14
r? @eddyb
2015-06-20Add a regression test for #18058.Nick Hamann-0/+14
Fixes #18058.
2015-06-19fixup! Finished implementing proper function check (through FnOnce) and ↵Paul Faria-6/+9
moved tests to new file and updated tests
2015-06-19Finished implementing proper function check (through FnOnce) and moved tests ↵Paul Faria-24/+66
to new file and updated tests
2015-06-19Fixed note message to display expression in recommendationsPaul Faria-6/+18
2015-06-19Uncomplete fix for #2392Paul Faria-0/+11
2015-06-19rustc: replace Repr/UserString impls with Debug/Display ones.Eduard Burtescu-1/+1
2015-06-18Auto merge of #26147 - arielb1:assoc-trans, r=nikomatsakisbors-0/+24
Fixes #25700 r? @nikomatsakis
2015-06-18Fix #23589Ariel Ben-Yehuda-2/+14
2015-06-18Auto merge of #26192 - alexcrichton:features-clean, r=aturonbors-9/+4
This commit shards the all-encompassing `core`, `std_misc`, `collections`, and `alloc` features into finer-grained components that are much more easily opted into and tracked. This reflects the effort to push forward current unstable APIs to either stabilization or removal. Keeping track of unstable features on a much more fine-grained basis will enable the library subteam to quickly analyze a feature and help prioritize internally about what APIs should be stabilized. A few assorted APIs were deprecated along the way, but otherwise this change is just changing the feature name associated with each API. Soon we will have a dashboard for keeping track of all the unstable APIs in the standard library, and I'll also start making issues for each unstable API after performing a first-pass for stabilization.
2015-06-18Simplify and type_known_to_meet_builtin_bound and make it more correct whenAriel Ben-Yehuda-0/+24
associated types are involved.
2015-06-18Auto merge of #26385 - nham:fix_25396, r=alexcrichtonbors-0/+37
Currently in the E0252 message, traits and modules are all called types (as in "a type named `Foo` has already been imported", even when `Foo` was a trait or module). This commit changes that to additionally detect when the import in question is a trait or module and report it accordingly. Fixes #25396.
2015-06-18Prohibit casts between fat pointers to different traitsAriel Ben-Yehuda-0/+6
This makes them compliant with the new version of RFC 401 (i.e. RFC 1052). Fixes #26391. I *hope* the tests I have are enough. This is a [breaking-change]
2015-06-18Auto merge of #26358 - nham:fix_24081, r=alexcrichtonbors-0/+23
Previously, it said "import `Foo` conflicts with existing submodule" even when it was a type alias, enum, or trait. The message now says the conflict is with "type in this module" in the case of the first two, and "trait in this module" for the last one. Fixes #24081.
2015-06-18Auto merge of #26336 - dotdash:raw_ptr_coercions, r=nrcbors-0/+1
Unlike coercing from reference to unsafe pointer, coercing between two unsafe pointers doesn't need an AutoDerefRef, because there is no region that regionck would need to know about. In unoptimized libcore, this reduces the number of "auto_deref" allocas from 174 to 4.
2015-06-17Fix the E0252 error message to use better names for things.Nick Hamann-0/+37
Currently in the E0252 message, traits and modules are all called types (as in "a type named `Foo` has already been imported", even when `Foo` was a trait or module). This commit changes that to additionally detect when the import in question is a trait or module and report it accordingly. Fixes #25396.
2015-06-17Auto merge of #26326 - nikomatsakis:optimize-fulfillment-cache-in-tcx, ↵bors-20/+72
r=pcwalton When we successfully resolve a trait reference with no type/lifetime parameters, like `i32: Foo` or `Box<u32>: Sized`, this is in fact globally true. This patch adds a simple global to the tcx to cache such cases. The main advantage of this is really about caching things like `Box<Vec<Foo>>: Sized`. It also points to the need to revamp our caching infrastructure -- the current caches make selection cost cheaper, but we still wind up paying a high cost in the confirmation process, and in particular unrolling out dependent obligations. Moreover, we should probably do caching more uniformly and with a key that takes the where-clauses into account. But that's for later. For me, this shows up as a reasonably nice win (20%) on Servo's script crate (when built in dev mode). This is not as big as my initial measurements suggested, I think because I was building my rustc with more debugging enabled at the time. I've not yet done follow-up profiling and so forth to see where the new hot spots are. Bootstrap times seem to be largely unaffected. cc @pcwalton This is technically a [breaking-change] in that functions with unsatisfiable where-clauses may now yield errors where before they may have been accepted. Even before, these functions could never have been *called* by actual code. In the future, such functions will probably become illegal altogether, but in this commit they are still accepted, so long as they do not rely on the unsatisfiable where-clauses. As before, the functions still cannot be called in any case.
2015-06-17Fallout in tests and docs from feature renamingsAlex Crichton-9/+4
2015-06-17Auto merge of #25961 - sanxiyn:dead-variant-2, r=huonwbors-0/+22
Rebase of #21468. Fix #25960.
2015-06-16Fix error message for E0256 in certain cases.Nick Hamann-0/+23
Previously, it said "import `Foo` conflicts with existing submodule" even when it was a type alias, enum, or trait. The message now says the conflict is with "type in this module" in the case of the first two, and "trait in this module" for the last one. Fixes #24081.
2015-06-16Avoid deref/ref cycles for no-op coercions between unsafe pointersBjörn Steinbrink-0/+1
Unlike coercing from reference to unsafe pointer, coercing between two unsafe pointers doesn't need an AutoDerefRef, because there is no region that regionck would need to know about. In unoptimized libcore, this reduces the number of "auto_deref" allocas from 174 to 4.
2015-06-15This new caching sometimes suppresses duplicate errors that occur inNiko Matsakis-20/+31
different parts of the crate, so modify the test cases that were relying on that to test distinct types etc.
2015-06-15Rather than expanding the where-clauses in the environment over and overNiko Matsakis-0/+41
again, do it once and then just remember the expanded form. At the same time, filter globally nameable predicates out of the environment, since they can cause cache errors (and they are not necessary in any case).
2015-06-15Auto merge of #26275 - arielb1:unconstrained-projection, r=nikomatsakisbors-0/+32
Fixes #26262 Because this rejects code that previously compiled, this is a [breaking-change] r? @nikomatsakis
2015-06-13Ensure projections are not counted as constraining type parameters.Ariel Ben-Yehuda-0/+32
Fixes #26262
2015-06-13Use `assert_eq!` instead of `assert!` in testspetrochenkov-9/+8
2015-06-13Auto merge of #26253 - steveklabnik:remove_old_ignored_tests, r=brsonbors-73/+1
Two commits here: one which removes a bunch of tests, and re-enables a few that work. Second updates the syntax of one of the failing tests. It still doesn't pass, but at least it compiles.
2015-06-12Update dead-code-closure-bangSteve Klabnik-1/+1
This stdlib function went away, so update it to use current syntax.
2015-06-12ignore-test cleanupSteve Klabnik-72/+0
Most of these are old, but some specific messages for specific tests: * trait-contravariant-self.rs: failed due to a soundess hole: https://github.com/rust-lang/rust/commit/05e3248a7974f55b64f75a2483b37ff8c001a4ff * process-detatch: https://github.com/rust-lang/rust/commit/15966c3c1f99810ac81053769651776a67181dae says "this test is being ignored until signals are implemented" That's not happening for a long time, and when it is, we'll write tests for it. * deep-vector{,2}.rs: "too big for our poor macro infrastructure", and has been ignored over a year. * borrowck-nested-calls.rs's FIXME #6268 was closed in favor of rust-lang/rfcs#811 * issue-15167.rs works properly now * issue-9737.rs works properly now * match-var-hygiene.rs works properly now Addresses a chunk of #3965
2015-06-12Add tests for tuple-like structs and dictionary-like enum variantsSeo Sanghyeon-0/+8
2015-06-12Use more precise span when checking type definitionsSeo Sanghyeon-8/+4
2015-06-11Prevent raw pointers from being used as an explicit selfAriel Ben-Yehuda-0/+18
This can't be made to work with the current setup. Fixes #26194.
2015-06-11Auto merge of #26172 - nham:add_E0116, r=alexcrichtonbors-2/+2
Also improves the wording of the E0133 description. cc #24407
2015-06-10Rollup merge of #26146 - steveklabnik:remove_unsafe_pointer, r=GankroManish Goregaokar-6/+6
Using two terms for one thing is confusing, these are called 'raw pointers' today.
2015-06-10Add explanation for E0116 and update the error message.Nick Hamann-2/+2
Also updates the reference on this point.
2015-06-09Exise 'unsafe pointer' in favor of 'raw pointer'Steve Klabnik-6/+6
Using two terms for one thing is confusing, these are called 'raw pointers' today.
2015-06-09Exise 'owned pointer' from the codebaseSteve Klabnik-3/+3
Still some references left to this old term, I've updated them to say boxes. Related to #25851
2015-06-08Auto merge of #26091 - chellmuth:pub-struct-field-span, r=nrcbors-0/+30
Issue: #26083 Re-submitting https://github.com/rust-lang/rust/pull/26084 r? @nrc
2015-06-07Add licenseChris Hellmuth-0/+10