Matthias Krüger
a5a1ffb178
Rollup merge of #94017 - fee1-dead:unub, r=bjorn3
...
Clarify confusing UB statement in MIR
2022-02-16 18:59:31 +01:00
Matthias Krüger
75a631d4ba
Rollup merge of #94015 - GuillaumeGomez:check-option, r=notriddle
...
rustdoc --check option documentation
Part of #92763 .
r? ```@notriddle```
2022-02-16 18:59:30 +01:00
Matthias Krüger
9a42121135
Rollup merge of #93962 - joboet:branchless_slice_ord, r=Mark-Simulacrum
...
Make [u8]::cmp implementation branchless
The current implementation generates rather ugly assembly code, branching when the common parts are equal. By performing the comparison of the lengths upfront using a subtraction, the assembly gets much prettier: https://godbolt.org/z/4e5fnEKGd .
This will probably not impact speed too much, as the expensive part is in most cases the `memcmp`, but it sure looks better (I'm porting a sorting algorithm currently, and that branch just bothered me).
2022-02-16 18:59:29 +01:00
Matthias Krüger
01f0da2373
Rollup merge of #93382 - GuillaumeGomez:search-input-padding, r=jsha
...
Add a bit more padding in search box
As asked in https://github.com/rust-lang/rust/pull/93113#issuecomment-1021565703 , here is a bit more padding.
You can check it [here](https://rustdoc.crud.net/imperio/search-input-padding/foo/index.html ).
r? `@camelid`
2022-02-16 18:59:28 +01:00
Matthias Krüger
6930b6676a
Rollup merge of #92366 - jhpratt:derive-default-enum, r=Mark-Simulacrum
...
Resolve concern of `derive_default_enum`
This resolves the concern in favor of prohibiting multiple instances of
the attribute. This is similar to non-helper attributes as introduced in
#88681 .
``@rustbot`` label +S-waiting-on-review +T-libs-api
2022-02-16 18:59:27 +01:00
Michael Howell
65fc7058d8
Do not suggest "is a function" for free variables
...
Part of #82323
2022-02-16 09:12:32 -07:00
Mark Rousskov
fc01d2b854
Destabilize cfg(target_has_atomic_load_store = ...)
...
This was not intended to be stabilized yet.
2022-02-16 10:28:12 -05:00
Laurențiu Nicola
ef88c3f406
⬆️ rust-analyzer
2022-02-16 17:23:51 +02:00
Ivan Lozano
568aeda9e9
MemTagSanitizer Support
...
Adds support for the LLVM MemTagSanitizer.
2022-02-16 09:39:03 -05:00
Krasimir Georgiev
0647e38904
add llvm-nm to bootstrap dist bin's
2022-02-16 14:13:09 +01:00
bors
f90b06d7fb
Auto merge of #94044 - ehuss:update-cargo, r=ehuss
...
Update cargo
5 commits in c082648646cbb2be266df9ecbcdc253058158d68..ea2a21c994ca1e4d4c49412827b3cf4dcb158b1d
2022-02-08 14:55:05 +0000 to 2022-02-15 04:24:07 +0000
- cargo-new should not add ignore rule on Cargo.lock inside subdirs (rust-lang/cargo#10379 )
- Add a badge for github actions (rust-lang/cargo#10385 )
- Remove outdated badges (rust-lang/cargo#10380 )
- Remove `strip = "off"` (and undocumented `strip = "n"`/`strip = "no"`) (rust-lang/cargo#10376 )
- Fix unmatched backticks (rust-lang/cargo#10375 )
2022-02-16 12:51:41 +00:00
lcnr
1b7c3bcef9
allow special behavior when printing const infer
2022-02-16 13:37:56 +01:00
lcnr
11ec2a47a4
extract Res to generics_of
def_id conversion
2022-02-16 13:37:21 +01:00
Michael Woerister
28ca6b0f79
debuginfo: Support fat pointers to unsized tuples.
2022-02-16 13:29:00 +01:00
Daniel Henry-Mantilla
6d2cdbec3e
Add mentions to Copy
for union
fields
2022-02-16 13:29:00 +01:00
Loïc BRANSTETT
3a73ca587b
Implement --check-cfg option (RFC 3013)
...
Co-authored-by: Urgau <lolo.branstett@numericable.fr>
Co-authored-by: Marcelina Kościelnicka <mwk@0x04.net>
2022-02-16 13:03:12 +01:00
Chayim Refael Friedman
91adb6ccd6
Correctly mark the span of captured arguments in format_args!()
...
It should only include the identifier, or misspelling suggestions will be wrong.
2022-02-16 07:34:06 +00:00
Eric Huss
d385899288
Update cargo
2022-02-15 20:31:20 -08:00
Eric Huss
2b75594140
Update books
2022-02-15 20:17:31 -08:00
DrMeepster
ae32f43c50
fix assumption that ScalarPair Box is always a fat pointer
2022-02-15 20:04:43 -08:00
Lucas Kent
1973f277a3
Cleanup uses
2022-02-16 15:01:19 +11:00
Lucas Kent
ae212402d6
Make implementation generic
2022-02-16 14:58:36 +11:00
Lucas Kent
8610edd014
Suggest deriving required supertraits
2022-02-16 14:58:36 +11:00
bors
a240ccd81c
Auto merge of #93800 - b-naber:static-initializers-mir-val, r=oli-obk
...
Treat static refs as `mir::ConstantKind::Val`
With the upcoming introduction of Valtrees we want to treat more values as `mir::ConstantKind::Val` directly.
r? `@lcnr`
cc `@oli-obk`
2022-02-16 03:03:03 +00:00
Tomasz Miąsko
3158372dea
Fix inconsistent symbol mangling with -Zverbose
...
Always skip arguments that are the defaults of their respective
parameters, to avoid generating inconsistent symbols for builds
with `-Zverbose` flag and without it.
2022-02-16 02:05:17 +01:00
bors
393fdc1048
Auto merge of #94021 - tmiasko:inline, r=nagisa
...
Inline a few trivial conversion functions
2022-02-15 23:48:43 +00:00
Tomasz Miąsko
92d20c4aad
Support pretty printing of invalid constants
...
Make it possible to pretty print invalid constants by introducing a
fallible variant of `destructure_const` and falling back to debug
formatting when it fails.
2022-02-16 00:38:59 +01:00
b-naber
db019f2160
try to bless 32bit mir tests manually
2022-02-15 22:24:53 +01:00
bors
09cb29c64c
Auto merge of #93439 - abrown:cf-protection, r=nagisa
...
Add support for control-flow protection
This change adds a flag for configuring control-flow protection in the LLVM backend. In Clang, this flag is exposed as `-fcf-protection` with options `none|branch|return|full`. This convention is followed for `rustc`, though as a codegen option: `rustc -Z cf-protection=<none|branch|return|full>`. Tracking issue for future work is #93754 .
2022-02-15 21:20:49 +00:00
Guillaume Gomez
590ca7e756
Add documentation for rustdoc --check option
2022-02-15 21:34:40 +01:00
Guillaume Gomez
0d2ff61ef5
Fix GUI test
2022-02-15 21:31:40 +01:00
Guillaume Gomez
6763cb9ab7
Update browser-ui-test version
2022-02-15 21:31:40 +01:00
b-naber
fff06e5edc
use AllocId and Ty in ExprKind::StaticRef and delay ConstValue construction
2022-02-15 21:18:33 +01:00
b-naber
54ff25e446
bless mir-opt tests
2022-02-15 21:17:49 +01:00
b-naber
22d6204db8
use mir::Visitor when collecting alloc_ids in pretty printing
2022-02-15 21:17:46 +01:00
b-naber
8092b90cb2
bless tests
2022-02-15 21:16:30 +01:00
b-naber
c612ef8f48
treat mir::ConstantKind::Val correctly in check_static_ptr
2022-02-15 21:16:26 +01:00
b-naber
5e0fab6da5
use ConstantKind::Val in StaticRef
2022-02-15 21:10:42 +01:00
bors
bfb2856f27
Auto merge of #93820 - compiler-errors:gat-wfcheck, r=jackh726
...
Rework GAT `where` clause check
rework the GAT where check to use a fixed-point algorithm, and check all GATs in a trait at once
fixes #93278
r? `@jackh726`
cc `@nikomatsakis`
2022-02-15 19:03:38 +00:00
Tomasz Miąsko
ea71420761
Inline LocalExpnId::from_raw and LocalExpnId::as_raw
2022-02-15 19:08:12 +01:00
Tomasz Miąsko
81f12eb7ef
Inline Target::deref
2022-02-15 19:08:12 +01:00
Tomasz Miąsko
d04677750b
Inline GenericArg conversion functions
2022-02-15 19:08:08 +01:00
Tomasz Miąsko
cd37638c14
Inline UnifyKey::index and UnifyKey::from_index
2022-02-15 19:07:06 +01:00
Michael Goulet
f045b214ea
Add removed comments back in self-outlives-lint
2022-02-15 09:17:09 -08:00
Michael Goulet
ce16189d46
add some more comments to GAT where clause check
2022-02-15 09:17:09 -08:00
Michael Goulet
d8b49f0282
add test for issue-93278, bless
2022-02-15 09:17:09 -08:00
Michael Goulet
477459795d
make the gat wfcheck algorithm a loop
2022-02-15 09:17:09 -08:00
Michael Goulet
852a851712
check associated types too
2022-02-15 09:17:09 -08:00
Michael Goulet
453d2dbbd4
check all GATs at once
2022-02-15 09:17:09 -08:00
Michael Goulet
764839320c
rename some variables in gat wfcheck
2022-02-15 09:17:09 -08:00