diff --git a/packages/squiggle-lang/src/rescript/Dummy-TypeScriptingRescript/ForTS/ForTS_InternalValue/ForTS_InternalValue.res b/packages/squiggle-lang/src/rescript/Dummy-TypeScriptingRescript/ForTS/ForTS_InternalValue/ForTS_InternalValue.res index e9e0bfeb..c85474da 100644 --- a/packages/squiggle-lang/src/rescript/Dummy-TypeScriptingRescript/ForTS/ForTS_InternalValue/ForTS_InternalValue.res +++ b/packages/squiggle-lang/src/rescript/Dummy-TypeScriptingRescript/ForTS/ForTS_InternalValue/ForTS_InternalValue.res @@ -7,6 +7,7 @@ external ivtString_: int = "IvtString" @module("ForTS_InternalValue_tag") @scope("InternalValueTag") external ivtRecordLike_: int = "IvtRecordLike" +@genType let getTag = (variant: internalValue) => switch variant { | IvVoid(_) => ivtVoid_ @@ -14,18 +15,21 @@ let getTag = (variant: internalValue) => | IvRecordLike(_) => ivtRecordLike_ } +@genType let getVoid = (variant: internalValue): option => switch variant { | IvVoid(v) => Some(v) | _ => None } +@genType let getString = (variant: internalValue): option => switch variant { | IvString(s) => Some(s) | _ => None } +@genType let getRecordLike = (variant: internalValue): option => switch variant { | IvRecordLike(r) => Some(r)