Îõ³h&ÕT¹–Ä      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€�‚ƒ„…†‡ˆ‰Š‹Œ�Ž��‘’“”•–—˜™š›œ�žŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâ ã ä å æ ç è é ê ë ì í î ï ð ñ ò ó ô õ ö ÷ ø ù ú û ü ý þ ÿ € � ‚ ƒ „ … † ‡ ˆ ‰ Š ‹ Œ � Ž � � ‘ ’ “ ” • – — ˜ ™ š › œ � ž Ÿ   ¡ ¢ £ ¤ ¥ ¦ § ¨ © ª « ¬ ­ ® ¯ ° ± ² ³ ´ µ ¶ · ¸ ¹ º » ¼ ½ ¾ ¿ ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ€�‚ƒ„…†‡ˆ‰Š‹Œ�Ž��‘’“”•–—˜™š›œ�žŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ€�‚ƒ„…†‡ˆ‰Š‹Œ�Ž��‘’“”•–—˜™š›œ�žŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ€�‚ƒ„…†‡ˆ‰Š‹Œ�Ž��‘’“”•–—˜™š›œ�žŸ ¡¢£¤¥ ¦!§"¨"©"ª"«"¬"­"®"¯"°"±"²"³"´"µ"¶"·"¸"¹"º"»"¼"½"¾"¿"À"Á"Â"Ã"Ä"Å"Æ"Ç"È"É"Ê"Ë"Ì"Í"Î"Ï"Ð"Ñ"Ò"Ó"Ô"Õ"Ö"×"Ø"Ù"Ú"Û"Ü"Ý"Þ"ß"à"á"â"ã"ä"å"æ"ç"è"é"ê"ë"ì"í"î"ï"ð"ñ"ò"ó"ô"õ"ö"÷"ø"ù"ú"û"ü"ý"þ"ÿ"€"�"‚"ƒ"„"…"†"‡"ˆ"‰"Š"‹"Œ"�"Ž"�"�"‘"’"“"”"•"–"—"˜"™#š#›#œ#�#ž#Ÿ# #¡#¢#£#¤#¥#¦#§#¨#©$ª$«$¬$­$®$¯$°$±$²$³$´$µ$¶$·$¸%¹&º&»'¼(½(¾(¿)À)Á)Â)Ã)Ä*Å*Æ*Ç*È*É*Ê+Ë+Ì+Í,Î-Ï.Ð/Ñ0Ò1Ó2Ô2Õ2Ö2×2Ø2Ù2Ú2Û2Ü2Ý2Þ2ß2à2á2â2ã2ä2å2æ2ç2è2é3ê3ë3ì3í3î3ï3ð3ñ3ò4ó5ô6õ6ö6÷6ø6ù6ú6û6ü6ý6þ6ÿ6€6�6‚6ƒ6„6…6†6‡6ˆ6‰6Š6‹6Œ6�6Ž6�6�6‘6’6“6”6•6–6—6˜6™6š6›7œ7�8ž8Ÿ9 9¡:¢:£;¤;¥;¦;§;¨;©<ª<«<¬<­<®<¯<°<±<²<³<´<µ<¶=·>¸>¹>º>»>¼>½>¾>¿>À>Á>Â>Ã>Ä>Å>Æ?Ç@ÈAÉAÊAËAÌAÍAÎAÏÐÑÒÓÔÕÖרÙÚÛÜÝÞBßBàBáBâBãBäBåBæBçBèBéBêBëBìBíBîBïBðBñBòBóBôBõBöB÷BøBùBúBûBüBýBþBÿB€B�B‚BƒB„B…B†C‡CˆC‰CŠC‹DŒD�DŽD�E�E‘E’E“E”E•E–E—E˜E™EšE›EœE�EžEŸE E¡E¢E£E¤E¥E¦E§E¨E©EªE«E¬E­E®E¯E°F±G²H³H´HµH¶H·I¸J¹JºK»L¼M½N¾O¿OÀPÁPÂPÃQÒ Safe-Inferred #$%9>?ÀÑÖ×Ùàáè„BNFC$Get the start position of something.BNFC+Start position (line, column) of something.Ê "! #$'&%()*/.,-+0213546FEDA@?>=<;:987CBGHIJÊGH6FEDA@?>=<;:987CB354021*/.,-+()$'&%"! # JI Safe-Inferred #$%9>?ÀÑÖ×Ùàá•|BNFC&Switch C to language variant that has strdup.|| Safe-Inferred #$%9>?ÀÑÖ×ÙàáÓ}~€�}~€� Safe-Inferred #$%9>?ÀÑÖ×ÙàáÀ‚BNFC±Function that, given an input string, renders it either as a char (if it has legth 1) or a string. It should also excape characters correctly. The first returned value is the 'type'˜ of the string: either C for char or S for string. (used in the C printer to choose the right rendering function) e.g. >>> renderCharOrString "a" (C,"a#") >>> renderCharOrString "abc" (S(,""abc"") >>> renderCharOrString "'" (C,"\\$'") >>> renderCharOrString ""\'" (S ,""\"\\\'"")ƒBNFCƒHelper function that escapes characters in strings >>> escapeChars "\" "\\" >>> escapeChars """ "\"" >>> escapeChars "'" "\'"‚ƒ‚ƒ Safe-Inferred #$%9>?ÀÑÖ×Ùàá>…BNFC.Escape character for use inside single quotes.„…„…None #$%9>?ÀÇÑÖ×ÙàáèÛ›BNFC>Finite map from text to token organized as binary search tree.œBNFC Nil (leaf).�BNFC Binary node.žBNFCToken with position.¡BNFC*Keyword or symbol tokens have a unique ID.£BNFCKeyword or symbol text.¤BNFC Unique ID.¥BNFCToken without position.¦BNFCReserved word or symbol.§BNFCString literal.¨BNFCInteger literal.©BNFC Identifier.ªBNFCFloat literal.«BNFCCharacter literal.­BNFCSmart constructor for ¥) for the sake of backwards compatibility.µBNFCCreate a token with position.¶BNFCPretty print a position.·BNFC9Pretty print the position of the first token in the list.¸BNFCGet the position of a token.¹BNFCGet line and column of a token.ºBNFC"Get line and column of a position.»BNFC+Convert a token into "position token" form.¼BNFCConvert a token to its text.½BNFCConvert a token to a string.¾BNFCÀConvert potential keyword into token or use fallback conversion.¿BNFCÉThe keywords and symbols of the language organized as binary search tree.ÀBNFCUnquote string literal.ÆBNFCÂEncode a Haskell String to a list of Word8 values, in UTF8 format.ÔBNFC7Keyword/symbol ordering is determined by the unique ID.ÕBNFC7Keyword/symbol equality is determined by the unique ID.̈‹Š‰ŒŽ���”“’‘•–—˜™š›�œž Ÿ¡¢¤£¥¬«ª©¨§¦­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÌ®¯°±²³´•–ÎÏÐ�”“’‘ÑÒÓŒŽ��ˆ‹Š‰µ¥¬«ª©¨§¦­¡¢¤£ž Ÿ¶·¸¹º»¼½›�œ¾¿À™šÁ˜—ÃÄÅÆÇÈÉÊËÌÍNone #$%9>?ÀÑÖ×Ùàá!Aáá None #$%9>?ÀÇÑÖ×Ùàáèé!€âãäåæçèéêëìíîïðñòóôõö÷øùúûúûâãäåæçèéêëìíîïðñòóôõö÷øùÄ9 Å9   Safe-Inferred #$%9>?ÀÑÖ×Ùàá'H üBNFCOverloaded function ý.ÿBNFC Render as Æ.€BNFCPut Ç, around document if given condition is true.parensIf True "foo"(foo)parensIf False "bar"bar�BNFC$Separate vertically by a blank line."foo" $++$ "bar"foobar"foo" $++$ emptyfoo‚BNFCList version of �.vsep [ "foo", nest 4 "bar" ]foo barvsep []ƒBNFCList version of RS.'vcat' [text "abc", nest 4 (text "def")]abc def„BNFC3Pretty print separator with = (for assignments...). "a" <=> "123"a = 123…BNFC÷Print a list of 0-1 elements on the same line as some preamble and from 2 elements on the following lines, indented.6prettyList 2 ("foo" <+> equals) lbrack rbrack comma []foo = [];prettyList 2 ("foo" <+> equals) lbrack rbrack comma [ "a" ] foo = [a]ÀprettyList 2 ("foo" <+> equals) lbrack rbrack comma [ "a", "b" ]foo = [ a , b ]Used in the Agda backend.†BNFCÂCode block. A block of C/Java code, surrounded by {} and indented.codeblock 4 ["abc", "def"]{ abc def}Used in the C backend.…BNFC Indentation.BNFC Preamble.BNFCLeft parenthesis.BNFCRight parenthesis.BNFC)Separator (usually not including spaces).BNFC List item.ÈÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÇÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ€ � ‚ ƒ üýþÿ€�‚ƒ„…† üýþÿ€�‚ƒ„…†  Safe-Inferred #$%9>?ÀÑÖ×Ùàá(+ŠŠ  Safe-Inferred #$%9>?ÀÑÖ×Ùàá(Á‹BNFCThe printer class does the job.ŽBNFCThe top-level printing method. ‹Œ�Ž��‘’“”•–— Ž���‘’“”‹Œ•–—  Safe-Inferred #$%9>?ÀÑÖ×Ùàá*y°BNFCÄCheck if a regular expression is nullable (accepts the empty string)±BNFCúSimplification of regular expression, mostly for the purpose of simplifying character alternatives (character classes).êThis may help lexer backends, since often lexer generators have a limited syntax for character classes.°±°± Safe-Inferred #$%9>?ÀÑÖ×Ùàáè:ô.ÀBNFCDifferent case styleÁBNFCe.g.  lowercaseÂBNFCe.g.  UPPERCASEÃBNFCe.g.  snake_caseÄBNFCe.g.  CamelCaseÅBNFCe.g.  mixedCaseÆBNFC&Keep original capitalization and form.ÇBNFCThe name of a module, e.g. Foo.Abs,  Foo.Print etc.ÈBNFCGeneralization of TU.ÉBNFCGeneralization of TV.ÊBNFCÈ* for the monoid of endofunctions 'a -> a'.ËBNFCÉ* for the monoid of endofunctions 'a -> a'.ÌBNFC'Invoke continuation for non-empty list.ÍBNFC'Invoke continuation for non-empty list.ÎBNFCDiagrammatic composition.ÏBNFC Non-monadic forM.ÐBNFCGeneralization of forM to „ .ÑBNFC Rotation of … .ÒBNFC5Converts an uncurried function to a curried function.ÓBNFC6Converts a curried function to a function on a triple.ÔBNFCConcatenate strings by a space.ÕBNFC!Concatenate strings by a newline.ÖBNFC%Concatenate strings by an underscore.×BNFCConcatenate strings by a dot.ØBNFC'Wrap in parentheses if condition holds.ÙBNFCÀPad a string on the right by spaces to reach the desired length.ÚBNFC>> lowerCase MyIdent myidentéBNFC$Ident to upper case. >>> upperCase MyIdent MYIDENTêBNFC7Ident to camel case. >>> camelCase "my_ident" MyIdentìBNFC1To mixed case. >>> mixedCase "my_ident" myIdentíBNFCTo snake case. >>> snakeCase MyIdent my_identïBNFCšA function that renders a c-like string with escaped characters. Note that although it's called cstring, this can be used with most (all) backend as they seem to mostly share escaping conventions. The c in the name is barely an homage for C being the oldest language in the lot.cstring "foobar""foobar"cstring "foobar\"" "foobar\""ðBNFC2Print a symbol as typical token name, like "(" as LPAREN.ßBNFCValue to replaceBNFCValue to replace it with1ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâãäåæçèéêëìíîïð1ÇÈÉÌÍÊËÏÐÑÎÒÓÛÜÝÞàáâãÔÕÖרÙÚæçÀÁÂÃÄÅÆèéìêëíîßåïäðÎ8Ô5Õ5Ö5×5None #$%5679>?ÀÑÖ×ÙàáèZùèóBNFC!The abstract syntax of a grammar.úBNFC5Is this function just a coercion? (I.e. the identity)üBNFC#Fun is the function name of a rule.€BNFC0Categories are the non-terminals of the grammar.�BNFCOrdinary non-terminal.‚BNFCToken types (like Ident, Integer, ..., user-defined).ƒBNFCList non-terminals, e.g., [Ident], [Exp], [Exp1].„BNFCE.g. Exp1, Exp2.†BNFC4A "ranged string" (terminology from Agda code base).‹BNFCSource positions.ŽBNFCName of the grammar file.�BNFCLine in the grammar file.�BNFCColumn in the grammar file.“BNFCÂLiteral: builtin-token types Char, String, Ident, Integer, Double.”BNFCList delimiters.–BNFCList separator.—BNFCList opening delimiter.˜BNFCList closing delimiter.šBNFCFunction arguments with type.žBNFC,Argument types inferred by the type checker. BNFC/Type of the body, inferred by the type checker.¡BNFCPragmas.¢BNFCfor single line comments£BNFCfor multiple-line comments.¤BNFC for tokens¨BNFCSeparator for top-level layout.«BNFC%Expressions for function definitions.¬BNFCÁ(Possibly defined) label applied to expressions. The function ²! is inferred by the type checker.­BNFCFunction parameter.²BNFCType of a rule label.·BNFCType of a non-terminal.¸BNFCÇTypes of the rule labels, together with the position of the rule label.¹BNFC$Type of context-free grammars (GFG).¼BNFCCategories used by the parser.½BNFC$Char, String, Ident, Integer, Double. Strings are quoted strings, and Idents are unquoted.¾BNFC'Symbols in the grammar, e.g. œ@*�@, œ@->�@.¿BNFCReserved words, e.g. if, while.ÀBNFC+Categories that can be made left-recursive.ÂBNFC$Types of rule labels, computed from Á.ÃBNFC>A sentential form is a sequence of non-terminals or terminals.ÅBNFCinternal rule (only for AST & printer)ÆBNFCordinary rule (also for parser)ÇBNFCPolymorphic rule type.ÉBNFC�The function (semantic action) of a rule. In order to be able to generate data types this must be a constructor (or an identity function).ÊBNFC3The value category, i.e., the defined non-terminal.ËBNFCÚThe sentential form, i.e., the list of (non)terminals in the right-hand-side of a rule.ÌBNFCÍIs this an "internal" rule only for the AST and printing, not for parsing?ÍBNFCãA rule consists of a function name, a main category and a sequence of terminals and non-terminals. ( function_name . Main_Cat ::= sequence ÎBNFCýA context free grammar consists of a set of rules and some extended information (e.g. pragmas, literals, symbols, keywords).ÐBNFCPlaceholder for a type.ÑBNFC Placeholder for a function type.ÒBNFC For use with partitionEithers.ÓBNFCAll define pragmas of the grammar.ÔBNFC&User-defined regular expression tokensÕBNFC%The names of all user-defined tokens.ÛBNFC7Prefix string with pretty-printed position information.ßBNFC"Render category symbols as stringsàBNFCŠReads a string into a category. This should only need to handle the case of simple categories (with or without coercion) since list categories are parsed in the grammar already. To be on the safe side here, we still call the parser function that parses categries.æBNFC-Token categories corresponding to base types.èBNFC,Does the category correspond to a data type?êBNFC�Categories C1, C2,... (one digit at the end) are variants of C. This function returns true if two category are variants of the same abstract category. E.g.'sameCat (Cat "Abc") (CoercCat "Abc" 44)TrueëBNFC4Removes precedence information. C1 => C, [C2] => [C]íBNFCãWhen given a list Cat, i.e. '[C]', it removes the square brackets, and adds the prefix List, i.e. ListC. (for Happy and Latex)ïBNFCæReconstruct (non-coercion) category from a type, given a list of what should be the token categories.ñBNFC'Get the underlying category identifier.ôBNFC=Unwraps the list constructor from the category name. E.g.  [C1] => C1.ùBNFC firstEntry returns the first of the  entrypoints&, or (if none), the first parsable Category appearing in the grammar.úBNFCConstructors and categories.ûBNFC/Get all elements with more than one occurrence.üBNFCExtract the comment pragmas.þBNFCåReturns all parseable rules that construct the given Cat. Whitespace separators have been removed.€BNFC Modify the Ë part of a Í.�BNFCÏLike rulesForCat but for normalized value categories. I.e., `rulesForCat (Cat ExpÑ)` will return rules for category Exp but also Exp1, Exp2... in case of coercion‚BNFCÀAs rulesForCat, but this version doesn't exclude internal rules.ƒBNFCèGet all categories of a grammar matching the filter. (No Cat w/o production returned; no duplicates.)„BNFCÔGet all categories of a grammar. (No Cat w/o production returned; no duplicates.)†BNFC)Gets all normalized identified Categories‡BNFCGet all normalized CatˆBNFCGet all normalized Cat‰BNFC>Is the category is used on an rhs? Includes internal rules.ŠBNFC„Group all parsable categories with their rules. Deletes whitespace separators, as they will not become part of the parsing rules.‹BNFC?Group all categories with their rules including internal rules.ŒBNFC4Get all literals of a grammar. (e.g. String, Double)�BNFCGet the keywords of a grammar.ŽBNFCÚCanonical, numbered list of symbols and reserved words. (These do not end up in the AST.)�BNFCComments can be defined by the comment pragma�BNFC:Number of block comment forms defined in the grammar file.‘BNFC3Whether the grammar uses the predefined Ident type.’BNFCÙCategories corresponding to tokens. These end up in the AST. (unlike tokens returned by Ž)“BNFC¼Return the abstract syntax of the grammar. All categories are normalized, so a rule like: EAdd . Exp2 ::= Exp2 "+" Exp3 ; Will give the following signature: EAdd : Exp -> Exp -> Exp”BNFCÁAll the functions below implement the idea of getting the abstract syntax of the grammar with some variation but they seem to do a poor job at handling corner cases involving coercions. Use “ instead if possible.˜BNFCGet the type of a rule label.™BNFCChecks if the rule is parsable.›BNFC4Gets the singleton rule out of the rules for a list.œBNFC$Sort rules by descending precedence.�BNFC?Is the given category a list category parsing also empty lists?¢BNFCÊReturns the precedence of a category symbol. E.g. >>> precCat (CoercCat Abc 4) 4¤BNFC-Defines or uses the grammar token types like Ident? Excludes position tokens.¥BNFCDefines or uses the grammar token types or Ident?¦BNFC Is there a position token declaration in the grammar?§BNFC0Does the category have a position stored in AST?¨BNFC/Categories that are entry points to the parser.These are either the declared  entrypoints' (in the original order), or, if no  entrypointsè were declared explicitly, all parsable categories (in the order of declaration in the grammar file).­BNFC)Ignore position in equality and ordering.¯BNFC*This instance is for the Hspec test suite.öBNFC(Is this the constructor for empty lists?÷BNFC,Is this the constructor for singleton lists?øBNFCIs this the list constructor?ùBNFCIs this list concatenation?¶óôúù÷õöøûüýþÿ€„‚ƒ�…†‡ˆ‰Š‹Œ���Ž‘’“”•˜—–™š›œ Ÿž�¡©¥¤£¢¨§¦ª«¯±°®¬­²³´µ¶·¸¹ºÂÁÀ¿¾½¼»ÃÄÆÅÇÈËÊÉÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ€�‚ƒ„…†‡ˆ‰Š‹Œ�Ž��‘’“”•–—˜™š›œ�žŸ ¡¢£¤¥¦§¨¶ÏÎÍÇÈËÊÉÌÄÆÅùºÂÁÀ¿¾½¼»¸·´µ¶²³ÐÑ«¯±°®¬­ª¡©¥¤£¢¨§¦›œ Ÿž�šÒÓ™”•˜—–ÔÕÖר“’‘‹Œ���ŽÙ‡ˆ‰ŠÚ†Û…ÜÝÞ€„‚ƒ�ÿþýßàáâãäåæçèéêëìíîïðñòóôüûôúù÷õöøõö÷øóùúûüýþÿ€�‚ƒ„…†‡ˆ‰Š‹Œ�Ž��‘’“”•–—˜™š›œ�žŸ ¡¢£¤¥¦§¨None #$%9>?ÀÁÂÎÑÖ×Ùàá_öÍBNFC· is the element type. ² the list type.ÏBNFCUser-defined token types.ÑBNFC Entry point.ÓBNFCÎCreate context containing the types of all labels, computed from the rules.+Fail if a label is used at different types.ÒBNFC%Translation of the list constructors.BNFCSignature (types of labels).BNFCFunction name.BNFCFunction arguments.BNFCFunction body.BNFC/Typed arguments, translated body, type of body. ËÌÎÍÏÐÑÒÓÔÕ ÐÑÒÓÔÏÕËÌÎÍNone #$%9>?ÀÑÖ×ÙàáaÊáBNFC$Create regex for multiline comments.*debugPrint $ mkRegMultilineComment "<" ">"'<'(char-'>')*'>',debugPrint $ mkRegMultilineComment "/*" "*/"9{"/*"}(char-'*')*'*'((char-["*/"])(char-'*')*'*'|'*')*'/'/debugPrint $ mkRegMultilineComment ""ã{"