Skip to content

Commit e904e2c

Browse files
committed
fix: correct error mapping for BadTypeConstruction
1 parent 09f06c9 commit e904e2c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

clarity/src/vm/clarity_wasm.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7681,7 +7681,7 @@ mod error_mapping {
76817681
DivisionByZero = 2,
76827682
ArithmeticLog2Error = 3,
76837683
ArithmeticSqrtiError = 4,
7684-
UnwrapFailure = 5,
7684+
BadTypeConstruction = 5,
76857685
Panic = 6,
76867686
ShortReturnAssertionFailure = 7,
76877687
ArithmeticPowError = 8,
@@ -7698,7 +7698,7 @@ mod error_mapping {
76987698
2 => ErrorMap::DivisionByZero,
76997699
3 => ErrorMap::ArithmeticLog2Error,
77007700
4 => ErrorMap::ArithmeticSqrtiError,
7701-
5 => ErrorMap::UnwrapFailure,
7701+
5 => ErrorMap::BadTypeConstruction,
77027702
6 => ErrorMap::Panic,
77037703
7 => ErrorMap::ShortReturnAssertionFailure,
77047704
8 => ErrorMap::ArithmeticPowError,
@@ -7806,8 +7806,8 @@ mod error_mapping {
78067806
RuntimeErrorType::Arithmetic(SQRTI_ERROR_MESSAGE.into()),
78077807
Some(Vec::new()),
78087808
),
7809-
ErrorMap::UnwrapFailure => {
7810-
Error::Runtime(RuntimeErrorType::UnwrapFailure, Some(Vec::new()))
7809+
ErrorMap::BadTypeConstruction => {
7810+
Error::Runtime(RuntimeErrorType::BadTypeConstruction, Some(Vec::new()))
78117811
}
78127812
ErrorMap::Panic => {
78137813
// TODO: see issue: #531

0 commit comments

Comments
 (0)