mirror of
https://github.com/fluencelabs/aquavm
synced 2025-04-25 07:12:16 +00:00
Fix typo
This commit is contained in:
parent
aba0423106
commit
9e2f123dc3
@ -103,7 +103,7 @@ pub enum CatchableError {
|
||||
StreamMapError(#[from] StreamMapError),
|
||||
|
||||
#[error("Starlark error: {0}")]
|
||||
StalarkError(air_interpreter_starlark::ExecutionError),
|
||||
StarlarkError(air_interpreter_starlark::ExecutionError),
|
||||
}
|
||||
|
||||
impl From<LambdaError> for Rc<CatchableError> {
|
||||
|
@ -145,7 +145,7 @@ pub enum UncatchableError {
|
||||
CallArgumentsSerializationFailed(<CallArgumentsRepr as Representation>::SerializeError),
|
||||
|
||||
#[error("Starlark error: {0}")]
|
||||
StalarkError(air_interpreter_starlark::ExecutionError),
|
||||
StarlarkError(air_interpreter_starlark::ExecutionError),
|
||||
}
|
||||
|
||||
impl ToErrorCode for UncatchableError {
|
||||
|
@ -85,8 +85,8 @@ fn classify_starlark_error(err: air_interpreter_starlark::ExecutionError) -> Exe
|
||||
|
||||
match err {
|
||||
// TODO perhaps, Other should be uncatchable
|
||||
Value(_) | Function(_) | Other(_) => ExecutionError::Catchable(CatchableError::StalarkError(err).into()),
|
||||
Scope(_) | Lexer(_) | Internal(_) => ExecutionError::Uncatchable(UncatchableError::StalarkError(err)),
|
||||
Value(_) | Function(_) | Other(_) => ExecutionError::Catchable(CatchableError::StarlarkError(err).into()),
|
||||
Scope(_) | Lexer(_) | Internal(_) => ExecutionError::Uncatchable(UncatchableError::StarlarkError(err)),
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -118,7 +118,7 @@ async fn embed_error_value() {
|
||||
var)"##;
|
||||
|
||||
let result = call_vm!(vm, <_>::default(), script, "", "");
|
||||
let expected_error = CatchableError::StalarkError(StarlarkExecutionError::Value(
|
||||
let expected_error = CatchableError::StarlarkError(StarlarkExecutionError::Value(
|
||||
"error: Operation `+` not supported for types `int` and `string`\n --> dummy.star:2:1\n |\n2 | 42 + \"string\"\n | ^^^^^^^^^^^^^\n |\n".to_owned(),
|
||||
));
|
||||
assert_error_eq!(&result, expected_error);
|
||||
@ -137,7 +137,7 @@ async fn embed_error_lexer() {
|
||||
var)"##;
|
||||
|
||||
let result = call_vm!(vm, <_>::default(), script, "", "");
|
||||
let expected_error = UncatchableError::StalarkError(StarlarkExecutionError::Lexer(
|
||||
let expected_error = UncatchableError::StarlarkError(StarlarkExecutionError::Lexer(
|
||||
"Parse error: unfinished string literal".to_owned(),
|
||||
));
|
||||
assert_error_eq!(&result, expected_error);
|
||||
|
Loading…
x
Reference in New Issue
Block a user