about summary refs log tree commit diff
path: root/src/test
AgeCommit message (Collapse)AuthorLines
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-11rustdoc: add test cases for checkbox togglesMichael Howell-4/+79
2022-11-11Introduce `ExprKind::IncludedBytes`clubby789-8/+13
2022-11-11Add regression test for multi-level importGuillaume Gomez-0/+34
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 #104169 - GuillaumeGomez:migrate-css-target, r=notriddleDylan DPC-0/+35
Migrate `:target` rules to use CSS variables There should be no GUI changes. r? `@notriddle`
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-11Print all labels, even if they have no span. Fall back to main item's span.Oli Scherer-13/+10
2022-11-11Don't add message that will never be shown to usersOli Scherer-7/+4
It will still be used in json, as seen by the ui test changes
2022-11-11Do not rename bound variables when verbose-printing binders.Camille GILLOT-18/+18
2022-11-11Recover from fn ptr tys with generic param listLeón Orell Valerian Liehr-0/+142
2022-11-11Visit opaque types during type collection too.Camille GILLOT-321/+100
2022-11-11Add test for repr(transparent) with scalarJannis Christopher Köhl-0/+56
2022-11-11Resolve lifetimes using the regular logic for RPIT.Camille GILLOT-25/+202
2022-11-11Add `nto` as known `target_os`Florian Bartels-1/+1
2022-11-11rustc_codegen_ssa: Better code generation for niche discriminants.Michael Benfield-0/+226
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-11emit errors when using `RangeFrom` and `RangeTo`Takayuki Maeda-6/+13
2022-11-11suggest removing unnecessary . to use a floating point literalTakayuki Maeda-0/+58
2022-11-10rustdoc: use checkbox instead of switch for settings togglesMichael Howell-8/+5
The switch is designed to give the application a "physical" feel, but nothing else in here really followed through. They didn't support the "flick" gesture that real iOS switches support, and the radio buttons that were also used in Rustdoc Settings were a more "classic" form element anyway. Also, while "switches" are the exclusive toggle design on iOS (since [Apple HIG] reserves checkboxes for Mac only), the [Google Material] guidelines say that lists of switches are bad, and you should just use check boxes. [Apple HIG]: https://developer.apple.com/design/human-interface-guidelines/components/selection-and-input/toggles [Google Material]: https://m3.material.io/components/checkbox/guidelines#6902f23d-ceba-4b19-ae3b-b78b9b01d185
2022-11-10Regression test for coercion of mut-ref to dyn-starMichael Goulet-0/+32
2022-11-10Don't CoerceUnsized dyn* to dyn*Michael Goulet-0/+26
2022-11-10Don't allow implement CoerceUnsized into dyn-starMichael Goulet-0/+18
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-10Deduce closure signature from TAIT supertraitsMichael Goulet-0/+15
2022-11-10More accurately report error when formal and expected signature types differMichael Goulet-0/+55
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-10Add GUI test for :targetGuillaume Gomez-0/+35
2022-11-11Mark `trait_upcasting` feature no longer incomplete.Charles Lew-80/+80
2022-11-10update debuginfo checkjoboet-2/+2
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 #104077 - nicholasbishop:bishop-uefi-aapcs, r=nagisaManish Goregaokar-1/+1
Use aapcs for efiapi calling convention on arm On arm, [llvm treats the C calling convention as `aapcs` on soft-float targets and `aapcs-vfp` on hard-float targets](https://github.com/rust-lang/compiler-builtins/issues/116#issuecomment-261057422). UEFI specifies in the arm calling convention that [floating point extensions aren't used](https://uefi.org/specs/UEFI/2.10/02_Overview.html#detailed-calling-convention), so always translate `efiapi` to `aapcs` on arm. https://github.com/rust-lang/rust/issues/65815