about summary refs log tree commit diff
path: root/src/test/ui
AgeCommit message (Collapse)AuthorLines
2022-11-11Auto merge of #104293 - Manishearth:rollup-xj92d0k, r=Manishearthbors-76/+570
Rollup of 8 pull requests Successful merges: - #95292 (Allow specialized const trait impls.) - #100386 (Make `Sized` coinductive, again) - #102215 (Implement the `+whole-archive` modifier for `wasm-ld`) - #103468 (Fix unused lint and parser caring about spaces to won't produce invalid code) - #103531 (Suggest calling the instance method of the same name when method not found) - #103960 (piece of diagnostic migrate) - #104051 (update Miri) - #104129 (rustdoc: use javascript to layout notable traits popups) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2022-11-11Auto merge of #104289 - Dylan-DPC:rollup-v7wei2t, r=Dylan-DPCbors-93/+229
Rollup of 9 pull requests Successful merges: - #100633 (Consider `#[must_use]` annotation on `async fn` as also affecting the `Future::Output`) - #103445 (`#[test]`: Point at return type if `Termination` bound is unsatisfied) - #103924 (Fix broken link in description of error code E0706) - #104146 (Retry binding TCP Socket in remote-test-server) - #104169 (Migrate `:target` rules to use CSS variables) - #104202 (Fix ICE #103748) - #104216 (Don't ICE on operator trait methods with generic methods) - #104217 (Display help message when fluent arg was referenced incorrectly) - #104245 (Reduce default configuration's dependency upon static libstdcpp library (#103606)) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2022-11-11Rollup merge of #103531 - chenyukang:yukang/fix-103474, r=estebankManish Goregaokar-4/+76
Suggest calling the instance method of the same name when method not found Fixes #103474
2022-11-11Rollup merge of #103468 - chenyukang:yukang/fix-103435-extra-parentheses, ↵Manish Goregaokar-0/+97
r=estebank Fix unused lint and parser caring about spaces to won't produce invalid code Fixes #103435
2022-11-11Rollup merge of #100386 - compiler-errors:sized-coinductive-redux, r=lcnrManish Goregaokar-69/+113
Make `Sized` coinductive, again A revival of #83647 --- What exactly makes co-induction sound? Better question: are there any unsoundness risks from this? `Sized` can't be implemented by custom `impl` blocks, nor can it be conditionally implemented based on anything other than child fields being `Sized`, right? r? `@nikomatsakis` for whenever he gets back from vacation
2022-11-11Rollup merge of #95292 - BGR360:const-trait-specialize, r=lcnrManish Goregaokar-3/+284
Allow specialized const trait impls. Fixes #95186. Fixes #95187. I've done my best to create a comprehensive test suite for the interaction between `min_specialization` and `const_trait_impls`. I wouldn't be surprised if there are interesting cases I haven't tested, please let me know.
2022-11-11Rollup merge of #104216 - Nilstrieb:dont-ice-invalid-operator-traits, r=estebankDylan DPC-0/+31
Don't ICE on operator trait methods with generic methods Emit a fatal error instead. fixes #104213
2022-11-11Rollup merge of #104202 - camsteffen:103748, r=estebankDylan DPC-0/+59
Fix ICE #103748 Fixes #103748
2022-11-11Rollup merge of #103445 - fmease:fix-50291, r=estebankDylan DPC-7/+5
`#[test]`: Point at return type if `Termination` bound is unsatisfied Together with #103142 (already merged) this fully fixes #50291. I don't consider my current solution of changing a few spans “here and there” very clean since the failed obligation is a `FunctionArgumentObligation` and we point at a type instead of a function argument. If you agree with me on this point, I can offer to keep the spans of the existing nodes and instead inject `let _: AssertRetTyIsTermination<$ret_ty>;` (type to be defined in `libtest`) similar to `AssertParamIsEq` etc. used by some built-in derive-macros. I haven't tried that approach yet though and cannot promise that it would actually work out or be “cleaner” for that matter. ````@rustbot```` label A-libtest A-diagnostics r? ````@estebank````
2022-11-11Rollup merge of #100633 - estebank:must_use_async_fn_return, r=tmandryDylan DPC-86/+134
Consider `#[must_use]` annotation on `async fn` as also affecting the `Future::Output` No longer lint against `#[must_use] async fn foo()`. When encountering a statement that awaits on a `Future`, check if the `Future`'s parent item is annotated with `#[must_use]` and emit a lint if so. This effectively makes `must_use` an annotation on the `Future::Output` instead of only the `Future` itself. Fix #78149.
2022-11-11rustc_codegen_ssa: Better code generation for niche discriminants.Michael Benfield-0/+114
In some cases we can avoid arithmetic before checking whether a niche represents an untagged variant. This is relevant to #101872
2022-11-10Oops, bless this test.Ben Reeves-1/+1
2022-11-10Fix tests after rebaseEsteban Küber-2/+2
2022-11-11Auto merge of #99918 - WaffleLapkin:fnFnfun, r=estebankbors-0/+154
Recover wrong-cased keywords that start items (_this pr was inspired by [this tweet](https://twitter.com/Azumanga/status/1552982326409367561)_) r? `@estebank` We've talked a bit about this recovery, but I just wanted to make sure that this is the right approach :) For now I've only added the case insensitive recovery to `use`s, since most other items like `impl` blocks, modules, functions can start with multiple keywords which complicates the matter.
2022-11-10review commentsEsteban Küber-4/+4
2022-11-10Consider `#[must_use]` annotation on `async fn` as also affecting the ↵Esteban Küber-30/+78
`Future::Output` No longer lint against `#[must_use] async fn foo()`. When encountering a statement that awaits on a `Future`, check if the `Future`'s parent item is annotated with `#[must_use]` and emit a lint if so. This effectively makes `must_use` an annotation on the `Future::Output` instead of only the `Future` itself. Fix #78149.
2022-11-10Tweak span for `#[must_use]`Esteban Küber-55/+55
Do not point at whole statement, only at the expression (skip pointing at `;`)
2022-11-10More nitsMichael Goulet-0/+14
2022-11-10bless testsMichael Goulet-70/+23
2022-11-10add some more testslcnr-0/+35
2022-11-10make `Sized` coinductivelcnr-0/+42
2022-11-10Apply PR feedback.Ben Reeves-1/+1
2022-11-10Require `~const` qualifier on trait bounds in specializing impls if present ↵Ben Reeves-8/+94
in base impl.
2022-11-10Add #[const_trait] where needed in tests.Ben Reeves-1/+10
2022-11-10Disallow specializing on const impls with non-const impls.Ben Reeves-76/+20
2022-11-10Allow specialized const trait impls.Ben Reeves-0/+242
Fixes #95186. Fixes #95187.
2022-11-10Rollup merge of #104233 - compiler-errors:issue-104209, r=lcnrManish Goregaokar-0/+14
Don't ICE when encountering `ConstKind::Error` in `RequiredConstsVisitor` Fixes #104209
2022-11-10Rollup merge of #104186 - chenyukang:yukang/fix-104086-let-binding-issue, ↵Manish Goregaokar-0/+165
r=oli-obk Tighten the 'introduce new binding' suggestion Fixes #104086
2022-11-10Rollup merge of #104036 - compiler-errors:option-sugg, r=petrochenkovManish Goregaokar-0/+25
Suggest `is_some` when we've found `Option` but expected `bool` Thanks `@lunasorcery` for the suggestion.
2022-11-10Rollup merge of #103863 - compiler-errors:fulfillcx-less, r=wesleywiserManish Goregaokar-0/+4
Use `TraitEngine` in more places, restrict visibility of `FulfillmentCtxt` constructor Most places that are constructing a `FulfillmentContext` should be constructing a `TraitEngine` generically, so later on if/when we're transitioning it'll be easier. Logical extension of #99746
2022-11-10Auto merge of #104236 - compiler-errors:rollup-adjshd6, r=compiler-errorsbors-0/+63
Rollup of 9 pull requests Successful merges: - #102763 (Some diagnostic-related nits) - #103443 (Parser: Recover from using colon as path separator in imports) - #103675 (remove redundent "<>" for ty::Slice with reference type) - #104046 (bootstrap: add support for running Miri on a file) - #104115 (Migrate crate-search element to CSS variables) - #104190 (Ignore "Change InferCtxtBuilder from enter to build" in git blame) - #104201 (Add check in GUI test for file loading failure) - #104211 (:arrow_up: rust-analyzer) - #104231 (Update mailmap) Failed merges: - #104169 (Migrate `:target` rules to use CSS variables) r? `@ghost` `@rustbot` modify labels: rollup
2022-11-09Rollup merge of #103675 - lyming2007:issue-103271-fix, r=fee1-deadMichael Goulet-0/+24
remove redundent "<>" for ty::Slice with reference type this fix #103271
2022-11-09Rollup merge of #103443 - mucinoab:recover-colon-as-path-separetor, ↵Michael Goulet-0/+39
r=compiler-errors Parser: Recover from using colon as path separator in imports I don't know if this is the right approach, any feedback is welcome. r? ```@compiler-errors``` Fixes #103269
2022-11-10Auto merge of #103636 - chenyukang:yukang/fix-103587-sugg-if-let, ↵bors-0/+72
r=jackh276,davidtwco Recover from common if let syntax mistakes/typos Fixes #103587
2022-11-10Don't ICE when encountering ConstKind::Error in RequiredConstsVisitorMichael Goulet-0/+14
2022-11-10bless a chalk testMichael Goulet-0/+4
2022-11-10Auto merge of #101990 - clubby789:dont-machine-apply-placeholder-method, ↵bors-15/+165
r=compiler-errors Fix auto-application of associated generic functions with placeholders Fixes #101920
2022-11-09remove redundent "<>" for ty::Slice with reference typeYiming Lei-0/+24
this fix #103271
2022-11-09Don't ICE on operator trait methods with generic methodsNilstrieb-0/+31
Emit a fatal error instead.
2022-11-09Rollup merge of #104020 - nicholasbishop:bishop-limit-efiapi, r=nagisaManish Goregaokar-99/+127
Limit efiapi calling convention to supported arches Supported architectures in UEFI are described here: https://uefi.org/specs/UEFI/2.10/02_Overview.html#calling-conventions https://github.com/rust-lang/rust/issues/65815
2022-11-09Rollup merge of #103464 - JakobDegen:mir-parsing, r=oli-obkManish Goregaokar-0/+23
Add support for custom mir This implements rust-lang/compiler-team#564 . Details about the design, motivation, etc. can be found in there. r? ```@oli-obk```
2022-11-09Rollup merge of #103307 - b4den:master, r=estebankManish Goregaokar-126/+126
Add context to compiler error message Changed `creates a temporary which is freed while still in use` to `creates a temporary value which is freed while still in use`.
2022-11-09Rollup merge of #101005 - SLASHLogin:rustc_codegen_llvm_diagnostics, r=davidtwcoManish Goregaokar-3/+3
Migrate rustc_codegen_llvm to SessionDiagnostics WIP: Port current implementation of diagnostics to the new SessionDiagnostics. Part of #100717 ```@rustbot``` label +A-translation
2022-11-09Suggest is_some or let when encountering Option and bool type mismatchMichael Goulet-0/+25
2022-11-10add 'is_assign_rhs' to avoid weird suggesting 'let'yukang-4/+24
2022-11-09Add domain size check to fix ICECameron Steffen-0/+59
2022-11-09Correct tests to match errorsSLASHLogin-3/+3
2022-11-09Rollup merge of #104125 - ink-feather-org:const_cmp_tuples, r=fee1-deadDylan DPC-11/+8
Const Compare for Tuples Makes the impls for Tuples of ~const `PartialEq` types also `PartialEq`, impls for Tuples of ~const `PartialOrd` types also `PartialOrd`, for Tuples of ~const `Ord` types also `Ord`. behind the `#![feature(const_cmp)]` gate. ~~Do not merge before #104113 is merged because I want to use this feature to clean up the new test that I added there.~~ r? ``@fee1-dead``
2022-11-09Rollup merge of #103919 - nnethercote:unescaping-cleanups, r=matkladDylan DPC-45/+45
Unescaping cleanups Some code improvements, and some error message improvements. Best reviewed one commit at a time. r? ````@matklad````
2022-11-09Cleanup fn trait ref testonestacked-11/+8