diff --git a/packages/squiggle-lang/src/rescript/ForTS/ForTS_SquiggleValue.res b/packages/squiggle-lang/src/rescript/ForTS/ForTS_SquiggleValue.res index 12a73d64..893c50b3 100644 --- a/packages/squiggle-lang/src/rescript/ForTS/ForTS_SquiggleValue.res +++ b/packages/squiggle-lang/src/rescript/ForTS/ForTS_SquiggleValue.res @@ -79,6 +79,12 @@ let getTag = (variant: squiggleValue) => let toString = (variant: squiggleValue) => ReducerInterface_InternalExpressionValue.toString(variant) +// This is a useful method for unit tests. +// Convert the result along with the error message to a string. +@genType +let toStringResult = (variantResult: result_) => + ReducerInterface_InternalExpressionValue.toStringResult(variantResult) + @genType let getArray = (variant: squiggleValue): option => //FIXME: Convert