150365 Commits

Author SHA1 Message Date
jam1garner
64c61a32f6 Fix future_prelude_collision adding unneeded generic arguments 2021-06-14 13:27:25 -04:00
jam1garner
4a21a0bebc Fix future_prelude_collision not maintaining type aliases 2021-06-14 13:27:25 -04:00
jam1garner
cb4999242d Fix future_prelude_collision lint breaking for pointer mutabilty coercion 2021-06-14 13:27:24 -04:00
jam1garner
93c60f26bf Fix missing generic parameters from future_prelude_collision lint suggestion 2021-06-14 13:27:24 -04:00
jam1garner
eb5e0af3a9 Add autoderef and autoref tests for future_prelude_collision lint 2021-06-14 13:27:24 -04:00
jam1garner
327697a540 Fix autoderef and autoref for future_prelude_collision lint 2021-06-14 13:27:24 -04:00
jam1garner
c41a157b90 Fix incorrect argument description on FnCtxt::resolve_ufcs 2021-06-14 13:27:24 -04:00
jam1garner
35af38353e Add UI tests for future_prelude_collision lint 2021-06-14 13:27:24 -04:00
jam1garner
c341d5b9d7 Improve documentation for future_prelude_collision lint 2021-06-14 13:27:24 -04:00
jam1garner
1626e1938a Add support for associated functions to future_prelude_collision lint 2021-06-14 13:27:24 -04:00
jam1garner
a9dc234c43 Add docs for FnCtxt::resolve_ufcs 2021-06-14 13:27:24 -04:00
jam1garner
01bdb8e38a Disable future_prelude_collision for 2021 edition 2021-06-14 13:27:24 -04:00
jam1garner
79388aa067 Add future_prelude_collision lint 2021-06-14 13:27:23 -04:00
bors
304441960e Auto merge of #86117 - ehuss:force-warns-underscore, r=rylev
Fix force-warns to allow dashes.

The `--force-warns` flag was not allowing lint names with dashes, only supporting underscores.  This changes it to allow dashes to match the behavior of the A/W/D/F flags.
2021-06-14 17:21:28 +00:00
Rémy Rakic
5af1c72513 Adjust throw_validation_failure macro to shorten the use of with_no_trimmed_paths 2021-06-14 18:57:53 +02:00
Rémy Rakic
19fddc019f Improve documentation on UndefinedBehaviorInfo::ValidationFailure 2021-06-14 18:57:06 +02:00
Mara Bos
65c1d35973 Stabilize {std, core}::prelude::rust_*. 2021-06-14 14:44:50 +00:00
Guillaume Gomez
6a66b79fb6 Allow to run only a few GUI tests 2021-06-14 16:40:10 +02:00
bors
a216131c35 Auto merge of #86273 - JohnTitor:stabilize-maybe-uninit-ref, r=RalfJung
Stabilize `maybe_uninit_ref`

This stabilizes `assume_init_{ref,mut}`. FCP is complete: https://github.com/rust-lang/rust/issues/63568#issuecomment-590121300
The renaming was done by #76047 and FIXME was resolved by #76241, so I think we can now stabilize them finally 🎉
Still, it's const-unstable as `assert_inhabited` is unstable.

Closes #63568
2021-06-14 13:05:54 +00:00
mbartlett21
7803955cae Use try_from_secs_* in Duration::from_secs_* functions.
`Duration::from_secs_{f32, f64}` now use the results from the
non-panicking functions and unwrap it.
2021-06-14 12:17:53 +00:00
mbartlett21
c2c1ca071f Add functions Duration::try_from_secs_{f32, f64}
This also adds the error type used, `FromSecsError` and its `impl`s.
2021-06-14 12:16:13 +00:00
est31
8710258714 Improve maybe_uninit_extra docs
For reasoning, see https://github.com/rust-lang/rust/issues/63567#issuecomment-858640987
2021-06-14 13:30:58 +02:00
bors
7510b0ca45 Auto merge of #85758 - petertodd:2021-revert-manuallydrop-clone-from, r=m-ou-se
Revert #85176 addition of `clone_from` for `ManuallyDrop`

Forwarding `clone_from` to the inner value changes the observable behavior, as previously the inner value would *not* be dropped by the default implementation.

Frankly, this is a super-niche case, so #85176 is welcome to argue the behavior should be otherwise! But if we overrride it, IMO documenting the behavior would be good.

Example: https://play.rust-lang.org/?version=nightly&mode=debug&edition=2018&gist=c5d0856686fa850c1d7ee16891014efb
2021-06-14 10:24:48 +00:00
Yuki Okushi
d7db9698e6
Add a regression test for issue-76510 2021-06-14 18:06:48 +09:00
Ethan Brierley
85b06e9c01 run tidy 2021-06-14 09:58:41 +01:00
Ethan Brierley
b59f7d9662 stabilize int_error_matching 2021-06-14 09:58:32 +01:00
Laurențiu Nicola
69f88f55c5 ⬆️ rust-analyzer 2021-06-14 09:44:02 +03:00
Jacob Hoffman-Andrews
74e8e7bb60 Remove must_use from ALLOWED_ATTRIBUTES
This is a fairly common attribute on methods, but is not something you
need to know when reading the method docs - the purpose of the attribute
is for the compiler to tell you about it if you forget to use a value.

Removing reclaims some valuable space in the summary of methods.
2021-06-13 17:57:16 -07:00
Yuki Okushi
4e755a96a7
Adjust documentation 2021-06-14 07:42:15 +09:00
Yuki Okushi
ea188e9d21
Permit zero non-zero-field on transparent types 2021-06-14 07:42:14 +09:00
bors
14831568d5 Auto merge of #86270 - Shadlock0133:patch-1, r=jackh726
Fix typo `with custom a custom` -> `with a custom`
2021-06-13 22:42:02 +00:00
Rémy Rakic
b87724053e update tests involving CTFE validation 2021-06-13 23:26:06 +02:00
Rémy Rakic
87ecf84c36 Improve CTFE validation error message 2021-06-13 22:40:42 +02:00
bors
f586d79d18 Auto merge of #86271 - GuillaumeGomez:fix-font-weight, r=jsha
Fix font weight

Fixes #86256.

I realized that the only cases where we actually needed to have bold text was inside `impl-items`.

cc `@camelid`
r? `@jsha`
2021-06-13 20:13:32 +00:00
Yuki Okushi
7fa1308db1
Stabilize maybe_uninit_ref 2021-06-14 05:08:03 +09:00
Guillaume Gomez
466aec9957 Add test to ensure font-weight is applied correctly 2021-06-13 21:50:11 +02:00
Guillaume Gomez
d87ec7ae19 Update browser-ui-test version 2021-06-13 21:49:30 +02:00
Guillaume Gomez
a8318e420d Fix font-weight 2021-06-13 21:49:10 +02:00
Shadlock0133
dab89b51ac
Fix typo with custom a custom -> with a custom 2021-06-13 21:21:45 +02:00
ltdk
525d76026f Change tracking issue 2021-06-13 14:04:43 -04:00
ltdk
d8e247e38c More lerp tests, altering lerp docs 2021-06-13 14:00:15 -04:00
LeSeulArtichaut
5e802e5e97 Box ExprKind::Adt 2021-06-13 17:03:11 +02:00
bors
fb3ea63d9b Auto merge of #86245 - lqd:const-ub-align, r=RalfJung
Fix ICEs on invalid vtable size/alignment const UB errors

The invalid vtable size/alignment errors from `InterpCx::read_size_and_align_from_vtable` were "freeform const UB errors", causing ICEs when reaching validation. This PR turns them into const UB hard errors to catch them during validation and avoid that.

Fixes #86193

r? `@RalfJung`

(It seemed cleaner to have 2 variants but they can be merged into one variant with a message payload if you prefer that ?)
2021-06-13 12:08:59 +00:00
Rémy Rakic
e29f3e837f Test invalid vtable size/alignment const UB errors 2021-06-13 13:11:07 +02:00
Rémy Rakic
cae1918b29 Turn incorrect vtable size/alignment errors into hard const-UB errors
They were "freeform const UB" error message, but could reach validation
and trigger ICEs there. We now catch them during validation to avoid
that.
2021-06-13 13:11:07 +02:00
bors
6cc5d5432a Auto merge of #86185 - klensy:ast-val, r=petrochenkov
simplify validate_generic_param_order
2021-06-13 09:36:12 +00:00
bors
a75e74df89 Auto merge of #86233 - JohnTitor:stabilize-simd-x86-bittest, r=Amanieu
Stabilize `simd_x86_bittest` feature

This pulls https://github.com/rust-lang/stdarch/pull/1180, FCP is complete: https://github.com/rust-lang/rust/issues/59414#issuecomment-826072554
Closes #59414
2021-06-13 01:27:37 +00:00
bors
302468e71c Auto merge of #86207 - ehuss:update-cargo, r=ehuss
Update cargo

11 commits in aa8b09297bb3156b849e73db48af4cd050492fe6..44456677b5d1d82fe981c955dc5c67734b31f340
2021-06-09 00:28:53 +0000 to 2021-06-12 18:00:01 +0000
- Fix package_default_run test. (rust-lang/cargo#9577)
- Change how the fix_deny_warnings_but_not_others test works (rust-lang/cargo#9571)
- Add mising documentation regarding `cargo doc` (rust-lang/cargo#9565)
- Implement warning for ignored trailing arguments (rust-lang/cargo#9561)
- Make clippy happy (rust-lang/cargo#9569)
- Fix rustc/rustdoc config values to be config-relative. (rust-lang/cargo#9566)
- Update rustfix. (rust-lang/cargo#9567)
- Warn if an "all" target is specified, but we don't match anything (rust-lang/cargo#9549)
- add default_run to SerializedPackage (rust-lang/cargo#9550)
- respect user choice of lib/bin over heuristics (rust-lang/cargo#9522)
- Add a mean to mutably access the members of a workspace (rust-lang/cargo#9547)
2021-06-12 23:08:16 +00:00
klensy
6a19867417 simplify validate_generic_param_order 2021-06-13 01:39:57 +03:00
bors
24bdc6d73a Auto merge of #86240 - tmiasko:verbose-generator-witness, r=jackh726
Pretty print generator witness only in `-Zverbose` mode

In release build of deeply-nested-async benchmark the size of
`no-opt.bc` file is reduced from 46MB to 62kB.

Helps with #84873, where in one of reported test cases the size of `no-opt.bc`
file is reduced from 2.3GB to 799kB.
2021-06-12 20:38:17 +00:00