Skip to content

Commit

Permalink
Stabilize ascii_ctype methods for u8 and char
Browse files Browse the repository at this point in the history
The feature of those methods was renamed to "ascii_ctype_on_intrinsics".
  • Loading branch information
LukasKalbertodt committed Nov 18, 2017
1 parent 667f83d commit 0337017
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 deletions.
20 changes: 10 additions & 10 deletions src/libcore/num/mod.rs
Expand Up @@ -2420,7 +2420,7 @@ impl u8 {
/// assert!(!lf.is_ascii_alphabetic());
/// assert!(!esc.is_ascii_alphabetic());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_alphabetic(&self) -> bool {
if *self >= 0x80 { return false; }
Expand Down Expand Up @@ -2458,7 +2458,7 @@ impl u8 {
/// assert!(!lf.is_ascii_uppercase());
/// assert!(!esc.is_ascii_uppercase());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_uppercase(&self) -> bool {
if *self >= 0x80 { return false }
Expand Down Expand Up @@ -2496,7 +2496,7 @@ impl u8 {
/// assert!(!lf.is_ascii_lowercase());
/// assert!(!esc.is_ascii_lowercase());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_lowercase(&self) -> bool {
if *self >= 0x80 { return false }
Expand Down Expand Up @@ -2537,7 +2537,7 @@ impl u8 {
/// assert!(!lf.is_ascii_alphanumeric());
/// assert!(!esc.is_ascii_alphanumeric());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_alphanumeric(&self) -> bool {
if *self >= 0x80 { return false }
Expand Down Expand Up @@ -2575,7 +2575,7 @@ impl u8 {
/// assert!(!lf.is_ascii_digit());
/// assert!(!esc.is_ascii_digit());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_digit(&self) -> bool {
if *self >= 0x80 { return false }
Expand Down Expand Up @@ -2616,7 +2616,7 @@ impl u8 {
/// assert!(!lf.is_ascii_hexdigit());
/// assert!(!esc.is_ascii_hexdigit());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_hexdigit(&self) -> bool {
if *self >= 0x80 { return false }
Expand Down Expand Up @@ -2658,7 +2658,7 @@ impl u8 {
/// assert!(!lf.is_ascii_punctuation());
/// assert!(!esc.is_ascii_punctuation());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_punctuation(&self) -> bool {
if *self >= 0x80 { return false }
Expand Down Expand Up @@ -2696,7 +2696,7 @@ impl u8 {
/// assert!(!lf.is_ascii_graphic());
/// assert!(!esc.is_ascii_graphic());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_graphic(&self) -> bool {
if *self >= 0x80 { return false; }
Expand Down Expand Up @@ -2751,7 +2751,7 @@ impl u8 {
/// assert!(lf.is_ascii_whitespace());
/// assert!(!esc.is_ascii_whitespace());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_whitespace(&self) -> bool {
if *self >= 0x80 { return false; }
Expand Down Expand Up @@ -2791,7 +2791,7 @@ impl u8 {
/// assert!(lf.is_ascii_control());
/// assert!(esc.is_ascii_control());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_control(&self) -> bool {
if *self >= 0x80 { return false; }
Expand Down
20 changes: 10 additions & 10 deletions src/libstd_unicode/char.rs
Expand Up @@ -1106,7 +1106,7 @@ impl char {
/// assert!(!lf.is_ascii_alphabetic());
/// assert!(!esc.is_ascii_alphabetic());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_alphabetic(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_alphabetic()
Expand Down Expand Up @@ -1140,7 +1140,7 @@ impl char {
/// assert!(!lf.is_ascii_uppercase());
/// assert!(!esc.is_ascii_uppercase());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_uppercase(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_uppercase()
Expand Down Expand Up @@ -1174,7 +1174,7 @@ impl char {
/// assert!(!lf.is_ascii_lowercase());
/// assert!(!esc.is_ascii_lowercase());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_lowercase(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_lowercase()
Expand Down Expand Up @@ -1211,7 +1211,7 @@ impl char {
/// assert!(!lf.is_ascii_alphanumeric());
/// assert!(!esc.is_ascii_alphanumeric());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_alphanumeric(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_alphanumeric()
Expand Down Expand Up @@ -1245,7 +1245,7 @@ impl char {
/// assert!(!lf.is_ascii_digit());
/// assert!(!esc.is_ascii_digit());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_digit(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_digit()
Expand Down Expand Up @@ -1282,7 +1282,7 @@ impl char {
/// assert!(!lf.is_ascii_hexdigit());
/// assert!(!esc.is_ascii_hexdigit());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_hexdigit(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_hexdigit()
Expand Down Expand Up @@ -1320,7 +1320,7 @@ impl char {
/// assert!(!lf.is_ascii_punctuation());
/// assert!(!esc.is_ascii_punctuation());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_punctuation(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_punctuation()
Expand Down Expand Up @@ -1354,7 +1354,7 @@ impl char {
/// assert!(!lf.is_ascii_graphic());
/// assert!(!esc.is_ascii_graphic());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_graphic(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_graphic()
Expand Down Expand Up @@ -1405,7 +1405,7 @@ impl char {
/// assert!(lf.is_ascii_whitespace());
/// assert!(!esc.is_ascii_whitespace());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_whitespace(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_whitespace()
Expand Down Expand Up @@ -1441,7 +1441,7 @@ impl char {
/// assert!(lf.is_ascii_control());
/// assert!(esc.is_ascii_control());
/// ```
#[unstable(feature = "ascii_ctype", issue = "39658")]
#[stable(feature = "ascii_ctype_on_intrinsics", since = "1.23.0")]
#[inline]
pub fn is_ascii_control(&self) -> bool {
self.is_ascii() && (*self as u8).is_ascii_control()
Expand Down

0 comments on commit 0337017

Please sign in to comment.