Skip to content

Update the global lint configuration#5218

Merged
tgross35 merged 4 commits into
rust-lang:mainfrom
tgross35:lint-cfg
Jun 25, 2026
Merged

Update the global lint configuration#5218
tgross35 merged 4 commits into
rust-lang:mainfrom
tgross35:lint-cfg

Conversation

@tgross35

@tgross35 tgross35 commented Jun 25, 2026

Copy link
Copy Markdown
Contributor
  • Don't completely ignore overflowing_literals. This is the main thing
    since this lint catches things like u64-sized constants being
    assigned to a c_long, which is too small on 32-bit platforms.
  • safe_packed_borrows is now a hard error, we don't need to explicitly
    set the level.
  • Drop renamed_and_removed_lints and unknown_lints since we are now
    more selective about tested versions.

Closes: #4141

@tgross35 tgross35 force-pushed the lint-cfg branch 4 times, most recently from 9ec7c2a to a00baff Compare June 25, 2026 09:00
@rustbot rustbot added the A-CI Area: CI-related items label Jun 25, 2026
@rustbot

This comment has been minimized.

tgross35 added 4 commits June 25, 2026 14:59
Most of these just need a conversion function to assert that wrapping
values are okay to assign to signed int types. There are a few
corrections:

* Android `PR_SET_PTRACER_ANY`: https://cs.android.com/android/platform/superproject/+/android-latest-release:bionic/libc/kernel/uapi/linux/prctl.h;l=101;drc=19d5053f12cafecac5174e4c7af4c9fdfd7bcae0
* Linux `PR_SET_PTRACER_ANY`: https://github.com/torvalds/linux/blob/ab9de95c9cf952332ab79453b4b5d1bfca8e514f/include/uapi/linux/prctl.h#L156
* Haiku `B_INFINITE_TIMEOUT` is a `long long`, this is a type change: https://github.com/haiku/haiku/blob/2b75ca9e1c15526b9ff7613363bb792a28a7f7ac/headers/os/kernel/OS.h#L24
* Don't completely ignore `overflowing_literals`. This is the main thing
  since this lint catches things like `u64`-sized constants being
  assigned to a `c_long`, which is too small on 32-bit platforms.
* `safe_packed_borrows` is now a hard error, we don't need to explicitly
  set the level. 
* Drop `renamed_and_removed_lints` and `unknown_lints` since we are now
  more selective about tested versions.

Closes: rust-lang#4141
@tgross35 tgross35 marked this pull request as ready for review June 25, 2026 19:01
@rustbot

rustbot commented Jun 25, 2026

Copy link
Copy Markdown
Collaborator

Some changes occurred in an Android module

cc @maurer

Some changes occurred in an OpenBSD module

cc @semarie

Some changes occurred in a NetBSD-like module

cc @semarie

Some changes occurred in a solarish module

cc @jclulow, @pfmooney

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-CI Area: CI-related items

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Revisit allow(...)ed lints

2 participants