Safe Haskell | Safe |
---|---|
Language | Haskell98 |
This module contains parsers for:
- Catalog headers (
Name: Value
lines, that are specified as translation for empty string inpo
file); - Plural form selection expressions (specified in
Plural-Forms
header).
These parsers are already used by main module; but they can be useful for other libraries working with gettext's files.
Types
Parsing functions
parseHeaders :: Text -> Either String Headers Source #
Parse catalog headers. NB: for now this function does not use Parsec.
parsePlural :: Headers -> Either String (Int, Expr) Source #
Parse plural form selection definition. Return value is (number of possible plural forms; selection expression).
Parsec parsers
Parse plural form selection expression.
Note: this parses only part which goes after plural=
.