about summary refs log tree commit diff
path: root/src/test/ui/issues
AgeCommit message (Collapse)AuthorLines
2020-04-05"cannot resolve" → "cannot satisfy"Esteban Küber-6/+6
2020-04-03Rollup merge of #70720 - ecstatic-morse:issue-70637, r=oli-obkMazdak Farrokhzad-0/+12
Place TLS initializers with relocations in .tdata Should fix #70673, although I'm not sure how to test this. Perhaps @joshlf could find a MCVE? Also adds more context to the FIXME. r? @oli-obk
2020-04-03Add regression test for #70673Oliver Scherer-0/+12
2020-04-03Rollup merge of #70725 - Centril:nix-unwraps, r=estebankDylan DPC-0/+51
Avoid `.unwrap()`s on `.span_to_snippet(...)`s First commit fixes https://github.com/rust-lang/rust/issues/70724 and the others fix similar issues found by grepping. r? @estebank
2020-04-03Auto merge of #70582 - pnkfelix:update-llvm-to-fix-69841, r=cuviperbors-0/+30
Fix #69841 by updating LLVM submodule. Fix #69841 by updating LLVM submodule. Includes regression test for issue 69841.
2020-04-03add_type_neq_err_label: don't .unwrapMazdak Farrokhzad-0/+51
2020-04-02tests: remove ignore directives from tests that mention core/alloc/std spans.Eduard-Mihai Burtescu-56/+21
2020-04-01Rollup merge of #70081 - lcnr:issue68387, r=varkorDylan DPC-0/+2
add `unused_braces` lint Add the lint `unused_braces` which is warn by default. `unused_parens` is also extended and now checks anon consts. closes #68387 r? @varkor
2020-03-31update testsBastian Kauschke-0/+2
2020-03-30Fix #69841 by updating LLVM submodule. Includes regression test for issue 69841.Felix S. Klock II-0/+30
2020-03-29Tweak `suggest_constraining_type_param`Esteban Küber-17/+13
Some of the bound restriction structured suggestions were incorrect while others had subpar output.
2020-03-28Auto merge of #70095 - jsgf:link-native, r=nagisabors-0/+8
Implement -Zlink-native-libraries This implements a flag `-Zlink-native-libraries=yes/no`. If set to true/yes, or unspecified, then native libraries referenced via `#[link]` attributes will be put on the linker line (ie, unchanged behaviour). If `-Zlink-native-libraries=no` is specified then rustc will not add the native libraries to the link line. The assumption is that the outer build system driving the build already knows about the native libraries and will specify them to the linker directly (for example via `-Clink-arg=`). Addresses issue #70093
2020-03-27Rollup merge of #70457 - Centril:non-exhaustive-scrutinee-type, r=estebankMazdak Farrokhzad-0/+12
non-exhastive diagnostic: add note re. scrutinee type This fixes https://github.com/rust-lang/rust/issues/67259 by adding a note: ``` = note: the matched value is of type &[i32] ``` to non-exhaustive pattern matching errors. r? @varkor @estebank
2020-03-27Implement -Zlink-native-librariesJeremy Fitzhardinge-0/+8
This implements a flag `-Zlink-native-libraries=yes/no`. If set to true/yes, or unspecified, then native libraries referenced via `#[link]` attributes will be put on the linker line (ie, unchanged behaviour). If `-Zlink-native-libraries=no` is specified then rustc will not add the native libraries to the link line. The assumption is that the outer build system driving the build already knows about the native libraries and will specify them to the linker directly (for example via `-Clink-arg=`). Addresses issue #70093
2020-03-27non-exhastive diagnostic: add note re. scrutinee typeMazdak Farrokhzad-0/+12
2020-03-27Auto merge of #68404 - Amanieu:llvm-asm, r=estebankbors-34/+34
Rename asm! to llvm_asm! As per https://github.com/rust-lang/rfcs/pull/2843, this PR renames `asm!` to `llvm_asm!`. It also renames the compiler's internal `InlineAsm` data structures to `LlvmInlineAsm` in preparation for the new `asm!` functionality specified in https://github.com/rust-lang/rfcs/pull/2850. This PR doesn't actually deprecate `asm!` yet, it just makes it redirect to `llvm_asm!`. This is necessary because we first need to update the submodules (in particular stdarch) to use `llvm_asm!`.
2020-03-27Rollup merge of #70435 - Alexendoo:test-66706, r=CentrilDylan DPC-0/+45
Add regression test for #66706 Adds the two cases that no longer ICE (https://github.com/rust-lang/rust/issues/66706#issuecomment-604098436)
2020-03-27Rollup merge of #69936 - Aaron1011:fix/suggestion-cycle, r=varkorDylan DPC-0/+71
Fix cycle error when emitting suggestion for mismatched `fn` type Fixes #66667 Previously, we called `tcx.typeck_tables_of` when determining whether or not to emit a suggestion for a type error. However, we might already be type-checking the `DefId` we pass to `typeck_tables_of` (it could be anywhere in the query stack). Fortunately, we only need the function signature, not the entire `TypeckTables`. By using `tcx.fn_sig`, we avoid the possibility of cycle errors while retaining the ability to emit a suggestion.
2020-03-26Add regression test for #66706Alex Macleod-0/+45
2020-03-26Update tests to use llvm_asm!Amanieu d'Antras-34/+34
2020-03-26introduce `negative_impls` feature gate and documentNiko Matsakis-4/+7
They used to be covered by `optin_builtin_traits` but negative impls are now applicable to all traits, not just auto traits. This also adds docs in the unstable book for the current state of auto traits.
2020-03-26make a custom error for overlap with negative implsNiko Matsakis-31/+22
2020-03-24Rollup merge of #70077 - Aaron1011:feature/new-def-path-ident, r=petrochenkovMazdak Farrokhzad-2/+28
Store idents for `DefPathData` into crate metadata Previously, we threw away the `Span` associated with a definition's identifier when we encoded crate metadata, causing us to lose location and hygiene information. We now store the identifier's `Span` in a side table, which gets encoded into the crate metadata. When we decode items from the metadata, we combine the name and span back into an `Ident`. This improves the output of several tests, which previously had messages suppressed due to dummy spans. This is a prerequisite for #68686, since throwing away a `Span` means that we lose hygiene information.
2020-03-24Rollup merge of #69981 - oli-obk:const_blocks, r=eddybMazdak Farrokhzad-12/+28
Evaluate repeat expression lengths as late as possible Fixes #68567 r? @varkor
2020-03-24Rollup merge of #69740 - mark-i-m:describe-it-3, r=eddybMazdak Farrokhzad-2/+2
Replace some desc logic in librustc_lint with article_and_desc r? @eddyb @Centril @matthewjasper Followup to https://github.com/rust-lang/rust/pull/69674 Blocked on #69498
2020-03-23Rollup merge of #70300 - aleksator:66636_reword_unused_variable_warning, ↵Mazdak Farrokhzad-9/+9
r=Dylan-DPC Reword unused variable warning Fixes #66636
2020-03-23Rollup merge of #70195 - rylev:test-for-53275, r=CentrilMazdak Farrokhzad-0/+9
Add test for issue #53275 Fixes #53275
2020-03-23Evaluate repeat expression lengths as late as possibleOliver Scherer-12/+28
2020-03-23Make sure issue 53275 test goes through codegenRyan Levick-1/+2
2020-03-23Rollup merge of #69968 - eddyb:tupled-closure-captures, r=nikomatsakisMazdak Farrokhzad-1/+1
rustc: keep upvars tupled in {Closure,Generator}Substs. Previously, each closure/generator capture's (aka "upvar") type was tracked as one "synthetic" type parameter in the closure/generator substs, and figuring out where the parent `fn`'s generics end and the synthetics start involved slicing at `tcx.generics_of(def_id).parent_count`. Needing to query `generics_of` limited @davidtwco (who wants to compute some `TypeFlags` differently for parent generics vs upvars, and `TyCtxt` is not available there), which is how I got started on this, but it's also possible that the `generics_of` queries are slowing down `{Closure,Generator}Substs` methods. To give an example, for a `foo::<T, U>::{closure#0}` with captures `x: X` and `y: Y`, substs are: * before this PR: `[T, U, /*kind*/, /*signature*/, X, Y]` * after this PR: `[T, U, /*kind*/, /*signature*/, (X, Y)]` You can see that, with this PR, no matter how many captures, the last 3 entries in the substs (or 5 for a generator) are always the "synthetic" ones, with the last one being the tuple of capture types. r? @nikomatsakis cc @Zoxc
2020-03-23Rollup merge of #69942 - estebank:sized-verbose-sugg, r=matthewjasperMazdak Farrokhzad-50/+55
Increase verbosity when suggesting subtle code changes Do not suggest changes that are actually quite small inline, to minimize the likelihood of confusion. Fix #69243.
2020-03-23Reword unused variable warningAlex Tokarev-9/+9
2020-03-23Ignore tests on some platforms due to #53081Aaron Hill-2/+12
2020-03-22Store idents for `DefPathData` into crate metadataAaron Hill-0/+16
Previously, we threw away the `Span` associated with a definition's identifier when we encoded crate metadata, causing us to lose location and hygiene information. We now store the identifier's `Span` in the crate metadata. When we decode items from the metadata, we combine the name and span back into an `Ident`. This improves the output of several tests, which previously had messages suppressed due to dummy spans. This is a prerequisite for #68686, since throwing away a `Span` means that we lose hygiene information.
2020-03-23Rollup merge of #70227 - LeSeulArtichaut:typo-def, r=CentrilMazdak Farrokhzad-6/+5
Only display definition when suggesting a typo Closes #70206 r? @Centril
2020-03-22Use more targetted span for error labelEsteban Küber-4/+4
2020-03-22Normalize wording of privacy access labelsEsteban Küber-18/+18
2020-03-22the crate and testsmark-2/+2
2020-03-22Add span label to primary error spanEsteban Küber-24/+19
2020-03-22Increase verbosity when suggesting subtle code changesEsteban Küber-8/+18
2020-03-21Allow `hir().find` to return `None`John Kåre Alsaker-0/+32
2020-03-21Bless testsLeSeulArtichaut-6/+5
2020-03-21rustc: keep upvars tupled in {Closure,Generator}Substs.Eduard-Mihai Burtescu-1/+1
2020-03-21Rollup merge of #70176 - rylev:ice-tests, r=CentrilMazdak Farrokhzad-0/+651
Add tests for #58319 and #65131 Fixes #58319 and fixes #65131
2020-03-20Auto merge of #69509 - RalfJung:debug-assert-write, r=eddybbors-3/+4
debug-assert ptr sanity in ptr::write This is a re-submission of the parts that we removed from https://github.com/rust-lang/rust/pull/69208 due to ["interesting" test failures](https://github.com/rust-lang/rust/pull/69208#issuecomment-591310437). Fixes https://github.com/rust-lang/rust/issues/53871 r? @Mark-Simulacrum @eddyb
2020-03-20Add test for issue #53275Ryan Levick-0/+8
2020-03-20Add tests for #58319 and #65131Ryan Levick-0/+651
2020-03-18increase stack slack for x86_64-pc-windows-gnuRalf Jung-3/+4
2020-03-17Update tests for erasing regions in typeckMatthew Jasper-2/+2
2020-03-16Rollup merge of #69995 - contrun:add-context-to-literal-overflow, ↵Dylan DPC-0/+1
r=ecstatic-morse Add more context to the literal overflow message related to issue https://github.com/rust-lang/rust/issues/63733