@@ -6,8 +6,6 @@ import ProjectM36.AtomFunctionError
6import ProjectM36.AtomFunction
6import ProjectM36.AtomFunction
7import qualified Data.HashSet as HS
7import qualified Data.HashSet as HS
8import qualified Data.Vector as V
8import qualified Data.Vector as V
9−import qualified Data.ByteString.Base64 as B64
10−import qualified Data.Text.Encoding as TE
11import Control.Monad
9import Control.Monad
13primitiveAtomFunctions :: AtomFunctions
11primitiveAtomFunctions :: AtomFunctions
@@ -45,12 +43,7 @@ primitiveAtomFunctions = HS.fromList [
45 atomFuncBody = body $ intAtomFuncLessThan True >=> boolAtomNot},
43 atomFuncBody = body $ intAtomFuncLessThan True >=> boolAtomNot},
46 AtomFunction { atomFuncName = "not",
44 AtomFunction { atomFuncName = "not",
47 atomFuncType = [BoolAtomType, BoolAtomType],
45 atomFuncType = [BoolAtomType, BoolAtomType],
48− atomFuncBody = body $ \(b:_) -> boolAtomNot b },
46+ atomFuncBody = body $ \(b:_) -> boolAtomNot b }
49− AtomFunction { atomFuncName = "makeByteString",
50− atomFuncType = [TextAtomType, ByteStringAtomType],
51− atomFuncBody = body $ \(TextAtom textIn:_) -> case B64.decode (TE.encodeUtf8 textIn) of
52− Left err -> Left (AtomFunctionBytesDecodingError err)
53− Right bs -> pure (ByteStringAtom bs) }
56 body = AtomFunctionBody Nothing
49 body = AtomFunctionBody Nothing