1
1
mirror of https://github.com/github/semantic.git synced 2024-12-30 10:27:45 +03:00

Gotta use error

This commit is contained in:
joshvera 2018-06-26 13:07:35 -04:00
parent 6a294827e2
commit 1c2abd36d0

View File

@ -29,7 +29,7 @@ instance HasDefault Name where
instance Primitive Name where
encodePrimitive num (Name text) = Encode.text num (LT.fromStrict text)
encodePrimitive _ (I _) = fail "We should never be encoding I :: Name constructors"
encodePrimitive _ (I _) = error "We should never be encoding I :: Name constructors"
decodePrimitive = Name . LT.toStrict <$> Decode.text
primType _ = Bytes