| Age | Commit message (Collapse) | Author | Lines |
|
|
|
|
|
|
|
ast: Unmerge structures for associated items and foreign items
Follow-up to https://github.com/rust-lang/rust/pull/69194.
r? @Centril
|
|
Rollup of 8 pull requests
Successful merges:
- #69697 (Add explanation for E0380)
- #69698 (Use associated constants of integer types)
- #69711 (Update macros.rs: fix documentation typo.)
- #69713 (more clippy cleanups)
- #69728 (Make link to `std::str` active)
- #69732 (Clean E0382 and E0384 explanations)
- #69736 (even more clippy cleanups)
- #69742 (Fixed a typo)
Failed merges:
r? @ghost
|
|
Fixed a typo
"vector" was used instead of "string". I think this is a typo?
|
|
even more clippy cleanups
* Don't pass &mut where immutable reference (&) is sufficient (clippy::unnecessary_mut_passed)
* Use more efficient &&str to String conversion (clippy::inefficient_to_string)
* Don't always eval arguments inside .expect(), use unwrap_or_else and closure. (clippy::expect_fun_call)
* Use righthand '&' instead of lefthand "ref". (clippy::toplevel_ref_arg)
* Use simple 'for i in x' loops instead of 'while let Some(i) = x.next()' loops on iterators. (clippy::while_let_on_iterator)
* Const items have by default a static lifetime, there's no need to annotate it. (clippy::redundant_static_lifetimes)
* Remove redundant patterns when matching ( x @ _ to x) (clippy::redundant_pattern)
|
|
Clean E0382 and E0384 explanations
r? @Dylan-DPC
|
|
Make link to `std::str` active
Closes #69726.
r? @dtolnay
|
|
more clippy cleanups
* Don't use .ok() before unwrapping via .expect() on a Result.
* Use .map() to modify data inside Options instead of using .and_then(|x| Some(y))
* Use .as_deref() instead of .as_ref().map(Deref::deref)
* Don't use "if let" bindings to only check a value and not actually bind anything.
* Use single-char patter on {ends,starts}_with and remove clone on copy type.
|
|
Update macros.rs: fix documentation typo.
|
|
Use associated constants of integer types
Take advantage of https://github.com/rust-lang/rust/pull/68952 in the interpreter and some nearby modules :)
|
|
Add explanation for E0380
r? @Dylan-DPC
|
|
"vector" was used instead of "string"
|
|
const limit for CTFE
I tried to tackle the first steps for this issue.
The active feature flag does link to the issue below, I think this has to change, because there should be a tracking issue?
https://github.com/TheSamsa/rust/blob/1679a7647da0de672bac26b716db82d16f3896a8/src/librustc_feature/active.rs#L530
Also, I only put up the storage of the limit like "recursion_limit" but created a seperate file in the same place. Since I guess the invocation happens seperately.
https://github.com/TheSamsa/rust/blob/const-limit/src/librustc/middle/const_limit.rs
If this does not hold up for the issue and since there is a time pressure, just reject it.
hopefully this does not put more load on you than I expected...
|
|
(clippy::unnecessary_mut_passed)
|
|
|
|
closure. (clippy::expect_fun_call)
|
|
|
|
loops on iterators. (clippy::while_let_on_iterator)
|
|
it. (clippy::redundant_static_lifetimes)
|
|
(clippy::redundant_pattern)
|
|
submodules: update clippy from 8b7f7e66 to 74eae9dc
Changes:
````
Rustup to rust-lang/rust#69506
Revive rls integration test
use question mark operator
Add regression test
Use `try_eval_usize` over `eval_usize`
Add path for display trait
Use lang items instead of get_trait_def_id where possible
Update stderr
Don't lint debug formatting in debug impl
Whitelist unused attribute for use items.
add test for #5238
````
Makes clippy tests pass again.
r? @oli-obk
|
|
|
|
|
|
and renamed 'recursion_limit' in limits.rs to simple 'limit' because it does handle other limits too.
|
|
|
|
rename feature to const_eval_limit
|
|
defaults to 1_000_000
|
|
|
|
Correctly reject `TraitCandidate` in all cases
Follow up to #69255, addresses #69629.
When `self.select_trait_candidate(trait_ref)` returned `Err(_)`, `result` wasn't being set to `NoMatch`, causing invalid methods to be selected.
|
|
Follow up to #69255, fix #69629.
|
|
These were introduced since I last fixed most of these occurences. (clippy::clone_on_copy, clippy::single_char_pattern)
|
|
anything.
For example: `if let Some(_) = foo() {}` can be reduced to `if foo().is_some() {}` (clippy::redundant_pattern_matching)
|
|
(clippy::option_as_ref_deref)
|
|
Some(y)) (clippy::option_and_then_some)
|
|
The Result can be expect-unwrapped directly. (clippy::ok_expect)
|
|
|
|
Changes:
````
Apply suggestions from code review
Simplify if_chain.
Move NumericLiteral to its own module.
Included binary and octal cases.
Resolve false positives for hex int cast.
Test for unnecessary_cast of hex int literal.
run-rustfix
Lint `if let Some` in question_mark lint
Add restrictive pat use in full binded struct
Update test case answers to match cargo dev fmt
Ran cargo dev fmt
Rustup to rust-lang/rust#69506
Recommended changes from flip1995
Revive rls integration test
use question mark operator
Add regression test
Use `try_eval_usize` over `eval_usize`
Add path for display trait
Use lang items instead of get_trait_def_id where possible
Update stderr
Don't lint debug formatting in debug impl
Whitelist unused attribute for use items.
Fix one last test issue
Refactor suggested by krishna-veerareddy
Fixed compile error from merging
Changed test output to reflect cargo fmt
Run cargo dev fmt
Finished checking for cases of absolute values
add test for #5238
Some bugfixing
Created floating point abs lint and test, but not yet run
````
|
|
nightly: bootstrap from 1.42.0-beta.5 (4e1c5f0e9 2020-02-28)
This beta snapshot has the llvm miscompilation fix included and is bootstrapped from a stable version that also has it included.
|
|
|
|
|
|
|
|
update miri
Let's make that toolstate green again. :D
This bumps serde in the lockfile, so r? @oli-obk
Fixes https://github.com/rust-lang/rust/issues/69462
|
|
|
|
|
|
Stabilize assoc_int_consts associated int/float constants
The next step in RFC https://github.com/rust-lang/rfcs/pull/2700 (tracking issue #68490). Stabilizing the associated constants that were added in #68325.
* Stabilize all constants under the `assoc_int_consts` feature flag.
* Update documentation on old constants to say they are soft-deprecated and the new ones should be preferred.
* Update documentation examples to use new constants.
* Remove `uint_macro` and use `int_macro` for all integer types since the macros were identical anyway.
r? @LukasKalbertodt
|
|
interpret engine: Scalar cleanup
* Remove `to_ptr`
* Make `to_bits` private
r? @oli-obk
|
|
Rollup of 6 pull requests
Successful merges:
- #69565 (miri engine: turn some debug_assert into assert)
- #69621 (use question mark operator in a few places.)
- #69650 (cleanup more iterator usages (and other things))
- #69653 (use conditions directly)
- #69665 (Invoke OptimizerLastEPCallbacks in PreLinkThinLTO)
- #69670 (Add explanation for E0379)
Failed merges:
r? @ghost
|
|
Add explanation for E0379
r? @Dylan-DPC
|