[][src]Enum bracket::error::syntax::SyntaxError

pub enum SyntaxError {
    ExpectedIdentifier(String),
    ExpectedPath(String),
    BlockName(String),
    LiteralNewline(String),
    PartialPosition(String),
    SubExprNotOpen(String),
    SubExprTargetNotAllowed(String),
    PathDelimiterNotAllowed(String),
    ElseNotAllowed(String),
    UnexpectedPathExplicitThis(String),
    UnexpectedPathParent(String),
    UnexpectedPathLocal(String),
    UnexpectedPathDelimiter(String),
    UnexpectedPathParentWithLocal(String),
    UnexpectedPathParentWithExplicit(String),
    ExpectedPathDelimiter(String),
    OpenSubExpression(String),
    TagNameMismatch(String),
    BlockNotOpen(String),
    SubExpressionNotTerminated(String),
    LinkNotTerminated(String),
    RawBlockOpenNotTerminated(String),
    RawBlockNotTerminated(String),
    RawCommentNotTerminated(String),
    RawStatementNotTerminated(String),
    CommentNotTerminated(String),
    BlockTargetSubExpr(String),
    EmptyPath(String),
    ComponentType(String),
    MixedPartialConditional(String),
    TokenError(StringString),
    TokenCallTarget(String),
    TokenJsonLiteral(String),
    TokenParameter(String),
    TokenHashKeyValue(String),
    TokenRawLiteral(String),
    TokenDoubleQuoteLiteral(String),
    TokenSingleQuoteLiteral(String),
    TokenArrayLiteral(String),
    TokenLink(String),
    TokenParameterPath(String),
    TokenEndRawBlock(String),
}

Errors generated when compiling a template.

Variants

ExpectedIdentifier(String)

Error when an identifier is expected.

ExpectedPath(String)

Error when a path is expected.

BlockName(String)

Error if a block name is not a simple identifier.

LiteralNewline(String)

Error when a newline is enccountered in a raw literal.

PartialPosition(String)

Error when the partial operator is not the first token in a call statement.

SubExprNotOpen(String)

Error when a sub-expression is closed by no sub-expression is open.

SubExprTargetNotAllowed(String)

Error when a sub-expression attempts to use a sub-expression for it's target.

Currently sub-expressions for the target are only supported when evaluating partials.

PathDelimiterNotAllowed(String)

Error when a path delimiter is encountered in an invalid position.

ElseNotAllowed(String)

Error when the else keyword is encountered in an invalid position.

UnexpectedPathExplicitThis(String)

Error when the this keywords is not at the start of a path.

UnexpectedPathParent(String)

Error when a parent path reference (../) is not at the start of a path.

UnexpectedPathLocal(String)

Error when a local identifier is not at the start of a path.

UnexpectedPathDelimiter(String)

Error when an identifier is expected but a path delimiter was encountered.

UnexpectedPathParentWithLocal(String)

Error when parent scope references and local identifiers are combined illegally.

UnexpectedPathParentWithExplicit(String)

Error attempting to mix parent scope references and explicit this.

ExpectedPathDelimiter(String)

Error when a path delimiter is expected.

OpenSubExpression(String)

Error when a sub-expression was not terminated.

TagNameMismatch(String)

Error when a closing tag name does not match the opening name.

BlockNotOpen(String)

Error when an end tag is encountered but no block is open.

SubExpressionNotTerminated(String)

Error when a sub-expression is not terminated.

LinkNotTerminated(String)

Erro when a link is not terminated.

RawBlockOpenNotTerminated(String)

Error when the opening tag for a raw block is not terminated.

RawBlockNotTerminated(String)

Error when a raw block is not terminated.

RawCommentNotTerminated(String)

Error when a raw comment is not terminated.

RawStatementNotTerminated(String)

Error when a raw statement is not terminated.

CommentNotTerminated(String)

Error when a comment is not terminated.

BlockTargetSubExpr(String)

Error attempting to use a sub-expression outside of a partial target context.

EmptyPath(String)

Error when an empty path is encountered.

ComponentType(String)

Error if we could not identify the type of a path component (internal error).

MixedPartialConditional(String)

Error attempting to combine partials with conditionals.

TokenError(StringString)

Invalid token error (internal error).

TokenCallTarget(String)

Invalid token error (internal error).

TokenJsonLiteral(String)

Invalid token error (internal error).

TokenParameter(String)

Invalid token error (internal error).

TokenHashKeyValue(String)

Invalid token error (internal error).

TokenRawLiteral(String)

Invalid token error (internal error).

TokenDoubleQuoteLiteral(String)

Invalid token error (internal error).

TokenSingleQuoteLiteral(String)

Invalid token error (internal error).

TokenArrayLiteral(String)

Invalid token error (internal error).

Invalid token error (internal error).

TokenParameterPath(String)

Invalid token error (internal error).

TokenEndRawBlock(String)

Invalid token error (internal error).

Trait Implementations

impl Debug for SyntaxError[src]

impl Display for SyntaxError[src]

impl Eq for SyntaxError[src]

impl Error for SyntaxError[src]

impl From<SyntaxError> for HelperError[src]

impl From<SyntaxError> for Error[src]

impl PartialEq<SyntaxError> for SyntaxError[src]

impl StructuralEq for SyntaxError[src]

impl StructuralPartialEq for SyntaxError[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

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

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

impl<T> ToString for T where
    T: Display + ?Sized
[src]

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.