pub enum SemanticError {
RedefinitionError {
kind: String,
name: String,
},
MainMethodParamUsed {
name: String,
},
StaticMethodNotMain,
NoMainMethod,
MultipleStaticMethods {
amount: u64,
},
ThisInStaticMethod,
MightNotReturn {
method_name: String,
},
ThisMethodInvocationInStaticMethod {
method_name: String,
},
CannotCallStaticMethod {
method_name: String,
},
ConditionMustBeBoolean,
CannotLookupVarOrField {
name: String,
},
CannotLookupVarOrFieldDidYouMean {
name: String,
did_you_mean: String,
},
CannotAccessNonStaticFieldInStaticMethod {
field_name: String,
},
VoidMethodCannotReturnValue,
VoidNotAllowed,
MethodMustReturnSomething {
ty: String,
},
InvalidType {
ty_expected: String,
ty_expr: String,
},
InvalidReferenceToClass {
class_name: String,
},
ClassDoesNotExist {
class_name: String,
},
CannotIndexNonArrayType {
ty: String,
},
MethodDoesNotExistOnType {
method_name: String,
ty: String,
},
FieldDoesNotExistOnType {
field_name: String,
ty: String,
},
MethodArgCountDoesNotMatch {
expected_args: usize,
actual_args: usize,
},
CannotCompareValuesOfType1WithType2 {
ty1: String,
ty2: String,
},
NotAStatement,
InvalidAssignment,
CannotWriteToReadOnlyField {
field_name: String,
},
IntTooLarge {
int: String,
},
}
Fields of RedefinitionError
MainMethodParamUsed
Fields of MainMethodParamUsed
StaticMethodNotMain
NoMainMethod
Fields of MultipleStaticMethods
Fields of MightNotReturn
Fields of ThisMethodInvocationInStaticMethod
Fields of CannotCallStaticMethod
Fields of CannotLookupVarOrField
Fields of CannotLookupVarOrFieldDidYouMean
Fields of CannotAccessNonStaticFieldInStaticMethod
Fields of MethodMustReturnSomething
Fields of InvalidType
Fields of InvalidReferenceToClass
Fields of ClassDoesNotExist
Fields of CannotIndexNonArrayType
Fields of MethodDoesNotExistOnType
Fields of FieldDoesNotExistOnType
Fields of MethodArgCountDoesNotMatch
Fields of CannotCompareValuesOfType1WithType2
Fields of CannotWriteToReadOnlyField
Fields of IntTooLarge
Formats the value using the given formatter. Read more
Formats the value using the given formatter. Read more
Returns a reference to the underlying cause of this failure, if it is an error that wraps other errors. Read more
Returns a reference to the Backtrace
carried by this failure, if it carries one. Read more
Wraps this failure in a compatibility wrapper that implements std::error::Error
. Read more
Converts the given value to a String
. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Returns a reference to the underlying cause of this failure, if it is an error that wraps other errors. Read more
Returns a reference to the Backtrace
carried by this failure, if it carries one. Read more
Wraps this failure in a compatibility wrapper that implements std::error::Error
. Read more
Converts a reference to Self
into a dynamic trait object of Fail
.