Safe Haskell | None |
---|---|
Language | Haskell2010 |
Parser for the proto3 spec, as defined in https://developers.google.com/protocol-buffers/docs/reference/proto3-spec.
Synopsis
- parseProtoBufFile :: FilePath -> IO (Either (ParseErrorBundle Text Char) ProtoBuf)
- parseProtoBuf :: Text -> Either (ParseErrorBundle Text Char) ProtoBuf
- parseProtoBufDeclarations :: Text -> Either (ParseErrorBundle Text Char) [Declaration]
Parse and sort out a whole file
parseProtoBufFile :: FilePath -> IO (Either (ParseErrorBundle Text Char) ProtoBuf) Source #
Parse a whole file into a ProtoBuf
structure.
This function sorts together the different declarations.
Parse declarations
parseProtoBufDeclarations :: Text -> Either (ParseErrorBundle Text Char) [Declaration] Source #
Parse all the declarations in a Text
.