[][src]Enum dora_parser::ast::Expr

pub enum Expr {
    ExprUn(ExprUnType),
    ExprBin(ExprBinType),
    ExprLitChar(ExprLitCharType),
    ExprLitInt(ExprLitIntType),
    ExprLitFloat(ExprLitFloatType),
    ExprLitStr(ExprLitStrType),
    ExprTemplate(ExprTemplateType),
    ExprLitBool(ExprLitBoolType),
    ExprIdent(ExprIdentType),
    ExprCall(ExprCallType),
    ExprTypeParam(ExprTypeParamType),
    ExprPath(ExprPathType),
    ExprDelegation(ExprDelegationType),
    ExprDot(ExprDotType),
    ExprSelf(ExprSelfType),
    ExprSuper(ExprSuperType),
    ExprNil(ExprNilType),
    ExprConv(ExprConvType),
    ExprTry(ExprTryType),
    ExprLambda(ExprLambdaType),
}

Variants

ExprUn(ExprUnType)
ExprBin(ExprBinType)
ExprLitChar(ExprLitCharType)
ExprLitInt(ExprLitIntType)
ExprLitFloat(ExprLitFloatType)
ExprLitStr(ExprLitStrType)
ExprTemplate(ExprTemplateType)
ExprLitBool(ExprLitBoolType)
ExprIdent(ExprIdentType)
ExprCall(ExprCallType)
ExprTypeParam(ExprTypeParamType)
ExprPath(ExprPathType)
ExprDelegation(ExprDelegationType)
ExprDot(ExprDotType)
ExprSelf(ExprSelfType)
ExprSuper(ExprSuperType)
ExprNil(ExprNilType)
ExprConv(ExprConvType)
ExprTry(ExprTryType)
ExprLambda(ExprLambdaType)

Methods

impl Expr[src]

pub fn create_un(
    id: NodeId,
    pos: Position,
    span: Span,
    op: UnOp,
    opnd: Box<Expr>
) -> Expr
[src]

pub fn create_try(
    id: NodeId,
    pos: Position,
    span: Span,
    expr: Box<Expr>,
    mode: TryMode
) -> Expr
[src]

pub fn create_bin(
    id: NodeId,
    pos: Position,
    span: Span,
    op: BinOp,
    lhs: Box<Expr>,
    rhs: Box<Expr>
) -> Expr
[src]

pub fn create_conv(
    id: NodeId,
    pos: Position,
    span: Span,
    object: Box<Expr>,
    data_type: Box<Type>,
    is: bool
) -> Expr
[src]

pub fn create_lit_char(
    id: NodeId,
    pos: Position,
    span: Span,
    value: char
) -> Expr
[src]

pub fn create_lit_int(
    id: NodeId,
    pos: Position,
    span: Span,
    value: u64,
    base: IntBase,
    suffix: IntSuffix
) -> Expr
[src]

pub fn create_lit_float(
    id: NodeId,
    pos: Position,
    span: Span,
    value: f64,
    suffix: FloatSuffix
) -> Expr
[src]

pub fn create_lit_str(
    id: NodeId,
    pos: Position,
    span: Span,
    value: String
) -> Expr
[src]

pub fn create_template(
    id: NodeId,
    pos: Position,
    span: Span,
    parts: Vec<Box<Expr>>
) -> Expr
[src]

pub fn create_lit_bool(
    id: NodeId,
    pos: Position,
    span: Span,
    value: bool
) -> Expr
[src]

pub fn create_this(id: NodeId, pos: Position, span: Span) -> Expr[src]

pub fn create_super(id: NodeId, pos: Position, span: Span) -> Expr[src]

pub fn create_nil(id: NodeId, pos: Position, span: Span) -> Expr[src]

pub fn create_ident(
    id: NodeId,
    pos: Position,
    span: Span,
    name: Name,
    type_params: Option<Vec<Type>>
) -> Expr
[src]

pub fn create_call(
    id: NodeId,
    pos: Position,
    span: Span,
    callee: Box<Expr>,
    args: Vec<Box<Expr>>
) -> Expr
[src]

pub fn create_type_param(
    id: NodeId,
    pos: Position,
    span: Span,
    callee: Box<Expr>,
    args: Vec<Type>
) -> Expr
[src]

pub fn create_path(
    id: NodeId,
    pos: Position,
    span: Span,
    lhs: Box<Expr>,
    rhs: Box<Expr>
) -> Expr
[src]

pub fn create_delegation(
    id: NodeId,
    pos: Position,
    span: Span,
    ty: DelegationType,
    args: Vec<Box<Expr>>
) -> Expr
[src]

pub fn create_dot(
    id: NodeId,
    pos: Position,
    span: Span,
    object: Box<Expr>,
    name: Name
) -> Expr
[src]

pub fn create_lambda(
    id: NodeId,
    pos: Position,
    span: Span,
    params: Vec<Param>,
    ret: Option<Box<Type>>,
    block: Box<Stmt>
) -> Expr
[src]

pub fn to_un(&self) -> Option<&ExprUnType>[src]

pub fn is_un(&self) -> bool[src]

pub fn to_bin(&self) -> Option<&ExprBinType>[src]

pub fn is_bin(&self) -> bool[src]

pub fn to_ident(&self) -> Option<&ExprIdentType>[src]

pub fn is_ident(&self) -> bool[src]

pub fn to_call(&self) -> Option<&ExprCallType>[src]

pub fn is_call(&self) -> bool[src]

pub fn to_path(&self) -> Option<&ExprPathType>[src]

pub fn is_path(&self) -> bool[src]

pub fn to_type_param(&self) -> Option<&ExprTypeParamType>[src]

pub fn is_type_param(&self) -> bool[src]

pub fn to_lit_char(&self) -> Option<&ExprLitCharType>[src]

pub fn is_lit_char(&self) -> bool[src]

pub fn to_lit_int(&self) -> Option<&ExprLitIntType>[src]

pub fn is_lit_int(&self) -> bool[src]

pub fn to_template(&self) -> Option<&ExprTemplateType>[src]

pub fn is_template(&self) -> bool[src]

pub fn to_lit_float(&self) -> Option<&ExprLitFloatType>[src]

pub fn is_lit_float(&self) -> bool[src]

pub fn to_lit_str(&self) -> Option<&ExprLitStrType>[src]

pub fn is_lit_str(&self) -> bool[src]

pub fn to_lit_bool(&self) -> Option<&ExprLitBoolType>[src]

pub fn is_lit_bool(&self) -> bool[src]

pub fn is_lit_true(&self) -> bool[src]

pub fn to_dot(&self) -> Option<&ExprDotType>[src]

pub fn is_dot(&self) -> bool[src]

pub fn to_delegation(&self) -> Option<&ExprDelegationType>[src]

pub fn is_delegation(&self) -> bool[src]

pub fn is_this(&self) -> bool[src]

pub fn is_super(&self) -> bool[src]

pub fn to_super(&self) -> Option<&ExprSuperType>[src]

pub fn is_nil(&self) -> bool[src]

pub fn to_conv(&self) -> Option<&ExprConvType>[src]

pub fn is_conv(&self) -> bool[src]

pub fn to_try(&self) -> Option<&ExprTryType>[src]

pub fn is_try(&self) -> bool[src]

pub fn to_lambda(&self) -> Option<&ExprLambdaType>[src]

pub fn is_lambda(&self) -> bool[src]

pub fn pos(&self) -> Position[src]

pub fn span(&self) -> Span[src]

pub fn id(&self) -> NodeId[src]

Trait Implementations

impl Clone for Expr[src]

impl Debug for Expr[src]

Auto Trait Implementations

impl Send for Expr

impl Sync for Expr

impl Unpin for Expr

impl UnwindSafe for Expr

impl RefUnwindSafe for Expr

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Erased for T