-
Notifications
You must be signed in to change notification settings - Fork 12.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Clippy #108474
Update Clippy #108474
Commits on Feb 6, 2023
-
Configuration menu - View commit details
-
Copy full SHA for c6692a8 - Browse repository at this point
Copy the full SHA c6692a8View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8eac9e3 - Browse repository at this point
Copy the full SHA 8eac9e3View commit details
Commits on Feb 9, 2023
-
Introduce
-Zterminal-urls
to use OSC8 for error codesTerminals supporting the OSC8 Hyperlink Extension can support inline anchors where the text is user defineable but clicking on it opens a browser to a specified URLs, just like `<a href="URL">` does in HTML. https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda
Configuration menu - View commit details
-
Copy full SHA for 374c393 - Browse repository at this point
Copy the full SHA 374c393View commit details -
Configuration menu - View commit details
-
Copy full SHA for e2e23c0 - Browse repository at this point
Copy the full SHA e2e23c0View commit details -
Configuration menu - View commit details
-
Copy full SHA for cc19fbe - Browse repository at this point
Copy the full SHA cc19fbeView commit details
Commits on Feb 10, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 179c037 - Browse repository at this point
Copy the full SHA 179c037View commit details -
Configuration menu - View commit details
-
Copy full SHA for e7fe1f9 - Browse repository at this point
Copy the full SHA e7fe1f9View commit details -
Configuration menu - View commit details
-
Copy full SHA for cd3bcbb - Browse repository at this point
Copy the full SHA cd3bcbbView commit details -
Configuration menu - View commit details
-
Copy full SHA for 145e6a9 - Browse repository at this point
Copy the full SHA 145e6a9View commit details -
Configuration menu - View commit details
-
Copy full SHA for 5fefe8b - Browse repository at this point
Copy the full SHA 5fefe8bView commit details -
Clarify description of suspicious_command_arg_space.
Co-authored-by: Manish Goregaokar <manishsmail@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for 984c47b - Browse repository at this point
Copy the full SHA 984c47bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 8f56767 - Browse repository at this point
Copy the full SHA 8f56767View commit details -
Configuration menu - View commit details
-
Copy full SHA for 078f149 - Browse repository at this point
Copy the full SHA 078f149View commit details -
Configuration menu - View commit details
-
Copy full SHA for 805a0ae - Browse repository at this point
Copy the full SHA 805a0aeView commit details
Commits on Feb 11, 2023
-
Auto merge of rust-lang#107507 - BoxyUwU:deferred_projection_equality…
…, r=lcnr Implement `deferred_projection_equality` for erica solver Somewhat of a revival of rust-lang#96912. When relating projections now emit an `AliasEq` obligation instead of attempting to determine equality of projections that may not be as normalized as possible (i.e. because of lazy norm, or just containing inference variables that prevent us from resolving an impl). Only do this when the new solver is enabled
Configuration menu - View commit details
-
Copy full SHA for 863e96d - Browse repository at this point
Copy the full SHA 863e96dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 8789b37 - Browse repository at this point
Copy the full SHA 8789b37View commit details
Commits on Feb 12, 2023
-
Configuration menu - View commit details
-
Copy full SHA for d9dc167 - Browse repository at this point
Copy the full SHA d9dc167View commit details -
Configuration menu - View commit details
-
Copy full SHA for aeaa1cc - Browse repository at this point
Copy the full SHA aeaa1ccView commit details -
Auto merge of rust-lang#10330 - samueltardieu:10325, r=xFrednet
cast_possible_truncation: issue proper help message Fixes rust-lang#10325 --- changelog: Sugg: [`cast_possible_truncation`]: Corrected the lint name in help message [rust-lang#10330](rust-lang/rust-clippy#10330) <!-- changelog_checked-->
Configuration menu - View commit details
-
Copy full SHA for d880cae - Browse repository at this point
Copy the full SHA d880caeView commit details -
Configuration menu - View commit details
-
Copy full SHA for 21433ab - Browse repository at this point
Copy the full SHA 21433abView commit details -
Auto merge of rust-lang#10333 - samueltardieu:lintcheck-clap-panic, r…
…=flip1995 lintcheck: fix clap panic clap 4.1.4 panics if `-` is used at the start of an argument: ``` $ cargo lintcheck […] thread 'main' panicked at 'Argument recursive: long "--recursive" must not start with a `-`, that will be handled by the parser', /home/sam/.cargo/registry/src/github.com-1ecc6299db9ec823/clap-4.1.4/src/builder/debug_asserts.rs:82:13 ``` changelog: none <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for ad2135e - Browse repository at this point
Copy the full SHA ad2135eView commit details -
Configuration menu - View commit details
-
Copy full SHA for 09d3097 - Browse repository at this point
Copy the full SHA 09d3097View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1b286b1 - Browse repository at this point
Copy the full SHA 1b286b1View commit details -
Configuration menu - View commit details
-
Copy full SHA for e70a7a6 - Browse repository at this point
Copy the full SHA e70a7a6View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1ed8ed3 - Browse repository at this point
Copy the full SHA 1ed8ed3View commit details -
Auto merge of rust-lang#10310 - c410-f3r:arith-2, r=Alexendoo
[arithmetic_side_effects] Fix rust-lang#10209 Fix rust-lang#10209 --- changelog: Enhancement: [`arithmetic_side_effects`]: No longer lints, if safe constant values are used. [rust-lang#10310](rust-lang/rust-clippy#10310) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for 6f353fd - Browse repository at this point
Copy the full SHA 6f353fdView commit details -
Configuration menu - View commit details
-
Copy full SHA for 1f77866 - Browse repository at this point
Copy the full SHA 1f77866View commit details -
Auto merge of rust-lang#10317 - m-ou-se:suspicious-command-arg-space,…
… r=Manishearth Add `suspicious_command_arg_space` lint Fixes rust-lang#10316 --- changelog: New lint: [`suspicious_command_arg_space`] [rust-lang#10317](rust-lang/rust-clippy#10317) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for 298f139 - Browse repository at this point
Copy the full SHA 298f139View commit details
Commits on Feb 13, 2023
-
Configuration menu - View commit details
-
Copy full SHA for ebca1b5 - Browse repository at this point
Copy the full SHA ebca1b5View commit details -
Configuration menu - View commit details
-
Copy full SHA for e8e9c32 - Browse repository at this point
Copy the full SHA e8e9c32View commit details -
Configuration menu - View commit details
-
Copy full SHA for 340d9e8 - Browse repository at this point
Copy the full SHA 340d9e8View commit details -
Rollup merge of rust-lang#107838 - estebank:terminal_hyperlinks, r=na…
…gisa Introduce `-Zterminal-urls` to use OSC8 for error codes Terminals supporting the OSC8 Hyperlink Extension can support inline anchors where the text is user defineable but clicking on it opens a browser to a specified URLs, just like `<a href="URL">` does in HTML. https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda
Configuration menu - View commit details
-
Copy full SHA for b3077fb - Browse repository at this point
Copy the full SHA b3077fbView commit details -
Auto merge of rust-lang#10177 - chansuke:almost_swapped, r=Alexendoo
Almost swapped Take over from rust-lang/rust-clippy#8945 Fix rust-lang/rust-clippy#8151 --- changelog: enhancement: [`almost_swapped`]: Now detects almost swaps using `let` statements [rust-lang#10177](rust-lang/rust-clippy#10177) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for ac60dca - Browse repository at this point
Copy the full SHA ac60dcaView commit details -
Auto merge of rust-lang#107924 - eggyal:move_fold_visit_traits_to_typ…
…e_lib_with_trait_alias, r=oli-obk Move folding & visiting traits into type library This is a rework of rust-lang#107712, following feedback on that PR. In particular, this version uses trait aliases to reduce the API churn for trait consumers. Doing so requires a workaround for rust-lang#107747 until its fix in rust-lang#107803 is merged into the stage0 compiler; this workaround, which uses conditional compilation based on the `bootstrap` configuration predicate, sits in dedicated commit b409329 for ease of reversion. The possibility of the `rustc_middle` crate retaining its own distinct versions of each folding/visiting trait, blanket-implemented on all types that implement the respective trait in the type library, was also explored: however since this would necessitate making each `rustc_middle` trait a subtrait of the respective type library trait (so that such blanket implementations can delegate their generic methods), no benefit would be gained. r? types
Configuration menu - View commit details
-
Copy full SHA for 42d4bd7 - Browse repository at this point
Copy the full SHA 42d4bd7View commit details -
Auto merge of rust-lang#10334 - samueltardieu:book-warning-text, r=Ma…
…nishearth book: move warning to the right place changelog: none
Configuration menu - View commit details
-
Copy full SHA for 63562a6 - Browse repository at this point
Copy the full SHA 63562a6View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4b8f112 - Browse repository at this point
Copy the full SHA 4b8f112View commit details -
This lint complains when the question mark operator (try operator) is used. This is a restriction lint that can be useful on local scopes where a custom error handling macro is supposed to be used to augment the error based on local scope data before returning.
Configuration menu - View commit details
-
Copy full SHA for 89314a0 - Browse repository at this point
Copy the full SHA 89314a0View commit details -
Remove useless call to combine_seq
`combine_seq(x, NeverLoopResult::Otherwise)` always returns `x`
Configuration menu - View commit details
-
Copy full SHA for c231b41 - Browse repository at this point
Copy the full SHA c231b41View commit details -
Replace combine_both by combine_seq
All evaluations now happen in order.
Configuration menu - View commit details
-
Copy full SHA for 1fec292 - Browse repository at this point
Copy the full SHA 1fec292View commit details
Commits on Feb 14, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 8e96ade - Browse repository at this point
Copy the full SHA 8e96adeView commit details -
Fix a bug in never_loop when anonymous blocks are nested in named blocks
The following code ``` loop { 'a: { { } break 'a; } } ``` was detected as a never-looping loop.
Configuration menu - View commit details
-
Copy full SHA for e9dffa3 - Browse repository at this point
Copy the full SHA e9dffa3View commit details -
Configuration menu - View commit details
-
Copy full SHA for e3a739a - Browse repository at this point
Copy the full SHA e3a739aView commit details -
Ignore instructions following a break from block in never_loop lint
It is not sufficient to ignore break from a block inside the loop. Instructions after the break must be ignored, as they are unreachable. This is also true for all instructions in outer blocks and loops until the right block is reached.
Configuration menu - View commit details
-
Copy full SHA for 657ee48 - Browse repository at this point
Copy the full SHA 657ee48View commit details -
Configuration menu - View commit details
-
Copy full SHA for e4e5924 - Browse repository at this point
Copy the full SHA e4e5924View commit details -
Rollup merge of rust-lang#108007 - compiler-errors:str-less-kind, r=N…
…ilstrieb Use `is_str` instead of string kind comparison Split out from rust-lang#107939
Configuration menu - View commit details
-
Copy full SHA for b8c3642 - Browse repository at this point
Copy the full SHA b8c3642View commit details -
Auto merge of rust-lang#10311 - samueltardieu:issue-10304, r=Jarcho
[never_loop] Fix rust-lang#10304 It is not sufficient to ignore break from a block inside the loop. Instructions after the break must be ignored, as they are unreachable. This is also true for all instructions in outer blocks and loops until the right block is reached. Fixes rust-lang#10304 --- changelog: FP: [`never_loop`]: No longer lints, for statements following break statements for outer blocks. [rust-lang#10311](rust-lang/rust-clippy#10311) <!-- changelog_checked-->
Configuration menu - View commit details
-
Copy full SHA for a182a67 - Browse repository at this point
Copy the full SHA a182a67View commit details -
Configuration menu - View commit details
-
Copy full SHA for e41c373 - Browse repository at this point
Copy the full SHA e41c373View commit details -
Auto merge of rust-lang#108056 - matthiaskrgr:rollup-oa6bxvh, r=matth…
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#107573 (Update the minimum external LLVM to 14) - rust-lang#107626 (Fix `x fix` on the standard library itself) - rust-lang#107673 (update ICU4X to 1.1.0) - rust-lang#107733 (Store metrics from `metrics.json` to CI PGO timer) - rust-lang#108007 (Use `is_str` instead of string kind comparison) - rust-lang#108033 (add an unstable `#[rustc_coinductive]` attribute) - rust-lang#108039 (Refactor refcounted structural_impls via functors) - rust-lang#108040 (Use derive attributes for uninteresting traversals) - rust-lang#108044 (interpret: rename Pointer::from_addr → from_addr_invalid) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Configuration menu - View commit details
-
Copy full SHA for 5a8b288 - Browse repository at this point
Copy the full SHA 5a8b288View commit details -
Auto merge of rust-lang#10346 - samueltardieu:issue-10331, r=Manishearth
Do not base map_entry lint suggestion on expanded code Fixes rust-lang#10331 changelog: [`map_entry`]: do not base suggestion on code expanded by the compiler
Configuration menu - View commit details
-
Copy full SHA for 0e40f94 - Browse repository at this point
Copy the full SHA 0e40f94View commit details -
Configuration menu - View commit details
-
Copy full SHA for 17cb2e4 - Browse repository at this point
Copy the full SHA 17cb2e4View commit details -
manual_let_else: let/else is not divergent by default
The divergent `else` block of a `let`/`else` statement does not make the `let`/`else` statement itself divergent.
Configuration menu - View commit details
-
Copy full SHA for 7f15a11 - Browse repository at this point
Copy the full SHA 7f15a11View commit details -
Auto merge of rust-lang#10332 - samueltardieu:issue-10296, r=Alexendoo
manual_let_else: let/else is not divergent by default The divergent `else` block of a `let`/`else` statement does not make the `let/else` statement itself divergent. Fixes rust-lang#10296 changelog: [`manual_let_else`]: do not consider `let`/`else` to be divergent by default
Configuration menu - View commit details
-
Copy full SHA for 4c28fdd - Browse repository at this point
Copy the full SHA 4c28fddView commit details
Commits on Feb 15, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 8b93eb8 - Browse repository at this point
Copy the full SHA 8b93eb8View commit details -
Auto merge of rust-lang#10328 - compiler-errors:fix-re-erased-in-need…
…less_pass_by_value, r=matthiaskrgr Liberate late-bound regions rather than erasing them in `needless_pass_by_value` changelog: [`needless_pass_by_value`]: fixes an ICE when there are late-bound regions in function arguments that are needlessly passed by value Fixes rust-lang#107147 r? `@matthiaskrgr`
Configuration menu - View commit details
-
Copy full SHA for e018a2c - Browse repository at this point
Copy the full SHA e018a2cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 75aa2b9 - Browse repository at this point
Copy the full SHA 75aa2b9View commit details -
Use target instead of machine for mir interpreter integer handling.
The naming of `machine` only makes sense from a mir interpreter internals perspective, but outside users talk about the `target` platform
Configuration menu - View commit details
-
Copy full SHA for cecc45c - Browse repository at this point
Copy the full SHA cecc45cView commit details -
Auto merge of rust-lang#10345 - J-ZhengLi:issue_10049, r=xFrednet
fix [`needless_return`] incorrect suggestion when returning if sequence fixes: rust-lang#10049 --- changelog: [`needless_return`]: fix incorrect suggestion on if sequence
Configuration menu - View commit details
-
Copy full SHA for d3d235d - Browse repository at this point
Copy the full SHA d3d235dView commit details -
Auto merge of rust-lang#10343 - samueltardieu:issue-10339, r=Alexendoo
uninlined_format_args: do not inline argument with generic parameters Fix rust-lang#10339 --- changelog: FP: [`uninlined_format_args`]: No longer lints for arguments with generic parameters [rust-lang#10343](rust-lang/rust-clippy#10343) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for 8754d5a - Browse repository at this point
Copy the full SHA 8754d5aView commit details -
Auto merge of rust-lang#10321 - mkrasnitski:false-positives, r=flip1995
Fix false positives for `extra_unused_type_parameters` Don't lint external macros. Also, if the function body is empty, any type parameters with bounds on them are not linted. Note that only the body needs be empty - this rule still applies if the function takes any arguments. fixes rust-lang#10318 fixes rust-lang#10319 changelog: none <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for 595f783 - Browse repository at this point
Copy the full SHA 595f783View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1ee4651 - Browse repository at this point
Copy the full SHA 1ee4651View commit details -
Auto merge of rust-lang#10338 - mkrasnitski:synthetic-params, r=flip1995
Ignore synthetic type parameters for `extra_unused_type_parameters` There was a minor bug around calculating spans when forming the help message. An example: ```rust fn unused_opaque<A, B>(dummy: impl Default) {} // ^^ ^ ``` In this case, the entire list of generics should be highlighted, instead of each individual parameter. The culprit is the `impl Default`, which registers as a type parameter but doesn't live within the `<...>`. Because synthetic parameters can't ever be manually created, we just ignore them for this lint. r? `@flip1995` changelog: none <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for 5b6795f - Browse repository at this point
Copy the full SHA 5b6795fView commit details -
Auto merge of rust-lang#108006 - cjgillot:def-impl, r=oli-obk
Avoid accessing HIR when it can be avoided Experiment to see if it helps some incremental cases. Will be rebased once rust-lang#107942 gets merged. r? `@ghost`
Configuration menu - View commit details
-
Copy full SHA for 30f38d6 - Browse repository at this point
Copy the full SHA 30f38d6View commit details -
As this is a lint about "style", and a purely cosmetical choice (using `<A: Trait>` over `impl Trait`), a lot of other files needed to be allowed this lint.
Configuration menu - View commit details
-
Copy full SHA for 8ec9543 - Browse repository at this point
Copy the full SHA 8ec9543View commit details -
Rollup merge of rust-lang#108047 - oli-obk:machine->🞋, r=RalfJung
Use `target` instead of `machine` for mir interpreter integer handling. The naming of `machine` only makes sense from a mir interpreter internals perspective, but outside users talk about the `target` platform. As per rust-lang#108029 (comment) r? `@RalfJung`
Configuration menu - View commit details
-
Copy full SHA for dd6534a - Browse repository at this point
Copy the full SHA dd6534aView commit details -
Configuration menu - View commit details
-
Copy full SHA for ade4c9b - Browse repository at this point
Copy the full SHA ade4c9bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6c9983b - Browse repository at this point
Copy the full SHA 6c9983bView commit details -
Configuration menu - View commit details
-
Copy full SHA for bdf4fd3 - Browse repository at this point
Copy the full SHA bdf4fd3View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8a2245d - Browse repository at this point
Copy the full SHA 8a2245dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6aa06b7 - Browse repository at this point
Copy the full SHA 6aa06b7View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4166b7d - Browse repository at this point
Copy the full SHA 4166b7dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6ef34bf - Browse repository at this point
Copy the full SHA 6ef34bfView commit details
Commits on Feb 16, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 27a4768 - Browse repository at this point
Copy the full SHA 27a4768View commit details -
Configuration menu - View commit details
-
Copy full SHA for f12b492 - Browse repository at this point
Copy the full SHA f12b492View commit details -
Auto merge of rust-lang#10353 - nindalf:master, r=llogiq
Change unusual_byte_groupings to require byte groupings of equal size Fixes issue rust-lang#6556 This lint required byte groupings of size 2 or 4 for `Radix::Binary` and `Radix::Hexadecimal`. Since there are good reasons for allowing groups of other sizes, this PR relaxes the restriction. This lint now requires that - group sizes after the first group be of the same size and - greater or equal in size to the first group. --- changelog: [`unusual_byte_groupings`]: reduce false positives by relaxing restriction requiring groups of specific sizes.
Configuration menu - View commit details
-
Copy full SHA for 86fb33a - Browse repository at this point
Copy the full SHA 86fb33aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 2d4d39d - Browse repository at this point
Copy the full SHA 2d4d39dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0933798 - Browse repository at this point
Copy the full SHA 0933798View commit details -
Configuration menu - View commit details
-
Copy full SHA for 0b1ae20 - Browse repository at this point
Copy the full SHA 0b1ae20View commit details -
Auto merge of rust-lang#10163 - c410-f3r:lock-1, r=llogiq
[significant_drop_tightening] Add MVP cc rust-lang#9399 Creates the lint with minimum functionalities, which is a good start IMO. --- changelog: new lint: [`significant_drop_tightening`] [rust-lang#10163](rust-lang/rust-clippy#10163) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for 4369a67 - Browse repository at this point
Copy the full SHA 4369a67View commit details -
Auto merge of rust-lang#10356 - JirkaVebr:let_underscore_untyped, r=l…
…logiq Add `let_underscore_untyped` Fixes rust-lang#6842 This adds a new pedantic `let_underscore_untyped` lint which checks for `let _ = <expr>`, and suggests to either provide a type annotation, or to remove the `let` keyword. That way the author is forced to specify the type they intended to ignore, and thus get forced to re-visit the decision should the type of `<expr>` change. Alternatively, they can drop the `let` keyword to truly just ignore the value no matter what. r? `@llogiq` changelog: New lint: [let_underscore_untyped]
Configuration menu - View commit details
-
Copy full SHA for 99d4ea4 - Browse repository at this point
Copy the full SHA 99d4ea4View commit details -
Auto merge of rust-lang#10342 - mitsuhiko:feature/question-mark-used,…
… r=Alexendoo Add question-mark-used lint This lint complains when the question mark operator (try operator) is used. This is a restriction lint that can be useful on local scopes where a custom error handling macro is supposed to be used to augment the error based on local scope data before returning. Fixes rust-lang#10340 --- changelog: New lint [`question_mark_used`] [rust-lang#10342](rust-lang/rust-clippy#10342) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for 52c8b53 - Browse repository at this point
Copy the full SHA 52c8b53View commit details -
Configuration menu - View commit details
-
Copy full SHA for 9c9dbc2 - Browse repository at this point
Copy the full SHA 9c9dbc2View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6d0df84 - Browse repository at this point
Copy the full SHA 6d0df84View commit details -
Auto merge of rust-lang#10360 - JirkaVebr:transmute_integer_to_non_ze…
…ro_wrapper, r=llogiq Add the `transmute_int_to_non_zero` lint Fixes rust-lang#10288 This adds a new complexity lint `transmute_int_to_non_zero` which checks for transmutes to any of the `NonZero*` types, and suggests their `new_unchecked` method instead. r? `@llogiq` changelog: New lint: [`transmute_int_to_non_zero`]
Configuration menu - View commit details
-
Copy full SHA for dfe23dc - Browse repository at this point
Copy the full SHA dfe23dcView commit details -
Configuration menu - View commit details
-
Copy full SHA for 64b8aaf - Browse repository at this point
Copy the full SHA 64b8aafView commit details -
Configuration menu - View commit details
-
Copy full SHA for 7e53e27 - Browse repository at this point
Copy the full SHA 7e53e27View commit details -
Auto merge of rust-lang#10357 - nindalf:doc_markdown_relax, r=llogiq
Stop doc_markdown requiring backticks on links to external websites Fixes rust-lang#10302 This lint currently checks that any link should be enclosed with `backticks` if the title looks like a lang item. This PR changes the lint to only run on internal links. External links, indicated by `http` or `https`, are skipped. This PR also reorganises `pulldown_cmark` imports to bypass the clippy lint enforcing 100 line functions. --- changelog: Stop doc_markdown requiring backticks on links to external websites
Configuration menu - View commit details
-
Copy full SHA for be74773 - Browse repository at this point
Copy the full SHA be74773View commit details -
Auto merge of rust-lang#10361 - nindalf:nth_bytes_copy, r=llogiq
Stop bytes_nth from suggesting code that does not compile Fixes rust-lang#10151 As discussed in the issue, this PR changes the lint in 2 ways 1. Replace `bytes().nth(n).unwrap()` with `as_bytes()[n]` 2. Replace other `bytes().nth(n)` with `as_bytes().get(n).copied()` --- changelog: Stop bytes_nth from suggesting code that does not compile in some cases
Configuration menu - View commit details
-
Copy full SHA for eac0bd9 - Browse repository at this point
Copy the full SHA eac0bd9View commit details -
Auto merge of rust-lang#10336 - samueltardieu:issue-10241, r=llogiq
manual_let_else: do not suggest semantically different replacements The problem is that this lint does not consider the possibility that the divergent branch can come first and that the patterns may overlap. This led to incorrect suggestions, previously registered as correct in the tests themselves: ```rust let v = match build_enum() { _ => continue, Variant::Bar(v) | Variant::Baz(v) => v, }; ``` had a `let Variant::Bar(v) | Variant::Baz(v) = v else { continue; }` suggestion, which is obviously wrong as the original code `continue`s in any case. Issue rust-lang#10241 gives another example. The code now checks that the divergent branch comes second. It could be extended later (I've added a TODO) to check for non-overlapping patterns. Fixes rust-lang#10241. changelog: [`manual_let_else`] do not suggest non equivalent replacements in `match`
Configuration menu - View commit details
-
Copy full SHA for 6444621 - Browse repository at this point
Copy the full SHA 6444621View commit details -
Configuration menu - View commit details
-
Copy full SHA for 747f81e - Browse repository at this point
Copy the full SHA 747f81eView commit details -
Rollup merge of rust-lang#107489 - compiler-errors:non_lifetime_binde…
…rs, r=cjgillot Implement partial support for non-lifetime binders This implements support for non-lifetime binders. It's pretty useless currently, but I wanted to put this up so the implementation can be discussed. Specifically, this piggybacks off of the late-bound lifetime collection code in `rustc_hir_typeck::collect::lifetimes`. This seems like a necessary step given the fact we don't resolve late-bound regions until this point, and binders are sometimes merged. Q: I'm not sure if I should go along this route, or try to modify the earlier nameres code to compute the right bound var indices for type and const binders eagerly... If so, I'll need to rename all these queries to something more appropriate (I've done this for `resolve_lifetime::Region` -> `resolve_lifetime::ResolvedArg`) cc rust-lang/types-team#81 r? `@ghost`
Configuration menu - View commit details
-
Copy full SHA for cc60e21 - Browse repository at this point
Copy the full SHA cc60e21View commit details
Commits on Feb 17, 2023
-
Configuration menu - View commit details
-
Copy full SHA for f0565c9 - Browse repository at this point
Copy the full SHA f0565c9View commit details -
remove bound_type_of query; make type_of return EarlyBinder; change t…
…ype_of in metadata
Configuration menu - View commit details
-
Copy full SHA for 98c4a49 - Browse repository at this point
Copy the full SHA 98c4a49View commit details -
Auto merge of rust-lang#107753 - kylematsuda:type-of, r=BoxyUwU
Switch to `EarlyBinder` for `type_of` query Part of the work to finish rust-lang#105779 and implement rust-lang/types-team#78. Several queries `X` have a `bound_X` variant that wraps the output in `EarlyBinder`. This adds `EarlyBinder` to the return type of the `type_of` query and removes `bound_type_of`. r? `@lcnr`
Configuration menu - View commit details
-
Copy full SHA for 9554045 - Browse repository at this point
Copy the full SHA 9554045View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8a66a68 - Browse repository at this point
Copy the full SHA 8a66a68View commit details -
Replace
mk_foo
calls withinfer_foo
where possible.There are several `mk_foo`/`intern_foo` pairs, where the former takes an iterator and the latter takes a slice. (This naming convention is bad, but that's a fix for another PR.) This commit changes several `mk_foo` occurrences into `intern_foo`, avoiding the need for some `.iter()`/`.into_iter()` calls. Affected cases: - mk_type_list - mk_tup - mk_substs - mk_const_list
Configuration menu - View commit details
-
Copy full SHA for ae12b72 - Browse repository at this point
Copy the full SHA ae12b72View commit details -
Configuration menu - View commit details
-
Copy full SHA for a3837c6 - Browse repository at this point
Copy the full SHA a3837c6View commit details -
Configuration menu - View commit details
-
Copy full SHA for c29e767 - Browse repository at this point
Copy the full SHA c29e767View commit details
Commits on Feb 18, 2023
-
Auto merge of rust-lang#108112 - nnethercote:clarify-iterator-interne…
…rs, r=oli-obk,compiler-errors Clarify iterator interners I found the iterator interners very confusing. This PR clarifies things. r? `@compiler-errors`
Configuration menu - View commit details
-
Copy full SHA for c0373f5 - Browse repository at this point
Copy the full SHA c0373f5View commit details -
Auto merge of rust-lang#10363 - c410-f3r:lock-1, r=xFrednet
[significant_drop_tightening] Ignore inexpensive statements Not all statements that follow the last use of a lock guard are expensive and can therefore be ignored by the lint. ```rust pub fn foo() -> i32 { let mutex = Mutex::new(1); let lock = mutex.lock().unwrap(); let rslt = *lock; let another = rslt; another } ``` --- changelog: [`significant_drop_tightening`]: No longer lints for inexpensive statements after the lock guard [rust-lang#10363](rust-lang/rust-clippy#10363) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for e1da002 - Browse repository at this point
Copy the full SHA e1da002View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7518969 - Browse repository at this point
Copy the full SHA 7518969View commit details -
Auto merge of rust-lang#10368 - c410-f3r:lock-1, r=xFrednet
[significant_drop_tightening] Evaluate the return expression of a block For whatever reason, the return expression of a block is not contained inside the slice of statements and because of that the lint wasn't evaluating things that could potentially block the release of a lock. ```rust pub fn example() -> i32 { let mutex = Mutex::new(1); let lock = mutex.lock().unwrap(); let _ = *lock; let _ = *lock; do_heavy_computation_that_takes_time_and_returns_i32() } ``` --- changelog: none <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for 85d4b5a - Browse repository at this point
Copy the full SHA 85d4b5aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 89fde4a - Browse repository at this point
Copy the full SHA 89fde4aView commit details
Commits on Feb 20, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 0905838 - Browse repository at this point
Copy the full SHA 0905838View commit details -
Box::default(): do not omit the type of the removed trait object
Within a larger expression, when the type of `Box::new(T::default())` is `Box<dyn Trait>`, the concrete type `T` cannot be omitted in the proposed replacement `Box::<T>::default()`.
Configuration menu - View commit details
-
Copy full SHA for 92c403c - Browse repository at this point
Copy the full SHA 92c403cView commit details -
Auto merge of rust-lang#10382 - samueltardieu:issue-10381, r=llogiq
Box::default(): do not omit the type of the removed trait object Within a larger expression, when the type of `Box::new(T::default())` is `Box<dyn Trait>`, the concrete type `T` cannot be omitted in the proposed replacement `Box::<T>::default()`. Fixes rust-lang#10381 changelog: [`box_default`]: in case of a trait object do not omit the concrete type name
Configuration menu - View commit details
-
Copy full SHA for 574c8ae - Browse repository at this point
Copy the full SHA 574c8aeView commit details -
Configuration menu - View commit details
-
Copy full SHA for 790f28b - Browse repository at this point
Copy the full SHA 790f28bView commit details -
Auto merge of rust-lang#10303 - pvdrz:pub_crate_missing_docs, r=giraf…
…fate Add configuration to lint missing docs of `pub(crate)` items Fixes this: rust-lang/rust-clippy#5736 (comment) TODO: - [x] Needs docs - [x] Needs better names - [x] Should `pub` items be checked to when this new option is enabled? I'm saying no because `missing_docs` already exists `@flip1995` I'd like to get some input from you :) --- changelog: Enhancement: [`missing_docs_in_private_items`]: Added new configuration `missing-docs-in-crate-items` to lint on items visible within the current crate. For example, `pub(crate)` items. [rust-lang#10303](rust-lang/rust-clippy#10303) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for b1cf1e7 - Browse repository at this point
Copy the full SHA b1cf1e7View commit details
Commits on Feb 21, 2023
-
Use
ThinVec
in various AST types.This commit changes the sequence parsers to produce `ThinVec`, which triggers numerous conversions.
Configuration menu - View commit details
-
Copy full SHA for 71b8646 - Browse repository at this point
Copy the full SHA 71b8646View commit details -
Auto merge of rust-lang#10197 - blyxyas:impl_trait_param, r=Jarcho
Add `impl_trait_in_params` lint As this is a lint about style, and using `impl Trait` is purely cosmetical (even with downsides), a lot of unrelated files needed to allow this lint. --- Resolves rust-lang#10030 changelog: New lint: [`impl_trait_in_params`] [10197](rust-lang/rust-clippy#10197) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for 5ef3cc8 - Browse repository at this point
Copy the full SHA 5ef3cc8View commit details -
Auto merge of rust-lang#10380 - Alexendoo:needless-lifetime-macro-exp…
…ansion, r=xFrednet Ignore lifetimes from differing contexts in `needless_lifetimes` Fixes rust-lang#10379 changelog: [`needless_lifetimes`]: Don't lint signatures in macros if the lifetime is a metavariable
Configuration menu - View commit details
-
Copy full SHA for 803ce88 - Browse repository at this point
Copy the full SHA 803ce88View commit details -
Configuration menu - View commit details
-
Copy full SHA for 0aad34e - Browse repository at this point
Copy the full SHA 0aad34eView commit details -
Auto merge of rust-lang#10386 - Jarcho:issue_10384, r=Manishearth
Normalize projections types when checking `explicit_auto_deref` fixes rust-lang#10384 changelog: [`explicit_auto_deref`]: Better consider projection types when checking if auto deref is applicable
Configuration menu - View commit details
-
Copy full SHA for 5166882 - Browse repository at this point
Copy the full SHA 5166882View commit details
Commits on Feb 22, 2023
-
Configuration menu - View commit details
-
Copy full SHA for bf7c209 - Browse repository at this point
Copy the full SHA bf7c209View commit details -
errors: generate typed identifiers in each crate
Instead of loading the Fluent resources for every crate in `rustc_error_messages`, each crate generates typed identifiers for its own diagnostics and creates a static which are pulled together in the `rustc_driver` crate and provided to the diagnostic emitter. Signed-off-by: David Wood <david.wood@huawei.com>
Configuration menu - View commit details
-
Copy full SHA for aa0e543 - Browse repository at this point
Copy the full SHA aa0e543View commit details -
various: translation resources from cg backend
Extend `CodegenBackend` trait with a function returning the translation resources from the codegen backend, which can be added to the complete list of resources provided to the emitter. Signed-off-by: David Wood <david.wood@huawei.com>
Configuration menu - View commit details
-
Copy full SHA for ab69a2a - Browse repository at this point
Copy the full SHA ab69a2aView commit details -
Auto merge of rust-lang#10385 - Jarcho:readme_restriction, r=xFrednet
Update readme description of `restriction` lints to dissuade casual use. Adds some stronger wording about not enabling `restriction` lints. I've seen it come up a few times where people are confused about what the `restriction` category is for and end up casually enabling lints from it (or the whole category). changelog: None
Configuration menu - View commit details
-
Copy full SHA for 8d08917 - Browse repository at this point
Copy the full SHA 8d08917View commit details -
Configuration menu - View commit details
-
Copy full SHA for 72e773f - Browse repository at this point
Copy the full SHA 72e773fView commit details -
Configuration menu - View commit details
-
Copy full SHA for b9c617a - Browse repository at this point
Copy the full SHA b9c617aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 1a474d9 - Browse repository at this point
Copy the full SHA 1a474d9View commit details -
Configuration menu - View commit details
-
Copy full SHA for a5acb92 - Browse repository at this point
Copy the full SHA a5acb92View commit details -
Configuration menu - View commit details
-
Copy full SHA for 79a9024 - Browse repository at this point
Copy the full SHA 79a9024View commit details -
Configuration menu - View commit details
-
Copy full SHA for d254516 - Browse repository at this point
Copy the full SHA d254516View commit details -
Configuration menu - View commit details
-
Copy full SHA for 430c4ab - Browse repository at this point
Copy the full SHA 430c4abView commit details -
Auto merge of rust-lang#108340 - eggyal:remove_traversal_trait_aliase…
…s, r=oli-obk Remove type-traversal trait aliases rust-lang#107924 moved the type traversal (folding and visiting) traits into the type library, but created trait aliases in `rustc_middle` to minimise both the API churn for trait consumers and the arising boilerplate. As mentioned in that PR, an alternative approach of defining subtraits with blanket implementations of the respective supertraits was also considered at that time but was ruled out as not adding much value. Unfortunately, it has since emerged that rust-analyzer has difficulty with these trait aliases at present, resulting in a degraded contributor experience (see the recent [r-a has become useless](https://rust-lang.zulipchat.com/#narrow/stream/182449-t-compiler.2Fhelp/topic/r-a.20has.20become.20useless) topic on the #t-compiler/help Zulip stream). This PR removes the trait aliases, and accordingly the underlying type library traits are now used directly; they are parameterised by `TyCtxt<'tcx>` rather than just the `'tcx` lifetime, and imports have been updated to reflect the fact that the trait aliases' explicitly named traits are no longer automatically brought into scope. These changes also roll-back the (no-longer required) workarounds to rust-lang#107747 that were made in b409329. Since this PR is just a find+replace together with the changes necessary for compilation & tidy to pass, it's currently just one mega-commit. Let me know if you'd like it broken up. r? `@oli-obk`
Configuration menu - View commit details
-
Copy full SHA for 95cd528 - Browse repository at this point
Copy the full SHA 95cd528View commit details
Commits on Feb 23, 2023
-
Auto merge of rust-lang#108324 - notriddle:notriddle/assoc-fn-method,…
… r=compiler-errors,davidtwco,estebank,oli-obk diagnostics: if AssocFn has self argument, describe as method Discussed in https://rust-lang.zulipchat.com/#narrow/stream/147480-t-compiler.2Fwg-diagnostics/topic/.22associated.20function.22.20vs.20.22method.22/near/329265515 This commit also changes the tooltips on rustdoc intra-doc links targeting methods. For anyone not sure why this is being done, see the Reference definitions of these terms in <https://doc.rust-lang.org/1.67.1/reference/items/associated-items.html#methods> > Associated functions whose first parameter is named `self` are called methods and may be invoked using the [method call operator](https://doc.rust-lang.org/1.67.1/reference/expressions/method-call-expr.html), for example, `x.foo()`, as well as the usual function call notation. In particular, while this means it's technically correct for rustc to refer to a method as an associated function (and there are a few cases where it'll still do so), rustc *must never* use the term "method" to refer to an associated function that does not have a `self` parameter.
Configuration menu - View commit details
-
Copy full SHA for daa94d2 - Browse repository at this point
Copy the full SHA daa94d2View commit details -
Configuration menu - View commit details
-
Copy full SHA for 528bb63 - Browse repository at this point
Copy the full SHA 528bb63View commit details -
Auto merge of rust-lang#10392 - mkrasnitski:false-positives, r=Jarcho
Fix more false positives for `extra_unused_type_parameters` Builds on rust-lang#10321. All empty functions are no longer linted, instead of just those that have trait bounds on them. Also, if a trait bound contains a non-public trait (un-exported, but still potentially reachable), then the corresponding type parameter isn't linted. Finally, added support for the `avoid_breaking_exported_api` config option. r? `@flip1995` changelog: none
Configuration menu - View commit details
-
Copy full SHA for f9adb83 - Browse repository at this point
Copy the full SHA f9adb83View commit details -
Configuration menu - View commit details
-
Copy full SHA for 00c294a - Browse repository at this point
Copy the full SHA 00c294aView commit details -
Auto merge of rust-lang#10369 - nindalf:no_mangle_lint, r=llogiq
Add new lint no_mangle_with_rust_abi Fixes issue rust-lang#10347 This PR adds a new lint `no_mangle_with_rust_abi` that suggests converting a function to the C ABI to if the function has the `#[no_mangle]` attribute and `Abi == Abi::Rust`. It will not run for any of the other variants defined in [rustc_target::spec::abi::Abi](https://doc.rust-lang.org/beta/nightly-rustc/rustc_target/spec/abi/enum.Abi.html), nor suggest any conversion other than conversion to the C ABI. Functions that explicitly opt into the Rust ABI with `extern "Rust"` are ignored by this lint. --- changelog: [`no_mangle_with_rust_abi`]: add lint that converts Rust ABI functions with the `#[no_mangle]` attribute to C ABI
Configuration menu - View commit details
-
Copy full SHA for 659112c - Browse repository at this point
Copy the full SHA 659112cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 84ceca8 - Browse repository at this point
Copy the full SHA 84ceca8View commit details
Commits on Feb 24, 2023
-
Auto merge of rust-lang#10391 - ldm0:ldm0_fix_unwrap_in_tests, r=xFre…
…dnet Fix test function checker in `unwrap_used`, `expect_used` After rust-lang#9686 , `unwrap` and `expect` in integration tests and raw test functions won't be allowed. fixes rust-lang#10011 fixes rust-lang#10238 fixes rust-lang#10264 --- changelog: Fix: [`expect_used`], [`unwrap_used`], [`dbg_macro`], [`print_stdout`], [`print_stderr`]: No longer lint in test functions, if the related configuration is set [rust-lang#10391](rust-lang/rust-clippy#10391) <!-- changelog_checked -->
Configuration menu - View commit details
-
Copy full SHA for b528cc9 - Browse repository at this point
Copy the full SHA b528cc9View commit details
Commits on Feb 25, 2023
-
Configuration menu - View commit details
-
Copy full SHA for bc184e9 - Browse repository at this point
Copy the full SHA bc184e9View commit details -
Configuration menu - View commit details
-
Copy full SHA for 5552f4a - Browse repository at this point
Copy the full SHA 5552f4aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 64775f3 - Browse repository at this point
Copy the full SHA 64775f3View commit details -
Auto merge of rust-lang#10401 - samueltardieu:issue-10148, r=Alexendoo
Do not panic when analyzing the malformed origin of a format string Fixes rust-lang#10148. This will trigger only when generating format strings while accepting weird things in a procedural macro and setting the span to something which is not a string. changelog: none
Configuration menu - View commit details
-
Copy full SHA for 5155119 - Browse repository at this point
Copy the full SHA 5155119View commit details -
Configuration menu - View commit details
-
Copy full SHA for e825adf - Browse repository at this point
Copy the full SHA e825adfView commit details -
Configuration menu - View commit details
-
Copy full SHA for 69c4ff6 - Browse repository at this point
Copy the full SHA 69c4ff6View commit details -
Auto merge of rust-lang#10402 - Jarcho:rustup, r=Jarcho
Rustup Looks like `@flip1995` is busy. r? `@ghost` changelog: None
Configuration menu - View commit details
-
Copy full SHA for 149392b - Browse repository at this point
Copy the full SHA 149392bView commit details
Commits on Feb 26, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 4a2de63 - Browse repository at this point
Copy the full SHA 4a2de63View commit details