markdown.parser.Error
type pub inline ErrorAn error produced during parsing.
Fields
message
let pub @message: StringA human readable description of the error.
offset
let pub @offset: IntThe byte offset in the input stream at which the error occurred.
Instance methods
!=
Show source codeHide source code
fn pub !=(other: ref Self) -> Bool {
!(self == other)
}fn pub !=(other: ref Self) -> BoolReturns true if self and the given object are not equal to each other.
==
Show source codeHide source code
fn pub ==(other: ref Error) -> Bool {
@message == other.message and @offset == other.offset
}fn pub ==(other: ref Error) -> BoolReturns true if self and the given object are equal to each other.
This operator is used to perform structural equality. This means two objects residing in different memory locations may be considered equal, provided their structure is equal. For example, two different arrays may be considered to have structural equality if they contain the exact same values.
fmt
Show source codeHide source code
fn pub fmt(formatter: mut Formatter) {
formatter
.object('Error')
.field('message', @message)
.field('offset', @offset)
.finish
}fn pub fmt(formatter: mut Formatter)Formats self in a human-readable format for debugging purposes.
to_string
Show source codeHide source code
fn pub to_string -> String {
@message
}fn pub to_string -> StringConverts self to a String.
Implemented traits
Equal
impl Equal for ErrorFormat
impl Format for ErrorToString
impl ToString for Error