diff --git a/examples/announcement.cash b/examples/announcement.cash index d8dbce8a..ffcb5ada 100644 --- a/examples/announcement.cash +++ b/examples/announcement.cash @@ -1,4 +1,4 @@ -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; /* This is a contract showcasing covenants outside of regular transactional use. * It enforces the contract to make an "announcement" on Memo.cash, and send the diff --git a/examples/hodl_vault.cash b/examples/hodl_vault.cash index d5849322..6bf77f1a 100644 --- a/examples/hodl_vault.cash +++ b/examples/hodl_vault.cash @@ -1,4 +1,4 @@ -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; // This contract forces HODLing until a certain price target has been reached // A minimum block is provided to ensure that oracle price entries from before this block are disregarded diff --git a/examples/mecenas.cash b/examples/mecenas.cash index aef868ab..b04d563d 100644 --- a/examples/mecenas.cash +++ b/examples/mecenas.cash @@ -1,4 +1,4 @@ -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; /* This is an unofficial CashScript port of Licho's Mecenas contract. It is * not compatible with Licho's EC plugin, but rather meant as a demonstration diff --git a/examples/mecenas_locktime.cash b/examples/mecenas_locktime.cash index f4d1ccdc..5439977b 100644 --- a/examples/mecenas_locktime.cash +++ b/examples/mecenas_locktime.cash @@ -1,4 +1,4 @@ -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; // This is an experimental contract for a more "streaming" Mecenas experience // Completely untested, just a concept diff --git a/examples/p2pkh.cash b/examples/p2pkh.cash index 0cd49ca0..66b407f6 100644 --- a/examples/p2pkh.cash +++ b/examples/p2pkh.cash @@ -1,4 +1,4 @@ -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract P2PKH(bytes20 pkh) { // Require pk to match stored pkh and signature to match diff --git a/examples/package.json b/examples/package.json index ff3f9988..28262a53 100644 --- a/examples/package.json +++ b/examples/package.json @@ -1,7 +1,7 @@ { "name": "cashscript-examples", "private": true, - "version": "0.12.0", + "version": "0.13.0-next.0", "description": "Usage examples of the CashScript SDK", "main": "p2pkh.js", "type": "module", @@ -13,8 +13,8 @@ "dependencies": { "@bitauth/libauth": "^3.1.0-next.8", "@types/node": "^22.17.0", - "cashc": "^0.12.0", - "cashscript": "^0.12.0", + "cashc": "^0.13.0-next.0", + "cashscript": "^0.13.0-next.0", "eslint": "^8.56.0", "typescript": "^5.9.2" } diff --git a/examples/testing-suite/artifacts/example.json b/examples/testing-suite/artifacts/example.json index b28c0de2..dc847889 100644 --- a/examples/testing-suite/artifacts/example.json +++ b/examples/testing-suite/artifacts/example.json @@ -41,7 +41,7 @@ }, "compiler": { "name": "cashc", - "version": "0.12.0" + "version": "0.13.0" }, "updatedAt": "2025-10-02T09:56:11.510Z" -} \ No newline at end of file +} diff --git a/examples/testing-suite/package.json b/examples/testing-suite/package.json index 53b4f682..8de7823e 100644 --- a/examples/testing-suite/package.json +++ b/examples/testing-suite/package.json @@ -1,6 +1,6 @@ { "name": "testing-suite", - "version": "0.12.0", + "version": "0.13.0-next.0", "description": "Example project to develop and test CashScript contracts", "main": "index.js", "type": "module", @@ -26,8 +26,8 @@ }, "dependencies": { "@bitauth/libauth": "^3.1.0-next.8", - "cashc": "^0.12.0", - "cashscript": "^0.12.0", + "cashc": "^0.13.0-next.0", + "cashscript": "^0.13.0-next.0", "url-join": "^5.0.0" }, "devDependencies": { diff --git a/examples/transfer_with_timeout.cash b/examples/transfer_with_timeout.cash index 98723e44..ab06c01a 100644 --- a/examples/transfer_with_timeout.cash +++ b/examples/transfer_with_timeout.cash @@ -1,4 +1,4 @@ -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract TransferWithTimeout( pubkey sender, diff --git a/packages/cashc/package.json b/packages/cashc/package.json index 43e145a6..8d165577 100644 --- a/packages/cashc/package.json +++ b/packages/cashc/package.json @@ -1,6 +1,6 @@ { "name": "cashc", - "version": "0.12.0", + "version": "0.13.0-next.0", "description": "Compile Bitcoin Cash contracts to Bitcoin Cash Script or artifacts", "keywords": [ "bitcoin", @@ -52,7 +52,7 @@ }, "dependencies": { "@bitauth/libauth": "^3.1.0-next.8", - "@cashscript/utils": "^0.12.0", + "@cashscript/utils": "^0.13.0-next.0", "antlr4": "^4.13.2", "commander": "^14.0.0", "semver": "^7.7.2" diff --git a/packages/cashc/src/ast/AST.ts b/packages/cashc/src/ast/AST.ts index b43935dd..fa247e04 100644 --- a/packages/cashc/src/ast/AST.ts +++ b/packages/cashc/src/ast/AST.ts @@ -165,6 +165,19 @@ export class BranchNode extends StatementNode { } } +export class DoWhileNode extends StatementNode { + constructor( + public condition: ExpressionNode, + public block: BlockNode, + ) { + super(); + } + + accept(visitor: AstVisitor): T { + return visitor.visitDoWhile(this); + } +} + export class BlockNode extends Node { symbolTable?: SymbolTable; diff --git a/packages/cashc/src/ast/AstBuilder.ts b/packages/cashc/src/ast/AstBuilder.ts index 7f5bc994..6d10fd68 100644 --- a/packages/cashc/src/ast/AstBuilder.ts +++ b/packages/cashc/src/ast/AstBuilder.ts @@ -34,6 +34,7 @@ import { ConsoleStatementNode, ConsoleParameterNode, SliceNode, + DoWhileNode, } from './AST.js'; import { UnaryOperator, BinaryOperator, NullaryOperator } from './Operator.js'; import type { @@ -68,6 +69,8 @@ import type { StatementContext, RequireMessageContext, SliceContext, + DoWhileStatementContext, + LoopStatementContext, } from '../grammar/CashScriptParser.js'; import CashScriptVisitor from '../grammar/CashScriptVisitor.js'; import { Location } from './Location.js'; @@ -214,6 +217,18 @@ export default class AstBuilder return branch; } + visitLoopStatement(ctx: LoopStatementContext): DoWhileNode { + return this.visit(ctx.doWhileStatement()) as DoWhileNode; + } + + visitDoWhileStatement(ctx: DoWhileStatementContext): DoWhileNode { + const condition = this.visit(ctx.expression()); + const block = this.visit(ctx.block()) as StatementNode; + const doWhile = new DoWhileNode(condition, block); + doWhile.location = Location.fromCtx(ctx); + return doWhile; + } + visitBlock(ctx: BlockContext): BlockNode { const statements = ctx.statement_list().map((s) => this.visit(s) as StatementNode); const block = new BlockNode(statements); diff --git a/packages/cashc/src/ast/AstTraversal.ts b/packages/cashc/src/ast/AstTraversal.ts index 4d94df61..9eaa07f3 100644 --- a/packages/cashc/src/ast/AstTraversal.ts +++ b/packages/cashc/src/ast/AstTraversal.ts @@ -28,6 +28,7 @@ import { ConsoleStatementNode, ConsoleParameterNode, SliceNode, + DoWhileNode, } from './AST.js'; import AstVisitor from './AstVisitor.js'; @@ -86,6 +87,12 @@ export default class AstTraversal extends AstVisitor { return node; } + visitDoWhile(node: DoWhileNode): Node { + node.condition = this.visit(node.condition); + node.block = this.visit(node.block) as StatementNode; + return node; + } + visitBlock(node: BlockNode): Node { node.statements = this.visitOptionalList(node.statements) as StatementNode[]; return node; diff --git a/packages/cashc/src/ast/AstVisitor.ts b/packages/cashc/src/ast/AstVisitor.ts index 8e558ed0..8b47528a 100644 --- a/packages/cashc/src/ast/AstVisitor.ts +++ b/packages/cashc/src/ast/AstVisitor.ts @@ -26,6 +26,7 @@ import { NullaryOpNode, ConsoleStatementNode, SliceNode, + DoWhileNode, } from './AST.js'; export default abstract class AstVisitor { @@ -39,6 +40,7 @@ export default abstract class AstVisitor { abstract visitTimeOp(node: TimeOpNode): T; abstract visitRequire(node: RequireNode): T; abstract visitBranch(node: BranchNode): T; + abstract visitDoWhile(node: DoWhileNode): T; abstract visitBlock(node: BlockNode): T; abstract visitCast(node: CastNode): T; abstract visitFunctionCall(node: FunctionCallNode): T; diff --git a/packages/cashc/src/generation/GenerateTargetTraversal.ts b/packages/cashc/src/generation/GenerateTargetTraversal.ts index 6f17eda6..ca24484a 100644 --- a/packages/cashc/src/generation/GenerateTargetTraversal.ts +++ b/packages/cashc/src/generation/GenerateTargetTraversal.ts @@ -47,6 +47,7 @@ import { ConsoleParameterNode, ConsoleStatementNode, SliceNode, + DoWhileNode, } from '../ast/AST.js'; import AstTraversal from '../ast/AstTraversal.js'; import { GlobalFunction, Class } from '../ast/Globals.js'; @@ -197,7 +198,7 @@ export default class GenerateTargetTraversalWithLocation extends AstTraversal { removeFinalVerifyFromFunction(functionBodyNode: Node): void { // After EnsureFinalRequireTraversal, we know that the final opcodes are either - // "OP_VERIFY", "OP_CHECK{LOCKTIME|SEQUENCE}VERIFY OP_DROP" or "OP_ENDIF" + // "OP_VERIFY", "OP_CHECK{LOCKTIME|SEQUENCE}VERIFY OP_DROP", "OP_ENDIF" or "OP_UNTIL" const finalOp = this.output.pop() as Op; const { location, positionHint } = this.locationData.pop()!; @@ -219,7 +220,7 @@ export default class GenerateTargetTraversalWithLocation extends AstTraversal { this.emit(finalOp, { location, positionHint: PositionHint.END }); // At this point there is no verification value left on the stack: - // - scoped stack is cleared inside branch ended by OP_ENDIF + // - scoped stack is cleared inside block ended by OP_ENDIF or OP_UNTIL // - OP_CHECK{LOCKTIME|SEQUENCE}VERIFY OP_DROP does not leave a verification value // - OP_VERIFY does not leave a verification value // so we add OP_1 to the script (indicating success) @@ -381,6 +382,23 @@ export default class GenerateTargetTraversalWithLocation extends AstTraversal { return node; } + visitDoWhile(node: DoWhileNode): Node { + this.scopeDepth += 1; + this.emit(Op.OP_BEGIN, { location: node.location, positionHint: PositionHint.START }); + + const stackDepth = this.stack.length; + node.block = this.visit(node.block); + this.removeScopedVariables(stackDepth, node.block); + + node.condition = this.visit(node.condition); + this.emit(Op.OP_NOT, { location: node.location, positionHint: PositionHint.END }); + + this.emit(Op.OP_UNTIL, { location: node.location, positionHint: PositionHint.END }); + this.popFromStack(); + + return node; + } + removeScopedVariables(depthBeforeScope: number, node: Node): void { const dropCount = this.stack.length - depthBeforeScope; for (let i = 0; i < dropCount; i += 1) { diff --git a/packages/cashc/src/grammar/CashScript.g4 b/packages/cashc/src/grammar/CashScript.g4 index 6b79d54e..38b0c115 100644 --- a/packages/cashc/src/grammar/CashScript.g4 +++ b/packages/cashc/src/grammar/CashScript.g4 @@ -52,6 +52,7 @@ statement | timeOpStatement | requireStatement | ifStatement + | loopStatement | consoleStatement ; @@ -79,6 +80,14 @@ ifStatement : 'if' '(' expression ')' ifBlock=block ('else' elseBlock=block)? ; +loopStatement + : doWhileStatement + ; + +doWhileStatement + : 'do' block 'while' '(' expression ')' ';' + ; + consoleStatement : 'console.log' consoleParameterList ';' ; diff --git a/packages/cashc/src/grammar/CashScript.interp b/packages/cashc/src/grammar/CashScript.interp index f59a2136..85f6dfd9 100644 --- a/packages/cashc/src/grammar/CashScript.interp +++ b/packages/cashc/src/grammar/CashScript.interp @@ -20,6 +20,8 @@ null 'require' 'if' 'else' +'do' +'while' 'console.log' 'new' '[' @@ -136,6 +138,8 @@ null null null null +null +null VersionLiteral BooleanLiteral NumberUnit @@ -173,6 +177,8 @@ assignStatement timeOpStatement requireStatement ifStatement +loopStatement +doWhileStatement consoleStatement requireMessage consoleParameter @@ -187,4 +193,4 @@ typeName atn: -[4, 1, 75, 373, 2, 0, 7, 0, 2, 1, 7, 1, 2, 2, 7, 2, 2, 3, 7, 3, 2, 4, 7, 4, 2, 5, 7, 5, 2, 6, 7, 6, 2, 7, 7, 7, 2, 8, 7, 8, 2, 9, 7, 9, 2, 10, 7, 10, 2, 11, 7, 11, 2, 12, 7, 12, 2, 13, 7, 13, 2, 14, 7, 14, 2, 15, 7, 15, 2, 16, 7, 16, 2, 17, 7, 17, 2, 18, 7, 18, 2, 19, 7, 19, 2, 20, 7, 20, 2, 21, 7, 21, 2, 22, 7, 22, 2, 23, 7, 23, 2, 24, 7, 24, 2, 25, 7, 25, 2, 26, 7, 26, 2, 27, 7, 27, 2, 28, 7, 28, 1, 0, 5, 0, 60, 8, 0, 10, 0, 12, 0, 63, 9, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1, 3, 1, 3, 3, 3, 77, 8, 3, 1, 4, 3, 4, 80, 8, 4, 1, 4, 1, 4, 1, 5, 1, 5, 1, 6, 1, 6, 1, 6, 1, 6, 1, 6, 5, 6, 91, 8, 6, 10, 6, 12, 6, 94, 9, 6, 1, 6, 1, 6, 1, 7, 1, 7, 1, 7, 1, 7, 1, 7, 5, 7, 103, 8, 7, 10, 7, 12, 7, 106, 9, 7, 1, 7, 1, 7, 1, 8, 1, 8, 1, 8, 1, 8, 5, 8, 114, 8, 8, 10, 8, 12, 8, 117, 9, 8, 1, 8, 3, 8, 120, 8, 8, 3, 8, 122, 8, 8, 1, 8, 1, 8, 1, 9, 1, 9, 1, 9, 1, 10, 1, 10, 5, 10, 131, 8, 10, 10, 10, 12, 10, 134, 9, 10, 1, 10, 1, 10, 3, 10, 138, 8, 10, 1, 11, 1, 11, 1, 11, 1, 11, 1, 11, 1, 11, 1, 11, 3, 11, 147, 8, 11, 1, 12, 1, 12, 5, 12, 151, 8, 12, 10, 12, 12, 12, 154, 9, 12, 1, 12, 1, 12, 1, 12, 1, 12, 1, 12, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 14, 1, 14, 1, 14, 1, 14, 1, 14, 1, 15, 1, 15, 1, 15, 1, 15, 1, 15, 1, 15, 1, 15, 3, 15, 182, 8, 15, 1, 15, 1, 15, 1, 15, 1, 16, 1, 16, 1, 16, 1, 16, 1, 16, 3, 16, 192, 8, 16, 1, 16, 1, 16, 1, 16, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 3, 17, 204, 8, 17, 1, 18, 1, 18, 1, 18, 1, 18, 1, 19, 1, 19, 1, 20, 1, 20, 3, 20, 214, 8, 20, 1, 21, 1, 21, 1, 21, 1, 21, 5, 21, 220, 8, 21, 10, 21, 12, 21, 223, 9, 21, 1, 21, 3, 21, 226, 8, 21, 3, 21, 228, 8, 21, 1, 21, 1, 21, 1, 22, 1, 22, 1, 22, 1, 23, 1, 23, 1, 23, 1, 23, 5, 23, 239, 8, 23, 10, 23, 12, 23, 242, 9, 23, 1, 23, 3, 23, 245, 8, 23, 3, 23, 247, 8, 23, 1, 23, 1, 23, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 3, 24, 261, 8, 24, 1, 24, 3, 24, 264, 8, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 5, 24, 290, 8, 24, 10, 24, 12, 24, 293, 9, 24, 1, 24, 3, 24, 296, 8, 24, 3, 24, 298, 8, 24, 1, 24, 1, 24, 1, 24, 1, 24, 3, 24, 304, 8, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 5, 24, 353, 8, 24, 10, 24, 12, 24, 356, 9, 24, 1, 25, 1, 25, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 3, 26, 365, 8, 26, 1, 27, 1, 27, 3, 27, 369, 8, 27, 1, 28, 1, 28, 1, 28, 0, 1, 48, 29, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 0, 10, 1, 0, 4, 10, 1, 0, 26, 30, 2, 0, 26, 30, 32, 35, 1, 0, 40, 41, 1, 0, 42, 44, 2, 0, 41, 41, 45, 45, 1, 0, 6, 9, 1, 0, 46, 47, 1, 0, 36, 37, 2, 0, 53, 58, 65, 65, 403, 0, 61, 1, 0, 0, 0, 2, 67, 1, 0, 0, 0, 4, 72, 1, 0, 0, 0, 6, 74, 1, 0, 0, 0, 8, 79, 1, 0, 0, 0, 10, 83, 1, 0, 0, 0, 12, 85, 1, 0, 0, 0, 14, 97, 1, 0, 0, 0, 16, 109, 1, 0, 0, 0, 18, 125, 1, 0, 0, 0, 20, 137, 1, 0, 0, 0, 22, 146, 1, 0, 0, 0, 24, 148, 1, 0, 0, 0, 26, 160, 1, 0, 0, 0, 28, 169, 1, 0, 0, 0, 30, 174, 1, 0, 0, 0, 32, 186, 1, 0, 0, 0, 34, 196, 1, 0, 0, 0, 36, 205, 1, 0, 0, 0, 38, 209, 1, 0, 0, 0, 40, 213, 1, 0, 0, 0, 42, 215, 1, 0, 0, 0, 44, 231, 1, 0, 0, 0, 46, 234, 1, 0, 0, 0, 48, 303, 1, 0, 0, 0, 50, 357, 1, 0, 0, 0, 52, 364, 1, 0, 0, 0, 54, 366, 1, 0, 0, 0, 56, 370, 1, 0, 0, 0, 58, 60, 3, 2, 1, 0, 59, 58, 1, 0, 0, 0, 60, 63, 1, 0, 0, 0, 61, 59, 1, 0, 0, 0, 61, 62, 1, 0, 0, 0, 62, 64, 1, 0, 0, 0, 63, 61, 1, 0, 0, 0, 64, 65, 3, 12, 6, 0, 65, 66, 5, 0, 0, 1, 66, 1, 1, 0, 0, 0, 67, 68, 5, 1, 0, 0, 68, 69, 3, 4, 2, 0, 69, 70, 3, 6, 3, 0, 70, 71, 5, 2, 0, 0, 71, 3, 1, 0, 0, 0, 72, 73, 5, 3, 0, 0, 73, 5, 1, 0, 0, 0, 74, 76, 3, 8, 4, 0, 75, 77, 3, 8, 4, 0, 76, 75, 1, 0, 0, 0, 76, 77, 1, 0, 0, 0, 77, 7, 1, 0, 0, 0, 78, 80, 3, 10, 5, 0, 79, 78, 1, 0, 0, 0, 79, 80, 1, 0, 0, 0, 80, 81, 1, 0, 0, 0, 81, 82, 5, 59, 0, 0, 82, 9, 1, 0, 0, 0, 83, 84, 7, 0, 0, 0, 84, 11, 1, 0, 0, 0, 85, 86, 5, 11, 0, 0, 86, 87, 5, 72, 0, 0, 87, 88, 3, 16, 8, 0, 88, 92, 5, 12, 0, 0, 89, 91, 3, 14, 7, 0, 90, 89, 1, 0, 0, 0, 91, 94, 1, 0, 0, 0, 92, 90, 1, 0, 0, 0, 92, 93, 1, 0, 0, 0, 93, 95, 1, 0, 0, 0, 94, 92, 1, 0, 0, 0, 95, 96, 5, 13, 0, 0, 96, 13, 1, 0, 0, 0, 97, 98, 5, 14, 0, 0, 98, 99, 5, 72, 0, 0, 99, 100, 3, 16, 8, 0, 100, 104, 5, 12, 0, 0, 101, 103, 3, 22, 11, 0, 102, 101, 1, 0, 0, 0, 103, 106, 1, 0, 0, 0, 104, 102, 1, 0, 0, 0, 104, 105, 1, 0, 0, 0, 105, 107, 1, 0, 0, 0, 106, 104, 1, 0, 0, 0, 107, 108, 5, 13, 0, 0, 108, 15, 1, 0, 0, 0, 109, 121, 5, 15, 0, 0, 110, 115, 3, 18, 9, 0, 111, 112, 5, 16, 0, 0, 112, 114, 3, 18, 9, 0, 113, 111, 1, 0, 0, 0, 114, 117, 1, 0, 0, 0, 115, 113, 1, 0, 0, 0, 115, 116, 1, 0, 0, 0, 116, 119, 1, 0, 0, 0, 117, 115, 1, 0, 0, 0, 118, 120, 5, 16, 0, 0, 119, 118, 1, 0, 0, 0, 119, 120, 1, 0, 0, 0, 120, 122, 1, 0, 0, 0, 121, 110, 1, 0, 0, 0, 121, 122, 1, 0, 0, 0, 122, 123, 1, 0, 0, 0, 123, 124, 5, 17, 0, 0, 124, 17, 1, 0, 0, 0, 125, 126, 3, 56, 28, 0, 126, 127, 5, 72, 0, 0, 127, 19, 1, 0, 0, 0, 128, 132, 5, 12, 0, 0, 129, 131, 3, 22, 11, 0, 130, 129, 1, 0, 0, 0, 131, 134, 1, 0, 0, 0, 132, 130, 1, 0, 0, 0, 132, 133, 1, 0, 0, 0, 133, 135, 1, 0, 0, 0, 134, 132, 1, 0, 0, 0, 135, 138, 5, 13, 0, 0, 136, 138, 3, 22, 11, 0, 137, 128, 1, 0, 0, 0, 137, 136, 1, 0, 0, 0, 138, 21, 1, 0, 0, 0, 139, 147, 3, 24, 12, 0, 140, 147, 3, 26, 13, 0, 141, 147, 3, 28, 14, 0, 142, 147, 3, 30, 15, 0, 143, 147, 3, 32, 16, 0, 144, 147, 3, 34, 17, 0, 145, 147, 3, 36, 18, 0, 146, 139, 1, 0, 0, 0, 146, 140, 1, 0, 0, 0, 146, 141, 1, 0, 0, 0, 146, 142, 1, 0, 0, 0, 146, 143, 1, 0, 0, 0, 146, 144, 1, 0, 0, 0, 146, 145, 1, 0, 0, 0, 147, 23, 1, 0, 0, 0, 148, 152, 3, 56, 28, 0, 149, 151, 3, 50, 25, 0, 150, 149, 1, 0, 0, 0, 151, 154, 1, 0, 0, 0, 152, 150, 1, 0, 0, 0, 152, 153, 1, 0, 0, 0, 153, 155, 1, 0, 0, 0, 154, 152, 1, 0, 0, 0, 155, 156, 5, 72, 0, 0, 156, 157, 5, 10, 0, 0, 157, 158, 3, 48, 24, 0, 158, 159, 5, 2, 0, 0, 159, 25, 1, 0, 0, 0, 160, 161, 3, 56, 28, 0, 161, 162, 5, 72, 0, 0, 162, 163, 5, 16, 0, 0, 163, 164, 3, 56, 28, 0, 164, 165, 5, 72, 0, 0, 165, 166, 5, 10, 0, 0, 166, 167, 3, 48, 24, 0, 167, 168, 5, 2, 0, 0, 168, 27, 1, 0, 0, 0, 169, 170, 5, 72, 0, 0, 170, 171, 5, 10, 0, 0, 171, 172, 3, 48, 24, 0, 172, 173, 5, 2, 0, 0, 173, 29, 1, 0, 0, 0, 174, 175, 5, 18, 0, 0, 175, 176, 5, 15, 0, 0, 176, 177, 5, 70, 0, 0, 177, 178, 5, 6, 0, 0, 178, 181, 3, 48, 24, 0, 179, 180, 5, 16, 0, 0, 180, 182, 3, 38, 19, 0, 181, 179, 1, 0, 0, 0, 181, 182, 1, 0, 0, 0, 182, 183, 1, 0, 0, 0, 183, 184, 5, 17, 0, 0, 184, 185, 5, 2, 0, 0, 185, 31, 1, 0, 0, 0, 186, 187, 5, 18, 0, 0, 187, 188, 5, 15, 0, 0, 188, 191, 3, 48, 24, 0, 189, 190, 5, 16, 0, 0, 190, 192, 3, 38, 19, 0, 191, 189, 1, 0, 0, 0, 191, 192, 1, 0, 0, 0, 192, 193, 1, 0, 0, 0, 193, 194, 5, 17, 0, 0, 194, 195, 5, 2, 0, 0, 195, 33, 1, 0, 0, 0, 196, 197, 5, 19, 0, 0, 197, 198, 5, 15, 0, 0, 198, 199, 3, 48, 24, 0, 199, 200, 5, 17, 0, 0, 200, 203, 3, 20, 10, 0, 201, 202, 5, 20, 0, 0, 202, 204, 3, 20, 10, 0, 203, 201, 1, 0, 0, 0, 203, 204, 1, 0, 0, 0, 204, 35, 1, 0, 0, 0, 205, 206, 5, 21, 0, 0, 206, 207, 3, 42, 21, 0, 207, 208, 5, 2, 0, 0, 208, 37, 1, 0, 0, 0, 209, 210, 5, 67, 0, 0, 210, 39, 1, 0, 0, 0, 211, 214, 5, 72, 0, 0, 212, 214, 3, 52, 26, 0, 213, 211, 1, 0, 0, 0, 213, 212, 1, 0, 0, 0, 214, 41, 1, 0, 0, 0, 215, 227, 5, 15, 0, 0, 216, 221, 3, 40, 20, 0, 217, 218, 5, 16, 0, 0, 218, 220, 3, 40, 20, 0, 219, 217, 1, 0, 0, 0, 220, 223, 1, 0, 0, 0, 221, 219, 1, 0, 0, 0, 221, 222, 1, 0, 0, 0, 222, 225, 1, 0, 0, 0, 223, 221, 1, 0, 0, 0, 224, 226, 5, 16, 0, 0, 225, 224, 1, 0, 0, 0, 225, 226, 1, 0, 0, 0, 226, 228, 1, 0, 0, 0, 227, 216, 1, 0, 0, 0, 227, 228, 1, 0, 0, 0, 228, 229, 1, 0, 0, 0, 229, 230, 5, 17, 0, 0, 230, 43, 1, 0, 0, 0, 231, 232, 5, 72, 0, 0, 232, 233, 3, 46, 23, 0, 233, 45, 1, 0, 0, 0, 234, 246, 5, 15, 0, 0, 235, 240, 3, 48, 24, 0, 236, 237, 5, 16, 0, 0, 237, 239, 3, 48, 24, 0, 238, 236, 1, 0, 0, 0, 239, 242, 1, 0, 0, 0, 240, 238, 1, 0, 0, 0, 240, 241, 1, 0, 0, 0, 241, 244, 1, 0, 0, 0, 242, 240, 1, 0, 0, 0, 243, 245, 5, 16, 0, 0, 244, 243, 1, 0, 0, 0, 244, 245, 1, 0, 0, 0, 245, 247, 1, 0, 0, 0, 246, 235, 1, 0, 0, 0, 246, 247, 1, 0, 0, 0, 247, 248, 1, 0, 0, 0, 248, 249, 5, 17, 0, 0, 249, 47, 1, 0, 0, 0, 250, 251, 6, 24, -1, 0, 251, 252, 5, 15, 0, 0, 252, 253, 3, 48, 24, 0, 253, 254, 5, 17, 0, 0, 254, 304, 1, 0, 0, 0, 255, 256, 3, 56, 28, 0, 256, 257, 5, 15, 0, 0, 257, 260, 3, 48, 24, 0, 258, 259, 5, 16, 0, 0, 259, 261, 3, 48, 24, 0, 260, 258, 1, 0, 0, 0, 260, 261, 1, 0, 0, 0, 261, 263, 1, 0, 0, 0, 262, 264, 5, 16, 0, 0, 263, 262, 1, 0, 0, 0, 263, 264, 1, 0, 0, 0, 264, 265, 1, 0, 0, 0, 265, 266, 5, 17, 0, 0, 266, 304, 1, 0, 0, 0, 267, 304, 3, 44, 22, 0, 268, 269, 5, 22, 0, 0, 269, 270, 5, 72, 0, 0, 270, 304, 3, 46, 23, 0, 271, 272, 5, 25, 0, 0, 272, 273, 5, 23, 0, 0, 273, 274, 3, 48, 24, 0, 274, 275, 5, 24, 0, 0, 275, 276, 7, 1, 0, 0, 276, 304, 1, 0, 0, 0, 277, 278, 5, 31, 0, 0, 278, 279, 5, 23, 0, 0, 279, 280, 3, 48, 24, 0, 280, 281, 5, 24, 0, 0, 281, 282, 7, 2, 0, 0, 282, 304, 1, 0, 0, 0, 283, 284, 7, 3, 0, 0, 284, 304, 3, 48, 24, 14, 285, 297, 5, 23, 0, 0, 286, 291, 3, 48, 24, 0, 287, 288, 5, 16, 0, 0, 288, 290, 3, 48, 24, 0, 289, 287, 1, 0, 0, 0, 290, 293, 1, 0, 0, 0, 291, 289, 1, 0, 0, 0, 291, 292, 1, 0, 0, 0, 292, 295, 1, 0, 0, 0, 293, 291, 1, 0, 0, 0, 294, 296, 5, 16, 0, 0, 295, 294, 1, 0, 0, 0, 295, 296, 1, 0, 0, 0, 296, 298, 1, 0, 0, 0, 297, 286, 1, 0, 0, 0, 297, 298, 1, 0, 0, 0, 298, 299, 1, 0, 0, 0, 299, 304, 5, 24, 0, 0, 300, 304, 5, 71, 0, 0, 301, 304, 5, 72, 0, 0, 302, 304, 3, 52, 26, 0, 303, 250, 1, 0, 0, 0, 303, 255, 1, 0, 0, 0, 303, 267, 1, 0, 0, 0, 303, 268, 1, 0, 0, 0, 303, 271, 1, 0, 0, 0, 303, 277, 1, 0, 0, 0, 303, 283, 1, 0, 0, 0, 303, 285, 1, 0, 0, 0, 303, 300, 1, 0, 0, 0, 303, 301, 1, 0, 0, 0, 303, 302, 1, 0, 0, 0, 304, 354, 1, 0, 0, 0, 305, 306, 10, 13, 0, 0, 306, 307, 7, 4, 0, 0, 307, 353, 3, 48, 24, 14, 308, 309, 10, 12, 0, 0, 309, 310, 7, 5, 0, 0, 310, 353, 3, 48, 24, 13, 311, 312, 10, 11, 0, 0, 312, 313, 7, 6, 0, 0, 313, 353, 3, 48, 24, 12, 314, 315, 10, 10, 0, 0, 315, 316, 7, 7, 0, 0, 316, 353, 3, 48, 24, 11, 317, 318, 10, 9, 0, 0, 318, 319, 5, 48, 0, 0, 319, 353, 3, 48, 24, 10, 320, 321, 10, 8, 0, 0, 321, 322, 5, 4, 0, 0, 322, 353, 3, 48, 24, 9, 323, 324, 10, 7, 0, 0, 324, 325, 5, 49, 0, 0, 325, 353, 3, 48, 24, 8, 326, 327, 10, 6, 0, 0, 327, 328, 5, 50, 0, 0, 328, 353, 3, 48, 24, 7, 329, 330, 10, 5, 0, 0, 330, 331, 5, 51, 0, 0, 331, 353, 3, 48, 24, 6, 332, 333, 10, 20, 0, 0, 333, 334, 5, 23, 0, 0, 334, 335, 5, 62, 0, 0, 335, 353, 5, 24, 0, 0, 336, 337, 10, 17, 0, 0, 337, 353, 7, 8, 0, 0, 338, 339, 10, 16, 0, 0, 339, 340, 5, 38, 0, 0, 340, 341, 5, 15, 0, 0, 341, 342, 3, 48, 24, 0, 342, 343, 5, 17, 0, 0, 343, 353, 1, 0, 0, 0, 344, 345, 10, 15, 0, 0, 345, 346, 5, 39, 0, 0, 346, 347, 5, 15, 0, 0, 347, 348, 3, 48, 24, 0, 348, 349, 5, 16, 0, 0, 349, 350, 3, 48, 24, 0, 350, 351, 5, 17, 0, 0, 351, 353, 1, 0, 0, 0, 352, 305, 1, 0, 0, 0, 352, 308, 1, 0, 0, 0, 352, 311, 1, 0, 0, 0, 352, 314, 1, 0, 0, 0, 352, 317, 1, 0, 0, 0, 352, 320, 1, 0, 0, 0, 352, 323, 1, 0, 0, 0, 352, 326, 1, 0, 0, 0, 352, 329, 1, 0, 0, 0, 352, 332, 1, 0, 0, 0, 352, 336, 1, 0, 0, 0, 352, 338, 1, 0, 0, 0, 352, 344, 1, 0, 0, 0, 353, 356, 1, 0, 0, 0, 354, 352, 1, 0, 0, 0, 354, 355, 1, 0, 0, 0, 355, 49, 1, 0, 0, 0, 356, 354, 1, 0, 0, 0, 357, 358, 5, 52, 0, 0, 358, 51, 1, 0, 0, 0, 359, 365, 5, 60, 0, 0, 360, 365, 3, 54, 27, 0, 361, 365, 5, 67, 0, 0, 362, 365, 5, 68, 0, 0, 363, 365, 5, 69, 0, 0, 364, 359, 1, 0, 0, 0, 364, 360, 1, 0, 0, 0, 364, 361, 1, 0, 0, 0, 364, 362, 1, 0, 0, 0, 364, 363, 1, 0, 0, 0, 365, 53, 1, 0, 0, 0, 366, 368, 5, 62, 0, 0, 367, 369, 5, 61, 0, 0, 368, 367, 1, 0, 0, 0, 368, 369, 1, 0, 0, 0, 369, 55, 1, 0, 0, 0, 370, 371, 7, 9, 0, 0, 371, 57, 1, 0, 0, 0, 32, 61, 76, 79, 92, 104, 115, 119, 121, 132, 137, 146, 152, 181, 191, 203, 213, 221, 225, 227, 240, 244, 246, 260, 263, 291, 295, 297, 303, 352, 354, 364, 368] \ No newline at end of file +[4, 1, 77, 388, 2, 0, 7, 0, 2, 1, 7, 1, 2, 2, 7, 2, 2, 3, 7, 3, 2, 4, 7, 4, 2, 5, 7, 5, 2, 6, 7, 6, 2, 7, 7, 7, 2, 8, 7, 8, 2, 9, 7, 9, 2, 10, 7, 10, 2, 11, 7, 11, 2, 12, 7, 12, 2, 13, 7, 13, 2, 14, 7, 14, 2, 15, 7, 15, 2, 16, 7, 16, 2, 17, 7, 17, 2, 18, 7, 18, 2, 19, 7, 19, 2, 20, 7, 20, 2, 21, 7, 21, 2, 22, 7, 22, 2, 23, 7, 23, 2, 24, 7, 24, 2, 25, 7, 25, 2, 26, 7, 26, 2, 27, 7, 27, 2, 28, 7, 28, 2, 29, 7, 29, 2, 30, 7, 30, 1, 0, 5, 0, 64, 8, 0, 10, 0, 12, 0, 67, 9, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1, 3, 1, 3, 3, 3, 81, 8, 3, 1, 4, 3, 4, 84, 8, 4, 1, 4, 1, 4, 1, 5, 1, 5, 1, 6, 1, 6, 1, 6, 1, 6, 1, 6, 5, 6, 95, 8, 6, 10, 6, 12, 6, 98, 9, 6, 1, 6, 1, 6, 1, 7, 1, 7, 1, 7, 1, 7, 1, 7, 5, 7, 107, 8, 7, 10, 7, 12, 7, 110, 9, 7, 1, 7, 1, 7, 1, 8, 1, 8, 1, 8, 1, 8, 5, 8, 118, 8, 8, 10, 8, 12, 8, 121, 9, 8, 1, 8, 3, 8, 124, 8, 8, 3, 8, 126, 8, 8, 1, 8, 1, 8, 1, 9, 1, 9, 1, 9, 1, 10, 1, 10, 5, 10, 135, 8, 10, 10, 10, 12, 10, 138, 9, 10, 1, 10, 1, 10, 3, 10, 142, 8, 10, 1, 11, 1, 11, 1, 11, 1, 11, 1, 11, 1, 11, 1, 11, 1, 11, 3, 11, 152, 8, 11, 1, 12, 1, 12, 5, 12, 156, 8, 12, 10, 12, 12, 12, 159, 9, 12, 1, 12, 1, 12, 1, 12, 1, 12, 1, 12, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 14, 1, 14, 1, 14, 1, 14, 1, 14, 1, 15, 1, 15, 1, 15, 1, 15, 1, 15, 1, 15, 1, 15, 3, 15, 187, 8, 15, 1, 15, 1, 15, 1, 15, 1, 16, 1, 16, 1, 16, 1, 16, 1, 16, 3, 16, 197, 8, 16, 1, 16, 1, 16, 1, 16, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 3, 17, 209, 8, 17, 1, 18, 1, 18, 1, 19, 1, 19, 1, 19, 1, 19, 1, 19, 1, 19, 1, 19, 1, 19, 1, 20, 1, 20, 1, 20, 1, 20, 1, 21, 1, 21, 1, 22, 1, 22, 3, 22, 229, 8, 22, 1, 23, 1, 23, 1, 23, 1, 23, 5, 23, 235, 8, 23, 10, 23, 12, 23, 238, 9, 23, 1, 23, 3, 23, 241, 8, 23, 3, 23, 243, 8, 23, 1, 23, 1, 23, 1, 24, 1, 24, 1, 24, 1, 25, 1, 25, 1, 25, 1, 25, 5, 25, 254, 8, 25, 10, 25, 12, 25, 257, 9, 25, 1, 25, 3, 25, 260, 8, 25, 3, 25, 262, 8, 25, 1, 25, 1, 25, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 3, 26, 276, 8, 26, 1, 26, 3, 26, 279, 8, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 5, 26, 305, 8, 26, 10, 26, 12, 26, 308, 9, 26, 1, 26, 3, 26, 311, 8, 26, 3, 26, 313, 8, 26, 1, 26, 1, 26, 1, 26, 1, 26, 3, 26, 319, 8, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 5, 26, 368, 8, 26, 10, 26, 12, 26, 371, 9, 26, 1, 27, 1, 27, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 3, 28, 380, 8, 28, 1, 29, 1, 29, 3, 29, 384, 8, 29, 1, 30, 1, 30, 1, 30, 0, 1, 52, 31, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 58, 60, 0, 10, 1, 0, 4, 10, 1, 0, 28, 32, 2, 0, 28, 32, 34, 37, 1, 0, 42, 43, 1, 0, 44, 46, 2, 0, 43, 43, 47, 47, 1, 0, 6, 9, 1, 0, 48, 49, 1, 0, 38, 39, 2, 0, 55, 60, 67, 67, 417, 0, 65, 1, 0, 0, 0, 2, 71, 1, 0, 0, 0, 4, 76, 1, 0, 0, 0, 6, 78, 1, 0, 0, 0, 8, 83, 1, 0, 0, 0, 10, 87, 1, 0, 0, 0, 12, 89, 1, 0, 0, 0, 14, 101, 1, 0, 0, 0, 16, 113, 1, 0, 0, 0, 18, 129, 1, 0, 0, 0, 20, 141, 1, 0, 0, 0, 22, 151, 1, 0, 0, 0, 24, 153, 1, 0, 0, 0, 26, 165, 1, 0, 0, 0, 28, 174, 1, 0, 0, 0, 30, 179, 1, 0, 0, 0, 32, 191, 1, 0, 0, 0, 34, 201, 1, 0, 0, 0, 36, 210, 1, 0, 0, 0, 38, 212, 1, 0, 0, 0, 40, 220, 1, 0, 0, 0, 42, 224, 1, 0, 0, 0, 44, 228, 1, 0, 0, 0, 46, 230, 1, 0, 0, 0, 48, 246, 1, 0, 0, 0, 50, 249, 1, 0, 0, 0, 52, 318, 1, 0, 0, 0, 54, 372, 1, 0, 0, 0, 56, 379, 1, 0, 0, 0, 58, 381, 1, 0, 0, 0, 60, 385, 1, 0, 0, 0, 62, 64, 3, 2, 1, 0, 63, 62, 1, 0, 0, 0, 64, 67, 1, 0, 0, 0, 65, 63, 1, 0, 0, 0, 65, 66, 1, 0, 0, 0, 66, 68, 1, 0, 0, 0, 67, 65, 1, 0, 0, 0, 68, 69, 3, 12, 6, 0, 69, 70, 5, 0, 0, 1, 70, 1, 1, 0, 0, 0, 71, 72, 5, 1, 0, 0, 72, 73, 3, 4, 2, 0, 73, 74, 3, 6, 3, 0, 74, 75, 5, 2, 0, 0, 75, 3, 1, 0, 0, 0, 76, 77, 5, 3, 0, 0, 77, 5, 1, 0, 0, 0, 78, 80, 3, 8, 4, 0, 79, 81, 3, 8, 4, 0, 80, 79, 1, 0, 0, 0, 80, 81, 1, 0, 0, 0, 81, 7, 1, 0, 0, 0, 82, 84, 3, 10, 5, 0, 83, 82, 1, 0, 0, 0, 83, 84, 1, 0, 0, 0, 84, 85, 1, 0, 0, 0, 85, 86, 5, 61, 0, 0, 86, 9, 1, 0, 0, 0, 87, 88, 7, 0, 0, 0, 88, 11, 1, 0, 0, 0, 89, 90, 5, 11, 0, 0, 90, 91, 5, 74, 0, 0, 91, 92, 3, 16, 8, 0, 92, 96, 5, 12, 0, 0, 93, 95, 3, 14, 7, 0, 94, 93, 1, 0, 0, 0, 95, 98, 1, 0, 0, 0, 96, 94, 1, 0, 0, 0, 96, 97, 1, 0, 0, 0, 97, 99, 1, 0, 0, 0, 98, 96, 1, 0, 0, 0, 99, 100, 5, 13, 0, 0, 100, 13, 1, 0, 0, 0, 101, 102, 5, 14, 0, 0, 102, 103, 5, 74, 0, 0, 103, 104, 3, 16, 8, 0, 104, 108, 5, 12, 0, 0, 105, 107, 3, 22, 11, 0, 106, 105, 1, 0, 0, 0, 107, 110, 1, 0, 0, 0, 108, 106, 1, 0, 0, 0, 108, 109, 1, 0, 0, 0, 109, 111, 1, 0, 0, 0, 110, 108, 1, 0, 0, 0, 111, 112, 5, 13, 0, 0, 112, 15, 1, 0, 0, 0, 113, 125, 5, 15, 0, 0, 114, 119, 3, 18, 9, 0, 115, 116, 5, 16, 0, 0, 116, 118, 3, 18, 9, 0, 117, 115, 1, 0, 0, 0, 118, 121, 1, 0, 0, 0, 119, 117, 1, 0, 0, 0, 119, 120, 1, 0, 0, 0, 120, 123, 1, 0, 0, 0, 121, 119, 1, 0, 0, 0, 122, 124, 5, 16, 0, 0, 123, 122, 1, 0, 0, 0, 123, 124, 1, 0, 0, 0, 124, 126, 1, 0, 0, 0, 125, 114, 1, 0, 0, 0, 125, 126, 1, 0, 0, 0, 126, 127, 1, 0, 0, 0, 127, 128, 5, 17, 0, 0, 128, 17, 1, 0, 0, 0, 129, 130, 3, 60, 30, 0, 130, 131, 5, 74, 0, 0, 131, 19, 1, 0, 0, 0, 132, 136, 5, 12, 0, 0, 133, 135, 3, 22, 11, 0, 134, 133, 1, 0, 0, 0, 135, 138, 1, 0, 0, 0, 136, 134, 1, 0, 0, 0, 136, 137, 1, 0, 0, 0, 137, 139, 1, 0, 0, 0, 138, 136, 1, 0, 0, 0, 139, 142, 5, 13, 0, 0, 140, 142, 3, 22, 11, 0, 141, 132, 1, 0, 0, 0, 141, 140, 1, 0, 0, 0, 142, 21, 1, 0, 0, 0, 143, 152, 3, 24, 12, 0, 144, 152, 3, 26, 13, 0, 145, 152, 3, 28, 14, 0, 146, 152, 3, 30, 15, 0, 147, 152, 3, 32, 16, 0, 148, 152, 3, 34, 17, 0, 149, 152, 3, 36, 18, 0, 150, 152, 3, 40, 20, 0, 151, 143, 1, 0, 0, 0, 151, 144, 1, 0, 0, 0, 151, 145, 1, 0, 0, 0, 151, 146, 1, 0, 0, 0, 151, 147, 1, 0, 0, 0, 151, 148, 1, 0, 0, 0, 151, 149, 1, 0, 0, 0, 151, 150, 1, 0, 0, 0, 152, 23, 1, 0, 0, 0, 153, 157, 3, 60, 30, 0, 154, 156, 3, 54, 27, 0, 155, 154, 1, 0, 0, 0, 156, 159, 1, 0, 0, 0, 157, 155, 1, 0, 0, 0, 157, 158, 1, 0, 0, 0, 158, 160, 1, 0, 0, 0, 159, 157, 1, 0, 0, 0, 160, 161, 5, 74, 0, 0, 161, 162, 5, 10, 0, 0, 162, 163, 3, 52, 26, 0, 163, 164, 5, 2, 0, 0, 164, 25, 1, 0, 0, 0, 165, 166, 3, 60, 30, 0, 166, 167, 5, 74, 0, 0, 167, 168, 5, 16, 0, 0, 168, 169, 3, 60, 30, 0, 169, 170, 5, 74, 0, 0, 170, 171, 5, 10, 0, 0, 171, 172, 3, 52, 26, 0, 172, 173, 5, 2, 0, 0, 173, 27, 1, 0, 0, 0, 174, 175, 5, 74, 0, 0, 175, 176, 5, 10, 0, 0, 176, 177, 3, 52, 26, 0, 177, 178, 5, 2, 0, 0, 178, 29, 1, 0, 0, 0, 179, 180, 5, 18, 0, 0, 180, 181, 5, 15, 0, 0, 181, 182, 5, 72, 0, 0, 182, 183, 5, 6, 0, 0, 183, 186, 3, 52, 26, 0, 184, 185, 5, 16, 0, 0, 185, 187, 3, 42, 21, 0, 186, 184, 1, 0, 0, 0, 186, 187, 1, 0, 0, 0, 187, 188, 1, 0, 0, 0, 188, 189, 5, 17, 0, 0, 189, 190, 5, 2, 0, 0, 190, 31, 1, 0, 0, 0, 191, 192, 5, 18, 0, 0, 192, 193, 5, 15, 0, 0, 193, 196, 3, 52, 26, 0, 194, 195, 5, 16, 0, 0, 195, 197, 3, 42, 21, 0, 196, 194, 1, 0, 0, 0, 196, 197, 1, 0, 0, 0, 197, 198, 1, 0, 0, 0, 198, 199, 5, 17, 0, 0, 199, 200, 5, 2, 0, 0, 200, 33, 1, 0, 0, 0, 201, 202, 5, 19, 0, 0, 202, 203, 5, 15, 0, 0, 203, 204, 3, 52, 26, 0, 204, 205, 5, 17, 0, 0, 205, 208, 3, 20, 10, 0, 206, 207, 5, 20, 0, 0, 207, 209, 3, 20, 10, 0, 208, 206, 1, 0, 0, 0, 208, 209, 1, 0, 0, 0, 209, 35, 1, 0, 0, 0, 210, 211, 3, 38, 19, 0, 211, 37, 1, 0, 0, 0, 212, 213, 5, 21, 0, 0, 213, 214, 3, 20, 10, 0, 214, 215, 5, 22, 0, 0, 215, 216, 5, 15, 0, 0, 216, 217, 3, 52, 26, 0, 217, 218, 5, 17, 0, 0, 218, 219, 5, 2, 0, 0, 219, 39, 1, 0, 0, 0, 220, 221, 5, 23, 0, 0, 221, 222, 3, 46, 23, 0, 222, 223, 5, 2, 0, 0, 223, 41, 1, 0, 0, 0, 224, 225, 5, 69, 0, 0, 225, 43, 1, 0, 0, 0, 226, 229, 5, 74, 0, 0, 227, 229, 3, 56, 28, 0, 228, 226, 1, 0, 0, 0, 228, 227, 1, 0, 0, 0, 229, 45, 1, 0, 0, 0, 230, 242, 5, 15, 0, 0, 231, 236, 3, 44, 22, 0, 232, 233, 5, 16, 0, 0, 233, 235, 3, 44, 22, 0, 234, 232, 1, 0, 0, 0, 235, 238, 1, 0, 0, 0, 236, 234, 1, 0, 0, 0, 236, 237, 1, 0, 0, 0, 237, 240, 1, 0, 0, 0, 238, 236, 1, 0, 0, 0, 239, 241, 5, 16, 0, 0, 240, 239, 1, 0, 0, 0, 240, 241, 1, 0, 0, 0, 241, 243, 1, 0, 0, 0, 242, 231, 1, 0, 0, 0, 242, 243, 1, 0, 0, 0, 243, 244, 1, 0, 0, 0, 244, 245, 5, 17, 0, 0, 245, 47, 1, 0, 0, 0, 246, 247, 5, 74, 0, 0, 247, 248, 3, 50, 25, 0, 248, 49, 1, 0, 0, 0, 249, 261, 5, 15, 0, 0, 250, 255, 3, 52, 26, 0, 251, 252, 5, 16, 0, 0, 252, 254, 3, 52, 26, 0, 253, 251, 1, 0, 0, 0, 254, 257, 1, 0, 0, 0, 255, 253, 1, 0, 0, 0, 255, 256, 1, 0, 0, 0, 256, 259, 1, 0, 0, 0, 257, 255, 1, 0, 0, 0, 258, 260, 5, 16, 0, 0, 259, 258, 1, 0, 0, 0, 259, 260, 1, 0, 0, 0, 260, 262, 1, 0, 0, 0, 261, 250, 1, 0, 0, 0, 261, 262, 1, 0, 0, 0, 262, 263, 1, 0, 0, 0, 263, 264, 5, 17, 0, 0, 264, 51, 1, 0, 0, 0, 265, 266, 6, 26, -1, 0, 266, 267, 5, 15, 0, 0, 267, 268, 3, 52, 26, 0, 268, 269, 5, 17, 0, 0, 269, 319, 1, 0, 0, 0, 270, 271, 3, 60, 30, 0, 271, 272, 5, 15, 0, 0, 272, 275, 3, 52, 26, 0, 273, 274, 5, 16, 0, 0, 274, 276, 3, 52, 26, 0, 275, 273, 1, 0, 0, 0, 275, 276, 1, 0, 0, 0, 276, 278, 1, 0, 0, 0, 277, 279, 5, 16, 0, 0, 278, 277, 1, 0, 0, 0, 278, 279, 1, 0, 0, 0, 279, 280, 1, 0, 0, 0, 280, 281, 5, 17, 0, 0, 281, 319, 1, 0, 0, 0, 282, 319, 3, 48, 24, 0, 283, 284, 5, 24, 0, 0, 284, 285, 5, 74, 0, 0, 285, 319, 3, 50, 25, 0, 286, 287, 5, 27, 0, 0, 287, 288, 5, 25, 0, 0, 288, 289, 3, 52, 26, 0, 289, 290, 5, 26, 0, 0, 290, 291, 7, 1, 0, 0, 291, 319, 1, 0, 0, 0, 292, 293, 5, 33, 0, 0, 293, 294, 5, 25, 0, 0, 294, 295, 3, 52, 26, 0, 295, 296, 5, 26, 0, 0, 296, 297, 7, 2, 0, 0, 297, 319, 1, 0, 0, 0, 298, 299, 7, 3, 0, 0, 299, 319, 3, 52, 26, 14, 300, 312, 5, 25, 0, 0, 301, 306, 3, 52, 26, 0, 302, 303, 5, 16, 0, 0, 303, 305, 3, 52, 26, 0, 304, 302, 1, 0, 0, 0, 305, 308, 1, 0, 0, 0, 306, 304, 1, 0, 0, 0, 306, 307, 1, 0, 0, 0, 307, 310, 1, 0, 0, 0, 308, 306, 1, 0, 0, 0, 309, 311, 5, 16, 0, 0, 310, 309, 1, 0, 0, 0, 310, 311, 1, 0, 0, 0, 311, 313, 1, 0, 0, 0, 312, 301, 1, 0, 0, 0, 312, 313, 1, 0, 0, 0, 313, 314, 1, 0, 0, 0, 314, 319, 5, 26, 0, 0, 315, 319, 5, 73, 0, 0, 316, 319, 5, 74, 0, 0, 317, 319, 3, 56, 28, 0, 318, 265, 1, 0, 0, 0, 318, 270, 1, 0, 0, 0, 318, 282, 1, 0, 0, 0, 318, 283, 1, 0, 0, 0, 318, 286, 1, 0, 0, 0, 318, 292, 1, 0, 0, 0, 318, 298, 1, 0, 0, 0, 318, 300, 1, 0, 0, 0, 318, 315, 1, 0, 0, 0, 318, 316, 1, 0, 0, 0, 318, 317, 1, 0, 0, 0, 319, 369, 1, 0, 0, 0, 320, 321, 10, 13, 0, 0, 321, 322, 7, 4, 0, 0, 322, 368, 3, 52, 26, 14, 323, 324, 10, 12, 0, 0, 324, 325, 7, 5, 0, 0, 325, 368, 3, 52, 26, 13, 326, 327, 10, 11, 0, 0, 327, 328, 7, 6, 0, 0, 328, 368, 3, 52, 26, 12, 329, 330, 10, 10, 0, 0, 330, 331, 7, 7, 0, 0, 331, 368, 3, 52, 26, 11, 332, 333, 10, 9, 0, 0, 333, 334, 5, 50, 0, 0, 334, 368, 3, 52, 26, 10, 335, 336, 10, 8, 0, 0, 336, 337, 5, 4, 0, 0, 337, 368, 3, 52, 26, 9, 338, 339, 10, 7, 0, 0, 339, 340, 5, 51, 0, 0, 340, 368, 3, 52, 26, 8, 341, 342, 10, 6, 0, 0, 342, 343, 5, 52, 0, 0, 343, 368, 3, 52, 26, 7, 344, 345, 10, 5, 0, 0, 345, 346, 5, 53, 0, 0, 346, 368, 3, 52, 26, 6, 347, 348, 10, 20, 0, 0, 348, 349, 5, 25, 0, 0, 349, 350, 5, 64, 0, 0, 350, 368, 5, 26, 0, 0, 351, 352, 10, 17, 0, 0, 352, 368, 7, 8, 0, 0, 353, 354, 10, 16, 0, 0, 354, 355, 5, 40, 0, 0, 355, 356, 5, 15, 0, 0, 356, 357, 3, 52, 26, 0, 357, 358, 5, 17, 0, 0, 358, 368, 1, 0, 0, 0, 359, 360, 10, 15, 0, 0, 360, 361, 5, 41, 0, 0, 361, 362, 5, 15, 0, 0, 362, 363, 3, 52, 26, 0, 363, 364, 5, 16, 0, 0, 364, 365, 3, 52, 26, 0, 365, 366, 5, 17, 0, 0, 366, 368, 1, 0, 0, 0, 367, 320, 1, 0, 0, 0, 367, 323, 1, 0, 0, 0, 367, 326, 1, 0, 0, 0, 367, 329, 1, 0, 0, 0, 367, 332, 1, 0, 0, 0, 367, 335, 1, 0, 0, 0, 367, 338, 1, 0, 0, 0, 367, 341, 1, 0, 0, 0, 367, 344, 1, 0, 0, 0, 367, 347, 1, 0, 0, 0, 367, 351, 1, 0, 0, 0, 367, 353, 1, 0, 0, 0, 367, 359, 1, 0, 0, 0, 368, 371, 1, 0, 0, 0, 369, 367, 1, 0, 0, 0, 369, 370, 1, 0, 0, 0, 370, 53, 1, 0, 0, 0, 371, 369, 1, 0, 0, 0, 372, 373, 5, 54, 0, 0, 373, 55, 1, 0, 0, 0, 374, 380, 5, 62, 0, 0, 375, 380, 3, 58, 29, 0, 376, 380, 5, 69, 0, 0, 377, 380, 5, 70, 0, 0, 378, 380, 5, 71, 0, 0, 379, 374, 1, 0, 0, 0, 379, 375, 1, 0, 0, 0, 379, 376, 1, 0, 0, 0, 379, 377, 1, 0, 0, 0, 379, 378, 1, 0, 0, 0, 380, 57, 1, 0, 0, 0, 381, 383, 5, 64, 0, 0, 382, 384, 5, 63, 0, 0, 383, 382, 1, 0, 0, 0, 383, 384, 1, 0, 0, 0, 384, 59, 1, 0, 0, 0, 385, 386, 7, 9, 0, 0, 386, 61, 1, 0, 0, 0, 32, 65, 80, 83, 96, 108, 119, 123, 125, 136, 141, 151, 157, 186, 196, 208, 228, 236, 240, 242, 255, 259, 261, 275, 278, 306, 310, 312, 318, 367, 369, 379, 383] \ No newline at end of file diff --git a/packages/cashc/src/grammar/CashScript.tokens b/packages/cashc/src/grammar/CashScript.tokens index 4e0173da..3a95541f 100644 --- a/packages/cashc/src/grammar/CashScript.tokens +++ b/packages/cashc/src/grammar/CashScript.tokens @@ -56,23 +56,25 @@ T__54=55 T__55=56 T__56=57 T__57=58 -VersionLiteral=59 -BooleanLiteral=60 -NumberUnit=61 -NumberLiteral=62 -NumberPart=63 -ExponentPart=64 -Bytes=65 -Bound=66 -StringLiteral=67 -DateLiteral=68 -HexLiteral=69 -TxVar=70 -NullaryOp=71 -Identifier=72 -WHITESPACE=73 -COMMENT=74 -LINE_COMMENT=75 +T__58=59 +T__59=60 +VersionLiteral=61 +BooleanLiteral=62 +NumberUnit=63 +NumberLiteral=64 +NumberPart=65 +ExponentPart=66 +Bytes=67 +Bound=68 +StringLiteral=69 +DateLiteral=70 +HexLiteral=71 +TxVar=72 +NullaryOp=73 +Identifier=74 +WHITESPACE=75 +COMMENT=76 +LINE_COMMENT=77 'pragma'=1 ';'=2 'cashscript'=3 @@ -93,41 +95,43 @@ LINE_COMMENT=75 'require'=18 'if'=19 'else'=20 -'console.log'=21 -'new'=22 -'['=23 -']'=24 -'tx.outputs'=25 -'.value'=26 -'.lockingBytecode'=27 -'.tokenCategory'=28 -'.nftCommitment'=29 -'.tokenAmount'=30 -'tx.inputs'=31 -'.outpointTransactionHash'=32 -'.outpointIndex'=33 -'.unlockingBytecode'=34 -'.sequenceNumber'=35 -'.reverse()'=36 -'.length'=37 -'.split'=38 -'.slice'=39 -'!'=40 -'-'=41 -'*'=42 -'/'=43 -'%'=44 -'+'=45 -'=='=46 -'!='=47 -'&'=48 -'|'=49 -'&&'=50 -'||'=51 -'constant'=52 -'int'=53 -'bool'=54 -'string'=55 -'pubkey'=56 -'sig'=57 -'datasig'=58 +'do'=21 +'while'=22 +'console.log'=23 +'new'=24 +'['=25 +']'=26 +'tx.outputs'=27 +'.value'=28 +'.lockingBytecode'=29 +'.tokenCategory'=30 +'.nftCommitment'=31 +'.tokenAmount'=32 +'tx.inputs'=33 +'.outpointTransactionHash'=34 +'.outpointIndex'=35 +'.unlockingBytecode'=36 +'.sequenceNumber'=37 +'.reverse()'=38 +'.length'=39 +'.split'=40 +'.slice'=41 +'!'=42 +'-'=43 +'*'=44 +'/'=45 +'%'=46 +'+'=47 +'=='=48 +'!='=49 +'&'=50 +'|'=51 +'&&'=52 +'||'=53 +'constant'=54 +'int'=55 +'bool'=56 +'string'=57 +'pubkey'=58 +'sig'=59 +'datasig'=60 diff --git a/packages/cashc/src/grammar/CashScriptLexer.interp b/packages/cashc/src/grammar/CashScriptLexer.interp index a4c165f2..7ee1f359 100644 --- a/packages/cashc/src/grammar/CashScriptLexer.interp +++ b/packages/cashc/src/grammar/CashScriptLexer.interp @@ -20,6 +20,8 @@ null 'require' 'if' 'else' +'do' +'while' 'console.log' 'new' '[' @@ -136,6 +138,8 @@ null null null null +null +null VersionLiteral BooleanLiteral NumberUnit @@ -213,6 +217,8 @@ T__54 T__55 T__56 T__57 +T__58 +T__59 VersionLiteral BooleanLiteral NumberUnit @@ -239,4 +245,4 @@ mode names: DEFAULT_MODE atn: -[4, 0, 75, 845, 6, -1, 2, 0, 7, 0, 2, 1, 7, 1, 2, 2, 7, 2, 2, 3, 7, 3, 2, 4, 7, 4, 2, 5, 7, 5, 2, 6, 7, 6, 2, 7, 7, 7, 2, 8, 7, 8, 2, 9, 7, 9, 2, 10, 7, 10, 2, 11, 7, 11, 2, 12, 7, 12, 2, 13, 7, 13, 2, 14, 7, 14, 2, 15, 7, 15, 2, 16, 7, 16, 2, 17, 7, 17, 2, 18, 7, 18, 2, 19, 7, 19, 2, 20, 7, 20, 2, 21, 7, 21, 2, 22, 7, 22, 2, 23, 7, 23, 2, 24, 7, 24, 2, 25, 7, 25, 2, 26, 7, 26, 2, 27, 7, 27, 2, 28, 7, 28, 2, 29, 7, 29, 2, 30, 7, 30, 2, 31, 7, 31, 2, 32, 7, 32, 2, 33, 7, 33, 2, 34, 7, 34, 2, 35, 7, 35, 2, 36, 7, 36, 2, 37, 7, 37, 2, 38, 7, 38, 2, 39, 7, 39, 2, 40, 7, 40, 2, 41, 7, 41, 2, 42, 7, 42, 2, 43, 7, 43, 2, 44, 7, 44, 2, 45, 7, 45, 2, 46, 7, 46, 2, 47, 7, 47, 2, 48, 7, 48, 2, 49, 7, 49, 2, 50, 7, 50, 2, 51, 7, 51, 2, 52, 7, 52, 2, 53, 7, 53, 2, 54, 7, 54, 2, 55, 7, 55, 2, 56, 7, 56, 2, 57, 7, 57, 2, 58, 7, 58, 2, 59, 7, 59, 2, 60, 7, 60, 2, 61, 7, 61, 2, 62, 7, 62, 2, 63, 7, 63, 2, 64, 7, 64, 2, 65, 7, 65, 2, 66, 7, 66, 2, 67, 7, 67, 2, 68, 7, 68, 2, 69, 7, 69, 2, 70, 7, 70, 2, 71, 7, 71, 2, 72, 7, 72, 2, 73, 7, 73, 2, 74, 7, 74, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 1, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 3, 1, 3, 1, 4, 1, 4, 1, 5, 1, 5, 1, 5, 1, 6, 1, 6, 1, 7, 1, 7, 1, 8, 1, 8, 1, 8, 1, 9, 1, 9, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 11, 1, 11, 1, 12, 1, 12, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 14, 1, 14, 1, 15, 1, 15, 1, 16, 1, 16, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 18, 1, 18, 1, 18, 1, 19, 1, 19, 1, 19, 1, 19, 1, 19, 1, 20, 1, 20, 1, 20, 1, 20, 1, 20, 1, 20, 1, 20, 1, 20, 1, 20, 1, 20, 1, 20, 1, 20, 1, 21, 1, 21, 1, 21, 1, 21, 1, 22, 1, 22, 1, 23, 1, 23, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 24, 1, 25, 1, 25, 1, 25, 1, 25, 1, 25, 1, 25, 1, 25, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 38, 1, 38, 1, 38, 1, 38, 1, 38, 1, 38, 1, 38, 1, 39, 1, 39, 1, 40, 1, 40, 1, 41, 1, 41, 1, 42, 1, 42, 1, 43, 1, 43, 1, 44, 1, 44, 1, 45, 1, 45, 1, 45, 1, 46, 1, 46, 1, 46, 1, 47, 1, 47, 1, 48, 1, 48, 1, 49, 1, 49, 1, 49, 1, 50, 1, 50, 1, 50, 1, 51, 1, 51, 1, 51, 1, 51, 1, 51, 1, 51, 1, 51, 1, 51, 1, 51, 1, 52, 1, 52, 1, 52, 1, 52, 1, 53, 1, 53, 1, 53, 1, 53, 1, 53, 1, 54, 1, 54, 1, 54, 1, 54, 1, 54, 1, 54, 1, 54, 1, 55, 1, 55, 1, 55, 1, 55, 1, 55, 1, 55, 1, 55, 1, 56, 1, 56, 1, 56, 1, 56, 1, 57, 1, 57, 1, 57, 1, 57, 1, 57, 1, 57, 1, 57, 1, 57, 1, 58, 4, 58, 521, 8, 58, 11, 58, 12, 58, 522, 1, 58, 1, 58, 4, 58, 527, 8, 58, 11, 58, 12, 58, 528, 1, 58, 1, 58, 4, 58, 533, 8, 58, 11, 58, 12, 58, 534, 1, 59, 1, 59, 1, 59, 1, 59, 1, 59, 1, 59, 1, 59, 1, 59, 1, 59, 3, 59, 546, 8, 59, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 1, 60, 3, 60, 605, 8, 60, 1, 61, 3, 61, 608, 8, 61, 1, 61, 1, 61, 3, 61, 612, 8, 61, 1, 62, 4, 62, 615, 8, 62, 11, 62, 12, 62, 616, 1, 62, 1, 62, 4, 62, 621, 8, 62, 11, 62, 12, 62, 622, 5, 62, 625, 8, 62, 10, 62, 12, 62, 628, 9, 62, 1, 63, 1, 63, 1, 63, 1, 64, 1, 64, 1, 64, 1, 64, 1, 64, 1, 64, 1, 64, 3, 64, 640, 8, 64, 1, 64, 1, 64, 1, 64, 1, 64, 3, 64, 646, 8, 64, 1, 65, 1, 65, 5, 65, 650, 8, 65, 10, 65, 12, 65, 653, 9, 65, 1, 66, 1, 66, 1, 66, 1, 66, 5, 66, 659, 8, 66, 10, 66, 12, 66, 662, 9, 66, 1, 66, 1, 66, 1, 66, 1, 66, 1, 66, 5, 66, 669, 8, 66, 10, 66, 12, 66, 672, 9, 66, 1, 66, 3, 66, 675, 8, 66, 1, 67, 1, 67, 1, 67, 1, 67, 1, 67, 1, 67, 1, 67, 1, 67, 1, 67, 1, 68, 1, 68, 1, 68, 5, 68, 689, 8, 68, 10, 68, 12, 68, 692, 9, 68, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 3, 69, 709, 8, 69, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 1, 70, 3, 70, 805, 8, 70, 1, 71, 1, 71, 5, 71, 809, 8, 71, 10, 71, 12, 71, 812, 9, 71, 1, 72, 4, 72, 815, 8, 72, 11, 72, 12, 72, 816, 1, 72, 1, 72, 1, 73, 1, 73, 1, 73, 1, 73, 5, 73, 825, 8, 73, 10, 73, 12, 73, 828, 9, 73, 1, 73, 1, 73, 1, 73, 1, 73, 1, 73, 1, 74, 1, 74, 1, 74, 1, 74, 5, 74, 839, 8, 74, 10, 74, 12, 74, 842, 9, 74, 1, 74, 1, 74, 3, 660, 670, 826, 0, 75, 1, 1, 3, 2, 5, 3, 7, 4, 9, 5, 11, 6, 13, 7, 15, 8, 17, 9, 19, 10, 21, 11, 23, 12, 25, 13, 27, 14, 29, 15, 31, 16, 33, 17, 35, 18, 37, 19, 39, 20, 41, 21, 43, 22, 45, 23, 47, 24, 49, 25, 51, 26, 53, 27, 55, 28, 57, 29, 59, 30, 61, 31, 63, 32, 65, 33, 67, 34, 69, 35, 71, 36, 73, 37, 75, 38, 77, 39, 79, 40, 81, 41, 83, 42, 85, 43, 87, 44, 89, 45, 91, 46, 93, 47, 95, 48, 97, 49, 99, 50, 101, 51, 103, 52, 105, 53, 107, 54, 109, 55, 111, 56, 113, 57, 115, 58, 117, 59, 119, 60, 121, 61, 123, 62, 125, 63, 127, 64, 129, 65, 131, 66, 133, 67, 135, 68, 137, 69, 139, 70, 141, 71, 143, 72, 145, 73, 147, 74, 149, 75, 1, 0, 11, 1, 0, 48, 57, 2, 0, 69, 69, 101, 101, 1, 0, 49, 57, 3, 0, 10, 10, 13, 13, 34, 34, 3, 0, 10, 10, 13, 13, 39, 39, 2, 0, 88, 88, 120, 120, 3, 0, 48, 57, 65, 70, 97, 102, 2, 0, 65, 90, 97, 122, 4, 0, 48, 57, 65, 90, 95, 95, 97, 122, 3, 0, 9, 10, 12, 13, 32, 32, 2, 0, 10, 10, 13, 13, 881, 0, 1, 1, 0, 0, 0, 0, 3, 1, 0, 0, 0, 0, 5, 1, 0, 0, 0, 0, 7, 1, 0, 0, 0, 0, 9, 1, 0, 0, 0, 0, 11, 1, 0, 0, 0, 0, 13, 1, 0, 0, 0, 0, 15, 1, 0, 0, 0, 0, 17, 1, 0, 0, 0, 0, 19, 1, 0, 0, 0, 0, 21, 1, 0, 0, 0, 0, 23, 1, 0, 0, 0, 0, 25, 1, 0, 0, 0, 0, 27, 1, 0, 0, 0, 0, 29, 1, 0, 0, 0, 0, 31, 1, 0, 0, 0, 0, 33, 1, 0, 0, 0, 0, 35, 1, 0, 0, 0, 0, 37, 1, 0, 0, 0, 0, 39, 1, 0, 0, 0, 0, 41, 1, 0, 0, 0, 0, 43, 1, 0, 0, 0, 0, 45, 1, 0, 0, 0, 0, 47, 1, 0, 0, 0, 0, 49, 1, 0, 0, 0, 0, 51, 1, 0, 0, 0, 0, 53, 1, 0, 0, 0, 0, 55, 1, 0, 0, 0, 0, 57, 1, 0, 0, 0, 0, 59, 1, 0, 0, 0, 0, 61, 1, 0, 0, 0, 0, 63, 1, 0, 0, 0, 0, 65, 1, 0, 0, 0, 0, 67, 1, 0, 0, 0, 0, 69, 1, 0, 0, 0, 0, 71, 1, 0, 0, 0, 0, 73, 1, 0, 0, 0, 0, 75, 1, 0, 0, 0, 0, 77, 1, 0, 0, 0, 0, 79, 1, 0, 0, 0, 0, 81, 1, 0, 0, 0, 0, 83, 1, 0, 0, 0, 0, 85, 1, 0, 0, 0, 0, 87, 1, 0, 0, 0, 0, 89, 1, 0, 0, 0, 0, 91, 1, 0, 0, 0, 0, 93, 1, 0, 0, 0, 0, 95, 1, 0, 0, 0, 0, 97, 1, 0, 0, 0, 0, 99, 1, 0, 0, 0, 0, 101, 1, 0, 0, 0, 0, 103, 1, 0, 0, 0, 0, 105, 1, 0, 0, 0, 0, 107, 1, 0, 0, 0, 0, 109, 1, 0, 0, 0, 0, 111, 1, 0, 0, 0, 0, 113, 1, 0, 0, 0, 0, 115, 1, 0, 0, 0, 0, 117, 1, 0, 0, 0, 0, 119, 1, 0, 0, 0, 0, 121, 1, 0, 0, 0, 0, 123, 1, 0, 0, 0, 0, 125, 1, 0, 0, 0, 0, 127, 1, 0, 0, 0, 0, 129, 1, 0, 0, 0, 0, 131, 1, 0, 0, 0, 0, 133, 1, 0, 0, 0, 0, 135, 1, 0, 0, 0, 0, 137, 1, 0, 0, 0, 0, 139, 1, 0, 0, 0, 0, 141, 1, 0, 0, 0, 0, 143, 1, 0, 0, 0, 0, 145, 1, 0, 0, 0, 0, 147, 1, 0, 0, 0, 0, 149, 1, 0, 0, 0, 1, 151, 1, 0, 0, 0, 3, 158, 1, 0, 0, 0, 5, 160, 1, 0, 0, 0, 7, 171, 1, 0, 0, 0, 9, 173, 1, 0, 0, 0, 11, 175, 1, 0, 0, 0, 13, 178, 1, 0, 0, 0, 15, 180, 1, 0, 0, 0, 17, 182, 1, 0, 0, 0, 19, 185, 1, 0, 0, 0, 21, 187, 1, 0, 0, 0, 23, 196, 1, 0, 0, 0, 25, 198, 1, 0, 0, 0, 27, 200, 1, 0, 0, 0, 29, 209, 1, 0, 0, 0, 31, 211, 1, 0, 0, 0, 33, 213, 1, 0, 0, 0, 35, 215, 1, 0, 0, 0, 37, 223, 1, 0, 0, 0, 39, 226, 1, 0, 0, 0, 41, 231, 1, 0, 0, 0, 43, 243, 1, 0, 0, 0, 45, 247, 1, 0, 0, 0, 47, 249, 1, 0, 0, 0, 49, 251, 1, 0, 0, 0, 51, 262, 1, 0, 0, 0, 53, 269, 1, 0, 0, 0, 55, 286, 1, 0, 0, 0, 57, 301, 1, 0, 0, 0, 59, 316, 1, 0, 0, 0, 61, 329, 1, 0, 0, 0, 63, 339, 1, 0, 0, 0, 65, 364, 1, 0, 0, 0, 67, 379, 1, 0, 0, 0, 69, 398, 1, 0, 0, 0, 71, 414, 1, 0, 0, 0, 73, 425, 1, 0, 0, 0, 75, 433, 1, 0, 0, 0, 77, 440, 1, 0, 0, 0, 79, 447, 1, 0, 0, 0, 81, 449, 1, 0, 0, 0, 83, 451, 1, 0, 0, 0, 85, 453, 1, 0, 0, 0, 87, 455, 1, 0, 0, 0, 89, 457, 1, 0, 0, 0, 91, 459, 1, 0, 0, 0, 93, 462, 1, 0, 0, 0, 95, 465, 1, 0, 0, 0, 97, 467, 1, 0, 0, 0, 99, 469, 1, 0, 0, 0, 101, 472, 1, 0, 0, 0, 103, 475, 1, 0, 0, 0, 105, 484, 1, 0, 0, 0, 107, 488, 1, 0, 0, 0, 109, 493, 1, 0, 0, 0, 111, 500, 1, 0, 0, 0, 113, 507, 1, 0, 0, 0, 115, 511, 1, 0, 0, 0, 117, 520, 1, 0, 0, 0, 119, 545, 1, 0, 0, 0, 121, 604, 1, 0, 0, 0, 123, 607, 1, 0, 0, 0, 125, 614, 1, 0, 0, 0, 127, 629, 1, 0, 0, 0, 129, 645, 1, 0, 0, 0, 131, 647, 1, 0, 0, 0, 133, 674, 1, 0, 0, 0, 135, 676, 1, 0, 0, 0, 137, 685, 1, 0, 0, 0, 139, 708, 1, 0, 0, 0, 141, 804, 1, 0, 0, 0, 143, 806, 1, 0, 0, 0, 145, 814, 1, 0, 0, 0, 147, 820, 1, 0, 0, 0, 149, 834, 1, 0, 0, 0, 151, 152, 5, 112, 0, 0, 152, 153, 5, 114, 0, 0, 153, 154, 5, 97, 0, 0, 154, 155, 5, 103, 0, 0, 155, 156, 5, 109, 0, 0, 156, 157, 5, 97, 0, 0, 157, 2, 1, 0, 0, 0, 158, 159, 5, 59, 0, 0, 159, 4, 1, 0, 0, 0, 160, 161, 5, 99, 0, 0, 161, 162, 5, 97, 0, 0, 162, 163, 5, 115, 0, 0, 163, 164, 5, 104, 0, 0, 164, 165, 5, 115, 0, 0, 165, 166, 5, 99, 0, 0, 166, 167, 5, 114, 0, 0, 167, 168, 5, 105, 0, 0, 168, 169, 5, 112, 0, 0, 169, 170, 5, 116, 0, 0, 170, 6, 1, 0, 0, 0, 171, 172, 5, 94, 0, 0, 172, 8, 1, 0, 0, 0, 173, 174, 5, 126, 0, 0, 174, 10, 1, 0, 0, 0, 175, 176, 5, 62, 0, 0, 176, 177, 5, 61, 0, 0, 177, 12, 1, 0, 0, 0, 178, 179, 5, 62, 0, 0, 179, 14, 1, 0, 0, 0, 180, 181, 5, 60, 0, 0, 181, 16, 1, 0, 0, 0, 182, 183, 5, 60, 0, 0, 183, 184, 5, 61, 0, 0, 184, 18, 1, 0, 0, 0, 185, 186, 5, 61, 0, 0, 186, 20, 1, 0, 0, 0, 187, 188, 5, 99, 0, 0, 188, 189, 5, 111, 0, 0, 189, 190, 5, 110, 0, 0, 190, 191, 5, 116, 0, 0, 191, 192, 5, 114, 0, 0, 192, 193, 5, 97, 0, 0, 193, 194, 5, 99, 0, 0, 194, 195, 5, 116, 0, 0, 195, 22, 1, 0, 0, 0, 196, 197, 5, 123, 0, 0, 197, 24, 1, 0, 0, 0, 198, 199, 5, 125, 0, 0, 199, 26, 1, 0, 0, 0, 200, 201, 5, 102, 0, 0, 201, 202, 5, 117, 0, 0, 202, 203, 5, 110, 0, 0, 203, 204, 5, 99, 0, 0, 204, 205, 5, 116, 0, 0, 205, 206, 5, 105, 0, 0, 206, 207, 5, 111, 0, 0, 207, 208, 5, 110, 0, 0, 208, 28, 1, 0, 0, 0, 209, 210, 5, 40, 0, 0, 210, 30, 1, 0, 0, 0, 211, 212, 5, 44, 0, 0, 212, 32, 1, 0, 0, 0, 213, 214, 5, 41, 0, 0, 214, 34, 1, 0, 0, 0, 215, 216, 5, 114, 0, 0, 216, 217, 5, 101, 0, 0, 217, 218, 5, 113, 0, 0, 218, 219, 5, 117, 0, 0, 219, 220, 5, 105, 0, 0, 220, 221, 5, 114, 0, 0, 221, 222, 5, 101, 0, 0, 222, 36, 1, 0, 0, 0, 223, 224, 5, 105, 0, 0, 224, 225, 5, 102, 0, 0, 225, 38, 1, 0, 0, 0, 226, 227, 5, 101, 0, 0, 227, 228, 5, 108, 0, 0, 228, 229, 5, 115, 0, 0, 229, 230, 5, 101, 0, 0, 230, 40, 1, 0, 0, 0, 231, 232, 5, 99, 0, 0, 232, 233, 5, 111, 0, 0, 233, 234, 5, 110, 0, 0, 234, 235, 5, 115, 0, 0, 235, 236, 5, 111, 0, 0, 236, 237, 5, 108, 0, 0, 237, 238, 5, 101, 0, 0, 238, 239, 5, 46, 0, 0, 239, 240, 5, 108, 0, 0, 240, 241, 5, 111, 0, 0, 241, 242, 5, 103, 0, 0, 242, 42, 1, 0, 0, 0, 243, 244, 5, 110, 0, 0, 244, 245, 5, 101, 0, 0, 245, 246, 5, 119, 0, 0, 246, 44, 1, 0, 0, 0, 247, 248, 5, 91, 0, 0, 248, 46, 1, 0, 0, 0, 249, 250, 5, 93, 0, 0, 250, 48, 1, 0, 0, 0, 251, 252, 5, 116, 0, 0, 252, 253, 5, 120, 0, 0, 253, 254, 5, 46, 0, 0, 254, 255, 5, 111, 0, 0, 255, 256, 5, 117, 0, 0, 256, 257, 5, 116, 0, 0, 257, 258, 5, 112, 0, 0, 258, 259, 5, 117, 0, 0, 259, 260, 5, 116, 0, 0, 260, 261, 5, 115, 0, 0, 261, 50, 1, 0, 0, 0, 262, 263, 5, 46, 0, 0, 263, 264, 5, 118, 0, 0, 264, 265, 5, 97, 0, 0, 265, 266, 5, 108, 0, 0, 266, 267, 5, 117, 0, 0, 267, 268, 5, 101, 0, 0, 268, 52, 1, 0, 0, 0, 269, 270, 5, 46, 0, 0, 270, 271, 5, 108, 0, 0, 271, 272, 5, 111, 0, 0, 272, 273, 5, 99, 0, 0, 273, 274, 5, 107, 0, 0, 274, 275, 5, 105, 0, 0, 275, 276, 5, 110, 0, 0, 276, 277, 5, 103, 0, 0, 277, 278, 5, 66, 0, 0, 278, 279, 5, 121, 0, 0, 279, 280, 5, 116, 0, 0, 280, 281, 5, 101, 0, 0, 281, 282, 5, 99, 0, 0, 282, 283, 5, 111, 0, 0, 283, 284, 5, 100, 0, 0, 284, 285, 5, 101, 0, 0, 285, 54, 1, 0, 0, 0, 286, 287, 5, 46, 0, 0, 287, 288, 5, 116, 0, 0, 288, 289, 5, 111, 0, 0, 289, 290, 5, 107, 0, 0, 290, 291, 5, 101, 0, 0, 291, 292, 5, 110, 0, 0, 292, 293, 5, 67, 0, 0, 293, 294, 5, 97, 0, 0, 294, 295, 5, 116, 0, 0, 295, 296, 5, 101, 0, 0, 296, 297, 5, 103, 0, 0, 297, 298, 5, 111, 0, 0, 298, 299, 5, 114, 0, 0, 299, 300, 5, 121, 0, 0, 300, 56, 1, 0, 0, 0, 301, 302, 5, 46, 0, 0, 302, 303, 5, 110, 0, 0, 303, 304, 5, 102, 0, 0, 304, 305, 5, 116, 0, 0, 305, 306, 5, 67, 0, 0, 306, 307, 5, 111, 0, 0, 307, 308, 5, 109, 0, 0, 308, 309, 5, 109, 0, 0, 309, 310, 5, 105, 0, 0, 310, 311, 5, 116, 0, 0, 311, 312, 5, 109, 0, 0, 312, 313, 5, 101, 0, 0, 313, 314, 5, 110, 0, 0, 314, 315, 5, 116, 0, 0, 315, 58, 1, 0, 0, 0, 316, 317, 5, 46, 0, 0, 317, 318, 5, 116, 0, 0, 318, 319, 5, 111, 0, 0, 319, 320, 5, 107, 0, 0, 320, 321, 5, 101, 0, 0, 321, 322, 5, 110, 0, 0, 322, 323, 5, 65, 0, 0, 323, 324, 5, 109, 0, 0, 324, 325, 5, 111, 0, 0, 325, 326, 5, 117, 0, 0, 326, 327, 5, 110, 0, 0, 327, 328, 5, 116, 0, 0, 328, 60, 1, 0, 0, 0, 329, 330, 5, 116, 0, 0, 330, 331, 5, 120, 0, 0, 331, 332, 5, 46, 0, 0, 332, 333, 5, 105, 0, 0, 333, 334, 5, 110, 0, 0, 334, 335, 5, 112, 0, 0, 335, 336, 5, 117, 0, 0, 336, 337, 5, 116, 0, 0, 337, 338, 5, 115, 0, 0, 338, 62, 1, 0, 0, 0, 339, 340, 5, 46, 0, 0, 340, 341, 5, 111, 0, 0, 341, 342, 5, 117, 0, 0, 342, 343, 5, 116, 0, 0, 343, 344, 5, 112, 0, 0, 344, 345, 5, 111, 0, 0, 345, 346, 5, 105, 0, 0, 346, 347, 5, 110, 0, 0, 347, 348, 5, 116, 0, 0, 348, 349, 5, 84, 0, 0, 349, 350, 5, 114, 0, 0, 350, 351, 5, 97, 0, 0, 351, 352, 5, 110, 0, 0, 352, 353, 5, 115, 0, 0, 353, 354, 5, 97, 0, 0, 354, 355, 5, 99, 0, 0, 355, 356, 5, 116, 0, 0, 356, 357, 5, 105, 0, 0, 357, 358, 5, 111, 0, 0, 358, 359, 5, 110, 0, 0, 359, 360, 5, 72, 0, 0, 360, 361, 5, 97, 0, 0, 361, 362, 5, 115, 0, 0, 362, 363, 5, 104, 0, 0, 363, 64, 1, 0, 0, 0, 364, 365, 5, 46, 0, 0, 365, 366, 5, 111, 0, 0, 366, 367, 5, 117, 0, 0, 367, 368, 5, 116, 0, 0, 368, 369, 5, 112, 0, 0, 369, 370, 5, 111, 0, 0, 370, 371, 5, 105, 0, 0, 371, 372, 5, 110, 0, 0, 372, 373, 5, 116, 0, 0, 373, 374, 5, 73, 0, 0, 374, 375, 5, 110, 0, 0, 375, 376, 5, 100, 0, 0, 376, 377, 5, 101, 0, 0, 377, 378, 5, 120, 0, 0, 378, 66, 1, 0, 0, 0, 379, 380, 5, 46, 0, 0, 380, 381, 5, 117, 0, 0, 381, 382, 5, 110, 0, 0, 382, 383, 5, 108, 0, 0, 383, 384, 5, 111, 0, 0, 384, 385, 5, 99, 0, 0, 385, 386, 5, 107, 0, 0, 386, 387, 5, 105, 0, 0, 387, 388, 5, 110, 0, 0, 388, 389, 5, 103, 0, 0, 389, 390, 5, 66, 0, 0, 390, 391, 5, 121, 0, 0, 391, 392, 5, 116, 0, 0, 392, 393, 5, 101, 0, 0, 393, 394, 5, 99, 0, 0, 394, 395, 5, 111, 0, 0, 395, 396, 5, 100, 0, 0, 396, 397, 5, 101, 0, 0, 397, 68, 1, 0, 0, 0, 398, 399, 5, 46, 0, 0, 399, 400, 5, 115, 0, 0, 400, 401, 5, 101, 0, 0, 401, 402, 5, 113, 0, 0, 402, 403, 5, 117, 0, 0, 403, 404, 5, 101, 0, 0, 404, 405, 5, 110, 0, 0, 405, 406, 5, 99, 0, 0, 406, 407, 5, 101, 0, 0, 407, 408, 5, 78, 0, 0, 408, 409, 5, 117, 0, 0, 409, 410, 5, 109, 0, 0, 410, 411, 5, 98, 0, 0, 411, 412, 5, 101, 0, 0, 412, 413, 5, 114, 0, 0, 413, 70, 1, 0, 0, 0, 414, 415, 5, 46, 0, 0, 415, 416, 5, 114, 0, 0, 416, 417, 5, 101, 0, 0, 417, 418, 5, 118, 0, 0, 418, 419, 5, 101, 0, 0, 419, 420, 5, 114, 0, 0, 420, 421, 5, 115, 0, 0, 421, 422, 5, 101, 0, 0, 422, 423, 5, 40, 0, 0, 423, 424, 5, 41, 0, 0, 424, 72, 1, 0, 0, 0, 425, 426, 5, 46, 0, 0, 426, 427, 5, 108, 0, 0, 427, 428, 5, 101, 0, 0, 428, 429, 5, 110, 0, 0, 429, 430, 5, 103, 0, 0, 430, 431, 5, 116, 0, 0, 431, 432, 5, 104, 0, 0, 432, 74, 1, 0, 0, 0, 433, 434, 5, 46, 0, 0, 434, 435, 5, 115, 0, 0, 435, 436, 5, 112, 0, 0, 436, 437, 5, 108, 0, 0, 437, 438, 5, 105, 0, 0, 438, 439, 5, 116, 0, 0, 439, 76, 1, 0, 0, 0, 440, 441, 5, 46, 0, 0, 441, 442, 5, 115, 0, 0, 442, 443, 5, 108, 0, 0, 443, 444, 5, 105, 0, 0, 444, 445, 5, 99, 0, 0, 445, 446, 5, 101, 0, 0, 446, 78, 1, 0, 0, 0, 447, 448, 5, 33, 0, 0, 448, 80, 1, 0, 0, 0, 449, 450, 5, 45, 0, 0, 450, 82, 1, 0, 0, 0, 451, 452, 5, 42, 0, 0, 452, 84, 1, 0, 0, 0, 453, 454, 5, 47, 0, 0, 454, 86, 1, 0, 0, 0, 455, 456, 5, 37, 0, 0, 456, 88, 1, 0, 0, 0, 457, 458, 5, 43, 0, 0, 458, 90, 1, 0, 0, 0, 459, 460, 5, 61, 0, 0, 460, 461, 5, 61, 0, 0, 461, 92, 1, 0, 0, 0, 462, 463, 5, 33, 0, 0, 463, 464, 5, 61, 0, 0, 464, 94, 1, 0, 0, 0, 465, 466, 5, 38, 0, 0, 466, 96, 1, 0, 0, 0, 467, 468, 5, 124, 0, 0, 468, 98, 1, 0, 0, 0, 469, 470, 5, 38, 0, 0, 470, 471, 5, 38, 0, 0, 471, 100, 1, 0, 0, 0, 472, 473, 5, 124, 0, 0, 473, 474, 5, 124, 0, 0, 474, 102, 1, 0, 0, 0, 475, 476, 5, 99, 0, 0, 476, 477, 5, 111, 0, 0, 477, 478, 5, 110, 0, 0, 478, 479, 5, 115, 0, 0, 479, 480, 5, 116, 0, 0, 480, 481, 5, 97, 0, 0, 481, 482, 5, 110, 0, 0, 482, 483, 5, 116, 0, 0, 483, 104, 1, 0, 0, 0, 484, 485, 5, 105, 0, 0, 485, 486, 5, 110, 0, 0, 486, 487, 5, 116, 0, 0, 487, 106, 1, 0, 0, 0, 488, 489, 5, 98, 0, 0, 489, 490, 5, 111, 0, 0, 490, 491, 5, 111, 0, 0, 491, 492, 5, 108, 0, 0, 492, 108, 1, 0, 0, 0, 493, 494, 5, 115, 0, 0, 494, 495, 5, 116, 0, 0, 495, 496, 5, 114, 0, 0, 496, 497, 5, 105, 0, 0, 497, 498, 5, 110, 0, 0, 498, 499, 5, 103, 0, 0, 499, 110, 1, 0, 0, 0, 500, 501, 5, 112, 0, 0, 501, 502, 5, 117, 0, 0, 502, 503, 5, 98, 0, 0, 503, 504, 5, 107, 0, 0, 504, 505, 5, 101, 0, 0, 505, 506, 5, 121, 0, 0, 506, 112, 1, 0, 0, 0, 507, 508, 5, 115, 0, 0, 508, 509, 5, 105, 0, 0, 509, 510, 5, 103, 0, 0, 510, 114, 1, 0, 0, 0, 511, 512, 5, 100, 0, 0, 512, 513, 5, 97, 0, 0, 513, 514, 5, 116, 0, 0, 514, 515, 5, 97, 0, 0, 515, 516, 5, 115, 0, 0, 516, 517, 5, 105, 0, 0, 517, 518, 5, 103, 0, 0, 518, 116, 1, 0, 0, 0, 519, 521, 7, 0, 0, 0, 520, 519, 1, 0, 0, 0, 521, 522, 1, 0, 0, 0, 522, 520, 1, 0, 0, 0, 522, 523, 1, 0, 0, 0, 523, 524, 1, 0, 0, 0, 524, 526, 5, 46, 0, 0, 525, 527, 7, 0, 0, 0, 526, 525, 1, 0, 0, 0, 527, 528, 1, 0, 0, 0, 528, 526, 1, 0, 0, 0, 528, 529, 1, 0, 0, 0, 529, 530, 1, 0, 0, 0, 530, 532, 5, 46, 0, 0, 531, 533, 7, 0, 0, 0, 532, 531, 1, 0, 0, 0, 533, 534, 1, 0, 0, 0, 534, 532, 1, 0, 0, 0, 534, 535, 1, 0, 0, 0, 535, 118, 1, 0, 0, 0, 536, 537, 5, 116, 0, 0, 537, 538, 5, 114, 0, 0, 538, 539, 5, 117, 0, 0, 539, 546, 5, 101, 0, 0, 540, 541, 5, 102, 0, 0, 541, 542, 5, 97, 0, 0, 542, 543, 5, 108, 0, 0, 543, 544, 5, 115, 0, 0, 544, 546, 5, 101, 0, 0, 545, 536, 1, 0, 0, 0, 545, 540, 1, 0, 0, 0, 546, 120, 1, 0, 0, 0, 547, 548, 5, 115, 0, 0, 548, 549, 5, 97, 0, 0, 549, 550, 5, 116, 0, 0, 550, 551, 5, 111, 0, 0, 551, 552, 5, 115, 0, 0, 552, 553, 5, 104, 0, 0, 553, 554, 5, 105, 0, 0, 554, 605, 5, 115, 0, 0, 555, 556, 5, 115, 0, 0, 556, 557, 5, 97, 0, 0, 557, 558, 5, 116, 0, 0, 558, 605, 5, 115, 0, 0, 559, 560, 5, 102, 0, 0, 560, 561, 5, 105, 0, 0, 561, 562, 5, 110, 0, 0, 562, 563, 5, 110, 0, 0, 563, 564, 5, 101, 0, 0, 564, 605, 5, 121, 0, 0, 565, 566, 5, 98, 0, 0, 566, 567, 5, 105, 0, 0, 567, 568, 5, 116, 0, 0, 568, 605, 5, 115, 0, 0, 569, 570, 5, 98, 0, 0, 570, 571, 5, 105, 0, 0, 571, 572, 5, 116, 0, 0, 572, 573, 5, 99, 0, 0, 573, 574, 5, 111, 0, 0, 574, 575, 5, 105, 0, 0, 575, 605, 5, 110, 0, 0, 576, 577, 5, 115, 0, 0, 577, 578, 5, 101, 0, 0, 578, 579, 5, 99, 0, 0, 579, 580, 5, 111, 0, 0, 580, 581, 5, 110, 0, 0, 581, 582, 5, 100, 0, 0, 582, 605, 5, 115, 0, 0, 583, 584, 5, 109, 0, 0, 584, 585, 5, 105, 0, 0, 585, 586, 5, 110, 0, 0, 586, 587, 5, 117, 0, 0, 587, 588, 5, 116, 0, 0, 588, 589, 5, 101, 0, 0, 589, 605, 5, 115, 0, 0, 590, 591, 5, 104, 0, 0, 591, 592, 5, 111, 0, 0, 592, 593, 5, 117, 0, 0, 593, 594, 5, 114, 0, 0, 594, 605, 5, 115, 0, 0, 595, 596, 5, 100, 0, 0, 596, 597, 5, 97, 0, 0, 597, 598, 5, 121, 0, 0, 598, 605, 5, 115, 0, 0, 599, 600, 5, 119, 0, 0, 600, 601, 5, 101, 0, 0, 601, 602, 5, 101, 0, 0, 602, 603, 5, 107, 0, 0, 603, 605, 5, 115, 0, 0, 604, 547, 1, 0, 0, 0, 604, 555, 1, 0, 0, 0, 604, 559, 1, 0, 0, 0, 604, 565, 1, 0, 0, 0, 604, 569, 1, 0, 0, 0, 604, 576, 1, 0, 0, 0, 604, 583, 1, 0, 0, 0, 604, 590, 1, 0, 0, 0, 604, 595, 1, 0, 0, 0, 604, 599, 1, 0, 0, 0, 605, 122, 1, 0, 0, 0, 606, 608, 5, 45, 0, 0, 607, 606, 1, 0, 0, 0, 607, 608, 1, 0, 0, 0, 608, 609, 1, 0, 0, 0, 609, 611, 3, 125, 62, 0, 610, 612, 3, 127, 63, 0, 611, 610, 1, 0, 0, 0, 611, 612, 1, 0, 0, 0, 612, 124, 1, 0, 0, 0, 613, 615, 7, 0, 0, 0, 614, 613, 1, 0, 0, 0, 615, 616, 1, 0, 0, 0, 616, 614, 1, 0, 0, 0, 616, 617, 1, 0, 0, 0, 617, 626, 1, 0, 0, 0, 618, 620, 5, 95, 0, 0, 619, 621, 7, 0, 0, 0, 620, 619, 1, 0, 0, 0, 621, 622, 1, 0, 0, 0, 622, 620, 1, 0, 0, 0, 622, 623, 1, 0, 0, 0, 623, 625, 1, 0, 0, 0, 624, 618, 1, 0, 0, 0, 625, 628, 1, 0, 0, 0, 626, 624, 1, 0, 0, 0, 626, 627, 1, 0, 0, 0, 627, 126, 1, 0, 0, 0, 628, 626, 1, 0, 0, 0, 629, 630, 7, 1, 0, 0, 630, 631, 3, 125, 62, 0, 631, 128, 1, 0, 0, 0, 632, 633, 5, 98, 0, 0, 633, 634, 5, 121, 0, 0, 634, 635, 5, 116, 0, 0, 635, 636, 5, 101, 0, 0, 636, 637, 5, 115, 0, 0, 637, 639, 1, 0, 0, 0, 638, 640, 3, 131, 65, 0, 639, 638, 1, 0, 0, 0, 639, 640, 1, 0, 0, 0, 640, 646, 1, 0, 0, 0, 641, 642, 5, 98, 0, 0, 642, 643, 5, 121, 0, 0, 643, 644, 5, 116, 0, 0, 644, 646, 5, 101, 0, 0, 645, 632, 1, 0, 0, 0, 645, 641, 1, 0, 0, 0, 646, 130, 1, 0, 0, 0, 647, 651, 7, 2, 0, 0, 648, 650, 7, 0, 0, 0, 649, 648, 1, 0, 0, 0, 650, 653, 1, 0, 0, 0, 651, 649, 1, 0, 0, 0, 651, 652, 1, 0, 0, 0, 652, 132, 1, 0, 0, 0, 653, 651, 1, 0, 0, 0, 654, 660, 5, 34, 0, 0, 655, 656, 5, 92, 0, 0, 656, 659, 5, 34, 0, 0, 657, 659, 8, 3, 0, 0, 658, 655, 1, 0, 0, 0, 658, 657, 1, 0, 0, 0, 659, 662, 1, 0, 0, 0, 660, 661, 1, 0, 0, 0, 660, 658, 1, 0, 0, 0, 661, 663, 1, 0, 0, 0, 662, 660, 1, 0, 0, 0, 663, 675, 5, 34, 0, 0, 664, 670, 5, 39, 0, 0, 665, 666, 5, 92, 0, 0, 666, 669, 5, 39, 0, 0, 667, 669, 8, 4, 0, 0, 668, 665, 1, 0, 0, 0, 668, 667, 1, 0, 0, 0, 669, 672, 1, 0, 0, 0, 670, 671, 1, 0, 0, 0, 670, 668, 1, 0, 0, 0, 671, 673, 1, 0, 0, 0, 672, 670, 1, 0, 0, 0, 673, 675, 5, 39, 0, 0, 674, 654, 1, 0, 0, 0, 674, 664, 1, 0, 0, 0, 675, 134, 1, 0, 0, 0, 676, 677, 5, 100, 0, 0, 677, 678, 5, 97, 0, 0, 678, 679, 5, 116, 0, 0, 679, 680, 5, 101, 0, 0, 680, 681, 5, 40, 0, 0, 681, 682, 1, 0, 0, 0, 682, 683, 3, 133, 66, 0, 683, 684, 5, 41, 0, 0, 684, 136, 1, 0, 0, 0, 685, 686, 5, 48, 0, 0, 686, 690, 7, 5, 0, 0, 687, 689, 7, 6, 0, 0, 688, 687, 1, 0, 0, 0, 689, 692, 1, 0, 0, 0, 690, 688, 1, 0, 0, 0, 690, 691, 1, 0, 0, 0, 691, 138, 1, 0, 0, 0, 692, 690, 1, 0, 0, 0, 693, 694, 5, 116, 0, 0, 694, 695, 5, 104, 0, 0, 695, 696, 5, 105, 0, 0, 696, 697, 5, 115, 0, 0, 697, 698, 5, 46, 0, 0, 698, 699, 5, 97, 0, 0, 699, 700, 5, 103, 0, 0, 700, 709, 5, 101, 0, 0, 701, 702, 5, 116, 0, 0, 702, 703, 5, 120, 0, 0, 703, 704, 5, 46, 0, 0, 704, 705, 5, 116, 0, 0, 705, 706, 5, 105, 0, 0, 706, 707, 5, 109, 0, 0, 707, 709, 5, 101, 0, 0, 708, 693, 1, 0, 0, 0, 708, 701, 1, 0, 0, 0, 709, 140, 1, 0, 0, 0, 710, 711, 5, 116, 0, 0, 711, 712, 5, 104, 0, 0, 712, 713, 5, 105, 0, 0, 713, 714, 5, 115, 0, 0, 714, 715, 5, 46, 0, 0, 715, 716, 5, 97, 0, 0, 716, 717, 5, 99, 0, 0, 717, 718, 5, 116, 0, 0, 718, 719, 5, 105, 0, 0, 719, 720, 5, 118, 0, 0, 720, 721, 5, 101, 0, 0, 721, 722, 5, 73, 0, 0, 722, 723, 5, 110, 0, 0, 723, 724, 5, 112, 0, 0, 724, 725, 5, 117, 0, 0, 725, 726, 5, 116, 0, 0, 726, 727, 5, 73, 0, 0, 727, 728, 5, 110, 0, 0, 728, 729, 5, 100, 0, 0, 729, 730, 5, 101, 0, 0, 730, 805, 5, 120, 0, 0, 731, 732, 5, 116, 0, 0, 732, 733, 5, 104, 0, 0, 733, 734, 5, 105, 0, 0, 734, 735, 5, 115, 0, 0, 735, 736, 5, 46, 0, 0, 736, 737, 5, 97, 0, 0, 737, 738, 5, 99, 0, 0, 738, 739, 5, 116, 0, 0, 739, 740, 5, 105, 0, 0, 740, 741, 5, 118, 0, 0, 741, 742, 5, 101, 0, 0, 742, 743, 5, 66, 0, 0, 743, 744, 5, 121, 0, 0, 744, 745, 5, 116, 0, 0, 745, 746, 5, 101, 0, 0, 746, 747, 5, 99, 0, 0, 747, 748, 5, 111, 0, 0, 748, 749, 5, 100, 0, 0, 749, 805, 5, 101, 0, 0, 750, 751, 5, 116, 0, 0, 751, 752, 5, 120, 0, 0, 752, 753, 5, 46, 0, 0, 753, 754, 5, 105, 0, 0, 754, 755, 5, 110, 0, 0, 755, 756, 5, 112, 0, 0, 756, 757, 5, 117, 0, 0, 757, 758, 5, 116, 0, 0, 758, 759, 5, 115, 0, 0, 759, 760, 5, 46, 0, 0, 760, 761, 5, 108, 0, 0, 761, 762, 5, 101, 0, 0, 762, 763, 5, 110, 0, 0, 763, 764, 5, 103, 0, 0, 764, 765, 5, 116, 0, 0, 765, 805, 5, 104, 0, 0, 766, 767, 5, 116, 0, 0, 767, 768, 5, 120, 0, 0, 768, 769, 5, 46, 0, 0, 769, 770, 5, 111, 0, 0, 770, 771, 5, 117, 0, 0, 771, 772, 5, 116, 0, 0, 772, 773, 5, 112, 0, 0, 773, 774, 5, 117, 0, 0, 774, 775, 5, 116, 0, 0, 775, 776, 5, 115, 0, 0, 776, 777, 5, 46, 0, 0, 777, 778, 5, 108, 0, 0, 778, 779, 5, 101, 0, 0, 779, 780, 5, 110, 0, 0, 780, 781, 5, 103, 0, 0, 781, 782, 5, 116, 0, 0, 782, 805, 5, 104, 0, 0, 783, 784, 5, 116, 0, 0, 784, 785, 5, 120, 0, 0, 785, 786, 5, 46, 0, 0, 786, 787, 5, 118, 0, 0, 787, 788, 5, 101, 0, 0, 788, 789, 5, 114, 0, 0, 789, 790, 5, 115, 0, 0, 790, 791, 5, 105, 0, 0, 791, 792, 5, 111, 0, 0, 792, 805, 5, 110, 0, 0, 793, 794, 5, 116, 0, 0, 794, 795, 5, 120, 0, 0, 795, 796, 5, 46, 0, 0, 796, 797, 5, 108, 0, 0, 797, 798, 5, 111, 0, 0, 798, 799, 5, 99, 0, 0, 799, 800, 5, 107, 0, 0, 800, 801, 5, 116, 0, 0, 801, 802, 5, 105, 0, 0, 802, 803, 5, 109, 0, 0, 803, 805, 5, 101, 0, 0, 804, 710, 1, 0, 0, 0, 804, 731, 1, 0, 0, 0, 804, 750, 1, 0, 0, 0, 804, 766, 1, 0, 0, 0, 804, 783, 1, 0, 0, 0, 804, 793, 1, 0, 0, 0, 805, 142, 1, 0, 0, 0, 806, 810, 7, 7, 0, 0, 807, 809, 7, 8, 0, 0, 808, 807, 1, 0, 0, 0, 809, 812, 1, 0, 0, 0, 810, 808, 1, 0, 0, 0, 810, 811, 1, 0, 0, 0, 811, 144, 1, 0, 0, 0, 812, 810, 1, 0, 0, 0, 813, 815, 7, 9, 0, 0, 814, 813, 1, 0, 0, 0, 815, 816, 1, 0, 0, 0, 816, 814, 1, 0, 0, 0, 816, 817, 1, 0, 0, 0, 817, 818, 1, 0, 0, 0, 818, 819, 6, 72, 0, 0, 819, 146, 1, 0, 0, 0, 820, 821, 5, 47, 0, 0, 821, 822, 5, 42, 0, 0, 822, 826, 1, 0, 0, 0, 823, 825, 9, 0, 0, 0, 824, 823, 1, 0, 0, 0, 825, 828, 1, 0, 0, 0, 826, 827, 1, 0, 0, 0, 826, 824, 1, 0, 0, 0, 827, 829, 1, 0, 0, 0, 828, 826, 1, 0, 0, 0, 829, 830, 5, 42, 0, 0, 830, 831, 5, 47, 0, 0, 831, 832, 1, 0, 0, 0, 832, 833, 6, 73, 1, 0, 833, 148, 1, 0, 0, 0, 834, 835, 5, 47, 0, 0, 835, 836, 5, 47, 0, 0, 836, 840, 1, 0, 0, 0, 837, 839, 8, 10, 0, 0, 838, 837, 1, 0, 0, 0, 839, 842, 1, 0, 0, 0, 840, 838, 1, 0, 0, 0, 840, 841, 1, 0, 0, 0, 841, 843, 1, 0, 0, 0, 842, 840, 1, 0, 0, 0, 843, 844, 6, 74, 1, 0, 844, 150, 1, 0, 0, 0, 26, 0, 522, 528, 534, 545, 604, 607, 611, 616, 622, 626, 639, 645, 651, 658, 660, 668, 670, 674, 690, 708, 804, 810, 816, 826, 840, 2, 6, 0, 0, 0, 1, 0] \ No newline at end of file +[4, 0, 77, 858, 6, -1, 2, 0, 7, 0, 2, 1, 7, 1, 2, 2, 7, 2, 2, 3, 7, 3, 2, 4, 7, 4, 2, 5, 7, 5, 2, 6, 7, 6, 2, 7, 7, 7, 2, 8, 7, 8, 2, 9, 7, 9, 2, 10, 7, 10, 2, 11, 7, 11, 2, 12, 7, 12, 2, 13, 7, 13, 2, 14, 7, 14, 2, 15, 7, 15, 2, 16, 7, 16, 2, 17, 7, 17, 2, 18, 7, 18, 2, 19, 7, 19, 2, 20, 7, 20, 2, 21, 7, 21, 2, 22, 7, 22, 2, 23, 7, 23, 2, 24, 7, 24, 2, 25, 7, 25, 2, 26, 7, 26, 2, 27, 7, 27, 2, 28, 7, 28, 2, 29, 7, 29, 2, 30, 7, 30, 2, 31, 7, 31, 2, 32, 7, 32, 2, 33, 7, 33, 2, 34, 7, 34, 2, 35, 7, 35, 2, 36, 7, 36, 2, 37, 7, 37, 2, 38, 7, 38, 2, 39, 7, 39, 2, 40, 7, 40, 2, 41, 7, 41, 2, 42, 7, 42, 2, 43, 7, 43, 2, 44, 7, 44, 2, 45, 7, 45, 2, 46, 7, 46, 2, 47, 7, 47, 2, 48, 7, 48, 2, 49, 7, 49, 2, 50, 7, 50, 2, 51, 7, 51, 2, 52, 7, 52, 2, 53, 7, 53, 2, 54, 7, 54, 2, 55, 7, 55, 2, 56, 7, 56, 2, 57, 7, 57, 2, 58, 7, 58, 2, 59, 7, 59, 2, 60, 7, 60, 2, 61, 7, 61, 2, 62, 7, 62, 2, 63, 7, 63, 2, 64, 7, 64, 2, 65, 7, 65, 2, 66, 7, 66, 2, 67, 7, 67, 2, 68, 7, 68, 2, 69, 7, 69, 2, 70, 7, 70, 2, 71, 7, 71, 2, 72, 7, 72, 2, 73, 7, 73, 2, 74, 7, 74, 2, 75, 7, 75, 2, 76, 7, 76, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 1, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 3, 1, 3, 1, 4, 1, 4, 1, 5, 1, 5, 1, 5, 1, 6, 1, 6, 1, 7, 1, 7, 1, 8, 1, 8, 1, 8, 1, 9, 1, 9, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 10, 1, 11, 1, 11, 1, 12, 1, 12, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 14, 1, 14, 1, 15, 1, 15, 1, 16, 1, 16, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 17, 1, 18, 1, 18, 1, 18, 1, 19, 1, 19, 1, 19, 1, 19, 1, 19, 1, 20, 1, 20, 1, 20, 1, 21, 1, 21, 1, 21, 1, 21, 1, 21, 1, 21, 1, 22, 1, 22, 1, 22, 1, 22, 1, 22, 1, 22, 1, 22, 1, 22, 1, 22, 1, 22, 1, 22, 1, 22, 1, 23, 1, 23, 1, 23, 1, 23, 1, 24, 1, 24, 1, 25, 1, 25, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 26, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 27, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 28, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 29, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 30, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 31, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 32, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 33, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 34, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 35, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 36, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 37, 1, 38, 1, 38, 1, 38, 1, 38, 1, 38, 1, 38, 1, 38, 1, 38, 1, 39, 1, 39, 1, 39, 1, 39, 1, 39, 1, 39, 1, 39, 1, 40, 1, 40, 1, 40, 1, 40, 1, 40, 1, 40, 1, 40, 1, 41, 1, 41, 1, 42, 1, 42, 1, 43, 1, 43, 1, 44, 1, 44, 1, 45, 1, 45, 1, 46, 1, 46, 1, 47, 1, 47, 1, 47, 1, 48, 1, 48, 1, 48, 1, 49, 1, 49, 1, 50, 1, 50, 1, 51, 1, 51, 1, 51, 1, 52, 1, 52, 1, 52, 1, 53, 1, 53, 1, 53, 1, 53, 1, 53, 1, 53, 1, 53, 1, 53, 1, 53, 1, 54, 1, 54, 1, 54, 1, 54, 1, 55, 1, 55, 1, 55, 1, 55, 1, 55, 1, 56, 1, 56, 1, 56, 1, 56, 1, 56, 1, 56, 1, 56, 1, 57, 1, 57, 1, 57, 1, 57, 1, 57, 1, 57, 1, 57, 1, 58, 1, 58, 1, 58, 1, 58, 1, 59, 1, 59, 1, 59, 1, 59, 1, 59, 1, 59, 1, 59, 1, 59, 1, 60, 4, 60, 534, 8, 60, 11, 60, 12, 60, 535, 1, 60, 1, 60, 4, 60, 540, 8, 60, 11, 60, 12, 60, 541, 1, 60, 1, 60, 4, 60, 546, 8, 60, 11, 60, 12, 60, 547, 1, 61, 1, 61, 1, 61, 1, 61, 1, 61, 1, 61, 1, 61, 1, 61, 1, 61, 3, 61, 559, 8, 61, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 1, 62, 3, 62, 618, 8, 62, 1, 63, 3, 63, 621, 8, 63, 1, 63, 1, 63, 3, 63, 625, 8, 63, 1, 64, 4, 64, 628, 8, 64, 11, 64, 12, 64, 629, 1, 64, 1, 64, 4, 64, 634, 8, 64, 11, 64, 12, 64, 635, 5, 64, 638, 8, 64, 10, 64, 12, 64, 641, 9, 64, 1, 65, 1, 65, 1, 65, 1, 66, 1, 66, 1, 66, 1, 66, 1, 66, 1, 66, 1, 66, 3, 66, 653, 8, 66, 1, 66, 1, 66, 1, 66, 1, 66, 3, 66, 659, 8, 66, 1, 67, 1, 67, 5, 67, 663, 8, 67, 10, 67, 12, 67, 666, 9, 67, 1, 68, 1, 68, 1, 68, 1, 68, 5, 68, 672, 8, 68, 10, 68, 12, 68, 675, 9, 68, 1, 68, 1, 68, 1, 68, 1, 68, 1, 68, 5, 68, 682, 8, 68, 10, 68, 12, 68, 685, 9, 68, 1, 68, 3, 68, 688, 8, 68, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 69, 1, 70, 1, 70, 1, 70, 5, 70, 702, 8, 70, 10, 70, 12, 70, 705, 9, 70, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 1, 71, 3, 71, 722, 8, 71, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 1, 72, 3, 72, 818, 8, 72, 1, 73, 1, 73, 5, 73, 822, 8, 73, 10, 73, 12, 73, 825, 9, 73, 1, 74, 4, 74, 828, 8, 74, 11, 74, 12, 74, 829, 1, 74, 1, 74, 1, 75, 1, 75, 1, 75, 1, 75, 5, 75, 838, 8, 75, 10, 75, 12, 75, 841, 9, 75, 1, 75, 1, 75, 1, 75, 1, 75, 1, 75, 1, 76, 1, 76, 1, 76, 1, 76, 5, 76, 852, 8, 76, 10, 76, 12, 76, 855, 9, 76, 1, 76, 1, 76, 3, 673, 683, 839, 0, 77, 1, 1, 3, 2, 5, 3, 7, 4, 9, 5, 11, 6, 13, 7, 15, 8, 17, 9, 19, 10, 21, 11, 23, 12, 25, 13, 27, 14, 29, 15, 31, 16, 33, 17, 35, 18, 37, 19, 39, 20, 41, 21, 43, 22, 45, 23, 47, 24, 49, 25, 51, 26, 53, 27, 55, 28, 57, 29, 59, 30, 61, 31, 63, 32, 65, 33, 67, 34, 69, 35, 71, 36, 73, 37, 75, 38, 77, 39, 79, 40, 81, 41, 83, 42, 85, 43, 87, 44, 89, 45, 91, 46, 93, 47, 95, 48, 97, 49, 99, 50, 101, 51, 103, 52, 105, 53, 107, 54, 109, 55, 111, 56, 113, 57, 115, 58, 117, 59, 119, 60, 121, 61, 123, 62, 125, 63, 127, 64, 129, 65, 131, 66, 133, 67, 135, 68, 137, 69, 139, 70, 141, 71, 143, 72, 145, 73, 147, 74, 149, 75, 151, 76, 153, 77, 1, 0, 11, 1, 0, 48, 57, 2, 0, 69, 69, 101, 101, 1, 0, 49, 57, 3, 0, 10, 10, 13, 13, 34, 34, 3, 0, 10, 10, 13, 13, 39, 39, 2, 0, 88, 88, 120, 120, 3, 0, 48, 57, 65, 70, 97, 102, 2, 0, 65, 90, 97, 122, 4, 0, 48, 57, 65, 90, 95, 95, 97, 122, 3, 0, 9, 10, 12, 13, 32, 32, 2, 0, 10, 10, 13, 13, 894, 0, 1, 1, 0, 0, 0, 0, 3, 1, 0, 0, 0, 0, 5, 1, 0, 0, 0, 0, 7, 1, 0, 0, 0, 0, 9, 1, 0, 0, 0, 0, 11, 1, 0, 0, 0, 0, 13, 1, 0, 0, 0, 0, 15, 1, 0, 0, 0, 0, 17, 1, 0, 0, 0, 0, 19, 1, 0, 0, 0, 0, 21, 1, 0, 0, 0, 0, 23, 1, 0, 0, 0, 0, 25, 1, 0, 0, 0, 0, 27, 1, 0, 0, 0, 0, 29, 1, 0, 0, 0, 0, 31, 1, 0, 0, 0, 0, 33, 1, 0, 0, 0, 0, 35, 1, 0, 0, 0, 0, 37, 1, 0, 0, 0, 0, 39, 1, 0, 0, 0, 0, 41, 1, 0, 0, 0, 0, 43, 1, 0, 0, 0, 0, 45, 1, 0, 0, 0, 0, 47, 1, 0, 0, 0, 0, 49, 1, 0, 0, 0, 0, 51, 1, 0, 0, 0, 0, 53, 1, 0, 0, 0, 0, 55, 1, 0, 0, 0, 0, 57, 1, 0, 0, 0, 0, 59, 1, 0, 0, 0, 0, 61, 1, 0, 0, 0, 0, 63, 1, 0, 0, 0, 0, 65, 1, 0, 0, 0, 0, 67, 1, 0, 0, 0, 0, 69, 1, 0, 0, 0, 0, 71, 1, 0, 0, 0, 0, 73, 1, 0, 0, 0, 0, 75, 1, 0, 0, 0, 0, 77, 1, 0, 0, 0, 0, 79, 1, 0, 0, 0, 0, 81, 1, 0, 0, 0, 0, 83, 1, 0, 0, 0, 0, 85, 1, 0, 0, 0, 0, 87, 1, 0, 0, 0, 0, 89, 1, 0, 0, 0, 0, 91, 1, 0, 0, 0, 0, 93, 1, 0, 0, 0, 0, 95, 1, 0, 0, 0, 0, 97, 1, 0, 0, 0, 0, 99, 1, 0, 0, 0, 0, 101, 1, 0, 0, 0, 0, 103, 1, 0, 0, 0, 0, 105, 1, 0, 0, 0, 0, 107, 1, 0, 0, 0, 0, 109, 1, 0, 0, 0, 0, 111, 1, 0, 0, 0, 0, 113, 1, 0, 0, 0, 0, 115, 1, 0, 0, 0, 0, 117, 1, 0, 0, 0, 0, 119, 1, 0, 0, 0, 0, 121, 1, 0, 0, 0, 0, 123, 1, 0, 0, 0, 0, 125, 1, 0, 0, 0, 0, 127, 1, 0, 0, 0, 0, 129, 1, 0, 0, 0, 0, 131, 1, 0, 0, 0, 0, 133, 1, 0, 0, 0, 0, 135, 1, 0, 0, 0, 0, 137, 1, 0, 0, 0, 0, 139, 1, 0, 0, 0, 0, 141, 1, 0, 0, 0, 0, 143, 1, 0, 0, 0, 0, 145, 1, 0, 0, 0, 0, 147, 1, 0, 0, 0, 0, 149, 1, 0, 0, 0, 0, 151, 1, 0, 0, 0, 0, 153, 1, 0, 0, 0, 1, 155, 1, 0, 0, 0, 3, 162, 1, 0, 0, 0, 5, 164, 1, 0, 0, 0, 7, 175, 1, 0, 0, 0, 9, 177, 1, 0, 0, 0, 11, 179, 1, 0, 0, 0, 13, 182, 1, 0, 0, 0, 15, 184, 1, 0, 0, 0, 17, 186, 1, 0, 0, 0, 19, 189, 1, 0, 0, 0, 21, 191, 1, 0, 0, 0, 23, 200, 1, 0, 0, 0, 25, 202, 1, 0, 0, 0, 27, 204, 1, 0, 0, 0, 29, 213, 1, 0, 0, 0, 31, 215, 1, 0, 0, 0, 33, 217, 1, 0, 0, 0, 35, 219, 1, 0, 0, 0, 37, 227, 1, 0, 0, 0, 39, 230, 1, 0, 0, 0, 41, 235, 1, 0, 0, 0, 43, 238, 1, 0, 0, 0, 45, 244, 1, 0, 0, 0, 47, 256, 1, 0, 0, 0, 49, 260, 1, 0, 0, 0, 51, 262, 1, 0, 0, 0, 53, 264, 1, 0, 0, 0, 55, 275, 1, 0, 0, 0, 57, 282, 1, 0, 0, 0, 59, 299, 1, 0, 0, 0, 61, 314, 1, 0, 0, 0, 63, 329, 1, 0, 0, 0, 65, 342, 1, 0, 0, 0, 67, 352, 1, 0, 0, 0, 69, 377, 1, 0, 0, 0, 71, 392, 1, 0, 0, 0, 73, 411, 1, 0, 0, 0, 75, 427, 1, 0, 0, 0, 77, 438, 1, 0, 0, 0, 79, 446, 1, 0, 0, 0, 81, 453, 1, 0, 0, 0, 83, 460, 1, 0, 0, 0, 85, 462, 1, 0, 0, 0, 87, 464, 1, 0, 0, 0, 89, 466, 1, 0, 0, 0, 91, 468, 1, 0, 0, 0, 93, 470, 1, 0, 0, 0, 95, 472, 1, 0, 0, 0, 97, 475, 1, 0, 0, 0, 99, 478, 1, 0, 0, 0, 101, 480, 1, 0, 0, 0, 103, 482, 1, 0, 0, 0, 105, 485, 1, 0, 0, 0, 107, 488, 1, 0, 0, 0, 109, 497, 1, 0, 0, 0, 111, 501, 1, 0, 0, 0, 113, 506, 1, 0, 0, 0, 115, 513, 1, 0, 0, 0, 117, 520, 1, 0, 0, 0, 119, 524, 1, 0, 0, 0, 121, 533, 1, 0, 0, 0, 123, 558, 1, 0, 0, 0, 125, 617, 1, 0, 0, 0, 127, 620, 1, 0, 0, 0, 129, 627, 1, 0, 0, 0, 131, 642, 1, 0, 0, 0, 133, 658, 1, 0, 0, 0, 135, 660, 1, 0, 0, 0, 137, 687, 1, 0, 0, 0, 139, 689, 1, 0, 0, 0, 141, 698, 1, 0, 0, 0, 143, 721, 1, 0, 0, 0, 145, 817, 1, 0, 0, 0, 147, 819, 1, 0, 0, 0, 149, 827, 1, 0, 0, 0, 151, 833, 1, 0, 0, 0, 153, 847, 1, 0, 0, 0, 155, 156, 5, 112, 0, 0, 156, 157, 5, 114, 0, 0, 157, 158, 5, 97, 0, 0, 158, 159, 5, 103, 0, 0, 159, 160, 5, 109, 0, 0, 160, 161, 5, 97, 0, 0, 161, 2, 1, 0, 0, 0, 162, 163, 5, 59, 0, 0, 163, 4, 1, 0, 0, 0, 164, 165, 5, 99, 0, 0, 165, 166, 5, 97, 0, 0, 166, 167, 5, 115, 0, 0, 167, 168, 5, 104, 0, 0, 168, 169, 5, 115, 0, 0, 169, 170, 5, 99, 0, 0, 170, 171, 5, 114, 0, 0, 171, 172, 5, 105, 0, 0, 172, 173, 5, 112, 0, 0, 173, 174, 5, 116, 0, 0, 174, 6, 1, 0, 0, 0, 175, 176, 5, 94, 0, 0, 176, 8, 1, 0, 0, 0, 177, 178, 5, 126, 0, 0, 178, 10, 1, 0, 0, 0, 179, 180, 5, 62, 0, 0, 180, 181, 5, 61, 0, 0, 181, 12, 1, 0, 0, 0, 182, 183, 5, 62, 0, 0, 183, 14, 1, 0, 0, 0, 184, 185, 5, 60, 0, 0, 185, 16, 1, 0, 0, 0, 186, 187, 5, 60, 0, 0, 187, 188, 5, 61, 0, 0, 188, 18, 1, 0, 0, 0, 189, 190, 5, 61, 0, 0, 190, 20, 1, 0, 0, 0, 191, 192, 5, 99, 0, 0, 192, 193, 5, 111, 0, 0, 193, 194, 5, 110, 0, 0, 194, 195, 5, 116, 0, 0, 195, 196, 5, 114, 0, 0, 196, 197, 5, 97, 0, 0, 197, 198, 5, 99, 0, 0, 198, 199, 5, 116, 0, 0, 199, 22, 1, 0, 0, 0, 200, 201, 5, 123, 0, 0, 201, 24, 1, 0, 0, 0, 202, 203, 5, 125, 0, 0, 203, 26, 1, 0, 0, 0, 204, 205, 5, 102, 0, 0, 205, 206, 5, 117, 0, 0, 206, 207, 5, 110, 0, 0, 207, 208, 5, 99, 0, 0, 208, 209, 5, 116, 0, 0, 209, 210, 5, 105, 0, 0, 210, 211, 5, 111, 0, 0, 211, 212, 5, 110, 0, 0, 212, 28, 1, 0, 0, 0, 213, 214, 5, 40, 0, 0, 214, 30, 1, 0, 0, 0, 215, 216, 5, 44, 0, 0, 216, 32, 1, 0, 0, 0, 217, 218, 5, 41, 0, 0, 218, 34, 1, 0, 0, 0, 219, 220, 5, 114, 0, 0, 220, 221, 5, 101, 0, 0, 221, 222, 5, 113, 0, 0, 222, 223, 5, 117, 0, 0, 223, 224, 5, 105, 0, 0, 224, 225, 5, 114, 0, 0, 225, 226, 5, 101, 0, 0, 226, 36, 1, 0, 0, 0, 227, 228, 5, 105, 0, 0, 228, 229, 5, 102, 0, 0, 229, 38, 1, 0, 0, 0, 230, 231, 5, 101, 0, 0, 231, 232, 5, 108, 0, 0, 232, 233, 5, 115, 0, 0, 233, 234, 5, 101, 0, 0, 234, 40, 1, 0, 0, 0, 235, 236, 5, 100, 0, 0, 236, 237, 5, 111, 0, 0, 237, 42, 1, 0, 0, 0, 238, 239, 5, 119, 0, 0, 239, 240, 5, 104, 0, 0, 240, 241, 5, 105, 0, 0, 241, 242, 5, 108, 0, 0, 242, 243, 5, 101, 0, 0, 243, 44, 1, 0, 0, 0, 244, 245, 5, 99, 0, 0, 245, 246, 5, 111, 0, 0, 246, 247, 5, 110, 0, 0, 247, 248, 5, 115, 0, 0, 248, 249, 5, 111, 0, 0, 249, 250, 5, 108, 0, 0, 250, 251, 5, 101, 0, 0, 251, 252, 5, 46, 0, 0, 252, 253, 5, 108, 0, 0, 253, 254, 5, 111, 0, 0, 254, 255, 5, 103, 0, 0, 255, 46, 1, 0, 0, 0, 256, 257, 5, 110, 0, 0, 257, 258, 5, 101, 0, 0, 258, 259, 5, 119, 0, 0, 259, 48, 1, 0, 0, 0, 260, 261, 5, 91, 0, 0, 261, 50, 1, 0, 0, 0, 262, 263, 5, 93, 0, 0, 263, 52, 1, 0, 0, 0, 264, 265, 5, 116, 0, 0, 265, 266, 5, 120, 0, 0, 266, 267, 5, 46, 0, 0, 267, 268, 5, 111, 0, 0, 268, 269, 5, 117, 0, 0, 269, 270, 5, 116, 0, 0, 270, 271, 5, 112, 0, 0, 271, 272, 5, 117, 0, 0, 272, 273, 5, 116, 0, 0, 273, 274, 5, 115, 0, 0, 274, 54, 1, 0, 0, 0, 275, 276, 5, 46, 0, 0, 276, 277, 5, 118, 0, 0, 277, 278, 5, 97, 0, 0, 278, 279, 5, 108, 0, 0, 279, 280, 5, 117, 0, 0, 280, 281, 5, 101, 0, 0, 281, 56, 1, 0, 0, 0, 282, 283, 5, 46, 0, 0, 283, 284, 5, 108, 0, 0, 284, 285, 5, 111, 0, 0, 285, 286, 5, 99, 0, 0, 286, 287, 5, 107, 0, 0, 287, 288, 5, 105, 0, 0, 288, 289, 5, 110, 0, 0, 289, 290, 5, 103, 0, 0, 290, 291, 5, 66, 0, 0, 291, 292, 5, 121, 0, 0, 292, 293, 5, 116, 0, 0, 293, 294, 5, 101, 0, 0, 294, 295, 5, 99, 0, 0, 295, 296, 5, 111, 0, 0, 296, 297, 5, 100, 0, 0, 297, 298, 5, 101, 0, 0, 298, 58, 1, 0, 0, 0, 299, 300, 5, 46, 0, 0, 300, 301, 5, 116, 0, 0, 301, 302, 5, 111, 0, 0, 302, 303, 5, 107, 0, 0, 303, 304, 5, 101, 0, 0, 304, 305, 5, 110, 0, 0, 305, 306, 5, 67, 0, 0, 306, 307, 5, 97, 0, 0, 307, 308, 5, 116, 0, 0, 308, 309, 5, 101, 0, 0, 309, 310, 5, 103, 0, 0, 310, 311, 5, 111, 0, 0, 311, 312, 5, 114, 0, 0, 312, 313, 5, 121, 0, 0, 313, 60, 1, 0, 0, 0, 314, 315, 5, 46, 0, 0, 315, 316, 5, 110, 0, 0, 316, 317, 5, 102, 0, 0, 317, 318, 5, 116, 0, 0, 318, 319, 5, 67, 0, 0, 319, 320, 5, 111, 0, 0, 320, 321, 5, 109, 0, 0, 321, 322, 5, 109, 0, 0, 322, 323, 5, 105, 0, 0, 323, 324, 5, 116, 0, 0, 324, 325, 5, 109, 0, 0, 325, 326, 5, 101, 0, 0, 326, 327, 5, 110, 0, 0, 327, 328, 5, 116, 0, 0, 328, 62, 1, 0, 0, 0, 329, 330, 5, 46, 0, 0, 330, 331, 5, 116, 0, 0, 331, 332, 5, 111, 0, 0, 332, 333, 5, 107, 0, 0, 333, 334, 5, 101, 0, 0, 334, 335, 5, 110, 0, 0, 335, 336, 5, 65, 0, 0, 336, 337, 5, 109, 0, 0, 337, 338, 5, 111, 0, 0, 338, 339, 5, 117, 0, 0, 339, 340, 5, 110, 0, 0, 340, 341, 5, 116, 0, 0, 341, 64, 1, 0, 0, 0, 342, 343, 5, 116, 0, 0, 343, 344, 5, 120, 0, 0, 344, 345, 5, 46, 0, 0, 345, 346, 5, 105, 0, 0, 346, 347, 5, 110, 0, 0, 347, 348, 5, 112, 0, 0, 348, 349, 5, 117, 0, 0, 349, 350, 5, 116, 0, 0, 350, 351, 5, 115, 0, 0, 351, 66, 1, 0, 0, 0, 352, 353, 5, 46, 0, 0, 353, 354, 5, 111, 0, 0, 354, 355, 5, 117, 0, 0, 355, 356, 5, 116, 0, 0, 356, 357, 5, 112, 0, 0, 357, 358, 5, 111, 0, 0, 358, 359, 5, 105, 0, 0, 359, 360, 5, 110, 0, 0, 360, 361, 5, 116, 0, 0, 361, 362, 5, 84, 0, 0, 362, 363, 5, 114, 0, 0, 363, 364, 5, 97, 0, 0, 364, 365, 5, 110, 0, 0, 365, 366, 5, 115, 0, 0, 366, 367, 5, 97, 0, 0, 367, 368, 5, 99, 0, 0, 368, 369, 5, 116, 0, 0, 369, 370, 5, 105, 0, 0, 370, 371, 5, 111, 0, 0, 371, 372, 5, 110, 0, 0, 372, 373, 5, 72, 0, 0, 373, 374, 5, 97, 0, 0, 374, 375, 5, 115, 0, 0, 375, 376, 5, 104, 0, 0, 376, 68, 1, 0, 0, 0, 377, 378, 5, 46, 0, 0, 378, 379, 5, 111, 0, 0, 379, 380, 5, 117, 0, 0, 380, 381, 5, 116, 0, 0, 381, 382, 5, 112, 0, 0, 382, 383, 5, 111, 0, 0, 383, 384, 5, 105, 0, 0, 384, 385, 5, 110, 0, 0, 385, 386, 5, 116, 0, 0, 386, 387, 5, 73, 0, 0, 387, 388, 5, 110, 0, 0, 388, 389, 5, 100, 0, 0, 389, 390, 5, 101, 0, 0, 390, 391, 5, 120, 0, 0, 391, 70, 1, 0, 0, 0, 392, 393, 5, 46, 0, 0, 393, 394, 5, 117, 0, 0, 394, 395, 5, 110, 0, 0, 395, 396, 5, 108, 0, 0, 396, 397, 5, 111, 0, 0, 397, 398, 5, 99, 0, 0, 398, 399, 5, 107, 0, 0, 399, 400, 5, 105, 0, 0, 400, 401, 5, 110, 0, 0, 401, 402, 5, 103, 0, 0, 402, 403, 5, 66, 0, 0, 403, 404, 5, 121, 0, 0, 404, 405, 5, 116, 0, 0, 405, 406, 5, 101, 0, 0, 406, 407, 5, 99, 0, 0, 407, 408, 5, 111, 0, 0, 408, 409, 5, 100, 0, 0, 409, 410, 5, 101, 0, 0, 410, 72, 1, 0, 0, 0, 411, 412, 5, 46, 0, 0, 412, 413, 5, 115, 0, 0, 413, 414, 5, 101, 0, 0, 414, 415, 5, 113, 0, 0, 415, 416, 5, 117, 0, 0, 416, 417, 5, 101, 0, 0, 417, 418, 5, 110, 0, 0, 418, 419, 5, 99, 0, 0, 419, 420, 5, 101, 0, 0, 420, 421, 5, 78, 0, 0, 421, 422, 5, 117, 0, 0, 422, 423, 5, 109, 0, 0, 423, 424, 5, 98, 0, 0, 424, 425, 5, 101, 0, 0, 425, 426, 5, 114, 0, 0, 426, 74, 1, 0, 0, 0, 427, 428, 5, 46, 0, 0, 428, 429, 5, 114, 0, 0, 429, 430, 5, 101, 0, 0, 430, 431, 5, 118, 0, 0, 431, 432, 5, 101, 0, 0, 432, 433, 5, 114, 0, 0, 433, 434, 5, 115, 0, 0, 434, 435, 5, 101, 0, 0, 435, 436, 5, 40, 0, 0, 436, 437, 5, 41, 0, 0, 437, 76, 1, 0, 0, 0, 438, 439, 5, 46, 0, 0, 439, 440, 5, 108, 0, 0, 440, 441, 5, 101, 0, 0, 441, 442, 5, 110, 0, 0, 442, 443, 5, 103, 0, 0, 443, 444, 5, 116, 0, 0, 444, 445, 5, 104, 0, 0, 445, 78, 1, 0, 0, 0, 446, 447, 5, 46, 0, 0, 447, 448, 5, 115, 0, 0, 448, 449, 5, 112, 0, 0, 449, 450, 5, 108, 0, 0, 450, 451, 5, 105, 0, 0, 451, 452, 5, 116, 0, 0, 452, 80, 1, 0, 0, 0, 453, 454, 5, 46, 0, 0, 454, 455, 5, 115, 0, 0, 455, 456, 5, 108, 0, 0, 456, 457, 5, 105, 0, 0, 457, 458, 5, 99, 0, 0, 458, 459, 5, 101, 0, 0, 459, 82, 1, 0, 0, 0, 460, 461, 5, 33, 0, 0, 461, 84, 1, 0, 0, 0, 462, 463, 5, 45, 0, 0, 463, 86, 1, 0, 0, 0, 464, 465, 5, 42, 0, 0, 465, 88, 1, 0, 0, 0, 466, 467, 5, 47, 0, 0, 467, 90, 1, 0, 0, 0, 468, 469, 5, 37, 0, 0, 469, 92, 1, 0, 0, 0, 470, 471, 5, 43, 0, 0, 471, 94, 1, 0, 0, 0, 472, 473, 5, 61, 0, 0, 473, 474, 5, 61, 0, 0, 474, 96, 1, 0, 0, 0, 475, 476, 5, 33, 0, 0, 476, 477, 5, 61, 0, 0, 477, 98, 1, 0, 0, 0, 478, 479, 5, 38, 0, 0, 479, 100, 1, 0, 0, 0, 480, 481, 5, 124, 0, 0, 481, 102, 1, 0, 0, 0, 482, 483, 5, 38, 0, 0, 483, 484, 5, 38, 0, 0, 484, 104, 1, 0, 0, 0, 485, 486, 5, 124, 0, 0, 486, 487, 5, 124, 0, 0, 487, 106, 1, 0, 0, 0, 488, 489, 5, 99, 0, 0, 489, 490, 5, 111, 0, 0, 490, 491, 5, 110, 0, 0, 491, 492, 5, 115, 0, 0, 492, 493, 5, 116, 0, 0, 493, 494, 5, 97, 0, 0, 494, 495, 5, 110, 0, 0, 495, 496, 5, 116, 0, 0, 496, 108, 1, 0, 0, 0, 497, 498, 5, 105, 0, 0, 498, 499, 5, 110, 0, 0, 499, 500, 5, 116, 0, 0, 500, 110, 1, 0, 0, 0, 501, 502, 5, 98, 0, 0, 502, 503, 5, 111, 0, 0, 503, 504, 5, 111, 0, 0, 504, 505, 5, 108, 0, 0, 505, 112, 1, 0, 0, 0, 506, 507, 5, 115, 0, 0, 507, 508, 5, 116, 0, 0, 508, 509, 5, 114, 0, 0, 509, 510, 5, 105, 0, 0, 510, 511, 5, 110, 0, 0, 511, 512, 5, 103, 0, 0, 512, 114, 1, 0, 0, 0, 513, 514, 5, 112, 0, 0, 514, 515, 5, 117, 0, 0, 515, 516, 5, 98, 0, 0, 516, 517, 5, 107, 0, 0, 517, 518, 5, 101, 0, 0, 518, 519, 5, 121, 0, 0, 519, 116, 1, 0, 0, 0, 520, 521, 5, 115, 0, 0, 521, 522, 5, 105, 0, 0, 522, 523, 5, 103, 0, 0, 523, 118, 1, 0, 0, 0, 524, 525, 5, 100, 0, 0, 525, 526, 5, 97, 0, 0, 526, 527, 5, 116, 0, 0, 527, 528, 5, 97, 0, 0, 528, 529, 5, 115, 0, 0, 529, 530, 5, 105, 0, 0, 530, 531, 5, 103, 0, 0, 531, 120, 1, 0, 0, 0, 532, 534, 7, 0, 0, 0, 533, 532, 1, 0, 0, 0, 534, 535, 1, 0, 0, 0, 535, 533, 1, 0, 0, 0, 535, 536, 1, 0, 0, 0, 536, 537, 1, 0, 0, 0, 537, 539, 5, 46, 0, 0, 538, 540, 7, 0, 0, 0, 539, 538, 1, 0, 0, 0, 540, 541, 1, 0, 0, 0, 541, 539, 1, 0, 0, 0, 541, 542, 1, 0, 0, 0, 542, 543, 1, 0, 0, 0, 543, 545, 5, 46, 0, 0, 544, 546, 7, 0, 0, 0, 545, 544, 1, 0, 0, 0, 546, 547, 1, 0, 0, 0, 547, 545, 1, 0, 0, 0, 547, 548, 1, 0, 0, 0, 548, 122, 1, 0, 0, 0, 549, 550, 5, 116, 0, 0, 550, 551, 5, 114, 0, 0, 551, 552, 5, 117, 0, 0, 552, 559, 5, 101, 0, 0, 553, 554, 5, 102, 0, 0, 554, 555, 5, 97, 0, 0, 555, 556, 5, 108, 0, 0, 556, 557, 5, 115, 0, 0, 557, 559, 5, 101, 0, 0, 558, 549, 1, 0, 0, 0, 558, 553, 1, 0, 0, 0, 559, 124, 1, 0, 0, 0, 560, 561, 5, 115, 0, 0, 561, 562, 5, 97, 0, 0, 562, 563, 5, 116, 0, 0, 563, 564, 5, 111, 0, 0, 564, 565, 5, 115, 0, 0, 565, 566, 5, 104, 0, 0, 566, 567, 5, 105, 0, 0, 567, 618, 5, 115, 0, 0, 568, 569, 5, 115, 0, 0, 569, 570, 5, 97, 0, 0, 570, 571, 5, 116, 0, 0, 571, 618, 5, 115, 0, 0, 572, 573, 5, 102, 0, 0, 573, 574, 5, 105, 0, 0, 574, 575, 5, 110, 0, 0, 575, 576, 5, 110, 0, 0, 576, 577, 5, 101, 0, 0, 577, 618, 5, 121, 0, 0, 578, 579, 5, 98, 0, 0, 579, 580, 5, 105, 0, 0, 580, 581, 5, 116, 0, 0, 581, 618, 5, 115, 0, 0, 582, 583, 5, 98, 0, 0, 583, 584, 5, 105, 0, 0, 584, 585, 5, 116, 0, 0, 585, 586, 5, 99, 0, 0, 586, 587, 5, 111, 0, 0, 587, 588, 5, 105, 0, 0, 588, 618, 5, 110, 0, 0, 589, 590, 5, 115, 0, 0, 590, 591, 5, 101, 0, 0, 591, 592, 5, 99, 0, 0, 592, 593, 5, 111, 0, 0, 593, 594, 5, 110, 0, 0, 594, 595, 5, 100, 0, 0, 595, 618, 5, 115, 0, 0, 596, 597, 5, 109, 0, 0, 597, 598, 5, 105, 0, 0, 598, 599, 5, 110, 0, 0, 599, 600, 5, 117, 0, 0, 600, 601, 5, 116, 0, 0, 601, 602, 5, 101, 0, 0, 602, 618, 5, 115, 0, 0, 603, 604, 5, 104, 0, 0, 604, 605, 5, 111, 0, 0, 605, 606, 5, 117, 0, 0, 606, 607, 5, 114, 0, 0, 607, 618, 5, 115, 0, 0, 608, 609, 5, 100, 0, 0, 609, 610, 5, 97, 0, 0, 610, 611, 5, 121, 0, 0, 611, 618, 5, 115, 0, 0, 612, 613, 5, 119, 0, 0, 613, 614, 5, 101, 0, 0, 614, 615, 5, 101, 0, 0, 615, 616, 5, 107, 0, 0, 616, 618, 5, 115, 0, 0, 617, 560, 1, 0, 0, 0, 617, 568, 1, 0, 0, 0, 617, 572, 1, 0, 0, 0, 617, 578, 1, 0, 0, 0, 617, 582, 1, 0, 0, 0, 617, 589, 1, 0, 0, 0, 617, 596, 1, 0, 0, 0, 617, 603, 1, 0, 0, 0, 617, 608, 1, 0, 0, 0, 617, 612, 1, 0, 0, 0, 618, 126, 1, 0, 0, 0, 619, 621, 5, 45, 0, 0, 620, 619, 1, 0, 0, 0, 620, 621, 1, 0, 0, 0, 621, 622, 1, 0, 0, 0, 622, 624, 3, 129, 64, 0, 623, 625, 3, 131, 65, 0, 624, 623, 1, 0, 0, 0, 624, 625, 1, 0, 0, 0, 625, 128, 1, 0, 0, 0, 626, 628, 7, 0, 0, 0, 627, 626, 1, 0, 0, 0, 628, 629, 1, 0, 0, 0, 629, 627, 1, 0, 0, 0, 629, 630, 1, 0, 0, 0, 630, 639, 1, 0, 0, 0, 631, 633, 5, 95, 0, 0, 632, 634, 7, 0, 0, 0, 633, 632, 1, 0, 0, 0, 634, 635, 1, 0, 0, 0, 635, 633, 1, 0, 0, 0, 635, 636, 1, 0, 0, 0, 636, 638, 1, 0, 0, 0, 637, 631, 1, 0, 0, 0, 638, 641, 1, 0, 0, 0, 639, 637, 1, 0, 0, 0, 639, 640, 1, 0, 0, 0, 640, 130, 1, 0, 0, 0, 641, 639, 1, 0, 0, 0, 642, 643, 7, 1, 0, 0, 643, 644, 3, 129, 64, 0, 644, 132, 1, 0, 0, 0, 645, 646, 5, 98, 0, 0, 646, 647, 5, 121, 0, 0, 647, 648, 5, 116, 0, 0, 648, 649, 5, 101, 0, 0, 649, 650, 5, 115, 0, 0, 650, 652, 1, 0, 0, 0, 651, 653, 3, 135, 67, 0, 652, 651, 1, 0, 0, 0, 652, 653, 1, 0, 0, 0, 653, 659, 1, 0, 0, 0, 654, 655, 5, 98, 0, 0, 655, 656, 5, 121, 0, 0, 656, 657, 5, 116, 0, 0, 657, 659, 5, 101, 0, 0, 658, 645, 1, 0, 0, 0, 658, 654, 1, 0, 0, 0, 659, 134, 1, 0, 0, 0, 660, 664, 7, 2, 0, 0, 661, 663, 7, 0, 0, 0, 662, 661, 1, 0, 0, 0, 663, 666, 1, 0, 0, 0, 664, 662, 1, 0, 0, 0, 664, 665, 1, 0, 0, 0, 665, 136, 1, 0, 0, 0, 666, 664, 1, 0, 0, 0, 667, 673, 5, 34, 0, 0, 668, 669, 5, 92, 0, 0, 669, 672, 5, 34, 0, 0, 670, 672, 8, 3, 0, 0, 671, 668, 1, 0, 0, 0, 671, 670, 1, 0, 0, 0, 672, 675, 1, 0, 0, 0, 673, 674, 1, 0, 0, 0, 673, 671, 1, 0, 0, 0, 674, 676, 1, 0, 0, 0, 675, 673, 1, 0, 0, 0, 676, 688, 5, 34, 0, 0, 677, 683, 5, 39, 0, 0, 678, 679, 5, 92, 0, 0, 679, 682, 5, 39, 0, 0, 680, 682, 8, 4, 0, 0, 681, 678, 1, 0, 0, 0, 681, 680, 1, 0, 0, 0, 682, 685, 1, 0, 0, 0, 683, 684, 1, 0, 0, 0, 683, 681, 1, 0, 0, 0, 684, 686, 1, 0, 0, 0, 685, 683, 1, 0, 0, 0, 686, 688, 5, 39, 0, 0, 687, 667, 1, 0, 0, 0, 687, 677, 1, 0, 0, 0, 688, 138, 1, 0, 0, 0, 689, 690, 5, 100, 0, 0, 690, 691, 5, 97, 0, 0, 691, 692, 5, 116, 0, 0, 692, 693, 5, 101, 0, 0, 693, 694, 5, 40, 0, 0, 694, 695, 1, 0, 0, 0, 695, 696, 3, 137, 68, 0, 696, 697, 5, 41, 0, 0, 697, 140, 1, 0, 0, 0, 698, 699, 5, 48, 0, 0, 699, 703, 7, 5, 0, 0, 700, 702, 7, 6, 0, 0, 701, 700, 1, 0, 0, 0, 702, 705, 1, 0, 0, 0, 703, 701, 1, 0, 0, 0, 703, 704, 1, 0, 0, 0, 704, 142, 1, 0, 0, 0, 705, 703, 1, 0, 0, 0, 706, 707, 5, 116, 0, 0, 707, 708, 5, 104, 0, 0, 708, 709, 5, 105, 0, 0, 709, 710, 5, 115, 0, 0, 710, 711, 5, 46, 0, 0, 711, 712, 5, 97, 0, 0, 712, 713, 5, 103, 0, 0, 713, 722, 5, 101, 0, 0, 714, 715, 5, 116, 0, 0, 715, 716, 5, 120, 0, 0, 716, 717, 5, 46, 0, 0, 717, 718, 5, 116, 0, 0, 718, 719, 5, 105, 0, 0, 719, 720, 5, 109, 0, 0, 720, 722, 5, 101, 0, 0, 721, 706, 1, 0, 0, 0, 721, 714, 1, 0, 0, 0, 722, 144, 1, 0, 0, 0, 723, 724, 5, 116, 0, 0, 724, 725, 5, 104, 0, 0, 725, 726, 5, 105, 0, 0, 726, 727, 5, 115, 0, 0, 727, 728, 5, 46, 0, 0, 728, 729, 5, 97, 0, 0, 729, 730, 5, 99, 0, 0, 730, 731, 5, 116, 0, 0, 731, 732, 5, 105, 0, 0, 732, 733, 5, 118, 0, 0, 733, 734, 5, 101, 0, 0, 734, 735, 5, 73, 0, 0, 735, 736, 5, 110, 0, 0, 736, 737, 5, 112, 0, 0, 737, 738, 5, 117, 0, 0, 738, 739, 5, 116, 0, 0, 739, 740, 5, 73, 0, 0, 740, 741, 5, 110, 0, 0, 741, 742, 5, 100, 0, 0, 742, 743, 5, 101, 0, 0, 743, 818, 5, 120, 0, 0, 744, 745, 5, 116, 0, 0, 745, 746, 5, 104, 0, 0, 746, 747, 5, 105, 0, 0, 747, 748, 5, 115, 0, 0, 748, 749, 5, 46, 0, 0, 749, 750, 5, 97, 0, 0, 750, 751, 5, 99, 0, 0, 751, 752, 5, 116, 0, 0, 752, 753, 5, 105, 0, 0, 753, 754, 5, 118, 0, 0, 754, 755, 5, 101, 0, 0, 755, 756, 5, 66, 0, 0, 756, 757, 5, 121, 0, 0, 757, 758, 5, 116, 0, 0, 758, 759, 5, 101, 0, 0, 759, 760, 5, 99, 0, 0, 760, 761, 5, 111, 0, 0, 761, 762, 5, 100, 0, 0, 762, 818, 5, 101, 0, 0, 763, 764, 5, 116, 0, 0, 764, 765, 5, 120, 0, 0, 765, 766, 5, 46, 0, 0, 766, 767, 5, 105, 0, 0, 767, 768, 5, 110, 0, 0, 768, 769, 5, 112, 0, 0, 769, 770, 5, 117, 0, 0, 770, 771, 5, 116, 0, 0, 771, 772, 5, 115, 0, 0, 772, 773, 5, 46, 0, 0, 773, 774, 5, 108, 0, 0, 774, 775, 5, 101, 0, 0, 775, 776, 5, 110, 0, 0, 776, 777, 5, 103, 0, 0, 777, 778, 5, 116, 0, 0, 778, 818, 5, 104, 0, 0, 779, 780, 5, 116, 0, 0, 780, 781, 5, 120, 0, 0, 781, 782, 5, 46, 0, 0, 782, 783, 5, 111, 0, 0, 783, 784, 5, 117, 0, 0, 784, 785, 5, 116, 0, 0, 785, 786, 5, 112, 0, 0, 786, 787, 5, 117, 0, 0, 787, 788, 5, 116, 0, 0, 788, 789, 5, 115, 0, 0, 789, 790, 5, 46, 0, 0, 790, 791, 5, 108, 0, 0, 791, 792, 5, 101, 0, 0, 792, 793, 5, 110, 0, 0, 793, 794, 5, 103, 0, 0, 794, 795, 5, 116, 0, 0, 795, 818, 5, 104, 0, 0, 796, 797, 5, 116, 0, 0, 797, 798, 5, 120, 0, 0, 798, 799, 5, 46, 0, 0, 799, 800, 5, 118, 0, 0, 800, 801, 5, 101, 0, 0, 801, 802, 5, 114, 0, 0, 802, 803, 5, 115, 0, 0, 803, 804, 5, 105, 0, 0, 804, 805, 5, 111, 0, 0, 805, 818, 5, 110, 0, 0, 806, 807, 5, 116, 0, 0, 807, 808, 5, 120, 0, 0, 808, 809, 5, 46, 0, 0, 809, 810, 5, 108, 0, 0, 810, 811, 5, 111, 0, 0, 811, 812, 5, 99, 0, 0, 812, 813, 5, 107, 0, 0, 813, 814, 5, 116, 0, 0, 814, 815, 5, 105, 0, 0, 815, 816, 5, 109, 0, 0, 816, 818, 5, 101, 0, 0, 817, 723, 1, 0, 0, 0, 817, 744, 1, 0, 0, 0, 817, 763, 1, 0, 0, 0, 817, 779, 1, 0, 0, 0, 817, 796, 1, 0, 0, 0, 817, 806, 1, 0, 0, 0, 818, 146, 1, 0, 0, 0, 819, 823, 7, 7, 0, 0, 820, 822, 7, 8, 0, 0, 821, 820, 1, 0, 0, 0, 822, 825, 1, 0, 0, 0, 823, 821, 1, 0, 0, 0, 823, 824, 1, 0, 0, 0, 824, 148, 1, 0, 0, 0, 825, 823, 1, 0, 0, 0, 826, 828, 7, 9, 0, 0, 827, 826, 1, 0, 0, 0, 828, 829, 1, 0, 0, 0, 829, 827, 1, 0, 0, 0, 829, 830, 1, 0, 0, 0, 830, 831, 1, 0, 0, 0, 831, 832, 6, 74, 0, 0, 832, 150, 1, 0, 0, 0, 833, 834, 5, 47, 0, 0, 834, 835, 5, 42, 0, 0, 835, 839, 1, 0, 0, 0, 836, 838, 9, 0, 0, 0, 837, 836, 1, 0, 0, 0, 838, 841, 1, 0, 0, 0, 839, 840, 1, 0, 0, 0, 839, 837, 1, 0, 0, 0, 840, 842, 1, 0, 0, 0, 841, 839, 1, 0, 0, 0, 842, 843, 5, 42, 0, 0, 843, 844, 5, 47, 0, 0, 844, 845, 1, 0, 0, 0, 845, 846, 6, 75, 1, 0, 846, 152, 1, 0, 0, 0, 847, 848, 5, 47, 0, 0, 848, 849, 5, 47, 0, 0, 849, 853, 1, 0, 0, 0, 850, 852, 8, 10, 0, 0, 851, 850, 1, 0, 0, 0, 852, 855, 1, 0, 0, 0, 853, 851, 1, 0, 0, 0, 853, 854, 1, 0, 0, 0, 854, 856, 1, 0, 0, 0, 855, 853, 1, 0, 0, 0, 856, 857, 6, 76, 1, 0, 857, 154, 1, 0, 0, 0, 26, 0, 535, 541, 547, 558, 617, 620, 624, 629, 635, 639, 652, 658, 664, 671, 673, 681, 683, 687, 703, 721, 817, 823, 829, 839, 853, 2, 6, 0, 0, 0, 1, 0] \ No newline at end of file diff --git a/packages/cashc/src/grammar/CashScriptLexer.tokens b/packages/cashc/src/grammar/CashScriptLexer.tokens index 4e0173da..3a95541f 100644 --- a/packages/cashc/src/grammar/CashScriptLexer.tokens +++ b/packages/cashc/src/grammar/CashScriptLexer.tokens @@ -56,23 +56,25 @@ T__54=55 T__55=56 T__56=57 T__57=58 -VersionLiteral=59 -BooleanLiteral=60 -NumberUnit=61 -NumberLiteral=62 -NumberPart=63 -ExponentPart=64 -Bytes=65 -Bound=66 -StringLiteral=67 -DateLiteral=68 -HexLiteral=69 -TxVar=70 -NullaryOp=71 -Identifier=72 -WHITESPACE=73 -COMMENT=74 -LINE_COMMENT=75 +T__58=59 +T__59=60 +VersionLiteral=61 +BooleanLiteral=62 +NumberUnit=63 +NumberLiteral=64 +NumberPart=65 +ExponentPart=66 +Bytes=67 +Bound=68 +StringLiteral=69 +DateLiteral=70 +HexLiteral=71 +TxVar=72 +NullaryOp=73 +Identifier=74 +WHITESPACE=75 +COMMENT=76 +LINE_COMMENT=77 'pragma'=1 ';'=2 'cashscript'=3 @@ -93,41 +95,43 @@ LINE_COMMENT=75 'require'=18 'if'=19 'else'=20 -'console.log'=21 -'new'=22 -'['=23 -']'=24 -'tx.outputs'=25 -'.value'=26 -'.lockingBytecode'=27 -'.tokenCategory'=28 -'.nftCommitment'=29 -'.tokenAmount'=30 -'tx.inputs'=31 -'.outpointTransactionHash'=32 -'.outpointIndex'=33 -'.unlockingBytecode'=34 -'.sequenceNumber'=35 -'.reverse()'=36 -'.length'=37 -'.split'=38 -'.slice'=39 -'!'=40 -'-'=41 -'*'=42 -'/'=43 -'%'=44 -'+'=45 -'=='=46 -'!='=47 -'&'=48 -'|'=49 -'&&'=50 -'||'=51 -'constant'=52 -'int'=53 -'bool'=54 -'string'=55 -'pubkey'=56 -'sig'=57 -'datasig'=58 +'do'=21 +'while'=22 +'console.log'=23 +'new'=24 +'['=25 +']'=26 +'tx.outputs'=27 +'.value'=28 +'.lockingBytecode'=29 +'.tokenCategory'=30 +'.nftCommitment'=31 +'.tokenAmount'=32 +'tx.inputs'=33 +'.outpointTransactionHash'=34 +'.outpointIndex'=35 +'.unlockingBytecode'=36 +'.sequenceNumber'=37 +'.reverse()'=38 +'.length'=39 +'.split'=40 +'.slice'=41 +'!'=42 +'-'=43 +'*'=44 +'/'=45 +'%'=46 +'+'=47 +'=='=48 +'!='=49 +'&'=50 +'|'=51 +'&&'=52 +'||'=53 +'constant'=54 +'int'=55 +'bool'=56 +'string'=57 +'pubkey'=58 +'sig'=59 +'datasig'=60 diff --git a/packages/cashc/src/grammar/CashScriptLexer.ts b/packages/cashc/src/grammar/CashScriptLexer.ts index 73ad0dcb..e6fd5c92 100644 --- a/packages/cashc/src/grammar/CashScriptLexer.ts +++ b/packages/cashc/src/grammar/CashScriptLexer.ts @@ -70,23 +70,25 @@ export default class CashScriptLexer extends Lexer { public static readonly T__55 = 56; public static readonly T__56 = 57; public static readonly T__57 = 58; - public static readonly VersionLiteral = 59; - public static readonly BooleanLiteral = 60; - public static readonly NumberUnit = 61; - public static readonly NumberLiteral = 62; - public static readonly NumberPart = 63; - public static readonly ExponentPart = 64; - public static readonly Bytes = 65; - public static readonly Bound = 66; - public static readonly StringLiteral = 67; - public static readonly DateLiteral = 68; - public static readonly HexLiteral = 69; - public static readonly TxVar = 70; - public static readonly NullaryOp = 71; - public static readonly Identifier = 72; - public static readonly WHITESPACE = 73; - public static readonly COMMENT = 74; - public static readonly LINE_COMMENT = 75; + public static readonly T__58 = 59; + public static readonly T__59 = 60; + public static readonly VersionLiteral = 61; + public static readonly BooleanLiteral = 62; + public static readonly NumberUnit = 63; + public static readonly NumberLiteral = 64; + public static readonly NumberPart = 65; + public static readonly ExponentPart = 66; + public static readonly Bytes = 67; + public static readonly Bound = 68; + public static readonly StringLiteral = 69; + public static readonly DateLiteral = 70; + public static readonly HexLiteral = 71; + public static readonly TxVar = 72; + public static readonly NullaryOp = 73; + public static readonly Identifier = 74; + public static readonly WHITESPACE = 75; + public static readonly COMMENT = 76; + public static readonly LINE_COMMENT = 77; public static readonly EOF = Token.EOF; public static readonly channelNames: string[] = [ "DEFAULT_TOKEN_CHANNEL", "HIDDEN" ]; @@ -101,6 +103,7 @@ export default class CashScriptLexer extends Lexer { "'('", "','", "')'", "'require'", "'if'", "'else'", + "'do'", "'while'", "'console.log'", "'new'", "'['", "']'", "'tx.outputs'", @@ -158,6 +161,7 @@ export default class CashScriptLexer extends Lexer { null, null, null, null, null, null, + null, null, null, "VersionLiteral", "BooleanLiteral", "NumberUnit", @@ -183,10 +187,10 @@ export default class CashScriptLexer extends Lexer { "T__33", "T__34", "T__35", "T__36", "T__37", "T__38", "T__39", "T__40", "T__41", "T__42", "T__43", "T__44", "T__45", "T__46", "T__47", "T__48", "T__49", "T__50", "T__51", "T__52", "T__53", "T__54", "T__55", "T__56", - "T__57", "VersionLiteral", "BooleanLiteral", "NumberUnit", "NumberLiteral", - "NumberPart", "ExponentPart", "Bytes", "Bound", "StringLiteral", "DateLiteral", - "HexLiteral", "TxVar", "NullaryOp", "Identifier", "WHITESPACE", "COMMENT", - "LINE_COMMENT", + "T__57", "T__58", "T__59", "VersionLiteral", "BooleanLiteral", "NumberUnit", + "NumberLiteral", "NumberPart", "ExponentPart", "Bytes", "Bound", "StringLiteral", + "DateLiteral", "HexLiteral", "TxVar", "NullaryOp", "Identifier", "WHITESPACE", + "COMMENT", "LINE_COMMENT", ]; @@ -207,7 +211,7 @@ export default class CashScriptLexer extends Lexer { public get modeNames(): string[] { return CashScriptLexer.modeNames; } - public static readonly _serializedATN: number[] = [4,0,75,845,6,-1,2,0, + public static readonly _serializedATN: number[] = [4,0,77,858,6,-1,2,0, 7,0,2,1,7,1,2,2,7,2,2,3,7,3,2,4,7,4,2,5,7,5,2,6,7,6,2,7,7,7,2,8,7,8,2,9, 7,9,2,10,7,10,2,11,7,11,2,12,7,12,2,13,7,13,2,14,7,14,2,15,7,15,2,16,7, 16,2,17,7,17,2,18,7,18,2,19,7,19,2,20,7,20,2,21,7,21,2,22,7,22,2,23,7,23, @@ -218,272 +222,276 @@ export default class CashScriptLexer extends Lexer { 2,53,7,53,2,54,7,54,2,55,7,55,2,56,7,56,2,57,7,57,2,58,7,58,2,59,7,59,2, 60,7,60,2,61,7,61,2,62,7,62,2,63,7,63,2,64,7,64,2,65,7,65,2,66,7,66,2,67, 7,67,2,68,7,68,2,69,7,69,2,70,7,70,2,71,7,71,2,72,7,72,2,73,7,73,2,74,7, - 74,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,1,1,1,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2, - 1,2,1,2,1,2,1,3,1,3,1,4,1,4,1,5,1,5,1,5,1,6,1,6,1,7,1,7,1,8,1,8,1,8,1,9, - 1,9,1,10,1,10,1,10,1,10,1,10,1,10,1,10,1,10,1,10,1,11,1,11,1,12,1,12,1, - 13,1,13,1,13,1,13,1,13,1,13,1,13,1,13,1,13,1,14,1,14,1,15,1,15,1,16,1,16, - 1,17,1,17,1,17,1,17,1,17,1,17,1,17,1,17,1,18,1,18,1,18,1,19,1,19,1,19,1, - 19,1,19,1,20,1,20,1,20,1,20,1,20,1,20,1,20,1,20,1,20,1,20,1,20,1,20,1,21, - 1,21,1,21,1,21,1,22,1,22,1,23,1,23,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1, - 24,1,24,1,24,1,24,1,25,1,25,1,25,1,25,1,25,1,25,1,25,1,26,1,26,1,26,1,26, - 1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,27,1, - 27,1,27,1,27,1,27,1,27,1,27,1,27,1,27,1,27,1,27,1,27,1,27,1,27,1,27,1,28, - 1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1, - 29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,30,1,30, - 1,30,1,30,1,30,1,30,1,30,1,30,1,30,1,30,1,31,1,31,1,31,1,31,1,31,1,31,1, - 31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31, - 1,31,1,31,1,31,1,31,1,32,1,32,1,32,1,32,1,32,1,32,1,32,1,32,1,32,1,32,1, - 32,1,32,1,32,1,32,1,32,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33, - 1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,34,1,34,1,34,1,34,1,34,1, - 34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,35,1,35,1,35,1,35, - 1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,36,1,36,1,36,1,36,1,36,1,36,1,36,1, - 36,1,37,1,37,1,37,1,37,1,37,1,37,1,37,1,38,1,38,1,38,1,38,1,38,1,38,1,38, - 1,39,1,39,1,40,1,40,1,41,1,41,1,42,1,42,1,43,1,43,1,44,1,44,1,45,1,45,1, - 45,1,46,1,46,1,46,1,47,1,47,1,48,1,48,1,49,1,49,1,49,1,50,1,50,1,50,1,51, - 1,51,1,51,1,51,1,51,1,51,1,51,1,51,1,51,1,52,1,52,1,52,1,52,1,53,1,53,1, - 53,1,53,1,53,1,54,1,54,1,54,1,54,1,54,1,54,1,54,1,55,1,55,1,55,1,55,1,55, - 1,55,1,55,1,56,1,56,1,56,1,56,1,57,1,57,1,57,1,57,1,57,1,57,1,57,1,57,1, - 58,4,58,521,8,58,11,58,12,58,522,1,58,1,58,4,58,527,8,58,11,58,12,58,528, - 1,58,1,58,4,58,533,8,58,11,58,12,58,534,1,59,1,59,1,59,1,59,1,59,1,59,1, - 59,1,59,1,59,3,59,546,8,59,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60, - 1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1, - 60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60, - 1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1,60,1, - 60,1,60,1,60,1,60,1,60,3,60,605,8,60,1,61,3,61,608,8,61,1,61,1,61,3,61, - 612,8,61,1,62,4,62,615,8,62,11,62,12,62,616,1,62,1,62,4,62,621,8,62,11, - 62,12,62,622,5,62,625,8,62,10,62,12,62,628,9,62,1,63,1,63,1,63,1,64,1,64, - 1,64,1,64,1,64,1,64,1,64,3,64,640,8,64,1,64,1,64,1,64,1,64,3,64,646,8,64, - 1,65,1,65,5,65,650,8,65,10,65,12,65,653,9,65,1,66,1,66,1,66,1,66,5,66,659, - 8,66,10,66,12,66,662,9,66,1,66,1,66,1,66,1,66,1,66,5,66,669,8,66,10,66, - 12,66,672,9,66,1,66,3,66,675,8,66,1,67,1,67,1,67,1,67,1,67,1,67,1,67,1, - 67,1,67,1,68,1,68,1,68,5,68,689,8,68,10,68,12,68,692,9,68,1,69,1,69,1,69, - 1,69,1,69,1,69,1,69,1,69,1,69,1,69,1,69,1,69,1,69,1,69,1,69,3,69,709,8, - 69,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70, - 1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1, - 70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70, - 1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1, - 70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70, - 1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,1, - 70,1,70,1,70,1,70,1,70,1,70,1,70,1,70,3,70,805,8,70,1,71,1,71,5,71,809, - 8,71,10,71,12,71,812,9,71,1,72,4,72,815,8,72,11,72,12,72,816,1,72,1,72, - 1,73,1,73,1,73,1,73,5,73,825,8,73,10,73,12,73,828,9,73,1,73,1,73,1,73,1, - 73,1,73,1,74,1,74,1,74,1,74,5,74,839,8,74,10,74,12,74,842,9,74,1,74,1,74, - 3,660,670,826,0,75,1,1,3,2,5,3,7,4,9,5,11,6,13,7,15,8,17,9,19,10,21,11, - 23,12,25,13,27,14,29,15,31,16,33,17,35,18,37,19,39,20,41,21,43,22,45,23, - 47,24,49,25,51,26,53,27,55,28,57,29,59,30,61,31,63,32,65,33,67,34,69,35, - 71,36,73,37,75,38,77,39,79,40,81,41,83,42,85,43,87,44,89,45,91,46,93,47, - 95,48,97,49,99,50,101,51,103,52,105,53,107,54,109,55,111,56,113,57,115, - 58,117,59,119,60,121,61,123,62,125,63,127,64,129,65,131,66,133,67,135,68, - 137,69,139,70,141,71,143,72,145,73,147,74,149,75,1,0,11,1,0,48,57,2,0,69, - 69,101,101,1,0,49,57,3,0,10,10,13,13,34,34,3,0,10,10,13,13,39,39,2,0,88, - 88,120,120,3,0,48,57,65,70,97,102,2,0,65,90,97,122,4,0,48,57,65,90,95,95, - 97,122,3,0,9,10,12,13,32,32,2,0,10,10,13,13,881,0,1,1,0,0,0,0,3,1,0,0,0, - 0,5,1,0,0,0,0,7,1,0,0,0,0,9,1,0,0,0,0,11,1,0,0,0,0,13,1,0,0,0,0,15,1,0, - 0,0,0,17,1,0,0,0,0,19,1,0,0,0,0,21,1,0,0,0,0,23,1,0,0,0,0,25,1,0,0,0,0, - 27,1,0,0,0,0,29,1,0,0,0,0,31,1,0,0,0,0,33,1,0,0,0,0,35,1,0,0,0,0,37,1,0, - 0,0,0,39,1,0,0,0,0,41,1,0,0,0,0,43,1,0,0,0,0,45,1,0,0,0,0,47,1,0,0,0,0, - 49,1,0,0,0,0,51,1,0,0,0,0,53,1,0,0,0,0,55,1,0,0,0,0,57,1,0,0,0,0,59,1,0, - 0,0,0,61,1,0,0,0,0,63,1,0,0,0,0,65,1,0,0,0,0,67,1,0,0,0,0,69,1,0,0,0,0, - 71,1,0,0,0,0,73,1,0,0,0,0,75,1,0,0,0,0,77,1,0,0,0,0,79,1,0,0,0,0,81,1,0, - 0,0,0,83,1,0,0,0,0,85,1,0,0,0,0,87,1,0,0,0,0,89,1,0,0,0,0,91,1,0,0,0,0, - 93,1,0,0,0,0,95,1,0,0,0,0,97,1,0,0,0,0,99,1,0,0,0,0,101,1,0,0,0,0,103,1, - 0,0,0,0,105,1,0,0,0,0,107,1,0,0,0,0,109,1,0,0,0,0,111,1,0,0,0,0,113,1,0, - 0,0,0,115,1,0,0,0,0,117,1,0,0,0,0,119,1,0,0,0,0,121,1,0,0,0,0,123,1,0,0, - 0,0,125,1,0,0,0,0,127,1,0,0,0,0,129,1,0,0,0,0,131,1,0,0,0,0,133,1,0,0,0, - 0,135,1,0,0,0,0,137,1,0,0,0,0,139,1,0,0,0,0,141,1,0,0,0,0,143,1,0,0,0,0, - 145,1,0,0,0,0,147,1,0,0,0,0,149,1,0,0,0,1,151,1,0,0,0,3,158,1,0,0,0,5,160, - 1,0,0,0,7,171,1,0,0,0,9,173,1,0,0,0,11,175,1,0,0,0,13,178,1,0,0,0,15,180, - 1,0,0,0,17,182,1,0,0,0,19,185,1,0,0,0,21,187,1,0,0,0,23,196,1,0,0,0,25, - 198,1,0,0,0,27,200,1,0,0,0,29,209,1,0,0,0,31,211,1,0,0,0,33,213,1,0,0,0, - 35,215,1,0,0,0,37,223,1,0,0,0,39,226,1,0,0,0,41,231,1,0,0,0,43,243,1,0, - 0,0,45,247,1,0,0,0,47,249,1,0,0,0,49,251,1,0,0,0,51,262,1,0,0,0,53,269, - 1,0,0,0,55,286,1,0,0,0,57,301,1,0,0,0,59,316,1,0,0,0,61,329,1,0,0,0,63, - 339,1,0,0,0,65,364,1,0,0,0,67,379,1,0,0,0,69,398,1,0,0,0,71,414,1,0,0,0, - 73,425,1,0,0,0,75,433,1,0,0,0,77,440,1,0,0,0,79,447,1,0,0,0,81,449,1,0, - 0,0,83,451,1,0,0,0,85,453,1,0,0,0,87,455,1,0,0,0,89,457,1,0,0,0,91,459, - 1,0,0,0,93,462,1,0,0,0,95,465,1,0,0,0,97,467,1,0,0,0,99,469,1,0,0,0,101, - 472,1,0,0,0,103,475,1,0,0,0,105,484,1,0,0,0,107,488,1,0,0,0,109,493,1,0, - 0,0,111,500,1,0,0,0,113,507,1,0,0,0,115,511,1,0,0,0,117,520,1,0,0,0,119, - 545,1,0,0,0,121,604,1,0,0,0,123,607,1,0,0,0,125,614,1,0,0,0,127,629,1,0, - 0,0,129,645,1,0,0,0,131,647,1,0,0,0,133,674,1,0,0,0,135,676,1,0,0,0,137, - 685,1,0,0,0,139,708,1,0,0,0,141,804,1,0,0,0,143,806,1,0,0,0,145,814,1,0, - 0,0,147,820,1,0,0,0,149,834,1,0,0,0,151,152,5,112,0,0,152,153,5,114,0,0, - 153,154,5,97,0,0,154,155,5,103,0,0,155,156,5,109,0,0,156,157,5,97,0,0,157, - 2,1,0,0,0,158,159,5,59,0,0,159,4,1,0,0,0,160,161,5,99,0,0,161,162,5,97, - 0,0,162,163,5,115,0,0,163,164,5,104,0,0,164,165,5,115,0,0,165,166,5,99, - 0,0,166,167,5,114,0,0,167,168,5,105,0,0,168,169,5,112,0,0,169,170,5,116, - 0,0,170,6,1,0,0,0,171,172,5,94,0,0,172,8,1,0,0,0,173,174,5,126,0,0,174, - 10,1,0,0,0,175,176,5,62,0,0,176,177,5,61,0,0,177,12,1,0,0,0,178,179,5,62, - 0,0,179,14,1,0,0,0,180,181,5,60,0,0,181,16,1,0,0,0,182,183,5,60,0,0,183, - 184,5,61,0,0,184,18,1,0,0,0,185,186,5,61,0,0,186,20,1,0,0,0,187,188,5,99, - 0,0,188,189,5,111,0,0,189,190,5,110,0,0,190,191,5,116,0,0,191,192,5,114, - 0,0,192,193,5,97,0,0,193,194,5,99,0,0,194,195,5,116,0,0,195,22,1,0,0,0, - 196,197,5,123,0,0,197,24,1,0,0,0,198,199,5,125,0,0,199,26,1,0,0,0,200,201, - 5,102,0,0,201,202,5,117,0,0,202,203,5,110,0,0,203,204,5,99,0,0,204,205, - 5,116,0,0,205,206,5,105,0,0,206,207,5,111,0,0,207,208,5,110,0,0,208,28, - 1,0,0,0,209,210,5,40,0,0,210,30,1,0,0,0,211,212,5,44,0,0,212,32,1,0,0,0, - 213,214,5,41,0,0,214,34,1,0,0,0,215,216,5,114,0,0,216,217,5,101,0,0,217, - 218,5,113,0,0,218,219,5,117,0,0,219,220,5,105,0,0,220,221,5,114,0,0,221, - 222,5,101,0,0,222,36,1,0,0,0,223,224,5,105,0,0,224,225,5,102,0,0,225,38, - 1,0,0,0,226,227,5,101,0,0,227,228,5,108,0,0,228,229,5,115,0,0,229,230,5, - 101,0,0,230,40,1,0,0,0,231,232,5,99,0,0,232,233,5,111,0,0,233,234,5,110, - 0,0,234,235,5,115,0,0,235,236,5,111,0,0,236,237,5,108,0,0,237,238,5,101, - 0,0,238,239,5,46,0,0,239,240,5,108,0,0,240,241,5,111,0,0,241,242,5,103, - 0,0,242,42,1,0,0,0,243,244,5,110,0,0,244,245,5,101,0,0,245,246,5,119,0, - 0,246,44,1,0,0,0,247,248,5,91,0,0,248,46,1,0,0,0,249,250,5,93,0,0,250,48, - 1,0,0,0,251,252,5,116,0,0,252,253,5,120,0,0,253,254,5,46,0,0,254,255,5, - 111,0,0,255,256,5,117,0,0,256,257,5,116,0,0,257,258,5,112,0,0,258,259,5, - 117,0,0,259,260,5,116,0,0,260,261,5,115,0,0,261,50,1,0,0,0,262,263,5,46, - 0,0,263,264,5,118,0,0,264,265,5,97,0,0,265,266,5,108,0,0,266,267,5,117, - 0,0,267,268,5,101,0,0,268,52,1,0,0,0,269,270,5,46,0,0,270,271,5,108,0,0, - 271,272,5,111,0,0,272,273,5,99,0,0,273,274,5,107,0,0,274,275,5,105,0,0, - 275,276,5,110,0,0,276,277,5,103,0,0,277,278,5,66,0,0,278,279,5,121,0,0, - 279,280,5,116,0,0,280,281,5,101,0,0,281,282,5,99,0,0,282,283,5,111,0,0, - 283,284,5,100,0,0,284,285,5,101,0,0,285,54,1,0,0,0,286,287,5,46,0,0,287, - 288,5,116,0,0,288,289,5,111,0,0,289,290,5,107,0,0,290,291,5,101,0,0,291, - 292,5,110,0,0,292,293,5,67,0,0,293,294,5,97,0,0,294,295,5,116,0,0,295,296, - 5,101,0,0,296,297,5,103,0,0,297,298,5,111,0,0,298,299,5,114,0,0,299,300, - 5,121,0,0,300,56,1,0,0,0,301,302,5,46,0,0,302,303,5,110,0,0,303,304,5,102, - 0,0,304,305,5,116,0,0,305,306,5,67,0,0,306,307,5,111,0,0,307,308,5,109, - 0,0,308,309,5,109,0,0,309,310,5,105,0,0,310,311,5,116,0,0,311,312,5,109, - 0,0,312,313,5,101,0,0,313,314,5,110,0,0,314,315,5,116,0,0,315,58,1,0,0, - 0,316,317,5,46,0,0,317,318,5,116,0,0,318,319,5,111,0,0,319,320,5,107,0, - 0,320,321,5,101,0,0,321,322,5,110,0,0,322,323,5,65,0,0,323,324,5,109,0, - 0,324,325,5,111,0,0,325,326,5,117,0,0,326,327,5,110,0,0,327,328,5,116,0, - 0,328,60,1,0,0,0,329,330,5,116,0,0,330,331,5,120,0,0,331,332,5,46,0,0,332, - 333,5,105,0,0,333,334,5,110,0,0,334,335,5,112,0,0,335,336,5,117,0,0,336, - 337,5,116,0,0,337,338,5,115,0,0,338,62,1,0,0,0,339,340,5,46,0,0,340,341, - 5,111,0,0,341,342,5,117,0,0,342,343,5,116,0,0,343,344,5,112,0,0,344,345, - 5,111,0,0,345,346,5,105,0,0,346,347,5,110,0,0,347,348,5,116,0,0,348,349, - 5,84,0,0,349,350,5,114,0,0,350,351,5,97,0,0,351,352,5,110,0,0,352,353,5, - 115,0,0,353,354,5,97,0,0,354,355,5,99,0,0,355,356,5,116,0,0,356,357,5,105, - 0,0,357,358,5,111,0,0,358,359,5,110,0,0,359,360,5,72,0,0,360,361,5,97,0, - 0,361,362,5,115,0,0,362,363,5,104,0,0,363,64,1,0,0,0,364,365,5,46,0,0,365, - 366,5,111,0,0,366,367,5,117,0,0,367,368,5,116,0,0,368,369,5,112,0,0,369, - 370,5,111,0,0,370,371,5,105,0,0,371,372,5,110,0,0,372,373,5,116,0,0,373, - 374,5,73,0,0,374,375,5,110,0,0,375,376,5,100,0,0,376,377,5,101,0,0,377, - 378,5,120,0,0,378,66,1,0,0,0,379,380,5,46,0,0,380,381,5,117,0,0,381,382, - 5,110,0,0,382,383,5,108,0,0,383,384,5,111,0,0,384,385,5,99,0,0,385,386, - 5,107,0,0,386,387,5,105,0,0,387,388,5,110,0,0,388,389,5,103,0,0,389,390, - 5,66,0,0,390,391,5,121,0,0,391,392,5,116,0,0,392,393,5,101,0,0,393,394, - 5,99,0,0,394,395,5,111,0,0,395,396,5,100,0,0,396,397,5,101,0,0,397,68,1, - 0,0,0,398,399,5,46,0,0,399,400,5,115,0,0,400,401,5,101,0,0,401,402,5,113, - 0,0,402,403,5,117,0,0,403,404,5,101,0,0,404,405,5,110,0,0,405,406,5,99, - 0,0,406,407,5,101,0,0,407,408,5,78,0,0,408,409,5,117,0,0,409,410,5,109, - 0,0,410,411,5,98,0,0,411,412,5,101,0,0,412,413,5,114,0,0,413,70,1,0,0,0, - 414,415,5,46,0,0,415,416,5,114,0,0,416,417,5,101,0,0,417,418,5,118,0,0, - 418,419,5,101,0,0,419,420,5,114,0,0,420,421,5,115,0,0,421,422,5,101,0,0, - 422,423,5,40,0,0,423,424,5,41,0,0,424,72,1,0,0,0,425,426,5,46,0,0,426,427, - 5,108,0,0,427,428,5,101,0,0,428,429,5,110,0,0,429,430,5,103,0,0,430,431, - 5,116,0,0,431,432,5,104,0,0,432,74,1,0,0,0,433,434,5,46,0,0,434,435,5,115, - 0,0,435,436,5,112,0,0,436,437,5,108,0,0,437,438,5,105,0,0,438,439,5,116, - 0,0,439,76,1,0,0,0,440,441,5,46,0,0,441,442,5,115,0,0,442,443,5,108,0,0, - 443,444,5,105,0,0,444,445,5,99,0,0,445,446,5,101,0,0,446,78,1,0,0,0,447, - 448,5,33,0,0,448,80,1,0,0,0,449,450,5,45,0,0,450,82,1,0,0,0,451,452,5,42, - 0,0,452,84,1,0,0,0,453,454,5,47,0,0,454,86,1,0,0,0,455,456,5,37,0,0,456, - 88,1,0,0,0,457,458,5,43,0,0,458,90,1,0,0,0,459,460,5,61,0,0,460,461,5,61, - 0,0,461,92,1,0,0,0,462,463,5,33,0,0,463,464,5,61,0,0,464,94,1,0,0,0,465, - 466,5,38,0,0,466,96,1,0,0,0,467,468,5,124,0,0,468,98,1,0,0,0,469,470,5, - 38,0,0,470,471,5,38,0,0,471,100,1,0,0,0,472,473,5,124,0,0,473,474,5,124, - 0,0,474,102,1,0,0,0,475,476,5,99,0,0,476,477,5,111,0,0,477,478,5,110,0, - 0,478,479,5,115,0,0,479,480,5,116,0,0,480,481,5,97,0,0,481,482,5,110,0, - 0,482,483,5,116,0,0,483,104,1,0,0,0,484,485,5,105,0,0,485,486,5,110,0,0, - 486,487,5,116,0,0,487,106,1,0,0,0,488,489,5,98,0,0,489,490,5,111,0,0,490, - 491,5,111,0,0,491,492,5,108,0,0,492,108,1,0,0,0,493,494,5,115,0,0,494,495, - 5,116,0,0,495,496,5,114,0,0,496,497,5,105,0,0,497,498,5,110,0,0,498,499, - 5,103,0,0,499,110,1,0,0,0,500,501,5,112,0,0,501,502,5,117,0,0,502,503,5, - 98,0,0,503,504,5,107,0,0,504,505,5,101,0,0,505,506,5,121,0,0,506,112,1, - 0,0,0,507,508,5,115,0,0,508,509,5,105,0,0,509,510,5,103,0,0,510,114,1,0, - 0,0,511,512,5,100,0,0,512,513,5,97,0,0,513,514,5,116,0,0,514,515,5,97,0, - 0,515,516,5,115,0,0,516,517,5,105,0,0,517,518,5,103,0,0,518,116,1,0,0,0, - 519,521,7,0,0,0,520,519,1,0,0,0,521,522,1,0,0,0,522,520,1,0,0,0,522,523, - 1,0,0,0,523,524,1,0,0,0,524,526,5,46,0,0,525,527,7,0,0,0,526,525,1,0,0, - 0,527,528,1,0,0,0,528,526,1,0,0,0,528,529,1,0,0,0,529,530,1,0,0,0,530,532, - 5,46,0,0,531,533,7,0,0,0,532,531,1,0,0,0,533,534,1,0,0,0,534,532,1,0,0, - 0,534,535,1,0,0,0,535,118,1,0,0,0,536,537,5,116,0,0,537,538,5,114,0,0,538, - 539,5,117,0,0,539,546,5,101,0,0,540,541,5,102,0,0,541,542,5,97,0,0,542, - 543,5,108,0,0,543,544,5,115,0,0,544,546,5,101,0,0,545,536,1,0,0,0,545,540, - 1,0,0,0,546,120,1,0,0,0,547,548,5,115,0,0,548,549,5,97,0,0,549,550,5,116, - 0,0,550,551,5,111,0,0,551,552,5,115,0,0,552,553,5,104,0,0,553,554,5,105, - 0,0,554,605,5,115,0,0,555,556,5,115,0,0,556,557,5,97,0,0,557,558,5,116, - 0,0,558,605,5,115,0,0,559,560,5,102,0,0,560,561,5,105,0,0,561,562,5,110, - 0,0,562,563,5,110,0,0,563,564,5,101,0,0,564,605,5,121,0,0,565,566,5,98, - 0,0,566,567,5,105,0,0,567,568,5,116,0,0,568,605,5,115,0,0,569,570,5,98, - 0,0,570,571,5,105,0,0,571,572,5,116,0,0,572,573,5,99,0,0,573,574,5,111, - 0,0,574,575,5,105,0,0,575,605,5,110,0,0,576,577,5,115,0,0,577,578,5,101, - 0,0,578,579,5,99,0,0,579,580,5,111,0,0,580,581,5,110,0,0,581,582,5,100, - 0,0,582,605,5,115,0,0,583,584,5,109,0,0,584,585,5,105,0,0,585,586,5,110, - 0,0,586,587,5,117,0,0,587,588,5,116,0,0,588,589,5,101,0,0,589,605,5,115, - 0,0,590,591,5,104,0,0,591,592,5,111,0,0,592,593,5,117,0,0,593,594,5,114, - 0,0,594,605,5,115,0,0,595,596,5,100,0,0,596,597,5,97,0,0,597,598,5,121, - 0,0,598,605,5,115,0,0,599,600,5,119,0,0,600,601,5,101,0,0,601,602,5,101, - 0,0,602,603,5,107,0,0,603,605,5,115,0,0,604,547,1,0,0,0,604,555,1,0,0,0, - 604,559,1,0,0,0,604,565,1,0,0,0,604,569,1,0,0,0,604,576,1,0,0,0,604,583, - 1,0,0,0,604,590,1,0,0,0,604,595,1,0,0,0,604,599,1,0,0,0,605,122,1,0,0,0, - 606,608,5,45,0,0,607,606,1,0,0,0,607,608,1,0,0,0,608,609,1,0,0,0,609,611, - 3,125,62,0,610,612,3,127,63,0,611,610,1,0,0,0,611,612,1,0,0,0,612,124,1, - 0,0,0,613,615,7,0,0,0,614,613,1,0,0,0,615,616,1,0,0,0,616,614,1,0,0,0,616, - 617,1,0,0,0,617,626,1,0,0,0,618,620,5,95,0,0,619,621,7,0,0,0,620,619,1, - 0,0,0,621,622,1,0,0,0,622,620,1,0,0,0,622,623,1,0,0,0,623,625,1,0,0,0,624, - 618,1,0,0,0,625,628,1,0,0,0,626,624,1,0,0,0,626,627,1,0,0,0,627,126,1,0, - 0,0,628,626,1,0,0,0,629,630,7,1,0,0,630,631,3,125,62,0,631,128,1,0,0,0, - 632,633,5,98,0,0,633,634,5,121,0,0,634,635,5,116,0,0,635,636,5,101,0,0, - 636,637,5,115,0,0,637,639,1,0,0,0,638,640,3,131,65,0,639,638,1,0,0,0,639, - 640,1,0,0,0,640,646,1,0,0,0,641,642,5,98,0,0,642,643,5,121,0,0,643,644, - 5,116,0,0,644,646,5,101,0,0,645,632,1,0,0,0,645,641,1,0,0,0,646,130,1,0, - 0,0,647,651,7,2,0,0,648,650,7,0,0,0,649,648,1,0,0,0,650,653,1,0,0,0,651, - 649,1,0,0,0,651,652,1,0,0,0,652,132,1,0,0,0,653,651,1,0,0,0,654,660,5,34, - 0,0,655,656,5,92,0,0,656,659,5,34,0,0,657,659,8,3,0,0,658,655,1,0,0,0,658, - 657,1,0,0,0,659,662,1,0,0,0,660,661,1,0,0,0,660,658,1,0,0,0,661,663,1,0, - 0,0,662,660,1,0,0,0,663,675,5,34,0,0,664,670,5,39,0,0,665,666,5,92,0,0, - 666,669,5,39,0,0,667,669,8,4,0,0,668,665,1,0,0,0,668,667,1,0,0,0,669,672, - 1,0,0,0,670,671,1,0,0,0,670,668,1,0,0,0,671,673,1,0,0,0,672,670,1,0,0,0, - 673,675,5,39,0,0,674,654,1,0,0,0,674,664,1,0,0,0,675,134,1,0,0,0,676,677, - 5,100,0,0,677,678,5,97,0,0,678,679,5,116,0,0,679,680,5,101,0,0,680,681, - 5,40,0,0,681,682,1,0,0,0,682,683,3,133,66,0,683,684,5,41,0,0,684,136,1, - 0,0,0,685,686,5,48,0,0,686,690,7,5,0,0,687,689,7,6,0,0,688,687,1,0,0,0, - 689,692,1,0,0,0,690,688,1,0,0,0,690,691,1,0,0,0,691,138,1,0,0,0,692,690, - 1,0,0,0,693,694,5,116,0,0,694,695,5,104,0,0,695,696,5,105,0,0,696,697,5, - 115,0,0,697,698,5,46,0,0,698,699,5,97,0,0,699,700,5,103,0,0,700,709,5,101, - 0,0,701,702,5,116,0,0,702,703,5,120,0,0,703,704,5,46,0,0,704,705,5,116, - 0,0,705,706,5,105,0,0,706,707,5,109,0,0,707,709,5,101,0,0,708,693,1,0,0, - 0,708,701,1,0,0,0,709,140,1,0,0,0,710,711,5,116,0,0,711,712,5,104,0,0,712, - 713,5,105,0,0,713,714,5,115,0,0,714,715,5,46,0,0,715,716,5,97,0,0,716,717, - 5,99,0,0,717,718,5,116,0,0,718,719,5,105,0,0,719,720,5,118,0,0,720,721, - 5,101,0,0,721,722,5,73,0,0,722,723,5,110,0,0,723,724,5,112,0,0,724,725, - 5,117,0,0,725,726,5,116,0,0,726,727,5,73,0,0,727,728,5,110,0,0,728,729, - 5,100,0,0,729,730,5,101,0,0,730,805,5,120,0,0,731,732,5,116,0,0,732,733, - 5,104,0,0,733,734,5,105,0,0,734,735,5,115,0,0,735,736,5,46,0,0,736,737, - 5,97,0,0,737,738,5,99,0,0,738,739,5,116,0,0,739,740,5,105,0,0,740,741,5, - 118,0,0,741,742,5,101,0,0,742,743,5,66,0,0,743,744,5,121,0,0,744,745,5, - 116,0,0,745,746,5,101,0,0,746,747,5,99,0,0,747,748,5,111,0,0,748,749,5, - 100,0,0,749,805,5,101,0,0,750,751,5,116,0,0,751,752,5,120,0,0,752,753,5, - 46,0,0,753,754,5,105,0,0,754,755,5,110,0,0,755,756,5,112,0,0,756,757,5, - 117,0,0,757,758,5,116,0,0,758,759,5,115,0,0,759,760,5,46,0,0,760,761,5, - 108,0,0,761,762,5,101,0,0,762,763,5,110,0,0,763,764,5,103,0,0,764,765,5, - 116,0,0,765,805,5,104,0,0,766,767,5,116,0,0,767,768,5,120,0,0,768,769,5, - 46,0,0,769,770,5,111,0,0,770,771,5,117,0,0,771,772,5,116,0,0,772,773,5, - 112,0,0,773,774,5,117,0,0,774,775,5,116,0,0,775,776,5,115,0,0,776,777,5, - 46,0,0,777,778,5,108,0,0,778,779,5,101,0,0,779,780,5,110,0,0,780,781,5, - 103,0,0,781,782,5,116,0,0,782,805,5,104,0,0,783,784,5,116,0,0,784,785,5, - 120,0,0,785,786,5,46,0,0,786,787,5,118,0,0,787,788,5,101,0,0,788,789,5, - 114,0,0,789,790,5,115,0,0,790,791,5,105,0,0,791,792,5,111,0,0,792,805,5, - 110,0,0,793,794,5,116,0,0,794,795,5,120,0,0,795,796,5,46,0,0,796,797,5, - 108,0,0,797,798,5,111,0,0,798,799,5,99,0,0,799,800,5,107,0,0,800,801,5, - 116,0,0,801,802,5,105,0,0,802,803,5,109,0,0,803,805,5,101,0,0,804,710,1, - 0,0,0,804,731,1,0,0,0,804,750,1,0,0,0,804,766,1,0,0,0,804,783,1,0,0,0,804, - 793,1,0,0,0,805,142,1,0,0,0,806,810,7,7,0,0,807,809,7,8,0,0,808,807,1,0, - 0,0,809,812,1,0,0,0,810,808,1,0,0,0,810,811,1,0,0,0,811,144,1,0,0,0,812, - 810,1,0,0,0,813,815,7,9,0,0,814,813,1,0,0,0,815,816,1,0,0,0,816,814,1,0, - 0,0,816,817,1,0,0,0,817,818,1,0,0,0,818,819,6,72,0,0,819,146,1,0,0,0,820, - 821,5,47,0,0,821,822,5,42,0,0,822,826,1,0,0,0,823,825,9,0,0,0,824,823,1, - 0,0,0,825,828,1,0,0,0,826,827,1,0,0,0,826,824,1,0,0,0,827,829,1,0,0,0,828, - 826,1,0,0,0,829,830,5,42,0,0,830,831,5,47,0,0,831,832,1,0,0,0,832,833,6, - 73,1,0,833,148,1,0,0,0,834,835,5,47,0,0,835,836,5,47,0,0,836,840,1,0,0, - 0,837,839,8,10,0,0,838,837,1,0,0,0,839,842,1,0,0,0,840,838,1,0,0,0,840, - 841,1,0,0,0,841,843,1,0,0,0,842,840,1,0,0,0,843,844,6,74,1,0,844,150,1, - 0,0,0,26,0,522,528,534,545,604,607,611,616,622,626,639,645,651,658,660, - 668,670,674,690,708,804,810,816,826,840,2,6,0,0,0,1,0]; + 74,2,75,7,75,2,76,7,76,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,1,1,1,1,2,1,2,1,2, + 1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,3,1,3,1,4,1,4,1,5,1,5,1,5,1,6,1,6,1,7, + 1,7,1,8,1,8,1,8,1,9,1,9,1,10,1,10,1,10,1,10,1,10,1,10,1,10,1,10,1,10,1, + 11,1,11,1,12,1,12,1,13,1,13,1,13,1,13,1,13,1,13,1,13,1,13,1,13,1,14,1,14, + 1,15,1,15,1,16,1,16,1,17,1,17,1,17,1,17,1,17,1,17,1,17,1,17,1,18,1,18,1, + 18,1,19,1,19,1,19,1,19,1,19,1,20,1,20,1,20,1,21,1,21,1,21,1,21,1,21,1,21, + 1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,23,1,23,1, + 23,1,23,1,24,1,24,1,25,1,25,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26, + 1,26,1,26,1,27,1,27,1,27,1,27,1,27,1,27,1,27,1,28,1,28,1,28,1,28,1,28,1, + 28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,29,1,29,1,29, + 1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,29,1,30,1,30,1, + 30,1,30,1,30,1,30,1,30,1,30,1,30,1,30,1,30,1,30,1,30,1,30,1,30,1,31,1,31, + 1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,32,1,32,1,32,1, + 32,1,32,1,32,1,32,1,32,1,32,1,32,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33, + 1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1, + 33,1,33,1,33,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34, + 1,34,1,34,1,34,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1, + 35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,36,1,36,1,36,1,36,1,36,1,36,1,36, + 1,36,1,36,1,36,1,36,1,36,1,36,1,36,1,36,1,36,1,37,1,37,1,37,1,37,1,37,1, + 37,1,37,1,37,1,37,1,37,1,37,1,38,1,38,1,38,1,38,1,38,1,38,1,38,1,38,1,39, + 1,39,1,39,1,39,1,39,1,39,1,39,1,40,1,40,1,40,1,40,1,40,1,40,1,40,1,41,1, + 41,1,42,1,42,1,43,1,43,1,44,1,44,1,45,1,45,1,46,1,46,1,47,1,47,1,47,1,48, + 1,48,1,48,1,49,1,49,1,50,1,50,1,51,1,51,1,51,1,52,1,52,1,52,1,53,1,53,1, + 53,1,53,1,53,1,53,1,53,1,53,1,53,1,54,1,54,1,54,1,54,1,55,1,55,1,55,1,55, + 1,55,1,56,1,56,1,56,1,56,1,56,1,56,1,56,1,57,1,57,1,57,1,57,1,57,1,57,1, + 57,1,58,1,58,1,58,1,58,1,59,1,59,1,59,1,59,1,59,1,59,1,59,1,59,1,60,4,60, + 534,8,60,11,60,12,60,535,1,60,1,60,4,60,540,8,60,11,60,12,60,541,1,60,1, + 60,4,60,546,8,60,11,60,12,60,547,1,61,1,61,1,61,1,61,1,61,1,61,1,61,1,61, + 1,61,3,61,559,8,61,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1, + 62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62, + 1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1, + 62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62,1,62, + 1,62,1,62,1,62,3,62,618,8,62,1,63,3,63,621,8,63,1,63,1,63,3,63,625,8,63, + 1,64,4,64,628,8,64,11,64,12,64,629,1,64,1,64,4,64,634,8,64,11,64,12,64, + 635,5,64,638,8,64,10,64,12,64,641,9,64,1,65,1,65,1,65,1,66,1,66,1,66,1, + 66,1,66,1,66,1,66,3,66,653,8,66,1,66,1,66,1,66,1,66,3,66,659,8,66,1,67, + 1,67,5,67,663,8,67,10,67,12,67,666,9,67,1,68,1,68,1,68,1,68,5,68,672,8, + 68,10,68,12,68,675,9,68,1,68,1,68,1,68,1,68,1,68,5,68,682,8,68,10,68,12, + 68,685,9,68,1,68,3,68,688,8,68,1,69,1,69,1,69,1,69,1,69,1,69,1,69,1,69, + 1,69,1,70,1,70,1,70,5,70,702,8,70,10,70,12,70,705,9,70,1,71,1,71,1,71,1, + 71,1,71,1,71,1,71,1,71,1,71,1,71,1,71,1,71,1,71,1,71,1,71,3,71,722,8,71, + 1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1, + 72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72, + 1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1, + 72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72, + 1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1, + 72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72,1,72, + 1,72,1,72,1,72,1,72,1,72,1,72,1,72,3,72,818,8,72,1,73,1,73,5,73,822,8,73, + 10,73,12,73,825,9,73,1,74,4,74,828,8,74,11,74,12,74,829,1,74,1,74,1,75, + 1,75,1,75,1,75,5,75,838,8,75,10,75,12,75,841,9,75,1,75,1,75,1,75,1,75,1, + 75,1,76,1,76,1,76,1,76,5,76,852,8,76,10,76,12,76,855,9,76,1,76,1,76,3,673, + 683,839,0,77,1,1,3,2,5,3,7,4,9,5,11,6,13,7,15,8,17,9,19,10,21,11,23,12, + 25,13,27,14,29,15,31,16,33,17,35,18,37,19,39,20,41,21,43,22,45,23,47,24, + 49,25,51,26,53,27,55,28,57,29,59,30,61,31,63,32,65,33,67,34,69,35,71,36, + 73,37,75,38,77,39,79,40,81,41,83,42,85,43,87,44,89,45,91,46,93,47,95,48, + 97,49,99,50,101,51,103,52,105,53,107,54,109,55,111,56,113,57,115,58,117, + 59,119,60,121,61,123,62,125,63,127,64,129,65,131,66,133,67,135,68,137,69, + 139,70,141,71,143,72,145,73,147,74,149,75,151,76,153,77,1,0,11,1,0,48,57, + 2,0,69,69,101,101,1,0,49,57,3,0,10,10,13,13,34,34,3,0,10,10,13,13,39,39, + 2,0,88,88,120,120,3,0,48,57,65,70,97,102,2,0,65,90,97,122,4,0,48,57,65, + 90,95,95,97,122,3,0,9,10,12,13,32,32,2,0,10,10,13,13,894,0,1,1,0,0,0,0, + 3,1,0,0,0,0,5,1,0,0,0,0,7,1,0,0,0,0,9,1,0,0,0,0,11,1,0,0,0,0,13,1,0,0,0, + 0,15,1,0,0,0,0,17,1,0,0,0,0,19,1,0,0,0,0,21,1,0,0,0,0,23,1,0,0,0,0,25,1, + 0,0,0,0,27,1,0,0,0,0,29,1,0,0,0,0,31,1,0,0,0,0,33,1,0,0,0,0,35,1,0,0,0, + 0,37,1,0,0,0,0,39,1,0,0,0,0,41,1,0,0,0,0,43,1,0,0,0,0,45,1,0,0,0,0,47,1, + 0,0,0,0,49,1,0,0,0,0,51,1,0,0,0,0,53,1,0,0,0,0,55,1,0,0,0,0,57,1,0,0,0, + 0,59,1,0,0,0,0,61,1,0,0,0,0,63,1,0,0,0,0,65,1,0,0,0,0,67,1,0,0,0,0,69,1, + 0,0,0,0,71,1,0,0,0,0,73,1,0,0,0,0,75,1,0,0,0,0,77,1,0,0,0,0,79,1,0,0,0, + 0,81,1,0,0,0,0,83,1,0,0,0,0,85,1,0,0,0,0,87,1,0,0,0,0,89,1,0,0,0,0,91,1, + 0,0,0,0,93,1,0,0,0,0,95,1,0,0,0,0,97,1,0,0,0,0,99,1,0,0,0,0,101,1,0,0,0, + 0,103,1,0,0,0,0,105,1,0,0,0,0,107,1,0,0,0,0,109,1,0,0,0,0,111,1,0,0,0,0, + 113,1,0,0,0,0,115,1,0,0,0,0,117,1,0,0,0,0,119,1,0,0,0,0,121,1,0,0,0,0,123, + 1,0,0,0,0,125,1,0,0,0,0,127,1,0,0,0,0,129,1,0,0,0,0,131,1,0,0,0,0,133,1, + 0,0,0,0,135,1,0,0,0,0,137,1,0,0,0,0,139,1,0,0,0,0,141,1,0,0,0,0,143,1,0, + 0,0,0,145,1,0,0,0,0,147,1,0,0,0,0,149,1,0,0,0,0,151,1,0,0,0,0,153,1,0,0, + 0,1,155,1,0,0,0,3,162,1,0,0,0,5,164,1,0,0,0,7,175,1,0,0,0,9,177,1,0,0,0, + 11,179,1,0,0,0,13,182,1,0,0,0,15,184,1,0,0,0,17,186,1,0,0,0,19,189,1,0, + 0,0,21,191,1,0,0,0,23,200,1,0,0,0,25,202,1,0,0,0,27,204,1,0,0,0,29,213, + 1,0,0,0,31,215,1,0,0,0,33,217,1,0,0,0,35,219,1,0,0,0,37,227,1,0,0,0,39, + 230,1,0,0,0,41,235,1,0,0,0,43,238,1,0,0,0,45,244,1,0,0,0,47,256,1,0,0,0, + 49,260,1,0,0,0,51,262,1,0,0,0,53,264,1,0,0,0,55,275,1,0,0,0,57,282,1,0, + 0,0,59,299,1,0,0,0,61,314,1,0,0,0,63,329,1,0,0,0,65,342,1,0,0,0,67,352, + 1,0,0,0,69,377,1,0,0,0,71,392,1,0,0,0,73,411,1,0,0,0,75,427,1,0,0,0,77, + 438,1,0,0,0,79,446,1,0,0,0,81,453,1,0,0,0,83,460,1,0,0,0,85,462,1,0,0,0, + 87,464,1,0,0,0,89,466,1,0,0,0,91,468,1,0,0,0,93,470,1,0,0,0,95,472,1,0, + 0,0,97,475,1,0,0,0,99,478,1,0,0,0,101,480,1,0,0,0,103,482,1,0,0,0,105,485, + 1,0,0,0,107,488,1,0,0,0,109,497,1,0,0,0,111,501,1,0,0,0,113,506,1,0,0,0, + 115,513,1,0,0,0,117,520,1,0,0,0,119,524,1,0,0,0,121,533,1,0,0,0,123,558, + 1,0,0,0,125,617,1,0,0,0,127,620,1,0,0,0,129,627,1,0,0,0,131,642,1,0,0,0, + 133,658,1,0,0,0,135,660,1,0,0,0,137,687,1,0,0,0,139,689,1,0,0,0,141,698, + 1,0,0,0,143,721,1,0,0,0,145,817,1,0,0,0,147,819,1,0,0,0,149,827,1,0,0,0, + 151,833,1,0,0,0,153,847,1,0,0,0,155,156,5,112,0,0,156,157,5,114,0,0,157, + 158,5,97,0,0,158,159,5,103,0,0,159,160,5,109,0,0,160,161,5,97,0,0,161,2, + 1,0,0,0,162,163,5,59,0,0,163,4,1,0,0,0,164,165,5,99,0,0,165,166,5,97,0, + 0,166,167,5,115,0,0,167,168,5,104,0,0,168,169,5,115,0,0,169,170,5,99,0, + 0,170,171,5,114,0,0,171,172,5,105,0,0,172,173,5,112,0,0,173,174,5,116,0, + 0,174,6,1,0,0,0,175,176,5,94,0,0,176,8,1,0,0,0,177,178,5,126,0,0,178,10, + 1,0,0,0,179,180,5,62,0,0,180,181,5,61,0,0,181,12,1,0,0,0,182,183,5,62,0, + 0,183,14,1,0,0,0,184,185,5,60,0,0,185,16,1,0,0,0,186,187,5,60,0,0,187,188, + 5,61,0,0,188,18,1,0,0,0,189,190,5,61,0,0,190,20,1,0,0,0,191,192,5,99,0, + 0,192,193,5,111,0,0,193,194,5,110,0,0,194,195,5,116,0,0,195,196,5,114,0, + 0,196,197,5,97,0,0,197,198,5,99,0,0,198,199,5,116,0,0,199,22,1,0,0,0,200, + 201,5,123,0,0,201,24,1,0,0,0,202,203,5,125,0,0,203,26,1,0,0,0,204,205,5, + 102,0,0,205,206,5,117,0,0,206,207,5,110,0,0,207,208,5,99,0,0,208,209,5, + 116,0,0,209,210,5,105,0,0,210,211,5,111,0,0,211,212,5,110,0,0,212,28,1, + 0,0,0,213,214,5,40,0,0,214,30,1,0,0,0,215,216,5,44,0,0,216,32,1,0,0,0,217, + 218,5,41,0,0,218,34,1,0,0,0,219,220,5,114,0,0,220,221,5,101,0,0,221,222, + 5,113,0,0,222,223,5,117,0,0,223,224,5,105,0,0,224,225,5,114,0,0,225,226, + 5,101,0,0,226,36,1,0,0,0,227,228,5,105,0,0,228,229,5,102,0,0,229,38,1,0, + 0,0,230,231,5,101,0,0,231,232,5,108,0,0,232,233,5,115,0,0,233,234,5,101, + 0,0,234,40,1,0,0,0,235,236,5,100,0,0,236,237,5,111,0,0,237,42,1,0,0,0,238, + 239,5,119,0,0,239,240,5,104,0,0,240,241,5,105,0,0,241,242,5,108,0,0,242, + 243,5,101,0,0,243,44,1,0,0,0,244,245,5,99,0,0,245,246,5,111,0,0,246,247, + 5,110,0,0,247,248,5,115,0,0,248,249,5,111,0,0,249,250,5,108,0,0,250,251, + 5,101,0,0,251,252,5,46,0,0,252,253,5,108,0,0,253,254,5,111,0,0,254,255, + 5,103,0,0,255,46,1,0,0,0,256,257,5,110,0,0,257,258,5,101,0,0,258,259,5, + 119,0,0,259,48,1,0,0,0,260,261,5,91,0,0,261,50,1,0,0,0,262,263,5,93,0,0, + 263,52,1,0,0,0,264,265,5,116,0,0,265,266,5,120,0,0,266,267,5,46,0,0,267, + 268,5,111,0,0,268,269,5,117,0,0,269,270,5,116,0,0,270,271,5,112,0,0,271, + 272,5,117,0,0,272,273,5,116,0,0,273,274,5,115,0,0,274,54,1,0,0,0,275,276, + 5,46,0,0,276,277,5,118,0,0,277,278,5,97,0,0,278,279,5,108,0,0,279,280,5, + 117,0,0,280,281,5,101,0,0,281,56,1,0,0,0,282,283,5,46,0,0,283,284,5,108, + 0,0,284,285,5,111,0,0,285,286,5,99,0,0,286,287,5,107,0,0,287,288,5,105, + 0,0,288,289,5,110,0,0,289,290,5,103,0,0,290,291,5,66,0,0,291,292,5,121, + 0,0,292,293,5,116,0,0,293,294,5,101,0,0,294,295,5,99,0,0,295,296,5,111, + 0,0,296,297,5,100,0,0,297,298,5,101,0,0,298,58,1,0,0,0,299,300,5,46,0,0, + 300,301,5,116,0,0,301,302,5,111,0,0,302,303,5,107,0,0,303,304,5,101,0,0, + 304,305,5,110,0,0,305,306,5,67,0,0,306,307,5,97,0,0,307,308,5,116,0,0,308, + 309,5,101,0,0,309,310,5,103,0,0,310,311,5,111,0,0,311,312,5,114,0,0,312, + 313,5,121,0,0,313,60,1,0,0,0,314,315,5,46,0,0,315,316,5,110,0,0,316,317, + 5,102,0,0,317,318,5,116,0,0,318,319,5,67,0,0,319,320,5,111,0,0,320,321, + 5,109,0,0,321,322,5,109,0,0,322,323,5,105,0,0,323,324,5,116,0,0,324,325, + 5,109,0,0,325,326,5,101,0,0,326,327,5,110,0,0,327,328,5,116,0,0,328,62, + 1,0,0,0,329,330,5,46,0,0,330,331,5,116,0,0,331,332,5,111,0,0,332,333,5, + 107,0,0,333,334,5,101,0,0,334,335,5,110,0,0,335,336,5,65,0,0,336,337,5, + 109,0,0,337,338,5,111,0,0,338,339,5,117,0,0,339,340,5,110,0,0,340,341,5, + 116,0,0,341,64,1,0,0,0,342,343,5,116,0,0,343,344,5,120,0,0,344,345,5,46, + 0,0,345,346,5,105,0,0,346,347,5,110,0,0,347,348,5,112,0,0,348,349,5,117, + 0,0,349,350,5,116,0,0,350,351,5,115,0,0,351,66,1,0,0,0,352,353,5,46,0,0, + 353,354,5,111,0,0,354,355,5,117,0,0,355,356,5,116,0,0,356,357,5,112,0,0, + 357,358,5,111,0,0,358,359,5,105,0,0,359,360,5,110,0,0,360,361,5,116,0,0, + 361,362,5,84,0,0,362,363,5,114,0,0,363,364,5,97,0,0,364,365,5,110,0,0,365, + 366,5,115,0,0,366,367,5,97,0,0,367,368,5,99,0,0,368,369,5,116,0,0,369,370, + 5,105,0,0,370,371,5,111,0,0,371,372,5,110,0,0,372,373,5,72,0,0,373,374, + 5,97,0,0,374,375,5,115,0,0,375,376,5,104,0,0,376,68,1,0,0,0,377,378,5,46, + 0,0,378,379,5,111,0,0,379,380,5,117,0,0,380,381,5,116,0,0,381,382,5,112, + 0,0,382,383,5,111,0,0,383,384,5,105,0,0,384,385,5,110,0,0,385,386,5,116, + 0,0,386,387,5,73,0,0,387,388,5,110,0,0,388,389,5,100,0,0,389,390,5,101, + 0,0,390,391,5,120,0,0,391,70,1,0,0,0,392,393,5,46,0,0,393,394,5,117,0,0, + 394,395,5,110,0,0,395,396,5,108,0,0,396,397,5,111,0,0,397,398,5,99,0,0, + 398,399,5,107,0,0,399,400,5,105,0,0,400,401,5,110,0,0,401,402,5,103,0,0, + 402,403,5,66,0,0,403,404,5,121,0,0,404,405,5,116,0,0,405,406,5,101,0,0, + 406,407,5,99,0,0,407,408,5,111,0,0,408,409,5,100,0,0,409,410,5,101,0,0, + 410,72,1,0,0,0,411,412,5,46,0,0,412,413,5,115,0,0,413,414,5,101,0,0,414, + 415,5,113,0,0,415,416,5,117,0,0,416,417,5,101,0,0,417,418,5,110,0,0,418, + 419,5,99,0,0,419,420,5,101,0,0,420,421,5,78,0,0,421,422,5,117,0,0,422,423, + 5,109,0,0,423,424,5,98,0,0,424,425,5,101,0,0,425,426,5,114,0,0,426,74,1, + 0,0,0,427,428,5,46,0,0,428,429,5,114,0,0,429,430,5,101,0,0,430,431,5,118, + 0,0,431,432,5,101,0,0,432,433,5,114,0,0,433,434,5,115,0,0,434,435,5,101, + 0,0,435,436,5,40,0,0,436,437,5,41,0,0,437,76,1,0,0,0,438,439,5,46,0,0,439, + 440,5,108,0,0,440,441,5,101,0,0,441,442,5,110,0,0,442,443,5,103,0,0,443, + 444,5,116,0,0,444,445,5,104,0,0,445,78,1,0,0,0,446,447,5,46,0,0,447,448, + 5,115,0,0,448,449,5,112,0,0,449,450,5,108,0,0,450,451,5,105,0,0,451,452, + 5,116,0,0,452,80,1,0,0,0,453,454,5,46,0,0,454,455,5,115,0,0,455,456,5,108, + 0,0,456,457,5,105,0,0,457,458,5,99,0,0,458,459,5,101,0,0,459,82,1,0,0,0, + 460,461,5,33,0,0,461,84,1,0,0,0,462,463,5,45,0,0,463,86,1,0,0,0,464,465, + 5,42,0,0,465,88,1,0,0,0,466,467,5,47,0,0,467,90,1,0,0,0,468,469,5,37,0, + 0,469,92,1,0,0,0,470,471,5,43,0,0,471,94,1,0,0,0,472,473,5,61,0,0,473,474, + 5,61,0,0,474,96,1,0,0,0,475,476,5,33,0,0,476,477,5,61,0,0,477,98,1,0,0, + 0,478,479,5,38,0,0,479,100,1,0,0,0,480,481,5,124,0,0,481,102,1,0,0,0,482, + 483,5,38,0,0,483,484,5,38,0,0,484,104,1,0,0,0,485,486,5,124,0,0,486,487, + 5,124,0,0,487,106,1,0,0,0,488,489,5,99,0,0,489,490,5,111,0,0,490,491,5, + 110,0,0,491,492,5,115,0,0,492,493,5,116,0,0,493,494,5,97,0,0,494,495,5, + 110,0,0,495,496,5,116,0,0,496,108,1,0,0,0,497,498,5,105,0,0,498,499,5,110, + 0,0,499,500,5,116,0,0,500,110,1,0,0,0,501,502,5,98,0,0,502,503,5,111,0, + 0,503,504,5,111,0,0,504,505,5,108,0,0,505,112,1,0,0,0,506,507,5,115,0,0, + 507,508,5,116,0,0,508,509,5,114,0,0,509,510,5,105,0,0,510,511,5,110,0,0, + 511,512,5,103,0,0,512,114,1,0,0,0,513,514,5,112,0,0,514,515,5,117,0,0,515, + 516,5,98,0,0,516,517,5,107,0,0,517,518,5,101,0,0,518,519,5,121,0,0,519, + 116,1,0,0,0,520,521,5,115,0,0,521,522,5,105,0,0,522,523,5,103,0,0,523,118, + 1,0,0,0,524,525,5,100,0,0,525,526,5,97,0,0,526,527,5,116,0,0,527,528,5, + 97,0,0,528,529,5,115,0,0,529,530,5,105,0,0,530,531,5,103,0,0,531,120,1, + 0,0,0,532,534,7,0,0,0,533,532,1,0,0,0,534,535,1,0,0,0,535,533,1,0,0,0,535, + 536,1,0,0,0,536,537,1,0,0,0,537,539,5,46,0,0,538,540,7,0,0,0,539,538,1, + 0,0,0,540,541,1,0,0,0,541,539,1,0,0,0,541,542,1,0,0,0,542,543,1,0,0,0,543, + 545,5,46,0,0,544,546,7,0,0,0,545,544,1,0,0,0,546,547,1,0,0,0,547,545,1, + 0,0,0,547,548,1,0,0,0,548,122,1,0,0,0,549,550,5,116,0,0,550,551,5,114,0, + 0,551,552,5,117,0,0,552,559,5,101,0,0,553,554,5,102,0,0,554,555,5,97,0, + 0,555,556,5,108,0,0,556,557,5,115,0,0,557,559,5,101,0,0,558,549,1,0,0,0, + 558,553,1,0,0,0,559,124,1,0,0,0,560,561,5,115,0,0,561,562,5,97,0,0,562, + 563,5,116,0,0,563,564,5,111,0,0,564,565,5,115,0,0,565,566,5,104,0,0,566, + 567,5,105,0,0,567,618,5,115,0,0,568,569,5,115,0,0,569,570,5,97,0,0,570, + 571,5,116,0,0,571,618,5,115,0,0,572,573,5,102,0,0,573,574,5,105,0,0,574, + 575,5,110,0,0,575,576,5,110,0,0,576,577,5,101,0,0,577,618,5,121,0,0,578, + 579,5,98,0,0,579,580,5,105,0,0,580,581,5,116,0,0,581,618,5,115,0,0,582, + 583,5,98,0,0,583,584,5,105,0,0,584,585,5,116,0,0,585,586,5,99,0,0,586,587, + 5,111,0,0,587,588,5,105,0,0,588,618,5,110,0,0,589,590,5,115,0,0,590,591, + 5,101,0,0,591,592,5,99,0,0,592,593,5,111,0,0,593,594,5,110,0,0,594,595, + 5,100,0,0,595,618,5,115,0,0,596,597,5,109,0,0,597,598,5,105,0,0,598,599, + 5,110,0,0,599,600,5,117,0,0,600,601,5,116,0,0,601,602,5,101,0,0,602,618, + 5,115,0,0,603,604,5,104,0,0,604,605,5,111,0,0,605,606,5,117,0,0,606,607, + 5,114,0,0,607,618,5,115,0,0,608,609,5,100,0,0,609,610,5,97,0,0,610,611, + 5,121,0,0,611,618,5,115,0,0,612,613,5,119,0,0,613,614,5,101,0,0,614,615, + 5,101,0,0,615,616,5,107,0,0,616,618,5,115,0,0,617,560,1,0,0,0,617,568,1, + 0,0,0,617,572,1,0,0,0,617,578,1,0,0,0,617,582,1,0,0,0,617,589,1,0,0,0,617, + 596,1,0,0,0,617,603,1,0,0,0,617,608,1,0,0,0,617,612,1,0,0,0,618,126,1,0, + 0,0,619,621,5,45,0,0,620,619,1,0,0,0,620,621,1,0,0,0,621,622,1,0,0,0,622, + 624,3,129,64,0,623,625,3,131,65,0,624,623,1,0,0,0,624,625,1,0,0,0,625,128, + 1,0,0,0,626,628,7,0,0,0,627,626,1,0,0,0,628,629,1,0,0,0,629,627,1,0,0,0, + 629,630,1,0,0,0,630,639,1,0,0,0,631,633,5,95,0,0,632,634,7,0,0,0,633,632, + 1,0,0,0,634,635,1,0,0,0,635,633,1,0,0,0,635,636,1,0,0,0,636,638,1,0,0,0, + 637,631,1,0,0,0,638,641,1,0,0,0,639,637,1,0,0,0,639,640,1,0,0,0,640,130, + 1,0,0,0,641,639,1,0,0,0,642,643,7,1,0,0,643,644,3,129,64,0,644,132,1,0, + 0,0,645,646,5,98,0,0,646,647,5,121,0,0,647,648,5,116,0,0,648,649,5,101, + 0,0,649,650,5,115,0,0,650,652,1,0,0,0,651,653,3,135,67,0,652,651,1,0,0, + 0,652,653,1,0,0,0,653,659,1,0,0,0,654,655,5,98,0,0,655,656,5,121,0,0,656, + 657,5,116,0,0,657,659,5,101,0,0,658,645,1,0,0,0,658,654,1,0,0,0,659,134, + 1,0,0,0,660,664,7,2,0,0,661,663,7,0,0,0,662,661,1,0,0,0,663,666,1,0,0,0, + 664,662,1,0,0,0,664,665,1,0,0,0,665,136,1,0,0,0,666,664,1,0,0,0,667,673, + 5,34,0,0,668,669,5,92,0,0,669,672,5,34,0,0,670,672,8,3,0,0,671,668,1,0, + 0,0,671,670,1,0,0,0,672,675,1,0,0,0,673,674,1,0,0,0,673,671,1,0,0,0,674, + 676,1,0,0,0,675,673,1,0,0,0,676,688,5,34,0,0,677,683,5,39,0,0,678,679,5, + 92,0,0,679,682,5,39,0,0,680,682,8,4,0,0,681,678,1,0,0,0,681,680,1,0,0,0, + 682,685,1,0,0,0,683,684,1,0,0,0,683,681,1,0,0,0,684,686,1,0,0,0,685,683, + 1,0,0,0,686,688,5,39,0,0,687,667,1,0,0,0,687,677,1,0,0,0,688,138,1,0,0, + 0,689,690,5,100,0,0,690,691,5,97,0,0,691,692,5,116,0,0,692,693,5,101,0, + 0,693,694,5,40,0,0,694,695,1,0,0,0,695,696,3,137,68,0,696,697,5,41,0,0, + 697,140,1,0,0,0,698,699,5,48,0,0,699,703,7,5,0,0,700,702,7,6,0,0,701,700, + 1,0,0,0,702,705,1,0,0,0,703,701,1,0,0,0,703,704,1,0,0,0,704,142,1,0,0,0, + 705,703,1,0,0,0,706,707,5,116,0,0,707,708,5,104,0,0,708,709,5,105,0,0,709, + 710,5,115,0,0,710,711,5,46,0,0,711,712,5,97,0,0,712,713,5,103,0,0,713,722, + 5,101,0,0,714,715,5,116,0,0,715,716,5,120,0,0,716,717,5,46,0,0,717,718, + 5,116,0,0,718,719,5,105,0,0,719,720,5,109,0,0,720,722,5,101,0,0,721,706, + 1,0,0,0,721,714,1,0,0,0,722,144,1,0,0,0,723,724,5,116,0,0,724,725,5,104, + 0,0,725,726,5,105,0,0,726,727,5,115,0,0,727,728,5,46,0,0,728,729,5,97,0, + 0,729,730,5,99,0,0,730,731,5,116,0,0,731,732,5,105,0,0,732,733,5,118,0, + 0,733,734,5,101,0,0,734,735,5,73,0,0,735,736,5,110,0,0,736,737,5,112,0, + 0,737,738,5,117,0,0,738,739,5,116,0,0,739,740,5,73,0,0,740,741,5,110,0, + 0,741,742,5,100,0,0,742,743,5,101,0,0,743,818,5,120,0,0,744,745,5,116,0, + 0,745,746,5,104,0,0,746,747,5,105,0,0,747,748,5,115,0,0,748,749,5,46,0, + 0,749,750,5,97,0,0,750,751,5,99,0,0,751,752,5,116,0,0,752,753,5,105,0,0, + 753,754,5,118,0,0,754,755,5,101,0,0,755,756,5,66,0,0,756,757,5,121,0,0, + 757,758,5,116,0,0,758,759,5,101,0,0,759,760,5,99,0,0,760,761,5,111,0,0, + 761,762,5,100,0,0,762,818,5,101,0,0,763,764,5,116,0,0,764,765,5,120,0,0, + 765,766,5,46,0,0,766,767,5,105,0,0,767,768,5,110,0,0,768,769,5,112,0,0, + 769,770,5,117,0,0,770,771,5,116,0,0,771,772,5,115,0,0,772,773,5,46,0,0, + 773,774,5,108,0,0,774,775,5,101,0,0,775,776,5,110,0,0,776,777,5,103,0,0, + 777,778,5,116,0,0,778,818,5,104,0,0,779,780,5,116,0,0,780,781,5,120,0,0, + 781,782,5,46,0,0,782,783,5,111,0,0,783,784,5,117,0,0,784,785,5,116,0,0, + 785,786,5,112,0,0,786,787,5,117,0,0,787,788,5,116,0,0,788,789,5,115,0,0, + 789,790,5,46,0,0,790,791,5,108,0,0,791,792,5,101,0,0,792,793,5,110,0,0, + 793,794,5,103,0,0,794,795,5,116,0,0,795,818,5,104,0,0,796,797,5,116,0,0, + 797,798,5,120,0,0,798,799,5,46,0,0,799,800,5,118,0,0,800,801,5,101,0,0, + 801,802,5,114,0,0,802,803,5,115,0,0,803,804,5,105,0,0,804,805,5,111,0,0, + 805,818,5,110,0,0,806,807,5,116,0,0,807,808,5,120,0,0,808,809,5,46,0,0, + 809,810,5,108,0,0,810,811,5,111,0,0,811,812,5,99,0,0,812,813,5,107,0,0, + 813,814,5,116,0,0,814,815,5,105,0,0,815,816,5,109,0,0,816,818,5,101,0,0, + 817,723,1,0,0,0,817,744,1,0,0,0,817,763,1,0,0,0,817,779,1,0,0,0,817,796, + 1,0,0,0,817,806,1,0,0,0,818,146,1,0,0,0,819,823,7,7,0,0,820,822,7,8,0,0, + 821,820,1,0,0,0,822,825,1,0,0,0,823,821,1,0,0,0,823,824,1,0,0,0,824,148, + 1,0,0,0,825,823,1,0,0,0,826,828,7,9,0,0,827,826,1,0,0,0,828,829,1,0,0,0, + 829,827,1,0,0,0,829,830,1,0,0,0,830,831,1,0,0,0,831,832,6,74,0,0,832,150, + 1,0,0,0,833,834,5,47,0,0,834,835,5,42,0,0,835,839,1,0,0,0,836,838,9,0,0, + 0,837,836,1,0,0,0,838,841,1,0,0,0,839,840,1,0,0,0,839,837,1,0,0,0,840,842, + 1,0,0,0,841,839,1,0,0,0,842,843,5,42,0,0,843,844,5,47,0,0,844,845,1,0,0, + 0,845,846,6,75,1,0,846,152,1,0,0,0,847,848,5,47,0,0,848,849,5,47,0,0,849, + 853,1,0,0,0,850,852,8,10,0,0,851,850,1,0,0,0,852,855,1,0,0,0,853,851,1, + 0,0,0,853,854,1,0,0,0,854,856,1,0,0,0,855,853,1,0,0,0,856,857,6,76,1,0, + 857,154,1,0,0,0,26,0,535,541,547,558,617,620,624,629,635,639,652,658,664, + 671,673,681,683,687,703,721,817,823,829,839,853,2,6,0,0,0,1,0]; private static __ATN: ATN; public static get _ATN(): ATN { diff --git a/packages/cashc/src/grammar/CashScriptParser.ts b/packages/cashc/src/grammar/CashScriptParser.ts index 24ec7f97..292d7ec3 100644 --- a/packages/cashc/src/grammar/CashScriptParser.ts +++ b/packages/cashc/src/grammar/CashScriptParser.ts @@ -76,23 +76,25 @@ export default class CashScriptParser extends Parser { public static readonly T__55 = 56; public static readonly T__56 = 57; public static readonly T__57 = 58; - public static readonly VersionLiteral = 59; - public static readonly BooleanLiteral = 60; - public static readonly NumberUnit = 61; - public static readonly NumberLiteral = 62; - public static readonly NumberPart = 63; - public static readonly ExponentPart = 64; - public static readonly Bytes = 65; - public static readonly Bound = 66; - public static readonly StringLiteral = 67; - public static readonly DateLiteral = 68; - public static readonly HexLiteral = 69; - public static readonly TxVar = 70; - public static readonly NullaryOp = 71; - public static readonly Identifier = 72; - public static readonly WHITESPACE = 73; - public static readonly COMMENT = 74; - public static readonly LINE_COMMENT = 75; + public static readonly T__58 = 59; + public static readonly T__59 = 60; + public static readonly VersionLiteral = 61; + public static readonly BooleanLiteral = 62; + public static readonly NumberUnit = 63; + public static readonly NumberLiteral = 64; + public static readonly NumberPart = 65; + public static readonly ExponentPart = 66; + public static readonly Bytes = 67; + public static readonly Bound = 68; + public static readonly StringLiteral = 69; + public static readonly DateLiteral = 70; + public static readonly HexLiteral = 71; + public static readonly TxVar = 72; + public static readonly NullaryOp = 73; + public static readonly Identifier = 74; + public static readonly WHITESPACE = 75; + public static readonly COMMENT = 76; + public static readonly LINE_COMMENT = 77; public static readonly EOF = Token.EOF; public static readonly RULE_sourceFile = 0; public static readonly RULE_pragmaDirective = 1; @@ -112,17 +114,19 @@ export default class CashScriptParser extends Parser { public static readonly RULE_timeOpStatement = 15; public static readonly RULE_requireStatement = 16; public static readonly RULE_ifStatement = 17; - public static readonly RULE_consoleStatement = 18; - public static readonly RULE_requireMessage = 19; - public static readonly RULE_consoleParameter = 20; - public static readonly RULE_consoleParameterList = 21; - public static readonly RULE_functionCall = 22; - public static readonly RULE_expressionList = 23; - public static readonly RULE_expression = 24; - public static readonly RULE_modifier = 25; - public static readonly RULE_literal = 26; - public static readonly RULE_numberLiteral = 27; - public static readonly RULE_typeName = 28; + public static readonly RULE_loopStatement = 18; + public static readonly RULE_doWhileStatement = 19; + public static readonly RULE_consoleStatement = 20; + public static readonly RULE_requireMessage = 21; + public static readonly RULE_consoleParameter = 22; + public static readonly RULE_consoleParameterList = 23; + public static readonly RULE_functionCall = 24; + public static readonly RULE_expressionList = 25; + public static readonly RULE_expression = 26; + public static readonly RULE_modifier = 27; + public static readonly RULE_literal = 28; + public static readonly RULE_numberLiteral = 29; + public static readonly RULE_typeName = 30; public static readonly literalNames: (string | null)[] = [ null, "'pragma'", "';'", "'cashscript'", "'^'", "'~'", @@ -134,6 +138,7 @@ export default class CashScriptParser extends Parser { "'('", "','", "')'", "'require'", "'if'", "'else'", + "'do'", "'while'", "'console.log'", "'new'", "'['", "']'", "'tx.outputs'", @@ -191,6 +196,7 @@ export default class CashScriptParser extends Parser { null, null, null, null, null, null, + null, null, null, "VersionLiteral", "BooleanLiteral", "NumberUnit", @@ -212,9 +218,9 @@ export default class CashScriptParser extends Parser { "versionOperator", "contractDefinition", "functionDefinition", "parameterList", "parameter", "block", "statement", "variableDefinition", "tupleAssignment", "assignStatement", "timeOpStatement", "requireStatement", "ifStatement", - "consoleStatement", "requireMessage", "consoleParameter", "consoleParameterList", - "functionCall", "expressionList", "expression", "modifier", "literal", - "numberLiteral", "typeName", + "loopStatement", "doWhileStatement", "consoleStatement", "requireMessage", + "consoleParameter", "consoleParameterList", "functionCall", "expressionList", + "expression", "modifier", "literal", "numberLiteral", "typeName", ]; public get grammarFileName(): string { return "CashScript.g4"; } public get literalNames(): (string | null)[] { return CashScriptParser.literalNames; } @@ -238,23 +244,23 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 61; + this.state = 65; this._errHandler.sync(this); _la = this._input.LA(1); while (_la===1) { { { - this.state = 58; + this.state = 62; this.pragmaDirective(); } } - this.state = 63; + this.state = 67; this._errHandler.sync(this); _la = this._input.LA(1); } - this.state = 64; + this.state = 68; this.contractDefinition(); - this.state = 65; + this.state = 69; this.match(CashScriptParser.EOF); } } @@ -279,13 +285,13 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 67; + this.state = 71; this.match(CashScriptParser.T__0); - this.state = 68; + this.state = 72; this.pragmaName(); - this.state = 69; + this.state = 73; this.pragmaValue(); - this.state = 70; + this.state = 74; this.match(CashScriptParser.T__1); } } @@ -310,7 +316,7 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 72; + this.state = 76; this.match(CashScriptParser.T__2); } } @@ -336,14 +342,14 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 74; + this.state = 78; this.versionConstraint(); - this.state = 76; + this.state = 80; this._errHandler.sync(this); _la = this._input.LA(1); - if ((((_la) & ~0x1F) === 0 && ((1 << _la) & 2032) !== 0) || _la===59) { + if ((((_la) & ~0x1F) === 0 && ((1 << _la) & 2032) !== 0) || _la===61) { { - this.state = 75; + this.state = 79; this.versionConstraint(); } } @@ -372,17 +378,17 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 79; + this.state = 83; this._errHandler.sync(this); _la = this._input.LA(1); if ((((_la) & ~0x1F) === 0 && ((1 << _la) & 2032) !== 0)) { { - this.state = 78; + this.state = 82; this.versionOperator(); } } - this.state = 81; + this.state = 85; this.match(CashScriptParser.VersionLiteral); } } @@ -408,7 +414,7 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 83; + this.state = 87; _la = this._input.LA(1); if(!((((_la) & ~0x1F) === 0 && ((1 << _la) & 2032) !== 0))) { this._errHandler.recoverInline(this); @@ -441,29 +447,29 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 85; + this.state = 89; this.match(CashScriptParser.T__10); - this.state = 86; + this.state = 90; this.match(CashScriptParser.Identifier); - this.state = 87; + this.state = 91; this.parameterList(); - this.state = 88; - this.match(CashScriptParser.T__11); this.state = 92; + this.match(CashScriptParser.T__11); + this.state = 96; this._errHandler.sync(this); _la = this._input.LA(1); while (_la===14) { { { - this.state = 89; + this.state = 93; this.functionDefinition(); } } - this.state = 94; + this.state = 98; this._errHandler.sync(this); _la = this._input.LA(1); } - this.state = 95; + this.state = 99; this.match(CashScriptParser.T__12); } } @@ -489,29 +495,29 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 97; + this.state = 101; this.match(CashScriptParser.T__13); - this.state = 98; + this.state = 102; this.match(CashScriptParser.Identifier); - this.state = 99; + this.state = 103; this.parameterList(); - this.state = 100; - this.match(CashScriptParser.T__11); this.state = 104; + this.match(CashScriptParser.T__11); + this.state = 108; this._errHandler.sync(this); _la = this._input.LA(1); - while ((((_la) & ~0x1F) === 0 && ((1 << _la) & 2883584) !== 0) || ((((_la - 53)) & ~0x1F) === 0 && ((1 << (_la - 53)) & 528447) !== 0)) { + while ((((_la) & ~0x1F) === 0 && ((1 << _la) & 11272192) !== 0) || ((((_la - 55)) & ~0x1F) === 0 && ((1 << (_la - 55)) & 528447) !== 0)) { { { - this.state = 101; + this.state = 105; this.statement(); } } - this.state = 106; + this.state = 110; this._errHandler.sync(this); _la = this._input.LA(1); } - this.state = 107; + this.state = 111; this.match(CashScriptParser.T__12); } } @@ -538,39 +544,39 @@ export default class CashScriptParser extends Parser { let _alt: number; this.enterOuterAlt(localctx, 1); { - this.state = 109; + this.state = 113; this.match(CashScriptParser.T__14); - this.state = 121; + this.state = 125; this._errHandler.sync(this); _la = this._input.LA(1); - if (((((_la - 53)) & ~0x1F) === 0 && ((1 << (_la - 53)) & 4159) !== 0)) { + if (((((_la - 55)) & ~0x1F) === 0 && ((1 << (_la - 55)) & 4159) !== 0)) { { - this.state = 110; + this.state = 114; this.parameter(); - this.state = 115; + this.state = 119; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 5, this._ctx); while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) { if (_alt === 1) { { { - this.state = 111; + this.state = 115; this.match(CashScriptParser.T__15); - this.state = 112; + this.state = 116; this.parameter(); } } } - this.state = 117; + this.state = 121; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 5, this._ctx); } - this.state = 119; + this.state = 123; this._errHandler.sync(this); _la = this._input.LA(1); if (_la===16) { { - this.state = 118; + this.state = 122; this.match(CashScriptParser.T__15); } } @@ -578,7 +584,7 @@ export default class CashScriptParser extends Parser { } } - this.state = 123; + this.state = 127; this.match(CashScriptParser.T__16); } } @@ -603,9 +609,9 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 125; + this.state = 129; this.typeName(); - this.state = 126; + this.state = 130; this.match(CashScriptParser.Identifier); } } @@ -629,46 +635,47 @@ export default class CashScriptParser extends Parser { this.enterRule(localctx, 20, CashScriptParser.RULE_block); let _la: number; try { - this.state = 137; + this.state = 141; this._errHandler.sync(this); switch (this._input.LA(1)) { case 12: this.enterOuterAlt(localctx, 1); { - this.state = 128; - this.match(CashScriptParser.T__11); this.state = 132; + this.match(CashScriptParser.T__11); + this.state = 136; this._errHandler.sync(this); _la = this._input.LA(1); - while ((((_la) & ~0x1F) === 0 && ((1 << _la) & 2883584) !== 0) || ((((_la - 53)) & ~0x1F) === 0 && ((1 << (_la - 53)) & 528447) !== 0)) { + while ((((_la) & ~0x1F) === 0 && ((1 << _la) & 11272192) !== 0) || ((((_la - 55)) & ~0x1F) === 0 && ((1 << (_la - 55)) & 528447) !== 0)) { { { - this.state = 129; + this.state = 133; this.statement(); } } - this.state = 134; + this.state = 138; this._errHandler.sync(this); _la = this._input.LA(1); } - this.state = 135; + this.state = 139; this.match(CashScriptParser.T__12); } break; case 18: case 19: case 21: - case 53: - case 54: + case 23: case 55: case 56: case 57: case 58: - case 65: - case 72: + case 59: + case 60: + case 67: + case 74: this.enterOuterAlt(localctx, 2); { - this.state = 136; + this.state = 140; this.statement(); } break; @@ -695,55 +702,62 @@ export default class CashScriptParser extends Parser { let localctx: StatementContext = new StatementContext(this, this._ctx, this.state); this.enterRule(localctx, 22, CashScriptParser.RULE_statement); try { - this.state = 146; + this.state = 151; this._errHandler.sync(this); switch ( this._interp.adaptivePredict(this._input, 10, this._ctx) ) { case 1: this.enterOuterAlt(localctx, 1); { - this.state = 139; + this.state = 143; this.variableDefinition(); } break; case 2: this.enterOuterAlt(localctx, 2); { - this.state = 140; + this.state = 144; this.tupleAssignment(); } break; case 3: this.enterOuterAlt(localctx, 3); { - this.state = 141; + this.state = 145; this.assignStatement(); } break; case 4: this.enterOuterAlt(localctx, 4); { - this.state = 142; + this.state = 146; this.timeOpStatement(); } break; case 5: this.enterOuterAlt(localctx, 5); { - this.state = 143; + this.state = 147; this.requireStatement(); } break; case 6: this.enterOuterAlt(localctx, 6); { - this.state = 144; + this.state = 148; this.ifStatement(); } break; case 7: this.enterOuterAlt(localctx, 7); { - this.state = 145; + this.state = 149; + this.loopStatement(); + } + break; + case 8: + this.enterOuterAlt(localctx, 8); + { + this.state = 150; this.consoleStatement(); } break; @@ -771,29 +785,29 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 148; + this.state = 153; this.typeName(); - this.state = 152; + this.state = 157; this._errHandler.sync(this); _la = this._input.LA(1); - while (_la===52) { + while (_la===54) { { { - this.state = 149; + this.state = 154; this.modifier(); } } - this.state = 154; + this.state = 159; this._errHandler.sync(this); _la = this._input.LA(1); } - this.state = 155; + this.state = 160; this.match(CashScriptParser.Identifier); - this.state = 156; + this.state = 161; this.match(CashScriptParser.T__9); - this.state = 157; + this.state = 162; this.expression(0); - this.state = 158; + this.state = 163; this.match(CashScriptParser.T__1); } } @@ -818,21 +832,21 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 160; + this.state = 165; this.typeName(); - this.state = 161; + this.state = 166; this.match(CashScriptParser.Identifier); - this.state = 162; + this.state = 167; this.match(CashScriptParser.T__15); - this.state = 163; + this.state = 168; this.typeName(); - this.state = 164; + this.state = 169; this.match(CashScriptParser.Identifier); - this.state = 165; + this.state = 170; this.match(CashScriptParser.T__9); - this.state = 166; + this.state = 171; this.expression(0); - this.state = 167; + this.state = 172; this.match(CashScriptParser.T__1); } } @@ -857,13 +871,13 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 169; + this.state = 174; this.match(CashScriptParser.Identifier); - this.state = 170; + this.state = 175; this.match(CashScriptParser.T__9); - this.state = 171; + this.state = 176; this.expression(0); - this.state = 172; + this.state = 177; this.match(CashScriptParser.T__1); } } @@ -889,31 +903,31 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 174; + this.state = 179; this.match(CashScriptParser.T__17); - this.state = 175; + this.state = 180; this.match(CashScriptParser.T__14); - this.state = 176; + this.state = 181; this.match(CashScriptParser.TxVar); - this.state = 177; + this.state = 182; this.match(CashScriptParser.T__5); - this.state = 178; + this.state = 183; this.expression(0); - this.state = 181; + this.state = 186; this._errHandler.sync(this); _la = this._input.LA(1); if (_la===16) { { - this.state = 179; + this.state = 184; this.match(CashScriptParser.T__15); - this.state = 180; + this.state = 185; this.requireMessage(); } } - this.state = 183; + this.state = 188; this.match(CashScriptParser.T__16); - this.state = 184; + this.state = 189; this.match(CashScriptParser.T__1); } } @@ -939,27 +953,27 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 186; + this.state = 191; this.match(CashScriptParser.T__17); - this.state = 187; + this.state = 192; this.match(CashScriptParser.T__14); - this.state = 188; + this.state = 193; this.expression(0); - this.state = 191; + this.state = 196; this._errHandler.sync(this); _la = this._input.LA(1); if (_la===16) { { - this.state = 189; + this.state = 194; this.match(CashScriptParser.T__15); - this.state = 190; + this.state = 195; this.requireMessage(); } } - this.state = 193; + this.state = 198; this.match(CashScriptParser.T__16); - this.state = 194; + this.state = 199; this.match(CashScriptParser.T__1); } } @@ -984,24 +998,24 @@ export default class CashScriptParser extends Parser { try { this.enterOuterAlt(localctx, 1); { - this.state = 196; + this.state = 201; this.match(CashScriptParser.T__18); - this.state = 197; + this.state = 202; this.match(CashScriptParser.T__14); - this.state = 198; + this.state = 203; this.expression(0); - this.state = 199; + this.state = 204; this.match(CashScriptParser.T__16); - this.state = 200; + this.state = 205; localctx._ifBlock = this.block(); - this.state = 203; + this.state = 208; this._errHandler.sync(this); switch ( this._interp.adaptivePredict(this._input, 14, this._ctx) ) { case 1: { - this.state = 201; + this.state = 206; this.match(CashScriptParser.T__19); - this.state = 202; + this.state = 207; localctx._elseBlock = this.block(); } break; @@ -1023,17 +1037,79 @@ export default class CashScriptParser extends Parser { return localctx; } // @RuleVersion(0) + public loopStatement(): LoopStatementContext { + let localctx: LoopStatementContext = new LoopStatementContext(this, this._ctx, this.state); + this.enterRule(localctx, 36, CashScriptParser.RULE_loopStatement); + try { + this.enterOuterAlt(localctx, 1); + { + this.state = 210; + this.doWhileStatement(); + } + } + catch (re) { + if (re instanceof RecognitionException) { + localctx.exception = re; + this._errHandler.reportError(this, re); + this._errHandler.recover(this, re); + } else { + throw re; + } + } + finally { + this.exitRule(); + } + return localctx; + } + // @RuleVersion(0) + public doWhileStatement(): DoWhileStatementContext { + let localctx: DoWhileStatementContext = new DoWhileStatementContext(this, this._ctx, this.state); + this.enterRule(localctx, 38, CashScriptParser.RULE_doWhileStatement); + try { + this.enterOuterAlt(localctx, 1); + { + this.state = 212; + this.match(CashScriptParser.T__20); + this.state = 213; + this.block(); + this.state = 214; + this.match(CashScriptParser.T__21); + this.state = 215; + this.match(CashScriptParser.T__14); + this.state = 216; + this.expression(0); + this.state = 217; + this.match(CashScriptParser.T__16); + this.state = 218; + this.match(CashScriptParser.T__1); + } + } + catch (re) { + if (re instanceof RecognitionException) { + localctx.exception = re; + this._errHandler.reportError(this, re); + this._errHandler.recover(this, re); + } else { + throw re; + } + } + finally { + this.exitRule(); + } + return localctx; + } + // @RuleVersion(0) public consoleStatement(): ConsoleStatementContext { let localctx: ConsoleStatementContext = new ConsoleStatementContext(this, this._ctx, this.state); - this.enterRule(localctx, 36, CashScriptParser.RULE_consoleStatement); + this.enterRule(localctx, 40, CashScriptParser.RULE_consoleStatement); try { this.enterOuterAlt(localctx, 1); { - this.state = 205; - this.match(CashScriptParser.T__20); - this.state = 206; + this.state = 220; + this.match(CashScriptParser.T__22); + this.state = 221; this.consoleParameterList(); - this.state = 207; + this.state = 222; this.match(CashScriptParser.T__1); } } @@ -1054,11 +1130,11 @@ export default class CashScriptParser extends Parser { // @RuleVersion(0) public requireMessage(): RequireMessageContext { let localctx: RequireMessageContext = new RequireMessageContext(this, this._ctx, this.state); - this.enterRule(localctx, 38, CashScriptParser.RULE_requireMessage); + this.enterRule(localctx, 42, CashScriptParser.RULE_requireMessage); try { this.enterOuterAlt(localctx, 1); { - this.state = 209; + this.state = 224; this.match(CashScriptParser.StringLiteral); } } @@ -1079,26 +1155,26 @@ export default class CashScriptParser extends Parser { // @RuleVersion(0) public consoleParameter(): ConsoleParameterContext { let localctx: ConsoleParameterContext = new ConsoleParameterContext(this, this._ctx, this.state); - this.enterRule(localctx, 40, CashScriptParser.RULE_consoleParameter); + this.enterRule(localctx, 44, CashScriptParser.RULE_consoleParameter); try { - this.state = 213; + this.state = 228; this._errHandler.sync(this); switch (this._input.LA(1)) { - case 72: + case 74: this.enterOuterAlt(localctx, 1); { - this.state = 211; + this.state = 226; this.match(CashScriptParser.Identifier); } break; - case 60: case 62: - case 67: - case 68: + case 64: case 69: + case 70: + case 71: this.enterOuterAlt(localctx, 2); { - this.state = 212; + this.state = 227; this.literal(); } break; @@ -1123,45 +1199,45 @@ export default class CashScriptParser extends Parser { // @RuleVersion(0) public consoleParameterList(): ConsoleParameterListContext { let localctx: ConsoleParameterListContext = new ConsoleParameterListContext(this, this._ctx, this.state); - this.enterRule(localctx, 42, CashScriptParser.RULE_consoleParameterList); + this.enterRule(localctx, 46, CashScriptParser.RULE_consoleParameterList); let _la: number; try { let _alt: number; this.enterOuterAlt(localctx, 1); { - this.state = 215; + this.state = 230; this.match(CashScriptParser.T__14); - this.state = 227; + this.state = 242; this._errHandler.sync(this); _la = this._input.LA(1); - if (((((_la - 60)) & ~0x1F) === 0 && ((1 << (_la - 60)) & 4997) !== 0)) { + if (((((_la - 62)) & ~0x1F) === 0 && ((1 << (_la - 62)) & 4997) !== 0)) { { - this.state = 216; + this.state = 231; this.consoleParameter(); - this.state = 221; + this.state = 236; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 16, this._ctx); while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) { if (_alt === 1) { { { - this.state = 217; + this.state = 232; this.match(CashScriptParser.T__15); - this.state = 218; + this.state = 233; this.consoleParameter(); } } } - this.state = 223; + this.state = 238; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 16, this._ctx); } - this.state = 225; + this.state = 240; this._errHandler.sync(this); _la = this._input.LA(1); if (_la===16) { { - this.state = 224; + this.state = 239; this.match(CashScriptParser.T__15); } } @@ -1169,7 +1245,7 @@ export default class CashScriptParser extends Parser { } } - this.state = 229; + this.state = 244; this.match(CashScriptParser.T__16); } } @@ -1190,13 +1266,13 @@ export default class CashScriptParser extends Parser { // @RuleVersion(0) public functionCall(): FunctionCallContext { let localctx: FunctionCallContext = new FunctionCallContext(this, this._ctx, this.state); - this.enterRule(localctx, 44, CashScriptParser.RULE_functionCall); + this.enterRule(localctx, 48, CashScriptParser.RULE_functionCall); try { this.enterOuterAlt(localctx, 1); { - this.state = 231; + this.state = 246; this.match(CashScriptParser.Identifier); - this.state = 232; + this.state = 247; this.expressionList(); } } @@ -1217,45 +1293,45 @@ export default class CashScriptParser extends Parser { // @RuleVersion(0) public expressionList(): ExpressionListContext { let localctx: ExpressionListContext = new ExpressionListContext(this, this._ctx, this.state); - this.enterRule(localctx, 46, CashScriptParser.RULE_expressionList); + this.enterRule(localctx, 50, CashScriptParser.RULE_expressionList); let _la: number; try { let _alt: number; this.enterOuterAlt(localctx, 1); { - this.state = 234; + this.state = 249; this.match(CashScriptParser.T__14); - this.state = 246; + this.state = 261; this._errHandler.sync(this); _la = this._input.LA(1); - if (((((_la - 15)) & ~0x1F) === 0 && ((1 << (_la - 15)) & 100730241) !== 0) || ((((_la - 53)) & ~0x1F) === 0 && ((1 << (_la - 53)) & 905919) !== 0)) { + if (((((_la - 15)) & ~0x1F) === 0 && ((1 << (_la - 15)) & 402920961) !== 0) || ((((_la - 55)) & ~0x1F) === 0 && ((1 << (_la - 55)) & 905919) !== 0)) { { - this.state = 235; + this.state = 250; this.expression(0); - this.state = 240; + this.state = 255; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 19, this._ctx); while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) { if (_alt === 1) { { { - this.state = 236; + this.state = 251; this.match(CashScriptParser.T__15); - this.state = 237; + this.state = 252; this.expression(0); } } } - this.state = 242; + this.state = 257; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 19, this._ctx); } - this.state = 244; + this.state = 259; this._errHandler.sync(this); _la = this._input.LA(1); if (_la===16) { { - this.state = 243; + this.state = 258; this.match(CashScriptParser.T__15); } } @@ -1263,7 +1339,7 @@ export default class CashScriptParser extends Parser { } } - this.state = 248; + this.state = 263; this.match(CashScriptParser.T__16); } } @@ -1294,14 +1370,14 @@ export default class CashScriptParser extends Parser { let _parentState: number = this.state; let localctx: ExpressionContext = new ExpressionContext(this, this._ctx, _parentState); let _prevctx: ExpressionContext = localctx; - let _startState: number = 48; - this.enterRecursionRule(localctx, 48, CashScriptParser.RULE_expression, _p); + let _startState: number = 52; + this.enterRecursionRule(localctx, 52, CashScriptParser.RULE_expression, _p); let _la: number; try { let _alt: number; this.enterOuterAlt(localctx, 1); { - this.state = 303; + this.state = 318; this._errHandler.sync(this); switch ( this._interp.adaptivePredict(this._input, 27, this._ctx) ) { case 1: @@ -1310,11 +1386,11 @@ export default class CashScriptParser extends Parser { this._ctx = localctx; _prevctx = localctx; - this.state = 251; + this.state = 266; this.match(CashScriptParser.T__14); - this.state = 252; + this.state = 267; this.expression(0); - this.state = 253; + this.state = 268; this.match(CashScriptParser.T__16); } break; @@ -1323,35 +1399,35 @@ export default class CashScriptParser extends Parser { localctx = new CastContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 255; + this.state = 270; this.typeName(); - this.state = 256; + this.state = 271; this.match(CashScriptParser.T__14); - this.state = 257; + this.state = 272; (localctx as CastContext)._castable = this.expression(0); - this.state = 260; + this.state = 275; this._errHandler.sync(this); switch ( this._interp.adaptivePredict(this._input, 22, this._ctx) ) { case 1: { - this.state = 258; + this.state = 273; this.match(CashScriptParser.T__15); - this.state = 259; + this.state = 274; (localctx as CastContext)._size = this.expression(0); } break; } - this.state = 263; + this.state = 278; this._errHandler.sync(this); _la = this._input.LA(1); if (_la===16) { { - this.state = 262; + this.state = 277; this.match(CashScriptParser.T__15); } } - this.state = 265; + this.state = 280; this.match(CashScriptParser.T__16); } break; @@ -1360,7 +1436,7 @@ export default class CashScriptParser extends Parser { localctx = new FunctionCallExpressionContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 267; + this.state = 282; this.functionCall(); } break; @@ -1369,11 +1445,11 @@ export default class CashScriptParser extends Parser { localctx = new InstantiationContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 268; - this.match(CashScriptParser.T__21); - this.state = 269; + this.state = 283; + this.match(CashScriptParser.T__23); + this.state = 284; this.match(CashScriptParser.Identifier); - this.state = 270; + this.state = 285; this.expressionList(); } break; @@ -1382,18 +1458,18 @@ export default class CashScriptParser extends Parser { localctx = new UnaryIntrospectionOpContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 271; - (localctx as UnaryIntrospectionOpContext)._scope = this.match(CashScriptParser.T__24); - this.state = 272; - this.match(CashScriptParser.T__22); - this.state = 273; + this.state = 286; + (localctx as UnaryIntrospectionOpContext)._scope = this.match(CashScriptParser.T__26); + this.state = 287; + this.match(CashScriptParser.T__24); + this.state = 288; this.expression(0); - this.state = 274; - this.match(CashScriptParser.T__23); - this.state = 275; + this.state = 289; + this.match(CashScriptParser.T__25); + this.state = 290; (localctx as UnaryIntrospectionOpContext)._op = this._input.LT(1); _la = this._input.LA(1); - if(!((((_la) & ~0x1F) === 0 && ((1 << _la) & 2080374784) !== 0))) { + if(!(((((_la - 28)) & ~0x1F) === 0 && ((1 << (_la - 28)) & 31) !== 0))) { (localctx as UnaryIntrospectionOpContext)._op = this._errHandler.recoverInline(this); } else { @@ -1407,18 +1483,18 @@ export default class CashScriptParser extends Parser { localctx = new UnaryIntrospectionOpContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 277; - (localctx as UnaryIntrospectionOpContext)._scope = this.match(CashScriptParser.T__30); - this.state = 278; - this.match(CashScriptParser.T__22); - this.state = 279; + this.state = 292; + (localctx as UnaryIntrospectionOpContext)._scope = this.match(CashScriptParser.T__32); + this.state = 293; + this.match(CashScriptParser.T__24); + this.state = 294; this.expression(0); - this.state = 280; - this.match(CashScriptParser.T__23); - this.state = 281; + this.state = 295; + this.match(CashScriptParser.T__25); + this.state = 296; (localctx as UnaryIntrospectionOpContext)._op = this._input.LT(1); _la = this._input.LA(1); - if(!(((((_la - 26)) & ~0x1F) === 0 && ((1 << (_la - 26)) & 991) !== 0))) { + if(!(((((_la - 28)) & ~0x1F) === 0 && ((1 << (_la - 28)) & 991) !== 0))) { (localctx as UnaryIntrospectionOpContext)._op = this._errHandler.recoverInline(this); } else { @@ -1432,17 +1508,17 @@ export default class CashScriptParser extends Parser { localctx = new UnaryOpContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 283; + this.state = 298; (localctx as UnaryOpContext)._op = this._input.LT(1); _la = this._input.LA(1); - if(!(_la===40 || _la===41)) { + if(!(_la===42 || _la===43)) { (localctx as UnaryOpContext)._op = this._errHandler.recoverInline(this); } else { this._errHandler.reportMatch(this); this.consume(); } - this.state = 284; + this.state = 299; this.expression(14); } break; @@ -1451,39 +1527,39 @@ export default class CashScriptParser extends Parser { localctx = new ArrayContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 285; - this.match(CashScriptParser.T__22); - this.state = 297; + this.state = 300; + this.match(CashScriptParser.T__24); + this.state = 312; this._errHandler.sync(this); _la = this._input.LA(1); - if (((((_la - 15)) & ~0x1F) === 0 && ((1 << (_la - 15)) & 100730241) !== 0) || ((((_la - 53)) & ~0x1F) === 0 && ((1 << (_la - 53)) & 905919) !== 0)) { + if (((((_la - 15)) & ~0x1F) === 0 && ((1 << (_la - 15)) & 402920961) !== 0) || ((((_la - 55)) & ~0x1F) === 0 && ((1 << (_la - 55)) & 905919) !== 0)) { { - this.state = 286; + this.state = 301; this.expression(0); - this.state = 291; + this.state = 306; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 24, this._ctx); while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) { if (_alt === 1) { { { - this.state = 287; + this.state = 302; this.match(CashScriptParser.T__15); - this.state = 288; + this.state = 303; this.expression(0); } } } - this.state = 293; + this.state = 308; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 24, this._ctx); } - this.state = 295; + this.state = 310; this._errHandler.sync(this); _la = this._input.LA(1); if (_la===16) { { - this.state = 294; + this.state = 309; this.match(CashScriptParser.T__15); } } @@ -1491,8 +1567,8 @@ export default class CashScriptParser extends Parser { } } - this.state = 299; - this.match(CashScriptParser.T__23); + this.state = 314; + this.match(CashScriptParser.T__25); } break; case 9: @@ -1500,7 +1576,7 @@ export default class CashScriptParser extends Parser { localctx = new NullaryOpContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 300; + this.state = 315; this.match(CashScriptParser.NullaryOp); } break; @@ -1509,7 +1585,7 @@ export default class CashScriptParser extends Parser { localctx = new IdentifierContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 301; + this.state = 316; this.match(CashScriptParser.Identifier); } break; @@ -1518,13 +1594,13 @@ export default class CashScriptParser extends Parser { localctx = new LiteralExpressionContext(this, localctx); this._ctx = localctx; _prevctx = localctx; - this.state = 302; + this.state = 317; this.literal(); } break; } this._ctx.stop = this._input.LT(-1); - this.state = 354; + this.state = 369; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 29, this._ctx); while (_alt !== 2 && _alt !== ATN.INVALID_ALT_NUMBER) { @@ -1534,7 +1610,7 @@ export default class CashScriptParser extends Parser { } _prevctx = localctx; { - this.state = 352; + this.state = 367; this._errHandler.sync(this); switch ( this._interp.adaptivePredict(this._input, 28, this._ctx) ) { case 1: @@ -1542,21 +1618,21 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 305; + this.state = 320; if (!(this.precpred(this._ctx, 13))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 13)"); } - this.state = 306; + this.state = 321; (localctx as BinaryOpContext)._op = this._input.LT(1); _la = this._input.LA(1); - if(!(((((_la - 42)) & ~0x1F) === 0 && ((1 << (_la - 42)) & 7) !== 0))) { + if(!(((((_la - 44)) & ~0x1F) === 0 && ((1 << (_la - 44)) & 7) !== 0))) { (localctx as BinaryOpContext)._op = this._errHandler.recoverInline(this); } else { this._errHandler.reportMatch(this); this.consume(); } - this.state = 307; + this.state = 322; (localctx as BinaryOpContext)._right = this.expression(14); } break; @@ -1565,21 +1641,21 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 308; + this.state = 323; if (!(this.precpred(this._ctx, 12))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 12)"); } - this.state = 309; + this.state = 324; (localctx as BinaryOpContext)._op = this._input.LT(1); _la = this._input.LA(1); - if(!(_la===41 || _la===45)) { + if(!(_la===43 || _la===47)) { (localctx as BinaryOpContext)._op = this._errHandler.recoverInline(this); } else { this._errHandler.reportMatch(this); this.consume(); } - this.state = 310; + this.state = 325; (localctx as BinaryOpContext)._right = this.expression(13); } break; @@ -1588,11 +1664,11 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 311; + this.state = 326; if (!(this.precpred(this._ctx, 11))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 11)"); } - this.state = 312; + this.state = 327; (localctx as BinaryOpContext)._op = this._input.LT(1); _la = this._input.LA(1); if(!((((_la) & ~0x1F) === 0 && ((1 << _la) & 960) !== 0))) { @@ -1602,7 +1678,7 @@ export default class CashScriptParser extends Parser { this._errHandler.reportMatch(this); this.consume(); } - this.state = 313; + this.state = 328; (localctx as BinaryOpContext)._right = this.expression(12); } break; @@ -1611,21 +1687,21 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 314; + this.state = 329; if (!(this.precpred(this._ctx, 10))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 10)"); } - this.state = 315; + this.state = 330; (localctx as BinaryOpContext)._op = this._input.LT(1); _la = this._input.LA(1); - if(!(_la===46 || _la===47)) { + if(!(_la===48 || _la===49)) { (localctx as BinaryOpContext)._op = this._errHandler.recoverInline(this); } else { this._errHandler.reportMatch(this); this.consume(); } - this.state = 316; + this.state = 331; (localctx as BinaryOpContext)._right = this.expression(11); } break; @@ -1634,13 +1710,13 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 317; + this.state = 332; if (!(this.precpred(this._ctx, 9))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 9)"); } - this.state = 318; - (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__47); - this.state = 319; + this.state = 333; + (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__49); + this.state = 334; (localctx as BinaryOpContext)._right = this.expression(10); } break; @@ -1649,13 +1725,13 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 320; + this.state = 335; if (!(this.precpred(this._ctx, 8))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 8)"); } - this.state = 321; + this.state = 336; (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__3); - this.state = 322; + this.state = 337; (localctx as BinaryOpContext)._right = this.expression(9); } break; @@ -1664,13 +1740,13 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 323; + this.state = 338; if (!(this.precpred(this._ctx, 7))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 7)"); } - this.state = 324; - (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__48); - this.state = 325; + this.state = 339; + (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__50); + this.state = 340; (localctx as BinaryOpContext)._right = this.expression(8); } break; @@ -1679,13 +1755,13 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 326; + this.state = 341; if (!(this.precpred(this._ctx, 6))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 6)"); } - this.state = 327; - (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__49); - this.state = 328; + this.state = 342; + (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__51); + this.state = 343; (localctx as BinaryOpContext)._right = this.expression(7); } break; @@ -1694,13 +1770,13 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 329; + this.state = 344; if (!(this.precpred(this._ctx, 5))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 5)"); } - this.state = 330; - (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__50); - this.state = 331; + this.state = 345; + (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__52); + this.state = 346; (localctx as BinaryOpContext)._right = this.expression(6); } break; @@ -1708,30 +1784,30 @@ export default class CashScriptParser extends Parser { { localctx = new TupleIndexOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 332; + this.state = 347; if (!(this.precpred(this._ctx, 20))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 20)"); } - this.state = 333; - this.match(CashScriptParser.T__22); - this.state = 334; + this.state = 348; + this.match(CashScriptParser.T__24); + this.state = 349; (localctx as TupleIndexOpContext)._index = this.match(CashScriptParser.NumberLiteral); - this.state = 335; - this.match(CashScriptParser.T__23); + this.state = 350; + this.match(CashScriptParser.T__25); } break; case 11: { localctx = new UnaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 336; + this.state = 351; if (!(this.precpred(this._ctx, 17))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 17)"); } - this.state = 337; + this.state = 352; (localctx as UnaryOpContext)._op = this._input.LT(1); _la = this._input.LA(1); - if(!(_la===36 || _la===37)) { + if(!(_la===38 || _la===39)) { (localctx as UnaryOpContext)._op = this._errHandler.recoverInline(this); } else { @@ -1745,17 +1821,17 @@ export default class CashScriptParser extends Parser { localctx = new BinaryOpContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as BinaryOpContext)._left = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 338; + this.state = 353; if (!(this.precpred(this._ctx, 16))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 16)"); } - this.state = 339; - (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__37); - this.state = 340; + this.state = 354; + (localctx as BinaryOpContext)._op = this.match(CashScriptParser.T__39); + this.state = 355; this.match(CashScriptParser.T__14); - this.state = 341; + this.state = 356; (localctx as BinaryOpContext)._right = this.expression(0); - this.state = 342; + this.state = 357; this.match(CashScriptParser.T__16); } break; @@ -1764,28 +1840,28 @@ export default class CashScriptParser extends Parser { localctx = new SliceContext(this, new ExpressionContext(this, _parentctx, _parentState)); (localctx as SliceContext)._element = _prevctx; this.pushNewRecursionContext(localctx, _startState, CashScriptParser.RULE_expression); - this.state = 344; + this.state = 359; if (!(this.precpred(this._ctx, 15))) { throw this.createFailedPredicateException("this.precpred(this._ctx, 15)"); } - this.state = 345; - this.match(CashScriptParser.T__38); - this.state = 346; + this.state = 360; + this.match(CashScriptParser.T__40); + this.state = 361; this.match(CashScriptParser.T__14); - this.state = 347; + this.state = 362; (localctx as SliceContext)._start = this.expression(0); - this.state = 348; + this.state = 363; this.match(CashScriptParser.T__15); - this.state = 349; + this.state = 364; (localctx as SliceContext)._end = this.expression(0); - this.state = 350; + this.state = 365; this.match(CashScriptParser.T__16); } break; } } } - this.state = 356; + this.state = 371; this._errHandler.sync(this); _alt = this._interp.adaptivePredict(this._input, 29, this._ctx); } @@ -1808,12 +1884,12 @@ export default class CashScriptParser extends Parser { // @RuleVersion(0) public modifier(): ModifierContext { let localctx: ModifierContext = new ModifierContext(this, this._ctx, this.state); - this.enterRule(localctx, 50, CashScriptParser.RULE_modifier); + this.enterRule(localctx, 54, CashScriptParser.RULE_modifier); try { this.enterOuterAlt(localctx, 1); { - this.state = 357; - this.match(CashScriptParser.T__51); + this.state = 372; + this.match(CashScriptParser.T__53); } } catch (re) { @@ -1833,43 +1909,43 @@ export default class CashScriptParser extends Parser { // @RuleVersion(0) public literal(): LiteralContext { let localctx: LiteralContext = new LiteralContext(this, this._ctx, this.state); - this.enterRule(localctx, 52, CashScriptParser.RULE_literal); + this.enterRule(localctx, 56, CashScriptParser.RULE_literal); try { - this.state = 364; + this.state = 379; this._errHandler.sync(this); switch (this._input.LA(1)) { - case 60: + case 62: this.enterOuterAlt(localctx, 1); { - this.state = 359; + this.state = 374; this.match(CashScriptParser.BooleanLiteral); } break; - case 62: + case 64: this.enterOuterAlt(localctx, 2); { - this.state = 360; + this.state = 375; this.numberLiteral(); } break; - case 67: + case 69: this.enterOuterAlt(localctx, 3); { - this.state = 361; + this.state = 376; this.match(CashScriptParser.StringLiteral); } break; - case 68: + case 70: this.enterOuterAlt(localctx, 4); { - this.state = 362; + this.state = 377; this.match(CashScriptParser.DateLiteral); } break; - case 69: + case 71: this.enterOuterAlt(localctx, 5); { - this.state = 363; + this.state = 378; this.match(CashScriptParser.HexLiteral); } break; @@ -1894,18 +1970,18 @@ export default class CashScriptParser extends Parser { // @RuleVersion(0) public numberLiteral(): NumberLiteralContext { let localctx: NumberLiteralContext = new NumberLiteralContext(this, this._ctx, this.state); - this.enterRule(localctx, 54, CashScriptParser.RULE_numberLiteral); + this.enterRule(localctx, 58, CashScriptParser.RULE_numberLiteral); try { this.enterOuterAlt(localctx, 1); { - this.state = 366; + this.state = 381; this.match(CashScriptParser.NumberLiteral); - this.state = 368; + this.state = 383; this._errHandler.sync(this); switch ( this._interp.adaptivePredict(this._input, 31, this._ctx) ) { case 1: { - this.state = 367; + this.state = 382; this.match(CashScriptParser.NumberUnit); } break; @@ -1929,14 +2005,14 @@ export default class CashScriptParser extends Parser { // @RuleVersion(0) public typeName(): TypeNameContext { let localctx: TypeNameContext = new TypeNameContext(this, this._ctx, this.state); - this.enterRule(localctx, 56, CashScriptParser.RULE_typeName); + this.enterRule(localctx, 60, CashScriptParser.RULE_typeName); let _la: number; try { this.enterOuterAlt(localctx, 1); { - this.state = 370; + this.state = 385; _la = this._input.LA(1); - if(!(((((_la - 53)) & ~0x1F) === 0 && ((1 << (_la - 53)) & 4159) !== 0))) { + if(!(((((_la - 55)) & ~0x1F) === 0 && ((1 << (_la - 55)) & 4159) !== 0))) { this._errHandler.recoverInline(this); } else { @@ -1962,7 +2038,7 @@ export default class CashScriptParser extends Parser { public sempred(localctx: RuleContext, ruleIndex: number, predIndex: number): boolean { switch (ruleIndex) { - case 24: + case 26: return this.expression_sempred(localctx as ExpressionContext, predIndex); } return true; @@ -1999,130 +2075,134 @@ export default class CashScriptParser extends Parser { return true; } - public static readonly _serializedATN: number[] = [4,1,75,373,2,0,7,0,2, + public static readonly _serializedATN: number[] = [4,1,77,388,2,0,7,0,2, 1,7,1,2,2,7,2,2,3,7,3,2,4,7,4,2,5,7,5,2,6,7,6,2,7,7,7,2,8,7,8,2,9,7,9,2, 10,7,10,2,11,7,11,2,12,7,12,2,13,7,13,2,14,7,14,2,15,7,15,2,16,7,16,2,17, 7,17,2,18,7,18,2,19,7,19,2,20,7,20,2,21,7,21,2,22,7,22,2,23,7,23,2,24,7, - 24,2,25,7,25,2,26,7,26,2,27,7,27,2,28,7,28,1,0,5,0,60,8,0,10,0,12,0,63, - 9,0,1,0,1,0,1,0,1,1,1,1,1,1,1,1,1,1,1,2,1,2,1,3,1,3,3,3,77,8,3,1,4,3,4, - 80,8,4,1,4,1,4,1,5,1,5,1,6,1,6,1,6,1,6,1,6,5,6,91,8,6,10,6,12,6,94,9,6, - 1,6,1,6,1,7,1,7,1,7,1,7,1,7,5,7,103,8,7,10,7,12,7,106,9,7,1,7,1,7,1,8,1, - 8,1,8,1,8,5,8,114,8,8,10,8,12,8,117,9,8,1,8,3,8,120,8,8,3,8,122,8,8,1,8, - 1,8,1,9,1,9,1,9,1,10,1,10,5,10,131,8,10,10,10,12,10,134,9,10,1,10,1,10, - 3,10,138,8,10,1,11,1,11,1,11,1,11,1,11,1,11,1,11,3,11,147,8,11,1,12,1,12, - 5,12,151,8,12,10,12,12,12,154,9,12,1,12,1,12,1,12,1,12,1,12,1,13,1,13,1, - 13,1,13,1,13,1,13,1,13,1,13,1,13,1,14,1,14,1,14,1,14,1,14,1,15,1,15,1,15, - 1,15,1,15,1,15,1,15,3,15,182,8,15,1,15,1,15,1,15,1,16,1,16,1,16,1,16,1, - 16,3,16,192,8,16,1,16,1,16,1,16,1,17,1,17,1,17,1,17,1,17,1,17,1,17,3,17, - 204,8,17,1,18,1,18,1,18,1,18,1,19,1,19,1,20,1,20,3,20,214,8,20,1,21,1,21, - 1,21,1,21,5,21,220,8,21,10,21,12,21,223,9,21,1,21,3,21,226,8,21,3,21,228, - 8,21,1,21,1,21,1,22,1,22,1,22,1,23,1,23,1,23,1,23,5,23,239,8,23,10,23,12, - 23,242,9,23,1,23,3,23,245,8,23,3,23,247,8,23,1,23,1,23,1,24,1,24,1,24,1, - 24,1,24,1,24,1,24,1,24,1,24,1,24,3,24,261,8,24,1,24,3,24,264,8,24,1,24, - 1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1, - 24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,5,24,290,8,24,10,24,12,24,293, - 9,24,1,24,3,24,296,8,24,3,24,298,8,24,1,24,1,24,1,24,1,24,3,24,304,8,24, - 1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1, - 24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24, - 1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1,24,1, - 24,1,24,1,24,1,24,5,24,353,8,24,10,24,12,24,356,9,24,1,25,1,25,1,26,1,26, - 1,26,1,26,1,26,3,26,365,8,26,1,27,1,27,3,27,369,8,27,1,28,1,28,1,28,0,1, - 48,29,0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46, - 48,50,52,54,56,0,10,1,0,4,10,1,0,26,30,2,0,26,30,32,35,1,0,40,41,1,0,42, - 44,2,0,41,41,45,45,1,0,6,9,1,0,46,47,1,0,36,37,2,0,53,58,65,65,403,0,61, - 1,0,0,0,2,67,1,0,0,0,4,72,1,0,0,0,6,74,1,0,0,0,8,79,1,0,0,0,10,83,1,0,0, - 0,12,85,1,0,0,0,14,97,1,0,0,0,16,109,1,0,0,0,18,125,1,0,0,0,20,137,1,0, - 0,0,22,146,1,0,0,0,24,148,1,0,0,0,26,160,1,0,0,0,28,169,1,0,0,0,30,174, - 1,0,0,0,32,186,1,0,0,0,34,196,1,0,0,0,36,205,1,0,0,0,38,209,1,0,0,0,40, - 213,1,0,0,0,42,215,1,0,0,0,44,231,1,0,0,0,46,234,1,0,0,0,48,303,1,0,0,0, - 50,357,1,0,0,0,52,364,1,0,0,0,54,366,1,0,0,0,56,370,1,0,0,0,58,60,3,2,1, - 0,59,58,1,0,0,0,60,63,1,0,0,0,61,59,1,0,0,0,61,62,1,0,0,0,62,64,1,0,0,0, - 63,61,1,0,0,0,64,65,3,12,6,0,65,66,5,0,0,1,66,1,1,0,0,0,67,68,5,1,0,0,68, - 69,3,4,2,0,69,70,3,6,3,0,70,71,5,2,0,0,71,3,1,0,0,0,72,73,5,3,0,0,73,5, - 1,0,0,0,74,76,3,8,4,0,75,77,3,8,4,0,76,75,1,0,0,0,76,77,1,0,0,0,77,7,1, - 0,0,0,78,80,3,10,5,0,79,78,1,0,0,0,79,80,1,0,0,0,80,81,1,0,0,0,81,82,5, - 59,0,0,82,9,1,0,0,0,83,84,7,0,0,0,84,11,1,0,0,0,85,86,5,11,0,0,86,87,5, - 72,0,0,87,88,3,16,8,0,88,92,5,12,0,0,89,91,3,14,7,0,90,89,1,0,0,0,91,94, - 1,0,0,0,92,90,1,0,0,0,92,93,1,0,0,0,93,95,1,0,0,0,94,92,1,0,0,0,95,96,5, - 13,0,0,96,13,1,0,0,0,97,98,5,14,0,0,98,99,5,72,0,0,99,100,3,16,8,0,100, - 104,5,12,0,0,101,103,3,22,11,0,102,101,1,0,0,0,103,106,1,0,0,0,104,102, - 1,0,0,0,104,105,1,0,0,0,105,107,1,0,0,0,106,104,1,0,0,0,107,108,5,13,0, - 0,108,15,1,0,0,0,109,121,5,15,0,0,110,115,3,18,9,0,111,112,5,16,0,0,112, - 114,3,18,9,0,113,111,1,0,0,0,114,117,1,0,0,0,115,113,1,0,0,0,115,116,1, - 0,0,0,116,119,1,0,0,0,117,115,1,0,0,0,118,120,5,16,0,0,119,118,1,0,0,0, - 119,120,1,0,0,0,120,122,1,0,0,0,121,110,1,0,0,0,121,122,1,0,0,0,122,123, - 1,0,0,0,123,124,5,17,0,0,124,17,1,0,0,0,125,126,3,56,28,0,126,127,5,72, - 0,0,127,19,1,0,0,0,128,132,5,12,0,0,129,131,3,22,11,0,130,129,1,0,0,0,131, - 134,1,0,0,0,132,130,1,0,0,0,132,133,1,0,0,0,133,135,1,0,0,0,134,132,1,0, - 0,0,135,138,5,13,0,0,136,138,3,22,11,0,137,128,1,0,0,0,137,136,1,0,0,0, - 138,21,1,0,0,0,139,147,3,24,12,0,140,147,3,26,13,0,141,147,3,28,14,0,142, - 147,3,30,15,0,143,147,3,32,16,0,144,147,3,34,17,0,145,147,3,36,18,0,146, - 139,1,0,0,0,146,140,1,0,0,0,146,141,1,0,0,0,146,142,1,0,0,0,146,143,1,0, - 0,0,146,144,1,0,0,0,146,145,1,0,0,0,147,23,1,0,0,0,148,152,3,56,28,0,149, - 151,3,50,25,0,150,149,1,0,0,0,151,154,1,0,0,0,152,150,1,0,0,0,152,153,1, - 0,0,0,153,155,1,0,0,0,154,152,1,0,0,0,155,156,5,72,0,0,156,157,5,10,0,0, - 157,158,3,48,24,0,158,159,5,2,0,0,159,25,1,0,0,0,160,161,3,56,28,0,161, - 162,5,72,0,0,162,163,5,16,0,0,163,164,3,56,28,0,164,165,5,72,0,0,165,166, - 5,10,0,0,166,167,3,48,24,0,167,168,5,2,0,0,168,27,1,0,0,0,169,170,5,72, - 0,0,170,171,5,10,0,0,171,172,3,48,24,0,172,173,5,2,0,0,173,29,1,0,0,0,174, - 175,5,18,0,0,175,176,5,15,0,0,176,177,5,70,0,0,177,178,5,6,0,0,178,181, - 3,48,24,0,179,180,5,16,0,0,180,182,3,38,19,0,181,179,1,0,0,0,181,182,1, - 0,0,0,182,183,1,0,0,0,183,184,5,17,0,0,184,185,5,2,0,0,185,31,1,0,0,0,186, - 187,5,18,0,0,187,188,5,15,0,0,188,191,3,48,24,0,189,190,5,16,0,0,190,192, - 3,38,19,0,191,189,1,0,0,0,191,192,1,0,0,0,192,193,1,0,0,0,193,194,5,17, - 0,0,194,195,5,2,0,0,195,33,1,0,0,0,196,197,5,19,0,0,197,198,5,15,0,0,198, - 199,3,48,24,0,199,200,5,17,0,0,200,203,3,20,10,0,201,202,5,20,0,0,202,204, - 3,20,10,0,203,201,1,0,0,0,203,204,1,0,0,0,204,35,1,0,0,0,205,206,5,21,0, - 0,206,207,3,42,21,0,207,208,5,2,0,0,208,37,1,0,0,0,209,210,5,67,0,0,210, - 39,1,0,0,0,211,214,5,72,0,0,212,214,3,52,26,0,213,211,1,0,0,0,213,212,1, - 0,0,0,214,41,1,0,0,0,215,227,5,15,0,0,216,221,3,40,20,0,217,218,5,16,0, - 0,218,220,3,40,20,0,219,217,1,0,0,0,220,223,1,0,0,0,221,219,1,0,0,0,221, - 222,1,0,0,0,222,225,1,0,0,0,223,221,1,0,0,0,224,226,5,16,0,0,225,224,1, - 0,0,0,225,226,1,0,0,0,226,228,1,0,0,0,227,216,1,0,0,0,227,228,1,0,0,0,228, - 229,1,0,0,0,229,230,5,17,0,0,230,43,1,0,0,0,231,232,5,72,0,0,232,233,3, - 46,23,0,233,45,1,0,0,0,234,246,5,15,0,0,235,240,3,48,24,0,236,237,5,16, - 0,0,237,239,3,48,24,0,238,236,1,0,0,0,239,242,1,0,0,0,240,238,1,0,0,0,240, - 241,1,0,0,0,241,244,1,0,0,0,242,240,1,0,0,0,243,245,5,16,0,0,244,243,1, - 0,0,0,244,245,1,0,0,0,245,247,1,0,0,0,246,235,1,0,0,0,246,247,1,0,0,0,247, - 248,1,0,0,0,248,249,5,17,0,0,249,47,1,0,0,0,250,251,6,24,-1,0,251,252,5, - 15,0,0,252,253,3,48,24,0,253,254,5,17,0,0,254,304,1,0,0,0,255,256,3,56, - 28,0,256,257,5,15,0,0,257,260,3,48,24,0,258,259,5,16,0,0,259,261,3,48,24, - 0,260,258,1,0,0,0,260,261,1,0,0,0,261,263,1,0,0,0,262,264,5,16,0,0,263, - 262,1,0,0,0,263,264,1,0,0,0,264,265,1,0,0,0,265,266,5,17,0,0,266,304,1, - 0,0,0,267,304,3,44,22,0,268,269,5,22,0,0,269,270,5,72,0,0,270,304,3,46, - 23,0,271,272,5,25,0,0,272,273,5,23,0,0,273,274,3,48,24,0,274,275,5,24,0, - 0,275,276,7,1,0,0,276,304,1,0,0,0,277,278,5,31,0,0,278,279,5,23,0,0,279, - 280,3,48,24,0,280,281,5,24,0,0,281,282,7,2,0,0,282,304,1,0,0,0,283,284, - 7,3,0,0,284,304,3,48,24,14,285,297,5,23,0,0,286,291,3,48,24,0,287,288,5, - 16,0,0,288,290,3,48,24,0,289,287,1,0,0,0,290,293,1,0,0,0,291,289,1,0,0, - 0,291,292,1,0,0,0,292,295,1,0,0,0,293,291,1,0,0,0,294,296,5,16,0,0,295, - 294,1,0,0,0,295,296,1,0,0,0,296,298,1,0,0,0,297,286,1,0,0,0,297,298,1,0, - 0,0,298,299,1,0,0,0,299,304,5,24,0,0,300,304,5,71,0,0,301,304,5,72,0,0, - 302,304,3,52,26,0,303,250,1,0,0,0,303,255,1,0,0,0,303,267,1,0,0,0,303,268, - 1,0,0,0,303,271,1,0,0,0,303,277,1,0,0,0,303,283,1,0,0,0,303,285,1,0,0,0, - 303,300,1,0,0,0,303,301,1,0,0,0,303,302,1,0,0,0,304,354,1,0,0,0,305,306, - 10,13,0,0,306,307,7,4,0,0,307,353,3,48,24,14,308,309,10,12,0,0,309,310, - 7,5,0,0,310,353,3,48,24,13,311,312,10,11,0,0,312,313,7,6,0,0,313,353,3, - 48,24,12,314,315,10,10,0,0,315,316,7,7,0,0,316,353,3,48,24,11,317,318,10, - 9,0,0,318,319,5,48,0,0,319,353,3,48,24,10,320,321,10,8,0,0,321,322,5,4, - 0,0,322,353,3,48,24,9,323,324,10,7,0,0,324,325,5,49,0,0,325,353,3,48,24, - 8,326,327,10,6,0,0,327,328,5,50,0,0,328,353,3,48,24,7,329,330,10,5,0,0, - 330,331,5,51,0,0,331,353,3,48,24,6,332,333,10,20,0,0,333,334,5,23,0,0,334, - 335,5,62,0,0,335,353,5,24,0,0,336,337,10,17,0,0,337,353,7,8,0,0,338,339, - 10,16,0,0,339,340,5,38,0,0,340,341,5,15,0,0,341,342,3,48,24,0,342,343,5, - 17,0,0,343,353,1,0,0,0,344,345,10,15,0,0,345,346,5,39,0,0,346,347,5,15, - 0,0,347,348,3,48,24,0,348,349,5,16,0,0,349,350,3,48,24,0,350,351,5,17,0, - 0,351,353,1,0,0,0,352,305,1,0,0,0,352,308,1,0,0,0,352,311,1,0,0,0,352,314, - 1,0,0,0,352,317,1,0,0,0,352,320,1,0,0,0,352,323,1,0,0,0,352,326,1,0,0,0, - 352,329,1,0,0,0,352,332,1,0,0,0,352,336,1,0,0,0,352,338,1,0,0,0,352,344, - 1,0,0,0,353,356,1,0,0,0,354,352,1,0,0,0,354,355,1,0,0,0,355,49,1,0,0,0, - 356,354,1,0,0,0,357,358,5,52,0,0,358,51,1,0,0,0,359,365,5,60,0,0,360,365, - 3,54,27,0,361,365,5,67,0,0,362,365,5,68,0,0,363,365,5,69,0,0,364,359,1, - 0,0,0,364,360,1,0,0,0,364,361,1,0,0,0,364,362,1,0,0,0,364,363,1,0,0,0,365, - 53,1,0,0,0,366,368,5,62,0,0,367,369,5,61,0,0,368,367,1,0,0,0,368,369,1, - 0,0,0,369,55,1,0,0,0,370,371,7,9,0,0,371,57,1,0,0,0,32,61,76,79,92,104, - 115,119,121,132,137,146,152,181,191,203,213,221,225,227,240,244,246,260, - 263,291,295,297,303,352,354,364,368]; + 24,2,25,7,25,2,26,7,26,2,27,7,27,2,28,7,28,2,29,7,29,2,30,7,30,1,0,5,0, + 64,8,0,10,0,12,0,67,9,0,1,0,1,0,1,0,1,1,1,1,1,1,1,1,1,1,1,2,1,2,1,3,1,3, + 3,3,81,8,3,1,4,3,4,84,8,4,1,4,1,4,1,5,1,5,1,6,1,6,1,6,1,6,1,6,5,6,95,8, + 6,10,6,12,6,98,9,6,1,6,1,6,1,7,1,7,1,7,1,7,1,7,5,7,107,8,7,10,7,12,7,110, + 9,7,1,7,1,7,1,8,1,8,1,8,1,8,5,8,118,8,8,10,8,12,8,121,9,8,1,8,3,8,124,8, + 8,3,8,126,8,8,1,8,1,8,1,9,1,9,1,9,1,10,1,10,5,10,135,8,10,10,10,12,10,138, + 9,10,1,10,1,10,3,10,142,8,10,1,11,1,11,1,11,1,11,1,11,1,11,1,11,1,11,3, + 11,152,8,11,1,12,1,12,5,12,156,8,12,10,12,12,12,159,9,12,1,12,1,12,1,12, + 1,12,1,12,1,13,1,13,1,13,1,13,1,13,1,13,1,13,1,13,1,13,1,14,1,14,1,14,1, + 14,1,14,1,15,1,15,1,15,1,15,1,15,1,15,1,15,3,15,187,8,15,1,15,1,15,1,15, + 1,16,1,16,1,16,1,16,1,16,3,16,197,8,16,1,16,1,16,1,16,1,17,1,17,1,17,1, + 17,1,17,1,17,1,17,3,17,209,8,17,1,18,1,18,1,19,1,19,1,19,1,19,1,19,1,19, + 1,19,1,19,1,20,1,20,1,20,1,20,1,21,1,21,1,22,1,22,3,22,229,8,22,1,23,1, + 23,1,23,1,23,5,23,235,8,23,10,23,12,23,238,9,23,1,23,3,23,241,8,23,3,23, + 243,8,23,1,23,1,23,1,24,1,24,1,24,1,25,1,25,1,25,1,25,5,25,254,8,25,10, + 25,12,25,257,9,25,1,25,3,25,260,8,25,3,25,262,8,25,1,25,1,25,1,26,1,26, + 1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,3,26,276,8,26,1,26,3,26,279,8,26, + 1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1, + 26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,5,26,305,8,26,10,26,12, + 26,308,9,26,1,26,3,26,311,8,26,3,26,313,8,26,1,26,1,26,1,26,1,26,3,26,319, + 8,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1, + 26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26, + 1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1,26,1, + 26,1,26,1,26,1,26,1,26,5,26,368,8,26,10,26,12,26,371,9,26,1,27,1,27,1,28, + 1,28,1,28,1,28,1,28,3,28,380,8,28,1,29,1,29,3,29,384,8,29,1,30,1,30,1,30, + 0,1,52,31,0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42, + 44,46,48,50,52,54,56,58,60,0,10,1,0,4,10,1,0,28,32,2,0,28,32,34,37,1,0, + 42,43,1,0,44,46,2,0,43,43,47,47,1,0,6,9,1,0,48,49,1,0,38,39,2,0,55,60,67, + 67,417,0,65,1,0,0,0,2,71,1,0,0,0,4,76,1,0,0,0,6,78,1,0,0,0,8,83,1,0,0,0, + 10,87,1,0,0,0,12,89,1,0,0,0,14,101,1,0,0,0,16,113,1,0,0,0,18,129,1,0,0, + 0,20,141,1,0,0,0,22,151,1,0,0,0,24,153,1,0,0,0,26,165,1,0,0,0,28,174,1, + 0,0,0,30,179,1,0,0,0,32,191,1,0,0,0,34,201,1,0,0,0,36,210,1,0,0,0,38,212, + 1,0,0,0,40,220,1,0,0,0,42,224,1,0,0,0,44,228,1,0,0,0,46,230,1,0,0,0,48, + 246,1,0,0,0,50,249,1,0,0,0,52,318,1,0,0,0,54,372,1,0,0,0,56,379,1,0,0,0, + 58,381,1,0,0,0,60,385,1,0,0,0,62,64,3,2,1,0,63,62,1,0,0,0,64,67,1,0,0,0, + 65,63,1,0,0,0,65,66,1,0,0,0,66,68,1,0,0,0,67,65,1,0,0,0,68,69,3,12,6,0, + 69,70,5,0,0,1,70,1,1,0,0,0,71,72,5,1,0,0,72,73,3,4,2,0,73,74,3,6,3,0,74, + 75,5,2,0,0,75,3,1,0,0,0,76,77,5,3,0,0,77,5,1,0,0,0,78,80,3,8,4,0,79,81, + 3,8,4,0,80,79,1,0,0,0,80,81,1,0,0,0,81,7,1,0,0,0,82,84,3,10,5,0,83,82,1, + 0,0,0,83,84,1,0,0,0,84,85,1,0,0,0,85,86,5,61,0,0,86,9,1,0,0,0,87,88,7,0, + 0,0,88,11,1,0,0,0,89,90,5,11,0,0,90,91,5,74,0,0,91,92,3,16,8,0,92,96,5, + 12,0,0,93,95,3,14,7,0,94,93,1,0,0,0,95,98,1,0,0,0,96,94,1,0,0,0,96,97,1, + 0,0,0,97,99,1,0,0,0,98,96,1,0,0,0,99,100,5,13,0,0,100,13,1,0,0,0,101,102, + 5,14,0,0,102,103,5,74,0,0,103,104,3,16,8,0,104,108,5,12,0,0,105,107,3,22, + 11,0,106,105,1,0,0,0,107,110,1,0,0,0,108,106,1,0,0,0,108,109,1,0,0,0,109, + 111,1,0,0,0,110,108,1,0,0,0,111,112,5,13,0,0,112,15,1,0,0,0,113,125,5,15, + 0,0,114,119,3,18,9,0,115,116,5,16,0,0,116,118,3,18,9,0,117,115,1,0,0,0, + 118,121,1,0,0,0,119,117,1,0,0,0,119,120,1,0,0,0,120,123,1,0,0,0,121,119, + 1,0,0,0,122,124,5,16,0,0,123,122,1,0,0,0,123,124,1,0,0,0,124,126,1,0,0, + 0,125,114,1,0,0,0,125,126,1,0,0,0,126,127,1,0,0,0,127,128,5,17,0,0,128, + 17,1,0,0,0,129,130,3,60,30,0,130,131,5,74,0,0,131,19,1,0,0,0,132,136,5, + 12,0,0,133,135,3,22,11,0,134,133,1,0,0,0,135,138,1,0,0,0,136,134,1,0,0, + 0,136,137,1,0,0,0,137,139,1,0,0,0,138,136,1,0,0,0,139,142,5,13,0,0,140, + 142,3,22,11,0,141,132,1,0,0,0,141,140,1,0,0,0,142,21,1,0,0,0,143,152,3, + 24,12,0,144,152,3,26,13,0,145,152,3,28,14,0,146,152,3,30,15,0,147,152,3, + 32,16,0,148,152,3,34,17,0,149,152,3,36,18,0,150,152,3,40,20,0,151,143,1, + 0,0,0,151,144,1,0,0,0,151,145,1,0,0,0,151,146,1,0,0,0,151,147,1,0,0,0,151, + 148,1,0,0,0,151,149,1,0,0,0,151,150,1,0,0,0,152,23,1,0,0,0,153,157,3,60, + 30,0,154,156,3,54,27,0,155,154,1,0,0,0,156,159,1,0,0,0,157,155,1,0,0,0, + 157,158,1,0,0,0,158,160,1,0,0,0,159,157,1,0,0,0,160,161,5,74,0,0,161,162, + 5,10,0,0,162,163,3,52,26,0,163,164,5,2,0,0,164,25,1,0,0,0,165,166,3,60, + 30,0,166,167,5,74,0,0,167,168,5,16,0,0,168,169,3,60,30,0,169,170,5,74,0, + 0,170,171,5,10,0,0,171,172,3,52,26,0,172,173,5,2,0,0,173,27,1,0,0,0,174, + 175,5,74,0,0,175,176,5,10,0,0,176,177,3,52,26,0,177,178,5,2,0,0,178,29, + 1,0,0,0,179,180,5,18,0,0,180,181,5,15,0,0,181,182,5,72,0,0,182,183,5,6, + 0,0,183,186,3,52,26,0,184,185,5,16,0,0,185,187,3,42,21,0,186,184,1,0,0, + 0,186,187,1,0,0,0,187,188,1,0,0,0,188,189,5,17,0,0,189,190,5,2,0,0,190, + 31,1,0,0,0,191,192,5,18,0,0,192,193,5,15,0,0,193,196,3,52,26,0,194,195, + 5,16,0,0,195,197,3,42,21,0,196,194,1,0,0,0,196,197,1,0,0,0,197,198,1,0, + 0,0,198,199,5,17,0,0,199,200,5,2,0,0,200,33,1,0,0,0,201,202,5,19,0,0,202, + 203,5,15,0,0,203,204,3,52,26,0,204,205,5,17,0,0,205,208,3,20,10,0,206,207, + 5,20,0,0,207,209,3,20,10,0,208,206,1,0,0,0,208,209,1,0,0,0,209,35,1,0,0, + 0,210,211,3,38,19,0,211,37,1,0,0,0,212,213,5,21,0,0,213,214,3,20,10,0,214, + 215,5,22,0,0,215,216,5,15,0,0,216,217,3,52,26,0,217,218,5,17,0,0,218,219, + 5,2,0,0,219,39,1,0,0,0,220,221,5,23,0,0,221,222,3,46,23,0,222,223,5,2,0, + 0,223,41,1,0,0,0,224,225,5,69,0,0,225,43,1,0,0,0,226,229,5,74,0,0,227,229, + 3,56,28,0,228,226,1,0,0,0,228,227,1,0,0,0,229,45,1,0,0,0,230,242,5,15,0, + 0,231,236,3,44,22,0,232,233,5,16,0,0,233,235,3,44,22,0,234,232,1,0,0,0, + 235,238,1,0,0,0,236,234,1,0,0,0,236,237,1,0,0,0,237,240,1,0,0,0,238,236, + 1,0,0,0,239,241,5,16,0,0,240,239,1,0,0,0,240,241,1,0,0,0,241,243,1,0,0, + 0,242,231,1,0,0,0,242,243,1,0,0,0,243,244,1,0,0,0,244,245,5,17,0,0,245, + 47,1,0,0,0,246,247,5,74,0,0,247,248,3,50,25,0,248,49,1,0,0,0,249,261,5, + 15,0,0,250,255,3,52,26,0,251,252,5,16,0,0,252,254,3,52,26,0,253,251,1,0, + 0,0,254,257,1,0,0,0,255,253,1,0,0,0,255,256,1,0,0,0,256,259,1,0,0,0,257, + 255,1,0,0,0,258,260,5,16,0,0,259,258,1,0,0,0,259,260,1,0,0,0,260,262,1, + 0,0,0,261,250,1,0,0,0,261,262,1,0,0,0,262,263,1,0,0,0,263,264,5,17,0,0, + 264,51,1,0,0,0,265,266,6,26,-1,0,266,267,5,15,0,0,267,268,3,52,26,0,268, + 269,5,17,0,0,269,319,1,0,0,0,270,271,3,60,30,0,271,272,5,15,0,0,272,275, + 3,52,26,0,273,274,5,16,0,0,274,276,3,52,26,0,275,273,1,0,0,0,275,276,1, + 0,0,0,276,278,1,0,0,0,277,279,5,16,0,0,278,277,1,0,0,0,278,279,1,0,0,0, + 279,280,1,0,0,0,280,281,5,17,0,0,281,319,1,0,0,0,282,319,3,48,24,0,283, + 284,5,24,0,0,284,285,5,74,0,0,285,319,3,50,25,0,286,287,5,27,0,0,287,288, + 5,25,0,0,288,289,3,52,26,0,289,290,5,26,0,0,290,291,7,1,0,0,291,319,1,0, + 0,0,292,293,5,33,0,0,293,294,5,25,0,0,294,295,3,52,26,0,295,296,5,26,0, + 0,296,297,7,2,0,0,297,319,1,0,0,0,298,299,7,3,0,0,299,319,3,52,26,14,300, + 312,5,25,0,0,301,306,3,52,26,0,302,303,5,16,0,0,303,305,3,52,26,0,304,302, + 1,0,0,0,305,308,1,0,0,0,306,304,1,0,0,0,306,307,1,0,0,0,307,310,1,0,0,0, + 308,306,1,0,0,0,309,311,5,16,0,0,310,309,1,0,0,0,310,311,1,0,0,0,311,313, + 1,0,0,0,312,301,1,0,0,0,312,313,1,0,0,0,313,314,1,0,0,0,314,319,5,26,0, + 0,315,319,5,73,0,0,316,319,5,74,0,0,317,319,3,56,28,0,318,265,1,0,0,0,318, + 270,1,0,0,0,318,282,1,0,0,0,318,283,1,0,0,0,318,286,1,0,0,0,318,292,1,0, + 0,0,318,298,1,0,0,0,318,300,1,0,0,0,318,315,1,0,0,0,318,316,1,0,0,0,318, + 317,1,0,0,0,319,369,1,0,0,0,320,321,10,13,0,0,321,322,7,4,0,0,322,368,3, + 52,26,14,323,324,10,12,0,0,324,325,7,5,0,0,325,368,3,52,26,13,326,327,10, + 11,0,0,327,328,7,6,0,0,328,368,3,52,26,12,329,330,10,10,0,0,330,331,7,7, + 0,0,331,368,3,52,26,11,332,333,10,9,0,0,333,334,5,50,0,0,334,368,3,52,26, + 10,335,336,10,8,0,0,336,337,5,4,0,0,337,368,3,52,26,9,338,339,10,7,0,0, + 339,340,5,51,0,0,340,368,3,52,26,8,341,342,10,6,0,0,342,343,5,52,0,0,343, + 368,3,52,26,7,344,345,10,5,0,0,345,346,5,53,0,0,346,368,3,52,26,6,347,348, + 10,20,0,0,348,349,5,25,0,0,349,350,5,64,0,0,350,368,5,26,0,0,351,352,10, + 17,0,0,352,368,7,8,0,0,353,354,10,16,0,0,354,355,5,40,0,0,355,356,5,15, + 0,0,356,357,3,52,26,0,357,358,5,17,0,0,358,368,1,0,0,0,359,360,10,15,0, + 0,360,361,5,41,0,0,361,362,5,15,0,0,362,363,3,52,26,0,363,364,5,16,0,0, + 364,365,3,52,26,0,365,366,5,17,0,0,366,368,1,0,0,0,367,320,1,0,0,0,367, + 323,1,0,0,0,367,326,1,0,0,0,367,329,1,0,0,0,367,332,1,0,0,0,367,335,1,0, + 0,0,367,338,1,0,0,0,367,341,1,0,0,0,367,344,1,0,0,0,367,347,1,0,0,0,367, + 351,1,0,0,0,367,353,1,0,0,0,367,359,1,0,0,0,368,371,1,0,0,0,369,367,1,0, + 0,0,369,370,1,0,0,0,370,53,1,0,0,0,371,369,1,0,0,0,372,373,5,54,0,0,373, + 55,1,0,0,0,374,380,5,62,0,0,375,380,3,58,29,0,376,380,5,69,0,0,377,380, + 5,70,0,0,378,380,5,71,0,0,379,374,1,0,0,0,379,375,1,0,0,0,379,376,1,0,0, + 0,379,377,1,0,0,0,379,378,1,0,0,0,380,57,1,0,0,0,381,383,5,64,0,0,382,384, + 5,63,0,0,383,382,1,0,0,0,383,384,1,0,0,0,384,59,1,0,0,0,385,386,7,9,0,0, + 386,61,1,0,0,0,32,65,80,83,96,108,119,123,125,136,141,151,157,186,196,208, + 228,236,240,242,255,259,261,275,278,306,310,312,318,367,369,379,383]; private static __ATN: ATN; public static get _ATN(): ATN { @@ -2442,6 +2522,9 @@ export class StatementContext extends ParserRuleContext { public ifStatement(): IfStatementContext { return this.getTypedRuleContext(IfStatementContext, 0) as IfStatementContext; } + public loopStatement(): LoopStatementContext { + return this.getTypedRuleContext(LoopStatementContext, 0) as LoopStatementContext; + } public consoleStatement(): ConsoleStatementContext { return this.getTypedRuleContext(ConsoleStatementContext, 0) as ConsoleStatementContext; } @@ -2635,6 +2718,53 @@ export class IfStatementContext extends ParserRuleContext { } +export class LoopStatementContext extends ParserRuleContext { + constructor(parser?: CashScriptParser, parent?: ParserRuleContext, invokingState?: number) { + super(parent, invokingState); + this.parser = parser; + } + public doWhileStatement(): DoWhileStatementContext { + return this.getTypedRuleContext(DoWhileStatementContext, 0) as DoWhileStatementContext; + } + public get ruleIndex(): number { + return CashScriptParser.RULE_loopStatement; + } + // @Override + public accept(visitor: CashScriptVisitor): Result { + if (visitor.visitLoopStatement) { + return visitor.visitLoopStatement(this); + } else { + return visitor.visitChildren(this); + } + } +} + + +export class DoWhileStatementContext extends ParserRuleContext { + constructor(parser?: CashScriptParser, parent?: ParserRuleContext, invokingState?: number) { + super(parent, invokingState); + this.parser = parser; + } + public block(): BlockContext { + return this.getTypedRuleContext(BlockContext, 0) as BlockContext; + } + public expression(): ExpressionContext { + return this.getTypedRuleContext(ExpressionContext, 0) as ExpressionContext; + } + public get ruleIndex(): number { + return CashScriptParser.RULE_doWhileStatement; + } + // @Override + public accept(visitor: CashScriptVisitor): Result { + if (visitor.visitDoWhileStatement) { + return visitor.visitDoWhileStatement(this); + } else { + return visitor.visitChildren(this); + } + } +} + + export class ConsoleStatementContext extends ParserRuleContext { constructor(parser?: CashScriptParser, parent?: ParserRuleContext, invokingState?: number) { super(parent, invokingState); diff --git a/packages/cashc/src/grammar/CashScriptVisitor.ts b/packages/cashc/src/grammar/CashScriptVisitor.ts index 4e161c03..a605fba4 100644 --- a/packages/cashc/src/grammar/CashScriptVisitor.ts +++ b/packages/cashc/src/grammar/CashScriptVisitor.ts @@ -21,6 +21,8 @@ import { AssignStatementContext } from "./CashScriptParser.js"; import { TimeOpStatementContext } from "./CashScriptParser.js"; import { RequireStatementContext } from "./CashScriptParser.js"; import { IfStatementContext } from "./CashScriptParser.js"; +import { LoopStatementContext } from "./CashScriptParser.js"; +import { DoWhileStatementContext } from "./CashScriptParser.js"; import { ConsoleStatementContext } from "./CashScriptParser.js"; import { RequireMessageContext } from "./CashScriptParser.js"; import { ConsoleParameterContext } from "./CashScriptParser.js"; @@ -162,6 +164,18 @@ export default class CashScriptVisitor extends ParseTreeVisitor * @return the visitor result */ visitIfStatement?: (ctx: IfStatementContext) => Result; + /** + * Visit a parse tree produced by `CashScriptParser.loopStatement`. + * @param ctx the parse tree + * @return the visitor result + */ + visitLoopStatement?: (ctx: LoopStatementContext) => Result; + /** + * Visit a parse tree produced by `CashScriptParser.doWhileStatement`. + * @param ctx the parse tree + * @return the visitor result + */ + visitDoWhileStatement?: (ctx: DoWhileStatementContext) => Result; /** * Visit a parse tree produced by `CashScriptParser.consoleStatement`. * @param ctx the parse tree diff --git a/packages/cashc/src/index.ts b/packages/cashc/src/index.ts index a4efe3fc..9ce0b760 100644 --- a/packages/cashc/src/index.ts +++ b/packages/cashc/src/index.ts @@ -2,4 +2,4 @@ export * from './Errors.js'; export * as utils from '@cashscript/utils'; export { compileFile, compileString } from './compiler.js'; -export const version = '0.12.0'; +export const version = '0.13.0-next.0'; diff --git a/packages/cashc/src/print/OutputSourceCodeTraversal.ts b/packages/cashc/src/print/OutputSourceCodeTraversal.ts index df50ee54..d5e6829b 100644 --- a/packages/cashc/src/print/OutputSourceCodeTraversal.ts +++ b/packages/cashc/src/print/OutputSourceCodeTraversal.ts @@ -29,6 +29,7 @@ import { ConsoleStatementNode, ConsoleParameterNode, SliceNode, + DoWhileNode, } from '../ast/AST.js'; import AstTraversal from '../ast/AstTraversal.js'; @@ -163,6 +164,15 @@ export default class OutputSourceCodeTraversal extends AstTraversal { return node; } + visitDoWhile(node: DoWhileNode): Node { + this.addOutput('do ', true); + node.block = this.visit(node.block) as BlockNode; + this.addOutput(' while (', true); + node.condition = this.visit(node.condition); + this.addOutput(');\n'); + return node; + } + visitConsoleStatement(node: ConsoleStatementNode): Node { this.addOutput('console.log(', true); node.parameters = this.visitCommaList(node.parameters) as ConsoleParameterNode[]; diff --git a/packages/cashc/src/semantic/EnsureFinalRequireTraversal.ts b/packages/cashc/src/semantic/EnsureFinalRequireTraversal.ts index 52f29685..52e9f891 100644 --- a/packages/cashc/src/semantic/EnsureFinalRequireTraversal.ts +++ b/packages/cashc/src/semantic/EnsureFinalRequireTraversal.ts @@ -7,6 +7,7 @@ import { TimeOpNode, BranchNode, ConsoleStatementNode, + DoWhileNode, } from '../ast/AST.js'; import AstTraversal from '../ast/AstTraversal.js'; import { EmptyContractError, EmptyFunctionError, FinalRequireStatementError } from '../Errors.js'; @@ -50,6 +51,12 @@ function ensureFinalStatementIsRequire(statements: StatementNode[] = []): void { return; } + // TODO: Revisit this later, for now we allow do-while loops to not have a require() at the end + if (finalStatement instanceof DoWhileNode) { + // ensureFinalStatementIsRequire(finalStatement.block.statements); + return; + } + // The final statement needs to be a require() if (!(finalStatement instanceof RequireNode || finalStatement instanceof TimeOpNode)) { throw new FinalRequireStatementError(finalStatement); diff --git a/packages/cashc/src/semantic/TypeCheckTraversal.ts b/packages/cashc/src/semantic/TypeCheckTraversal.ts index 41bca3e8..55a43fe8 100644 --- a/packages/cashc/src/semantic/TypeCheckTraversal.ts +++ b/packages/cashc/src/semantic/TypeCheckTraversal.ts @@ -29,6 +29,7 @@ import { NullaryOpNode, SliceNode, IntLiteralNode, + DoWhileNode, } from '../ast/AST.js'; import AstTraversal from '../ast/AstTraversal.js'; import { @@ -101,6 +102,17 @@ export default class TypeCheckTraversal extends AstTraversal { return node; } + visitDoWhile(node: DoWhileNode): Node { + node.condition = this.visit(node.condition); + node.block = this.visit(node.block); + + if (!implicitlyCastable(node.condition.type, PrimitiveType.BOOL)) { + throw new TypeError(node, node.condition.type, PrimitiveType.BOOL); + } + + return node; + } + visitCast(node: CastNode): Node { node.expression = this.visit(node.expression); node.size = this.visitOptional(node.size); diff --git a/packages/cashc/test/ast/fixtures.ts b/packages/cashc/test/ast/fixtures.ts index 20ed93b2..56559607 100644 --- a/packages/cashc/test/ast/fixtures.ts +++ b/packages/cashc/test/ast/fixtures.ts @@ -25,6 +25,7 @@ import { UnaryOpNode, InstantiationNode, ConsoleStatementNode, + DoWhileNode, } from '../../src/ast/AST.js'; import { BinaryOperator, NullaryOperator, UnaryOperator } from '../../src/ast/Operator.js'; import { Class, TimeOp } from '../../src/ast/Globals.js'; @@ -933,4 +934,52 @@ export const fixtures: Fixture[] = [ ), ), }, + { + fn: 'do_while_loop.cash', + ast: new SourceFileNode( + new ContractNode( + 'Loopy', + [], + [new FunctionDefinitionNode( + 'doLoop', + [], + new BlockNode([ + new VariableDefinitionNode( + PrimitiveType.INT, + [], + 'i', + new IntLiteralNode(0n), + ), + new DoWhileNode( + new BinaryOpNode( + new IdentifierNode('i'), + BinaryOperator.LT, + new NullaryOpNode(NullaryOperator.INPUT_COUNT), + ), + new BlockNode([ + new AssignNode( + new IdentifierNode('i'), + new BinaryOpNode( + new IdentifierNode('i'), + BinaryOperator.PLUS, + new IntLiteralNode(1n), + ), + ), + ]), + ), + new ConsoleStatementNode([ + new IdentifierNode('i'), + ]), + new RequireNode( + new BinaryOpNode( + new IdentifierNode('i'), + BinaryOperator.GT, + new IntLiteralNode(2n), + ), + ), + ]), + )], + ), + ), + }, ]; diff --git a/packages/cashc/test/compiler/ParseError/while_loop.cash b/packages/cashc/test/compiler/ParseError/while_loop.cash new file mode 100644 index 00000000..e88d0222 --- /dev/null +++ b/packages/cashc/test/compiler/ParseError/while_loop.cash @@ -0,0 +1,12 @@ +contract Loopy() { + function doLoop() { + int i = 0; + + while (i < tx.inputs.length) { + i = i + 1; + } + + console.log(i); + require(i > 2); + } +} diff --git a/packages/cashc/test/compiler/TypeError/do_while_loop_bytes32_condition.cash b/packages/cashc/test/compiler/TypeError/do_while_loop_bytes32_condition.cash new file mode 100644 index 00000000..d5a61eb9 --- /dev/null +++ b/packages/cashc/test/compiler/TypeError/do_while_loop_bytes32_condition.cash @@ -0,0 +1,12 @@ +contract Loopy() { + function doLoop() { + int i = 0; + + do { + i = i + 1; + } while (tx.inputs[0].outpointTransactionHash); + + console.log(i); + require(i > 2); + } +} diff --git a/packages/cashc/test/generation/fixtures.ts b/packages/cashc/test/generation/fixtures.ts index 899539a5..2bf7781b 100644 --- a/packages/cashc/test/generation/fixtures.ts +++ b/packages/cashc/test/generation/fixtures.ts @@ -905,4 +905,55 @@ export const fixtures: Fixture[] = [ updatedAt: '', }, }, + { + fn: 'complex_loop.cash', + artifact: { + contractName: 'Loopy', + constructorInputs: [], + abi: [{ name: 'doLoop', inputs: [] }], + bytecode: 'OP_0 OP_0 OP_0 OP_0 OP_BEGIN OP_DUP OP_UTXOVALUE OP_4 OP_ROLL OP_DROP OP_SWAP OP_TOALTSTACK OP_SWAP OP_TOALTSTACK OP_SWAP OP_FROMALTSTACK OP_FROMALTSTACK OP_DUP OP_1ADD OP_NIP OP_TXOUTPUTCOUNT OP_2DUP OP_LESSTHAN OP_DUP OP_IF OP_2 OP_PICK OP_OUTPUTTOKENCATEGORY OP_0 OP_EQUAL OP_NOT OP_NIP OP_DUP OP_IF OP_4 OP_PICK OP_3 OP_PICK OP_OUTPUTVALUE OP_ADD OP_5 OP_ROLL OP_DROP OP_SWAP OP_TOALTSTACK OP_SWAP OP_TOALTSTACK OP_SWAP OP_TOALTSTACK OP_SWAP OP_FROMALTSTACK OP_FROMALTSTACK OP_FROMALTSTACK OP_ELSE OP_3 OP_PICK OP_1ADD OP_4 OP_ROLL OP_DROP OP_SWAP OP_TOALTSTACK OP_SWAP OP_TOALTSTACK OP_SWAP OP_FROMALTSTACK OP_FROMALTSTACK OP_ENDIF OP_ENDIF OP_2DROP OP_DUP OP_TXINPUTCOUNT OP_GREATERTHANOREQUAL OP_UNTIL OP_2OVER OP_GREATERTHAN OP_VERIFY OP_OVER OP_0 OP_GREATERTHAN OP_VERIFY OP_2DROP OP_2DROP OP_1', + debug: { + bytecode: '000000006576c6547a757c6b7c6b7c6c6c768b77c46e9f76635279d100879177766354795379cc93557a757c6b7c6b7c6b7c6c6c6c6753798b547a757c6b7c6b7c6c6c68686d76c3a26670a0697800a0696d6d51', + sourceMap: '3:23:3:24;4:24:4:25;5:25:5:26;6:16:6:17;8:8:26:39;9:33:9:34;:23::41:1;:12::42;;;;;;;;;;10:16:10:17:0;:::21:1;:12::22;12:20:12:37:0;13:21:13:26;::::1;15:16:15:17:0;:19:25:13;16:31:16:32;;:20::47:1;:51::53:0;:20:::1;;:16::54;18:20:18:21:0;:23:20:17;19:32:19:41;;:55::56;;:44::63:1;:32;:20::64;;;;;;;;;;;;;20:23:22:17:0;21:33:21:43;;:::47:1;:20::48;;;;;;;;;;20:23:22:17;15:19:25:13;8:11:26:9;26:17::18:0;:21::37;8:8::39:1;;28:16:28:36:0;::::1;:8::38;29:16:29:26:0;:29::30;:16:::1;:8::32;2:4:30:5;;', + logs: [ + { ip: 68, line: 24, data: [{ stackIndex: 3, type: 'int', ip: 68 }] }, + ], + requires: [ + { ip: 76, line: 28 }, + { ip: 80, line: 29 }, + ], + }, + source: fs.readFileSync(new URL('../valid-contract-files/complex_loop.cash', import.meta.url), { encoding: 'utf-8' }), + compiler: { + name: 'cashc', + version, + }, + updatedAt: '', + }, + }, + { + fn: 'do_while_loop_no_introspection.cash', + artifact: { + contractName: 'Loopy', + constructorInputs: [], + abi: [{ name: 'doLoop', inputs: [] }], + bytecode: 'OP_0 OP_2 OP_BEGIN OP_OVER OP_1ADD OP_ROT OP_DROP OP_SWAP OP_2DUP OP_ADD OP_10 OP_LESSTHAN OP_VERIFY OP_OVER OP_10 OP_GREATERTHANOREQUAL OP_UNTIL OP_2DROP OP_1', + debug: { + bytecode: '005265788b7b757c6e935a9f69785aa2666d51', + sourceMap: '3:16:3:17;4::4;6:8:10:25;7:16:7:17;:::21:1;:12::22;;;9:20:9:25:0;::::1;:28::30:0;:20:::1;:12::32;10:17:10:18:0;:21::23;6:8::25:1;;2:4:11:5;', + logs: [ + { ip: 8, line: 8, data: [{ stackIndex: 1, type: 'int', ip: 8 }] }, + ], + requires: [ + { ip: 12, line: 9 }, + ], + }, + source: fs.readFileSync(new URL('../valid-contract-files/do_while_loop_no_introspection.cash', import.meta.url), { encoding: 'utf-8' }), + compiler: { + name: 'cashc', + version, + }, + updatedAt: '', + }, + }, ]; diff --git a/packages/cashc/test/valid-contract-files/complex_loop.cash b/packages/cashc/test/valid-contract-files/complex_loop.cash new file mode 100644 index 00000000..338d7525 --- /dev/null +++ b/packages/cashc/test/valid-contract-files/complex_loop.cash @@ -0,0 +1,31 @@ +contract Loopy() { + function doLoop() { + int inputSum = 0; + int outputSum = 0; + int tokenCount = 0; + int i = 0; + + do { + inputSum = tx.inputs[i].value; + i = i + 1; + + int x = tx.outputs.length; + bool b = i < x; + + if (b) { + b = tx.outputs[i].tokenCategory != 0x; + + if (b) { + outputSum = outputSum + tx.outputs[i].value; + } else { + tokenCount = tokenCount + 1; + } + + console.log(tokenCount); + } + } while (i < tx.inputs.length); + + require(inputSum > outputSum); + require(tokenCount > 0); + } +} diff --git a/packages/cashc/test/valid-contract-files/do_while_loop.cash b/packages/cashc/test/valid-contract-files/do_while_loop.cash new file mode 100644 index 00000000..2cfb3292 --- /dev/null +++ b/packages/cashc/test/valid-contract-files/do_while_loop.cash @@ -0,0 +1,12 @@ +contract Loopy() { + function doLoop() { + int i = 0; + + do { + i = i + 1; + } while (i < tx.inputs.length); + + console.log(i); + require(i > 2); + } +} diff --git a/packages/cashc/test/valid-contract-files/do_while_loop_no_introspection.cash b/packages/cashc/test/valid-contract-files/do_while_loop_no_introspection.cash new file mode 100644 index 00000000..a11a89b1 --- /dev/null +++ b/packages/cashc/test/valid-contract-files/do_while_loop_no_introspection.cash @@ -0,0 +1,12 @@ +contract Loopy() { + function doLoop() { + int i = 0; + int x = 2; + + do { + i = i + 1; + console.log(i); + require(i + x < 10); + } while (i < 10); + } +} diff --git a/packages/cashc/test/valid-contract-files/do_while_loop_no_tokens_in_inputs.cash b/packages/cashc/test/valid-contract-files/do_while_loop_no_tokens_in_inputs.cash new file mode 100644 index 00000000..07290469 --- /dev/null +++ b/packages/cashc/test/valid-contract-files/do_while_loop_no_tokens_in_inputs.cash @@ -0,0 +1,13 @@ +pragma cashscript ^0.13.0; + +contract Loopy() { + function doLoop() { + int inputIndex = 0; + + // Loop over all inputs (variable length), and make sure that none of them contain tokens + do { + require(tx.inputs[inputIndex].tokenCategory == 0x); + inputIndex = inputIndex + 1; + } while (inputIndex < tx.inputs.length); + } +} diff --git a/packages/cashc/test/valid-contract-files/do_while_loop_require_inside_loop.cash b/packages/cashc/test/valid-contract-files/do_while_loop_require_inside_loop.cash new file mode 100644 index 00000000..6a751cf4 --- /dev/null +++ b/packages/cashc/test/valid-contract-files/do_while_loop_require_inside_loop.cash @@ -0,0 +1,10 @@ +contract Loopy() { + function doLoop() { + int i = 0; + + do { + i = i + 1; + require(i < 10); + } while (i < tx.inputs.length); + } +} diff --git a/packages/cashc/test/valid-contract-files/do_while_no_require.cash b/packages/cashc/test/valid-contract-files/do_while_no_require.cash new file mode 100644 index 00000000..4b4fa097 --- /dev/null +++ b/packages/cashc/test/valid-contract-files/do_while_no_require.cash @@ -0,0 +1,11 @@ +contract Loopy() { + function doLoop() { + int i = 0; + + require(i < 1); + + do { + i = i + 1; + } while (i < tx.inputs.length); + } +} diff --git a/packages/cashc/test/valid-contract-files/sum_input_amount.cash b/packages/cashc/test/valid-contract-files/sum_input_amount.cash new file mode 100644 index 00000000..ebfefd44 --- /dev/null +++ b/packages/cashc/test/valid-contract-files/sum_input_amount.cash @@ -0,0 +1,14 @@ +contract Loopy() { + function doLoop() { + int sum = 0; + int i = 0; + + do { + sum = tx.inputs[i].value; + i = i + 1; + } while (i < tx.inputs.length); + + console.log(sum); + require(sum > 2000); + } +} diff --git a/packages/cashscript/package.json b/packages/cashscript/package.json index f830fbc2..c82d9147 100644 --- a/packages/cashscript/package.json +++ b/packages/cashscript/package.json @@ -1,6 +1,6 @@ { "name": "cashscript", - "version": "0.12.0", + "version": "0.13.0-next.0", "description": "Easily write and interact with Bitcoin Cash contracts", "keywords": [ "bitcoin cash", @@ -46,7 +46,7 @@ }, "dependencies": { "@bitauth/libauth": "^3.1.0-next.8", - "@cashscript/utils": "^0.12.0", + "@cashscript/utils": "^0.13.0-next.0", "@electrum-cash/network": "^4.1.3", "@mr-zwets/bchn-api-wrapper": "^1.0.1", "pako": "^2.1.0", diff --git a/packages/cashscript/test/debugging.test.ts b/packages/cashscript/test/debugging.test.ts index cdb45bd6..393a0cf3 100644 --- a/packages/cashscript/test/debugging.test.ts +++ b/packages/cashscript/test/debugging.test.ts @@ -1,4 +1,5 @@ import { Contract, FailedTransactionError, MockNetworkProvider, SignatureAlgorithm, SignatureTemplate, TransactionBuilder, VmTarget } from '../src/index.js'; +import { DEFAULT_VM_TARGET } from '../src/libauth-template/utils.js'; import { aliceAddress, alicePriv, alicePub, bobPriv, bobPub } from './fixture/vars.js'; import '../src/test/JestExtensions.js'; import { randomUtxo } from '../src/utils.js'; @@ -14,7 +15,6 @@ import { artifactTestZeroHandling, } from './fixture/debugging/debugging_contracts.js'; import { sha256 } from '@cashscript/utils'; -import { DEFAULT_VM_TARGET } from 'cashscript/src/libauth-template/utils.js'; describe('Debugging tests', () => { describe('console.log statements', () => { diff --git a/packages/utils/package.json b/packages/utils/package.json index d4cdb6bf..27860ed6 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -1,6 +1,6 @@ { "name": "@cashscript/utils", - "version": "0.12.0", + "version": "0.13.0-next.0", "description": "CashScript utilities and types", "keywords": [ "bitcoin cash", diff --git a/packages/utils/src/cashproof-optimisations.ts b/packages/utils/src/cashproof-optimisations.ts index 508101b9..59f64d04 100644 --- a/packages/utils/src/cashproof-optimisations.ts +++ b/packages/utils/src/cashproof-optimisations.ts @@ -125,4 +125,12 @@ OP_2 OP_PICK OP_SWAP OP_2 OP_PICK OP_NIP <=> OP_DROP OP_2DUP; # .slice(0, x) optimisation & .slice(x, y.length) optimisation OP_0 OP_SPLIT OP_NIP <=> ; OP_SIZE OP_SPLIT OP_DROP <=> ; + +# These are new optimisations that we cannot prove since CashProof doesn't work any more +# ////////////////////////////////////////////////////////////////////////////////////// + +OP_LESSTHAN OP_NOT <=> OP_GREATERTHANOREQUAL; +OP_GREATERTHAN OP_NOT <=> OP_LESSTHANOREQUAL; +OP_LESSTHANOREQUAL OP_NOT <=> OP_GREATERTHAN; +OP_GREATERTHANOREQUAL OP_NOT <=> OP_LESSTHAN; `; diff --git a/packages/utils/src/optimisations.ts b/packages/utils/src/optimisations.ts index 6477a794..651a682e 100644 --- a/packages/utils/src/optimisations.ts +++ b/packages/utils/src/optimisations.ts @@ -137,6 +137,18 @@ const unprovableOptimisations = [ // CashProof can't prove bitwise operators ['OP_DUP OP_AND', ''], ['OP_DUP OP_OR', ''], + + // These are new optimisations that we cannot prove since CashProof doesn't work any more + // ////////////////////////////////////////////////////////////////////////////////////// + + // TODO: Enable this optimisation when we overhaul the type system + // (right now bool(4) == true => false, but !!bool(4) == true => true) so can't replace OP_NOT OP_NOT with '' + // ['OP_NOT OP_NOT', ''] + + ['OP_LESSTHAN OP_NOT', 'OP_GREATERTHANOREQUAL'], + ['OP_GREATERTHAN OP_NOT', 'OP_LESSTHANOREQUAL'], + ['OP_LESSTHANOREQUAL OP_NOT', 'OP_GREATERTHAN'], + ['OP_GREATERTHANOREQUAL OP_NOT', 'OP_LESSTHAN'], ] as [string, string][]; // Note: we moved these optimisations into a single file, but kept the exact same order as before, diff --git a/packages/utils/src/script.ts b/packages/utils/src/script.ts index 9519dedc..854b5864 100644 --- a/packages/utils/src/script.ts +++ b/packages/utils/src/script.ts @@ -1,18 +1,19 @@ import { - OpcodesBch2023, encodeDataPush, hexToBin, disassembleBytecodeBch, flattenBinArray, encodeAuthenticationInstructions, decodeAuthenticationInstructions, + OpcodesBch, + AuthenticationInstruction, } from '@bitauth/libauth'; import OptimisationsEquivFile from './cashproof-optimisations.js'; import { optimisationReplacements } from './optimisations.js'; import { FullLocationData, PositionHint, SingleLocationData } from './types.js'; import { LogEntry, RequireStatement } from './artifact.js'; -export const Op = OpcodesBch2023; +export const Op = OpcodesBch; export type Op = number; export type OpOrData = Op | Uint8Array; export type Script = OpOrData[]; @@ -66,8 +67,10 @@ export function asmToBytecode(asm: string): Uint8Array { // Convert the ASM tokens to AuthenticationInstructions const instructions = asm.split(' ').map((token) => { + // Even though the OpcodesBch type allows for { [key: number]: string }, we know that the keys are always the opcodes + // so we can safely cast to the AuthenticationInstruction type if (token.startsWith('OP_')) { - return { opcode: Op[token as keyof typeof Op] }; + return { opcode: Op[token as keyof typeof Op] } as AuthenticationInstruction; } const data = token.replace(/<|>/g, '').replace(/^0x/, ''); diff --git a/packages/utils/test/manual-optimisation-proofs.test.ts b/packages/utils/test/manual-optimisation-proofs.test.ts new file mode 100644 index 00000000..d2a50d13 --- /dev/null +++ b/packages/utils/test/manual-optimisation-proofs.test.ts @@ -0,0 +1,57 @@ +describe('Manual Optimisation Proofs', () => { + it.todo('Properly implement automated tests'); + // <1> <2> OP_GREATERTHAN OP_NOT + // <1> <2> OP_LESSTHANOREQUAL + // OP_EQUALVERIFY + + // <2> <1> OP_GREATERTHAN OP_NOT + // <2> <1> OP_LESSTHANOREQUAL + // OP_EQUALVERIFY + + // <1> <1> OP_GREATERTHAN OP_NOT + // <1> <1> OP_LESSTHANOREQUAL + // OP_EQUALVERIFY + + + + + // <1> <2> OP_LESSTHAN OP_NOT + // <1> <2> OP_GREATERTHANOREQUAL + // OP_EQUALVERIFY + + // <2> <1> OP_LESSTHAN OP_NOT + // <2> <1> OP_GREATERTHANOREQUAL + // OP_EQUALVERIFY + + // <1> <1> OP_LESSTHAN OP_NOT + // <1> <1> OP_GREATERTHANOREQUAL + // OP_EQUALVERIFY + + + + // <1> <2> OP_LESSTHANOREQUAL OP_NOT + // <1> <2> OP_GREATERTHAN + // OP_EQUALVERIFY + + // <2> <1> OP_LESSTHANOREQUAL OP_NOT + // <2> <1> OP_GREATERTHAN + // OP_EQUALVERIFY + + // <1> <1> OP_LESSTHANOREQUAL OP_NOT + // <1> <1> OP_GREATERTHAN + // OP_EQUALVERIFY + + + + // <1> <2> OP_GREATERTHANOREQUAL OP_NOT + // <1> <2> OP_LESSTHAN + // OP_EQUALVERIFY + + // <2> <1> OP_GREATERTHANOREQUAL OP_NOT + // <2> <1> OP_LESSTHAN + // OP_EQUALVERIFY + + // <1> <1> OP_GREATERTHANOREQUAL OP_NOT + // <1> <1> OP_LESSTHAN + // OP_EQUALVERIFY +}); diff --git a/website/docs/basics/getting-started.md b/website/docs/basics/getting-started.md index e8bf5182..94ea33e8 100644 --- a/website/docs/basics/getting-started.md +++ b/website/docs/basics/getting-started.md @@ -52,7 +52,7 @@ We can start from a basic `TransferWithTimeout` smart contract, a simple contrac Open your code editor to start writing your first CashScript smart contract. Then create a new file `TransferWithTimeout.cash` and copy over the smart contracts code from below. ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract TransferWithTimeout(pubkey sender, pubkey recipient, int timeout) { // Allow the recipient to claim their received money diff --git a/website/docs/language/contracts.md b/website/docs/language/contracts.md index 8ee365ff..6c8175a8 100644 --- a/website/docs/language/contracts.md +++ b/website/docs/language/contracts.md @@ -13,7 +13,7 @@ Contract authors should be careful when allowing a range of versions to check th #### Example ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; pragma cashscript >= 0.7.0 < 0.9.3; ``` @@ -22,7 +22,7 @@ A CashScript constructor works slightly differently than what you might be used #### Example ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract HTLC(pubkey sender, pubkey recipient, int expiration, bytes32 hash) { ... @@ -46,7 +46,7 @@ The main construct in a CashScript contract is the function. A contract can cont #### Example ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract TransferWithTimeout(pubkey sender, pubkey recipient, int timeout) { function transfer(sig recipientSig) { @@ -89,7 +89,7 @@ The error message in a `require` statement is only available in debug evaluation #### Example ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract P2PKH(bytes20 pkh) { function spend(pubkey pk, sig s) { @@ -122,8 +122,8 @@ hashedValue = sha256(hashedValue); myString = 'Cash'; ``` -### Control structures -The only control structures in CashScript are `if...else` statements. This is due to limitations in the underlying Bitcoin Script which prevents loops, recursion, and `return` statements. If-else statements follow usual semantics known from languages like C or JavaScript. +### If statements +If and if-else statements follow usual semantics known from languages like C or JavaScript. If the condition within the `if` statement evaluates to `true`, the block of code within the `if` statement is executed. If the condition evaluates to `false`, the block of code within the optional `else` statement is executed. :::note There is no implicit type conversion from non-boolean to boolean types. So `if (1) { ... }` is not valid CashScript and should instead be written as `if (bool(1)) { ... }` @@ -131,7 +131,7 @@ There is no implicit type conversion from non-boolean to boolean types. So `if ( #### Example ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract OneOfTwo(bytes20 pkh1, bytes32 hash1, bytes20 pkh2, bytes32 hash2) { function spend(pubkey pk, sig s, bytes message) { @@ -149,6 +149,31 @@ contract OneOfTwo(bytes20 pkh1, bytes32 hash1, bytes20 pkh2, bytes32 hash2) { } ``` +### Loops (beta) + +Currently, CashScript only supports `do {} while ()` loops in the 0.13.0-next.0 pre-release. More advanced loop constructs will be added in the full 0.13.0 release. Keep in mind that in a `do {} while ()` loop, the condition is checked *after* the block of code within the loop is executed. This means that the block of code within the loop will be executed at least once, even if the condition is initially `false`. + +:::caution +Loops in CashScript are currently in beta and may not fully behave as expected with debugging and console.log statements. The syntax for loops may change in the future. +::: + +#### Example +```solidity +pragma cashscript ^0.13.0; + +contract NoTokensAllowed() { + function spend() { + int inputIndex = 0; + + // Loop over all inputs (variable length), and make sure that none of them contain tokens + do { + require(tx.inputs[inputIndex].tokenCategory == 0x); + inputIndex = inputIndex + 1; + } while (inputIndex < tx.inputs.length); + } +} +``` + ### console.log() The `console.log` statement can be used to log values during debug evaluation of a transaction. Any variables or primitive values (such as ints, strings, bytes, etc) can be logged. You can read more about debugging in the [debugging guide](/docs/guides/debugging). @@ -158,7 +183,7 @@ Logging is only available in debug evaluation of a transaction, but has no impac #### Example ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract P2PKH(bytes20 pkh) { function spend(pubkey pk, sig s) { diff --git a/website/docs/language/examples.md b/website/docs/language/examples.md index 80c12567..ab86a9eb 100644 --- a/website/docs/language/examples.md +++ b/website/docs/language/examples.md @@ -12,7 +12,7 @@ This smart contract works by connecting with a price oracle. This price oracle i This involves some degree of trust in the price oracle, but since the oracle produces price data for everyone to use, their incentive to attack *your* smart contract is minimised. To improve this situation, you can also choose to connect with multiple oracle providers so you do not have to trust a single party. ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; // A minimum block is provided to ensure that oracle price entries from before // this block are disregarded. i.e. when the BCH price was $1000 in the past, @@ -53,7 +53,7 @@ The contract works by checking that a UTXO is at least 30 days old, after which Due to the nature of covenants, we have to be very specific about the outputs (amounts and destinations) of the transaction. This also means that we have to account for the special case where the remaining contract balance is lower than the `pledge` amount, meaning no remainder should be sent back. Finally, we have to account for a small fee that has to be taken from the contract's balance to pay the miners. ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract Mecenas(bytes20 recipient, bytes20 funder, int pledge, int period) { function receive() { @@ -95,7 +95,7 @@ AMM DEX contract based on [the Cauldron DEX contract](https://www.cauldron.quest The CashScript contract code has the big advantage of abstracting away any stack management, having variable names, explicit types and a logical order of operations (compared to the 'reverse Polish notation' of raw script). ```solidity -pragma cashscript ^0.12.0; +pragma cashscript ^0.13.0; contract DexContract(bytes20 poolOwnerPkh) { function swap() { diff --git a/website/docs/releases/release-notes.md b/website/docs/releases/release-notes.md index aaa86016..c7f12a1d 100644 --- a/website/docs/releases/release-notes.md +++ b/website/docs/releases/release-notes.md @@ -4,6 +4,10 @@ title: Release Notes ## v0.13.0-next.0 +#### cashc compiler +- :sparkles: Add support for `do {} while ()` loops. +- :racehorse: Add optimisations for negated number comparisons. + #### CashScript SDK - :hammer_and_wrench: Update default VM target to `BCH_2026_05`.