about summary refs log tree commit diff
path: root/tests
AgeCommit message (Collapse)AuthorLines
2023-04-28fix codegen testThe 8472-3/+6
2023-04-27bless testsThe 8472-87/+71
2023-04-27don't promote large fields to higher alignments if that would affect niche ↵The 8472-0/+18
placement
2023-04-27try two different niche-placement strategies when layouting univariant structsThe 8472-1/+29
2023-04-27Rollup merge of #110866 - compiler-errors:test, r=jyn514Matthias Krüger-5/+5
Make `method-not-found-generic-arg-elision.rs` error message not path dependent Every time I bless `tests/ui/methods/method-not-found-generic-arg-elision.rs`, I get some nonsense "type is too long" + "written to disk" that shows up and have to manually revert because the combination of my rustc repo path + the UI test directory hits the length limit for printing types spilling to disk (since this happens before UI test path sanitization). The fact that we use a closure in this test doesn't have to do with the UI test, so just box the closure to make the type name smaller and not path dependent.
2023-04-27Rollup merge of #110864 - compiler-errors:into-future-stable, r=jackh726Matthias Krüger-1/+1
`IntoFuture::into_future` is no longer unstable We don't need to gate the `IntoFuture::into_future` call in `.await` lowering anymore. ``@bors`` rollup
2023-04-27Rollup merge of #110816 - clubby789:rustc-passes-diagnostics, r=compiler-errorsMatthias Krüger-5/+5
Migrate `rustc_passes` to translatable diagnostics cc #100717
2023-04-27Rollup merge of #110804 - cuishuang:master, r=jyn514Matthias Krüger-2/+2
Remove repeated definite articles
2023-04-26IntoFuture::into_future is no longer unstableMichael Goulet-1/+1
2023-04-26Auto merge of #110861 - m-ou-se:thread-local-restructure, r=workingjubileebors-12/+10
Restructure and rename std thread_local internals to make it less of a maze Every time I try to work on std's thread local internals, it feels like I'm trying to navigate a confusing maze made of macros, deeply nested modules, and types with multiple names/aliases. Time to clean it up a bit. This PR: - Exports `Key` with its own name (`Key`), instead of `__LocalKeyInner` - Uses `pub macro` to put `__thread_local_inner` into a (unstable, hidden) module, removing `#[macro_export]`, removing it from the crate root. - Removes the `__` from `__thread_local_inner`. - Removes a few unnecessary `allow_internal_unstable` features from the macros - Removes the `libstd_thread_internals` feature. (Merged with `thread_local_internals`.) - And removes it from the unstable book - Gets rid of the deeply nested modules for the `Key` definitions (`mod fast` / `mod os` / `mod statik`). - Turns a `#[cfg]` mess into a single `cfg_if`, now that there's no `#[macro_export]` anymore that breaks with `cfg_if`. - Simplifies the `cfg_if` conditions to not repeat the conditions. - Removes useless `normalize-stderr-test`, which were left over from when the `Key` types had different names on different platforms. - Removes a seemingly unnecessary `realstd` re-export on `cfg(test)`. This PR changes nothing about the thread local implementation. That's for a later PR. (Which should hopefully be easier once all this stuff is a bit cleaned up.)
2023-04-26Make method-not-found-generic-arg-elision.rs error message not path dependentMichael Goulet-5/+5
2023-04-26Update tests.Mara Bos-12/+10
2023-04-26Auto merge of #110852 - matthiaskrgr:rollup-jz3eosr, r=matthiaskrgrbors-2/+51
Rollup of 10 pull requests Successful merges: - #108760 (Add lint to deny diagnostics composed of static strings) - #109444 (Change tidy error message for TODOs) - #110419 (Spelling library) - #110550 (Suggest deref on comparison binop RHS even if type is not Copy) - #110641 (Add new rustdoc book chapter to describe in-doc settings) - #110798 (pass `unused_extern_crates` in `librustdoc::doctest::make_test`) - #110819 (simplify TrustedLen impls) - #110825 (diagnostics: add test case for already-solved issue) - #110835 (Make some region folders a little stricter.) - #110847 (rustdoc-json: Time serialization.) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2023-04-26Rollup merge of #110825 - notriddle:notriddle/issue-70082, r=compiler-errorsMatthias Krüger-0/+27
diagnostics: add test case for already-solved issue Fixes #70082
2023-04-26Rollup merge of #110798 - ozkanonur:rustdoc-unused-extern-crates, r=jyn514Matthias Krüger-1/+1
pass `unused_extern_crates` in `librustdoc::doctest::make_test` blocker for https://github.com/rust-lang/rust/pull/106621
2023-04-26Rollup merge of #110550 - compiler-errors:deref-on-binop-rhs, r=wesleywiserMatthias Krüger-1/+23
Suggest deref on comparison binop RHS even if type is not Copy Fixes #110500
2023-04-27Remove repeated definite articlescui fliter-2/+2
Signed-off-by: cui fliter <imcusg@gmail.com>
2023-04-26Auto merge of #110822 - scottmcm:lower-offset-to-mir, r=compiler-errorsbors-0/+35
Lower `intrinsics::offset` to `mir::BinOp::Offset` They're [semantically the same](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_middle/mir/enum.Rvalue.html#variant.BinaryOp), so this means the backends don't need to handle the intrinsic and means fewer MIR basic blocks in pointer arithmetic code.
2023-04-26Migrate `rustc_passes` to translatable diagnosticsclubby789-5/+5
2023-04-26Rollup merge of #110817 - fmease:fix-109759, r=compiler-errorsjyn-0/+51
Add regression tests for const-generic inherent associated types Fixes #109759. The tests are no longer failing since #96840 which was merged recently (#109410 is no longer necessary for them). `@rustbot` label F-inherent_associated_types
2023-04-26Rollup merge of #110329 - aDotInTheVoid:json-inline-again, r=jyn514jyn-11/+26
Improve tests for #110138 These should live in rustdoc-json, not rustdoc-ui, so we can run assertions, and not just check there's no ICE CC #100515, as we never document this suite r? rustdoc
2023-04-26Rollup merge of #109379 - flba-eb:108596_fixtest_sigpipe, r=jyn514jyn-3/+7
Replace `yes` command by `while-echo` in test `tests/ui/process/process-sigpipe.rs` The `yes` command is not available on all platforms. Fixes #108596. Inviting `@mvf` as he contributed to this patch. Thanks! This issue has been discussed in https://github.com/rust-lang/rust/pull/106673 but was moved to #108596 to get going. CC `@gh-tr` r? `@workingjubilee` `@rustbot` label +O-neutrino Notes about the comments https://github.com/rust-lang/rust/pull/106673#discussion_r1117324265: - The `echo` command is `/proc/boot/echo` (not built-in) - `/bin/sh` is a symlink to `/proc/boot/ksh` ```sh # ls -l /bin/sh /proc/boot/ksh /proc/boot/echo lrwxrwxrwx 1 root root 14 Mar 20 07:52 /bin/sh -> /proc/boot/ksh -r-xr-xr-x 1 root root 9390 Sep 12 2022 /proc/boot/echo -r-xr-xr-x 1 root root 308114 Sep 12 2022 /proc/boot/ksh ```
2023-04-25Lower `intrinsics::offset` to `mir::BinOp::Offset`Scott McMurray-0/+35
They're semantically the same, so this means the backends don't need to handle the intrinsic and means fewer MIR basic blocks in pointer arithmetic code.
2023-04-25Auto merge of #110811 - compiler-errors:vars-are-question-mark, r=WaffleLapkinbors-302/+302
Use `?0` notation for ty/ct/int/float/region vars Aligns the notation for infer vars that T-types and friends most often uses for inference variables with the notation in the compiler (which is kinda a sigil nightmare IMO: `_#`) by adopting `?0` style infer vars. This mostly affects debug output since verbose infer vars shouldn't show up in user-facing places. Does this need an MCP? It's debug output, so I'm thinking no, but happy to open one. :thinking: r? types
2023-04-25Add regression tests for const-generic IATsLeón Orell Valerian Liehr-0/+51
2023-04-25diagnostics: add test case for already-solved issueMichael Howell-0/+27
Fixes #70082
2023-04-25vars are ?Michael Goulet-302/+302
2023-04-25Rollup merge of #110671 - compiler-errors:polarity, r=lcnrMatthias Krüger-0/+52
Consider polarity in new solver It's kinda ugly to have a polarity check in all of the builtin impls -- I guess I could consider the polarity at the top of assemble-builtin but that would require adding a polarity fn to `GoalKind`... :shrug: putting this up just so i dont forget, since it's needed to bootstrap core during coherence (this alone does not allow core to bootstrap though, additional work is needed!) r? ``@lcnr``
2023-04-25pass `unused_extern_crates` in `librustdoc::doctest::make_test`ozkanonur-1/+1
Signed-off-by: ozkanonur <work@onurozkan.dev>
2023-04-25Auto merge of #110325 - obeis:hir-analysis-migrate-diagnostics-4, r=davidtwcobors-1/+3
Migrate `rustc_hir_analysis` to session diagnostic [Part 4] Part 4: Finishing `check/mod.rs` file r? `@compiler-errors`
2023-04-25Auto merge of #103093 - rytheo:linked-list-alloc-api, r=Mark-Simulacrumbors-2/+2
Add support for allocators in `LinkedList` Allows `LinkedList` to use a custom allocator
2023-04-25Auto merge of #101069 - zhaixiaojuan:loongarch64-inline-asm, r=Amanieubors-0/+196
Add loongarch64 asm! support
2023-04-25Add loongarch64 asm! supportzhaixiaojuan-0/+196
2023-04-25Negative coherence testMichael Goulet-0/+52
2023-04-24Add support for allocators in LinkedListRyan Lowe-2/+2
2023-04-25Revert "Remove #[alloc_error_handler] from the compiler and library"Matthias Krüger-4/+385
This reverts commit abc0660118cc95f47445fd33502a11dd448f5968.
2023-04-25Revert "Rename -Zoom=panic to -Zoom=unwind"Matthias Krüger-1/+1
This reverts commit 4b981c26487ebe56de6b3000fcd98713804beefc.
2023-04-25Revert "Adjust expected result for coverage test"Matthias Krüger-3/+3
This reverts commit 4da05e0b88d8b51fc6912da2d0b93edb2780e76b.
2023-04-24Auto merge of #110778 - JohnTitor:rollup-7f51qwk, r=JohnTitorbors-2/+530
Rollup of 10 pull requests Successful merges: - #110480 (Add `known-bug` tests for 11 unsound issues) - #110539 (Move around `{Idx, IndexVec, IndexSlice}` adjacent code) - #110590 (Add some tests around (lack of) object safety of associated types and consts) - #110602 (Ignore src/bootstrap formatting commit in .git-blame-ignore-revs) - #110667 (pointer-auth-link-with-c: Fix cross compilation.) - #110681 (drop few unused crates, gate libc under unix for rustc_codegen_ssa) - #110685 (Some cleanups to DataflowConstProp) - #110744 (bootstrap: update paths cargo-credential crate) - #110750 (Add size asserts for MIR `SourceScopeData` & `VarDebugInfo`) - #110760 (rustdoc: Add regression test for #60522) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2023-04-25Rollup merge of #110760 - GuillaumeGomez:regression-60522, r=notriddleYuki Okushi-0/+39
rustdoc: Add regression test for #60522 Fixes https://github.com/rust-lang/rust/issues/60522. r? `@notriddle`
2023-04-25Rollup merge of #110667 - pcc:fix-pointer-auth-link-with-c, r=Mark-SimulacrumYuki Okushi-2/+2
pointer-auth-link-with-c: Fix cross compilation.
2023-04-25Rollup merge of #110590 - oli-obk:object_safe_assoc_types, r=jackh726Yuki Okushi-0/+141
Add some tests around (lack of) object safety of associated types and consts See https://rust-lang.zulipchat.com/#narrow/stream/144729-t-types/topic/.60where.20Self.3ASized.60.20on.20assoc.20types/near/351260928 for some discussion around why this isn't allowed. We didn't have any tests for these, so I decided to add them now, even if we don't end up doing anything about it.
2023-04-25Rollup merge of #110480 - whtahy:105107/known-bug-tests-for-unsound-issues, ↵Yuki Okushi-0/+348
r=jackh726 Add `known-bug` tests for 11 unsound issues r? ``@jackh726`` Should tests for other issues be in separate PRs? Thanks. Edit: Partially addresses #105107. This PR adds `known-bug` tests for 11 unsound issues: - #25860 - #49206 - #57893 - #84366 - #84533 - #84591 - #85099 - #98117 - #100041 - #100051 - #104005
2023-04-24Auto merge of #110713 - cjgillot:track-mir-opt, r=scottmcmbors-170/+757
Add mir-opt tests to track MIR quality. cc `@scottmcm` `@saethlin` If you have other ideas, please say so.
2023-04-24Auto merge of #110672 - Ezrashaw:allow-array-simd-in-inline-asm, ↵bors-0/+25
r=workingjubilee allow array-style simd in inline asm Required for [MCP#621](https://github.com/rust-lang/compiler-team/issues/621) to be implemented. r? `@workingjubilee`
2023-04-24Add regression test for #60522Guillaume Gomez-0/+39
2023-04-24Rollup merge of #110706 - scottmcm:transmute_unchecked, r=oli-obkMatthias Krüger-33/+9
Add `intrinsics::transmute_unchecked` This takes a whole 3 lines in `compiler/` since it lowers to `CastKind::Transmute` in MIR *exactly* the same as the existing `intrinsics::transmute` does, it just doesn't have the fancy checking in `hir_typeck`. Added to enable experimenting with the request in <https://github.com/rust-lang/rust/pull/106281#issuecomment-1496648190> and because the portable-simd folks might be interested for dependently-sized array-vector conversions. It also simplifies a couple places in `core`. See also https://github.com/rust-lang/rust/pull/108442#issuecomment-1474777273, where `CastKind::Transmute` was added having exactly these semantics before the lang meeting (which I wasn't in) independently expressed interest.
2023-04-24Rollup merge of #110566 - compiler-errors:bad-projection-term, ↵Matthias Krüger-0/+33
r=cjgillot,BoxyUwU Don't create projection ty for const projection Fixes #110549
2023-04-24Rollup merge of #110255 - clubby789:proc-macro-test-help, r=jackh726Matthias Krüger-0/+26
Suggest using integration tests for test crate using own proc-macro cc #110247
2023-04-23Don't create projection ty for const projectionMichael Goulet-0/+33