about summary refs log tree commit diff
path: root/src/test
AgeCommit message (Collapse)AuthorLines
2019-04-16Auto merge of #59769 - RalfJung:compiletest-normalization, r=alexcrichtonbors-8/+89
compiletest normalization: preserve non-JSON lines such as ICEs Currently, every non-JSON line from stderr gets normalized away when compiletest normalizes the output. In particular, ICEs get normalized to the empty output. That does not seem desirable, so this changes normalization to preserve non-JSON lines instead. Also see https://github.com/laumann/compiletest-rs/issues/169: because of that bug, Miri currently *looks* green in the toolstate, but some tests ICE. That same bug is likely no longer present in latest compiletest because the error code gets checked separately, but it still seems like a good idea to also make sure that ICEs are considered stderr output: This change found an accidental user-visible `error!` in CTFE validation (fixed), and a non-deterministic panic when there are two `main` symbols (not fixed, no idea where this comes from). Both got missed before because non-JSON output got ignored.
2019-04-16this panic occurs not just on Windows, normalize it away everywhereRalf Jung-6/+6
2019-04-16Rollup merge of #59993 - euclio:unused-ref-field, r=estebankMazdak Farrokhzad-0/+107
include mode in unused binding suggestion span Fixes #54180.
2019-04-16Rollup merge of #59992 - QuietMisdreavus:static-settings-path, r=GuillaumeGomezMazdak Farrokhzad-0/+4
rustdoc: use --static-root-path for settings.js At the time i was writing https://github.com/rust-lang/docs.rs/pull/332, i noticed that the `settings.js` file that was being loaded was not being loaded from the `--static-root-path`. This PR fixes that so that users on docs.rs can effectively cache this file.
2019-04-16Rollup merge of #59903 - estebank:after-main, r=oli-obkMazdak Farrokhzad-0/+49
Continue evaluating after missing main
2019-04-15normalize away some Windows-only panic printingRalf Jung-3/+15
2019-04-15include mode in unused binding suggestion spanAndy Russell-0/+107
2019-04-15Rollup merge of #59978 - ollie27:rustdoc_default, r=QuietMisdreavusMazdak Farrokhzad-15/+62
rustdoc: Remove default keyword from re-exported trait methods Fixes #59977 r? @QuietMisdreavus As this fixes a stable to beta regression, could it be backported?
2019-04-15Rollup merge of #59648 - alex:must-use-result, r=alexcrichtonMazdak Farrokhzad-1/+1
Add must_use annotations to Result::is_ok and is_err Discussed in #59610
2019-04-15use --static-root-path for settings.jsQuietMisdreavus-0/+4
2019-04-15Update testJohn Kåre Alsaker-182/+186
2019-04-15Preallocate BUILTIN_ATTRIBUTES symbols and use a hash map instead of loopingJohn Kåre Alsaker-2/+2
2019-04-14rustdoc: Remove default keyword from re-exported trait methodsOliver Middleton-15/+62
2019-04-14Auto merge of #59335 - Aaron1011:fix/extern-priv-final, r=Aaron1011bors-1/+1
Properly parse '--extern-private' with name and path It turns out that https://github.com/rust-lang/rust/pull/57586 didn't properly parse `--extern-private name=path`. This PR properly implements the `--extern-private` option. I've added a new `extern-private` option to `compiletest`, which causes an `--extern-private` option to be passed to the compiler with the proper path. Part of https://github.com/rust-lang/rust/issues/44663
2019-04-14Rollup merge of #59936 - petrochenkov:confict, r=davidtwcoMazdak Farrokhzad-0/+12
Fix cross-crate visibility of fictive variant constructors After merging https://github.com/rust-lang/rust/pull/59376 I realized that the code in the decoder wasn't entirely correct - we "decoded" fictive variant constructors with their variant's visibility, which could be public, rather than demoted to `pub(crate)`. Fictive constructors are not directly usable in expression/patterns, but the effect still can be observed with imports. r? @davidtwco
2019-04-14Rollup merge of #59896 - estebank:dedup-spans, r=davidtwcoMazdak Farrokhzad-0/+27
Remove duplicated redundant spans Fix #59895.
2019-04-14Rollup merge of #59877 - Zoxc:hiridify_def_id, r=eddybMazdak Farrokhzad-3/+3
HirIdify hir::Def cc @ljedrz r? @oli-obk
2019-04-14Address review commentsVadim Petrochenkov-0/+3
2019-04-14Fix cross-crate visibility of fictive variant constructorsVadim Petrochenkov-0/+9
2019-04-14huge-enum also exhibits this errorRalf Jung-0/+4
2019-04-14some more tests need normalizationRalf Jung-0/+12
2019-04-14normalize away spurious errorRalf Jung-3/+27
2019-04-14normalize flags and rustc version in ICE reproRalf Jung-2/+4
2019-04-14fix output test for backtrace-debuginfo.rsRalf Jung-2/+4
2019-04-14fix testsRalf Jung-0/+25
2019-04-14Update testsJohn Kåre Alsaker-3/+3
2019-04-14Auto merge of #59798 - rchaser53:issue-59488, r=estebankbors-0/+115
Improvement for comparision against fn I try to add error message. related: https://github.com/rust-lang/rust/issues/59488
2019-04-14Properly parse '--extern-private' with name and pathAaron Hill-1/+1
2019-04-14Auto merge of #59950 - Centril:rollup-hpmr62i, r=Centrilbors-8/+411
Rollup of 6 pull requests Successful merges: - #59776 (Apply resource-suffix to search-index and source-files scripts as well) - #59784 (Suggest importing macros from the crate root) - #59812 (Exclude profiler-generated symbols from MSVC __imp_-symbol workaround.) - #59874 (Clean up handling of `-Z pgo-gen` commandline option.) - #59890 (Don't generate empty json variables) - #59911 (Revert "compile crates under test w/ -Zemit-stack-sizes") Failed merges: r? @ghost
2019-04-14Rollup merge of #59874 - michaelwoerister:pgo-updates-1, r=cramertjMazdak Farrokhzad-8/+4
Clean up handling of `-Z pgo-gen` commandline option. This PR adapts the `-Z pgo-gen` flag to how Clang and GCC handle the corresponding `-fprofile-generate` flag. In particular, the flag now optionally takes a directory to place the profiling data in and allows to omit the argument (instead of having to pass an empty string).
2019-04-14Rollup merge of #59812 - michaelwoerister:profile-gen-msvc-imp, r=alexcrichtonMazdak Farrokhzad-0/+12
Exclude profiler-generated symbols from MSVC __imp_-symbol workaround. LLVM's profiling instrumentation adds a few symbols that are used by the profiler runtime. Since these show up as globals in the LLVM IR, the compiler generates `dllimport`-related `__imp_` stubs for them. This can lead to linker errors because the instrumentation symbols have weak linkage or are in a comdat section, but the `__imp_` stubs aren't. Instead of trying to replicate the linkage/comdat setup for the stubs, this PR just excludes the profiler-related symbols from stub-generation since they aren't supposed to be referenced via `__declspec(dllimport)` anywhere anyway. r? @alexcrichton EDIT: I considered making this more general, i.e. inferring from the symbol name if it is a Rust symbol or not. But then I figured out that that would yield false negatives for `#[no_mangle]` et al, so I went with a blacklist approach.
2019-04-14Rollup merge of #59784 - davidtwco:issue-59764, r=estebankMazdak Farrokhzad-0/+395
Suggest importing macros from the crate root Fixes #59764. r? @estebank cc @varkor
2019-04-14Rollup merge of #59899 - nnethercote:sort-enum-variants-by-size, r=pnkfelixMazdak Farrokhzad-25/+25
In `-Zprint-type-size` output, sort enum variants by size. It's useful to see the biggest variants first. r? @pnkfelix
2019-04-14Rollup merge of #59858 - mark-i-m:dup-matcher-bindings-3, r=CentrilMazdak Farrokhzad-33/+37
Make duplicate matcher bindings a hard error r? @Centril Closes #57742
2019-04-14Rollup merge of #59835 - lzutao:nonzero-signed, r=Mark-SimulacrumMazdak Farrokhzad-1/+1
Re-export NonZero signed variant in std Closes #59834 .
2019-04-14Rollup merge of #59708 - matthewjasper:double-closure-unused-mut, r=pnkfelixMazdak Farrokhzad-8/+11
Mark variables captured by reference as mutable correctly Closes #59620 r? @pnkfelix
2019-04-14Rollup merge of #59675 - SimonSapin:stable-alloc, r=alexcrichtonMazdak Farrokhzad-32/+22
Stabilize the `alloc` crate. This implements RFC 2480: * https://github.com/rust-lang/rfcs/pull/2480 * https://github.com/rust-lang/rfcs/blob/master/text/2480-liballoc.md Closes https://github.com/rust-lang/rust/issues/27783
2019-04-13Auto merge of #59922 - Centril:rollup-0qmx4jg, r=Centrilbors-486/+992
Rollup of 8 pull requests Successful merges: - #59781 (Remove check_match from const_eval) - #59820 (proc_macro: stop using LEB128 for RPC.) - #59846 (clarify what the item is in "not a module" error) - #59847 (Error when using `catch` after `try`) - #59859 (Suggest removing `?` to resolve type errors.) - #59862 (Tweak unstable diagnostic output) - #59866 (Recover from missing semicolon based on the found token) - #59892 (Impl RawFd conversion traits for WASI TcpListener, TcpStream and UdpSocket) Failed merges: r? @ghost
2019-04-12Add test and fix dedupEsteban Küber-0/+27
2019-04-12Rollup merge of #59866 - estebank:recover-missing-semi, r=petrochenkovMazdak Farrokhzad-0/+52
Recover from missing semicolon based on the found token When encountering one of a few keywords when a semicolon was expected, suggest the semicolon and recover: ``` error: expected one of `.`, `;`, `?`, or an operator, found `let` --> $DIR/recover-missing-semi.rs:4:5 | LL | let _: usize = () | - help: missing semicolon here LL | LL | let _ = 3; | ^^^ error[E0308]: mismatched types --> $DIR/recover-missing-semi.rs:2:20 | LL | let _: usize = () | ^^ expected usize, found () | = note: expected type `usize` found type `()` ```
2019-04-12Rollup merge of #59862 - estebank:tweak-unstable-diag, r=petrochenkovMazdak Farrokhzad-423/+802
Tweak unstable diagnostic output
2019-04-12Rollup merge of #59859 - davidtwco:issue-59756, r=cramertjMazdak Farrokhzad-1/+53
Suggest removing `?` to resolve type errors. Fixes #59756.
2019-04-12Rollup merge of #59847 - Kampfkarren:try-block-catch, r=estebankMazdak Farrokhzad-0/+20
Error when using `catch` after `try` Part of https://github.com/rust-lang/rust/issues/31436
2019-04-12Rollup merge of #59846 - euclio:not-a-module, r=davidtwcoMazdak Farrokhzad-50/+62
clarify what the item is in "not a module" error The motivation here was that I was trying to import an associated constant when I thought it was an enum variant, and got confused by this error. Ideally I would like to add a note saying that associated constants, types, and methods cannot be imported, but I'm not sure that the associated items for a `Def` can be checked at resolve time.
2019-04-12Rollup merge of #59781 - whitfin:issue-59378, r=oli-obkMazdak Farrokhzad-12/+3
Remove check_match from const_eval This fixes #59378. It seems that the `check_match` may be unnecessary, so this removes it per instructions provided in the issue. I re-ran the tests for `librustc_mir` and everything seemed fine!
2019-04-12Stabilize the `alloc` crate.Simon Sapin-32/+22
This implements RFC 2480: * https://github.com/rust-lang/rfcs/pull/2480 * https://github.com/rust-lang/rfcs/blob/master/text/2480-liballoc.md Closes https://github.com/rust-lang/rust/issues/27783
2019-04-12Auto merge of #59733 - cramertj:wake-by-ref, r=withoutboatsbors-13/+29
Final (one can only hope) futures_api adjustments Based on https://github.com/rust-lang/rust/pull/59119 -- this change is only the latter two commits. cc https://github.com/rust-lang/rust/issues/59725 r? @withoutboats
2019-04-12add the logic for when other_ty is FnDefrchaser53-3/+55
2019-04-12Auto merge of #59910 - Centril:rollup-yjv7b06, r=Centrilbors-68/+204
Rollup of 15 pull requests Successful merges: - #59680 (Document the -Z flag to the rustc book) - #59711 (Add back the substring test) - #59806 (compiletest: Improve no_prefer_dynamic docs) - #59809 (Make trait_methods_not_found use a lock) - #59811 (Kill dead code dominator code.) - #59814 (Fix broken links on std::boxed doc page) - #59821 (improve unknown enum variant errors) - #59831 (Remove strange formatting in `Ordering` docs.) - #59836 (std::ops::Div examples: correct nominator to numerator) - #59857 (SGX target: fix cfg(test) build) - #59876 (Update TRPL to use mdbook 0.2) - #59880 (Remove note about transmute for float bitpatterns.) - #59889 (Update diagnostics.rs) - #59891 (Fix the link to sort_by_cached_key) - #59894 (save-analysis: Pull associated type definition using `qpath_def`) Failed merges: r? @ghost
2019-04-12Rollup merge of #59821 - euclio:unknown-enum-variants, r=davidtwcoMazdak Farrokhzad-68/+175
improve unknown enum variant errors Fixes #56517.