about summary refs log tree commit diff
path: root/src/test/ui
AgeCommit message (Collapse)AuthorLines
2022-10-20Add ui test to ensure attributes generated from macros are kept as expectedGuillaume Gomez-0/+35
2022-10-20Change process spawning to inherit the parent's signal mask by defaultRain-2/+4
Previously, the signal mask is always reset when a child process is started. This breaks tools like `nohup` which expect `SIGHUP` to be blocked. With this change, the default behavior changes to inherit the signal mask. This also changes the signal disposition for `SIGPIPE` to only be changed if the `#[unix_sigpipe]` attribute isn't set.
2022-10-20Rollup merge of #103319 - fee1-dead-contrib:improve_tilde_const_msg, r=oli-obkMatthias Krüger-5/+42
Improve "`~const` is not allowed here" message r? `@oli-obk`
2022-10-20Rollup merge of #103281 - thomcc:long-overdue, r=jyn514Matthias Krüger-3/+3
Adjust `transmute{,_copy}` to be clearer about which of `T` and `U` is input vs output This is essentially a documentation-only change (although it does touch code in an irrelevant way).
2022-10-20Rollup merge of #103221 - TaKO8Ki:fix-103202, r=oli-obkMatthias Krüger-0/+16
Fix `SelfVisitor::is_self_ty` ICE Fixes #103202
2022-10-20Improve "`~const` is not allowed here" messageDeadbeef-5/+42
2022-10-20Elaborate supertrait bounds when triggering unused_must_use on impl TraitMichael Goulet-0/+26
2022-10-20Update tests to match error message changesb4den-126/+126
2022-10-20fix rust-lang#101880: suggest let for assignment, and some code refactoryukang-0/+94
2022-10-20Move some tests for more reasonable placesCaio-0/+0
2022-10-20Auto merge of #103290 - matthiaskrgr:rollup-ngozai3, r=matthiaskrgrbors-1/+55
Rollup of 6 pull requests Successful merges: - #103197 (Stabilize proc_macro::Span::source_text) - #103251 (Fix item declaration highlighting) - #103262 (Adjusting test to needs-unwind, with linking issue) - #103268 (rustdoc: remove no-op CSS `nav.sub { font-size: 1rem }`) - #103272 (Remove extra spaces in docs) - #103276 (Erase regions before checking for `Default` in uninitialized binding error) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2022-10-20fix assertion failed for break_last_token and trailing tokenyukang-0/+25
2022-10-20Rollup merge of #103276 - compiler-errors:default-on-uninit-ice, r=TaKO8KiMatthias Krüger-0/+54
Erase regions before checking for `Default` in uninitialized binding error Fixes #103250
2022-10-20Rollup merge of #103262 - andrewpollack:switch-needs-unwind, r=tmandryMatthias Krüger-1/+1
Adjusting test to needs-unwind, with linking issue Test requires `needs-unwind` (see linked issue #103261)
2022-10-20Auto merge of #103220 - compiler-errors:deny-infers, r=lcnrbors-22/+22
Deny hashing ty/re/ct inference variables cc `@cjgillot` and https://github.com/rust-lang/rust/pull/102695#issuecomment-1275706528 r? `@lcnr` best reviewed one commit at a time, mostly because the second commit that fixes `ClosureOutlivesRequirement` is mostly noise because of losing its `<'tcx>` lifetime parameter.
2022-10-19Adjust `transmute{,_copy}` to be clearer about which of `T` and `U` is input ↵Thom Chiovoloni-3/+3
vs output
2022-10-20Bless testMichael Goulet-3/+19
2022-10-20fix span for suggestionyukang-2/+3
2022-10-20fix #103112, add diagnostic for calling a function with the same name when a ↵yukang-0/+18
Macro is not found
2022-10-20Auto merge of #103205 - spastorino:fix-rpits-lifetime-remapping, r=cjgillotbors-0/+23
Do anonymous lifetimes remapping correctly for nested rpits Closes #103141 r? `@cjgillot` `@nikomatsakis` This fixes a stable to stable regression that in my opinion is `P-critical` so, we probably want to backport it all the way up to stable.
2022-10-19Bless ui testsRyan Lopopolo-2/+2
2022-10-20Adjusting test to needs-unwind, with linking issueAndrew Pollack-1/+1
2022-10-20Auto merge of #102417 - oli-obk:opaque_lifetimes2, r=jackh726bors-25/+65
Require lifetime bounds for opaque types in order to allow hidden types to capture said lifetimes fixes #96996 cc `@aliemjay`
2022-10-19Erase regions before checking for default in uninitialized binding errorMichael Goulet-0/+54
2022-10-19Do anonymous lifetimes remapping correctly for nested rpitsSantiago Pastorino-0/+23
2022-10-19Rollup merge of #103239 - m-ou-se:unstable-abi-fn-impl-check, r=lcnrMatthias Krüger-5/+27
Allow #[unstable] impls for fn() with unstable abi. This allows `#[unstable]` trait impls for `extern "unwind-C" fn()`, based on the fact that that abi and therefore that type is unstable. See https://github.com/rust-lang/rust/pull/101263#issuecomment-1283099947
2022-10-19Rollup merge of #103223 - compiler-errors:deref-sugg-slow, r=wesleywiserMatthias Krüger-0/+213
Use already checked RHS ty for LHS deref suggestions There's no reason to do the `check_lhs_assignable` and RHS `check_expr_with_hint` in that order, so invert them and use the typeck results to avoid exponential blowup on error. Fixes #103219
2022-10-19Fixup a few tests needing asm supportJosh Stone-14/+3
2022-10-19Make ClosureOutlivesRequirement not rely on an unresolved typeMichael Goulet-22/+22
2022-10-19resolve: Revert "Set effective visibilities for imports more precisely"Vadim Petrochenkov-1/+8
2022-10-19Allow #[unstable] impl for fn() -> UnstableType.Mara Bos-0/+3
(But not fn() -> !, which is stable.)
2022-10-19Add test for #[unstable] impl for fn() -> !.Mara Bos-1/+13
2022-10-19Auto merge of #103228 - Dylan-DPC:rollup-31yiauw, r=Dylan-DPCbors-44/+135
Rollup of 6 pull requests Successful merges: - #102863 (Standardize "use parentheses to call" suggestions between typeck and trait selection) - #103034 (Let expressions on RHS shouldn't be terminating scopes) - #103127 (Make transpose const and inline) - #103153 (Allow `Vec::leak` when using `no_global_oom_handling`) - #103182 (Clean up query descriptions) - #103216 (Consider patterns in fn params in an `Elided(Infer)` lifetime rib.) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2022-10-19Add test.Mara Bos-4/+11
2022-10-19Rollup merge of #103216 - cjgillot:issue-103210, r=jackh726Dylan DPC-0/+11
Consider patterns in fn params in an `Elided(Infer)` lifetime rib. Fixes https://github.com/rust-lang/rust/issues/103210
2022-10-19Rollup merge of #103182 - Nilstrieb:query-desc-cleanup, r=oli-obkDylan DPC-12/+12
Clean up query descriptions Use the same tense everywhere and prefer display over debug, as these descriptions are user facing.
2022-10-19Rollup merge of #103034 - nathanwhit:let-chains-rhs-temporaries, r=wesleywiserDylan DPC-6/+18
Let expressions on RHS shouldn't be terminating scopes Fixes #100276. Before this PR, we were unconditionally marking the RHS of short-circuiting binary expressions as a terminating scope. In the case of a let chain where the `let` expression was on the RHS, this meant that temporaries within the `let` expr would only live until the end of the expression. Since this only affected the RHS, this led to surprising behavior ([example](https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=d1b0a5d1f01882f9c89c2194a75eb19f)). After this PR, we only mark the RHS as a terminating scope if it is not a `let` expression.
2022-10-19Rollup merge of #102863 - compiler-errors:call-suggestion-on-unimplemented, ↵Dylan DPC-26/+94
r=nagisa Standardize "use parentheses to call" suggestions between typeck and trait selection 1. Suggest calling constructors, since they're basically `FnDef`s but they have a different def kind and hir representation, so we were leaving them out. 2. Standardize the call suggestions between trait fulfillment errors and type mismatch. In the type mismatch suggestion, we suggest `/* Ty */` as the placeholder for an arg, and not the parameter's name, which is less helpful. 3. Use `predicate_must_hold_modulo_regions` instead of matching on `EvaluationResult` -- this might cause some suggestions to be filtered out, but we really shouldn't be suggesting a call if it "may" hold, only when it "must" hold. 4. Borrow some logic from `extract_callable_info` to generalize this suggestion to fn pointers, type parameters, and opaque types. Fixes #102852
2022-10-19Auto merge of #103180 - ferrocene:pa-qemu-user-mode, r=Mark-Simulacrumbors-4/+18
Handle core dumps output in QEMU user mode In addition to the whole-system emulation/virtualization, QEMU also supports user-mode emulation, where the emulation happens as a normal process inside the parent system. This allows running most tests by simply spawning remote-test-server inside user-mode emulation. Unfortunately, QEMU always writes its own message in addition to the system one when a core dump happens, which breaks a few tests which match on the exact output of the system. This PR changes those tests to strip the (possible) QEMU output before checking if the output is expected.
2022-10-19Rollup merge of #103176 - nnethercote:fix-TyKind-is_simple_path, r=spastorinoMatthias Krüger-3/+49
Fix `TyKind::is_simple_path` Fixes #103157. r? `@spastorino`
2022-10-19Use already checked RHS ty for LHS deref suggestionsMichael Goulet-0/+213
2022-10-19instantiate -> constructMichael Goulet-12/+12
2022-10-19fix `SelfVisitor::is_self_ty` ICETakayuki Maeda-0/+16
2022-10-19Generalize call suggestion for unsatisfied predicateMichael Goulet-21/+48
2022-10-19Standardize arg suggestions between typeck and trait selectionMichael Goulet-3/+3
2022-10-19Suggest calling ctor when trait is unimplementedMichael Goulet-0/+41
2022-10-19Implement -Ztrack-diagnosticsmejrs-0/+32
2022-10-18Consider patterns in fn params in an `Elided(Infer)` lifetime rib.Camille GILLOT-0/+11
2022-10-18Clean up query descriptionsnils-12/+12
Use the same tense everywhere and prefer display over debug, as these descriptions are user facing.
2022-10-18`const_evaluatable_unchecked` to const evallcnr-20/+24