bors
c15bae53b5
Auto merge of #75086 - lzutao:u32const, r=oli-obk
...
Use u32::from_ne_bytes to fix a FIXME and add comment about that
`u32::from_ne_bytes` has been const stable since 1.44.
2020-08-06 14:21:48 +00:00
Ryan Wiedemann
49c7e39d03
Apply suggestions from code review
...
Co-authored-by: Philipp Krones <hello@philkrones.com>
2020-08-06 07:57:31 -06:00
Ryan Wiedemann
d897fd28ae
Apply suggestions from code review
...
Co-authored-by: Philipp Krones <hello@philkrones.com>
2020-08-06 07:57:31 -06:00
Aaron Hill
c9bd9431d0
Record query name when profiling "metadata_decode_entry"
2020-08-06 09:33:34 -04:00
Ryan1729
42f3d39a54
run clippy_dev fmt
...
This seemed to overdo it a bit, affecting multiple submodules, and changing a file I didn't touch, so I didn't commit those changes
2020-08-06 06:15:57 -06:00
Ryan1729
32691da3d9
run clippy_dev fmt
...
This seemed to overdo it a bit, affecting multiple submodules, and changing a file I didn't touch, so I didn't commit those changes
2020-08-06 06:15:57 -06:00
bors
4b0882cfaa
Auto merge of #74889 - JohnTitor:hrtb-tests, r=nikomatsakis
...
Add HRTB-related regression test
Closes #59311 and cc #71546
This closes the former but the test is taken from https://github.com/rust-lang/rust/issues/71546#issuecomment-620638437 since it seems they have the same cause and it's simplified.
2020-08-06 12:12:59 +00:00
Ryan1729
0d2a378547
run clippy_dev update_lints
2020-08-06 06:11:23 -06:00
Ryan1729
007dc944da
run clippy_dev update_lints
2020-08-06 06:11:23 -06:00
Ryan1729
4027f15dd6
run ./x.py fmt
2020-08-06 06:08:32 -06:00
Guillaume Gomez
57b517bf1d
Clean up E0747 explanation
2020-08-06 13:33:54 +02:00
Ryan1729
b0c8c7af16
add newline to transmutes_expressible_as_ptr_casts.rs
2020-08-06 04:49:06 -06:00
Ryan1729
e3170bb1ec
add newline to transmutes_expressible_as_ptr_casts.rs
2020-08-06 04:49:06 -06:00
Ryan1729
8997c558d8
change filter to assert, and update comments
2020-08-06 04:24:25 -06:00
Ryan1729
54472478fa
change filter to assert, and update comments
2020-08-06 04:24:25 -06:00
Ryan1729
ded2d6c233
add extra error message to the expected stderr for transmutes_expressible_as_ptr_casts test
2020-08-06 04:24:25 -06:00
Ryan1729
afd4909d41
add extra error message to the expected stderr for transmutes_expressible_as_ptr_casts test
2020-08-06 04:24:25 -06:00
Ryan1729
94340d6e17
add documentation to functions that call do_check
and add a test against lint ordering changing
2020-08-06 04:24:25 -06:00
Ryan1729
8ba41017e7
add documentation to functions that call do_check
and add a test against lint ordering changing
2020-08-06 04:24:25 -06:00
Ryan1729
19f36bc2f3
add description to assert
2020-08-06 04:24:25 -06:00
Ryan1729
6fdd1dbe03
add description to assert
2020-08-06 04:24:25 -06:00
Ryan1729
d38766ed96
address some review comments
2020-08-06 04:24:25 -06:00
Ryan1729
ab93133e83
address some review comments
2020-08-06 04:24:25 -06:00
Ryan1729
ccc4747f46
get the expected number of errors by acknowledging that other lints are covering the same ground
2020-08-06 04:24:25 -06:00
Ryan1729
7a818c096c
get the expected number of errors by acknowledging that other lints are covering the same ground
2020-08-06 04:24:25 -06:00
Ryan1729
de05212987
try putting the can_be_expressed_as_pointer_cast at the top and find that we still get an ICE
2020-08-06 04:24:24 -06:00
Ryan1729
1e5c14df58
try putting the can_be_expressed_as_pointer_cast at the top and find that we still get an ICE
2020-08-06 04:24:24 -06:00
Ryan1729
34d3a0086c
accidentally cause an ICE by putting the TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS handling after the match
...
The reason I did this in the first place was to try and figure out why I don't see my expected 7 error messages
2020-08-06 04:24:24 -06:00
Ryan1729
b4ecee9ede
accidentally cause an ICE by putting the TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS handling after the match
...
The reason I did this in the first place was to try and figure out why I don't see my expected 7 error messages
2020-08-06 04:24:24 -06:00
Ryan1729
46ef4e8651
write currently failing test for transmutes_expressible_as_ptr_casts
...
There are 5 errors, when there should be 7.
2020-08-06 04:24:24 -06:00
Ryan1729
7061b1c093
write currently failing test for transmutes_expressible_as_ptr_casts
...
There are 5 errors, when there should be 7.
2020-08-06 04:24:24 -06:00
Ryan1729
069f851671
initial compiling version of TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS
2020-08-06 04:24:24 -06:00
Ryan1729
b4e6e70478
initial compiling version of TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS
2020-08-06 04:24:24 -06:00
Ryan1729
5e84b8c2fb
run cargo dev new_lint then move transmutes_expressible_as_ptr_casts into transmute module
2020-08-06 04:24:24 -06:00
Ryan1729
0c37239e0e
make InheritedBuilder::enter public
2020-08-06 04:24:24 -06:00
Ryan1729
5565c1a1ca
run cargo dev new_lint then move transmutes_expressible_as_ptr_casts into transmute module
2020-08-06 04:24:24 -06:00
Ryan1729
ef2916170b
make parts of rustc_typeck public
2020-08-06 04:24:24 -06:00
Tim Diekmann
a784729cde
Add as_mut_ptr
to NonNull<[T]>
2020-08-06 11:45:54 +02:00
Lzu Tao
eff7d568d8
Note about endianness of returned value
...
in {integer}::from_be_bytes and friends.
2020-08-06 07:33:07 +00:00
bors
3cfc7fe78e
Auto merge of #75008 - eddyb:rmeta-indexed-trait-impls, r=nikomatsakis
...
rustc_metadata: track the simplified Self type for every trait impl.
For the `traits_impls_of` query, we index the impls by `fast_reject::SimplifiedType` (a "shallow type"), which allows some simple cases like `impl Trait<..> for Foo<..>` to be efficiently iterated over, by e.g. `for_each_relevant_impl`.
This PR encodes the `fast_reject::SimplifiedType` cross-crate to avoid needing to deserialize the `Self` type of every `impl` in order to simplify it - the simplification itself should be cheap, but the deserialization is less so.
We could go further from here and make loading the list of impls lazy, for a given simplified `Self` type, but that would have more complicated implications for performance, and this PR doesn't do anything in that regard.
r? @nikomatsakis cc @Mark-Simulacrum
2020-08-06 03:23:57 +00:00
Christoph Walcher
0abc4833e5
Lint .min(x).max(y) with x < y
...
Fixes #5854
2020-08-06 02:56:07 +02:00
Joshua Nelson
2dad90d8b5
Suggest f() for functions and add a test case
2020-08-05 20:46:02 -04:00
Aaron Hill
ab766f0511
Handle projection predicates in the param env for auto-trait docs
...
Fixes #72213
Any predicates in the param env are guaranteed to hold, so we don't need
to do any additional processing of them if we come across them as
sub-obligations of a different predicate. This allows us to avoid adding
the same predicate to the computed ParamEnv multiple times (but with
different regions each time), which causes an ambiguity error during
fulfillment.
2020-08-05 20:22:55 -04:00
Tomasz Miąsko
888bc07c6b
Keep stdout open in limit_vector_count test
2020-08-06 00:00:00 +00:00
Eduardo Broto
50a86d4927
enable #[allow(clippy::unsafe_derive_deserialize)]
2020-08-06 00:45:30 +02:00
Nazım Can Altınova
cedf96c834
Add a test for BTreeMap lifetime bound to see if it compiles
2020-08-05 23:44:34 +02:00
Nazım Can Altınova
62e06a4d09
Make IntoIterator lifetime bounds of &BTreeMap match with &HashMap
2020-08-05 23:32:13 +02:00
bors
2d4c3379d3
Auto merge of #5809 - JarredAllen:stable_sort_primitive, r=Manishearth
...
Stable sort primitive
changelog: Implements #5762
2020-08-05 20:41:21 +00:00
Yuki Okushi
cc36c3d140
Add a FIXME comment
2020-08-06 05:21:03 +09:00
bors
22ee68dc58
Auto merge of #75166 - JulianKnodt:i64494, r=lcnr
...
Add regression test for #64494
Add regression test to indicate if this compilation ever succeeds.
Fixes #64494
r? @lcnr
2020-08-05 20:20:56 +00:00