-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Remove placeholder constants #3620
Remove placeholder constants #3620
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @JohnTitor (or someone else) some time within the next two weeks. Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Many of these are not placeholder constants, you should individually double-check each of them.
@@ -5007,7 +4990,6 @@ pub const VM_HUGETLB_PAGES: ::c_int = 18; | |||
pub const VM_SWAPPINESS: ::c_int = 19; | |||
pub const VM_LOWMEM_RESERVE_RATIO: ::c_int = 20; | |||
pub const VM_MIN_FREE_KBYTES: ::c_int = 21; | |||
pub const VM_MAX_MAP_COUNT: ::c_int = 22; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not a placeholder constant: it is an input to a function which returns a count.
@@ -3676,7 +3660,6 @@ pub const IW_MICFAILURE_KEY_ID: ::c_ulong = 0x00000003; | |||
pub const IW_MICFAILURE_GROUP: ::c_ulong = 0x00000004; | |||
pub const IW_MICFAILURE_PAIRWISE: ::c_ulong = 0x00000008; | |||
pub const IW_MICFAILURE_STAKEY: ::c_ulong = 0x00000010; | |||
pub const IW_MICFAILURE_COUNT: ::c_ulong = 0x00000060; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here.
See #1896 for more info." | ||
)] | ||
pub const IPPROTO_MAX: ::c_int = 256; | ||
pub const IPPROTO_MAX: ::c_int = 263; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be removed.
@@ -2324,8 +2321,6 @@ pub const IFLA_EVENT: ::c_ushort = 44; | |||
pub const IFLA_NEW_NETNSID: ::c_ushort = 45; | |||
pub const IFLA_IF_NETNSID: ::c_ushort = 46; | |||
pub const IFLA_TARGET_NETNSID: ::c_ushort = IFLA_IF_NETNSID; | |||
pub const IFLA_CARRIER_UP_COUNT: ::c_ushort = 47; | |||
pub const IFLA_CARRIER_DOWN_COUNT: ::c_ushort = 48; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a placeholder.
@@ -2307,8 +2306,6 @@ pub const IFLA_GROUP: ::c_ushort = 27; | |||
pub const IFLA_NET_NS_FD: ::c_ushort = 28; | |||
pub const IFLA_EXT_MASK: ::c_ushort = 29; | |||
pub const IFLA_PROMISCUITY: ::c_ushort = 30; | |||
pub const IFLA_NUM_TX_QUEUES: ::c_ushort = 31; | |||
pub const IFLA_NUM_RX_QUEUES: ::c_ushort = 32; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a placeholder.
@@ -1436,7 +1435,6 @@ pub const DOWNTIME: ::c_short = 11; | |||
// utmpx database types | |||
pub const UTX_DB_UTMPX: ::c_uint = 0; | |||
pub const UTX_DB_WTMPX: ::c_uint = 1; | |||
pub const UTX_DB_LASTLOG: ::c_uint = 2; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a placeholder.
@@ -1064,7 +1064,6 @@ pub const CPUCTL_CPUID: ::c_int = 0xc0106303; | |||
pub const CPUCTL_UPDATE: ::c_int = 0xc0106304; | |||
pub const CPUCTL_MSRSBIT: ::c_int = 0xc0106305; | |||
pub const CPUCTL_MSRCBIT: ::c_int = 0xc0106306; | |||
pub const CPUCTL_CPUID_COUNT: ::c_int = 0xc0106307; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a placeholder.
@@ -5225,7 +5221,6 @@ pub const VOL_CAP_FMT_DECMPFS_COMPRESSION: attrgroup_t = 0x00010000; | |||
pub const VOL_CAP_FMT_64BIT_OBJECT_IDS: attrgroup_t = 0x00020000; | |||
pub const VOL_CAP_FMT_DIR_HARDLINKS: attrgroup_t = 0x00040000; | |||
pub const VOL_CAP_FMT_DOCUMENT_ID: attrgroup_t = 0x00080000; | |||
pub const VOL_CAP_FMT_WRITE_GENERATION_COUNT: attrgroup_t = 0x00100000; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a placeholder.
@@ -5140,7 +5137,6 @@ pub const ATTR_CMN_OWNERID: attrgroup_t = 0x00008000; | |||
pub const ATTR_CMN_GRPID: attrgroup_t = 0x00010000; | |||
pub const ATTR_CMN_ACCESSMASK: attrgroup_t = 0x00020000; | |||
pub const ATTR_CMN_FLAGS: attrgroup_t = 0x00040000; | |||
pub const ATTR_CMN_GEN_COUNT: attrgroup_t = 0x00080000; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a placeholder.
@@ -1404,8 +1404,6 @@ pub const LPAR_INFO_FORMAT1: ::c_int = 1; | |||
pub const LPAR_INFO_FORMAT2: ::c_int = 2; | |||
pub const WPAR_INFO_FORMAT: ::c_int = 3; | |||
pub const PROC_MODULE_INFO: ::c_int = 4; | |||
pub const NUM_PROC_MODULE_TYPES: ::c_int = 5; | |||
pub const LPAR_INFO_VRME_NUM_POOLS: ::c_int = 6; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a placeholder.
Closing as inactive, it'd be great if you could split PRs to make our review easy. Thank you for the PR anyway! |
Yeahh, I paused on it because some clarification is needed based on my discussion with @Amanieu . |
This PR removes placeholder constants as described in #3131. Below are lists of patterns matched for unused constant names.
It also includes an update of the
IPROTO_MAX
constant on newer versions of Linux mentioned in #1896._COUNT
_MAX
_NUM
These are all breaking changes for the new
libc 1.0
version tracked in #3248