Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/solid/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,12 @@ pub const LC_MONETARY: c_int = 3;
pub const LC_NUMERIC: c_int = 4;
pub const LC_TIME: c_int = 5;
pub const LC_MESSAGES: c_int = 6;
#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const _LC_LAST: c_int = 7;

pub const EPERM: c_int = 1;
Expand Down
11 changes: 11 additions & 0 deletions src/unix/bsd/netbsdlike/openbsd/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1736,7 +1736,18 @@ pub const LC_NUMERIC_MASK: c_int = 1 << crate::LC_NUMERIC;
pub const LC_TIME_MASK: c_int = 1 << crate::LC_TIME;
pub const LC_MESSAGES_MASK: c_int = 1 << crate::LC_MESSAGES;

#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
const _LC_LAST: c_int = 7;
// NOTE: the constant is meant to be marked for deprecation, but its dependent
// uses are not. This constant is used as a bitmask where all bits for the above
// `LC_*` constants are on, and so it relies on `_LC_LAST` to more easily
// accomplish that.
#[allow(deprecated)]
pub const LC_ALL_MASK: c_int = (1 << _LC_LAST) - 2;

pub const LC_GLOBAL_LOCALE: crate::locale_t = -1isize as crate::locale_t;
Expand Down
18 changes: 18 additions & 0 deletions src/unix/linux_like/android/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1937,6 +1937,12 @@ pub const NF_BR_PRI_BRNF: c_int = 0;
pub const NF_BR_PRI_NAT_DST_OTHER: c_int = 100;
pub const NF_BR_PRI_FILTER_OTHER: c_int = 200;
pub const NF_BR_PRI_NAT_SRC: c_int = 300;
#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const NF_BR_PRI_LAST: c_int = crate::INT_MAX;

// linux/netfilter_ipv4.h
Expand All @@ -1961,6 +1967,12 @@ pub const NF_IP_PRI_NAT_SRC: c_int = 100;
pub const NF_IP_PRI_SELINUX_LAST: c_int = 225;
pub const NF_IP_PRI_CONNTRACK_HELPER: c_int = 300;
pub const NF_IP_PRI_CONNTRACK_CONFIRM: c_int = crate::INT_MAX;
#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const NF_IP_PRI_LAST: c_int = crate::INT_MAX;

// linux/netfilter_ipv6.h
Expand All @@ -1984,6 +1996,12 @@ pub const NF_IP6_PRI_SECURITY: c_int = 50;
pub const NF_IP6_PRI_NAT_SRC: c_int = 100;
pub const NF_IP6_PRI_SELINUX_LAST: c_int = 225;
pub const NF_IP6_PRI_CONNTRACK_HELPER: c_int = 300;
#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const NF_IP6_PRI_LAST: c_int = crate::INT_MAX;

// linux/netfilter_ipv6/ip6_tables.h
Expand Down
35 changes: 35 additions & 0 deletions src/unix/linux_like/linux/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2180,6 +2180,12 @@ pub const NF_BR_PRI_BRNF: c_int = 0;
pub const NF_BR_PRI_NAT_DST_OTHER: c_int = 100;
pub const NF_BR_PRI_FILTER_OTHER: c_int = 200;
pub const NF_BR_PRI_NAT_SRC: c_int = 300;
#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const NF_BR_PRI_LAST: c_int = crate::INT_MAX;

// linux/netfilter_ipv4.h
Expand All @@ -2204,6 +2210,12 @@ pub const NF_IP_PRI_NAT_SRC: c_int = 100;
pub const NF_IP_PRI_SELINUX_LAST: c_int = 225;
pub const NF_IP_PRI_CONNTRACK_HELPER: c_int = 300;
pub const NF_IP_PRI_CONNTRACK_CONFIRM: c_int = crate::INT_MAX;
#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const NF_IP_PRI_LAST: c_int = crate::INT_MAX;

// linux/netfilter_ipv6.h
Expand All @@ -2227,6 +2239,12 @@ pub const NF_IP6_PRI_SECURITY: c_int = 50;
pub const NF_IP6_PRI_NAT_SRC: c_int = 100;
pub const NF_IP6_PRI_SELINUX_LAST: c_int = 225;
pub const NF_IP6_PRI_CONNTRACK_HELPER: c_int = 300;
#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const NF_IP6_PRI_LAST: c_int = crate::INT_MAX;

// linux/netfilter_ipv6/ip6_tables.h
Expand Down Expand Up @@ -2304,9 +2322,26 @@ pub const SIOCGIWENCODEEXT: c_ulong = 0x8B35;
pub const SIOCSIWPMKSA: c_ulong = 0x8B36;

pub const SIOCIWFIRSTPRIV: c_ulong = 0x8BE0;
#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const SIOCIWLASTPRIV: c_ulong = 0x8BFF;

pub const SIOCIWFIRST: c_ulong = 0x8B00;
// NOTE: the symbol we're defining here is itself also deprecated. I can't
// annotate this with `expect` nor provide a `reason` parameter to the attribute
// because those were still experimental back in 1.65
// FIXME(msrv): change this to an `expect` with a `reason` once we bump.
#[allow(deprecated)]
#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const SIOCIWLAST: c_ulong = SIOCIWLASTPRIV;

pub const IWEVTXDROP: c_ulong = 0x8C00;
Expand Down
6 changes: 6 additions & 0 deletions src/unix/solarish/illumos.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,12 @@ pub const LOCK_EX: c_int = 2;
pub const LOCK_NB: c_int = 4;
pub const LOCK_UN: c_int = 8;

#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const _PC_LAST: c_int = 101;

pub const _CS_PATH: c_int = 65;
Expand Down
6 changes: 6 additions & 0 deletions src/unix/solarish/solaris.rs
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,12 @@ pub const F_DUPFD_CLOFORK: c_int = 49;
pub const F_DUP2FD_CLOEXEC: c_int = 48;
pub const F_DUP2FD_CLOFORK: c_int = 50;

#[deprecated(
since = "0.2.187",
note = "This constant, among others often used in C for the purposes of denoting the latest \
value or limit in a set of constants, has been deprecated. See #3131 for details and \
discussion."
)]
pub const _PC_LAST: c_int = 102;

pub const PRIV_PROC_SENSITIVE: c_uint = 0x0008;
Expand Down
Loading