ParseError

public struct ParseError

Error info from the parser for the parse operations that do not throw.

  • An integer number that references the error location

    Declaration

    Swift

    public var code: Int
  • When true, the error occured because the parser ran out of characters.

    Declaration

    Swift

    public var incomplete: Bool
  • A textual description of the error.

    Declaration

    Swift

    public var message: String
  • Create a new ParseError

    Declaration

    Swift

    public init(code: Int, incomplete: Bool, message: String)

    Parameters

    code

    An integer number that references the error location

    incomplete

    True if the error occured because the parser ran out of characters.

    message

    A textual description of the error.

  • Creates an empty ParseError

    Declaration

    Swift

    public init()
  • The textual description of the ParseError

    Declaration

    Swift

    public var description: String