pub enum PythonKeyword {
Show 35 variants
False,
None,
True,
And,
As,
Assert,
Async,
Await,
Break,
Class,
Continue,
Def,
Del,
Elif,
Else,
Except,
Finally,
For,
From,
Global,
If,
Import,
In,
Is,
Lambda,
Nonlocal,
Not,
Or,
Pass,
Raise,
Return,
Try,
While,
With,
Yield,
}Expand description
Common hard Python keywords.
Variants§
False
None
True
And
As
Assert
Async
Await
Break
Class
Continue
Def
Del
Elif
Else
Except
Finally
For
From
Global
If
Import
In
Is
Lambda
Nonlocal
Not
Or
Pass
Raise
Return
Try
While
With
Yield
Implementations§
Trait Implementations§
Source§impl Clone for PythonKeyword
impl Clone for PythonKeyword
Source§fn clone(&self) -> PythonKeyword
fn clone(&self) -> PythonKeyword
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PythonKeyword
impl Debug for PythonKeyword
Source§impl Display for PythonKeyword
impl Display for PythonKeyword
Source§impl FromStr for PythonKeyword
impl FromStr for PythonKeyword
Source§type Err = PythonKeywordParseError
type Err = PythonKeywordParseError
The associated error which can be returned from parsing.
Source§fn from_str(
input: &str,
) -> Result<PythonKeyword, <PythonKeyword as FromStr>::Err>
fn from_str( input: &str, ) -> Result<PythonKeyword, <PythonKeyword as FromStr>::Err>
Parses a string
s to return a value of this type. Read moreSource§impl Hash for PythonKeyword
impl Hash for PythonKeyword
Source§impl Ord for PythonKeyword
impl Ord for PythonKeyword
Source§fn cmp(&self, other: &PythonKeyword) -> Ordering
fn cmp(&self, other: &PythonKeyword) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for PythonKeyword
impl PartialEq for PythonKeyword
Source§fn eq(&self, other: &PythonKeyword) -> bool
fn eq(&self, other: &PythonKeyword) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialOrd for PythonKeyword
impl PartialOrd for PythonKeyword
impl Copy for PythonKeyword
impl Eq for PythonKeyword
impl StructuralPartialEq for PythonKeyword
Auto Trait Implementations§
impl Freeze for PythonKeyword
impl RefUnwindSafe for PythonKeyword
impl Send for PythonKeyword
impl Sync for PythonKeyword
impl Unpin for PythonKeyword
impl UnsafeUnpin for PythonKeyword
impl UnwindSafe for PythonKeyword
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more