From 7cdf1be916b450fde5e1821e8dac13e18b339661 Mon Sep 17 00:00:00 2001 From: Seth Kinast Date: Thu, 4 Sep 2014 18:40:42 -0700 Subject: [PATCH 1/5] Upgrade to pegJS 0.8 Upstream changes that affect us: - line and column variables are now functions - parser.toSource() removed in favor of a generator option that switches between an object and string versions --- Gruntfile.js | 8 +- bower.json | 2 +- lib/parser.js | 4839 +++++++++++++-------------- package.json | 2 +- src/build.js | 5 +- src/dust.pegjs | 54 +- test/jasmine-test/spec/coreTests.js | 10 +- 7 files changed, 2370 insertions(+), 2550 deletions(-) diff --git a/Gruntfile.js b/Gruntfile.js index d7d286a2..08bdda47 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -192,9 +192,9 @@ module.exports = function(grunt) { report: 'tmp/coverage', thresholds: { lines: 82, - statements: 83, - branches: 73, - functions: 89 + statements: 82, + branches: 70, + functions: 88 } } } @@ -305,4 +305,4 @@ module.exports = function(grunt) { //default task - full test grunt.registerTask('default', ['test']); -}; \ No newline at end of file +}; diff --git a/bower.json b/bower.json index 42f9545f..1b92f8cc 100644 --- a/bower.json +++ b/bower.json @@ -3,7 +3,7 @@ "version": "2.4.1", "main": "dist/dust-full.min.js", "devDependencies": { - "pegjs": "0.7.0" + "pegjs": "0.8.0" }, "ignore": [ "**/.*", diff --git a/lib/parser.js b/lib/parser.js index e683df63..745acaf9 100644 --- a/lib/parser.js +++ b/lib/parser.js @@ -9,2811 +9,2630 @@ factory(root.dust); } }(this, function(dust) { - var parser = (function(){ + var parser = (function() { /* - * Generated by PEG.js 0.7.0. + * Generated by PEG.js 0.8.0. * * http://pegjs.majda.cz/ */ - - function quote(s) { - /* - * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a - * string literal except for the closing quote character, backslash, - * carriage return, line separator, paragraph separator, and line feed. - * Any character may appear in the form of an escape sequence. - * - * For portability, we also escape escape all control and non-ASCII - * characters. Note that "\0" and "\v" escape sequences are not used - * because JSHint does not like the first and IE the second. - */ - return '"' + s - .replace(/\\/g, '\\\\') // backslash - .replace(/"/g, '\\"') // closing quote character - .replace(/\x08/g, '\\b') // backspace - .replace(/\t/g, '\\t') // horizontal tab - .replace(/\n/g, '\\n') // line feed - .replace(/\f/g, '\\f') // form feed - .replace(/\r/g, '\\r') // carriage return - .replace(/[\x00-\x07\x0B\x0E-\x1F\x80-\uFFFF]/g, escape) - + '"'; + + function peg$subclass(child, parent) { + function ctor() { this.constructor = child; } + ctor.prototype = parent.prototype; + child.prototype = new ctor(); } - - var result = { - /* - * Parses the input with a generated parser. If the parsing is successfull, - * returns a value explicitly or implicitly specified by the grammar from - * which the parser was generated (see |PEG.buildParser|). If the parsing is - * unsuccessful, throws |PEG.parser.SyntaxError| describing the error. - */ - parse: function(input, startRule) { - var parseFunctions = { - "body": parse_body, - "part": parse_part, - "section": parse_section, - "sec_tag_start": parse_sec_tag_start, - "end_tag": parse_end_tag, - "context": parse_context, - "params": parse_params, - "bodies": parse_bodies, - "reference": parse_reference, - "partial": parse_partial, - "filters": parse_filters, - "special": parse_special, - "identifier": parse_identifier, - "number": parse_number, - "float": parse_float, - "integer": parse_integer, - "path": parse_path, - "key": parse_key, - "array": parse_array, - "array_part": parse_array_part, - "inline": parse_inline, - "inline_part": parse_inline_part, - "buffer": parse_buffer, - "literal": parse_literal, - "esc": parse_esc, - "raw": parse_raw, - "comment": parse_comment, - "tag": parse_tag, - "ld": parse_ld, - "rd": parse_rd, - "lb": parse_lb, - "rb": parse_rb, - "eol": parse_eol, - "ws": parse_ws - }; - - if (startRule !== undefined) { - if (parseFunctions[startRule] === undefined) { - throw new Error("Invalid rule name: " + quote(startRule) + "."); - } - } else { - startRule = "body"; - } - - var pos = { offset: 0, line: 1, column: 1, seenCR: false }; - var reportFailures = 0; - var rightmostFailuresPos = { offset: 0, line: 1, column: 1, seenCR: false }; - var rightmostFailuresExpected = []; - - function padLeft(input, padding, length) { - var result = input; - - var padLength = length - input.length; - for (var i = 0; i < padLength; i++) { - result = padding + result; - } - - return result; - } - - function escape(ch) { - var charCode = ch.charCodeAt(0); - var escapeChar; - var length; - - if (charCode <= 0xFF) { - escapeChar = 'x'; - length = 2; - } else { - escapeChar = 'u'; - length = 4; - } - - return '\\' + escapeChar + padLeft(charCode.toString(16).toUpperCase(), '0', length); - } - - function clone(object) { - var result = {}; - for (var key in object) { - result[key] = object[key]; - } - return result; - } - - function advance(pos, n) { - var endOffset = pos.offset + n; - - for (var offset = pos.offset; offset < endOffset; offset++) { - var ch = input.charAt(offset); + + function SyntaxError(message, expected, found, offset, line, column) { + this.message = message; + this.expected = expected; + this.found = found; + this.offset = offset; + this.line = line; + this.column = column; + + this.name = "SyntaxError"; + } + + peg$subclass(SyntaxError, Error); + + function parse(input) { + var options = arguments.length > 1 ? arguments[1] : {}, + + peg$FAILED = {}, + + peg$startRuleFunctions = { start: peg$parsestart }, + peg$startRuleFunction = peg$parsestart, + + peg$c0 = [], + peg$c1 = function(p) { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) }, + peg$c2 = { type: "other", description: "section" }, + peg$c3 = peg$FAILED, + peg$c4 = null, + peg$c5 = function(t, b, e, n) {if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line()+", column : " + column())} return true;}, + peg$c6 = void 0, + peg$c7 = function(t, b, e, n) { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line()], ['col', column()]]) }, + peg$c8 = "/", + peg$c9 = { type: "literal", value: "/", description: "\"/\"" }, + peg$c10 = function(t) { t.push(["bodies"]); return t.concat([['line', line()], ['col', column()]]) }, + peg$c11 = /^[#?\^<+@%]/, + peg$c12 = { type: "class", value: "[#?\\^<+@%]", description: "[#?\\^<+@%]" }, + peg$c13 = function(t, n, c, p) { return [t, n, c, p] }, + peg$c14 = { type: "other", description: "end tag" }, + peg$c15 = function(n) { return n }, + peg$c16 = ":", + peg$c17 = { type: "literal", value: ":", description: "\":\"" }, + peg$c18 = function(n) {return n}, + peg$c19 = function(n) { return n ? ["context", n] : ["context"] }, + peg$c20 = { type: "other", description: "params" }, + peg$c21 = "=", + peg$c22 = { type: "literal", value: "=", description: "\"=\"" }, + peg$c23 = function(k, v) {return ["param", ["literal", k], v]}, + peg$c24 = function(p) { return ["params"].concat(p) }, + peg$c25 = { type: "other", description: "bodies" }, + peg$c26 = function(p) { return ["bodies"].concat(p) }, + peg$c27 = { type: "other", description: "reference" }, + peg$c28 = function(n, f) { return ["reference", n, f].concat([['line', line()], ['col', column()]]) }, + peg$c29 = { type: "other", description: "partial" }, + peg$c30 = ">", + peg$c31 = { type: "literal", value: ">", description: "\">\"" }, + peg$c32 = "+", + peg$c33 = { type: "literal", value: "+", description: "\"+\"" }, + peg$c34 = function(k) {return ["literal", k]}, + peg$c35 = function(s, n, c, p) { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line()], ['col', column()]]) }, + peg$c36 = { type: "other", description: "filters" }, + peg$c37 = "|", + peg$c38 = { type: "literal", value: "|", description: "\"|\"" }, + peg$c39 = function(f) { return ["filters"].concat(f) }, + peg$c40 = { type: "other", description: "special" }, + peg$c41 = "~", + peg$c42 = { type: "literal", value: "~", description: "\"~\"" }, + peg$c43 = function(k) { return ["special", k].concat([['line', line()], ['col', column()]]) }, + peg$c44 = { type: "other", description: "identifier" }, + peg$c45 = function(p) { var arr = ["path"].concat(p); arr.text = p[1].join('.'); return arr; }, + peg$c46 = function(k) { var arr = ["key", k]; arr.text = k; return arr; }, + peg$c47 = { type: "other", description: "number" }, + peg$c48 = function(n) { return ['literal', n]; }, + peg$c49 = { type: "other", description: "float" }, + peg$c50 = ".", + peg$c51 = { type: "literal", value: ".", description: "\".\"" }, + peg$c52 = function(l, r) { return parseFloat(l + "." + r.join('')); }, + peg$c53 = { type: "other", description: "integer" }, + peg$c54 = /^[0-9]/, + peg$c55 = { type: "class", value: "[0-9]", description: "[0-9]" }, + peg$c56 = function(digits) { return parseInt(digits.join(""), 10); }, + peg$c57 = { type: "other", description: "path" }, + peg$c58 = function(k, d) { + d = d[0]; + if (k && d) { + d.unshift(k); + return [false, d].concat([['line', line()], ['col', column()]]); + } + return [true, d].concat([['line', line()], ['col', column()]]); + }, + peg$c59 = function(d) { + if (d.length > 0) { + return [true, d[0]].concat([['line', line()], ['col', column()]]); + } + return [true, []].concat([['line', line()], ['col', column()]]); + }, + peg$c60 = { type: "other", description: "key" }, + peg$c61 = /^[a-zA-Z_$]/, + peg$c62 = { type: "class", value: "[a-zA-Z_$]", description: "[a-zA-Z_$]" }, + peg$c63 = /^[0-9a-zA-Z_$\-]/, + peg$c64 = { type: "class", value: "[0-9a-zA-Z_$\\-]", description: "[0-9a-zA-Z_$\\-]" }, + peg$c65 = function(h, t) { return h + t.join('') }, + peg$c66 = { type: "other", description: "array" }, + peg$c67 = function(n) {return n.join('')}, + peg$c68 = function(a) {return a; }, + peg$c69 = function(i, nk) { if(nk) { nk.unshift(i); } else {nk = [i] } return nk; }, + peg$c70 = { type: "other", description: "array_part" }, + peg$c71 = function(k) {return k}, + peg$c72 = function(d, a) { if (a) { return d.concat(a); } else { return d; } }, + peg$c73 = { type: "other", description: "inline" }, + peg$c74 = "\"", + peg$c75 = { type: "literal", value: "\"", description: "\"\\\"\"" }, + peg$c76 = function() { return ["literal", ""].concat([['line', line()], ['col', column()]]) }, + peg$c77 = function(l) { return ["literal", l].concat([['line', line()], ['col', column()]]) }, + peg$c78 = function(l) { return ["buffer", l] }, + peg$c79 = { type: "other", description: "buffer" }, + peg$c80 = function(e, w) { return ["format", e, w.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c81 = { type: "any", description: "any character" }, + peg$c82 = function(c) {return c}, + peg$c83 = function(b) { return ["buffer", b.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c84 = { type: "other", description: "literal" }, + peg$c85 = /^[^"]/, + peg$c86 = { type: "class", value: "[^\"]", description: "[^\"]" }, + peg$c87 = function(b) { return b.join('') }, + peg$c88 = "\\\"", + peg$c89 = { type: "literal", value: "\\\"", description: "\"\\\\\\\"\"" }, + peg$c90 = function() { return '"' }, + peg$c91 = { type: "other", description: "raw" }, + peg$c92 = "{`", + peg$c93 = { type: "literal", value: "{`", description: "\"{`\"" }, + peg$c94 = "`}", + peg$c95 = { type: "literal", value: "`}", description: "\"`}\"" }, + peg$c96 = function(char) {return char}, + peg$c97 = function(rawText) { return ["raw", rawText.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c98 = { type: "other", description: "comment" }, + peg$c99 = "{!", + peg$c100 = { type: "literal", value: "{!", description: "\"{!\"" }, + peg$c101 = "!}", + peg$c102 = { type: "literal", value: "!}", description: "\"!}\"" }, + peg$c103 = function(c) { return ["comment", c.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c104 = /^[#?\^><+%:@\/~%]/, + peg$c105 = { type: "class", value: "[#?\\^><+%:@\\/~%]", description: "[#?\\^><+%:@\\/~%]" }, + peg$c106 = "{", + peg$c107 = { type: "literal", value: "{", description: "\"{\"" }, + peg$c108 = "}", + peg$c109 = { type: "literal", value: "}", description: "\"}\"" }, + peg$c110 = "[", + peg$c111 = { type: "literal", value: "[", description: "\"[\"" }, + peg$c112 = "]", + peg$c113 = { type: "literal", value: "]", description: "\"]\"" }, + peg$c114 = "\n", + peg$c115 = { type: "literal", value: "\n", description: "\"\\n\"" }, + peg$c116 = "\r\n", + peg$c117 = { type: "literal", value: "\r\n", description: "\"\\r\\n\"" }, + peg$c118 = "\r", + peg$c119 = { type: "literal", value: "\r", description: "\"\\r\"" }, + peg$c120 = "\u2028", + peg$c121 = { type: "literal", value: "\u2028", description: "\"\\u2028\"" }, + peg$c122 = "\u2029", + peg$c123 = { type: "literal", value: "\u2029", description: "\"\\u2029\"" }, + peg$c124 = /^[\t\x0B\f \xA0\uFEFF]/, + peg$c125 = { type: "class", value: "[\\t\\x0B\\f \\xA0\\uFEFF]", description: "[\\t\\x0B\\f \\xA0\\uFEFF]" }, + + peg$currPos = 0, + peg$reportedPos = 0, + peg$cachedPos = 0, + peg$cachedPosDetails = { line: 1, column: 1, seenCR: false }, + peg$maxFailPos = 0, + peg$maxFailExpected = [], + peg$silentFails = 0, + + peg$result; + + if ("startRule" in options) { + if (!(options.startRule in peg$startRuleFunctions)) { + throw new Error("Can't start parsing from rule \"" + options.startRule + "\"."); + } + + peg$startRuleFunction = peg$startRuleFunctions[options.startRule]; + } + + function text() { + return input.substring(peg$reportedPos, peg$currPos); + } + + function offset() { + return peg$reportedPos; + } + + function line() { + return peg$computePosDetails(peg$reportedPos).line; + } + + function column() { + return peg$computePosDetails(peg$reportedPos).column; + } + + function expected(description) { + throw peg$buildException( + null, + [{ type: "other", description: description }], + peg$reportedPos + ); + } + + function error(message) { + throw peg$buildException(message, null, peg$reportedPos); + } + + function peg$computePosDetails(pos) { + function advance(details, startPos, endPos) { + var p, ch; + + for (p = startPos; p < endPos; p++) { + ch = input.charAt(p); if (ch === "\n") { - if (!pos.seenCR) { pos.line++; } - pos.column = 1; - pos.seenCR = false; + if (!details.seenCR) { details.line++; } + details.column = 1; + details.seenCR = false; } else if (ch === "\r" || ch === "\u2028" || ch === "\u2029") { - pos.line++; - pos.column = 1; - pos.seenCR = true; + details.line++; + details.column = 1; + details.seenCR = true; } else { - pos.column++; - pos.seenCR = false; - } - } - - pos.offset += n; - } - - function matchFailed(failure) { - if (pos.offset < rightmostFailuresPos.offset) { - return; - } - - if (pos.offset > rightmostFailuresPos.offset) { - rightmostFailuresPos = clone(pos); - rightmostFailuresExpected = []; - } - - rightmostFailuresExpected.push(failure); - } - - function parse_body() { - var result0, result1; - var pos0; - - pos0 = clone(pos); - result0 = []; - result1 = parse_part(); - while (result1 !== null) { - result0.push(result1); - result1 = parse_part(); - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["body"].concat(p).concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_part() { - var result0; - - result0 = parse_raw(); - if (result0 === null) { - result0 = parse_comment(); - if (result0 === null) { - result0 = parse_section(); - if (result0 === null) { - result0 = parse_partial(); - if (result0 === null) { - result0 = parse_special(); - if (result0 === null) { - result0 = parse_reference(); - if (result0 === null) { - result0 = parse_buffer(); - } + details.column++; + details.seenCR = false; + } + } + } + + if (peg$cachedPos !== pos) { + if (peg$cachedPos > pos) { + peg$cachedPos = 0; + peg$cachedPosDetails = { line: 1, column: 1, seenCR: false }; + } + advance(peg$cachedPosDetails, peg$cachedPos, pos); + peg$cachedPos = pos; + } + + return peg$cachedPosDetails; + } + + function peg$fail(expected) { + if (peg$currPos < peg$maxFailPos) { return; } + + if (peg$currPos > peg$maxFailPos) { + peg$maxFailPos = peg$currPos; + peg$maxFailExpected = []; + } + + peg$maxFailExpected.push(expected); + } + + function peg$buildException(message, expected, pos) { + function cleanupExpected(expected) { + var i = 1; + + expected.sort(function(a, b) { + if (a.description < b.description) { + return -1; + } else if (a.description > b.description) { + return 1; + } else { + return 0; + } + }); + + while (i < expected.length) { + if (expected[i - 1] === expected[i]) { + expected.splice(i, 1); + } else { + i++; + } + } + } + + function buildMessage(expected, found) { + function stringEscape(s) { + function hex(ch) { return ch.charCodeAt(0).toString(16).toUpperCase(); } + + return s + .replace(/\\/g, '\\\\') + .replace(/"/g, '\\"') + .replace(/\x08/g, '\\b') + .replace(/\t/g, '\\t') + .replace(/\n/g, '\\n') + .replace(/\f/g, '\\f') + .replace(/\r/g, '\\r') + .replace(/[\x00-\x07\x0B\x0E\x0F]/g, function(ch) { return '\\x0' + hex(ch); }) + .replace(/[\x10-\x1F\x80-\xFF]/g, function(ch) { return '\\x' + hex(ch); }) + .replace(/[\u0180-\u0FFF]/g, function(ch) { return '\\u0' + hex(ch); }) + .replace(/[\u1080-\uFFFF]/g, function(ch) { return '\\u' + hex(ch); }); + } + + var expectedDescs = new Array(expected.length), + expectedDesc, foundDesc, i; + + for (i = 0; i < expected.length; i++) { + expectedDescs[i] = expected[i].description; + } + + expectedDesc = expected.length > 1 + ? expectedDescs.slice(0, -1).join(", ") + + " or " + + expectedDescs[expected.length - 1] + : expectedDescs[0]; + + foundDesc = found ? "\"" + stringEscape(found) + "\"" : "end of input"; + + return "Expected " + expectedDesc + " but " + foundDesc + " found."; + } + + var posDetails = peg$computePosDetails(pos), + found = pos < input.length ? input.charAt(pos) : null; + + if (expected !== null) { + cleanupExpected(expected); + } + + return new SyntaxError( + message !== null ? message : buildMessage(expected, found), + expected, + found, + pos, + posDetails.line, + posDetails.column + ); + } + + function peg$parsestart() { + var s0; + + s0 = peg$parsebody(); + + return s0; + } + + function peg$parsebody() { + var s0, s1, s2; + + s0 = peg$currPos; + s1 = []; + s2 = peg$parsepart(); + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$parsepart(); + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c1(s1); + } + s0 = s1; + + return s0; + } + + function peg$parsepart() { + var s0; + + s0 = peg$parseraw(); + if (s0 === peg$FAILED) { + s0 = peg$parsecomment(); + if (s0 === peg$FAILED) { + s0 = peg$parsesection(); + if (s0 === peg$FAILED) { + s0 = peg$parsepartial(); + if (s0 === peg$FAILED) { + s0 = peg$parsespecial(); + if (s0 === peg$FAILED) { + s0 = peg$parsereference(); + if (s0 === peg$FAILED) { + s0 = peg$parsebuffer(); } } } } } - return result0; - } - - function parse_section() { - var result0, result1, result2, result3, result4, result5, result6; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_sec_tag_start(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - result2 = parse_rd(); - if (result2 !== null) { - result3 = parse_body(); - if (result3 !== null) { - result4 = parse_bodies(); - if (result4 !== null) { - result5 = parse_end_tag(); - result5 = result5 !== null ? result5 : ""; - if (result5 !== null) { - result6 = (function(offset, line, column, t, b, e, n) {if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line+", column : " + column)} return true;})(pos.offset, pos.line, pos.column, result0, result3, result4, result5) ? "" : null; - if (result6 !== null) { - result0 = [result0, result1, result2, result3, result4, result5, result6]; - } else { - result0 = null; - pos = clone(pos1); - } + } + + return s0; + } + + function peg$parsesection() { + var s0, s1, s2, s3, s4, s5, s6, s7; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsesec_tag_start(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + s3 = peg$parserd(); + if (s3 !== peg$FAILED) { + s4 = peg$parsebody(); + if (s4 !== peg$FAILED) { + s5 = peg$parsebodies(); + if (s5 !== peg$FAILED) { + s6 = peg$parseend_tag(); + if (s6 === peg$FAILED) { + s6 = peg$c4; + } + if (s6 !== peg$FAILED) { + peg$reportedPos = peg$currPos; + s7 = peg$c5(s1, s4, s5, s6); + if (s7) { + s7 = peg$c6; } else { - result0 = null; - pos = clone(pos1); + s7 = peg$c3; + } + if (s7 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c7(s1, s4, s5, s6); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, t, b, e, n) { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[0], result0[3], result0[4], result0[5]); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_sec_tag_start(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 47) { - result2 = "/"; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"/\""); - } - } - if (result2 !== null) { - result3 = parse_rd(); - if (result3 !== null) { - result0 = [result0, result1, result2, result3]; - } else { - result0 = null; - pos = clone(pos1); - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = peg$parsesec_tag_start(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 47) { + s3 = peg$c8; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c9); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parserd(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c10(s1); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, t) { t.push(["bodies"]); return t.concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[0]); - } - if (result0 === null) { - pos = clone(pos0); - } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("section"); - } - return result0; - } - - function parse_sec_tag_start() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1; - - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (/^[#?^<+@%]/.test(input.charAt(pos.offset))) { - result1 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("[#?^<+@%]"); - } + peg$currPos = s0; + s0 = peg$c3; } - if (result1 !== null) { - result2 = []; - result3 = parse_ws(); - while (result3 !== null) { - result2.push(result3); - result3 = parse_ws(); - } - if (result2 !== null) { - result3 = parse_identifier(); - if (result3 !== null) { - result4 = parse_context(); - if (result4 !== null) { - result5 = parse_params(); - if (result5 !== null) { - result0 = [result0, result1, result2, result3, result4, result5]; - } else { - result0 = null; - pos = clone(pos1); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c2); } + } + + return s0; + } + + function peg$parsesec_tag_start() { + var s0, s1, s2, s3, s4, s5, s6; + + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (peg$c11.test(input.charAt(peg$currPos))) { + s2 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c12); } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parsews(); + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + if (s3 !== peg$FAILED) { + s4 = peg$parseidentifier(); + if (s4 !== peg$FAILED) { + s5 = peg$parsecontext(); + if (s5 !== peg$FAILED) { + s6 = peg$parseparams(); + if (s6 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c13(s2, s4, s5, s6); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, t, n, c, p) { return [t, n, c, p] })(pos0.offset, pos0.line, pos0.column, result0[1], result0[3], result0[4], result0[5]); - } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_end_tag() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 47) { - result1 = "/"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"/\""); - } - } - if (result1 !== null) { - result2 = []; - result3 = parse_ws(); - while (result3 !== null) { - result2.push(result3); - result3 = parse_ws(); - } - if (result2 !== null) { - result3 = parse_identifier(); - if (result3 !== null) { - result4 = []; - result5 = parse_ws(); - while (result5 !== null) { - result4.push(result5); - result5 = parse_ws(); - } - if (result4 !== null) { - result5 = parse_rd(); - if (result5 !== null) { - result0 = [result0, result1, result2, result3, result4, result5]; - } else { - result0 = null; - pos = clone(pos1); - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + + return s0; + } + + function peg$parseend_tag() { + var s0, s1, s2, s3, s4, s5, s6; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 47) { + s2 = peg$c8; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c9); } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parsews(); + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + if (s3 !== peg$FAILED) { + s4 = peg$parseidentifier(); + if (s4 !== peg$FAILED) { + s5 = []; + s6 = peg$parsews(); + while (s6 !== peg$FAILED) { + s5.push(s6); + s6 = peg$parsews(); + } + if (s5 !== peg$FAILED) { + s6 = peg$parserd(); + if (s6 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c15(s4); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n) { return n })(pos0.offset, pos0.line, pos0.column, result0[3]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("end tag"); - } - return result0; - } - - function parse_context() { - var result0, result1; - var pos0, pos1, pos2; - - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - if (input.charCodeAt(pos.offset) === 58) { - result0 = ":"; - advance(pos, 1); + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c14); } + } + + return s0; + } + + function peg$parsecontext() { + var s0, s1, s2, s3; + + s0 = peg$currPos; + s1 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 58) { + s2 = peg$c16; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c17); } + } + if (s2 !== peg$FAILED) { + s3 = peg$parseidentifier(); + if (s3 !== peg$FAILED) { + peg$reportedPos = s1; + s2 = peg$c18(s3); + s1 = s2; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\":\""); - } + peg$currPos = s1; + s1 = peg$c3; } - if (result0 !== null) { - result1 = parse_identifier(); - if (result1 !== null) { - result0 = [result0, result1]; + } else { + peg$currPos = s1; + s1 = peg$c3; + } + if (s1 === peg$FAILED) { + s1 = peg$c4; + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c19(s1); + } + s0 = s1; + + return s0; + } + + function peg$parseparams() { + var s0, s1, s2, s3, s4, s5, s6; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = []; + s4 = peg$parsews(); + if (s4 !== peg$FAILED) { + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + } else { + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 61) { + s5 = peg$c21; + peg$currPos++; } else { - result0 = null; - pos = clone(pos2); - } - } else { - result0 = null; - pos = clone(pos2); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n) {return n})(pos1.offset, pos1.line, pos1.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos1); - } - result0 = result0 !== null ? result0 : ""; - if (result0 !== null) { - result0 = (function(offset, line, column, n) { return n ? ["context", n] : ["context"] })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_params() { - var result0, result1, result2, result3, result4; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - result0 = []; - pos1 = clone(pos); - pos2 = clone(pos); - result2 = parse_ws(); - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - } else { - result1 = null; - } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - if (input.charCodeAt(pos.offset) === 61) { - result3 = "="; - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("\"=\""); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c22); } + } + if (s5 !== peg$FAILED) { + s6 = peg$parsenumber(); + if (s6 === peg$FAILED) { + s6 = peg$parseidentifier(); + if (s6 === peg$FAILED) { + s6 = peg$parseinline(); } } - if (result3 !== null) { - result4 = parse_number(); - if (result4 === null) { - result4 = parse_identifier(); - if (result4 === null) { - result4 = parse_inline(); - } - } - if (result4 !== null) { - result1 = [result1, result2, result3, result4]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s6 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s4, s6); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[1], result1[3]); - } - if (result1 === null) { - pos = clone(pos1); - } - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - result2 = parse_ws(); - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - } else { - result1 = null; - } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - if (input.charCodeAt(pos.offset) === 61) { - result3 = "="; - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("\"=\""); + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = []; + s4 = peg$parsews(); + if (s4 !== peg$FAILED) { + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + } else { + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 61) { + s5 = peg$c21; + peg$currPos++; + } else { + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c22); } + } + if (s5 !== peg$FAILED) { + s6 = peg$parsenumber(); + if (s6 === peg$FAILED) { + s6 = peg$parseidentifier(); + if (s6 === peg$FAILED) { + s6 = peg$parseinline(); } } - if (result3 !== null) { - result4 = parse_number(); - if (result4 === null) { - result4 = parse_identifier(); - if (result4 === null) { - result4 = parse_inline(); - } - } - if (result4 !== null) { - result1 = [result1, result2, result3, result4]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s6 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s4, s6); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[1], result1[3]); - } - if (result1 === null) { - pos = clone(pos1); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["params"].concat(p) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("params"); - } - return result0; - } - - function parse_bodies() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - result0 = []; - pos1 = clone(pos); - pos2 = clone(pos); - result1 = parse_ld(); - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 58) { - result2 = ":"; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\":\""); - } + peg$currPos = s2; + s2 = peg$c3; } - if (result2 !== null) { - result3 = parse_key(); - if (result3 !== null) { - result4 = parse_rd(); - if (result4 !== null) { - result5 = parse_body(); - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c24(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c20); } + } + + return s0; + } + + function peg$parsebodies() { + var s0, s1, s2, s3, s4, s5, s6, s7; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = peg$parseld(); + if (s3 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 58) { + s4 = peg$c16; + peg$currPos++; + } else { + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c17); } + } + if (s4 !== peg$FAILED) { + s5 = peg$parsekey(); + if (s5 !== peg$FAILED) { + s6 = peg$parserd(); + if (s6 !== peg$FAILED) { + s7 = peg$parsebody(); + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s5, s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[2], result1[4]); - } - if (result1 === null) { - pos = clone(pos1); - } - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - result1 = parse_ld(); - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 58) { - result2 = ":"; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\":\""); - } - } - if (result2 !== null) { - result3 = parse_key(); - if (result3 !== null) { - result4 = parse_rd(); - if (result4 !== null) { - result5 = parse_body(); - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = peg$parseld(); + if (s3 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 58) { + s4 = peg$c16; + peg$currPos++; + } else { + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c17); } + } + if (s4 !== peg$FAILED) { + s5 = peg$parsekey(); + if (s5 !== peg$FAILED) { + s6 = peg$parserd(); + if (s6 !== peg$FAILED) { + s7 = peg$parsebody(); + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s5, s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[2], result1[4]); - } - if (result1 === null) { - pos = clone(pos1); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["bodies"].concat(p) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("bodies"); - } - return result0; - } - - function parse_reference() { - var result0, result1, result2, result3; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - result1 = parse_identifier(); - if (result1 !== null) { - result2 = parse_filters(); - if (result2 !== null) { - result3 = parse_rd(); - if (result3 !== null) { - result0 = [result0, result1, result2, result3]; - } else { - result0 = null; - pos = clone(pos1); - } + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c26(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c25); } + } + + return s0; + } + + function peg$parsereference() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + s2 = peg$parseidentifier(); + if (s2 !== peg$FAILED) { + s3 = peg$parsefilters(); + if (s3 !== peg$FAILED) { + s4 = peg$parserd(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c28(s2, s3); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n, f) { return ["reference", n, f].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1], result0[2]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("reference"); - } - return result0; - } - - function parse_partial() { - var result0, result1, result2, result3, result4, result5, result6, result7, result8; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 62) { - result1 = ">"; - advance(pos, 1); + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c27); } + } + + return s0; + } + + function peg$parsepartial() { + var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 62) { + s2 = peg$c30; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c31); } + } + if (s2 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 43) { + s2 = peg$c32; + peg$currPos++; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\">\""); - } - } - if (result1 === null) { - if (input.charCodeAt(pos.offset) === 43) { - result1 = "+"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"+\""); - } - } - } - if (result1 !== null) { - result2 = []; - result3 = parse_ws(); - while (result3 !== null) { - result2.push(result3); - result3 = parse_ws(); - } - if (result2 !== null) { - pos2 = clone(pos); - result3 = parse_key(); - if (result3 !== null) { - result3 = (function(offset, line, column, k) {return ["literal", k]})(pos2.offset, pos2.line, pos2.column, result3); - } - if (result3 === null) { - pos = clone(pos2); - } - if (result3 === null) { - result3 = parse_inline(); - } - if (result3 !== null) { - result4 = parse_context(); - if (result4 !== null) { - result5 = parse_params(); - if (result5 !== null) { - result6 = []; - result7 = parse_ws(); - while (result7 !== null) { - result6.push(result7); - result7 = parse_ws(); + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c33); } + } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parsews(); + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + if (s3 !== peg$FAILED) { + s4 = peg$currPos; + s5 = peg$parsekey(); + if (s5 !== peg$FAILED) { + peg$reportedPos = s4; + s5 = peg$c34(s5); + } + s4 = s5; + if (s4 === peg$FAILED) { + s4 = peg$parseinline(); + } + if (s4 !== peg$FAILED) { + s5 = peg$parsecontext(); + if (s5 !== peg$FAILED) { + s6 = peg$parseparams(); + if (s6 !== peg$FAILED) { + s7 = []; + s8 = peg$parsews(); + while (s8 !== peg$FAILED) { + s7.push(s8); + s8 = peg$parsews(); + } + if (s7 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 47) { + s8 = peg$c8; + peg$currPos++; + } else { + s8 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c9); } } - if (result6 !== null) { - if (input.charCodeAt(pos.offset) === 47) { - result7 = "/"; - advance(pos, 1); - } else { - result7 = null; - if (reportFailures === 0) { - matchFailed("\"/\""); - } - } - if (result7 !== null) { - result8 = parse_rd(); - if (result8 !== null) { - result0 = [result0, result1, result2, result3, result4, result5, result6, result7, result8]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s8 !== peg$FAILED) { + s9 = peg$parserd(); + if (s9 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c35(s2, s4, s5, s6); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, s, n, c, p) { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1], result0[3], result0[4], result0[5]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("partial"); - } - return result0; - } - - function parse_filters() { - var result0, result1, result2; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - result0 = []; - pos1 = clone(pos); - pos2 = clone(pos); - if (input.charCodeAt(pos.offset) === 124) { - result1 = "|"; - advance(pos, 1); + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c29); } + } + + return s0; + } + + function peg$parsefilters() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 124) { + s3 = peg$c37; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c38); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c18(s4); + s2 = s3; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"|\""); - } + peg$currPos = s2; + s2 = peg$c3; } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos2); - } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 124) { + s3 = peg$c37; + peg$currPos++; } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, n) {return n})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); - } - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - if (input.charCodeAt(pos.offset) === 124) { - result1 = "|"; - advance(pos, 1); + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c38); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c18(s4); + s2 = s3; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"|\""); - } + peg$currPos = s2; + s2 = peg$c3; } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos2); - } - } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, n) {return n})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column, f) { return ["filters"].concat(f) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("filters"); + } else { + peg$currPos = s2; + s2 = peg$c3; } - return result0; } - - function parse_special() { - var result0, result1, result2, result3; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 126) { - result1 = "~"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"~\""); - } - } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result3 = parse_rd(); - if (result3 !== null) { - result0 = [result0, result1, result2, result3]; - } else { - result0 = null; - pos = clone(pos1); - } - } else { - result0 = null; - pos = clone(pos1); - } - } else { - result0 = null; - pos = clone(pos1); - } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c39(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c36); } + } + + return s0; + } + + function peg$parsespecial() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 126) { + s2 = peg$c41; + peg$currPos++; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, k) { return ["special", k].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[2]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("special"); - } - return result0; - } - - function parse_identifier() { - var result0; - var pos0; - - reportFailures++; - pos0 = clone(pos); - result0 = parse_path(); - if (result0 !== null) { - result0 = (function(offset, line, column, p) { var arr = ["path"].concat(p); arr.text = p[1].join('.'); return arr; })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - result0 = parse_key(); - if (result0 !== null) { - result0 = (function(offset, line, column, k) { var arr = ["key", k]; arr.text = k; return arr; })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("identifier"); - } - return result0; - } - - function parse_number() { - var result0; - var pos0; - - reportFailures++; - pos0 = clone(pos); - result0 = parse_float(); - if (result0 === null) { - result0 = parse_integer(); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n) { return ['literal', n]; })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("number"); - } - return result0; - } - - function parse_float() { - var result0, result1, result2, result3; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_integer(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 46) { - result1 = "."; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } - } - if (result1 !== null) { - result3 = parse_integer(); - if (result3 !== null) { - result2 = []; - while (result3 !== null) { - result2.push(result3); - result3 = parse_integer(); - } - } else { - result2 = null; - } - if (result2 !== null) { - result0 = [result0, result1, result2]; + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c42); } + } + if (s2 !== peg$FAILED) { + s3 = peg$parsekey(); + if (s3 !== peg$FAILED) { + s4 = peg$parserd(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c43(s3); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, l, r) { return parseFloat(l + "." + r.join('')); })(pos0.offset, pos0.line, pos0.column, result0[0], result0[2]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("float"); - } - return result0; - } - - function parse_integer() { - var result0, result1; - var pos0; - - reportFailures++; - pos0 = clone(pos); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result1 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result1 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c40); } + } + + return s0; + } + + function peg$parseidentifier() { + var s0, s1; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsepath(); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c45(s1); + } + s0 = s1; + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = peg$parsekey(); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c46(s1); + } + s0 = s1; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c44); } + } + + return s0; + } + + function peg$parsenumber() { + var s0, s1; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsefloat(); + if (s1 === peg$FAILED) { + s1 = peg$parseinteger(); + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c48(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c47); } + } + + return s0; + } + + function peg$parsefloat() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseinteger(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 46) { + s2 = peg$c50; + peg$currPos++; } else { - result0 = null; - } - if (result0 !== null) { - result0 = (function(offset, line, column, digits) { return parseInt(digits.join(""), 10); })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("integer"); - } - return result0; - } - - function parse_path() { - var result0, result1, result2; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_key(); - result0 = result0 !== null ? result0 : ""; - if (result0 !== null) { - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parseinteger(); + if (s4 !== peg$FAILED) { + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parseinteger(); } } else { - result1 = null; + s3 = peg$c3; } - if (result1 !== null) { - result0 = [result0, result1]; + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c52(s1, s3); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, k, d) { - d = d[0]; - if (k && d) { - d.unshift(k); - return [false, d].concat([['line', line], ['col', column]]); - } - return [true, d].concat([['line', line], ['col', column]]); - })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 46) { - result0 = "."; - advance(pos, 1); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c49); } + } + + return s0; + } + + function peg$parseinteger() { + var s0, s1, s2; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + if (peg$c54.test(input.charAt(peg$currPos))) { + s2 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + if (peg$c54.test(input.charAt(peg$currPos))) { + s2 = input.charAt(peg$currPos); + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } } - if (result0 !== null) { - result1 = []; - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - while (result2 !== null) { - result1.push(result2); - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - } - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); + } + } else { + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c56(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c53); } + } + + return s0; + } + + function peg$parsepath() { + var s0, s1, s2, s3; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsekey(); + if (s1 === peg$FAILED) { + s1 = peg$c4; + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); + } + if (s3 !== peg$FAILED) { + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); } - } else { - result0 = null; - pos = clone(pos1); } - if (result0 !== null) { - result0 = (function(offset, line, column, d) { - if (d.length > 0) { - return [true, d[0]].concat([['line', line], ['col', column]]); - } - return [true, []].concat([['line', line], ['col', column]]); - })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("path"); - } - return result0; - } - - function parse_key() { - var result0, result1, result2; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (/^[a-zA-Z_$]/.test(input.charAt(pos.offset))) { - result0 = input.charAt(pos.offset); - advance(pos, 1); } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("[a-zA-Z_$]"); - } + s2 = peg$c3; } - if (result0 !== null) { - result1 = []; - if (/^[0-9a-zA-Z_$\-]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9a-zA-Z_$\\-]"); - } - } - while (result2 !== null) { - result1.push(result2); - if (/^[0-9a-zA-Z_$\-]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9a-zA-Z_$\\-]"); - } - } - } - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c58(s1, s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, h, t) { return h + t.join('') })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("key"); - } - return result0; - } - - function parse_array() { - var result0, result1, result2; - var pos0, pos1, pos2, pos3, pos4; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - result0 = parse_lb(); - if (result0 !== null) { - pos4 = clone(pos); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - } - } else { - result1 = null; - } - if (result1 !== null) { - result1 = (function(offset, line, column, n) {return n.join('')})(pos4.offset, pos4.line, pos4.column, result1); - } - if (result1 === null) { - pos = clone(pos4); - } - if (result1 === null) { - result1 = parse_identifier(); - } - if (result1 !== null) { - result2 = parse_rb(); - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos3); - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 46) { + s1 = peg$c50; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); + } + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); + } + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c59(s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos3); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos3); - } - if (result0 !== null) { - result0 = (function(offset, line, column, a) {return a; })(pos2.offset, pos2.line, pos2.column, result0[1]); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - pos = clone(pos2); - } - if (result0 !== null) { - result1 = parse_array_part(); - result1 = result1 !== null ? result1 : ""; - if (result1 !== null) { - result0 = [result0, result1]; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c57); } + } + + return s0; + } + + function peg$parsekey() { + var s0, s1, s2, s3; + + peg$silentFails++; + s0 = peg$currPos; + if (peg$c61.test(input.charAt(peg$currPos))) { + s1 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c62); } + } + if (s1 !== peg$FAILED) { + s2 = []; + if (peg$c63.test(input.charAt(peg$currPos))) { + s3 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c64); } + } + while (s3 !== peg$FAILED) { + s2.push(s3); + if (peg$c63.test(input.charAt(peg$currPos))) { + s3 = input.charAt(peg$currPos); + peg$currPos++; } else { - result0 = null; - pos = clone(pos1); + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c64); } } + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c65(s1, s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, i, nk) { if(nk) { nk.unshift(i); } else {nk = [i] } return nk; })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("array"); - } - return result0; - } - - function parse_array_part() { - var result0, result1, result2; - var pos0, pos1, pos2, pos3; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - if (input.charCodeAt(pos.offset) === 46) { - result1 = "."; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } + peg$currPos = s0; + s0 = peg$c3; } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos3); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c60); } + } + + return s0; + } + + function peg$parsearray() { + var s0, s1, s2, s3, s4, s5; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$currPos; + s2 = peg$parselb(); + if (s2 !== peg$FAILED) { + s3 = peg$currPos; + s4 = []; + if (peg$c54.test(input.charAt(peg$currPos))) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k) {return k})(pos2.offset, pos2.line, pos2.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos2); - } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - pos2 = clone(pos); - pos3 = clone(pos); - if (input.charCodeAt(pos.offset) === 46) { - result1 = "."; - advance(pos, 1); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } + } + if (s5 !== peg$FAILED) { + while (s5 !== peg$FAILED) { + s4.push(s5); + if (peg$c54.test(input.charAt(peg$currPos))) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } - } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos3); - } - } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k) {return k})(pos2.offset, pos2.line, pos2.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos2); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } } } } else { - result0 = null; - } - if (result0 !== null) { - result1 = parse_array(); - result1 = result1 !== null ? result1 : ""; - if (result1 !== null) { - result0 = [result0, result1]; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c67(s4); + } + s3 = s4; + if (s3 === peg$FAILED) { + s3 = peg$parseidentifier(); + } + if (s3 !== peg$FAILED) { + s4 = peg$parserb(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s1; + s2 = peg$c68(s3); + s1 = s2; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s1; + s1 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, d, a) { if (a) { return d.concat(a); } else { return d; } })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("array_part"); - } - return result0; - } - - function parse_inline() { - var result0, result1, result2; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 34) { - result0 = "\""; - advance(pos, 1); + peg$currPos = s1; + s1 = peg$c3; + } + } else { + peg$currPos = s1; + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + s2 = peg$parsearray_part(); + if (s2 === peg$FAILED) { + s2 = peg$c4; + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c69(s1, s2); + s0 = s1; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c66); } + } + + return s0; + } + + function peg$parsearray_part() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 46) { + s3 = peg$c50; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c71(s4); + s2 = s3; + } else { + peg$currPos = s2; + s2 = peg$c3; } - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 34) { - result1 = "\""; - advance(pos, 1); + } else { + peg$currPos = s2; + s2 = peg$c3; + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 46) { + s3 = peg$c50; + peg$currPos++; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c71(s4); + s2 = s3; + } else { + peg$currPos = s2; + s2 = peg$c3; } - } - if (result1 !== null) { - result0 = [result0, result1]; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s2; + s2 = peg$c3; } + } + } else { + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + s2 = peg$parsearray(); + if (s2 === peg$FAILED) { + s2 = peg$c4; + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c72(s1, s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column) { return ["literal", ""].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c70); } + } + + return s0; + } + + function peg$parseinline() { + var s0, s1, s2, s3; + + peg$silentFails++; + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 34) { + s1 = peg$c74; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } + } + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 34) { + s2 = peg$c74; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } } - if (result0 === null) { - pos = clone(pos0); + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c76(); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 34) { - result0 = "\""; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 34) { + s1 = peg$c74; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } + } + if (s1 !== peg$FAILED) { + s2 = peg$parseliteral(); + if (s2 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 34) { + s3 = peg$c74; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } } - } - if (result0 !== null) { - result1 = parse_literal(); - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 34) { - result2 = "\""; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } - } - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c77(s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, l) { return ["literal", l].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 34) { - result0 = "\""; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 34) { + s1 = peg$c74; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parseinline_part(); + if (s3 !== peg$FAILED) { + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parseinline_part(); } + } else { + s2 = peg$c3; } - if (result0 !== null) { - result2 = parse_inline_part(); - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_inline_part(); - } + if (s2 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 34) { + s3 = peg$c74; + peg$currPos++; } else { - result1 = null; + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } } - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 34) { - result2 = "\""; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } - } - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c1(s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["body"].concat(p).concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } + } else { + peg$currPos = s0; + s0 = peg$c3; } } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("inline"); - } - return result0; - } - - function parse_inline_part() { - var result0; - var pos0; - - result0 = parse_special(); - if (result0 === null) { - result0 = parse_reference(); - if (result0 === null) { - pos0 = clone(pos); - result0 = parse_literal(); - if (result0 !== null) { - result0 = (function(offset, line, column, l) { return ["buffer", l] })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - } + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c73); } + } + + return s0; + } + + function peg$parseinline_part() { + var s0, s1; + + s0 = peg$parsespecial(); + if (s0 === peg$FAILED) { + s0 = peg$parsereference(); + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = peg$parseliteral(); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c78(s1); + } + s0 = s1; + } + } + + return s0; + } + + function peg$parsebuffer() { + var s0, s1, s2, s3, s4, s5, s6, s7; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseeol(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c80(s1, s2); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } - return result0; - } - - function parse_buffer() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1, pos2, pos3; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_eol(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, e, w) { return ["format", e, w.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$currPos; + peg$silentFails++; + s5 = peg$parseraw(); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - pos3 = clone(pos); - reportFailures++; - result2 = parse_raw(); - reportFailures--; - if (result2 === null) { - result2 = ""; + peg$currPos = s4; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + s5 = peg$currPos; + peg$silentFails++; + s6 = peg$parsecomment(); + peg$silentFails--; + if (s6 === peg$FAILED) { + s5 = peg$c6; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - pos3 = clone(pos); - reportFailures++; - result3 = parse_comment(); - reportFailures--; - if (result3 === null) { - result3 = ""; + peg$currPos = s5; + s5 = peg$c3; + } + if (s5 !== peg$FAILED) { + s6 = peg$currPos; + peg$silentFails++; + s7 = peg$parseeol(); + peg$silentFails--; + if (s7 === peg$FAILED) { + s6 = peg$c6; } else { - result3 = null; - pos = clone(pos3); + peg$currPos = s6; + s6 = peg$c3; } - if (result3 !== null) { - pos3 = clone(pos); - reportFailures++; - result4 = parse_eol(); - reportFailures--; - if (result4 === null) { - result4 = ""; + if (s6 !== peg$FAILED) { + if (input.length > peg$currPos) { + s7 = input.charAt(peg$currPos); + peg$currPos++; } else { - result4 = null; - pos = clone(pos3); + s7 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result4 !== null) { - if (input.length > pos.offset) { - result5 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result5 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c82(s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[4]); - } - if (result1 === null) { - pos = clone(pos1); - } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$currPos; + peg$silentFails++; + s5 = peg$parseraw(); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result1 = null; - pos = clone(pos3); + peg$currPos = s4; + s4 = peg$c3; } - if (result1 !== null) { - pos3 = clone(pos); - reportFailures++; - result2 = parse_raw(); - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s4 !== peg$FAILED) { + s5 = peg$currPos; + peg$silentFails++; + s6 = peg$parsecomment(); + peg$silentFails--; + if (s6 === peg$FAILED) { + s5 = peg$c6; } else { - result2 = null; - pos = clone(pos3); + peg$currPos = s5; + s5 = peg$c3; } - if (result2 !== null) { - pos3 = clone(pos); - reportFailures++; - result3 = parse_comment(); - reportFailures--; - if (result3 === null) { - result3 = ""; + if (s5 !== peg$FAILED) { + s6 = peg$currPos; + peg$silentFails++; + s7 = peg$parseeol(); + peg$silentFails--; + if (s7 === peg$FAILED) { + s6 = peg$c6; } else { - result3 = null; - pos = clone(pos3); + peg$currPos = s6; + s6 = peg$c3; } - if (result3 !== null) { - pos3 = clone(pos); - reportFailures++; - result4 = parse_eol(); - reportFailures--; - if (result4 === null) { - result4 = ""; + if (s6 !== peg$FAILED) { + if (input.length > peg$currPos) { + s7 = input.charAt(peg$currPos); + peg$currPos++; } else { - result4 = null; - pos = clone(pos3); + s7 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result4 !== null) { - if (input.length > pos.offset) { - result5 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result5 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c82(s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[4]); + peg$currPos = s2; + s2 = peg$c3; } - if (result1 === null) { - pos = clone(pos1); - } - } - } else { - result0 = null; - } - if (result0 !== null) { - result0 = (function(offset, line, column, b) { return ["buffer", b.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("buffer"); - } - return result0; - } - - function parse_literal() { - var result0, result1, result2; - var pos0, pos1, pos2, pos3; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; - } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result2 = parse_esc(); - if (result2 === null) { - if (/^[^"]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[^\"]"); - } + peg$currPos = s2; + s2 = peg$c3; } } - if (result2 !== null) { - result1 = [result1, result2]; + } else { + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c83(s1); + } + s0 = s1; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c79); } + } + + return s0; + } + + function peg$parseliteral() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parseesc(); + if (s4 === peg$FAILED) { + if (peg$c85.test(input.charAt(peg$currPos))) { + s4 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - pos = clone(pos2); + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c86); } } + } + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c82(s4); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); - } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; - } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result2 = parse_esc(); - if (result2 === null) { - if (/^[^"]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[^\"]"); - } - } - } - if (result2 !== null) { - result1 = [result1, result2]; + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parseesc(); + if (s4 === peg$FAILED) { + if (peg$c85.test(input.charAt(peg$currPos))) { + s4 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - pos = clone(pos2); + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c86); } } - } else { - result1 = null; - pos = clone(pos2); } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c82(s4); + s2 = s3; + } else { + peg$currPos = s2; + s2 = peg$c3; } + } else { + peg$currPos = s2; + s2 = peg$c3; } - } else { - result0 = null; } - if (result0 !== null) { - result0 = (function(offset, line, column, b) { return b.join('') })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("literal"); - } - return result0; + } else { + s1 = peg$c3; } - - function parse_esc() { - var result0; - var pos0; - - pos0 = clone(pos); - if (input.substr(pos.offset, 2) === "\\\"") { - result0 = "\\\""; - advance(pos, 2); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c87(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c84); } + } + + return s0; + } + + function peg$parseesc() { + var s0, s1; + + s0 = peg$currPos; + if (input.substr(peg$currPos, 2) === peg$c88) { + s1 = peg$c88; + peg$currPos += 2; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c89); } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c90(); + } + s0 = s1; + + return s0; + } + + function peg$parseraw() { + var s0, s1, s2, s3, s4, s5; + + peg$silentFails++; + s0 = peg$currPos; + if (input.substr(peg$currPos, 2) === peg$c92) { + s1 = peg$c92; + peg$currPos += 2; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c93); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c94) { + s5 = peg$c94; + peg$currPos += 2; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\\\\\"\""); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column) { return '"' })(pos0.offset, pos0.line, pos0.column); - } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_raw() { - var result0, result1, result2, result3; - var pos0, pos1, pos2, pos3, pos4; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (input.substr(pos.offset, 2) === "{`") { - result0 = "{`"; - advance(pos, 2); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c95); } + } + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"{`\""); - } - } - if (result0 !== null) { - result1 = []; - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "`}") { - result2 = "`}"; - advance(pos, 2); + peg$currPos = s4; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"`}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c96(s5); + s3 = s4; } else { - result2 = null; - pos = clone(pos4); + peg$currPos = s3; + s3 = peg$c3; } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } + } else { + peg$currPos = s3; + s3 = peg$c3; + } + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c94) { + s5 = peg$c94; + peg$currPos += 2; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, char) {return char})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); - } - while (result2 !== null) { - result1.push(result2); - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "`}") { - result2 = "`}"; - advance(pos, 2); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"`}\""); - } - } - reportFailures--; - if (result2 === null) { - result2 = ""; - } else { - result2 = null; - pos = clone(pos4); - } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } - } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, char) {return char})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c95); } + } + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; + } else { + peg$currPos = s4; + s4 = peg$c3; } - if (result1 !== null) { - if (input.substr(pos.offset, 2) === "`}") { - result2 = "`}"; - advance(pos, 2); + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"`}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result2 !== null) { - result0 = [result0, result1, result2]; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c96(s5); + s3 = s4; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s3; + s3 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s3; + s3 = peg$c3; + } + } + if (s2 !== peg$FAILED) { + if (input.substr(peg$currPos, 2) === peg$c94) { + s3 = peg$c94; + peg$currPos += 2; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c95); } } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c97(s2); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c91); } + } + + return s0; + } + + function peg$parsecomment() { + var s0, s1, s2, s3, s4, s5; + + peg$silentFails++; + s0 = peg$currPos; + if (input.substr(peg$currPos, 2) === peg$c99) { + s1 = peg$c99; + peg$currPos += 2; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c100); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c101) { + s5 = peg$c101; + peg$currPos += 2; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, rawText) { return ["raw", rawText.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("raw"); - } - return result0; - } - - function parse_comment() { - var result0, result1, result2, result3; - var pos0, pos1, pos2, pos3, pos4; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (input.substr(pos.offset, 2) === "{!") { - result0 = "{!"; - advance(pos, 2); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c102); } + } + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"{!\""); - } - } - if (result0 !== null) { - result1 = []; - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "!}") { - result2 = "!}"; - advance(pos, 2); + peg$currPos = s4; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"!}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c82(s5); + s3 = s4; } else { - result2 = null; - pos = clone(pos4); + peg$currPos = s3; + s3 = peg$c3; } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } + } else { + peg$currPos = s3; + s3 = peg$c3; + } + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c101) { + s5 = peg$c101; + peg$currPos += 2; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, c) {return c})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); - } - while (result2 !== null) { - result1.push(result2); - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "!}") { - result2 = "!}"; - advance(pos, 2); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"!}\""); - } - } - reportFailures--; - if (result2 === null) { - result2 = ""; - } else { - result2 = null; - pos = clone(pos4); - } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } - } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, c) {return c})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c102); } } - if (result1 !== null) { - if (input.substr(pos.offset, 2) === "!}") { - result2 = "!}"; - advance(pos, 2); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; + } else { + peg$currPos = s4; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"!}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result2 !== null) { - result0 = [result0, result1, result2]; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c82(s5); + s3 = s4; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s3; + s3 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s3; + s3 = peg$c3; + } + } + if (s2 !== peg$FAILED) { + if (input.substr(peg$currPos, 2) === peg$c101) { + s3 = peg$c101; + peg$currPos += 2; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c102); } + } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c103(s2); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, c) { return ["comment", c.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("comment"); - } - return result0; - } - - function parse_tag() { - var result0, result1, result2, result3, result4, result5, result6, result7; - var pos0, pos1, pos2; - - pos0 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - if (/^[#?^><+%:@\/~%]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[#?^><+%:@\\/~%]"); - } - } - if (result2 !== null) { - result3 = []; - result4 = parse_ws(); - while (result4 !== null) { - result3.push(result4); - result4 = parse_ws(); + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c98); } + } + + return s0; + } + + function peg$parsetag() { + var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9; + + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + if (peg$c104.test(input.charAt(peg$currPos))) { + s3 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c105); } + } + if (s3 !== peg$FAILED) { + s4 = []; + s5 = peg$parsews(); + while (s5 !== peg$FAILED) { + s4.push(s5); + s5 = peg$parsews(); + } + if (s4 !== peg$FAILED) { + s5 = []; + s6 = peg$currPos; + s7 = peg$currPos; + peg$silentFails++; + s8 = peg$parserd(); + peg$silentFails--; + if (s8 === peg$FAILED) { + s7 = peg$c6; + } else { + peg$currPos = s7; + s7 = peg$c3; } - if (result3 !== null) { - pos1 = clone(pos); - pos2 = clone(pos); - reportFailures++; - result5 = parse_rd(); - reportFailures--; - if (result5 === null) { - result5 = ""; + if (s7 !== peg$FAILED) { + s8 = peg$currPos; + peg$silentFails++; + s9 = peg$parseeol(); + peg$silentFails--; + if (s9 === peg$FAILED) { + s8 = peg$c6; } else { - result5 = null; - pos = clone(pos2); + peg$currPos = s8; + s8 = peg$c3; } - if (result5 !== null) { - pos2 = clone(pos); - reportFailures++; - result6 = parse_eol(); - reportFailures--; - if (result6 === null) { - result6 = ""; + if (s8 !== peg$FAILED) { + if (input.length > peg$currPos) { + s9 = input.charAt(peg$currPos); + peg$currPos++; } else { - result6 = null; - pos = clone(pos2); + s9 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result6 !== null) { - if (input.length > pos.offset) { - result7 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result7 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result7 !== null) { - result5 = [result5, result6, result7]; - } else { - result5 = null; - pos = clone(pos1); - } + if (s9 !== peg$FAILED) { + s7 = [s7, s8, s9]; + s6 = s7; } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } - if (result5 !== null) { - result4 = []; - while (result5 !== null) { - result4.push(result5); - pos1 = clone(pos); - pos2 = clone(pos); - reportFailures++; - result5 = parse_rd(); - reportFailures--; - if (result5 === null) { - result5 = ""; + } else { + peg$currPos = s6; + s6 = peg$c3; + } + if (s6 !== peg$FAILED) { + while (s6 !== peg$FAILED) { + s5.push(s6); + s6 = peg$currPos; + s7 = peg$currPos; + peg$silentFails++; + s8 = peg$parserd(); + peg$silentFails--; + if (s8 === peg$FAILED) { + s7 = peg$c6; + } else { + peg$currPos = s7; + s7 = peg$c3; + } + if (s7 !== peg$FAILED) { + s8 = peg$currPos; + peg$silentFails++; + s9 = peg$parseeol(); + peg$silentFails--; + if (s9 === peg$FAILED) { + s8 = peg$c6; } else { - result5 = null; - pos = clone(pos2); + peg$currPos = s8; + s8 = peg$c3; } - if (result5 !== null) { - pos2 = clone(pos); - reportFailures++; - result6 = parse_eol(); - reportFailures--; - if (result6 === null) { - result6 = ""; + if (s8 !== peg$FAILED) { + if (input.length > peg$currPos) { + s9 = input.charAt(peg$currPos); + peg$currPos++; } else { - result6 = null; - pos = clone(pos2); + s9 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result6 !== null) { - if (input.length > pos.offset) { - result7 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result7 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result7 !== null) { - result5 = [result5, result6, result7]; - } else { - result5 = null; - pos = clone(pos1); - } + if (s9 !== peg$FAILED) { + s7 = [s7, s8, s9]; + s6 = s7; } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } + } else { + peg$currPos = s6; + s6 = peg$c3; } - } else { - result4 = null; } - if (result4 !== null) { - result5 = []; - result6 = parse_ws(); - while (result6 !== null) { - result5.push(result6); - result6 = parse_ws(); - } - if (result5 !== null) { - result6 = parse_rd(); - if (result6 !== null) { - result0 = [result0, result1, result2, result3, result4, result5, result6]; - } else { - result0 = null; - pos = clone(pos0); - } + } else { + s5 = peg$c3; + } + if (s5 !== peg$FAILED) { + s6 = []; + s7 = peg$parsews(); + while (s7 !== peg$FAILED) { + s6.push(s7); + s7 = peg$parsews(); + } + if (s6 !== peg$FAILED) { + s7 = peg$parserd(); + if (s7 !== peg$FAILED) { + s1 = [s1, s2, s3, s4, s5, s6, s7]; + s0 = s1; } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - result0 = parse_reference(); - } - return result0; + } else { + peg$currPos = s0; + s0 = peg$c3; } - - function parse_ld() { - var result0; - - if (input.charCodeAt(pos.offset) === 123) { - result0 = "{"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"{\""); - } - } - return result0; + if (s0 === peg$FAILED) { + s0 = peg$parsereference(); } - - function parse_rd() { - var result0; - - if (input.charCodeAt(pos.offset) === 125) { - result0 = "}"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"}\""); - } - } - return result0; + + return s0; + } + + function peg$parseld() { + var s0; + + if (input.charCodeAt(peg$currPos) === 123) { + s0 = peg$c106; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c107); } } - - function parse_lb() { - var result0; - - if (input.charCodeAt(pos.offset) === 91) { - result0 = "["; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"[\""); - } - } - return result0; + + return s0; + } + + function peg$parserd() { + var s0; + + if (input.charCodeAt(peg$currPos) === 125) { + s0 = peg$c108; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c109); } } - - function parse_rb() { - var result0; - - if (input.charCodeAt(pos.offset) === 93) { - result0 = "]"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"]\""); - } - } - return result0; + + return s0; + } + + function peg$parselb() { + var s0; + + if (input.charCodeAt(peg$currPos) === 91) { + s0 = peg$c110; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c111); } + } + + return s0; + } + + function peg$parserb() { + var s0; + + if (input.charCodeAt(peg$currPos) === 93) { + s0 = peg$c112; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c113); } + } + + return s0; + } + + function peg$parseeol() { + var s0; + + if (input.charCodeAt(peg$currPos) === 10) { + s0 = peg$c114; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c115); } } - - function parse_eol() { - var result0; - - if (input.charCodeAt(pos.offset) === 10) { - result0 = "\n"; - advance(pos, 1); + if (s0 === peg$FAILED) { + if (input.substr(peg$currPos, 2) === peg$c116) { + s0 = peg$c116; + peg$currPos += 2; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\n\""); - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c117); } } - if (result0 === null) { - if (input.substr(pos.offset, 2) === "\r\n") { - result0 = "\r\n"; - advance(pos, 2); + if (s0 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 13) { + s0 = peg$c118; + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\r\\n\""); - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c119); } } - if (result0 === null) { - if (input.charCodeAt(pos.offset) === 13) { - result0 = "\r"; - advance(pos, 1); + if (s0 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 8232) { + s0 = peg$c120; + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\r\""); - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c121); } } - if (result0 === null) { - if (input.charCodeAt(pos.offset) === 8232) { - result0 = "\u2028"; - advance(pos, 1); + if (s0 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 8233) { + s0 = peg$c122; + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\u2028\""); - } - } - if (result0 === null) { - if (input.charCodeAt(pos.offset) === 8233) { - result0 = "\u2029"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\u2029\""); - } - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c123); } } } } } - return result0; } - - function parse_ws() { - var result0; - - if (/^[\t\x0B\f \xA0\uFEFF]/.test(input.charAt(pos.offset))) { - result0 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("[\\t\\x0B\\f \\xA0\\uFEFF]"); - } - } - if (result0 === null) { - result0 = parse_eol(); - } - return result0; + + return s0; + } + + function peg$parsews() { + var s0; + + if (peg$c124.test(input.charAt(peg$currPos))) { + s0 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c125); } } - - - function cleanupExpected(expected) { - expected.sort(); - - var lastExpected = null; - var cleanExpected = []; - for (var i = 0; i < expected.length; i++) { - if (expected[i] !== lastExpected) { - cleanExpected.push(expected[i]); - lastExpected = expected[i]; - } - } - return cleanExpected; - } - - - - var result = parseFunctions[startRule](); - - /* - * The parser is now in one of the following three states: - * - * 1. The parser successfully parsed the whole input. - * - * - |result !== null| - * - |pos.offset === input.length| - * - |rightmostFailuresExpected| may or may not contain something - * - * 2. The parser successfully parsed only a part of the input. - * - * - |result !== null| - * - |pos.offset < input.length| - * - |rightmostFailuresExpected| may or may not contain something - * - * 3. The parser did not successfully parse any part of the input. - * - * - |result === null| - * - |pos.offset === 0| - * - |rightmostFailuresExpected| contains at least one failure - * - * All code following this comment (including called functions) must - * handle these states. - */ - if (result === null || pos.offset !== input.length) { - var offset = Math.max(pos.offset, rightmostFailuresPos.offset); - var found = offset < input.length ? input.charAt(offset) : null; - var errorPosition = pos.offset > rightmostFailuresPos.offset ? pos : rightmostFailuresPos; - - throw new parser.SyntaxError( - cleanupExpected(rightmostFailuresExpected), - found, - offset, - errorPosition.line, - errorPosition.column - ); - } - - return result; - }, - - /* Returns the parser source code. */ - toSource: function() { return this._source; } - }; - - /* Thrown when a parser encounters a syntax error. */ - - result.SyntaxError = function(expected, found, offset, line, column) { - function buildMessage(expected, found) { - var expectedHumanized, foundHumanized; - - switch (expected.length) { - case 0: - expectedHumanized = "end of input"; - break; - case 1: - expectedHumanized = expected[0]; - break; - default: - expectedHumanized = expected.slice(0, expected.length - 1).join(", ") - + " or " - + expected[expected.length - 1]; - } - - foundHumanized = found ? quote(found) : "end of input"; - - return "Expected " + expectedHumanized + " but " + foundHumanized + " found."; + if (s0 === peg$FAILED) { + s0 = peg$parseeol(); + } + + return s0; } - - this.name = "SyntaxError"; - this.expected = expected; - this.found = found; - this.message = buildMessage(expected, found); - this.offset = offset; - this.line = line; - this.column = column; + + peg$result = peg$startRuleFunction(); + + if (peg$result !== peg$FAILED && peg$currPos === input.length) { + return peg$result; + } else { + if (peg$result !== peg$FAILED && peg$currPos < input.length) { + peg$fail({ type: "end", description: "end of input" }); + } + + throw peg$buildException(null, peg$maxFailExpected, peg$maxFailPos); + } + } + + return { + SyntaxError: SyntaxError, + parse: parse }; - - result.SyntaxError.prototype = Error.prototype; - - return result; })(); // expose parser methods diff --git a/package.json b/package.json index d0a07993..0b434dd2 100644 --- a/package.json +++ b/package.json @@ -47,7 +47,7 @@ "views" ], "devDependencies": { - "pegjs": "0.7.0", + "pegjs": "0.8.0", "grunt": "~0.4.2", "grunt-contrib-connect": "~0.5.0", "grunt-template-jasmine-istanbul": "~0.2.5", diff --git a/src/build.js b/src/build.js index 97762a15..f8d8f73b 100644 --- a/src/build.js +++ b/src/build.js @@ -6,7 +6,8 @@ var peg = require('pegjs'), var options = { cache: false, - trackLineAndColumn: true + trackLineAndColumn: true, + output: 'source' }; var parser = peg.buildParser(fs.readFileSync(path.join(root, 'src', 'dust.pegjs'), 'utf8'), options), @@ -16,4 +17,4 @@ var parser = peg.buildParser(fs.readFileSync(path.join(root, 'src', 'dust.pegjs' buildMessage = 'Do not edit the parser directly. This is a generated file created using a build script and the PEG grammar.'; -fs.writeFileSync(path.join(root, 'lib', 'parser.js'), umdWrapper.replace(parserPlaceholder, parser.toSource()).replace(buildMessagePlaceHolder, buildMessage).replace('this.SyntaxError','parser.SyntaxError')); +fs.writeFileSync(path.join(root, 'lib', 'parser.js'), umdWrapper.replace(parserPlaceholder, parser).replace(buildMessagePlaceHolder, buildMessage).replace('this.SyntaxError','parser.SyntaxError')); diff --git a/src/dust.pegjs b/src/dust.pegjs index 65df1d4c..8119a40f 100644 --- a/src/dust.pegjs +++ b/src/dust.pegjs @@ -5,7 +5,7 @@ start body is defined as anything that matches with the part 0 or more times ---------------------------------------------------------------------------------------------------------------------------------------*/ body - = p:part* { return ["body"].concat(p).concat([['line', line], ['col', column]]) } + = p:part* { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- part is defined as anything that matches with raw or comment or section or partial or special or reference or buffer @@ -18,13 +18,13 @@ part plus bodies plus end_tag or sec_tag_start followed by a slash and closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ section "section" - = t:sec_tag_start ws* rd b:body e:bodies n:end_tag? &{if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line+", column : " + column)} return true;} - { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line], ['col', column]]) } + = t:sec_tag_start ws* rd b:body e:bodies n:end_tag? &{if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line()+", column : " + column())} return true;} + { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line()], ['col', column()]]) } / t:sec_tag_start ws* "/" rd - { t.push(["bodies"]); return t.concat([['line', line], ['col', column]]) } + { t.push(["bodies"]); return t.concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- - sec_tag_start is defined as matching an opening brace followed by one of #?^<+@% plus identifier plus context plus param + sec_tag_start is defined as matching an opening brace followed by one of #?^<+@% plus identifier plus context plus param followed by 0 or more white spaces ---------------------------------------------------------------------------------------------------------------------------------------*/ sec_tag_start @@ -32,7 +32,7 @@ sec_tag_start { return [t, n, c, p] } /*------------------------------------------------------------------------------------------------------------------------------------- - end_tag is defined as matching an opening brace followed by a slash plus 0 or more white spaces plus identifier followed + end_tag is defined as matching an opening brace followed by a slash plus 0 or more white spaces plus identifier followed by 0 or more white spaces and ends with closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ end_tag "end tag" @@ -65,15 +65,15 @@ bodies "bodies" ---------------------------------------------------------------------------------------------------------------------------------------*/ reference "reference" = ld n:identifier f:filters rd - { return ["reference", n, f].concat([['line', line], ['col', column]]) } + { return ["reference", n, f].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- - partial is defined as matching a opening brace followed by a > plus anything that matches with key or inline plus + partial is defined as matching a opening brace followed by a > plus anything that matches with key or inline plus context followed by slash and closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ partial "partial" = ld s:(">"/"+") ws* n:(k:key {return ["literal", k]} / inline) c:context p:params ws* "/" rd - { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line], ['col', column]]) } + { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- filters is defined as matching a pipe character followed by anything that matches the key @@ -87,7 +87,7 @@ filters "filters" ---------------------------------------------------------------------------------------------------------------------------------------*/ special "special" = ld "~" k:key rd - { return ["special", k].concat([['line', line], ['col', column]]) } + { return ["special", k].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- identifier is defined as matching a path or key @@ -106,26 +106,26 @@ integer "integer" = digits:[0-9]+ { return parseInt(digits.join(""), 10); } /*------------------------------------------------------------------------------------------------------------------------------------- - path is defined as matching a key plus one or more characters of key preceded by a dot + path is defined as matching a key plus one or more characters of key preceded by a dot ---------------------------------------------------------------------------------------------------------------------------------------*/ path "path" = k:key? d:(array_part / array)+ { d = d[0]; if (k && d) { d.unshift(k); - return [false, d].concat([['line', line], ['col', column]]); + return [false, d].concat([['line', line()], ['col', column()]]); } - return [true, d].concat([['line', line], ['col', column]]); + return [true, d].concat([['line', line()], ['col', column()]]); } / "." d:(array_part / array)* { if (d.length > 0) { - return [true, d[0]].concat([['line', line], ['col', column]]); + return [true, d[0]].concat([['line', line()], ['col', column()]]); } - return [true, []].concat([['line', line], ['col', column]]); + return [true, []].concat([['line', line()], ['col', column()]]); } /*------------------------------------------------------------------------------------------------------------------------------------- - key is defined as a character matching a to z, upper or lower case, followed by 0 or more alphanumeric characters + key is defined as a character matching a to z, upper or lower case, followed by 0 or more alphanumeric characters ---------------------------------------------------------------------------------------------------------------------------------------*/ key "key" = h:[a-zA-Z_$] t:[0-9a-zA-Z_$-]* @@ -138,25 +138,25 @@ array_part "array_part" = d:("." k:key {return k})+ a:(array)? { if (a) { return d.concat(a); } else { return d; } } /*------------------------------------------------------------------------------------------------------------------------------------- - inline params is defined as matching two double quotes or double quotes plus literal followed by closing double quotes or + inline params is defined as matching two double quotes or double quotes plus literal followed by closing double quotes or double quotes plus inline_part followed by the closing double quotes ---------------------------------------------------------------------------------------------------------------------------------------*/ inline "inline" - = '"' '"' { return ["literal", ""].concat([['line', line], ['col', column]]) } - / '"' l:literal '"' { return ["literal", l].concat([['line', line], ['col', column]]) } - / '"' p:inline_part+ '"' { return ["body"].concat(p).concat([['line', line], ['col', column]]) } + = '"' '"' { return ["literal", ""].concat([['line', line()], ['col', column()]]) } + / '"' l:literal '"' { return ["literal", l].concat([['line', line()], ['col', column()]]) } + / '"' p:inline_part+ '"' { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- - inline_part is defined as matching a special or reference or literal + inline_part is defined as matching a special or reference or literal ---------------------------------------------------------------------------------------------------------------------------------------*/ inline_part = special / reference / l:literal { return ["buffer", l] } buffer "buffer" = e:eol w:ws* - { return ["format", e, w.join('')].concat([['line', line], ['col', column]]) } + { return ["format", e, w.join('')].concat([['line', line()], ['col', column()]]) } / b:(!tag !raw !comment !eol c:. {return c})+ - { return ["buffer", b.join('')].concat([['line', line], ['col', column]]) } + { return ["buffer", b.join('')].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- literal is defined as matching esc or any character except the double quotes and it cannot be a tag @@ -170,13 +170,13 @@ esc raw "raw" = "{`" rawText:(!"`}" char:. {return char})* "`}" - { return ["raw", rawText.join('')].concat([['line', line], ['col', column]]) } + { return ["raw", rawText.join('')].concat([['line', line()], ['col', column()]]) } comment "comment" = "{!" c:(!"!}" c:. {return c})* "!}" - { return ["comment", c.join('')].concat([['line', line], ['col', column]]) } + { return ["comment", c.join('')].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- - tag is defined as matching an opening brace plus any of #?^><+%:@/~% plus 0 or more whitespaces plus any character or characters that + tag is defined as matching an opening brace plus any of #?^><+%:@/~% plus 0 or more whitespaces plus any character or characters that doesn't match rd or eol plus 0 or more whitespaces plus a closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ tag @@ -195,7 +195,7 @@ lb rb = "]" -eol +eol = "\n" //line feed / "\r\n" //carriage + line feed / "\r" //carriage return diff --git a/test/jasmine-test/spec/coreTests.js b/test/jasmine-test/spec/coreTests.js index ec4b2479..5cbe2b23 100755 --- a/test/jasmine-test/spec/coreTests.js +++ b/test/jasmine-test/spec/coreTests.js @@ -968,7 +968,7 @@ var coreTests = [ /** * PARTIAL DEFINITIONS TESTS */ - { + { name: "partial definitions", tests: [ { @@ -1399,7 +1399,7 @@ var coreTests = [ name: "error: whitespaces between the opening brace and any of (#,?,@,^,+,%) is not allowed", source: '{ # helper foo="bar" boo="boo" } {/helper}', context: { "helper": function(chunk, context, bodies, params) { return chunk.write(params.boo + " " + params.foo); } }, - error: 'Expected buffer, comment, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', + error: 'Expected buffer, comment, end of input, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', message: "should show an error for whitespces between the opening brace and any of (#,?,@,^,+,%)" }, { @@ -1427,7 +1427,7 @@ var coreTests = [ name: "error: whitespaces between the forward slash and the closing brace in self closing tags", source: '{#helper foo="bar" boo="boo" / }', context: { "helper": function(chunk, context, bodies, params) { return chunk.write(params.boo + " " + params.foo); } }, - error: 'Expected buffer, comment, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', + error: 'Expected buffer, comment, end of input, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', message: "should show an error for whitespaces etween the forward slash and the closing brace in self closing tags" }, { @@ -1441,7 +1441,7 @@ var coreTests = [ name: "error : whitespaces between the '{' plus '>' and partial identifier is not supported", source: '{ > partial/} {> "hello_world"/} {> "{ref}"/}', context: { "name": "Jim", "count": 42, "ref": "hello_world" }, - error: 'Expected buffer, comment, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', + error: 'Expected buffer, comment, end of input, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', message: "should show an error for whitespaces between the '{' plus '>' and partial identifier" }, { @@ -1541,7 +1541,7 @@ var coreTests = [ name: "Dust syntax error", source: "RRR {##}", context: { name: "Mick", count: 30 }, - error: 'Expected buffer, comment, partial, raw, reference, section or special but "{" found. At line : 1, column : 5', + error: 'Expected buffer, comment, end of input, partial, raw, reference, section or special but "{" found. At line : 1, column : 5', message: "should test that the error message shows line and column." }, { From 5cd74cab7bb015c140144c45026d24310c82a1ef Mon Sep 17 00:00:00 2001 From: Seth Kinast Date: Thu, 4 Sep 2014 19:19:27 -0700 Subject: [PATCH 2/5] Grammar cleanup. Use new |error| grammar. --- lib/parser.js | 290 ++++++++++++++++++++++++++----------------------- src/dust.pegjs | 30 ++++- 2 files changed, 179 insertions(+), 141 deletions(-) diff --git a/lib/parser.js b/lib/parser.js index 745acaf9..687387c5 100644 --- a/lib/parser.js +++ b/lib/parser.js @@ -44,16 +44,32 @@ peg$startRuleFunction = peg$parsestart, peg$c0 = [], - peg$c1 = function(p) { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) }, + peg$c1 = function(p) { + return ["body"] + .concat(p) + .concat([['line', line()], ['col', column()]]); + }, peg$c2 = { type: "other", description: "section" }, peg$c3 = peg$FAILED, peg$c4 = null, - peg$c5 = function(t, b, e, n) {if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line()+", column : " + column())} return true;}, + peg$c5 = function(t, b, e, n) { + if( (!n) || (t[1].text !== n.text) ) { + error("Expected end tag for "+t[1].text+" but it was not found."); + } + return true; + }, peg$c6 = void 0, - peg$c7 = function(t, b, e, n) { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line()], ['col', column()]]) }, + peg$c7 = function(t, b, e, n) { + e.push(["param", ["literal", "block"], b]); + t.push(e); + return t.concat([['line', line()], ['col', column()]]); + }, peg$c8 = "/", peg$c9 = { type: "literal", value: "/", description: "\"/\"" }, - peg$c10 = function(t) { t.push(["bodies"]); return t.concat([['line', line()], ['col', column()]]) }, + peg$c10 = function(t) { + t.push(["bodies"]); + return t.concat([['line', line()], ['col', column()]]); + }, peg$c11 = /^[#?\^<+@%]/, peg$c12 = { type: "class", value: "[#?\\^<+@%]", description: "[#?\\^<+@%]" }, peg$c13 = function(t, n, c, p) { return [t, n, c, p] }, @@ -78,7 +94,10 @@ peg$c32 = "+", peg$c33 = { type: "literal", value: "+", description: "\"+\"" }, peg$c34 = function(k) {return ["literal", k]}, - peg$c35 = function(s, n, c, p) { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line()], ['col', column()]]) }, + peg$c35 = function(s, n, c, p) { + var key = (s === ">") ? "partial" : s; + return [key, n, c, p].concat([['line', line()], ['col', column()]]); + }, peg$c36 = { type: "other", description: "filters" }, peg$c37 = "|", peg$c38 = { type: "literal", value: "|", description: "\"|\"" }, @@ -133,54 +152,55 @@ peg$c75 = { type: "literal", value: "\"", description: "\"\\\"\"" }, peg$c76 = function() { return ["literal", ""].concat([['line', line()], ['col', column()]]) }, peg$c77 = function(l) { return ["literal", l].concat([['line', line()], ['col', column()]]) }, - peg$c78 = function(l) { return ["buffer", l] }, - peg$c79 = { type: "other", description: "buffer" }, - peg$c80 = function(e, w) { return ["format", e, w.join('')].concat([['line', line()], ['col', column()]]) }, - peg$c81 = { type: "any", description: "any character" }, - peg$c82 = function(c) {return c}, - peg$c83 = function(b) { return ["buffer", b.join('')].concat([['line', line()], ['col', column()]]) }, - peg$c84 = { type: "other", description: "literal" }, - peg$c85 = /^[^"]/, - peg$c86 = { type: "class", value: "[^\"]", description: "[^\"]" }, - peg$c87 = function(b) { return b.join('') }, - peg$c88 = "\\\"", - peg$c89 = { type: "literal", value: "\\\"", description: "\"\\\\\\\"\"" }, - peg$c90 = function() { return '"' }, - peg$c91 = { type: "other", description: "raw" }, - peg$c92 = "{`", - peg$c93 = { type: "literal", value: "{`", description: "\"{`\"" }, - peg$c94 = "`}", - peg$c95 = { type: "literal", value: "`}", description: "\"`}\"" }, - peg$c96 = function(char) {return char}, - peg$c97 = function(rawText) { return ["raw", rawText.join('')].concat([['line', line()], ['col', column()]]) }, - peg$c98 = { type: "other", description: "comment" }, - peg$c99 = "{!", - peg$c100 = { type: "literal", value: "{!", description: "\"{!\"" }, - peg$c101 = "!}", - peg$c102 = { type: "literal", value: "!}", description: "\"!}\"" }, - peg$c103 = function(c) { return ["comment", c.join('')].concat([['line', line()], ['col', column()]]) }, - peg$c104 = /^[#?\^><+%:@\/~%]/, - peg$c105 = { type: "class", value: "[#?\\^><+%:@\\/~%]", description: "[#?\\^><+%:@\\/~%]" }, - peg$c106 = "{", - peg$c107 = { type: "literal", value: "{", description: "\"{\"" }, - peg$c108 = "}", - peg$c109 = { type: "literal", value: "}", description: "\"}\"" }, - peg$c110 = "[", - peg$c111 = { type: "literal", value: "[", description: "\"[\"" }, - peg$c112 = "]", - peg$c113 = { type: "literal", value: "]", description: "\"]\"" }, - peg$c114 = "\n", - peg$c115 = { type: "literal", value: "\n", description: "\"\\n\"" }, - peg$c116 = "\r\n", - peg$c117 = { type: "literal", value: "\r\n", description: "\"\\r\\n\"" }, - peg$c118 = "\r", - peg$c119 = { type: "literal", value: "\r", description: "\"\\r\"" }, - peg$c120 = "\u2028", - peg$c121 = { type: "literal", value: "\u2028", description: "\"\\u2028\"" }, - peg$c122 = "\u2029", - peg$c123 = { type: "literal", value: "\u2029", description: "\"\\u2029\"" }, - peg$c124 = /^[\t\x0B\f \xA0\uFEFF]/, - peg$c125 = { type: "class", value: "[\\t\\x0B\\f \\xA0\\uFEFF]", description: "[\\t\\x0B\\f \\xA0\\uFEFF]" }, + peg$c78 = function(p) { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) }, + peg$c79 = function(l) { return ["buffer", l] }, + peg$c80 = { type: "other", description: "buffer" }, + peg$c81 = function(e, w) { return ["format", e, w.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c82 = { type: "any", description: "any character" }, + peg$c83 = function(c) {return c}, + peg$c84 = function(b) { return ["buffer", b.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c85 = { type: "other", description: "literal" }, + peg$c86 = /^[^"]/, + peg$c87 = { type: "class", value: "[^\"]", description: "[^\"]" }, + peg$c88 = function(b) { return b.join('') }, + peg$c89 = "\\\"", + peg$c90 = { type: "literal", value: "\\\"", description: "\"\\\\\\\"\"" }, + peg$c91 = function() { return '"' }, + peg$c92 = { type: "other", description: "raw" }, + peg$c93 = "{`", + peg$c94 = { type: "literal", value: "{`", description: "\"{`\"" }, + peg$c95 = "`}", + peg$c96 = { type: "literal", value: "`}", description: "\"`}\"" }, + peg$c97 = function(char) {return char}, + peg$c98 = function(rawText) { return ["raw", rawText.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c99 = { type: "other", description: "comment" }, + peg$c100 = "{!", + peg$c101 = { type: "literal", value: "{!", description: "\"{!\"" }, + peg$c102 = "!}", + peg$c103 = { type: "literal", value: "!}", description: "\"!}\"" }, + peg$c104 = function(c) { return ["comment", c.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c105 = /^[#?\^><+%:@\/~%]/, + peg$c106 = { type: "class", value: "[#?\\^><+%:@\\/~%]", description: "[#?\\^><+%:@\\/~%]" }, + peg$c107 = "{", + peg$c108 = { type: "literal", value: "{", description: "\"{\"" }, + peg$c109 = "}", + peg$c110 = { type: "literal", value: "}", description: "\"}\"" }, + peg$c111 = "[", + peg$c112 = { type: "literal", value: "[", description: "\"[\"" }, + peg$c113 = "]", + peg$c114 = { type: "literal", value: "]", description: "\"]\"" }, + peg$c115 = "\n", + peg$c116 = { type: "literal", value: "\n", description: "\"\\n\"" }, + peg$c117 = "\r\n", + peg$c118 = { type: "literal", value: "\r\n", description: "\"\\r\\n\"" }, + peg$c119 = "\r", + peg$c120 = { type: "literal", value: "\r", description: "\"\\r\"" }, + peg$c121 = "\u2028", + peg$c122 = { type: "literal", value: "\u2028", description: "\"\\u2028\"" }, + peg$c123 = "\u2029", + peg$c124 = { type: "literal", value: "\u2029", description: "\"\\u2029\"" }, + peg$c125 = /^[\t\x0B\f \xA0\uFEFF]/, + peg$c126 = { type: "class", value: "[\\t\\x0B\\f \\xA0\\uFEFF]", description: "[\\t\\x0B\\f \\xA0\\uFEFF]" }, peg$currPos = 0, peg$reportedPos = 0, @@ -1710,7 +1730,7 @@ } if (s3 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c1(s2); + s1 = peg$c78(s2); s0 = s1; } else { peg$currPos = s0; @@ -1746,7 +1766,7 @@ s1 = peg$parseliteral(); if (s1 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c78(s1); + s1 = peg$c79(s1); } s0 = s1; } @@ -1770,7 +1790,7 @@ } if (s2 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c80(s1, s2); + s1 = peg$c81(s1, s2); s0 = s1; } else { peg$currPos = s0; @@ -1833,11 +1853,11 @@ peg$currPos++; } else { s7 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s7 !== peg$FAILED) { peg$reportedPos = s2; - s3 = peg$c82(s7); + s3 = peg$c83(s7); s2 = s3; } else { peg$currPos = s2; @@ -1912,11 +1932,11 @@ peg$currPos++; } else { s7 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s7 !== peg$FAILED) { peg$reportedPos = s2; - s3 = peg$c82(s7); + s3 = peg$c83(s7); s2 = s3; } else { peg$currPos = s2; @@ -1944,14 +1964,14 @@ } if (s1 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c83(s1); + s1 = peg$c84(s1); } s0 = s1; } peg$silentFails--; if (s0 === peg$FAILED) { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c79); } + if (peg$silentFails === 0) { peg$fail(peg$c80); } } return s0; @@ -1977,17 +1997,17 @@ if (s3 !== peg$FAILED) { s4 = peg$parseesc(); if (s4 === peg$FAILED) { - if (peg$c85.test(input.charAt(peg$currPos))) { + if (peg$c86.test(input.charAt(peg$currPos))) { s4 = input.charAt(peg$currPos); peg$currPos++; } else { s4 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c86); } + if (peg$silentFails === 0) { peg$fail(peg$c87); } } } if (s4 !== peg$FAILED) { peg$reportedPos = s2; - s3 = peg$c82(s4); + s3 = peg$c83(s4); s2 = s3; } else { peg$currPos = s2; @@ -2014,17 +2034,17 @@ if (s3 !== peg$FAILED) { s4 = peg$parseesc(); if (s4 === peg$FAILED) { - if (peg$c85.test(input.charAt(peg$currPos))) { + if (peg$c86.test(input.charAt(peg$currPos))) { s4 = input.charAt(peg$currPos); peg$currPos++; } else { s4 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c86); } + if (peg$silentFails === 0) { peg$fail(peg$c87); } } } if (s4 !== peg$FAILED) { peg$reportedPos = s2; - s3 = peg$c82(s4); + s3 = peg$c83(s4); s2 = s3; } else { peg$currPos = s2; @@ -2040,13 +2060,13 @@ } if (s1 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c87(s1); + s1 = peg$c88(s1); } s0 = s1; peg$silentFails--; if (s0 === peg$FAILED) { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c84); } + if (peg$silentFails === 0) { peg$fail(peg$c85); } } return s0; @@ -2056,16 +2076,16 @@ var s0, s1; s0 = peg$currPos; - if (input.substr(peg$currPos, 2) === peg$c88) { - s1 = peg$c88; + if (input.substr(peg$currPos, 2) === peg$c89) { + s1 = peg$c89; peg$currPos += 2; } else { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c89); } + if (peg$silentFails === 0) { peg$fail(peg$c90); } } if (s1 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c90(); + s1 = peg$c91(); } s0 = s1; @@ -2077,24 +2097,24 @@ peg$silentFails++; s0 = peg$currPos; - if (input.substr(peg$currPos, 2) === peg$c92) { - s1 = peg$c92; + if (input.substr(peg$currPos, 2) === peg$c93) { + s1 = peg$c93; peg$currPos += 2; } else { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c93); } + if (peg$silentFails === 0) { peg$fail(peg$c94); } } if (s1 !== peg$FAILED) { s2 = []; s3 = peg$currPos; s4 = peg$currPos; peg$silentFails++; - if (input.substr(peg$currPos, 2) === peg$c94) { - s5 = peg$c94; + if (input.substr(peg$currPos, 2) === peg$c95) { + s5 = peg$c95; peg$currPos += 2; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c95); } + if (peg$silentFails === 0) { peg$fail(peg$c96); } } peg$silentFails--; if (s5 === peg$FAILED) { @@ -2109,11 +2129,11 @@ peg$currPos++; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s5 !== peg$FAILED) { peg$reportedPos = s3; - s4 = peg$c96(s5); + s4 = peg$c97(s5); s3 = s4; } else { peg$currPos = s3; @@ -2128,12 +2148,12 @@ s3 = peg$currPos; s4 = peg$currPos; peg$silentFails++; - if (input.substr(peg$currPos, 2) === peg$c94) { - s5 = peg$c94; + if (input.substr(peg$currPos, 2) === peg$c95) { + s5 = peg$c95; peg$currPos += 2; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c95); } + if (peg$silentFails === 0) { peg$fail(peg$c96); } } peg$silentFails--; if (s5 === peg$FAILED) { @@ -2148,11 +2168,11 @@ peg$currPos++; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s5 !== peg$FAILED) { peg$reportedPos = s3; - s4 = peg$c96(s5); + s4 = peg$c97(s5); s3 = s4; } else { peg$currPos = s3; @@ -2164,16 +2184,16 @@ } } if (s2 !== peg$FAILED) { - if (input.substr(peg$currPos, 2) === peg$c94) { - s3 = peg$c94; + if (input.substr(peg$currPos, 2) === peg$c95) { + s3 = peg$c95; peg$currPos += 2; } else { s3 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c95); } + if (peg$silentFails === 0) { peg$fail(peg$c96); } } if (s3 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c97(s2); + s1 = peg$c98(s2); s0 = s1; } else { peg$currPos = s0; @@ -2190,7 +2210,7 @@ peg$silentFails--; if (s0 === peg$FAILED) { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c91); } + if (peg$silentFails === 0) { peg$fail(peg$c92); } } return s0; @@ -2201,24 +2221,24 @@ peg$silentFails++; s0 = peg$currPos; - if (input.substr(peg$currPos, 2) === peg$c99) { - s1 = peg$c99; + if (input.substr(peg$currPos, 2) === peg$c100) { + s1 = peg$c100; peg$currPos += 2; } else { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c100); } + if (peg$silentFails === 0) { peg$fail(peg$c101); } } if (s1 !== peg$FAILED) { s2 = []; s3 = peg$currPos; s4 = peg$currPos; peg$silentFails++; - if (input.substr(peg$currPos, 2) === peg$c101) { - s5 = peg$c101; + if (input.substr(peg$currPos, 2) === peg$c102) { + s5 = peg$c102; peg$currPos += 2; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c102); } + if (peg$silentFails === 0) { peg$fail(peg$c103); } } peg$silentFails--; if (s5 === peg$FAILED) { @@ -2233,11 +2253,11 @@ peg$currPos++; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s5 !== peg$FAILED) { peg$reportedPos = s3; - s4 = peg$c82(s5); + s4 = peg$c83(s5); s3 = s4; } else { peg$currPos = s3; @@ -2252,12 +2272,12 @@ s3 = peg$currPos; s4 = peg$currPos; peg$silentFails++; - if (input.substr(peg$currPos, 2) === peg$c101) { - s5 = peg$c101; + if (input.substr(peg$currPos, 2) === peg$c102) { + s5 = peg$c102; peg$currPos += 2; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c102); } + if (peg$silentFails === 0) { peg$fail(peg$c103); } } peg$silentFails--; if (s5 === peg$FAILED) { @@ -2272,11 +2292,11 @@ peg$currPos++; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s5 !== peg$FAILED) { peg$reportedPos = s3; - s4 = peg$c82(s5); + s4 = peg$c83(s5); s3 = s4; } else { peg$currPos = s3; @@ -2288,16 +2308,16 @@ } } if (s2 !== peg$FAILED) { - if (input.substr(peg$currPos, 2) === peg$c101) { - s3 = peg$c101; + if (input.substr(peg$currPos, 2) === peg$c102) { + s3 = peg$c102; peg$currPos += 2; } else { s3 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c102); } + if (peg$silentFails === 0) { peg$fail(peg$c103); } } if (s3 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c103(s2); + s1 = peg$c104(s2); s0 = s1; } else { peg$currPos = s0; @@ -2314,7 +2334,7 @@ peg$silentFails--; if (s0 === peg$FAILED) { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c98); } + if (peg$silentFails === 0) { peg$fail(peg$c99); } } return s0; @@ -2333,12 +2353,12 @@ s3 = peg$parsews(); } if (s2 !== peg$FAILED) { - if (peg$c104.test(input.charAt(peg$currPos))) { + if (peg$c105.test(input.charAt(peg$currPos))) { s3 = input.charAt(peg$currPos); peg$currPos++; } else { s3 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c105); } + if (peg$silentFails === 0) { peg$fail(peg$c106); } } if (s3 !== peg$FAILED) { s4 = []; @@ -2377,7 +2397,7 @@ peg$currPos++; } else { s9 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s9 !== peg$FAILED) { s7 = [s7, s8, s9]; @@ -2425,7 +2445,7 @@ peg$currPos++; } else { s9 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s9 !== peg$FAILED) { s7 = [s7, s8, s9]; @@ -2497,11 +2517,11 @@ var s0; if (input.charCodeAt(peg$currPos) === 123) { - s0 = peg$c106; + s0 = peg$c107; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c107); } + if (peg$silentFails === 0) { peg$fail(peg$c108); } } return s0; @@ -2511,11 +2531,11 @@ var s0; if (input.charCodeAt(peg$currPos) === 125) { - s0 = peg$c108; + s0 = peg$c109; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c109); } + if (peg$silentFails === 0) { peg$fail(peg$c110); } } return s0; @@ -2525,11 +2545,11 @@ var s0; if (input.charCodeAt(peg$currPos) === 91) { - s0 = peg$c110; + s0 = peg$c111; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c111); } + if (peg$silentFails === 0) { peg$fail(peg$c112); } } return s0; @@ -2539,11 +2559,11 @@ var s0; if (input.charCodeAt(peg$currPos) === 93) { - s0 = peg$c112; + s0 = peg$c113; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c113); } + if (peg$silentFails === 0) { peg$fail(peg$c114); } } return s0; @@ -2553,43 +2573,43 @@ var s0; if (input.charCodeAt(peg$currPos) === 10) { - s0 = peg$c114; + s0 = peg$c115; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c115); } + if (peg$silentFails === 0) { peg$fail(peg$c116); } } if (s0 === peg$FAILED) { - if (input.substr(peg$currPos, 2) === peg$c116) { - s0 = peg$c116; + if (input.substr(peg$currPos, 2) === peg$c117) { + s0 = peg$c117; peg$currPos += 2; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c117); } + if (peg$silentFails === 0) { peg$fail(peg$c118); } } if (s0 === peg$FAILED) { if (input.charCodeAt(peg$currPos) === 13) { - s0 = peg$c118; + s0 = peg$c119; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c119); } + if (peg$silentFails === 0) { peg$fail(peg$c120); } } if (s0 === peg$FAILED) { if (input.charCodeAt(peg$currPos) === 8232) { - s0 = peg$c120; + s0 = peg$c121; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c121); } + if (peg$silentFails === 0) { peg$fail(peg$c122); } } if (s0 === peg$FAILED) { if (input.charCodeAt(peg$currPos) === 8233) { - s0 = peg$c122; + s0 = peg$c123; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c123); } + if (peg$silentFails === 0) { peg$fail(peg$c124); } } } } @@ -2602,12 +2622,12 @@ function peg$parsews() { var s0; - if (peg$c124.test(input.charAt(peg$currPos))) { + if (peg$c125.test(input.charAt(peg$currPos))) { s0 = input.charAt(peg$currPos); peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c125); } + if (peg$silentFails === 0) { peg$fail(peg$c126); } } if (s0 === peg$FAILED) { s0 = peg$parseeol(); diff --git a/src/dust.pegjs b/src/dust.pegjs index 8119a40f..5b9a0667 100644 --- a/src/dust.pegjs +++ b/src/dust.pegjs @@ -5,7 +5,11 @@ start body is defined as anything that matches with the part 0 or more times ---------------------------------------------------------------------------------------------------------------------------------------*/ body - = p:part* { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) } + = p:part* { + return ["body"] + .concat(p) + .concat([['line', line()], ['col', column()]]); + } /*------------------------------------------------------------------------------------------------------------------------------------- part is defined as anything that matches with raw or comment or section or partial or special or reference or buffer @@ -18,10 +22,21 @@ part plus bodies plus end_tag or sec_tag_start followed by a slash and closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ section "section" - = t:sec_tag_start ws* rd b:body e:bodies n:end_tag? &{if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line()+", column : " + column())} return true;} - { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line()], ['col', column()]]) } - / t:sec_tag_start ws* "/" rd - { t.push(["bodies"]); return t.concat([['line', line()], ['col', column()]]) } + = t:sec_tag_start ws* rd b:body e:bodies n:end_tag? &{ + if( (!n) || (t[1].text !== n.text) ) { + error("Expected end tag for "+t[1].text+" but it was not found."); + } + return true; + } + { + e.push(["param", ["literal", "block"], b]); + t.push(e); + return t.concat([['line', line()], ['col', column()]]); + } + / t:sec_tag_start ws* "/" rd { + t.push(["bodies"]); + return t.concat([['line', line()], ['col', column()]]); + } /*------------------------------------------------------------------------------------------------------------------------------------- sec_tag_start is defined as matching an opening brace followed by one of #?^<+@% plus identifier plus context plus param @@ -73,7 +88,10 @@ reference "reference" ---------------------------------------------------------------------------------------------------------------------------------------*/ partial "partial" = ld s:(">"/"+") ws* n:(k:key {return ["literal", k]} / inline) c:context p:params ws* "/" rd - { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line()], ['col', column()]]) } + { + var key = (s === ">") ? "partial" : s; + return [key, n, c, p].concat([['line', line()], ['col', column()]]); + } /*------------------------------------------------------------------------------------------------------------------------------------- filters is defined as matching a pipe character followed by anything that matches the key From 94f732d7b0b9317e57ad43996d6aea7cfd92a017 Mon Sep 17 00:00:00 2001 From: Seth Kinast Date: Thu, 4 Sep 2014 18:40:42 -0700 Subject: [PATCH 3/5] Upgrade pegJS to 0.8 --- bower.json | 2 +- lib/parser.js | 4839 +++++++++++++-------------- package.json | 2 +- src/build.js | 5 +- src/dust.pegjs | 54 +- test/jasmine-test/spec/coreTests.js | 10 +- 6 files changed, 2366 insertions(+), 2546 deletions(-) diff --git a/bower.json b/bower.json index 156adc50..dcc8a4dd 100644 --- a/bower.json +++ b/bower.json @@ -3,7 +3,7 @@ "version": "2.3.5", "main": "dist/dust-full.min.js", "devDependencies": { - "pegjs": "0.7.0" + "pegjs": "0.8.0" }, "ignore": [ "**/.*", diff --git a/lib/parser.js b/lib/parser.js index e683df63..745acaf9 100644 --- a/lib/parser.js +++ b/lib/parser.js @@ -9,2811 +9,2630 @@ factory(root.dust); } }(this, function(dust) { - var parser = (function(){ + var parser = (function() { /* - * Generated by PEG.js 0.7.0. + * Generated by PEG.js 0.8.0. * * http://pegjs.majda.cz/ */ - - function quote(s) { - /* - * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a - * string literal except for the closing quote character, backslash, - * carriage return, line separator, paragraph separator, and line feed. - * Any character may appear in the form of an escape sequence. - * - * For portability, we also escape escape all control and non-ASCII - * characters. Note that "\0" and "\v" escape sequences are not used - * because JSHint does not like the first and IE the second. - */ - return '"' + s - .replace(/\\/g, '\\\\') // backslash - .replace(/"/g, '\\"') // closing quote character - .replace(/\x08/g, '\\b') // backspace - .replace(/\t/g, '\\t') // horizontal tab - .replace(/\n/g, '\\n') // line feed - .replace(/\f/g, '\\f') // form feed - .replace(/\r/g, '\\r') // carriage return - .replace(/[\x00-\x07\x0B\x0E-\x1F\x80-\uFFFF]/g, escape) - + '"'; + + function peg$subclass(child, parent) { + function ctor() { this.constructor = child; } + ctor.prototype = parent.prototype; + child.prototype = new ctor(); } - - var result = { - /* - * Parses the input with a generated parser. If the parsing is successfull, - * returns a value explicitly or implicitly specified by the grammar from - * which the parser was generated (see |PEG.buildParser|). If the parsing is - * unsuccessful, throws |PEG.parser.SyntaxError| describing the error. - */ - parse: function(input, startRule) { - var parseFunctions = { - "body": parse_body, - "part": parse_part, - "section": parse_section, - "sec_tag_start": parse_sec_tag_start, - "end_tag": parse_end_tag, - "context": parse_context, - "params": parse_params, - "bodies": parse_bodies, - "reference": parse_reference, - "partial": parse_partial, - "filters": parse_filters, - "special": parse_special, - "identifier": parse_identifier, - "number": parse_number, - "float": parse_float, - "integer": parse_integer, - "path": parse_path, - "key": parse_key, - "array": parse_array, - "array_part": parse_array_part, - "inline": parse_inline, - "inline_part": parse_inline_part, - "buffer": parse_buffer, - "literal": parse_literal, - "esc": parse_esc, - "raw": parse_raw, - "comment": parse_comment, - "tag": parse_tag, - "ld": parse_ld, - "rd": parse_rd, - "lb": parse_lb, - "rb": parse_rb, - "eol": parse_eol, - "ws": parse_ws - }; - - if (startRule !== undefined) { - if (parseFunctions[startRule] === undefined) { - throw new Error("Invalid rule name: " + quote(startRule) + "."); - } - } else { - startRule = "body"; - } - - var pos = { offset: 0, line: 1, column: 1, seenCR: false }; - var reportFailures = 0; - var rightmostFailuresPos = { offset: 0, line: 1, column: 1, seenCR: false }; - var rightmostFailuresExpected = []; - - function padLeft(input, padding, length) { - var result = input; - - var padLength = length - input.length; - for (var i = 0; i < padLength; i++) { - result = padding + result; - } - - return result; - } - - function escape(ch) { - var charCode = ch.charCodeAt(0); - var escapeChar; - var length; - - if (charCode <= 0xFF) { - escapeChar = 'x'; - length = 2; - } else { - escapeChar = 'u'; - length = 4; - } - - return '\\' + escapeChar + padLeft(charCode.toString(16).toUpperCase(), '0', length); - } - - function clone(object) { - var result = {}; - for (var key in object) { - result[key] = object[key]; - } - return result; - } - - function advance(pos, n) { - var endOffset = pos.offset + n; - - for (var offset = pos.offset; offset < endOffset; offset++) { - var ch = input.charAt(offset); + + function SyntaxError(message, expected, found, offset, line, column) { + this.message = message; + this.expected = expected; + this.found = found; + this.offset = offset; + this.line = line; + this.column = column; + + this.name = "SyntaxError"; + } + + peg$subclass(SyntaxError, Error); + + function parse(input) { + var options = arguments.length > 1 ? arguments[1] : {}, + + peg$FAILED = {}, + + peg$startRuleFunctions = { start: peg$parsestart }, + peg$startRuleFunction = peg$parsestart, + + peg$c0 = [], + peg$c1 = function(p) { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) }, + peg$c2 = { type: "other", description: "section" }, + peg$c3 = peg$FAILED, + peg$c4 = null, + peg$c5 = function(t, b, e, n) {if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line()+", column : " + column())} return true;}, + peg$c6 = void 0, + peg$c7 = function(t, b, e, n) { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line()], ['col', column()]]) }, + peg$c8 = "/", + peg$c9 = { type: "literal", value: "/", description: "\"/\"" }, + peg$c10 = function(t) { t.push(["bodies"]); return t.concat([['line', line()], ['col', column()]]) }, + peg$c11 = /^[#?\^<+@%]/, + peg$c12 = { type: "class", value: "[#?\\^<+@%]", description: "[#?\\^<+@%]" }, + peg$c13 = function(t, n, c, p) { return [t, n, c, p] }, + peg$c14 = { type: "other", description: "end tag" }, + peg$c15 = function(n) { return n }, + peg$c16 = ":", + peg$c17 = { type: "literal", value: ":", description: "\":\"" }, + peg$c18 = function(n) {return n}, + peg$c19 = function(n) { return n ? ["context", n] : ["context"] }, + peg$c20 = { type: "other", description: "params" }, + peg$c21 = "=", + peg$c22 = { type: "literal", value: "=", description: "\"=\"" }, + peg$c23 = function(k, v) {return ["param", ["literal", k], v]}, + peg$c24 = function(p) { return ["params"].concat(p) }, + peg$c25 = { type: "other", description: "bodies" }, + peg$c26 = function(p) { return ["bodies"].concat(p) }, + peg$c27 = { type: "other", description: "reference" }, + peg$c28 = function(n, f) { return ["reference", n, f].concat([['line', line()], ['col', column()]]) }, + peg$c29 = { type: "other", description: "partial" }, + peg$c30 = ">", + peg$c31 = { type: "literal", value: ">", description: "\">\"" }, + peg$c32 = "+", + peg$c33 = { type: "literal", value: "+", description: "\"+\"" }, + peg$c34 = function(k) {return ["literal", k]}, + peg$c35 = function(s, n, c, p) { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line()], ['col', column()]]) }, + peg$c36 = { type: "other", description: "filters" }, + peg$c37 = "|", + peg$c38 = { type: "literal", value: "|", description: "\"|\"" }, + peg$c39 = function(f) { return ["filters"].concat(f) }, + peg$c40 = { type: "other", description: "special" }, + peg$c41 = "~", + peg$c42 = { type: "literal", value: "~", description: "\"~\"" }, + peg$c43 = function(k) { return ["special", k].concat([['line', line()], ['col', column()]]) }, + peg$c44 = { type: "other", description: "identifier" }, + peg$c45 = function(p) { var arr = ["path"].concat(p); arr.text = p[1].join('.'); return arr; }, + peg$c46 = function(k) { var arr = ["key", k]; arr.text = k; return arr; }, + peg$c47 = { type: "other", description: "number" }, + peg$c48 = function(n) { return ['literal', n]; }, + peg$c49 = { type: "other", description: "float" }, + peg$c50 = ".", + peg$c51 = { type: "literal", value: ".", description: "\".\"" }, + peg$c52 = function(l, r) { return parseFloat(l + "." + r.join('')); }, + peg$c53 = { type: "other", description: "integer" }, + peg$c54 = /^[0-9]/, + peg$c55 = { type: "class", value: "[0-9]", description: "[0-9]" }, + peg$c56 = function(digits) { return parseInt(digits.join(""), 10); }, + peg$c57 = { type: "other", description: "path" }, + peg$c58 = function(k, d) { + d = d[0]; + if (k && d) { + d.unshift(k); + return [false, d].concat([['line', line()], ['col', column()]]); + } + return [true, d].concat([['line', line()], ['col', column()]]); + }, + peg$c59 = function(d) { + if (d.length > 0) { + return [true, d[0]].concat([['line', line()], ['col', column()]]); + } + return [true, []].concat([['line', line()], ['col', column()]]); + }, + peg$c60 = { type: "other", description: "key" }, + peg$c61 = /^[a-zA-Z_$]/, + peg$c62 = { type: "class", value: "[a-zA-Z_$]", description: "[a-zA-Z_$]" }, + peg$c63 = /^[0-9a-zA-Z_$\-]/, + peg$c64 = { type: "class", value: "[0-9a-zA-Z_$\\-]", description: "[0-9a-zA-Z_$\\-]" }, + peg$c65 = function(h, t) { return h + t.join('') }, + peg$c66 = { type: "other", description: "array" }, + peg$c67 = function(n) {return n.join('')}, + peg$c68 = function(a) {return a; }, + peg$c69 = function(i, nk) { if(nk) { nk.unshift(i); } else {nk = [i] } return nk; }, + peg$c70 = { type: "other", description: "array_part" }, + peg$c71 = function(k) {return k}, + peg$c72 = function(d, a) { if (a) { return d.concat(a); } else { return d; } }, + peg$c73 = { type: "other", description: "inline" }, + peg$c74 = "\"", + peg$c75 = { type: "literal", value: "\"", description: "\"\\\"\"" }, + peg$c76 = function() { return ["literal", ""].concat([['line', line()], ['col', column()]]) }, + peg$c77 = function(l) { return ["literal", l].concat([['line', line()], ['col', column()]]) }, + peg$c78 = function(l) { return ["buffer", l] }, + peg$c79 = { type: "other", description: "buffer" }, + peg$c80 = function(e, w) { return ["format", e, w.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c81 = { type: "any", description: "any character" }, + peg$c82 = function(c) {return c}, + peg$c83 = function(b) { return ["buffer", b.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c84 = { type: "other", description: "literal" }, + peg$c85 = /^[^"]/, + peg$c86 = { type: "class", value: "[^\"]", description: "[^\"]" }, + peg$c87 = function(b) { return b.join('') }, + peg$c88 = "\\\"", + peg$c89 = { type: "literal", value: "\\\"", description: "\"\\\\\\\"\"" }, + peg$c90 = function() { return '"' }, + peg$c91 = { type: "other", description: "raw" }, + peg$c92 = "{`", + peg$c93 = { type: "literal", value: "{`", description: "\"{`\"" }, + peg$c94 = "`}", + peg$c95 = { type: "literal", value: "`}", description: "\"`}\"" }, + peg$c96 = function(char) {return char}, + peg$c97 = function(rawText) { return ["raw", rawText.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c98 = { type: "other", description: "comment" }, + peg$c99 = "{!", + peg$c100 = { type: "literal", value: "{!", description: "\"{!\"" }, + peg$c101 = "!}", + peg$c102 = { type: "literal", value: "!}", description: "\"!}\"" }, + peg$c103 = function(c) { return ["comment", c.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c104 = /^[#?\^><+%:@\/~%]/, + peg$c105 = { type: "class", value: "[#?\\^><+%:@\\/~%]", description: "[#?\\^><+%:@\\/~%]" }, + peg$c106 = "{", + peg$c107 = { type: "literal", value: "{", description: "\"{\"" }, + peg$c108 = "}", + peg$c109 = { type: "literal", value: "}", description: "\"}\"" }, + peg$c110 = "[", + peg$c111 = { type: "literal", value: "[", description: "\"[\"" }, + peg$c112 = "]", + peg$c113 = { type: "literal", value: "]", description: "\"]\"" }, + peg$c114 = "\n", + peg$c115 = { type: "literal", value: "\n", description: "\"\\n\"" }, + peg$c116 = "\r\n", + peg$c117 = { type: "literal", value: "\r\n", description: "\"\\r\\n\"" }, + peg$c118 = "\r", + peg$c119 = { type: "literal", value: "\r", description: "\"\\r\"" }, + peg$c120 = "\u2028", + peg$c121 = { type: "literal", value: "\u2028", description: "\"\\u2028\"" }, + peg$c122 = "\u2029", + peg$c123 = { type: "literal", value: "\u2029", description: "\"\\u2029\"" }, + peg$c124 = /^[\t\x0B\f \xA0\uFEFF]/, + peg$c125 = { type: "class", value: "[\\t\\x0B\\f \\xA0\\uFEFF]", description: "[\\t\\x0B\\f \\xA0\\uFEFF]" }, + + peg$currPos = 0, + peg$reportedPos = 0, + peg$cachedPos = 0, + peg$cachedPosDetails = { line: 1, column: 1, seenCR: false }, + peg$maxFailPos = 0, + peg$maxFailExpected = [], + peg$silentFails = 0, + + peg$result; + + if ("startRule" in options) { + if (!(options.startRule in peg$startRuleFunctions)) { + throw new Error("Can't start parsing from rule \"" + options.startRule + "\"."); + } + + peg$startRuleFunction = peg$startRuleFunctions[options.startRule]; + } + + function text() { + return input.substring(peg$reportedPos, peg$currPos); + } + + function offset() { + return peg$reportedPos; + } + + function line() { + return peg$computePosDetails(peg$reportedPos).line; + } + + function column() { + return peg$computePosDetails(peg$reportedPos).column; + } + + function expected(description) { + throw peg$buildException( + null, + [{ type: "other", description: description }], + peg$reportedPos + ); + } + + function error(message) { + throw peg$buildException(message, null, peg$reportedPos); + } + + function peg$computePosDetails(pos) { + function advance(details, startPos, endPos) { + var p, ch; + + for (p = startPos; p < endPos; p++) { + ch = input.charAt(p); if (ch === "\n") { - if (!pos.seenCR) { pos.line++; } - pos.column = 1; - pos.seenCR = false; + if (!details.seenCR) { details.line++; } + details.column = 1; + details.seenCR = false; } else if (ch === "\r" || ch === "\u2028" || ch === "\u2029") { - pos.line++; - pos.column = 1; - pos.seenCR = true; + details.line++; + details.column = 1; + details.seenCR = true; } else { - pos.column++; - pos.seenCR = false; - } - } - - pos.offset += n; - } - - function matchFailed(failure) { - if (pos.offset < rightmostFailuresPos.offset) { - return; - } - - if (pos.offset > rightmostFailuresPos.offset) { - rightmostFailuresPos = clone(pos); - rightmostFailuresExpected = []; - } - - rightmostFailuresExpected.push(failure); - } - - function parse_body() { - var result0, result1; - var pos0; - - pos0 = clone(pos); - result0 = []; - result1 = parse_part(); - while (result1 !== null) { - result0.push(result1); - result1 = parse_part(); - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["body"].concat(p).concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_part() { - var result0; - - result0 = parse_raw(); - if (result0 === null) { - result0 = parse_comment(); - if (result0 === null) { - result0 = parse_section(); - if (result0 === null) { - result0 = parse_partial(); - if (result0 === null) { - result0 = parse_special(); - if (result0 === null) { - result0 = parse_reference(); - if (result0 === null) { - result0 = parse_buffer(); - } + details.column++; + details.seenCR = false; + } + } + } + + if (peg$cachedPos !== pos) { + if (peg$cachedPos > pos) { + peg$cachedPos = 0; + peg$cachedPosDetails = { line: 1, column: 1, seenCR: false }; + } + advance(peg$cachedPosDetails, peg$cachedPos, pos); + peg$cachedPos = pos; + } + + return peg$cachedPosDetails; + } + + function peg$fail(expected) { + if (peg$currPos < peg$maxFailPos) { return; } + + if (peg$currPos > peg$maxFailPos) { + peg$maxFailPos = peg$currPos; + peg$maxFailExpected = []; + } + + peg$maxFailExpected.push(expected); + } + + function peg$buildException(message, expected, pos) { + function cleanupExpected(expected) { + var i = 1; + + expected.sort(function(a, b) { + if (a.description < b.description) { + return -1; + } else if (a.description > b.description) { + return 1; + } else { + return 0; + } + }); + + while (i < expected.length) { + if (expected[i - 1] === expected[i]) { + expected.splice(i, 1); + } else { + i++; + } + } + } + + function buildMessage(expected, found) { + function stringEscape(s) { + function hex(ch) { return ch.charCodeAt(0).toString(16).toUpperCase(); } + + return s + .replace(/\\/g, '\\\\') + .replace(/"/g, '\\"') + .replace(/\x08/g, '\\b') + .replace(/\t/g, '\\t') + .replace(/\n/g, '\\n') + .replace(/\f/g, '\\f') + .replace(/\r/g, '\\r') + .replace(/[\x00-\x07\x0B\x0E\x0F]/g, function(ch) { return '\\x0' + hex(ch); }) + .replace(/[\x10-\x1F\x80-\xFF]/g, function(ch) { return '\\x' + hex(ch); }) + .replace(/[\u0180-\u0FFF]/g, function(ch) { return '\\u0' + hex(ch); }) + .replace(/[\u1080-\uFFFF]/g, function(ch) { return '\\u' + hex(ch); }); + } + + var expectedDescs = new Array(expected.length), + expectedDesc, foundDesc, i; + + for (i = 0; i < expected.length; i++) { + expectedDescs[i] = expected[i].description; + } + + expectedDesc = expected.length > 1 + ? expectedDescs.slice(0, -1).join(", ") + + " or " + + expectedDescs[expected.length - 1] + : expectedDescs[0]; + + foundDesc = found ? "\"" + stringEscape(found) + "\"" : "end of input"; + + return "Expected " + expectedDesc + " but " + foundDesc + " found."; + } + + var posDetails = peg$computePosDetails(pos), + found = pos < input.length ? input.charAt(pos) : null; + + if (expected !== null) { + cleanupExpected(expected); + } + + return new SyntaxError( + message !== null ? message : buildMessage(expected, found), + expected, + found, + pos, + posDetails.line, + posDetails.column + ); + } + + function peg$parsestart() { + var s0; + + s0 = peg$parsebody(); + + return s0; + } + + function peg$parsebody() { + var s0, s1, s2; + + s0 = peg$currPos; + s1 = []; + s2 = peg$parsepart(); + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$parsepart(); + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c1(s1); + } + s0 = s1; + + return s0; + } + + function peg$parsepart() { + var s0; + + s0 = peg$parseraw(); + if (s0 === peg$FAILED) { + s0 = peg$parsecomment(); + if (s0 === peg$FAILED) { + s0 = peg$parsesection(); + if (s0 === peg$FAILED) { + s0 = peg$parsepartial(); + if (s0 === peg$FAILED) { + s0 = peg$parsespecial(); + if (s0 === peg$FAILED) { + s0 = peg$parsereference(); + if (s0 === peg$FAILED) { + s0 = peg$parsebuffer(); } } } } } - return result0; - } - - function parse_section() { - var result0, result1, result2, result3, result4, result5, result6; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_sec_tag_start(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - result2 = parse_rd(); - if (result2 !== null) { - result3 = parse_body(); - if (result3 !== null) { - result4 = parse_bodies(); - if (result4 !== null) { - result5 = parse_end_tag(); - result5 = result5 !== null ? result5 : ""; - if (result5 !== null) { - result6 = (function(offset, line, column, t, b, e, n) {if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line+", column : " + column)} return true;})(pos.offset, pos.line, pos.column, result0, result3, result4, result5) ? "" : null; - if (result6 !== null) { - result0 = [result0, result1, result2, result3, result4, result5, result6]; - } else { - result0 = null; - pos = clone(pos1); - } + } + + return s0; + } + + function peg$parsesection() { + var s0, s1, s2, s3, s4, s5, s6, s7; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsesec_tag_start(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + s3 = peg$parserd(); + if (s3 !== peg$FAILED) { + s4 = peg$parsebody(); + if (s4 !== peg$FAILED) { + s5 = peg$parsebodies(); + if (s5 !== peg$FAILED) { + s6 = peg$parseend_tag(); + if (s6 === peg$FAILED) { + s6 = peg$c4; + } + if (s6 !== peg$FAILED) { + peg$reportedPos = peg$currPos; + s7 = peg$c5(s1, s4, s5, s6); + if (s7) { + s7 = peg$c6; } else { - result0 = null; - pos = clone(pos1); + s7 = peg$c3; + } + if (s7 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c7(s1, s4, s5, s6); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, t, b, e, n) { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[0], result0[3], result0[4], result0[5]); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_sec_tag_start(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 47) { - result2 = "/"; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"/\""); - } - } - if (result2 !== null) { - result3 = parse_rd(); - if (result3 !== null) { - result0 = [result0, result1, result2, result3]; - } else { - result0 = null; - pos = clone(pos1); - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = peg$parsesec_tag_start(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 47) { + s3 = peg$c8; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c9); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parserd(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c10(s1); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, t) { t.push(["bodies"]); return t.concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[0]); - } - if (result0 === null) { - pos = clone(pos0); - } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("section"); - } - return result0; - } - - function parse_sec_tag_start() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1; - - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (/^[#?^<+@%]/.test(input.charAt(pos.offset))) { - result1 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("[#?^<+@%]"); - } + peg$currPos = s0; + s0 = peg$c3; } - if (result1 !== null) { - result2 = []; - result3 = parse_ws(); - while (result3 !== null) { - result2.push(result3); - result3 = parse_ws(); - } - if (result2 !== null) { - result3 = parse_identifier(); - if (result3 !== null) { - result4 = parse_context(); - if (result4 !== null) { - result5 = parse_params(); - if (result5 !== null) { - result0 = [result0, result1, result2, result3, result4, result5]; - } else { - result0 = null; - pos = clone(pos1); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c2); } + } + + return s0; + } + + function peg$parsesec_tag_start() { + var s0, s1, s2, s3, s4, s5, s6; + + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (peg$c11.test(input.charAt(peg$currPos))) { + s2 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c12); } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parsews(); + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + if (s3 !== peg$FAILED) { + s4 = peg$parseidentifier(); + if (s4 !== peg$FAILED) { + s5 = peg$parsecontext(); + if (s5 !== peg$FAILED) { + s6 = peg$parseparams(); + if (s6 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c13(s2, s4, s5, s6); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, t, n, c, p) { return [t, n, c, p] })(pos0.offset, pos0.line, pos0.column, result0[1], result0[3], result0[4], result0[5]); - } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_end_tag() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 47) { - result1 = "/"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"/\""); - } - } - if (result1 !== null) { - result2 = []; - result3 = parse_ws(); - while (result3 !== null) { - result2.push(result3); - result3 = parse_ws(); - } - if (result2 !== null) { - result3 = parse_identifier(); - if (result3 !== null) { - result4 = []; - result5 = parse_ws(); - while (result5 !== null) { - result4.push(result5); - result5 = parse_ws(); - } - if (result4 !== null) { - result5 = parse_rd(); - if (result5 !== null) { - result0 = [result0, result1, result2, result3, result4, result5]; - } else { - result0 = null; - pos = clone(pos1); - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + + return s0; + } + + function peg$parseend_tag() { + var s0, s1, s2, s3, s4, s5, s6; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 47) { + s2 = peg$c8; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c9); } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parsews(); + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + if (s3 !== peg$FAILED) { + s4 = peg$parseidentifier(); + if (s4 !== peg$FAILED) { + s5 = []; + s6 = peg$parsews(); + while (s6 !== peg$FAILED) { + s5.push(s6); + s6 = peg$parsews(); + } + if (s5 !== peg$FAILED) { + s6 = peg$parserd(); + if (s6 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c15(s4); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n) { return n })(pos0.offset, pos0.line, pos0.column, result0[3]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("end tag"); - } - return result0; - } - - function parse_context() { - var result0, result1; - var pos0, pos1, pos2; - - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - if (input.charCodeAt(pos.offset) === 58) { - result0 = ":"; - advance(pos, 1); + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c14); } + } + + return s0; + } + + function peg$parsecontext() { + var s0, s1, s2, s3; + + s0 = peg$currPos; + s1 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 58) { + s2 = peg$c16; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c17); } + } + if (s2 !== peg$FAILED) { + s3 = peg$parseidentifier(); + if (s3 !== peg$FAILED) { + peg$reportedPos = s1; + s2 = peg$c18(s3); + s1 = s2; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\":\""); - } + peg$currPos = s1; + s1 = peg$c3; } - if (result0 !== null) { - result1 = parse_identifier(); - if (result1 !== null) { - result0 = [result0, result1]; + } else { + peg$currPos = s1; + s1 = peg$c3; + } + if (s1 === peg$FAILED) { + s1 = peg$c4; + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c19(s1); + } + s0 = s1; + + return s0; + } + + function peg$parseparams() { + var s0, s1, s2, s3, s4, s5, s6; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = []; + s4 = peg$parsews(); + if (s4 !== peg$FAILED) { + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + } else { + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 61) { + s5 = peg$c21; + peg$currPos++; } else { - result0 = null; - pos = clone(pos2); - } - } else { - result0 = null; - pos = clone(pos2); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n) {return n})(pos1.offset, pos1.line, pos1.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos1); - } - result0 = result0 !== null ? result0 : ""; - if (result0 !== null) { - result0 = (function(offset, line, column, n) { return n ? ["context", n] : ["context"] })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_params() { - var result0, result1, result2, result3, result4; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - result0 = []; - pos1 = clone(pos); - pos2 = clone(pos); - result2 = parse_ws(); - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - } else { - result1 = null; - } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - if (input.charCodeAt(pos.offset) === 61) { - result3 = "="; - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("\"=\""); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c22); } + } + if (s5 !== peg$FAILED) { + s6 = peg$parsenumber(); + if (s6 === peg$FAILED) { + s6 = peg$parseidentifier(); + if (s6 === peg$FAILED) { + s6 = peg$parseinline(); } } - if (result3 !== null) { - result4 = parse_number(); - if (result4 === null) { - result4 = parse_identifier(); - if (result4 === null) { - result4 = parse_inline(); - } - } - if (result4 !== null) { - result1 = [result1, result2, result3, result4]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s6 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s4, s6); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[1], result1[3]); - } - if (result1 === null) { - pos = clone(pos1); - } - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - result2 = parse_ws(); - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - } else { - result1 = null; - } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - if (input.charCodeAt(pos.offset) === 61) { - result3 = "="; - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("\"=\""); + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = []; + s4 = peg$parsews(); + if (s4 !== peg$FAILED) { + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + } else { + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 61) { + s5 = peg$c21; + peg$currPos++; + } else { + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c22); } + } + if (s5 !== peg$FAILED) { + s6 = peg$parsenumber(); + if (s6 === peg$FAILED) { + s6 = peg$parseidentifier(); + if (s6 === peg$FAILED) { + s6 = peg$parseinline(); } } - if (result3 !== null) { - result4 = parse_number(); - if (result4 === null) { - result4 = parse_identifier(); - if (result4 === null) { - result4 = parse_inline(); - } - } - if (result4 !== null) { - result1 = [result1, result2, result3, result4]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s6 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s4, s6); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[1], result1[3]); - } - if (result1 === null) { - pos = clone(pos1); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["params"].concat(p) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("params"); - } - return result0; - } - - function parse_bodies() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - result0 = []; - pos1 = clone(pos); - pos2 = clone(pos); - result1 = parse_ld(); - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 58) { - result2 = ":"; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\":\""); - } + peg$currPos = s2; + s2 = peg$c3; } - if (result2 !== null) { - result3 = parse_key(); - if (result3 !== null) { - result4 = parse_rd(); - if (result4 !== null) { - result5 = parse_body(); - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c24(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c20); } + } + + return s0; + } + + function peg$parsebodies() { + var s0, s1, s2, s3, s4, s5, s6, s7; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = peg$parseld(); + if (s3 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 58) { + s4 = peg$c16; + peg$currPos++; + } else { + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c17); } + } + if (s4 !== peg$FAILED) { + s5 = peg$parsekey(); + if (s5 !== peg$FAILED) { + s6 = peg$parserd(); + if (s6 !== peg$FAILED) { + s7 = peg$parsebody(); + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s5, s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[2], result1[4]); - } - if (result1 === null) { - pos = clone(pos1); - } - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - result1 = parse_ld(); - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 58) { - result2 = ":"; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\":\""); - } - } - if (result2 !== null) { - result3 = parse_key(); - if (result3 !== null) { - result4 = parse_rd(); - if (result4 !== null) { - result5 = parse_body(); - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = peg$parseld(); + if (s3 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 58) { + s4 = peg$c16; + peg$currPos++; + } else { + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c17); } + } + if (s4 !== peg$FAILED) { + s5 = peg$parsekey(); + if (s5 !== peg$FAILED) { + s6 = peg$parserd(); + if (s6 !== peg$FAILED) { + s7 = peg$parsebody(); + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s5, s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[2], result1[4]); - } - if (result1 === null) { - pos = clone(pos1); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["bodies"].concat(p) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("bodies"); - } - return result0; - } - - function parse_reference() { - var result0, result1, result2, result3; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - result1 = parse_identifier(); - if (result1 !== null) { - result2 = parse_filters(); - if (result2 !== null) { - result3 = parse_rd(); - if (result3 !== null) { - result0 = [result0, result1, result2, result3]; - } else { - result0 = null; - pos = clone(pos1); - } + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c26(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c25); } + } + + return s0; + } + + function peg$parsereference() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + s2 = peg$parseidentifier(); + if (s2 !== peg$FAILED) { + s3 = peg$parsefilters(); + if (s3 !== peg$FAILED) { + s4 = peg$parserd(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c28(s2, s3); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n, f) { return ["reference", n, f].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1], result0[2]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("reference"); - } - return result0; - } - - function parse_partial() { - var result0, result1, result2, result3, result4, result5, result6, result7, result8; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 62) { - result1 = ">"; - advance(pos, 1); + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c27); } + } + + return s0; + } + + function peg$parsepartial() { + var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 62) { + s2 = peg$c30; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c31); } + } + if (s2 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 43) { + s2 = peg$c32; + peg$currPos++; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\">\""); - } - } - if (result1 === null) { - if (input.charCodeAt(pos.offset) === 43) { - result1 = "+"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"+\""); - } - } - } - if (result1 !== null) { - result2 = []; - result3 = parse_ws(); - while (result3 !== null) { - result2.push(result3); - result3 = parse_ws(); - } - if (result2 !== null) { - pos2 = clone(pos); - result3 = parse_key(); - if (result3 !== null) { - result3 = (function(offset, line, column, k) {return ["literal", k]})(pos2.offset, pos2.line, pos2.column, result3); - } - if (result3 === null) { - pos = clone(pos2); - } - if (result3 === null) { - result3 = parse_inline(); - } - if (result3 !== null) { - result4 = parse_context(); - if (result4 !== null) { - result5 = parse_params(); - if (result5 !== null) { - result6 = []; - result7 = parse_ws(); - while (result7 !== null) { - result6.push(result7); - result7 = parse_ws(); + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c33); } + } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parsews(); + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + if (s3 !== peg$FAILED) { + s4 = peg$currPos; + s5 = peg$parsekey(); + if (s5 !== peg$FAILED) { + peg$reportedPos = s4; + s5 = peg$c34(s5); + } + s4 = s5; + if (s4 === peg$FAILED) { + s4 = peg$parseinline(); + } + if (s4 !== peg$FAILED) { + s5 = peg$parsecontext(); + if (s5 !== peg$FAILED) { + s6 = peg$parseparams(); + if (s6 !== peg$FAILED) { + s7 = []; + s8 = peg$parsews(); + while (s8 !== peg$FAILED) { + s7.push(s8); + s8 = peg$parsews(); + } + if (s7 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 47) { + s8 = peg$c8; + peg$currPos++; + } else { + s8 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c9); } } - if (result6 !== null) { - if (input.charCodeAt(pos.offset) === 47) { - result7 = "/"; - advance(pos, 1); - } else { - result7 = null; - if (reportFailures === 0) { - matchFailed("\"/\""); - } - } - if (result7 !== null) { - result8 = parse_rd(); - if (result8 !== null) { - result0 = [result0, result1, result2, result3, result4, result5, result6, result7, result8]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s8 !== peg$FAILED) { + s9 = peg$parserd(); + if (s9 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c35(s2, s4, s5, s6); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, s, n, c, p) { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1], result0[3], result0[4], result0[5]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("partial"); - } - return result0; - } - - function parse_filters() { - var result0, result1, result2; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - result0 = []; - pos1 = clone(pos); - pos2 = clone(pos); - if (input.charCodeAt(pos.offset) === 124) { - result1 = "|"; - advance(pos, 1); + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c29); } + } + + return s0; + } + + function peg$parsefilters() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 124) { + s3 = peg$c37; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c38); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c18(s4); + s2 = s3; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"|\""); - } + peg$currPos = s2; + s2 = peg$c3; } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos2); - } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 124) { + s3 = peg$c37; + peg$currPos++; } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, n) {return n})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); - } - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - if (input.charCodeAt(pos.offset) === 124) { - result1 = "|"; - advance(pos, 1); + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c38); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c18(s4); + s2 = s3; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"|\""); - } + peg$currPos = s2; + s2 = peg$c3; } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos2); - } - } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, n) {return n})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column, f) { return ["filters"].concat(f) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("filters"); + } else { + peg$currPos = s2; + s2 = peg$c3; } - return result0; } - - function parse_special() { - var result0, result1, result2, result3; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 126) { - result1 = "~"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"~\""); - } - } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result3 = parse_rd(); - if (result3 !== null) { - result0 = [result0, result1, result2, result3]; - } else { - result0 = null; - pos = clone(pos1); - } - } else { - result0 = null; - pos = clone(pos1); - } - } else { - result0 = null; - pos = clone(pos1); - } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c39(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c36); } + } + + return s0; + } + + function peg$parsespecial() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 126) { + s2 = peg$c41; + peg$currPos++; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, k) { return ["special", k].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[2]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("special"); - } - return result0; - } - - function parse_identifier() { - var result0; - var pos0; - - reportFailures++; - pos0 = clone(pos); - result0 = parse_path(); - if (result0 !== null) { - result0 = (function(offset, line, column, p) { var arr = ["path"].concat(p); arr.text = p[1].join('.'); return arr; })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - result0 = parse_key(); - if (result0 !== null) { - result0 = (function(offset, line, column, k) { var arr = ["key", k]; arr.text = k; return arr; })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("identifier"); - } - return result0; - } - - function parse_number() { - var result0; - var pos0; - - reportFailures++; - pos0 = clone(pos); - result0 = parse_float(); - if (result0 === null) { - result0 = parse_integer(); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n) { return ['literal', n]; })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("number"); - } - return result0; - } - - function parse_float() { - var result0, result1, result2, result3; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_integer(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 46) { - result1 = "."; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } - } - if (result1 !== null) { - result3 = parse_integer(); - if (result3 !== null) { - result2 = []; - while (result3 !== null) { - result2.push(result3); - result3 = parse_integer(); - } - } else { - result2 = null; - } - if (result2 !== null) { - result0 = [result0, result1, result2]; + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c42); } + } + if (s2 !== peg$FAILED) { + s3 = peg$parsekey(); + if (s3 !== peg$FAILED) { + s4 = peg$parserd(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c43(s3); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, l, r) { return parseFloat(l + "." + r.join('')); })(pos0.offset, pos0.line, pos0.column, result0[0], result0[2]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("float"); - } - return result0; - } - - function parse_integer() { - var result0, result1; - var pos0; - - reportFailures++; - pos0 = clone(pos); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result1 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result1 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c40); } + } + + return s0; + } + + function peg$parseidentifier() { + var s0, s1; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsepath(); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c45(s1); + } + s0 = s1; + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = peg$parsekey(); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c46(s1); + } + s0 = s1; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c44); } + } + + return s0; + } + + function peg$parsenumber() { + var s0, s1; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsefloat(); + if (s1 === peg$FAILED) { + s1 = peg$parseinteger(); + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c48(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c47); } + } + + return s0; + } + + function peg$parsefloat() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseinteger(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 46) { + s2 = peg$c50; + peg$currPos++; } else { - result0 = null; - } - if (result0 !== null) { - result0 = (function(offset, line, column, digits) { return parseInt(digits.join(""), 10); })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("integer"); - } - return result0; - } - - function parse_path() { - var result0, result1, result2; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_key(); - result0 = result0 !== null ? result0 : ""; - if (result0 !== null) { - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parseinteger(); + if (s4 !== peg$FAILED) { + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parseinteger(); } } else { - result1 = null; + s3 = peg$c3; } - if (result1 !== null) { - result0 = [result0, result1]; + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c52(s1, s3); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, k, d) { - d = d[0]; - if (k && d) { - d.unshift(k); - return [false, d].concat([['line', line], ['col', column]]); - } - return [true, d].concat([['line', line], ['col', column]]); - })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 46) { - result0 = "."; - advance(pos, 1); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c49); } + } + + return s0; + } + + function peg$parseinteger() { + var s0, s1, s2; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + if (peg$c54.test(input.charAt(peg$currPos))) { + s2 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + if (peg$c54.test(input.charAt(peg$currPos))) { + s2 = input.charAt(peg$currPos); + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } } - if (result0 !== null) { - result1 = []; - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - while (result2 !== null) { - result1.push(result2); - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - } - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); + } + } else { + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c56(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c53); } + } + + return s0; + } + + function peg$parsepath() { + var s0, s1, s2, s3; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsekey(); + if (s1 === peg$FAILED) { + s1 = peg$c4; + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); + } + if (s3 !== peg$FAILED) { + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); } - } else { - result0 = null; - pos = clone(pos1); } - if (result0 !== null) { - result0 = (function(offset, line, column, d) { - if (d.length > 0) { - return [true, d[0]].concat([['line', line], ['col', column]]); - } - return [true, []].concat([['line', line], ['col', column]]); - })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("path"); - } - return result0; - } - - function parse_key() { - var result0, result1, result2; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (/^[a-zA-Z_$]/.test(input.charAt(pos.offset))) { - result0 = input.charAt(pos.offset); - advance(pos, 1); } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("[a-zA-Z_$]"); - } + s2 = peg$c3; } - if (result0 !== null) { - result1 = []; - if (/^[0-9a-zA-Z_$\-]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9a-zA-Z_$\\-]"); - } - } - while (result2 !== null) { - result1.push(result2); - if (/^[0-9a-zA-Z_$\-]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9a-zA-Z_$\\-]"); - } - } - } - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c58(s1, s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, h, t) { return h + t.join('') })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("key"); - } - return result0; - } - - function parse_array() { - var result0, result1, result2; - var pos0, pos1, pos2, pos3, pos4; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - result0 = parse_lb(); - if (result0 !== null) { - pos4 = clone(pos); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - } - } else { - result1 = null; - } - if (result1 !== null) { - result1 = (function(offset, line, column, n) {return n.join('')})(pos4.offset, pos4.line, pos4.column, result1); - } - if (result1 === null) { - pos = clone(pos4); - } - if (result1 === null) { - result1 = parse_identifier(); - } - if (result1 !== null) { - result2 = parse_rb(); - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos3); - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 46) { + s1 = peg$c50; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); + } + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); + } + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c59(s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos3); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos3); - } - if (result0 !== null) { - result0 = (function(offset, line, column, a) {return a; })(pos2.offset, pos2.line, pos2.column, result0[1]); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - pos = clone(pos2); - } - if (result0 !== null) { - result1 = parse_array_part(); - result1 = result1 !== null ? result1 : ""; - if (result1 !== null) { - result0 = [result0, result1]; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c57); } + } + + return s0; + } + + function peg$parsekey() { + var s0, s1, s2, s3; + + peg$silentFails++; + s0 = peg$currPos; + if (peg$c61.test(input.charAt(peg$currPos))) { + s1 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c62); } + } + if (s1 !== peg$FAILED) { + s2 = []; + if (peg$c63.test(input.charAt(peg$currPos))) { + s3 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c64); } + } + while (s3 !== peg$FAILED) { + s2.push(s3); + if (peg$c63.test(input.charAt(peg$currPos))) { + s3 = input.charAt(peg$currPos); + peg$currPos++; } else { - result0 = null; - pos = clone(pos1); + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c64); } } + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c65(s1, s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, i, nk) { if(nk) { nk.unshift(i); } else {nk = [i] } return nk; })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("array"); - } - return result0; - } - - function parse_array_part() { - var result0, result1, result2; - var pos0, pos1, pos2, pos3; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - if (input.charCodeAt(pos.offset) === 46) { - result1 = "."; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } + peg$currPos = s0; + s0 = peg$c3; } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos3); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c60); } + } + + return s0; + } + + function peg$parsearray() { + var s0, s1, s2, s3, s4, s5; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$currPos; + s2 = peg$parselb(); + if (s2 !== peg$FAILED) { + s3 = peg$currPos; + s4 = []; + if (peg$c54.test(input.charAt(peg$currPos))) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k) {return k})(pos2.offset, pos2.line, pos2.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos2); - } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - pos2 = clone(pos); - pos3 = clone(pos); - if (input.charCodeAt(pos.offset) === 46) { - result1 = "."; - advance(pos, 1); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } + } + if (s5 !== peg$FAILED) { + while (s5 !== peg$FAILED) { + s4.push(s5); + if (peg$c54.test(input.charAt(peg$currPos))) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } - } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos3); - } - } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k) {return k})(pos2.offset, pos2.line, pos2.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos2); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } } } } else { - result0 = null; - } - if (result0 !== null) { - result1 = parse_array(); - result1 = result1 !== null ? result1 : ""; - if (result1 !== null) { - result0 = [result0, result1]; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c67(s4); + } + s3 = s4; + if (s3 === peg$FAILED) { + s3 = peg$parseidentifier(); + } + if (s3 !== peg$FAILED) { + s4 = peg$parserb(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s1; + s2 = peg$c68(s3); + s1 = s2; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s1; + s1 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, d, a) { if (a) { return d.concat(a); } else { return d; } })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("array_part"); - } - return result0; - } - - function parse_inline() { - var result0, result1, result2; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 34) { - result0 = "\""; - advance(pos, 1); + peg$currPos = s1; + s1 = peg$c3; + } + } else { + peg$currPos = s1; + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + s2 = peg$parsearray_part(); + if (s2 === peg$FAILED) { + s2 = peg$c4; + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c69(s1, s2); + s0 = s1; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c66); } + } + + return s0; + } + + function peg$parsearray_part() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 46) { + s3 = peg$c50; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c71(s4); + s2 = s3; + } else { + peg$currPos = s2; + s2 = peg$c3; } - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 34) { - result1 = "\""; - advance(pos, 1); + } else { + peg$currPos = s2; + s2 = peg$c3; + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 46) { + s3 = peg$c50; + peg$currPos++; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c71(s4); + s2 = s3; + } else { + peg$currPos = s2; + s2 = peg$c3; } - } - if (result1 !== null) { - result0 = [result0, result1]; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s2; + s2 = peg$c3; } + } + } else { + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + s2 = peg$parsearray(); + if (s2 === peg$FAILED) { + s2 = peg$c4; + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c72(s1, s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column) { return ["literal", ""].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c70); } + } + + return s0; + } + + function peg$parseinline() { + var s0, s1, s2, s3; + + peg$silentFails++; + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 34) { + s1 = peg$c74; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } + } + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 34) { + s2 = peg$c74; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } } - if (result0 === null) { - pos = clone(pos0); + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c76(); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 34) { - result0 = "\""; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 34) { + s1 = peg$c74; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } + } + if (s1 !== peg$FAILED) { + s2 = peg$parseliteral(); + if (s2 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 34) { + s3 = peg$c74; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } } - } - if (result0 !== null) { - result1 = parse_literal(); - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 34) { - result2 = "\""; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } - } - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c77(s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, l) { return ["literal", l].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 34) { - result0 = "\""; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 34) { + s1 = peg$c74; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parseinline_part(); + if (s3 !== peg$FAILED) { + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parseinline_part(); } + } else { + s2 = peg$c3; } - if (result0 !== null) { - result2 = parse_inline_part(); - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_inline_part(); - } + if (s2 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 34) { + s3 = peg$c74; + peg$currPos++; } else { - result1 = null; + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } } - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 34) { - result2 = "\""; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } - } - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c1(s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["body"].concat(p).concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } + } else { + peg$currPos = s0; + s0 = peg$c3; } } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("inline"); - } - return result0; - } - - function parse_inline_part() { - var result0; - var pos0; - - result0 = parse_special(); - if (result0 === null) { - result0 = parse_reference(); - if (result0 === null) { - pos0 = clone(pos); - result0 = parse_literal(); - if (result0 !== null) { - result0 = (function(offset, line, column, l) { return ["buffer", l] })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - } + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c73); } + } + + return s0; + } + + function peg$parseinline_part() { + var s0, s1; + + s0 = peg$parsespecial(); + if (s0 === peg$FAILED) { + s0 = peg$parsereference(); + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = peg$parseliteral(); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c78(s1); + } + s0 = s1; + } + } + + return s0; + } + + function peg$parsebuffer() { + var s0, s1, s2, s3, s4, s5, s6, s7; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseeol(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c80(s1, s2); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } - return result0; - } - - function parse_buffer() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1, pos2, pos3; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_eol(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, e, w) { return ["format", e, w.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$currPos; + peg$silentFails++; + s5 = peg$parseraw(); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - pos3 = clone(pos); - reportFailures++; - result2 = parse_raw(); - reportFailures--; - if (result2 === null) { - result2 = ""; + peg$currPos = s4; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + s5 = peg$currPos; + peg$silentFails++; + s6 = peg$parsecomment(); + peg$silentFails--; + if (s6 === peg$FAILED) { + s5 = peg$c6; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - pos3 = clone(pos); - reportFailures++; - result3 = parse_comment(); - reportFailures--; - if (result3 === null) { - result3 = ""; + peg$currPos = s5; + s5 = peg$c3; + } + if (s5 !== peg$FAILED) { + s6 = peg$currPos; + peg$silentFails++; + s7 = peg$parseeol(); + peg$silentFails--; + if (s7 === peg$FAILED) { + s6 = peg$c6; } else { - result3 = null; - pos = clone(pos3); + peg$currPos = s6; + s6 = peg$c3; } - if (result3 !== null) { - pos3 = clone(pos); - reportFailures++; - result4 = parse_eol(); - reportFailures--; - if (result4 === null) { - result4 = ""; + if (s6 !== peg$FAILED) { + if (input.length > peg$currPos) { + s7 = input.charAt(peg$currPos); + peg$currPos++; } else { - result4 = null; - pos = clone(pos3); + s7 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result4 !== null) { - if (input.length > pos.offset) { - result5 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result5 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c82(s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[4]); - } - if (result1 === null) { - pos = clone(pos1); - } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$currPos; + peg$silentFails++; + s5 = peg$parseraw(); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result1 = null; - pos = clone(pos3); + peg$currPos = s4; + s4 = peg$c3; } - if (result1 !== null) { - pos3 = clone(pos); - reportFailures++; - result2 = parse_raw(); - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s4 !== peg$FAILED) { + s5 = peg$currPos; + peg$silentFails++; + s6 = peg$parsecomment(); + peg$silentFails--; + if (s6 === peg$FAILED) { + s5 = peg$c6; } else { - result2 = null; - pos = clone(pos3); + peg$currPos = s5; + s5 = peg$c3; } - if (result2 !== null) { - pos3 = clone(pos); - reportFailures++; - result3 = parse_comment(); - reportFailures--; - if (result3 === null) { - result3 = ""; + if (s5 !== peg$FAILED) { + s6 = peg$currPos; + peg$silentFails++; + s7 = peg$parseeol(); + peg$silentFails--; + if (s7 === peg$FAILED) { + s6 = peg$c6; } else { - result3 = null; - pos = clone(pos3); + peg$currPos = s6; + s6 = peg$c3; } - if (result3 !== null) { - pos3 = clone(pos); - reportFailures++; - result4 = parse_eol(); - reportFailures--; - if (result4 === null) { - result4 = ""; + if (s6 !== peg$FAILED) { + if (input.length > peg$currPos) { + s7 = input.charAt(peg$currPos); + peg$currPos++; } else { - result4 = null; - pos = clone(pos3); + s7 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result4 !== null) { - if (input.length > pos.offset) { - result5 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result5 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c82(s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[4]); + peg$currPos = s2; + s2 = peg$c3; } - if (result1 === null) { - pos = clone(pos1); - } - } - } else { - result0 = null; - } - if (result0 !== null) { - result0 = (function(offset, line, column, b) { return ["buffer", b.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("buffer"); - } - return result0; - } - - function parse_literal() { - var result0, result1, result2; - var pos0, pos1, pos2, pos3; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; - } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result2 = parse_esc(); - if (result2 === null) { - if (/^[^"]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[^\"]"); - } + peg$currPos = s2; + s2 = peg$c3; } } - if (result2 !== null) { - result1 = [result1, result2]; + } else { + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c83(s1); + } + s0 = s1; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c79); } + } + + return s0; + } + + function peg$parseliteral() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parseesc(); + if (s4 === peg$FAILED) { + if (peg$c85.test(input.charAt(peg$currPos))) { + s4 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - pos = clone(pos2); + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c86); } } + } + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c82(s4); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); - } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; - } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result2 = parse_esc(); - if (result2 === null) { - if (/^[^"]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[^\"]"); - } - } - } - if (result2 !== null) { - result1 = [result1, result2]; + peg$currPos = s2; + s2 = peg$c3; + } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parseesc(); + if (s4 === peg$FAILED) { + if (peg$c85.test(input.charAt(peg$currPos))) { + s4 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - pos = clone(pos2); + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c86); } } - } else { - result1 = null; - pos = clone(pos2); } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c82(s4); + s2 = s3; + } else { + peg$currPos = s2; + s2 = peg$c3; } + } else { + peg$currPos = s2; + s2 = peg$c3; } - } else { - result0 = null; } - if (result0 !== null) { - result0 = (function(offset, line, column, b) { return b.join('') })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("literal"); - } - return result0; + } else { + s1 = peg$c3; } - - function parse_esc() { - var result0; - var pos0; - - pos0 = clone(pos); - if (input.substr(pos.offset, 2) === "\\\"") { - result0 = "\\\""; - advance(pos, 2); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c87(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c84); } + } + + return s0; + } + + function peg$parseesc() { + var s0, s1; + + s0 = peg$currPos; + if (input.substr(peg$currPos, 2) === peg$c88) { + s1 = peg$c88; + peg$currPos += 2; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c89); } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c90(); + } + s0 = s1; + + return s0; + } + + function peg$parseraw() { + var s0, s1, s2, s3, s4, s5; + + peg$silentFails++; + s0 = peg$currPos; + if (input.substr(peg$currPos, 2) === peg$c92) { + s1 = peg$c92; + peg$currPos += 2; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c93); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c94) { + s5 = peg$c94; + peg$currPos += 2; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\\\\\"\""); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column) { return '"' })(pos0.offset, pos0.line, pos0.column); - } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_raw() { - var result0, result1, result2, result3; - var pos0, pos1, pos2, pos3, pos4; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (input.substr(pos.offset, 2) === "{`") { - result0 = "{`"; - advance(pos, 2); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c95); } + } + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"{`\""); - } - } - if (result0 !== null) { - result1 = []; - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "`}") { - result2 = "`}"; - advance(pos, 2); + peg$currPos = s4; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"`}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c96(s5); + s3 = s4; } else { - result2 = null; - pos = clone(pos4); + peg$currPos = s3; + s3 = peg$c3; } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } + } else { + peg$currPos = s3; + s3 = peg$c3; + } + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c94) { + s5 = peg$c94; + peg$currPos += 2; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, char) {return char})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); - } - while (result2 !== null) { - result1.push(result2); - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "`}") { - result2 = "`}"; - advance(pos, 2); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"`}\""); - } - } - reportFailures--; - if (result2 === null) { - result2 = ""; - } else { - result2 = null; - pos = clone(pos4); - } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } - } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, char) {return char})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c95); } + } + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; + } else { + peg$currPos = s4; + s4 = peg$c3; } - if (result1 !== null) { - if (input.substr(pos.offset, 2) === "`}") { - result2 = "`}"; - advance(pos, 2); + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"`}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result2 !== null) { - result0 = [result0, result1, result2]; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c96(s5); + s3 = s4; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s3; + s3 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s3; + s3 = peg$c3; + } + } + if (s2 !== peg$FAILED) { + if (input.substr(peg$currPos, 2) === peg$c94) { + s3 = peg$c94; + peg$currPos += 2; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c95); } } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c97(s2); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c91); } + } + + return s0; + } + + function peg$parsecomment() { + var s0, s1, s2, s3, s4, s5; + + peg$silentFails++; + s0 = peg$currPos; + if (input.substr(peg$currPos, 2) === peg$c99) { + s1 = peg$c99; + peg$currPos += 2; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c100); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c101) { + s5 = peg$c101; + peg$currPos += 2; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, rawText) { return ["raw", rawText.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("raw"); - } - return result0; - } - - function parse_comment() { - var result0, result1, result2, result3; - var pos0, pos1, pos2, pos3, pos4; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (input.substr(pos.offset, 2) === "{!") { - result0 = "{!"; - advance(pos, 2); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c102); } + } + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"{!\""); - } - } - if (result0 !== null) { - result1 = []; - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "!}") { - result2 = "!}"; - advance(pos, 2); + peg$currPos = s4; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"!}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c82(s5); + s3 = s4; } else { - result2 = null; - pos = clone(pos4); + peg$currPos = s3; + s3 = peg$c3; } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } + } else { + peg$currPos = s3; + s3 = peg$c3; + } + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c101) { + s5 = peg$c101; + peg$currPos += 2; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, c) {return c})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); - } - while (result2 !== null) { - result1.push(result2); - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "!}") { - result2 = "!}"; - advance(pos, 2); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"!}\""); - } - } - reportFailures--; - if (result2 === null) { - result2 = ""; - } else { - result2 = null; - pos = clone(pos4); - } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } - } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, c) {return c})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c102); } } - if (result1 !== null) { - if (input.substr(pos.offset, 2) === "!}") { - result2 = "!}"; - advance(pos, 2); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; + } else { + peg$currPos = s4; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"!}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result2 !== null) { - result0 = [result0, result1, result2]; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c82(s5); + s3 = s4; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s3; + s3 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s3; + s3 = peg$c3; + } + } + if (s2 !== peg$FAILED) { + if (input.substr(peg$currPos, 2) === peg$c101) { + s3 = peg$c101; + peg$currPos += 2; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c102); } + } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c103(s2); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, c) { return ["comment", c.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("comment"); - } - return result0; - } - - function parse_tag() { - var result0, result1, result2, result3, result4, result5, result6, result7; - var pos0, pos1, pos2; - - pos0 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - if (/^[#?^><+%:@\/~%]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[#?^><+%:@\\/~%]"); - } - } - if (result2 !== null) { - result3 = []; - result4 = parse_ws(); - while (result4 !== null) { - result3.push(result4); - result4 = parse_ws(); + peg$currPos = s0; + s0 = peg$c3; + } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c98); } + } + + return s0; + } + + function peg$parsetag() { + var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9; + + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + if (peg$c104.test(input.charAt(peg$currPos))) { + s3 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c105); } + } + if (s3 !== peg$FAILED) { + s4 = []; + s5 = peg$parsews(); + while (s5 !== peg$FAILED) { + s4.push(s5); + s5 = peg$parsews(); + } + if (s4 !== peg$FAILED) { + s5 = []; + s6 = peg$currPos; + s7 = peg$currPos; + peg$silentFails++; + s8 = peg$parserd(); + peg$silentFails--; + if (s8 === peg$FAILED) { + s7 = peg$c6; + } else { + peg$currPos = s7; + s7 = peg$c3; } - if (result3 !== null) { - pos1 = clone(pos); - pos2 = clone(pos); - reportFailures++; - result5 = parse_rd(); - reportFailures--; - if (result5 === null) { - result5 = ""; + if (s7 !== peg$FAILED) { + s8 = peg$currPos; + peg$silentFails++; + s9 = peg$parseeol(); + peg$silentFails--; + if (s9 === peg$FAILED) { + s8 = peg$c6; } else { - result5 = null; - pos = clone(pos2); + peg$currPos = s8; + s8 = peg$c3; } - if (result5 !== null) { - pos2 = clone(pos); - reportFailures++; - result6 = parse_eol(); - reportFailures--; - if (result6 === null) { - result6 = ""; + if (s8 !== peg$FAILED) { + if (input.length > peg$currPos) { + s9 = input.charAt(peg$currPos); + peg$currPos++; } else { - result6 = null; - pos = clone(pos2); + s9 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result6 !== null) { - if (input.length > pos.offset) { - result7 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result7 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result7 !== null) { - result5 = [result5, result6, result7]; - } else { - result5 = null; - pos = clone(pos1); - } + if (s9 !== peg$FAILED) { + s7 = [s7, s8, s9]; + s6 = s7; } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } - if (result5 !== null) { - result4 = []; - while (result5 !== null) { - result4.push(result5); - pos1 = clone(pos); - pos2 = clone(pos); - reportFailures++; - result5 = parse_rd(); - reportFailures--; - if (result5 === null) { - result5 = ""; + } else { + peg$currPos = s6; + s6 = peg$c3; + } + if (s6 !== peg$FAILED) { + while (s6 !== peg$FAILED) { + s5.push(s6); + s6 = peg$currPos; + s7 = peg$currPos; + peg$silentFails++; + s8 = peg$parserd(); + peg$silentFails--; + if (s8 === peg$FAILED) { + s7 = peg$c6; + } else { + peg$currPos = s7; + s7 = peg$c3; + } + if (s7 !== peg$FAILED) { + s8 = peg$currPos; + peg$silentFails++; + s9 = peg$parseeol(); + peg$silentFails--; + if (s9 === peg$FAILED) { + s8 = peg$c6; } else { - result5 = null; - pos = clone(pos2); + peg$currPos = s8; + s8 = peg$c3; } - if (result5 !== null) { - pos2 = clone(pos); - reportFailures++; - result6 = parse_eol(); - reportFailures--; - if (result6 === null) { - result6 = ""; + if (s8 !== peg$FAILED) { + if (input.length > peg$currPos) { + s9 = input.charAt(peg$currPos); + peg$currPos++; } else { - result6 = null; - pos = clone(pos2); + s9 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c81); } } - if (result6 !== null) { - if (input.length > pos.offset) { - result7 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result7 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result7 !== null) { - result5 = [result5, result6, result7]; - } else { - result5 = null; - pos = clone(pos1); - } + if (s9 !== peg$FAILED) { + s7 = [s7, s8, s9]; + s6 = s7; } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } + } else { + peg$currPos = s6; + s6 = peg$c3; } - } else { - result4 = null; } - if (result4 !== null) { - result5 = []; - result6 = parse_ws(); - while (result6 !== null) { - result5.push(result6); - result6 = parse_ws(); - } - if (result5 !== null) { - result6 = parse_rd(); - if (result6 !== null) { - result0 = [result0, result1, result2, result3, result4, result5, result6]; - } else { - result0 = null; - pos = clone(pos0); - } + } else { + s5 = peg$c3; + } + if (s5 !== peg$FAILED) { + s6 = []; + s7 = peg$parsews(); + while (s7 !== peg$FAILED) { + s6.push(s7); + s7 = peg$parsews(); + } + if (s6 !== peg$FAILED) { + s7 = peg$parserd(); + if (s7 !== peg$FAILED) { + s1 = [s1, s2, s3, s4, s5, s6, s7]; + s0 = s1; } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - result0 = parse_reference(); - } - return result0; + } else { + peg$currPos = s0; + s0 = peg$c3; } - - function parse_ld() { - var result0; - - if (input.charCodeAt(pos.offset) === 123) { - result0 = "{"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"{\""); - } - } - return result0; + if (s0 === peg$FAILED) { + s0 = peg$parsereference(); } - - function parse_rd() { - var result0; - - if (input.charCodeAt(pos.offset) === 125) { - result0 = "}"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"}\""); - } - } - return result0; + + return s0; + } + + function peg$parseld() { + var s0; + + if (input.charCodeAt(peg$currPos) === 123) { + s0 = peg$c106; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c107); } } - - function parse_lb() { - var result0; - - if (input.charCodeAt(pos.offset) === 91) { - result0 = "["; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"[\""); - } - } - return result0; + + return s0; + } + + function peg$parserd() { + var s0; + + if (input.charCodeAt(peg$currPos) === 125) { + s0 = peg$c108; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c109); } } - - function parse_rb() { - var result0; - - if (input.charCodeAt(pos.offset) === 93) { - result0 = "]"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"]\""); - } - } - return result0; + + return s0; + } + + function peg$parselb() { + var s0; + + if (input.charCodeAt(peg$currPos) === 91) { + s0 = peg$c110; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c111); } + } + + return s0; + } + + function peg$parserb() { + var s0; + + if (input.charCodeAt(peg$currPos) === 93) { + s0 = peg$c112; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c113); } + } + + return s0; + } + + function peg$parseeol() { + var s0; + + if (input.charCodeAt(peg$currPos) === 10) { + s0 = peg$c114; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c115); } } - - function parse_eol() { - var result0; - - if (input.charCodeAt(pos.offset) === 10) { - result0 = "\n"; - advance(pos, 1); + if (s0 === peg$FAILED) { + if (input.substr(peg$currPos, 2) === peg$c116) { + s0 = peg$c116; + peg$currPos += 2; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\n\""); - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c117); } } - if (result0 === null) { - if (input.substr(pos.offset, 2) === "\r\n") { - result0 = "\r\n"; - advance(pos, 2); + if (s0 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 13) { + s0 = peg$c118; + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\r\\n\""); - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c119); } } - if (result0 === null) { - if (input.charCodeAt(pos.offset) === 13) { - result0 = "\r"; - advance(pos, 1); + if (s0 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 8232) { + s0 = peg$c120; + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\r\""); - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c121); } } - if (result0 === null) { - if (input.charCodeAt(pos.offset) === 8232) { - result0 = "\u2028"; - advance(pos, 1); + if (s0 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 8233) { + s0 = peg$c122; + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\u2028\""); - } - } - if (result0 === null) { - if (input.charCodeAt(pos.offset) === 8233) { - result0 = "\u2029"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\u2029\""); - } - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c123); } } } } } - return result0; } - - function parse_ws() { - var result0; - - if (/^[\t\x0B\f \xA0\uFEFF]/.test(input.charAt(pos.offset))) { - result0 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("[\\t\\x0B\\f \\xA0\\uFEFF]"); - } - } - if (result0 === null) { - result0 = parse_eol(); - } - return result0; + + return s0; + } + + function peg$parsews() { + var s0; + + if (peg$c124.test(input.charAt(peg$currPos))) { + s0 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c125); } } - - - function cleanupExpected(expected) { - expected.sort(); - - var lastExpected = null; - var cleanExpected = []; - for (var i = 0; i < expected.length; i++) { - if (expected[i] !== lastExpected) { - cleanExpected.push(expected[i]); - lastExpected = expected[i]; - } - } - return cleanExpected; - } - - - - var result = parseFunctions[startRule](); - - /* - * The parser is now in one of the following three states: - * - * 1. The parser successfully parsed the whole input. - * - * - |result !== null| - * - |pos.offset === input.length| - * - |rightmostFailuresExpected| may or may not contain something - * - * 2. The parser successfully parsed only a part of the input. - * - * - |result !== null| - * - |pos.offset < input.length| - * - |rightmostFailuresExpected| may or may not contain something - * - * 3. The parser did not successfully parse any part of the input. - * - * - |result === null| - * - |pos.offset === 0| - * - |rightmostFailuresExpected| contains at least one failure - * - * All code following this comment (including called functions) must - * handle these states. - */ - if (result === null || pos.offset !== input.length) { - var offset = Math.max(pos.offset, rightmostFailuresPos.offset); - var found = offset < input.length ? input.charAt(offset) : null; - var errorPosition = pos.offset > rightmostFailuresPos.offset ? pos : rightmostFailuresPos; - - throw new parser.SyntaxError( - cleanupExpected(rightmostFailuresExpected), - found, - offset, - errorPosition.line, - errorPosition.column - ); - } - - return result; - }, - - /* Returns the parser source code. */ - toSource: function() { return this._source; } - }; - - /* Thrown when a parser encounters a syntax error. */ - - result.SyntaxError = function(expected, found, offset, line, column) { - function buildMessage(expected, found) { - var expectedHumanized, foundHumanized; - - switch (expected.length) { - case 0: - expectedHumanized = "end of input"; - break; - case 1: - expectedHumanized = expected[0]; - break; - default: - expectedHumanized = expected.slice(0, expected.length - 1).join(", ") - + " or " - + expected[expected.length - 1]; - } - - foundHumanized = found ? quote(found) : "end of input"; - - return "Expected " + expectedHumanized + " but " + foundHumanized + " found."; + if (s0 === peg$FAILED) { + s0 = peg$parseeol(); + } + + return s0; } - - this.name = "SyntaxError"; - this.expected = expected; - this.found = found; - this.message = buildMessage(expected, found); - this.offset = offset; - this.line = line; - this.column = column; + + peg$result = peg$startRuleFunction(); + + if (peg$result !== peg$FAILED && peg$currPos === input.length) { + return peg$result; + } else { + if (peg$result !== peg$FAILED && peg$currPos < input.length) { + peg$fail({ type: "end", description: "end of input" }); + } + + throw peg$buildException(null, peg$maxFailExpected, peg$maxFailPos); + } + } + + return { + SyntaxError: SyntaxError, + parse: parse }; - - result.SyntaxError.prototype = Error.prototype; - - return result; })(); // expose parser methods diff --git a/package.json b/package.json index 122a240b..1ddd398a 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ "views" ], "devDependencies": { - "pegjs": "0.7.0", + "pegjs": "0.8.0", "grunt": "~0.4.2", "grunt-contrib-connect": "~0.5.0", "grunt-template-jasmine-istanbul": "~0.2.5", diff --git a/src/build.js b/src/build.js index 97762a15..f8d8f73b 100644 --- a/src/build.js +++ b/src/build.js @@ -6,7 +6,8 @@ var peg = require('pegjs'), var options = { cache: false, - trackLineAndColumn: true + trackLineAndColumn: true, + output: 'source' }; var parser = peg.buildParser(fs.readFileSync(path.join(root, 'src', 'dust.pegjs'), 'utf8'), options), @@ -16,4 +17,4 @@ var parser = peg.buildParser(fs.readFileSync(path.join(root, 'src', 'dust.pegjs' buildMessage = 'Do not edit the parser directly. This is a generated file created using a build script and the PEG grammar.'; -fs.writeFileSync(path.join(root, 'lib', 'parser.js'), umdWrapper.replace(parserPlaceholder, parser.toSource()).replace(buildMessagePlaceHolder, buildMessage).replace('this.SyntaxError','parser.SyntaxError')); +fs.writeFileSync(path.join(root, 'lib', 'parser.js'), umdWrapper.replace(parserPlaceholder, parser).replace(buildMessagePlaceHolder, buildMessage).replace('this.SyntaxError','parser.SyntaxError')); diff --git a/src/dust.pegjs b/src/dust.pegjs index 65df1d4c..8119a40f 100644 --- a/src/dust.pegjs +++ b/src/dust.pegjs @@ -5,7 +5,7 @@ start body is defined as anything that matches with the part 0 or more times ---------------------------------------------------------------------------------------------------------------------------------------*/ body - = p:part* { return ["body"].concat(p).concat([['line', line], ['col', column]]) } + = p:part* { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- part is defined as anything that matches with raw or comment or section or partial or special or reference or buffer @@ -18,13 +18,13 @@ part plus bodies plus end_tag or sec_tag_start followed by a slash and closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ section "section" - = t:sec_tag_start ws* rd b:body e:bodies n:end_tag? &{if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line+", column : " + column)} return true;} - { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line], ['col', column]]) } + = t:sec_tag_start ws* rd b:body e:bodies n:end_tag? &{if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line()+", column : " + column())} return true;} + { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line()], ['col', column()]]) } / t:sec_tag_start ws* "/" rd - { t.push(["bodies"]); return t.concat([['line', line], ['col', column]]) } + { t.push(["bodies"]); return t.concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- - sec_tag_start is defined as matching an opening brace followed by one of #?^<+@% plus identifier plus context plus param + sec_tag_start is defined as matching an opening brace followed by one of #?^<+@% plus identifier plus context plus param followed by 0 or more white spaces ---------------------------------------------------------------------------------------------------------------------------------------*/ sec_tag_start @@ -32,7 +32,7 @@ sec_tag_start { return [t, n, c, p] } /*------------------------------------------------------------------------------------------------------------------------------------- - end_tag is defined as matching an opening brace followed by a slash plus 0 or more white spaces plus identifier followed + end_tag is defined as matching an opening brace followed by a slash plus 0 or more white spaces plus identifier followed by 0 or more white spaces and ends with closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ end_tag "end tag" @@ -65,15 +65,15 @@ bodies "bodies" ---------------------------------------------------------------------------------------------------------------------------------------*/ reference "reference" = ld n:identifier f:filters rd - { return ["reference", n, f].concat([['line', line], ['col', column]]) } + { return ["reference", n, f].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- - partial is defined as matching a opening brace followed by a > plus anything that matches with key or inline plus + partial is defined as matching a opening brace followed by a > plus anything that matches with key or inline plus context followed by slash and closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ partial "partial" = ld s:(">"/"+") ws* n:(k:key {return ["literal", k]} / inline) c:context p:params ws* "/" rd - { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line], ['col', column]]) } + { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- filters is defined as matching a pipe character followed by anything that matches the key @@ -87,7 +87,7 @@ filters "filters" ---------------------------------------------------------------------------------------------------------------------------------------*/ special "special" = ld "~" k:key rd - { return ["special", k].concat([['line', line], ['col', column]]) } + { return ["special", k].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- identifier is defined as matching a path or key @@ -106,26 +106,26 @@ integer "integer" = digits:[0-9]+ { return parseInt(digits.join(""), 10); } /*------------------------------------------------------------------------------------------------------------------------------------- - path is defined as matching a key plus one or more characters of key preceded by a dot + path is defined as matching a key plus one or more characters of key preceded by a dot ---------------------------------------------------------------------------------------------------------------------------------------*/ path "path" = k:key? d:(array_part / array)+ { d = d[0]; if (k && d) { d.unshift(k); - return [false, d].concat([['line', line], ['col', column]]); + return [false, d].concat([['line', line()], ['col', column()]]); } - return [true, d].concat([['line', line], ['col', column]]); + return [true, d].concat([['line', line()], ['col', column()]]); } / "." d:(array_part / array)* { if (d.length > 0) { - return [true, d[0]].concat([['line', line], ['col', column]]); + return [true, d[0]].concat([['line', line()], ['col', column()]]); } - return [true, []].concat([['line', line], ['col', column]]); + return [true, []].concat([['line', line()], ['col', column()]]); } /*------------------------------------------------------------------------------------------------------------------------------------- - key is defined as a character matching a to z, upper or lower case, followed by 0 or more alphanumeric characters + key is defined as a character matching a to z, upper or lower case, followed by 0 or more alphanumeric characters ---------------------------------------------------------------------------------------------------------------------------------------*/ key "key" = h:[a-zA-Z_$] t:[0-9a-zA-Z_$-]* @@ -138,25 +138,25 @@ array_part "array_part" = d:("." k:key {return k})+ a:(array)? { if (a) { return d.concat(a); } else { return d; } } /*------------------------------------------------------------------------------------------------------------------------------------- - inline params is defined as matching two double quotes or double quotes plus literal followed by closing double quotes or + inline params is defined as matching two double quotes or double quotes plus literal followed by closing double quotes or double quotes plus inline_part followed by the closing double quotes ---------------------------------------------------------------------------------------------------------------------------------------*/ inline "inline" - = '"' '"' { return ["literal", ""].concat([['line', line], ['col', column]]) } - / '"' l:literal '"' { return ["literal", l].concat([['line', line], ['col', column]]) } - / '"' p:inline_part+ '"' { return ["body"].concat(p).concat([['line', line], ['col', column]]) } + = '"' '"' { return ["literal", ""].concat([['line', line()], ['col', column()]]) } + / '"' l:literal '"' { return ["literal", l].concat([['line', line()], ['col', column()]]) } + / '"' p:inline_part+ '"' { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- - inline_part is defined as matching a special or reference or literal + inline_part is defined as matching a special or reference or literal ---------------------------------------------------------------------------------------------------------------------------------------*/ inline_part = special / reference / l:literal { return ["buffer", l] } buffer "buffer" = e:eol w:ws* - { return ["format", e, w.join('')].concat([['line', line], ['col', column]]) } + { return ["format", e, w.join('')].concat([['line', line()], ['col', column()]]) } / b:(!tag !raw !comment !eol c:. {return c})+ - { return ["buffer", b.join('')].concat([['line', line], ['col', column]]) } + { return ["buffer", b.join('')].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- literal is defined as matching esc or any character except the double quotes and it cannot be a tag @@ -170,13 +170,13 @@ esc raw "raw" = "{`" rawText:(!"`}" char:. {return char})* "`}" - { return ["raw", rawText.join('')].concat([['line', line], ['col', column]]) } + { return ["raw", rawText.join('')].concat([['line', line()], ['col', column()]]) } comment "comment" = "{!" c:(!"!}" c:. {return c})* "!}" - { return ["comment", c.join('')].concat([['line', line], ['col', column]]) } + { return ["comment", c.join('')].concat([['line', line()], ['col', column()]]) } /*------------------------------------------------------------------------------------------------------------------------------------- - tag is defined as matching an opening brace plus any of #?^><+%:@/~% plus 0 or more whitespaces plus any character or characters that + tag is defined as matching an opening brace plus any of #?^><+%:@/~% plus 0 or more whitespaces plus any character or characters that doesn't match rd or eol plus 0 or more whitespaces plus a closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ tag @@ -195,7 +195,7 @@ lb rb = "]" -eol +eol = "\n" //line feed / "\r\n" //carriage + line feed / "\r" //carriage return diff --git a/test/jasmine-test/spec/coreTests.js b/test/jasmine-test/spec/coreTests.js index eee6223b..532b036f 100755 --- a/test/jasmine-test/spec/coreTests.js +++ b/test/jasmine-test/spec/coreTests.js @@ -958,7 +958,7 @@ var coreTests = [ /** * PARTIAL DEFINITIONS TESTS */ - { + { name: "partial definitions", tests: [ { @@ -1389,7 +1389,7 @@ var coreTests = [ name: "error: whitespaces between the opening brace and any of (#,?,@,^,+,%) is not allowed", source: '{ # helper foo="bar" boo="boo" } {/helper}', context: { "helper": function(chunk, context, bodies, params) { return chunk.write(params.boo + " " + params.foo); } }, - error: 'Expected buffer, comment, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', + error: 'Expected buffer, comment, end of input, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', message: "should show an error for whitespces between the opening brace and any of (#,?,@,^,+,%)" }, { @@ -1417,7 +1417,7 @@ var coreTests = [ name: "error: whitespaces between the forward slash and the closing brace in self closing tags", source: '{#helper foo="bar" boo="boo" / }', context: { "helper": function(chunk, context, bodies, params) { return chunk.write(params.boo + " " + params.foo); } }, - error: 'Expected buffer, comment, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', + error: 'Expected buffer, comment, end of input, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', message: "should show an error for whitespaces etween the forward slash and the closing brace in self closing tags" }, { @@ -1431,7 +1431,7 @@ var coreTests = [ name: "error : whitespaces between the '{' plus '>' and partial identifier is not supported", source: '{ > partial/} {> "hello_world"/} {> "{ref}"/}', context: { "name": "Jim", "count": 42, "ref": "hello_world" }, - error: 'Expected buffer, comment, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', + error: 'Expected buffer, comment, end of input, partial, raw, reference, section or special but "{" found. At line : 1, column : 1', message: "should show an error for whitespaces between the '{' plus '>' and partial identifier" }, { @@ -1531,7 +1531,7 @@ var coreTests = [ name: "Dust syntax error", source: "RRR {##}", context: { name: "Mick", count: 30 }, - error: 'Expected buffer, comment, partial, raw, reference, section or special but "{" found. At line : 1, column : 5', + error: 'Expected buffer, comment, end of input, partial, raw, reference, section or special but "{" found. At line : 1, column : 5', message: "should test that the error message shows line and column." }, { From 3b39e052413a49765f8209568dbf805603489c9f Mon Sep 17 00:00:00 2001 From: Seth Kinast Date: Thu, 4 Sep 2014 19:19:27 -0700 Subject: [PATCH 4/5] Grammar cleanup. Use new |error| grammar. --- lib/parser.js | 290 ++++++++++++++++++++++++++----------------------- src/dust.pegjs | 30 ++++- 2 files changed, 179 insertions(+), 141 deletions(-) diff --git a/lib/parser.js b/lib/parser.js index 745acaf9..687387c5 100644 --- a/lib/parser.js +++ b/lib/parser.js @@ -44,16 +44,32 @@ peg$startRuleFunction = peg$parsestart, peg$c0 = [], - peg$c1 = function(p) { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) }, + peg$c1 = function(p) { + return ["body"] + .concat(p) + .concat([['line', line()], ['col', column()]]); + }, peg$c2 = { type: "other", description: "section" }, peg$c3 = peg$FAILED, peg$c4 = null, - peg$c5 = function(t, b, e, n) {if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line()+", column : " + column())} return true;}, + peg$c5 = function(t, b, e, n) { + if( (!n) || (t[1].text !== n.text) ) { + error("Expected end tag for "+t[1].text+" but it was not found."); + } + return true; + }, peg$c6 = void 0, - peg$c7 = function(t, b, e, n) { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line()], ['col', column()]]) }, + peg$c7 = function(t, b, e, n) { + e.push(["param", ["literal", "block"], b]); + t.push(e); + return t.concat([['line', line()], ['col', column()]]); + }, peg$c8 = "/", peg$c9 = { type: "literal", value: "/", description: "\"/\"" }, - peg$c10 = function(t) { t.push(["bodies"]); return t.concat([['line', line()], ['col', column()]]) }, + peg$c10 = function(t) { + t.push(["bodies"]); + return t.concat([['line', line()], ['col', column()]]); + }, peg$c11 = /^[#?\^<+@%]/, peg$c12 = { type: "class", value: "[#?\\^<+@%]", description: "[#?\\^<+@%]" }, peg$c13 = function(t, n, c, p) { return [t, n, c, p] }, @@ -78,7 +94,10 @@ peg$c32 = "+", peg$c33 = { type: "literal", value: "+", description: "\"+\"" }, peg$c34 = function(k) {return ["literal", k]}, - peg$c35 = function(s, n, c, p) { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line()], ['col', column()]]) }, + peg$c35 = function(s, n, c, p) { + var key = (s === ">") ? "partial" : s; + return [key, n, c, p].concat([['line', line()], ['col', column()]]); + }, peg$c36 = { type: "other", description: "filters" }, peg$c37 = "|", peg$c38 = { type: "literal", value: "|", description: "\"|\"" }, @@ -133,54 +152,55 @@ peg$c75 = { type: "literal", value: "\"", description: "\"\\\"\"" }, peg$c76 = function() { return ["literal", ""].concat([['line', line()], ['col', column()]]) }, peg$c77 = function(l) { return ["literal", l].concat([['line', line()], ['col', column()]]) }, - peg$c78 = function(l) { return ["buffer", l] }, - peg$c79 = { type: "other", description: "buffer" }, - peg$c80 = function(e, w) { return ["format", e, w.join('')].concat([['line', line()], ['col', column()]]) }, - peg$c81 = { type: "any", description: "any character" }, - peg$c82 = function(c) {return c}, - peg$c83 = function(b) { return ["buffer", b.join('')].concat([['line', line()], ['col', column()]]) }, - peg$c84 = { type: "other", description: "literal" }, - peg$c85 = /^[^"]/, - peg$c86 = { type: "class", value: "[^\"]", description: "[^\"]" }, - peg$c87 = function(b) { return b.join('') }, - peg$c88 = "\\\"", - peg$c89 = { type: "literal", value: "\\\"", description: "\"\\\\\\\"\"" }, - peg$c90 = function() { return '"' }, - peg$c91 = { type: "other", description: "raw" }, - peg$c92 = "{`", - peg$c93 = { type: "literal", value: "{`", description: "\"{`\"" }, - peg$c94 = "`}", - peg$c95 = { type: "literal", value: "`}", description: "\"`}\"" }, - peg$c96 = function(char) {return char}, - peg$c97 = function(rawText) { return ["raw", rawText.join('')].concat([['line', line()], ['col', column()]]) }, - peg$c98 = { type: "other", description: "comment" }, - peg$c99 = "{!", - peg$c100 = { type: "literal", value: "{!", description: "\"{!\"" }, - peg$c101 = "!}", - peg$c102 = { type: "literal", value: "!}", description: "\"!}\"" }, - peg$c103 = function(c) { return ["comment", c.join('')].concat([['line', line()], ['col', column()]]) }, - peg$c104 = /^[#?\^><+%:@\/~%]/, - peg$c105 = { type: "class", value: "[#?\\^><+%:@\\/~%]", description: "[#?\\^><+%:@\\/~%]" }, - peg$c106 = "{", - peg$c107 = { type: "literal", value: "{", description: "\"{\"" }, - peg$c108 = "}", - peg$c109 = { type: "literal", value: "}", description: "\"}\"" }, - peg$c110 = "[", - peg$c111 = { type: "literal", value: "[", description: "\"[\"" }, - peg$c112 = "]", - peg$c113 = { type: "literal", value: "]", description: "\"]\"" }, - peg$c114 = "\n", - peg$c115 = { type: "literal", value: "\n", description: "\"\\n\"" }, - peg$c116 = "\r\n", - peg$c117 = { type: "literal", value: "\r\n", description: "\"\\r\\n\"" }, - peg$c118 = "\r", - peg$c119 = { type: "literal", value: "\r", description: "\"\\r\"" }, - peg$c120 = "\u2028", - peg$c121 = { type: "literal", value: "\u2028", description: "\"\\u2028\"" }, - peg$c122 = "\u2029", - peg$c123 = { type: "literal", value: "\u2029", description: "\"\\u2029\"" }, - peg$c124 = /^[\t\x0B\f \xA0\uFEFF]/, - peg$c125 = { type: "class", value: "[\\t\\x0B\\f \\xA0\\uFEFF]", description: "[\\t\\x0B\\f \\xA0\\uFEFF]" }, + peg$c78 = function(p) { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) }, + peg$c79 = function(l) { return ["buffer", l] }, + peg$c80 = { type: "other", description: "buffer" }, + peg$c81 = function(e, w) { return ["format", e, w.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c82 = { type: "any", description: "any character" }, + peg$c83 = function(c) {return c}, + peg$c84 = function(b) { return ["buffer", b.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c85 = { type: "other", description: "literal" }, + peg$c86 = /^[^"]/, + peg$c87 = { type: "class", value: "[^\"]", description: "[^\"]" }, + peg$c88 = function(b) { return b.join('') }, + peg$c89 = "\\\"", + peg$c90 = { type: "literal", value: "\\\"", description: "\"\\\\\\\"\"" }, + peg$c91 = function() { return '"' }, + peg$c92 = { type: "other", description: "raw" }, + peg$c93 = "{`", + peg$c94 = { type: "literal", value: "{`", description: "\"{`\"" }, + peg$c95 = "`}", + peg$c96 = { type: "literal", value: "`}", description: "\"`}\"" }, + peg$c97 = function(char) {return char}, + peg$c98 = function(rawText) { return ["raw", rawText.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c99 = { type: "other", description: "comment" }, + peg$c100 = "{!", + peg$c101 = { type: "literal", value: "{!", description: "\"{!\"" }, + peg$c102 = "!}", + peg$c103 = { type: "literal", value: "!}", description: "\"!}\"" }, + peg$c104 = function(c) { return ["comment", c.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c105 = /^[#?\^><+%:@\/~%]/, + peg$c106 = { type: "class", value: "[#?\\^><+%:@\\/~%]", description: "[#?\\^><+%:@\\/~%]" }, + peg$c107 = "{", + peg$c108 = { type: "literal", value: "{", description: "\"{\"" }, + peg$c109 = "}", + peg$c110 = { type: "literal", value: "}", description: "\"}\"" }, + peg$c111 = "[", + peg$c112 = { type: "literal", value: "[", description: "\"[\"" }, + peg$c113 = "]", + peg$c114 = { type: "literal", value: "]", description: "\"]\"" }, + peg$c115 = "\n", + peg$c116 = { type: "literal", value: "\n", description: "\"\\n\"" }, + peg$c117 = "\r\n", + peg$c118 = { type: "literal", value: "\r\n", description: "\"\\r\\n\"" }, + peg$c119 = "\r", + peg$c120 = { type: "literal", value: "\r", description: "\"\\r\"" }, + peg$c121 = "\u2028", + peg$c122 = { type: "literal", value: "\u2028", description: "\"\\u2028\"" }, + peg$c123 = "\u2029", + peg$c124 = { type: "literal", value: "\u2029", description: "\"\\u2029\"" }, + peg$c125 = /^[\t\x0B\f \xA0\uFEFF]/, + peg$c126 = { type: "class", value: "[\\t\\x0B\\f \\xA0\\uFEFF]", description: "[\\t\\x0B\\f \\xA0\\uFEFF]" }, peg$currPos = 0, peg$reportedPos = 0, @@ -1710,7 +1730,7 @@ } if (s3 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c1(s2); + s1 = peg$c78(s2); s0 = s1; } else { peg$currPos = s0; @@ -1746,7 +1766,7 @@ s1 = peg$parseliteral(); if (s1 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c78(s1); + s1 = peg$c79(s1); } s0 = s1; } @@ -1770,7 +1790,7 @@ } if (s2 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c80(s1, s2); + s1 = peg$c81(s1, s2); s0 = s1; } else { peg$currPos = s0; @@ -1833,11 +1853,11 @@ peg$currPos++; } else { s7 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s7 !== peg$FAILED) { peg$reportedPos = s2; - s3 = peg$c82(s7); + s3 = peg$c83(s7); s2 = s3; } else { peg$currPos = s2; @@ -1912,11 +1932,11 @@ peg$currPos++; } else { s7 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s7 !== peg$FAILED) { peg$reportedPos = s2; - s3 = peg$c82(s7); + s3 = peg$c83(s7); s2 = s3; } else { peg$currPos = s2; @@ -1944,14 +1964,14 @@ } if (s1 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c83(s1); + s1 = peg$c84(s1); } s0 = s1; } peg$silentFails--; if (s0 === peg$FAILED) { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c79); } + if (peg$silentFails === 0) { peg$fail(peg$c80); } } return s0; @@ -1977,17 +1997,17 @@ if (s3 !== peg$FAILED) { s4 = peg$parseesc(); if (s4 === peg$FAILED) { - if (peg$c85.test(input.charAt(peg$currPos))) { + if (peg$c86.test(input.charAt(peg$currPos))) { s4 = input.charAt(peg$currPos); peg$currPos++; } else { s4 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c86); } + if (peg$silentFails === 0) { peg$fail(peg$c87); } } } if (s4 !== peg$FAILED) { peg$reportedPos = s2; - s3 = peg$c82(s4); + s3 = peg$c83(s4); s2 = s3; } else { peg$currPos = s2; @@ -2014,17 +2034,17 @@ if (s3 !== peg$FAILED) { s4 = peg$parseesc(); if (s4 === peg$FAILED) { - if (peg$c85.test(input.charAt(peg$currPos))) { + if (peg$c86.test(input.charAt(peg$currPos))) { s4 = input.charAt(peg$currPos); peg$currPos++; } else { s4 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c86); } + if (peg$silentFails === 0) { peg$fail(peg$c87); } } } if (s4 !== peg$FAILED) { peg$reportedPos = s2; - s3 = peg$c82(s4); + s3 = peg$c83(s4); s2 = s3; } else { peg$currPos = s2; @@ -2040,13 +2060,13 @@ } if (s1 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c87(s1); + s1 = peg$c88(s1); } s0 = s1; peg$silentFails--; if (s0 === peg$FAILED) { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c84); } + if (peg$silentFails === 0) { peg$fail(peg$c85); } } return s0; @@ -2056,16 +2076,16 @@ var s0, s1; s0 = peg$currPos; - if (input.substr(peg$currPos, 2) === peg$c88) { - s1 = peg$c88; + if (input.substr(peg$currPos, 2) === peg$c89) { + s1 = peg$c89; peg$currPos += 2; } else { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c89); } + if (peg$silentFails === 0) { peg$fail(peg$c90); } } if (s1 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c90(); + s1 = peg$c91(); } s0 = s1; @@ -2077,24 +2097,24 @@ peg$silentFails++; s0 = peg$currPos; - if (input.substr(peg$currPos, 2) === peg$c92) { - s1 = peg$c92; + if (input.substr(peg$currPos, 2) === peg$c93) { + s1 = peg$c93; peg$currPos += 2; } else { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c93); } + if (peg$silentFails === 0) { peg$fail(peg$c94); } } if (s1 !== peg$FAILED) { s2 = []; s3 = peg$currPos; s4 = peg$currPos; peg$silentFails++; - if (input.substr(peg$currPos, 2) === peg$c94) { - s5 = peg$c94; + if (input.substr(peg$currPos, 2) === peg$c95) { + s5 = peg$c95; peg$currPos += 2; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c95); } + if (peg$silentFails === 0) { peg$fail(peg$c96); } } peg$silentFails--; if (s5 === peg$FAILED) { @@ -2109,11 +2129,11 @@ peg$currPos++; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s5 !== peg$FAILED) { peg$reportedPos = s3; - s4 = peg$c96(s5); + s4 = peg$c97(s5); s3 = s4; } else { peg$currPos = s3; @@ -2128,12 +2148,12 @@ s3 = peg$currPos; s4 = peg$currPos; peg$silentFails++; - if (input.substr(peg$currPos, 2) === peg$c94) { - s5 = peg$c94; + if (input.substr(peg$currPos, 2) === peg$c95) { + s5 = peg$c95; peg$currPos += 2; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c95); } + if (peg$silentFails === 0) { peg$fail(peg$c96); } } peg$silentFails--; if (s5 === peg$FAILED) { @@ -2148,11 +2168,11 @@ peg$currPos++; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s5 !== peg$FAILED) { peg$reportedPos = s3; - s4 = peg$c96(s5); + s4 = peg$c97(s5); s3 = s4; } else { peg$currPos = s3; @@ -2164,16 +2184,16 @@ } } if (s2 !== peg$FAILED) { - if (input.substr(peg$currPos, 2) === peg$c94) { - s3 = peg$c94; + if (input.substr(peg$currPos, 2) === peg$c95) { + s3 = peg$c95; peg$currPos += 2; } else { s3 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c95); } + if (peg$silentFails === 0) { peg$fail(peg$c96); } } if (s3 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c97(s2); + s1 = peg$c98(s2); s0 = s1; } else { peg$currPos = s0; @@ -2190,7 +2210,7 @@ peg$silentFails--; if (s0 === peg$FAILED) { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c91); } + if (peg$silentFails === 0) { peg$fail(peg$c92); } } return s0; @@ -2201,24 +2221,24 @@ peg$silentFails++; s0 = peg$currPos; - if (input.substr(peg$currPos, 2) === peg$c99) { - s1 = peg$c99; + if (input.substr(peg$currPos, 2) === peg$c100) { + s1 = peg$c100; peg$currPos += 2; } else { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c100); } + if (peg$silentFails === 0) { peg$fail(peg$c101); } } if (s1 !== peg$FAILED) { s2 = []; s3 = peg$currPos; s4 = peg$currPos; peg$silentFails++; - if (input.substr(peg$currPos, 2) === peg$c101) { - s5 = peg$c101; + if (input.substr(peg$currPos, 2) === peg$c102) { + s5 = peg$c102; peg$currPos += 2; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c102); } + if (peg$silentFails === 0) { peg$fail(peg$c103); } } peg$silentFails--; if (s5 === peg$FAILED) { @@ -2233,11 +2253,11 @@ peg$currPos++; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s5 !== peg$FAILED) { peg$reportedPos = s3; - s4 = peg$c82(s5); + s4 = peg$c83(s5); s3 = s4; } else { peg$currPos = s3; @@ -2252,12 +2272,12 @@ s3 = peg$currPos; s4 = peg$currPos; peg$silentFails++; - if (input.substr(peg$currPos, 2) === peg$c101) { - s5 = peg$c101; + if (input.substr(peg$currPos, 2) === peg$c102) { + s5 = peg$c102; peg$currPos += 2; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c102); } + if (peg$silentFails === 0) { peg$fail(peg$c103); } } peg$silentFails--; if (s5 === peg$FAILED) { @@ -2272,11 +2292,11 @@ peg$currPos++; } else { s5 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s5 !== peg$FAILED) { peg$reportedPos = s3; - s4 = peg$c82(s5); + s4 = peg$c83(s5); s3 = s4; } else { peg$currPos = s3; @@ -2288,16 +2308,16 @@ } } if (s2 !== peg$FAILED) { - if (input.substr(peg$currPos, 2) === peg$c101) { - s3 = peg$c101; + if (input.substr(peg$currPos, 2) === peg$c102) { + s3 = peg$c102; peg$currPos += 2; } else { s3 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c102); } + if (peg$silentFails === 0) { peg$fail(peg$c103); } } if (s3 !== peg$FAILED) { peg$reportedPos = s0; - s1 = peg$c103(s2); + s1 = peg$c104(s2); s0 = s1; } else { peg$currPos = s0; @@ -2314,7 +2334,7 @@ peg$silentFails--; if (s0 === peg$FAILED) { s1 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c98); } + if (peg$silentFails === 0) { peg$fail(peg$c99); } } return s0; @@ -2333,12 +2353,12 @@ s3 = peg$parsews(); } if (s2 !== peg$FAILED) { - if (peg$c104.test(input.charAt(peg$currPos))) { + if (peg$c105.test(input.charAt(peg$currPos))) { s3 = input.charAt(peg$currPos); peg$currPos++; } else { s3 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c105); } + if (peg$silentFails === 0) { peg$fail(peg$c106); } } if (s3 !== peg$FAILED) { s4 = []; @@ -2377,7 +2397,7 @@ peg$currPos++; } else { s9 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s9 !== peg$FAILED) { s7 = [s7, s8, s9]; @@ -2425,7 +2445,7 @@ peg$currPos++; } else { s9 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c81); } + if (peg$silentFails === 0) { peg$fail(peg$c82); } } if (s9 !== peg$FAILED) { s7 = [s7, s8, s9]; @@ -2497,11 +2517,11 @@ var s0; if (input.charCodeAt(peg$currPos) === 123) { - s0 = peg$c106; + s0 = peg$c107; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c107); } + if (peg$silentFails === 0) { peg$fail(peg$c108); } } return s0; @@ -2511,11 +2531,11 @@ var s0; if (input.charCodeAt(peg$currPos) === 125) { - s0 = peg$c108; + s0 = peg$c109; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c109); } + if (peg$silentFails === 0) { peg$fail(peg$c110); } } return s0; @@ -2525,11 +2545,11 @@ var s0; if (input.charCodeAt(peg$currPos) === 91) { - s0 = peg$c110; + s0 = peg$c111; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c111); } + if (peg$silentFails === 0) { peg$fail(peg$c112); } } return s0; @@ -2539,11 +2559,11 @@ var s0; if (input.charCodeAt(peg$currPos) === 93) { - s0 = peg$c112; + s0 = peg$c113; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c113); } + if (peg$silentFails === 0) { peg$fail(peg$c114); } } return s0; @@ -2553,43 +2573,43 @@ var s0; if (input.charCodeAt(peg$currPos) === 10) { - s0 = peg$c114; + s0 = peg$c115; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c115); } + if (peg$silentFails === 0) { peg$fail(peg$c116); } } if (s0 === peg$FAILED) { - if (input.substr(peg$currPos, 2) === peg$c116) { - s0 = peg$c116; + if (input.substr(peg$currPos, 2) === peg$c117) { + s0 = peg$c117; peg$currPos += 2; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c117); } + if (peg$silentFails === 0) { peg$fail(peg$c118); } } if (s0 === peg$FAILED) { if (input.charCodeAt(peg$currPos) === 13) { - s0 = peg$c118; + s0 = peg$c119; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c119); } + if (peg$silentFails === 0) { peg$fail(peg$c120); } } if (s0 === peg$FAILED) { if (input.charCodeAt(peg$currPos) === 8232) { - s0 = peg$c120; + s0 = peg$c121; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c121); } + if (peg$silentFails === 0) { peg$fail(peg$c122); } } if (s0 === peg$FAILED) { if (input.charCodeAt(peg$currPos) === 8233) { - s0 = peg$c122; + s0 = peg$c123; peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c123); } + if (peg$silentFails === 0) { peg$fail(peg$c124); } } } } @@ -2602,12 +2622,12 @@ function peg$parsews() { var s0; - if (peg$c124.test(input.charAt(peg$currPos))) { + if (peg$c125.test(input.charAt(peg$currPos))) { s0 = input.charAt(peg$currPos); peg$currPos++; } else { s0 = peg$FAILED; - if (peg$silentFails === 0) { peg$fail(peg$c125); } + if (peg$silentFails === 0) { peg$fail(peg$c126); } } if (s0 === peg$FAILED) { s0 = peg$parseeol(); diff --git a/src/dust.pegjs b/src/dust.pegjs index 8119a40f..5b9a0667 100644 --- a/src/dust.pegjs +++ b/src/dust.pegjs @@ -5,7 +5,11 @@ start body is defined as anything that matches with the part 0 or more times ---------------------------------------------------------------------------------------------------------------------------------------*/ body - = p:part* { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) } + = p:part* { + return ["body"] + .concat(p) + .concat([['line', line()], ['col', column()]]); + } /*------------------------------------------------------------------------------------------------------------------------------------- part is defined as anything that matches with raw or comment or section or partial or special or reference or buffer @@ -18,10 +22,21 @@ part plus bodies plus end_tag or sec_tag_start followed by a slash and closing brace ---------------------------------------------------------------------------------------------------------------------------------------*/ section "section" - = t:sec_tag_start ws* rd b:body e:bodies n:end_tag? &{if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line()+", column : " + column())} return true;} - { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line()], ['col', column()]]) } - / t:sec_tag_start ws* "/" rd - { t.push(["bodies"]); return t.concat([['line', line()], ['col', column()]]) } + = t:sec_tag_start ws* rd b:body e:bodies n:end_tag? &{ + if( (!n) || (t[1].text !== n.text) ) { + error("Expected end tag for "+t[1].text+" but it was not found."); + } + return true; + } + { + e.push(["param", ["literal", "block"], b]); + t.push(e); + return t.concat([['line', line()], ['col', column()]]); + } + / t:sec_tag_start ws* "/" rd { + t.push(["bodies"]); + return t.concat([['line', line()], ['col', column()]]); + } /*------------------------------------------------------------------------------------------------------------------------------------- sec_tag_start is defined as matching an opening brace followed by one of #?^<+@% plus identifier plus context plus param @@ -73,7 +88,10 @@ reference "reference" ---------------------------------------------------------------------------------------------------------------------------------------*/ partial "partial" = ld s:(">"/"+") ws* n:(k:key {return ["literal", k]} / inline) c:context p:params ws* "/" rd - { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line()], ['col', column()]]) } + { + var key = (s === ">") ? "partial" : s; + return [key, n, c, p].concat([['line', line()], ['col', column()]]); + } /*------------------------------------------------------------------------------------------------------------------------------------- filters is defined as matching a pipe character followed by anything that matches the key From 48171d98ea9fbc69fbe9759b51d4d53e17680a12 Mon Sep 17 00:00:00 2001 From: Seth Kinast Date: Fri, 5 Sep 2014 20:20:18 -0700 Subject: [PATCH 5/5] Release v2.3.6 --- archive/dust-2.3.6.tar.gz | Bin 0 -> 45510 bytes archive/dust-2.3.6.zip | Bin 0 -> 47022 bytes bower.json | 2 +- dist/dust-core.js | 2 +- dist/dust-core.min.js | 4 +- dist/dust-full.js | 4789 ++++++++++++++++++------------------- dist/dust-full.min.js | 6 +- package.json | 2 +- 8 files changed, 2322 insertions(+), 2483 deletions(-) create mode 100644 archive/dust-2.3.6.tar.gz create mode 100644 archive/dust-2.3.6.zip diff --git a/archive/dust-2.3.6.tar.gz b/archive/dust-2.3.6.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..1ab896dfa7e6ce8e61f07dcfb8e6db268759c4c6 GIT binary patch literal 45510 zcmZtNQ*A?nT0HT0GQ+&Y9C}k z8f(M0`OXe~98YBfOhNJW^Q9KEZIWtcVxptDiOI^|o6p_w^0aj}dutw_XWPr=@OH1y zz5nK``@`{*|DOD3)lXN4@7HnfrA~K`@6-FAY<4@nkMyftYxbJ!PwD2baYibjp-)KW z0+wt!jL_A+`Gyy+R*v?$yO*!Y!L#+v_19Mu#i#I#<>jl~tMmS|(~~y?Cyp#tf4uy> zILO+QbUI)DtZw|-lY_Hj?Afa1c^jA87Op&a^62?JF;^Cx*vd0SRvxUWIB}e1BQ1Dx z`>Muyn>d8U;9&zEEcv)9LDnIU^f@O-5Qc}d`Tc1FHlc$-D~5de@B`po)$ql=w~Kib zMh%CqqPsH-y(bKcqRN*6ug4YBgu(gU#{~}%i=qjARr`_XTmS+U2_>mCxAILjVP zJiPp*2;c86pI$a3b)5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BZKoqk)Y~dJhxKAN{2zE)~ z9-Y2r5b1F`7izFGYpgy^H+;1=Cp{;M8Wy@eGvM&-B_<{Hvsr=sV%>#vi2w%Yt*PJI zR+DNpT50-Q{$*T2zG9PbeGAIT6UEZPI!L6~(AVPPwWx$VwYww52C#_4ZDW+8k#K9W zt2KT*xKlW}Yt&5n`RH029sh_#HfEV22ZS;%SkMqKE3kF|jlTiTl!a%I&lL=;fJ$Wp zX$-U$Ab1WX%R2?4EAsI3A3$UKqAdi_#Z#Pq{7Syc7CG*|-nAiZoN_@0=HD}=m3ot7#g zvJ1vx`lVx&NuDw-D}v2Yy6SRlCPh=VZ0(S)CT`PBpVYLCXXXzzTrEKTbySal2hFce zha|s2h8CD#yZ?}^Mwv0{SyBQ33`7F_ldJ*)Ap`s`(W*;nQm8u+001cn0083ul&}8R z#Ms5jnTC;;iI$a4T0%%fR!QXltS5gm7?H;X0MOC}06_b%vj04{{X_k4_5V3FvU4<{ zwRHMFL1v^RK#Jf10M`DI{14^q{~9s`{|}J=p`-mjf&RNV_kU-@!SH_r{ih)J|7P>w hU)TT6CL-$p0rFpLK*9clI_SSc8xR11yX8Nw{y$S>-3|Z% literal 0 HcmV?d00001 diff --git a/bower.json b/bower.json index dcc8a4dd..468b6199 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "dustjs-linkedin", - "version": "2.3.5", + "version": "2.3.6", "main": "dist/dust-full.min.js", "devDependencies": { "pegjs": "0.8.0" diff --git a/dist/dust-core.js b/dist/dust-core.js index 5583d05f..179802f8 100644 --- a/dist/dust-core.js +++ b/dist/dust-core.js @@ -1,4 +1,4 @@ -/*! Dust - Asynchronous Templating - v2.3.5 +/*! Dust - Asynchronous Templating - v2.3.6 * http://linkedin.github.io/dustjs/ * Copyright (c) 2014 Aleksander Williams; Released under the MIT License */ (function(root) { diff --git a/dist/dust-core.min.js b/dist/dust-core.min.js index bdee5f12..fcfd6752 100644 --- a/dist/dust-core.min.js +++ b/dist/dust-core.min.js @@ -1,4 +1,4 @@ -/*! Dust - Asynchronous Templating - v2.3.5 +/*! Dust - Asynchronous Templating - v2.3.6 * http://linkedin.github.io/dustjs/ * Copyright (c) 2014 Aleksander Williams; Released under the MIT License */ -!function(root){function Context(a,b,c,d){this.stack=a,this.global=b,this.blocks=c,this.templateName=d}function Stack(a,b,c,d){this.tail=b,this.isObject=a&&"object"==typeof a,this.head=a,this.index=c,this.of=d}function Stub(a){this.head=new Chunk(this),this.callback=a,this.out=""}function Stream(){this.head=new Chunk(this)}function Chunk(a,b,c){this.root=a,this.next=b,this.data=[],this.flushable=!1,this.taps=c}function Tap(a,b){this.head=a,this.tail=b}var dust={},NONE="NONE",ERROR="ERROR",WARN="WARN",INFO="INFO",DEBUG="DEBUG",loggingLevels=[DEBUG,INFO,WARN,ERROR,NONE],EMPTY_FUNC=function(){},logger={},originalLog,loggerContext;dust.debugLevel=NONE,dust.silenceErrors=!1,root&&root.console&&root.console.log&&(loggerContext=root.console,originalLog=root.console.log),logger.log=loggerContext?function(){logger.log="function"==typeof originalLog?function(){originalLog.apply(loggerContext,arguments)}:function(){var a=Array.prototype.slice.apply(arguments).join(" ");originalLog(a)},logger.log.apply(this,arguments)}:function(){},dust.log=function(a,b){if(b=b||INFO,dust.debugLevel!==NONE&&dust.indexInArray(loggingLevels,b)>=dust.indexInArray(loggingLevels,dust.debugLevel)&&(dust.logQueue||(dust.logQueue=[]),dust.logQueue.push({message:a,type:b}),logger.log("[DUST "+b+"]: "+a)),!dust.silenceErrors&&b===ERROR)throw"string"==typeof a?new Error(a):a},dust.onError=function(a,b){if(logger.log("[!!!DEPRECATION WARNING!!!]: dust.onError will no longer return a chunk object."),dust.log(a.message||a,ERROR),dust.silenceErrors)return b;throw a},dust.helpers={},dust.cache={},dust.register=function(a,b){a&&(dust.cache[a]=b)},dust.render=function(a,b,c){var d=new Stub(c).head;try{dust.load(a,d,Context.wrap(b,a)).end()}catch(e){dust.log(e,ERROR)}},dust.stream=function(a,b){var c=new Stream;return dust.nextTick(function(){try{dust.load(a,c.head,Context.wrap(b,a)).end()}catch(d){dust.log(d,ERROR)}}),c},dust.renderSource=function(a,b,c){return dust.compileFn(a)(b,c)},dust.compileFn=function(a,b){b=b||null;var c=dust.loadSource(dust.compile(a,b));return function(a,d){var e=d?new Stub(d):new Stream;return dust.nextTick(function(){"function"==typeof c?c(e.head,Context.wrap(a,b)).end():dust.log(new Error("Template ["+b+"] cannot be resolved to a Dust function"),ERROR)}),e}},dust.load=function(a,b,c){var d=dust.cache[a];return d?d(b,c):dust.onLoad?b.map(function(b){dust.onLoad(a,function(d,e){return d?b.setError(d):(dust.cache[a]||dust.loadSource(dust.compile(e,a)),void dust.cache[a](b,c).end())})}):b.setError(new Error("Template Not Found: "+a))},dust.loadSource=function(source,path){return eval(source)},dust.isArray=Array.isArray?Array.isArray:function(a){return"[object Array]"===Object.prototype.toString.call(a)},dust.indexInArray=function(a,b,c){if(c=+c||0,Array.prototype.indexOf)return a.indexOf(b,c);if(void 0===a||null===a)throw new TypeError('cannot call method "indexOf" of null');var d=a.length;for(1/0===Math.abs(c)&&(c=0),0>c&&(c+=d,0>c&&(c=0));d>c;c++)if(a[c]===b)return c;return-1},dust.nextTick=function(){return function(a){setTimeout(a,0)}}(),dust.isEmpty=function(a){return dust.isArray(a)&&!a.length?!0:0===a?!1:!a},dust.filter=function(a,b,c){if(c)for(var d=0,e=c.length;e>d;d++){var f=c[d];"s"===f?b=null:"function"==typeof dust.filters[f]?a=dust.filters[f](a):dust.log("Invalid filter ["+f+"]",WARN)}return b&&(a=dust.filters[b](a)),a},dust.filters={h:function(a){return dust.escapeHtml(a)},j:function(a){return dust.escapeJs(a)},u:encodeURI,uc:encodeURIComponent,js:function(a){return JSON?JSON.stringify(a):(dust.log("JSON is undefined. JSON stringify has not been used on ["+a+"]",WARN),a)},jp:function(a){return JSON?JSON.parse(a):(dust.log("JSON is undefined. JSON parse has not been used on ["+a+"]",WARN),a)}},dust.makeBase=function(a){return new Context(new Stack,a)},Context.wrap=function(a,b){return a instanceof Context?a:new Context(new Stack(a),{},null,b)},Context.prototype.get=function(a,b){return"string"==typeof a&&("."===a[0]&&(b=!0,a=a.substr(1)),a=a.split(".")),this._get(b,a)},Context.prototype._get=function(a,b){var c,d,e,f,g=this.stack,h=1;if(d=b[0],e=b.length,a&&0===e)f=g,g=g.head;else{if(a)g&&(g=g.head?g.head[d]:void 0);else{for(;g&&(!g.isObject||(f=g.head,c=g.head[d],void 0===c));)g=g.tail;g=void 0!==c?c:this.global?this.global[d]:void 0}for(;g&&e>h;)f=g,g=g[b[h]],h++}if("function"==typeof g){var i=function(){try{return g.apply(f,arguments)}catch(a){return dust.log(a,ERROR)}};return i.isFunction=!0,i}return void 0===g&&dust.log("Cannot find the value for reference [{"+b.join(".")+"}] in template ["+this.getTemplateName()+"]"),g},Context.prototype.getPath=function(a,b){return this._get(a,b)},Context.prototype.push=function(a,b,c){return new Context(new Stack(a,this.stack,b,c),this.global,this.blocks,this.getTemplateName())},Context.prototype.rebase=function(a){return new Context(new Stack(a),this.global,this.blocks,this.getTemplateName())},Context.prototype.current=function(){return this.stack.head},Context.prototype.getBlock=function(a){if("function"==typeof a){var b=new Chunk;a=a(b,this).data.join("")}var c=this.blocks;if(!c)return void dust.log("No blocks for context[{"+a+"}] in template ["+this.getTemplateName()+"]",DEBUG);for(var d,e=c.length;e--;)if(d=c[e][a])return d},Context.prototype.shiftBlocks=function(a){var b,c=this.blocks;return a?(b=c?c.concat([a]):[a],new Context(this.stack,this.global,b,this.getTemplateName())):this},Context.prototype.getTemplateName=function(){return this.templateName},Stub.prototype.flush=function(){for(var a=this.head;a;){if(!a.flushable)return a.error?(this.callback(a.error),dust.log("Chunk error ["+a.error+"] thrown. Ceasing to render this template.",WARN),void(this.flush=EMPTY_FUNC)):void 0;this.out+=a.data.join(""),a=a.next,this.head=a}this.callback(null,this.out)},Stream.prototype.flush=function(){for(var a=this.head;a;){if(!a.flushable)return a.error?(this.emit("error",a.error),dust.log("Chunk error ["+a.error+"] thrown. Ceasing to render this template.",WARN),void(this.flush=EMPTY_FUNC)):void 0;this.emit("data",a.data.join("")),a=a.next,this.head=a}this.emit("end")},Stream.prototype.emit=function(a,b){if(!this.events)return dust.log("No events to emit",INFO),!1;var c=this.events[a];if(!c)return dust.log("Event type ["+a+"] does not exist",WARN),!1;if("function"==typeof c)c(b);else if(dust.isArray(c))for(var d=c.slice(0),e=0,f=d.length;f>e;e++)d[e](b);else dust.log("Event Handler ["+c+"] is not of a type that is handled by emit",WARN)},Stream.prototype.on=function(a,b){return this.events||(this.events={}),this.events[a]?"function"==typeof this.events[a]?this.events[a]=[this.events[a],b]:this.events[a].push(b):(dust.log("Event type ["+a+"] does not exist. Using just the specified callback.",WARN),b?this.events[a]=b:dust.log("Callback for type ["+a+"] does not exist. Listener not registered.",WARN)),this},Stream.prototype.pipe=function(a){return this.on("data",function(b){try{a.write(b,"utf8")}catch(c){dust.log(c,ERROR)}}).on("end",function(){try{return a.end()}catch(b){dust.log(b,ERROR)}}).on("error",function(b){a.error(b)}),this},Chunk.prototype.write=function(a){var b=this.taps;return b&&(a=b.go(a)),this.data.push(a),this},Chunk.prototype.end=function(a){return a&&this.write(a),this.flushable=!0,this.root.flush(),this},Chunk.prototype.map=function(a){var b=new Chunk(this.root,this.next,this.taps),c=new Chunk(this.root,b,this.taps);return this.next=c,this.flushable=!0,a(c),b},Chunk.prototype.tap=function(a){var b=this.taps;return this.taps=b?b.push(a):new Tap(a),this},Chunk.prototype.untap=function(){return this.taps=this.taps.tail,this},Chunk.prototype.render=function(a,b){return a(this,b)},Chunk.prototype.reference=function(a,b,c,d){return"function"==typeof a&&(a.isFunction=!0,a=a.apply(b.current(),[this,b,null,{auto:c,filters:d}]),a instanceof Chunk)?a:dust.isEmpty(a)?this:this.write(dust.filter(a,c,d))},Chunk.prototype.section=function(a,b,c,d){if("function"==typeof a&&(a=a.apply(b.current(),[this,b,c,d]),a instanceof Chunk))return a;var e=c.block,f=c["else"];if(d&&(b=b.push(d)),dust.isArray(a)){if(e){var g=a.length,h=this;if(g>0){b.stack.head&&(b.stack.head.$len=g);for(var i=0;g>i;i++)b.stack.head&&(b.stack.head.$idx=i),h=e(h,b.push(a[i],i,g));return b.stack.head&&(b.stack.head.$idx=void 0,b.stack.head.$len=void 0),h}if(f)return f(this,b)}}else if(a===!0){if(e)return e(this,b)}else if(a||0===a){if(e)return e(this,b.push(a))}else if(f)return f(this,b);return dust.log("Not rendering section (#) block in template ["+b.getTemplateName()+"], because above key was not found",DEBUG),this},Chunk.prototype.exists=function(a,b,c){var d=c.block,e=c["else"];if(dust.isEmpty(a)){if(e)return e(this,b)}else if(d)return d(this,b);return dust.log("Not rendering exists (?) block in template ["+b.getTemplateName()+"], because above key was not found",DEBUG),this},Chunk.prototype.notexists=function(a,b,c){var d=c.block,e=c["else"];if(dust.isEmpty(a)){if(d)return d(this,b)}else if(e)return e(this,b);return dust.log("Not rendering not exists (^) block check in template ["+b.getTemplateName()+"], because above key was found",DEBUG),this},Chunk.prototype.block=function(a,b,c){var d=c.block;return a&&(d=a),d?d(this,b):this},Chunk.prototype.partial=function(a,b,c){var d;d=dust.makeBase(b.global),d.blocks=b.blocks,b.stack&&b.stack.tail&&(d.stack=b.stack.tail),c&&(d=d.push(c)),"string"==typeof a&&(d.templateName=a),d=d.push(b.stack.head);var e;return e="function"==typeof a?this.capture(a,d,function(a,b){d.templateName=d.templateName||a,dust.load(a,b,d).end()}):dust.load(a,this,d)},Chunk.prototype.helper=function(a,b,c,d){var e=this;try{return dust.helpers[a]?dust.helpers[a](e,b,c,d):(dust.log("Invalid helper ["+a+"]",WARN),e)}catch(f){return dust.log(f,ERROR),e}},Chunk.prototype.capture=function(a,b,c){return this.map(function(d){var e=new Stub(function(a,b){a?d.setError(a):c(b,d)});a(e.head,b).end()})},Chunk.prototype.setError=function(a){return this.error=a,this.root.flush(),this},Tap.prototype.push=function(a){return new Tap(a,this)},Tap.prototype.go=function(a){for(var b=this;b;)a=b.head(a),b=b.tail;return a};var HCHARS=new RegExp(/[&<>\"\']/),AMP=/&/g,LT=//g,QUOT=/\"/g,SQUOT=/\'/g;dust.escapeHtml=function(a){return"string"==typeof a?HCHARS.test(a)?a.replace(AMP,"&").replace(LT,"<").replace(GT,">").replace(QUOT,""").replace(SQUOT,"'"):a:a};var BS=/\\/g,FS=/\//g,CR=/\r/g,LS=/\u2028/g,PS=/\u2029/g,NL=/\n/g,LF=/\f/g,SQ=/'/g,DQ=/"/g,TB=/\t/g;dust.escapeJs=function(a){return"string"==typeof a?a.replace(BS,"\\\\").replace(FS,"\\/").replace(DQ,'\\"').replace(SQ,"\\'").replace(CR,"\\r").replace(LS,"\\u2028").replace(PS,"\\u2029").replace(NL,"\\n").replace(LF,"\\f").replace(TB,"\\t"):a},"object"==typeof exports?module.exports=dust:root.dust=dust}(function(){return this}()); \ No newline at end of file +!function(root){function Context(a,b,c,d){this.stack=a,this.global=b,this.blocks=c,this.templateName=d}function Stack(a,b,c,d){this.tail=b,this.isObject=a&&"object"==typeof a,this.head=a,this.index=c,this.of=d}function Stub(a){this.head=new Chunk(this),this.callback=a,this.out=""}function Stream(){this.head=new Chunk(this)}function Chunk(a,b,c){this.root=a,this.next=b,this.data=[],this.flushable=!1,this.taps=c}function Tap(a,b){this.head=a,this.tail=b}var dust={},NONE="NONE",ERROR="ERROR",WARN="WARN",INFO="INFO",DEBUG="DEBUG",loggingLevels=[DEBUG,INFO,WARN,ERROR,NONE],EMPTY_FUNC=function(){},logger={},originalLog,loggerContext;dust.debugLevel=NONE,dust.silenceErrors=!1,root&&root.console&&root.console.log&&(loggerContext=root.console,originalLog=root.console.log),logger.log=loggerContext?function(){logger.log="function"==typeof originalLog?function(){originalLog.apply(loggerContext,arguments)}:function(){var a=Array.prototype.slice.apply(arguments).join(" ");originalLog(a)},logger.log.apply(this,arguments)}:function(){},dust.log=function(a,b){if(b=b||INFO,dust.debugLevel!==NONE&&dust.indexInArray(loggingLevels,b)>=dust.indexInArray(loggingLevels,dust.debugLevel)&&(dust.logQueue||(dust.logQueue=[]),dust.logQueue.push({message:a,type:b}),logger.log("[DUST "+b+"]: "+a)),!dust.silenceErrors&&b===ERROR)throw"string"==typeof a?new Error(a):a},dust.onError=function(a,b){if(logger.log("[!!!DEPRECATION WARNING!!!]: dust.onError will no longer return a chunk object."),dust.log(a.message||a,ERROR),dust.silenceErrors)return b;throw a},dust.helpers={},dust.cache={},dust.register=function(a,b){a&&(dust.cache[a]=b)},dust.render=function(a,b,c){var d=new Stub(c).head;try{dust.load(a,d,Context.wrap(b,a)).end()}catch(e){dust.log(e,ERROR)}},dust.stream=function(a,b){var c=new Stream;return dust.nextTick(function(){try{dust.load(a,c.head,Context.wrap(b,a)).end()}catch(d){dust.log(d,ERROR)}}),c},dust.renderSource=function(a,b,c){return dust.compileFn(a)(b,c)},dust.compileFn=function(a,b){b=b||null;var c=dust.loadSource(dust.compile(a,b));return function(a,d){var e=d?new Stub(d):new Stream;return dust.nextTick(function(){"function"==typeof c?c(e.head,Context.wrap(a,b)).end():dust.log(new Error("Template ["+b+"] cannot be resolved to a Dust function"),ERROR)}),e}},dust.load=function(a,b,c){var d=dust.cache[a];return d?d(b,c):dust.onLoad?b.map(function(b){dust.onLoad(a,function(d,e){return d?b.setError(d):(dust.cache[a]||dust.loadSource(dust.compile(e,a)),void dust.cache[a](b,c).end())})}):b.setError(new Error("Template Not Found: "+a))},dust.loadSource=function(source,path){return eval(source)},dust.isArray=Array.isArray?Array.isArray:function(a){return"[object Array]"===Object.prototype.toString.call(a)},dust.indexInArray=function(a,b,c){if(c=+c||0,Array.prototype.indexOf)return a.indexOf(b,c);if(void 0===a||null===a)throw new TypeError('cannot call method "indexOf" of null');var d=a.length;for(1/0===Math.abs(c)&&(c=0),0>c&&(c+=d,0>c&&(c=0));d>c;c++)if(a[c]===b)return c;return-1},dust.nextTick=function(){return function(a){setTimeout(a,0)}}(),dust.isEmpty=function(a){return dust.isArray(a)&&!a.length?!0:0===a?!1:!a},dust.filter=function(a,b,c){if(c)for(var d=0,e=c.length;e>d;d++){var f=c[d];"s"===f?b=null:"function"==typeof dust.filters[f]?a=dust.filters[f](a):dust.log("Invalid filter ["+f+"]",WARN)}return b&&(a=dust.filters[b](a)),a},dust.filters={h:function(a){return dust.escapeHtml(a)},j:function(a){return dust.escapeJs(a)},u:encodeURI,uc:encodeURIComponent,js:function(a){return JSON?JSON.stringify(a):(dust.log("JSON is undefined. JSON stringify has not been used on ["+a+"]",WARN),a)},jp:function(a){return JSON?JSON.parse(a):(dust.log("JSON is undefined. JSON parse has not been used on ["+a+"]",WARN),a)}},dust.makeBase=function(a){return new Context(new Stack,a)},Context.wrap=function(a,b){return a instanceof Context?a:new Context(new Stack(a),{},null,b)},Context.prototype.get=function(a,b){return"string"==typeof a&&("."===a[0]&&(b=!0,a=a.substr(1)),a=a.split(".")),this._get(b,a)},Context.prototype._get=function(a,b){var c,d,e,f,g=this.stack,h=1;if(d=b[0],e=b.length,a&&0===e)f=g,g=g.head;else{if(a)g&&(g=g.head?g.head[d]:void 0);else{for(;g&&(!g.isObject||(f=g.head,c=g.head[d],void 0===c));)g=g.tail;g=void 0!==c?c:this.global?this.global[d]:void 0}for(;g&&e>h;)f=g,g=g[b[h]],h++}if("function"==typeof g){var i=function(){try{return g.apply(f,arguments)}catch(a){return dust.log(a,ERROR)}};return i.isFunction=!0,i}return void 0===g&&dust.log("Cannot find the value for reference [{"+b.join(".")+"}] in template ["+this.getTemplateName()+"]"),g},Context.prototype.getPath=function(a,b){return this._get(a,b)},Context.prototype.push=function(a,b,c){return new Context(new Stack(a,this.stack,b,c),this.global,this.blocks,this.getTemplateName())},Context.prototype.rebase=function(a){return new Context(new Stack(a),this.global,this.blocks,this.getTemplateName())},Context.prototype.current=function(){return this.stack.head},Context.prototype.getBlock=function(a){if("function"==typeof a){var b=new Chunk;a=a(b,this).data.join("")}var c=this.blocks;if(!c)return void dust.log("No blocks for context[{"+a+"}] in template ["+this.getTemplateName()+"]",DEBUG);for(var d,e=c.length;e--;)if(d=c[e][a])return d},Context.prototype.shiftBlocks=function(a){var b,c=this.blocks;return a?(b=c?c.concat([a]):[a],new Context(this.stack,this.global,b,this.getTemplateName())):this},Context.prototype.getTemplateName=function(){return this.templateName},Stub.prototype.flush=function(){for(var a=this.head;a;){if(!a.flushable)return a.error?(this.callback(a.error),dust.log("Chunk error ["+a.error+"] thrown. Ceasing to render this template.",WARN),void(this.flush=EMPTY_FUNC)):void 0;this.out+=a.data.join(""),a=a.next,this.head=a}this.callback(null,this.out)},Stream.prototype.flush=function(){for(var a=this.head;a;){if(!a.flushable)return a.error?(this.emit("error",a.error),dust.log("Chunk error ["+a.error+"] thrown. Ceasing to render this template.",WARN),void(this.flush=EMPTY_FUNC)):void 0;this.emit("data",a.data.join("")),a=a.next,this.head=a}this.emit("end")},Stream.prototype.emit=function(a,b){if(!this.events)return dust.log("No events to emit",INFO),!1;var c=this.events[a];if(!c)return dust.log("Event type ["+a+"] does not exist",WARN),!1;if("function"==typeof c)c(b);else if(dust.isArray(c))for(var d=c.slice(0),e=0,f=d.length;f>e;e++)d[e](b);else dust.log("Event Handler ["+c+"] is not of a type that is handled by emit",WARN)},Stream.prototype.on=function(a,b){return this.events||(this.events={}),this.events[a]?"function"==typeof this.events[a]?this.events[a]=[this.events[a],b]:this.events[a].push(b):(dust.log("Event type ["+a+"] does not exist. Using just the specified callback.",WARN),b?this.events[a]=b:dust.log("Callback for type ["+a+"] does not exist. Listener not registered.",WARN)),this},Stream.prototype.pipe=function(a){return this.on("data",function(b){try{a.write(b,"utf8")}catch(c){dust.log(c,ERROR)}}).on("end",function(){try{return a.end()}catch(b){dust.log(b,ERROR)}}).on("error",function(b){a.error(b)}),this},Chunk.prototype.write=function(a){var b=this.taps;return b&&(a=b.go(a)),this.data.push(a),this},Chunk.prototype.end=function(a){return a&&this.write(a),this.flushable=!0,this.root.flush(),this},Chunk.prototype.map=function(a){var b=new Chunk(this.root,this.next,this.taps),c=new Chunk(this.root,b,this.taps);return this.next=c,this.flushable=!0,a(c),b},Chunk.prototype.tap=function(a){var b=this.taps;return this.taps=b?b.push(a):new Tap(a),this},Chunk.prototype.untap=function(){return this.taps=this.taps.tail,this},Chunk.prototype.render=function(a,b){return a(this,b)},Chunk.prototype.reference=function(a,b,c,d){return"function"==typeof a&&(a.isFunction=!0,a=a.apply(b.current(),[this,b,null,{auto:c,filters:d}]),a instanceof Chunk)?a:dust.isEmpty(a)?this:this.write(dust.filter(a,c,d))},Chunk.prototype.section=function(a,b,c,d){if("function"==typeof a&&(a=a.apply(b.current(),[this,b,c,d]),a instanceof Chunk))return a;var e=c.block,f=c["else"];if(d&&(b=b.push(d)),dust.isArray(a)){if(e){var g=a.length,h=this;if(g>0){b.stack.head&&(b.stack.head.$len=g);for(var i=0;g>i;i++)b.stack.head&&(b.stack.head.$idx=i),h=e(h,b.push(a[i],i,g));return b.stack.head&&(b.stack.head.$idx=void 0,b.stack.head.$len=void 0),h}if(f)return f(this,b)}}else if(a===!0){if(e)return e(this,b)}else if(a||0===a){if(e)return e(this,b.push(a))}else if(f)return f(this,b);return dust.log("Not rendering section (#) block in template ["+b.getTemplateName()+"], because above key was not found",DEBUG),this},Chunk.prototype.exists=function(a,b,c){var d=c.block,e=c["else"];if(dust.isEmpty(a)){if(e)return e(this,b)}else if(d)return d(this,b);return dust.log("Not rendering exists (?) block in template ["+b.getTemplateName()+"], because above key was not found",DEBUG),this},Chunk.prototype.notexists=function(a,b,c){var d=c.block,e=c["else"];if(dust.isEmpty(a)){if(d)return d(this,b)}else if(e)return e(this,b);return dust.log("Not rendering not exists (^) block check in template ["+b.getTemplateName()+"], because above key was found",DEBUG),this},Chunk.prototype.block=function(a,b,c){var d=c.block;return a&&(d=a),d?d(this,b):this},Chunk.prototype.partial=function(a,b,c){var d;d=dust.makeBase(b.global),d.blocks=b.blocks,b.stack&&b.stack.tail&&(d.stack=b.stack.tail),c&&(d=d.push(c)),"string"==typeof a&&(d.templateName=a),d=d.push(b.stack.head);var e;return e="function"==typeof a?this.capture(a,d,function(a,b){d.templateName=d.templateName||a,dust.load(a,b,d).end()}):dust.load(a,this,d)},Chunk.prototype.helper=function(a,b,c,d){var e=this;try{return dust.helpers[a]?dust.helpers[a](e,b,c,d):(dust.log("Invalid helper ["+a+"]",WARN),e)}catch(f){return dust.log(f,ERROR),e}},Chunk.prototype.capture=function(a,b,c){return this.map(function(d){var e=new Stub(function(a,b){a?d.setError(a):c(b,d)});a(e.head,b).end()})},Chunk.prototype.setError=function(a){return this.error=a,this.root.flush(),this},Tap.prototype.push=function(a){return new Tap(a,this)},Tap.prototype.go=function(a){for(var b=this;b;)a=b.head(a),b=b.tail;return a};var HCHARS=new RegExp(/[&<>\"\']/),AMP=/&/g,LT=//g,QUOT=/\"/g,SQUOT=/\'/g;dust.escapeHtml=function(a){return"string"==typeof a&&HCHARS.test(a)?a.replace(AMP,"&").replace(LT,"<").replace(GT,">").replace(QUOT,""").replace(SQUOT,"'"):a};var BS=/\\/g,FS=/\//g,CR=/\r/g,LS=/\u2028/g,PS=/\u2029/g,NL=/\n/g,LF=/\f/g,SQ=/'/g,DQ=/"/g,TB=/\t/g;dust.escapeJs=function(a){return"string"==typeof a?a.replace(BS,"\\\\").replace(FS,"\\/").replace(DQ,'\\"').replace(SQ,"\\'").replace(CR,"\\r").replace(LS,"\\u2028").replace(PS,"\\u2029").replace(NL,"\\n").replace(LF,"\\f").replace(TB,"\\t"):a},"object"==typeof exports?module.exports=dust:root.dust=dust}(function(){return this}()); \ No newline at end of file diff --git a/dist/dust-full.js b/dist/dust-full.js index c126a52f..3dfbde4f 100644 --- a/dist/dust-full.js +++ b/dist/dust-full.js @@ -1,4 +1,4 @@ -/*! Dust - Asynchronous Templating - v2.3.5 +/*! Dust - Asynchronous Templating - v2.3.6 * http://linkedin.github.io/dustjs/ * Copyright (c) 2014 Aleksander Williams; Released under the MIT License */ (function(root) { @@ -896,2811 +896,2650 @@ factory(root.dust); } }(this, function(dust) { - var parser = (function(){ + var parser = (function() { /* - * Generated by PEG.js 0.7.0. + * Generated by PEG.js 0.8.0. * * http://pegjs.majda.cz/ */ - - function quote(s) { - /* - * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a - * string literal except for the closing quote character, backslash, - * carriage return, line separator, paragraph separator, and line feed. - * Any character may appear in the form of an escape sequence. - * - * For portability, we also escape escape all control and non-ASCII - * characters. Note that "\0" and "\v" escape sequences are not used - * because JSHint does not like the first and IE the second. - */ - return '"' + s - .replace(/\\/g, '\\\\') // backslash - .replace(/"/g, '\\"') // closing quote character - .replace(/\x08/g, '\\b') // backspace - .replace(/\t/g, '\\t') // horizontal tab - .replace(/\n/g, '\\n') // line feed - .replace(/\f/g, '\\f') // form feed - .replace(/\r/g, '\\r') // carriage return - .replace(/[\x00-\x07\x0B\x0E-\x1F\x80-\uFFFF]/g, escape) - + '"'; + + function peg$subclass(child, parent) { + function ctor() { this.constructor = child; } + ctor.prototype = parent.prototype; + child.prototype = new ctor(); } - - var result = { - /* - * Parses the input with a generated parser. If the parsing is successfull, - * returns a value explicitly or implicitly specified by the grammar from - * which the parser was generated (see |PEG.buildParser|). If the parsing is - * unsuccessful, throws |PEG.parser.SyntaxError| describing the error. - */ - parse: function(input, startRule) { - var parseFunctions = { - "body": parse_body, - "part": parse_part, - "section": parse_section, - "sec_tag_start": parse_sec_tag_start, - "end_tag": parse_end_tag, - "context": parse_context, - "params": parse_params, - "bodies": parse_bodies, - "reference": parse_reference, - "partial": parse_partial, - "filters": parse_filters, - "special": parse_special, - "identifier": parse_identifier, - "number": parse_number, - "float": parse_float, - "integer": parse_integer, - "path": parse_path, - "key": parse_key, - "array": parse_array, - "array_part": parse_array_part, - "inline": parse_inline, - "inline_part": parse_inline_part, - "buffer": parse_buffer, - "literal": parse_literal, - "esc": parse_esc, - "raw": parse_raw, - "comment": parse_comment, - "tag": parse_tag, - "ld": parse_ld, - "rd": parse_rd, - "lb": parse_lb, - "rb": parse_rb, - "eol": parse_eol, - "ws": parse_ws - }; - - if (startRule !== undefined) { - if (parseFunctions[startRule] === undefined) { - throw new Error("Invalid rule name: " + quote(startRule) + "."); - } - } else { - startRule = "body"; - } - - var pos = { offset: 0, line: 1, column: 1, seenCR: false }; - var reportFailures = 0; - var rightmostFailuresPos = { offset: 0, line: 1, column: 1, seenCR: false }; - var rightmostFailuresExpected = []; - - function padLeft(input, padding, length) { - var result = input; - - var padLength = length - input.length; - for (var i = 0; i < padLength; i++) { - result = padding + result; - } - - return result; - } - - function escape(ch) { - var charCode = ch.charCodeAt(0); - var escapeChar; - var length; - - if (charCode <= 0xFF) { - escapeChar = 'x'; - length = 2; - } else { - escapeChar = 'u'; - length = 4; - } - - return '\\' + escapeChar + padLeft(charCode.toString(16).toUpperCase(), '0', length); - } - - function clone(object) { - var result = {}; - for (var key in object) { - result[key] = object[key]; - } - return result; - } - - function advance(pos, n) { - var endOffset = pos.offset + n; - - for (var offset = pos.offset; offset < endOffset; offset++) { - var ch = input.charAt(offset); + + function SyntaxError(message, expected, found, offset, line, column) { + this.message = message; + this.expected = expected; + this.found = found; + this.offset = offset; + this.line = line; + this.column = column; + + this.name = "SyntaxError"; + } + + peg$subclass(SyntaxError, Error); + + function parse(input) { + var options = arguments.length > 1 ? arguments[1] : {}, + + peg$FAILED = {}, + + peg$startRuleFunctions = { start: peg$parsestart }, + peg$startRuleFunction = peg$parsestart, + + peg$c0 = [], + peg$c1 = function(p) { + return ["body"] + .concat(p) + .concat([['line', line()], ['col', column()]]); + }, + peg$c2 = { type: "other", description: "section" }, + peg$c3 = peg$FAILED, + peg$c4 = null, + peg$c5 = function(t, b, e, n) { + if( (!n) || (t[1].text !== n.text) ) { + error("Expected end tag for "+t[1].text+" but it was not found."); + } + return true; + }, + peg$c6 = void 0, + peg$c7 = function(t, b, e, n) { + e.push(["param", ["literal", "block"], b]); + t.push(e); + return t.concat([['line', line()], ['col', column()]]); + }, + peg$c8 = "/", + peg$c9 = { type: "literal", value: "/", description: "\"/\"" }, + peg$c10 = function(t) { + t.push(["bodies"]); + return t.concat([['line', line()], ['col', column()]]); + }, + peg$c11 = /^[#?\^<+@%]/, + peg$c12 = { type: "class", value: "[#?\\^<+@%]", description: "[#?\\^<+@%]" }, + peg$c13 = function(t, n, c, p) { return [t, n, c, p] }, + peg$c14 = { type: "other", description: "end tag" }, + peg$c15 = function(n) { return n }, + peg$c16 = ":", + peg$c17 = { type: "literal", value: ":", description: "\":\"" }, + peg$c18 = function(n) {return n}, + peg$c19 = function(n) { return n ? ["context", n] : ["context"] }, + peg$c20 = { type: "other", description: "params" }, + peg$c21 = "=", + peg$c22 = { type: "literal", value: "=", description: "\"=\"" }, + peg$c23 = function(k, v) {return ["param", ["literal", k], v]}, + peg$c24 = function(p) { return ["params"].concat(p) }, + peg$c25 = { type: "other", description: "bodies" }, + peg$c26 = function(p) { return ["bodies"].concat(p) }, + peg$c27 = { type: "other", description: "reference" }, + peg$c28 = function(n, f) { return ["reference", n, f].concat([['line', line()], ['col', column()]]) }, + peg$c29 = { type: "other", description: "partial" }, + peg$c30 = ">", + peg$c31 = { type: "literal", value: ">", description: "\">\"" }, + peg$c32 = "+", + peg$c33 = { type: "literal", value: "+", description: "\"+\"" }, + peg$c34 = function(k) {return ["literal", k]}, + peg$c35 = function(s, n, c, p) { + var key = (s === ">") ? "partial" : s; + return [key, n, c, p].concat([['line', line()], ['col', column()]]); + }, + peg$c36 = { type: "other", description: "filters" }, + peg$c37 = "|", + peg$c38 = { type: "literal", value: "|", description: "\"|\"" }, + peg$c39 = function(f) { return ["filters"].concat(f) }, + peg$c40 = { type: "other", description: "special" }, + peg$c41 = "~", + peg$c42 = { type: "literal", value: "~", description: "\"~\"" }, + peg$c43 = function(k) { return ["special", k].concat([['line', line()], ['col', column()]]) }, + peg$c44 = { type: "other", description: "identifier" }, + peg$c45 = function(p) { var arr = ["path"].concat(p); arr.text = p[1].join('.'); return arr; }, + peg$c46 = function(k) { var arr = ["key", k]; arr.text = k; return arr; }, + peg$c47 = { type: "other", description: "number" }, + peg$c48 = function(n) { return ['literal', n]; }, + peg$c49 = { type: "other", description: "float" }, + peg$c50 = ".", + peg$c51 = { type: "literal", value: ".", description: "\".\"" }, + peg$c52 = function(l, r) { return parseFloat(l + "." + r.join('')); }, + peg$c53 = { type: "other", description: "integer" }, + peg$c54 = /^[0-9]/, + peg$c55 = { type: "class", value: "[0-9]", description: "[0-9]" }, + peg$c56 = function(digits) { return parseInt(digits.join(""), 10); }, + peg$c57 = { type: "other", description: "path" }, + peg$c58 = function(k, d) { + d = d[0]; + if (k && d) { + d.unshift(k); + return [false, d].concat([['line', line()], ['col', column()]]); + } + return [true, d].concat([['line', line()], ['col', column()]]); + }, + peg$c59 = function(d) { + if (d.length > 0) { + return [true, d[0]].concat([['line', line()], ['col', column()]]); + } + return [true, []].concat([['line', line()], ['col', column()]]); + }, + peg$c60 = { type: "other", description: "key" }, + peg$c61 = /^[a-zA-Z_$]/, + peg$c62 = { type: "class", value: "[a-zA-Z_$]", description: "[a-zA-Z_$]" }, + peg$c63 = /^[0-9a-zA-Z_$\-]/, + peg$c64 = { type: "class", value: "[0-9a-zA-Z_$\\-]", description: "[0-9a-zA-Z_$\\-]" }, + peg$c65 = function(h, t) { return h + t.join('') }, + peg$c66 = { type: "other", description: "array" }, + peg$c67 = function(n) {return n.join('')}, + peg$c68 = function(a) {return a; }, + peg$c69 = function(i, nk) { if(nk) { nk.unshift(i); } else {nk = [i] } return nk; }, + peg$c70 = { type: "other", description: "array_part" }, + peg$c71 = function(k) {return k}, + peg$c72 = function(d, a) { if (a) { return d.concat(a); } else { return d; } }, + peg$c73 = { type: "other", description: "inline" }, + peg$c74 = "\"", + peg$c75 = { type: "literal", value: "\"", description: "\"\\\"\"" }, + peg$c76 = function() { return ["literal", ""].concat([['line', line()], ['col', column()]]) }, + peg$c77 = function(l) { return ["literal", l].concat([['line', line()], ['col', column()]]) }, + peg$c78 = function(p) { return ["body"].concat(p).concat([['line', line()], ['col', column()]]) }, + peg$c79 = function(l) { return ["buffer", l] }, + peg$c80 = { type: "other", description: "buffer" }, + peg$c81 = function(e, w) { return ["format", e, w.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c82 = { type: "any", description: "any character" }, + peg$c83 = function(c) {return c}, + peg$c84 = function(b) { return ["buffer", b.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c85 = { type: "other", description: "literal" }, + peg$c86 = /^[^"]/, + peg$c87 = { type: "class", value: "[^\"]", description: "[^\"]" }, + peg$c88 = function(b) { return b.join('') }, + peg$c89 = "\\\"", + peg$c90 = { type: "literal", value: "\\\"", description: "\"\\\\\\\"\"" }, + peg$c91 = function() { return '"' }, + peg$c92 = { type: "other", description: "raw" }, + peg$c93 = "{`", + peg$c94 = { type: "literal", value: "{`", description: "\"{`\"" }, + peg$c95 = "`}", + peg$c96 = { type: "literal", value: "`}", description: "\"`}\"" }, + peg$c97 = function(char) {return char}, + peg$c98 = function(rawText) { return ["raw", rawText.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c99 = { type: "other", description: "comment" }, + peg$c100 = "{!", + peg$c101 = { type: "literal", value: "{!", description: "\"{!\"" }, + peg$c102 = "!}", + peg$c103 = { type: "literal", value: "!}", description: "\"!}\"" }, + peg$c104 = function(c) { return ["comment", c.join('')].concat([['line', line()], ['col', column()]]) }, + peg$c105 = /^[#?\^><+%:@\/~%]/, + peg$c106 = { type: "class", value: "[#?\\^><+%:@\\/~%]", description: "[#?\\^><+%:@\\/~%]" }, + peg$c107 = "{", + peg$c108 = { type: "literal", value: "{", description: "\"{\"" }, + peg$c109 = "}", + peg$c110 = { type: "literal", value: "}", description: "\"}\"" }, + peg$c111 = "[", + peg$c112 = { type: "literal", value: "[", description: "\"[\"" }, + peg$c113 = "]", + peg$c114 = { type: "literal", value: "]", description: "\"]\"" }, + peg$c115 = "\n", + peg$c116 = { type: "literal", value: "\n", description: "\"\\n\"" }, + peg$c117 = "\r\n", + peg$c118 = { type: "literal", value: "\r\n", description: "\"\\r\\n\"" }, + peg$c119 = "\r", + peg$c120 = { type: "literal", value: "\r", description: "\"\\r\"" }, + peg$c121 = "\u2028", + peg$c122 = { type: "literal", value: "\u2028", description: "\"\\u2028\"" }, + peg$c123 = "\u2029", + peg$c124 = { type: "literal", value: "\u2029", description: "\"\\u2029\"" }, + peg$c125 = /^[\t\x0B\f \xA0\uFEFF]/, + peg$c126 = { type: "class", value: "[\\t\\x0B\\f \\xA0\\uFEFF]", description: "[\\t\\x0B\\f \\xA0\\uFEFF]" }, + + peg$currPos = 0, + peg$reportedPos = 0, + peg$cachedPos = 0, + peg$cachedPosDetails = { line: 1, column: 1, seenCR: false }, + peg$maxFailPos = 0, + peg$maxFailExpected = [], + peg$silentFails = 0, + + peg$result; + + if ("startRule" in options) { + if (!(options.startRule in peg$startRuleFunctions)) { + throw new Error("Can't start parsing from rule \"" + options.startRule + "\"."); + } + + peg$startRuleFunction = peg$startRuleFunctions[options.startRule]; + } + + function text() { + return input.substring(peg$reportedPos, peg$currPos); + } + + function offset() { + return peg$reportedPos; + } + + function line() { + return peg$computePosDetails(peg$reportedPos).line; + } + + function column() { + return peg$computePosDetails(peg$reportedPos).column; + } + + function expected(description) { + throw peg$buildException( + null, + [{ type: "other", description: description }], + peg$reportedPos + ); + } + + function error(message) { + throw peg$buildException(message, null, peg$reportedPos); + } + + function peg$computePosDetails(pos) { + function advance(details, startPos, endPos) { + var p, ch; + + for (p = startPos; p < endPos; p++) { + ch = input.charAt(p); if (ch === "\n") { - if (!pos.seenCR) { pos.line++; } - pos.column = 1; - pos.seenCR = false; + if (!details.seenCR) { details.line++; } + details.column = 1; + details.seenCR = false; } else if (ch === "\r" || ch === "\u2028" || ch === "\u2029") { - pos.line++; - pos.column = 1; - pos.seenCR = true; + details.line++; + details.column = 1; + details.seenCR = true; } else { - pos.column++; - pos.seenCR = false; + details.column++; + details.seenCR = false; } } - - pos.offset += n; } - - function matchFailed(failure) { - if (pos.offset < rightmostFailuresPos.offset) { - return; - } - - if (pos.offset > rightmostFailuresPos.offset) { - rightmostFailuresPos = clone(pos); - rightmostFailuresExpected = []; + + if (peg$cachedPos !== pos) { + if (peg$cachedPos > pos) { + peg$cachedPos = 0; + peg$cachedPosDetails = { line: 1, column: 1, seenCR: false }; } - - rightmostFailuresExpected.push(failure); - } - - function parse_body() { - var result0, result1; - var pos0; - - pos0 = clone(pos); - result0 = []; - result1 = parse_part(); - while (result1 !== null) { - result0.push(result1); - result1 = parse_part(); + advance(peg$cachedPosDetails, peg$cachedPos, pos); + peg$cachedPos = pos; + } + + return peg$cachedPosDetails; + } + + function peg$fail(expected) { + if (peg$currPos < peg$maxFailPos) { return; } + + if (peg$currPos > peg$maxFailPos) { + peg$maxFailPos = peg$currPos; + peg$maxFailExpected = []; + } + + peg$maxFailExpected.push(expected); + } + + function peg$buildException(message, expected, pos) { + function cleanupExpected(expected) { + var i = 1; + + expected.sort(function(a, b) { + if (a.description < b.description) { + return -1; + } else if (a.description > b.description) { + return 1; + } else { + return 0; + } + }); + + while (i < expected.length) { + if (expected[i - 1] === expected[i]) { + expected.splice(i, 1); + } else { + i++; + } } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["body"].concat(p).concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0); + } + + function buildMessage(expected, found) { + function stringEscape(s) { + function hex(ch) { return ch.charCodeAt(0).toString(16).toUpperCase(); } + + return s + .replace(/\\/g, '\\\\') + .replace(/"/g, '\\"') + .replace(/\x08/g, '\\b') + .replace(/\t/g, '\\t') + .replace(/\n/g, '\\n') + .replace(/\f/g, '\\f') + .replace(/\r/g, '\\r') + .replace(/[\x00-\x07\x0B\x0E\x0F]/g, function(ch) { return '\\x0' + hex(ch); }) + .replace(/[\x10-\x1F\x80-\xFF]/g, function(ch) { return '\\x' + hex(ch); }) + .replace(/[\u0180-\u0FFF]/g, function(ch) { return '\\u0' + hex(ch); }) + .replace(/[\u1080-\uFFFF]/g, function(ch) { return '\\u' + hex(ch); }); } - if (result0 === null) { - pos = clone(pos0); + + var expectedDescs = new Array(expected.length), + expectedDesc, foundDesc, i; + + for (i = 0; i < expected.length; i++) { + expectedDescs[i] = expected[i].description; } - return result0; - } - - function parse_part() { - var result0; - - result0 = parse_raw(); - if (result0 === null) { - result0 = parse_comment(); - if (result0 === null) { - result0 = parse_section(); - if (result0 === null) { - result0 = parse_partial(); - if (result0 === null) { - result0 = parse_special(); - if (result0 === null) { - result0 = parse_reference(); - if (result0 === null) { - result0 = parse_buffer(); - } + + expectedDesc = expected.length > 1 + ? expectedDescs.slice(0, -1).join(", ") + + " or " + + expectedDescs[expected.length - 1] + : expectedDescs[0]; + + foundDesc = found ? "\"" + stringEscape(found) + "\"" : "end of input"; + + return "Expected " + expectedDesc + " but " + foundDesc + " found."; + } + + var posDetails = peg$computePosDetails(pos), + found = pos < input.length ? input.charAt(pos) : null; + + if (expected !== null) { + cleanupExpected(expected); + } + + return new SyntaxError( + message !== null ? message : buildMessage(expected, found), + expected, + found, + pos, + posDetails.line, + posDetails.column + ); + } + + function peg$parsestart() { + var s0; + + s0 = peg$parsebody(); + + return s0; + } + + function peg$parsebody() { + var s0, s1, s2; + + s0 = peg$currPos; + s1 = []; + s2 = peg$parsepart(); + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$parsepart(); + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c1(s1); + } + s0 = s1; + + return s0; + } + + function peg$parsepart() { + var s0; + + s0 = peg$parseraw(); + if (s0 === peg$FAILED) { + s0 = peg$parsecomment(); + if (s0 === peg$FAILED) { + s0 = peg$parsesection(); + if (s0 === peg$FAILED) { + s0 = peg$parsepartial(); + if (s0 === peg$FAILED) { + s0 = peg$parsespecial(); + if (s0 === peg$FAILED) { + s0 = peg$parsereference(); + if (s0 === peg$FAILED) { + s0 = peg$parsebuffer(); } } } } } - return result0; - } - - function parse_section() { - var result0, result1, result2, result3, result4, result5, result6; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_sec_tag_start(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - result2 = parse_rd(); - if (result2 !== null) { - result3 = parse_body(); - if (result3 !== null) { - result4 = parse_bodies(); - if (result4 !== null) { - result5 = parse_end_tag(); - result5 = result5 !== null ? result5 : ""; - if (result5 !== null) { - result6 = (function(offset, line, column, t, b, e, n) {if( (!n) || (t[1].text !== n.text) ) { throw new Error("Expected end tag for "+t[1].text+" but it was not found. At line : "+line+", column : " + column)} return true;})(pos.offset, pos.line, pos.column, result0, result3, result4, result5) ? "" : null; - if (result6 !== null) { - result0 = [result0, result1, result2, result3, result4, result5, result6]; - } else { - result0 = null; - pos = clone(pos1); - } + } + + return s0; + } + + function peg$parsesection() { + var s0, s1, s2, s3, s4, s5, s6, s7; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsesec_tag_start(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + s3 = peg$parserd(); + if (s3 !== peg$FAILED) { + s4 = peg$parsebody(); + if (s4 !== peg$FAILED) { + s5 = peg$parsebodies(); + if (s5 !== peg$FAILED) { + s6 = peg$parseend_tag(); + if (s6 === peg$FAILED) { + s6 = peg$c4; + } + if (s6 !== peg$FAILED) { + peg$reportedPos = peg$currPos; + s7 = peg$c5(s1, s4, s5, s6); + if (s7) { + s7 = peg$c6; } else { - result0 = null; - pos = clone(pos1); + s7 = peg$c3; + } + if (s7 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c7(s1, s4, s5, s6); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, t, b, e, n) { e.push(["param", ["literal", "block"], b]); t.push(e); return t.concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[0], result0[3], result0[4], result0[5]); - } - if (result0 === null) { - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_sec_tag_start(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 47) { - result2 = "/"; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"/\""); - } - } - if (result2 !== null) { - result3 = parse_rd(); - if (result3 !== null) { - result0 = [result0, result1, result2, result3]; - } else { - result0 = null; - pos = clone(pos1); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = peg$parsesec_tag_start(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 47) { + s3 = peg$c8; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c9); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parserd(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c10(s1); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, t) { t.push(["bodies"]); return t.concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[0]); - } - if (result0 === null) { - pos = clone(pos0); - } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("section"); + } else { + peg$currPos = s0; + s0 = peg$c3; } - return result0; - } - - function parse_sec_tag_start() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1; - - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (/^[#?^<+@%]/.test(input.charAt(pos.offset))) { - result1 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("[#?^<+@%]"); - } - } - if (result1 !== null) { - result2 = []; - result3 = parse_ws(); - while (result3 !== null) { - result2.push(result3); - result3 = parse_ws(); - } - if (result2 !== null) { - result3 = parse_identifier(); - if (result3 !== null) { - result4 = parse_context(); - if (result4 !== null) { - result5 = parse_params(); - if (result5 !== null) { - result0 = [result0, result1, result2, result3, result4, result5]; - } else { - result0 = null; - pos = clone(pos1); - } + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c2); } + } + + return s0; + } + + function peg$parsesec_tag_start() { + var s0, s1, s2, s3, s4, s5, s6; + + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (peg$c11.test(input.charAt(peg$currPos))) { + s2 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c12); } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parsews(); + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + if (s3 !== peg$FAILED) { + s4 = peg$parseidentifier(); + if (s4 !== peg$FAILED) { + s5 = peg$parsecontext(); + if (s5 !== peg$FAILED) { + s6 = peg$parseparams(); + if (s6 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c13(s2, s4, s5, s6); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, t, n, c, p) { return [t, n, c, p] })(pos0.offset, pos0.line, pos0.column, result0[1], result0[3], result0[4], result0[5]); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_end_tag() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 47) { - result1 = "/"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"/\""); - } - } - if (result1 !== null) { - result2 = []; - result3 = parse_ws(); - while (result3 !== null) { - result2.push(result3); - result3 = parse_ws(); - } - if (result2 !== null) { - result3 = parse_identifier(); - if (result3 !== null) { - result4 = []; - result5 = parse_ws(); - while (result5 !== null) { - result4.push(result5); - result5 = parse_ws(); - } - if (result4 !== null) { - result5 = parse_rd(); - if (result5 !== null) { - result0 = [result0, result1, result2, result3, result4, result5]; - } else { - result0 = null; - pos = clone(pos1); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + + return s0; + } + + function peg$parseend_tag() { + var s0, s1, s2, s3, s4, s5, s6; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 47) { + s2 = peg$c8; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c9); } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parsews(); + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + if (s3 !== peg$FAILED) { + s4 = peg$parseidentifier(); + if (s4 !== peg$FAILED) { + s5 = []; + s6 = peg$parsews(); + while (s6 !== peg$FAILED) { + s5.push(s6); + s6 = peg$parsews(); + } + if (s5 !== peg$FAILED) { + s6 = peg$parserd(); + if (s6 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c15(s4); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n) { return n })(pos0.offset, pos0.line, pos0.column, result0[3]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("end tag"); - } - return result0; - } - - function parse_context() { - var result0, result1; - var pos0, pos1, pos2; - - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - if (input.charCodeAt(pos.offset) === 58) { - result0 = ":"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\":\""); - } + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result1 = parse_identifier(); - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos2); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c14); } + } + + return s0; + } + + function peg$parsecontext() { + var s0, s1, s2, s3; + + s0 = peg$currPos; + s1 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 58) { + s2 = peg$c16; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c17); } + } + if (s2 !== peg$FAILED) { + s3 = peg$parseidentifier(); + if (s3 !== peg$FAILED) { + peg$reportedPos = s1; + s2 = peg$c18(s3); + s1 = s2; } else { - result0 = null; - pos = clone(pos2); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n) {return n})(pos1.offset, pos1.line, pos1.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos1); + peg$currPos = s1; + s1 = peg$c3; } - result0 = result0 !== null ? result0 : ""; - if (result0 !== null) { - result0 = (function(offset, line, column, n) { return n ? ["context", n] : ["context"] })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_params() { - var result0, result1, result2, result3, result4; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - result0 = []; - pos1 = clone(pos); - pos2 = clone(pos); - result2 = parse_ws(); - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - } else { - result1 = null; + } else { + peg$currPos = s1; + s1 = peg$c3; + } + if (s1 === peg$FAILED) { + s1 = peg$c4; + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c19(s1); + } + s0 = s1; + + return s0; + } + + function peg$parseparams() { + var s0, s1, s2, s3, s4, s5, s6; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = []; + s4 = peg$parsews(); + if (s4 !== peg$FAILED) { + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - if (input.charCodeAt(pos.offset) === 61) { - result3 = "="; - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("\"=\""); + } else { + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 61) { + s5 = peg$c21; + peg$currPos++; + } else { + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c22); } + } + if (s5 !== peg$FAILED) { + s6 = peg$parsenumber(); + if (s6 === peg$FAILED) { + s6 = peg$parseidentifier(); + if (s6 === peg$FAILED) { + s6 = peg$parseinline(); } } - if (result3 !== null) { - result4 = parse_number(); - if (result4 === null) { - result4 = parse_identifier(); - if (result4 === null) { - result4 = parse_inline(); - } - } - if (result4 !== null) { - result1 = [result1, result2, result3, result4]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s6 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s4, s6); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[1], result1[3]); + peg$currPos = s2; + s2 = peg$c3; } - if (result1 === null) { - pos = clone(pos1); - } - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - result2 = parse_ws(); - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - } else { - result1 = null; + } else { + peg$currPos = s2; + s2 = peg$c3; + } + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = []; + s4 = peg$parsews(); + if (s4 !== peg$FAILED) { + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - if (input.charCodeAt(pos.offset) === 61) { - result3 = "="; - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("\"=\""); + } else { + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 61) { + s5 = peg$c21; + peg$currPos++; + } else { + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c22); } + } + if (s5 !== peg$FAILED) { + s6 = peg$parsenumber(); + if (s6 === peg$FAILED) { + s6 = peg$parseidentifier(); + if (s6 === peg$FAILED) { + s6 = peg$parseinline(); } } - if (result3 !== null) { - result4 = parse_number(); - if (result4 === null) { - result4 = parse_identifier(); - if (result4 === null) { - result4 = parse_inline(); - } - } - if (result4 !== null) { - result1 = [result1, result2, result3, result4]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s6 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s4, s6); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[1], result1[3]); + peg$currPos = s2; + s2 = peg$c3; } - if (result1 === null) { - pos = clone(pos1); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["params"].concat(p) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("params"); + } else { + peg$currPos = s2; + s2 = peg$c3; } - return result0; - } - - function parse_bodies() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - result0 = []; - pos1 = clone(pos); - pos2 = clone(pos); - result1 = parse_ld(); - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 58) { - result2 = ":"; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\":\""); - } - } - if (result2 !== null) { - result3 = parse_key(); - if (result3 !== null) { - result4 = parse_rd(); - if (result4 !== null) { - result5 = parse_body(); - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c24(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c20); } + } + + return s0; + } + + function peg$parsebodies() { + var s0, s1, s2, s3, s4, s5, s6, s7; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = peg$parseld(); + if (s3 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 58) { + s4 = peg$c16; + peg$currPos++; + } else { + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c17); } + } + if (s4 !== peg$FAILED) { + s5 = peg$parsekey(); + if (s5 !== peg$FAILED) { + s6 = peg$parserd(); + if (s6 !== peg$FAILED) { + s7 = peg$parsebody(); + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s5, s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[2], result1[4]); + peg$currPos = s2; + s2 = peg$c3; } - if (result1 === null) { - pos = clone(pos1); - } - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - result1 = parse_ld(); - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 58) { - result2 = ":"; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\":\""); - } - } - if (result2 !== null) { - result3 = parse_key(); - if (result3 !== null) { - result4 = parse_rd(); - if (result4 !== null) { - result5 = parse_body(); - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = peg$parseld(); + if (s3 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 58) { + s4 = peg$c16; + peg$currPos++; + } else { + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c17); } + } + if (s4 !== peg$FAILED) { + s5 = peg$parsekey(); + if (s5 !== peg$FAILED) { + s6 = peg$parserd(); + if (s6 !== peg$FAILED) { + s7 = peg$parsebody(); + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c23(s5, s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k, v) {return ["param", ["literal", k], v]})(pos1.offset, pos1.line, pos1.column, result1[2], result1[4]); - } - if (result1 === null) { - pos = clone(pos1); + peg$currPos = s2; + s2 = peg$c3; } + } else { + peg$currPos = s2; + s2 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["bodies"].concat(p) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("bodies"); - } - return result0; - } - - function parse_reference() { - var result0, result1, result2, result3; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - result1 = parse_identifier(); - if (result1 !== null) { - result2 = parse_filters(); - if (result2 !== null) { - result3 = parse_rd(); - if (result3 !== null) { - result0 = [result0, result1, result2, result3]; - } else { - result0 = null; - pos = clone(pos1); - } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c26(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c25); } + } + + return s0; + } + + function peg$parsereference() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + s2 = peg$parseidentifier(); + if (s2 !== peg$FAILED) { + s3 = peg$parsefilters(); + if (s3 !== peg$FAILED) { + s4 = peg$parserd(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c28(s2, s3); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, n, f) { return ["reference", n, f].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1], result0[2]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("reference"); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c27); } + } + + return s0; + } + + function peg$parsepartial() { + var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 62) { + s2 = peg$c30; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c31); } } - return result0; - } - - function parse_partial() { - var result0, result1, result2, result3, result4, result5, result6, result7, result8; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 62) { - result1 = ">"; - advance(pos, 1); + if (s2 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 43) { + s2 = peg$c32; + peg$currPos++; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\">\""); - } - } - if (result1 === null) { - if (input.charCodeAt(pos.offset) === 43) { - result1 = "+"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"+\""); - } - } - } - if (result1 !== null) { - result2 = []; - result3 = parse_ws(); - while (result3 !== null) { - result2.push(result3); - result3 = parse_ws(); - } - if (result2 !== null) { - pos2 = clone(pos); - result3 = parse_key(); - if (result3 !== null) { - result3 = (function(offset, line, column, k) {return ["literal", k]})(pos2.offset, pos2.line, pos2.column, result3); - } - if (result3 === null) { - pos = clone(pos2); - } - if (result3 === null) { - result3 = parse_inline(); - } - if (result3 !== null) { - result4 = parse_context(); - if (result4 !== null) { - result5 = parse_params(); - if (result5 !== null) { - result6 = []; - result7 = parse_ws(); - while (result7 !== null) { - result6.push(result7); - result7 = parse_ws(); + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c33); } + } + } + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parsews(); + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parsews(); + } + if (s3 !== peg$FAILED) { + s4 = peg$currPos; + s5 = peg$parsekey(); + if (s5 !== peg$FAILED) { + peg$reportedPos = s4; + s5 = peg$c34(s5); + } + s4 = s5; + if (s4 === peg$FAILED) { + s4 = peg$parseinline(); + } + if (s4 !== peg$FAILED) { + s5 = peg$parsecontext(); + if (s5 !== peg$FAILED) { + s6 = peg$parseparams(); + if (s6 !== peg$FAILED) { + s7 = []; + s8 = peg$parsews(); + while (s8 !== peg$FAILED) { + s7.push(s8); + s8 = peg$parsews(); + } + if (s7 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 47) { + s8 = peg$c8; + peg$currPos++; + } else { + s8 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c9); } } - if (result6 !== null) { - if (input.charCodeAt(pos.offset) === 47) { - result7 = "/"; - advance(pos, 1); - } else { - result7 = null; - if (reportFailures === 0) { - matchFailed("\"/\""); - } - } - if (result7 !== null) { - result8 = parse_rd(); - if (result8 !== null) { - result0 = [result0, result1, result2, result3, result4, result5, result6, result7, result8]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s8 !== peg$FAILED) { + s9 = peg$parserd(); + if (s9 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c35(s2, s4, s5, s6); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, s, n, c, p) { var key = (s ===">")? "partial" : s; return [key, n, c, p].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1], result0[3], result0[4], result0[5]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("partial"); - } - return result0; - } - - function parse_filters() { - var result0, result1, result2; - var pos0, pos1, pos2; - - reportFailures++; - pos0 = clone(pos); - result0 = []; - pos1 = clone(pos); - pos2 = clone(pos); - if (input.charCodeAt(pos.offset) === 124) { - result1 = "|"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"|\""); - } - } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos2); - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c29); } + } + + return s0; + } + + function peg$parsefilters() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 124) { + s3 = peg$c37; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c38); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c18(s4); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, n) {return n})(pos1.offset, pos1.line, pos1.column, result1[1]); + peg$currPos = s2; + s2 = peg$c3; } - if (result1 === null) { - pos = clone(pos1); - } - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - if (input.charCodeAt(pos.offset) === 124) { - result1 = "|"; - advance(pos, 1); + } else { + peg$currPos = s2; + s2 = peg$c3; + } + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 124) { + s3 = peg$c37; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c38); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c18(s4); + s2 = s3; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"|\""); - } + peg$currPos = s2; + s2 = peg$c3; } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; + } else { + peg$currPos = s2; + s2 = peg$c3; + } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c39(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c36); } + } + + return s0; + } + + function peg$parsespecial() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 126) { + s2 = peg$c41; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c42); } + } + if (s2 !== peg$FAILED) { + s3 = peg$parsekey(); + if (s3 !== peg$FAILED) { + s4 = peg$parserd(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c43(s3); + s0 = s1; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s0; + s0 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, n) {return n})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } + } else { + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, f) { return ["filters"].concat(f) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c40); } + } + + return s0; + } + + function peg$parseidentifier() { + var s0, s1; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsepath(); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c45(s1); + } + s0 = s1; + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = peg$parsekey(); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c46(s1); } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("filters"); + s0 = s1; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c44); } + } + + return s0; + } + + function peg$parsenumber() { + var s0, s1; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsefloat(); + if (s1 === peg$FAILED) { + s1 = peg$parseinteger(); + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c48(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c47); } + } + + return s0; + } + + function peg$parsefloat() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseinteger(); + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 46) { + s2 = peg$c50; + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } } - return result0; - } - - function parse_special() { - var result0, result1, result2, result3; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 126) { - result1 = "~"; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"~\""); + if (s2 !== peg$FAILED) { + s3 = []; + s4 = peg$parseinteger(); + if (s4 !== peg$FAILED) { + while (s4 !== peg$FAILED) { + s3.push(s4); + s4 = peg$parseinteger(); } + } else { + s3 = peg$c3; } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result3 = parse_rd(); - if (result3 !== null) { - result0 = [result0, result1, result2, result3]; - } else { - result0 = null; - pos = clone(pos1); - } - } else { - result0 = null; - pos = clone(pos1); - } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c52(s1, s3); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, k) { return ["special", k].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[2]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("special"); + peg$currPos = s0; + s0 = peg$c3; } - return result0; - } - - function parse_identifier() { - var result0; - var pos0; - - reportFailures++; - pos0 = clone(pos); - result0 = parse_path(); - if (result0 !== null) { - result0 = (function(offset, line, column, p) { var arr = ["path"].concat(p); arr.text = p[1].join('.'); return arr; })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - result0 = parse_key(); - if (result0 !== null) { - result0 = (function(offset, line, column, k) { var arr = ["key", k]; arr.text = k; return arr; })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c49); } + } + + return s0; + } + + function peg$parseinteger() { + var s0, s1, s2; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + if (peg$c54.test(input.charAt(peg$currPos))) { + s2 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + if (peg$c54.test(input.charAt(peg$currPos))) { + s2 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } } } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("identifier"); - } - return result0; - } - - function parse_number() { - var result0; - var pos0; - - reportFailures++; - pos0 = clone(pos); - result0 = parse_float(); - if (result0 === null) { - result0 = parse_integer(); - } - if (result0 !== null) { - result0 = (function(offset, line, column, n) { return ['literal', n]; })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("number"); + } else { + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c56(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c53); } + } + + return s0; + } + + function peg$parsepath() { + var s0, s1, s2, s3; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parsekey(); + if (s1 === peg$FAILED) { + s1 = peg$c4; + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); } - return result0; - } - - function parse_float() { - var result0, result1, result2, result3; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_integer(); - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 46) { - result1 = "."; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } - } - if (result1 !== null) { - result3 = parse_integer(); - if (result3 !== null) { - result2 = []; - while (result3 !== null) { - result2.push(result3); - result3 = parse_integer(); - } - } else { - result2 = null; - } - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos1); + if (s3 !== peg$FAILED) { + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); } - } else { - result0 = null; - pos = clone(pos1); } } else { - result0 = null; - pos = clone(pos1); + s2 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, l, r) { return parseFloat(l + "." + r.join('')); })(pos0.offset, pos0.line, pos0.column, result0[0], result0[2]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("float"); - } - return result0; - } - - function parse_integer() { - var result0, result1; - var pos0; - - reportFailures++; - pos0 = clone(pos); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result1 = input.charAt(pos.offset); - advance(pos, 1); + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c58(s1, s2); + s0 = s1; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } + peg$currPos = s0; + s0 = peg$c3; } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result1 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - } + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 46) { + s1 = peg$c50; + peg$currPos++; } else { - result0 = null; - } - if (result0 !== null) { - result0 = (function(offset, line, column, digits) { return parseInt(digits.join(""), 10); })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("integer"); - } - return result0; - } - - function parse_path() { - var result0, result1, result2; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_key(); - result0 = result0 !== null ? result0 : ""; - if (result0 !== null) { - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - } + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); + } + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsearray_part(); + if (s3 === peg$FAILED) { + s3 = peg$parsearray(); + } + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c59(s2); + s0 = s1; } else { - result1 = null; - } - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, k, d) { - d = d[0]; - if (k && d) { - d.unshift(k); - return [false, d].concat([['line', line], ['col', column]]); - } - return [true, d].concat([['line', line], ['col', column]]); - })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 46) { - result0 = "."; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } - } - if (result0 !== null) { - result1 = []; - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - while (result2 !== null) { - result1.push(result2); - result2 = parse_array_part(); - if (result2 === null) { - result2 = parse_array(); - } - } - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); - } + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c57); } + } + + return s0; + } + + function peg$parsekey() { + var s0, s1, s2, s3; + + peg$silentFails++; + s0 = peg$currPos; + if (peg$c61.test(input.charAt(peg$currPos))) { + s1 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c62); } + } + if (s1 !== peg$FAILED) { + s2 = []; + if (peg$c63.test(input.charAt(peg$currPos))) { + s3 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c64); } + } + while (s3 !== peg$FAILED) { + s2.push(s3); + if (peg$c63.test(input.charAt(peg$currPos))) { + s3 = input.charAt(peg$currPos); + peg$currPos++; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, d) { - if (d.length > 0) { - return [true, d[0]].concat([['line', line], ['col', column]]); - } - return [true, []].concat([['line', line], ['col', column]]); - })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c64); } } } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("path"); - } - return result0; - } - - function parse_key() { - var result0, result1, result2; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (/^[a-zA-Z_$]/.test(input.charAt(pos.offset))) { - result0 = input.charAt(pos.offset); - advance(pos, 1); + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c65(s1, s2); + s0 = s1; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("[a-zA-Z_$]"); - } + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result1 = []; - if (/^[0-9a-zA-Z_$\-]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9a-zA-Z_$\\-]"); - } - } - while (result2 !== null) { - result1.push(result2); - if (/^[0-9a-zA-Z_$\-]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c60); } + } + + return s0; + } + + function peg$parsearray() { + var s0, s1, s2, s3, s4, s5; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$currPos; + s2 = peg$parselb(); + if (s2 !== peg$FAILED) { + s3 = peg$currPos; + s4 = []; + if (peg$c54.test(input.charAt(peg$currPos))) { + s5 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } + } + if (s5 !== peg$FAILED) { + while (s5 !== peg$FAILED) { + s4.push(s5); + if (peg$c54.test(input.charAt(peg$currPos))) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9a-zA-Z_$\\-]"); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c55); } } } - if (result1 !== null) { - result0 = [result0, result1]; + } else { + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c67(s4); + } + s3 = s4; + if (s3 === peg$FAILED) { + s3 = peg$parseidentifier(); + } + if (s3 !== peg$FAILED) { + s4 = peg$parserb(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s1; + s2 = peg$c68(s3); + s1 = s2; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s1; + s1 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, h, t) { return h + t.join('') })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); + peg$currPos = s1; + s1 = peg$c3; } - if (result0 === null) { - pos = clone(pos0); + } else { + peg$currPos = s1; + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + s2 = peg$parsearray_part(); + if (s2 === peg$FAILED) { + s2 = peg$c4; + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c69(s1, s2); + s0 = s1; + } else { + peg$currPos = s0; + s0 = peg$c3; } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("key"); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c66); } + } + + return s0; + } + + function peg$parsearray_part() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 46) { + s3 = peg$c50; + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c71(s4); + s2 = s3; + } else { + peg$currPos = s2; + s2 = peg$c3; } - return result0; - } - - function parse_array() { - var result0, result1, result2; - var pos0, pos1, pos2, pos3, pos4; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - result0 = parse_lb(); - if (result0 !== null) { - pos4 = clone(pos); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - if (/^[0-9]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[0-9]"); - } - } - } + } else { + peg$currPos = s2; + s2 = peg$c3; + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 46) { + s3 = peg$c50; + peg$currPos++; } else { - result1 = null; - } - if (result1 !== null) { - result1 = (function(offset, line, column, n) {return n.join('')})(pos4.offset, pos4.line, pos4.column, result1); - } - if (result1 === null) { - pos = clone(pos4); - } - if (result1 === null) { - result1 = parse_identifier(); - } - if (result1 !== null) { - result2 = parse_rb(); - if (result2 !== null) { - result0 = [result0, result1, result2]; + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c51); } + } + if (s3 !== peg$FAILED) { + s4 = peg$parsekey(); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c71(s4); + s2 = s3; } else { - result0 = null; - pos = clone(pos3); + peg$currPos = s2; + s2 = peg$c3; } } else { - result0 = null; - pos = clone(pos3); + peg$currPos = s2; + s2 = peg$c3; } - } else { - result0 = null; - pos = clone(pos3); - } - if (result0 !== null) { - result0 = (function(offset, line, column, a) {return a; })(pos2.offset, pos2.line, pos2.column, result0[1]); } - if (result0 === null) { - pos = clone(pos2); + } else { + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + s2 = peg$parsearray(); + if (s2 === peg$FAILED) { + s2 = peg$c4; } - if (result0 !== null) { - result1 = parse_array_part(); - result1 = result1 !== null ? result1 : ""; - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c72(s1, s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, i, nk) { if(nk) { nk.unshift(i); } else {nk = [i] } return nk; })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("array"); - } - return result0; - } - - function parse_array_part() { - var result0, result1, result2; - var pos0, pos1, pos2, pos3; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - if (input.charCodeAt(pos.offset) === 46) { - result1 = "."; - advance(pos, 1); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c70); } + } + + return s0; + } + + function peg$parseinline() { + var s0, s1, s2, s3; + + peg$silentFails++; + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 34) { + s1 = peg$c74; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } + } + if (s1 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 34) { + s2 = peg$c74; + peg$currPos++; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } + s2 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos3); - } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c76(); + s0 = s1; } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k) {return k})(pos2.offset, pos2.line, pos2.column, result1[1]); + peg$currPos = s0; + s0 = peg$c3; } - if (result1 === null) { - pos = clone(pos2); - } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - pos2 = clone(pos); - pos3 = clone(pos); - if (input.charCodeAt(pos.offset) === 46) { - result1 = "."; - advance(pos, 1); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 34) { + s1 = peg$c74; + peg$currPos++; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } + } + if (s1 !== peg$FAILED) { + s2 = peg$parseliteral(); + if (s2 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 34) { + s3 = peg$c74; + peg$currPos++; } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\".\""); - } + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } } - if (result1 !== null) { - result2 = parse_key(); - if (result2 !== null) { - result1 = [result1, result2]; - } else { - result1 = null; - pos = clone(pos3); - } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c77(s2); + s0 = s1; } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result1 = (function(offset, line, column, k) {return k})(pos2.offset, pos2.line, pos2.column, result1[1]); + peg$currPos = s0; + s0 = peg$c3; } - if (result1 === null) { - pos = clone(pos2); - } - } - } else { - result0 = null; - } - if (result0 !== null) { - result1 = parse_array(); - result1 = result1 !== null ? result1 : ""; - if (result1 !== null) { - result0 = [result0, result1]; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, d, a) { if (a) { return d.concat(a); } else { return d; } })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("array_part"); - } - return result0; - } - - function parse_inline() { - var result0, result1, result2; - var pos0, pos1; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 34) { - result0 = "\""; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } - } - if (result0 !== null) { - if (input.charCodeAt(pos.offset) === 34) { - result1 = "\""; - advance(pos, 1); - } else { - result1 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } - } - if (result1 !== null) { - result0 = [result0, result1]; + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + if (input.charCodeAt(peg$currPos) === 34) { + s1 = peg$c74; + peg$currPos++; } else { - result0 = null; - pos = clone(pos1); - } - } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column) { return ["literal", ""].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 34) { - result0 = "\""; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } - } - if (result0 !== null) { - result1 = parse_literal(); - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 34) { - result2 = "\""; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } - } - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos1); + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parseinline_part(); + if (s3 !== peg$FAILED) { + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parseinline_part(); } } else { - result0 = null; - pos = clone(pos1); - } - } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, l) { return ["literal", l].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - if (input.charCodeAt(pos.offset) === 34) { - result0 = "\""; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } + s2 = peg$c3; } - if (result0 !== null) { - result2 = parse_inline_part(); - if (result2 !== null) { - result1 = []; - while (result2 !== null) { - result1.push(result2); - result2 = parse_inline_part(); - } + if (s2 !== peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 34) { + s3 = peg$c74; + peg$currPos++; } else { - result1 = null; + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c75); } } - if (result1 !== null) { - if (input.charCodeAt(pos.offset) === 34) { - result2 = "\""; - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"\\\"\""); - } - } - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos1); - } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c78(s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, p) { return ["body"].concat(p).concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } + } else { + peg$currPos = s0; + s0 = peg$c3; } } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("inline"); - } - return result0; - } - - function parse_inline_part() { - var result0; - var pos0; - - result0 = parse_special(); - if (result0 === null) { - result0 = parse_reference(); - if (result0 === null) { - pos0 = clone(pos); - result0 = parse_literal(); - if (result0 !== null) { - result0 = (function(offset, line, column, l) { return ["buffer", l] })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c73); } + } + + return s0; + } + + function peg$parseinline_part() { + var s0, s1; + + s0 = peg$parsespecial(); + if (s0 === peg$FAILED) { + s0 = peg$parsereference(); + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = peg$parseliteral(); + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c79(s1); } + s0 = s1; } - return result0; - } - - function parse_buffer() { - var result0, result1, result2, result3, result4, result5; - var pos0, pos1, pos2, pos3; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - result0 = parse_eol(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - result0 = [result0, result1]; - } else { - result0 = null; - pos = clone(pos1); - } + } + + return s0; + } + + function peg$parsebuffer() { + var s0, s1, s2, s3, s4, s5, s6, s7; + + peg$silentFails++; + s0 = peg$currPos; + s1 = peg$parseeol(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c81(s1, s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); - } - if (result0 !== null) { - result0 = (function(offset, line, column, e, w) { return ["format", e, w.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[0], result0[1]); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 === null) { - pos = clone(pos0); - } - if (result0 === null) { - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$currPos; + peg$silentFails++; + s5 = peg$parseraw(); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - pos3 = clone(pos); - reportFailures++; - result2 = parse_raw(); - reportFailures--; - if (result2 === null) { - result2 = ""; + peg$currPos = s4; + s4 = peg$c3; + } + if (s4 !== peg$FAILED) { + s5 = peg$currPos; + peg$silentFails++; + s6 = peg$parsecomment(); + peg$silentFails--; + if (s6 === peg$FAILED) { + s5 = peg$c6; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - pos3 = clone(pos); - reportFailures++; - result3 = parse_comment(); - reportFailures--; - if (result3 === null) { - result3 = ""; + peg$currPos = s5; + s5 = peg$c3; + } + if (s5 !== peg$FAILED) { + s6 = peg$currPos; + peg$silentFails++; + s7 = peg$parseeol(); + peg$silentFails--; + if (s7 === peg$FAILED) { + s6 = peg$c6; } else { - result3 = null; - pos = clone(pos3); + peg$currPos = s6; + s6 = peg$c3; } - if (result3 !== null) { - pos3 = clone(pos); - reportFailures++; - result4 = parse_eol(); - reportFailures--; - if (result4 === null) { - result4 = ""; + if (s6 !== peg$FAILED) { + if (input.length > peg$currPos) { + s7 = input.charAt(peg$currPos); + peg$currPos++; } else { - result4 = null; - pos = clone(pos3); + s7 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c82); } } - if (result4 !== null) { - if (input.length > pos.offset) { - result5 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result5 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c83(s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[4]); - } - if (result1 === null) { - pos = clone(pos1); + peg$currPos = s2; + s2 = peg$c3; } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; + } else { + peg$currPos = s2; + s2 = peg$c3; + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$currPos; + peg$silentFails++; + s5 = peg$parseraw(); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result1 = null; - pos = clone(pos3); + peg$currPos = s4; + s4 = peg$c3; } - if (result1 !== null) { - pos3 = clone(pos); - reportFailures++; - result2 = parse_raw(); - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s4 !== peg$FAILED) { + s5 = peg$currPos; + peg$silentFails++; + s6 = peg$parsecomment(); + peg$silentFails--; + if (s6 === peg$FAILED) { + s5 = peg$c6; } else { - result2 = null; - pos = clone(pos3); + peg$currPos = s5; + s5 = peg$c3; } - if (result2 !== null) { - pos3 = clone(pos); - reportFailures++; - result3 = parse_comment(); - reportFailures--; - if (result3 === null) { - result3 = ""; + if (s5 !== peg$FAILED) { + s6 = peg$currPos; + peg$silentFails++; + s7 = peg$parseeol(); + peg$silentFails--; + if (s7 === peg$FAILED) { + s6 = peg$c6; } else { - result3 = null; - pos = clone(pos3); + peg$currPos = s6; + s6 = peg$c3; } - if (result3 !== null) { - pos3 = clone(pos); - reportFailures++; - result4 = parse_eol(); - reportFailures--; - if (result4 === null) { - result4 = ""; + if (s6 !== peg$FAILED) { + if (input.length > peg$currPos) { + s7 = input.charAt(peg$currPos); + peg$currPos++; } else { - result4 = null; - pos = clone(pos3); + s7 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c82); } } - if (result4 !== null) { - if (input.length > pos.offset) { - result5 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result5 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result5 !== null) { - result1 = [result1, result2, result3, result4, result5]; - } else { - result1 = null; - pos = clone(pos2); - } + if (s7 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c83(s7); + s2 = s3; } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); + peg$currPos = s2; + s2 = peg$c3; } } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[4]); - } - if (result1 === null) { - pos = clone(pos1); + peg$currPos = s2; + s2 = peg$c3; } + } else { + peg$currPos = s2; + s2 = peg$c3; } - } else { - result0 = null; - } - if (result0 !== null) { - result0 = (function(offset, line, column, b) { return ["buffer", b.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); } - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("buffer"); - } - return result0; - } - - function parse_literal() { - var result0, result1, result2; - var pos0, pos1, pos2, pos3; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; } else { - result1 = null; - pos = clone(pos3); + s1 = peg$c3; } - if (result1 !== null) { - result2 = parse_esc(); - if (result2 === null) { - if (/^[^"]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[^\"]"); - } - } - } - if (result2 !== null) { - result1 = [result1, result2]; + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c84(s1); + } + s0 = s1; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c80); } + } + + return s0; + } + + function peg$parseliteral() { + var s0, s1, s2, s3, s4; + + peg$silentFails++; + s0 = peg$currPos; + s1 = []; + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parseesc(); + if (s4 === peg$FAILED) { + if (peg$c86.test(input.charAt(peg$currPos))) { + s4 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - pos = clone(pos2); + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c87); } } - } else { - result1 = null; - pos = clone(pos2); } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[1]); - } - if (result1 === null) { - pos = clone(pos1); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c83(s4); + s2 = s3; + } else { + peg$currPos = s2; + s2 = peg$c3; } - if (result1 !== null) { - result0 = []; - while (result1 !== null) { - result0.push(result1); - pos1 = clone(pos); - pos2 = clone(pos); - pos3 = clone(pos); - reportFailures++; - result1 = parse_tag(); - reportFailures--; - if (result1 === null) { - result1 = ""; - } else { - result1 = null; - pos = clone(pos3); - } - if (result1 !== null) { - result2 = parse_esc(); - if (result2 === null) { - if (/^[^"]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[^\"]"); - } - } - } - if (result2 !== null) { - result1 = [result1, result2]; + } else { + peg$currPos = s2; + s2 = peg$c3; + } + if (s2 !== peg$FAILED) { + while (s2 !== peg$FAILED) { + s1.push(s2); + s2 = peg$currPos; + s3 = peg$currPos; + peg$silentFails++; + s4 = peg$parsetag(); + peg$silentFails--; + if (s4 === peg$FAILED) { + s3 = peg$c6; + } else { + peg$currPos = s3; + s3 = peg$c3; + } + if (s3 !== peg$FAILED) { + s4 = peg$parseesc(); + if (s4 === peg$FAILED) { + if (peg$c86.test(input.charAt(peg$currPos))) { + s4 = input.charAt(peg$currPos); + peg$currPos++; } else { - result1 = null; - pos = clone(pos2); + s4 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c87); } } - } else { - result1 = null; - pos = clone(pos2); - } - if (result1 !== null) { - result1 = (function(offset, line, column, c) {return c})(pos1.offset, pos1.line, pos1.column, result1[1]); } - if (result1 === null) { - pos = clone(pos1); + if (s4 !== peg$FAILED) { + peg$reportedPos = s2; + s3 = peg$c83(s4); + s2 = s3; + } else { + peg$currPos = s2; + s2 = peg$c3; } + } else { + peg$currPos = s2; + s2 = peg$c3; } - } else { - result0 = null; - } - if (result0 !== null) { - result0 = (function(offset, line, column, b) { return b.join('') })(pos0.offset, pos0.line, pos0.column, result0); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("literal"); } - return result0; - } - - function parse_esc() { - var result0; - var pos0; - - pos0 = clone(pos); - if (input.substr(pos.offset, 2) === "\\\"") { - result0 = "\\\""; - advance(pos, 2); + } else { + s1 = peg$c3; + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c88(s1); + } + s0 = s1; + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c85); } + } + + return s0; + } + + function peg$parseesc() { + var s0, s1; + + s0 = peg$currPos; + if (input.substr(peg$currPos, 2) === peg$c89) { + s1 = peg$c89; + peg$currPos += 2; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c90); } + } + if (s1 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c91(); + } + s0 = s1; + + return s0; + } + + function peg$parseraw() { + var s0, s1, s2, s3, s4, s5; + + peg$silentFails++; + s0 = peg$currPos; + if (input.substr(peg$currPos, 2) === peg$c93) { + s1 = peg$c93; + peg$currPos += 2; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c94); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c95) { + s5 = peg$c95; + peg$currPos += 2; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\\\\\\"\""); - } - } - if (result0 !== null) { - result0 = (function(offset, line, column) { return '"' })(pos0.offset, pos0.line, pos0.column); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c96); } } - if (result0 === null) { - pos = clone(pos0); - } - return result0; - } - - function parse_raw() { - var result0, result1, result2, result3; - var pos0, pos1, pos2, pos3, pos4; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (input.substr(pos.offset, 2) === "{`") { - result0 = "{`"; - advance(pos, 2); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"{`\""); - } + peg$currPos = s4; + s4 = peg$c3; } - if (result0 !== null) { - result1 = []; - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "`}") { - result2 = "`}"; - advance(pos, 2); + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"`}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c82); } } - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c97(s5); + s3 = s4; } else { - result2 = null; - pos = clone(pos4); + peg$currPos = s3; + s3 = peg$c3; } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } + } else { + peg$currPos = s3; + s3 = peg$c3; + } + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c95) { + s5 = peg$c95; + peg$currPos += 2; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, char) {return char})(pos2.offset, pos2.line, pos2.column, result2[1]); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c96); } } - if (result2 === null) { - pos = clone(pos2); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; + } else { + peg$currPos = s4; + s4 = peg$c3; } - while (result2 !== null) { - result1.push(result2); - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "`}") { - result2 = "`}"; - advance(pos, 2); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"`}\""); - } - } - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - pos = clone(pos4); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c82); } } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c97(s5); + s3 = s4; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, char) {return char})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); + peg$currPos = s3; + s3 = peg$c3; } + } else { + peg$currPos = s3; + s3 = peg$c3; } - if (result1 !== null) { - if (input.substr(pos.offset, 2) === "`}") { - result2 = "`}"; - advance(pos, 2); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"`}\""); - } - } - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos1); - } + } + if (s2 !== peg$FAILED) { + if (input.substr(peg$currPos, 2) === peg$c95) { + s3 = peg$c95; + peg$currPos += 2; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c96); } + } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c98(s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, rawText) { return ["raw", rawText.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("raw"); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c92); } + } + + return s0; + } + + function peg$parsecomment() { + var s0, s1, s2, s3, s4, s5; + + peg$silentFails++; + s0 = peg$currPos; + if (input.substr(peg$currPos, 2) === peg$c100) { + s1 = peg$c100; + peg$currPos += 2; + } else { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c101); } + } + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c102) { + s5 = peg$c102; + peg$currPos += 2; + } else { + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c103); } } - return result0; - } - - function parse_comment() { - var result0, result1, result2, result3; - var pos0, pos1, pos2, pos3, pos4; - - reportFailures++; - pos0 = clone(pos); - pos1 = clone(pos); - if (input.substr(pos.offset, 2) === "{!") { - result0 = "{!"; - advance(pos, 2); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"{!\""); - } + peg$currPos = s4; + s4 = peg$c3; } - if (result0 !== null) { - result1 = []; - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "!}") { - result2 = "!}"; - advance(pos, 2); + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"!}\""); - } + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c82); } } - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c83(s5); + s3 = s4; } else { - result2 = null; - pos = clone(pos4); + peg$currPos = s3; + s3 = peg$c3; } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } + } else { + peg$currPos = s3; + s3 = peg$c3; + } + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$currPos; + s4 = peg$currPos; + peg$silentFails++; + if (input.substr(peg$currPos, 2) === peg$c102) { + s5 = peg$c102; + peg$currPos += 2; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, c) {return c})(pos2.offset, pos2.line, pos2.column, result2[1]); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c103); } } - if (result2 === null) { - pos = clone(pos2); + peg$silentFails--; + if (s5 === peg$FAILED) { + s4 = peg$c6; + } else { + peg$currPos = s4; + s4 = peg$c3; } - while (result2 !== null) { - result1.push(result2); - pos2 = clone(pos); - pos3 = clone(pos); - pos4 = clone(pos); - reportFailures++; - if (input.substr(pos.offset, 2) === "!}") { - result2 = "!}"; - advance(pos, 2); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"!}\""); - } - } - reportFailures--; - if (result2 === null) { - result2 = ""; + if (s4 !== peg$FAILED) { + if (input.length > peg$currPos) { + s5 = input.charAt(peg$currPos); + peg$currPos++; } else { - result2 = null; - pos = clone(pos4); + s5 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c82); } } - if (result2 !== null) { - if (input.length > pos.offset) { - result3 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result3 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result3 !== null) { - result2 = [result2, result3]; - } else { - result2 = null; - pos = clone(pos3); - } + if (s5 !== peg$FAILED) { + peg$reportedPos = s3; + s4 = peg$c83(s5); + s3 = s4; } else { - result2 = null; - pos = clone(pos3); - } - if (result2 !== null) { - result2 = (function(offset, line, column, c) {return c})(pos2.offset, pos2.line, pos2.column, result2[1]); - } - if (result2 === null) { - pos = clone(pos2); + peg$currPos = s3; + s3 = peg$c3; } + } else { + peg$currPos = s3; + s3 = peg$c3; } - if (result1 !== null) { - if (input.substr(pos.offset, 2) === "!}") { - result2 = "!}"; - advance(pos, 2); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("\"!}\""); - } - } - if (result2 !== null) { - result0 = [result0, result1, result2]; - } else { - result0 = null; - pos = clone(pos1); - } + } + if (s2 !== peg$FAILED) { + if (input.substr(peg$currPos, 2) === peg$c102) { + s3 = peg$c102; + peg$currPos += 2; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c103); } + } + if (s3 !== peg$FAILED) { + peg$reportedPos = s0; + s1 = peg$c104(s2); + s0 = s1; } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos1); + peg$currPos = s0; + s0 = peg$c3; } - if (result0 !== null) { - result0 = (function(offset, line, column, c) { return ["comment", c.join('')].concat([['line', line], ['col', column]]) })(pos0.offset, pos0.line, pos0.column, result0[1]); - } - if (result0 === null) { - pos = clone(pos0); - } - reportFailures--; - if (reportFailures === 0 && result0 === null) { - matchFailed("comment"); - } - return result0; - } - - function parse_tag() { - var result0, result1, result2, result3, result4, result5, result6, result7; - var pos0, pos1, pos2; - - pos0 = clone(pos); - result0 = parse_ld(); - if (result0 !== null) { - result1 = []; - result2 = parse_ws(); - while (result2 !== null) { - result1.push(result2); - result2 = parse_ws(); - } - if (result1 !== null) { - if (/^[#?^><+%:@\/~%]/.test(input.charAt(pos.offset))) { - result2 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result2 = null; - if (reportFailures === 0) { - matchFailed("[#?^><+%:@\\/~%]"); - } - } - if (result2 !== null) { - result3 = []; - result4 = parse_ws(); - while (result4 !== null) { - result3.push(result4); - result4 = parse_ws(); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + peg$silentFails--; + if (s0 === peg$FAILED) { + s1 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c99); } + } + + return s0; + } + + function peg$parsetag() { + var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9; + + s0 = peg$currPos; + s1 = peg$parseld(); + if (s1 !== peg$FAILED) { + s2 = []; + s3 = peg$parsews(); + while (s3 !== peg$FAILED) { + s2.push(s3); + s3 = peg$parsews(); + } + if (s2 !== peg$FAILED) { + if (peg$c105.test(input.charAt(peg$currPos))) { + s3 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s3 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c106); } + } + if (s3 !== peg$FAILED) { + s4 = []; + s5 = peg$parsews(); + while (s5 !== peg$FAILED) { + s4.push(s5); + s5 = peg$parsews(); + } + if (s4 !== peg$FAILED) { + s5 = []; + s6 = peg$currPos; + s7 = peg$currPos; + peg$silentFails++; + s8 = peg$parserd(); + peg$silentFails--; + if (s8 === peg$FAILED) { + s7 = peg$c6; + } else { + peg$currPos = s7; + s7 = peg$c3; } - if (result3 !== null) { - pos1 = clone(pos); - pos2 = clone(pos); - reportFailures++; - result5 = parse_rd(); - reportFailures--; - if (result5 === null) { - result5 = ""; + if (s7 !== peg$FAILED) { + s8 = peg$currPos; + peg$silentFails++; + s9 = peg$parseeol(); + peg$silentFails--; + if (s9 === peg$FAILED) { + s8 = peg$c6; } else { - result5 = null; - pos = clone(pos2); + peg$currPos = s8; + s8 = peg$c3; } - if (result5 !== null) { - pos2 = clone(pos); - reportFailures++; - result6 = parse_eol(); - reportFailures--; - if (result6 === null) { - result6 = ""; + if (s8 !== peg$FAILED) { + if (input.length > peg$currPos) { + s9 = input.charAt(peg$currPos); + peg$currPos++; } else { - result6 = null; - pos = clone(pos2); + s9 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c82); } } - if (result6 !== null) { - if (input.length > pos.offset) { - result7 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result7 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result7 !== null) { - result5 = [result5, result6, result7]; - } else { - result5 = null; - pos = clone(pos1); - } + if (s9 !== peg$FAILED) { + s7 = [s7, s8, s9]; + s6 = s7; } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } - if (result5 !== null) { - result4 = []; - while (result5 !== null) { - result4.push(result5); - pos1 = clone(pos); - pos2 = clone(pos); - reportFailures++; - result5 = parse_rd(); - reportFailures--; - if (result5 === null) { - result5 = ""; + } else { + peg$currPos = s6; + s6 = peg$c3; + } + if (s6 !== peg$FAILED) { + while (s6 !== peg$FAILED) { + s5.push(s6); + s6 = peg$currPos; + s7 = peg$currPos; + peg$silentFails++; + s8 = peg$parserd(); + peg$silentFails--; + if (s8 === peg$FAILED) { + s7 = peg$c6; + } else { + peg$currPos = s7; + s7 = peg$c3; + } + if (s7 !== peg$FAILED) { + s8 = peg$currPos; + peg$silentFails++; + s9 = peg$parseeol(); + peg$silentFails--; + if (s9 === peg$FAILED) { + s8 = peg$c6; } else { - result5 = null; - pos = clone(pos2); + peg$currPos = s8; + s8 = peg$c3; } - if (result5 !== null) { - pos2 = clone(pos); - reportFailures++; - result6 = parse_eol(); - reportFailures--; - if (result6 === null) { - result6 = ""; + if (s8 !== peg$FAILED) { + if (input.length > peg$currPos) { + s9 = input.charAt(peg$currPos); + peg$currPos++; } else { - result6 = null; - pos = clone(pos2); + s9 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c82); } } - if (result6 !== null) { - if (input.length > pos.offset) { - result7 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result7 = null; - if (reportFailures === 0) { - matchFailed("any character"); - } - } - if (result7 !== null) { - result5 = [result5, result6, result7]; - } else { - result5 = null; - pos = clone(pos1); - } + if (s9 !== peg$FAILED) { + s7 = [s7, s8, s9]; + s6 = s7; } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } } else { - result5 = null; - pos = clone(pos1); + peg$currPos = s6; + s6 = peg$c3; } + } else { + peg$currPos = s6; + s6 = peg$c3; } - } else { - result4 = null; } - if (result4 !== null) { - result5 = []; - result6 = parse_ws(); - while (result6 !== null) { - result5.push(result6); - result6 = parse_ws(); - } - if (result5 !== null) { - result6 = parse_rd(); - if (result6 !== null) { - result0 = [result0, result1, result2, result3, result4, result5, result6]; - } else { - result0 = null; - pos = clone(pos0); - } + } else { + s5 = peg$c3; + } + if (s5 !== peg$FAILED) { + s6 = []; + s7 = peg$parsews(); + while (s7 !== peg$FAILED) { + s6.push(s7); + s7 = peg$parsews(); + } + if (s6 !== peg$FAILED) { + s7 = peg$parserd(); + if (s7 !== peg$FAILED) { + s1 = [s1, s2, s3, s4, s5, s6, s7]; + s0 = s1; } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); + peg$currPos = s0; + s0 = peg$c3; } } else { - result0 = null; - pos = clone(pos0); - } - } else { - result0 = null; - pos = clone(pos0); - } - if (result0 === null) { - result0 = parse_reference(); - } - return result0; - } - - function parse_ld() { - var result0; - - if (input.charCodeAt(pos.offset) === 123) { - result0 = "{"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"{\""); - } - } - return result0; - } - - function parse_rd() { - var result0; - - if (input.charCodeAt(pos.offset) === 125) { - result0 = "}"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"}\""); + peg$currPos = s0; + s0 = peg$c3; } - } - return result0; - } - - function parse_lb() { - var result0; - - if (input.charCodeAt(pos.offset) === 91) { - result0 = "["; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"[\""); - } - } - return result0; - } - - function parse_rb() { - var result0; - - if (input.charCodeAt(pos.offset) === 93) { - result0 = "]"; - advance(pos, 1); } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"]\""); - } + peg$currPos = s0; + s0 = peg$c3; } - return result0; - } - - function parse_eol() { - var result0; - - if (input.charCodeAt(pos.offset) === 10) { - result0 = "\n"; - advance(pos, 1); + } else { + peg$currPos = s0; + s0 = peg$c3; + } + if (s0 === peg$FAILED) { + s0 = peg$parsereference(); + } + + return s0; + } + + function peg$parseld() { + var s0; + + if (input.charCodeAt(peg$currPos) === 123) { + s0 = peg$c107; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c108); } + } + + return s0; + } + + function peg$parserd() { + var s0; + + if (input.charCodeAt(peg$currPos) === 125) { + s0 = peg$c109; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c110); } + } + + return s0; + } + + function peg$parselb() { + var s0; + + if (input.charCodeAt(peg$currPos) === 91) { + s0 = peg$c111; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c112); } + } + + return s0; + } + + function peg$parserb() { + var s0; + + if (input.charCodeAt(peg$currPos) === 93) { + s0 = peg$c113; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c114); } + } + + return s0; + } + + function peg$parseeol() { + var s0; + + if (input.charCodeAt(peg$currPos) === 10) { + s0 = peg$c115; + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c116); } + } + if (s0 === peg$FAILED) { + if (input.substr(peg$currPos, 2) === peg$c117) { + s0 = peg$c117; + peg$currPos += 2; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\n\""); - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c118); } } - if (result0 === null) { - if (input.substr(pos.offset, 2) === "\r\n") { - result0 = "\r\n"; - advance(pos, 2); + if (s0 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 13) { + s0 = peg$c119; + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\r\\n\""); - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c120); } } - if (result0 === null) { - if (input.charCodeAt(pos.offset) === 13) { - result0 = "\r"; - advance(pos, 1); + if (s0 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 8232) { + s0 = peg$c121; + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\r\""); - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c122); } } - if (result0 === null) { - if (input.charCodeAt(pos.offset) === 8232) { - result0 = "\u2028"; - advance(pos, 1); + if (s0 === peg$FAILED) { + if (input.charCodeAt(peg$currPos) === 8233) { + s0 = peg$c123; + peg$currPos++; } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\u2028\""); - } - } - if (result0 === null) { - if (input.charCodeAt(pos.offset) === 8233) { - result0 = "\u2029"; - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("\"\\u2029\""); - } - } + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c124); } } } } } - return result0; - } - - function parse_ws() { - var result0; - - if (/^[\t\x0B\f \xA0\uFEFF]/.test(input.charAt(pos.offset))) { - result0 = input.charAt(pos.offset); - advance(pos, 1); - } else { - result0 = null; - if (reportFailures === 0) { - matchFailed("[\\t\\x0B\\f \\xA0\\uFEFF]"); - } - } - if (result0 === null) { - result0 = parse_eol(); - } - return result0; } - - - function cleanupExpected(expected) { - expected.sort(); - - var lastExpected = null; - var cleanExpected = []; - for (var i = 0; i < expected.length; i++) { - if (expected[i] !== lastExpected) { - cleanExpected.push(expected[i]); - lastExpected = expected[i]; - } - } - return cleanExpected; - } - - - - var result = parseFunctions[startRule](); - - /* - * The parser is now in one of the following three states: - * - * 1. The parser successfully parsed the whole input. - * - * - |result !== null| - * - |pos.offset === input.length| - * - |rightmostFailuresExpected| may or may not contain something - * - * 2. The parser successfully parsed only a part of the input. - * - * - |result !== null| - * - |pos.offset < input.length| - * - |rightmostFailuresExpected| may or may not contain something - * - * 3. The parser did not successfully parse any part of the input. - * - * - |result === null| - * - |pos.offset === 0| - * - |rightmostFailuresExpected| contains at least one failure - * - * All code following this comment (including called functions) must - * handle these states. - */ - if (result === null || pos.offset !== input.length) { - var offset = Math.max(pos.offset, rightmostFailuresPos.offset); - var found = offset < input.length ? input.charAt(offset) : null; - var errorPosition = pos.offset > rightmostFailuresPos.offset ? pos : rightmostFailuresPos; - - throw new parser.SyntaxError( - cleanupExpected(rightmostFailuresExpected), - found, - offset, - errorPosition.line, - errorPosition.column - ); - } - - return result; - }, - - /* Returns the parser source code. */ - toSource: function() { return this._source; } - }; - - /* Thrown when a parser encounters a syntax error. */ - - result.SyntaxError = function(expected, found, offset, line, column) { - function buildMessage(expected, found) { - var expectedHumanized, foundHumanized; - - switch (expected.length) { - case 0: - expectedHumanized = "end of input"; - break; - case 1: - expectedHumanized = expected[0]; - break; - default: - expectedHumanized = expected.slice(0, expected.length - 1).join(", ") - + " or " - + expected[expected.length - 1]; - } - - foundHumanized = found ? quote(found) : "end of input"; - - return "Expected " + expectedHumanized + " but " + foundHumanized + " found."; + + return s0; } - - this.name = "SyntaxError"; - this.expected = expected; - this.found = found; - this.message = buildMessage(expected, found); - this.offset = offset; - this.line = line; - this.column = column; + + function peg$parsews() { + var s0; + + if (peg$c125.test(input.charAt(peg$currPos))) { + s0 = input.charAt(peg$currPos); + peg$currPos++; + } else { + s0 = peg$FAILED; + if (peg$silentFails === 0) { peg$fail(peg$c126); } + } + if (s0 === peg$FAILED) { + s0 = peg$parseeol(); + } + + return s0; + } + + peg$result = peg$startRuleFunction(); + + if (peg$result !== peg$FAILED && peg$currPos === input.length) { + return peg$result; + } else { + if (peg$result !== peg$FAILED && peg$currPos < input.length) { + peg$fail({ type: "end", description: "end of input" }); + } + + throw peg$buildException(null, peg$maxFailExpected, peg$maxFailPos); + } + } + + return { + SyntaxError: SyntaxError, + parse: parse }; - - result.SyntaxError.prototype = Error.prototype; - - return result; })(); // expose parser methods diff --git a/dist/dust-full.min.js b/dist/dust-full.min.js index 0441a749..3ac0f041 100644 --- a/dist/dust-full.min.js +++ b/dist/dust-full.min.js @@ -1,5 +1,5 @@ -/*! Dust - Asynchronous Templating - v2.3.5 +/*! Dust - Asynchronous Templating - v2.3.6 * http://linkedin.github.io/dustjs/ * Copyright (c) 2014 Aleksander Williams; Released under the MIT License */ -!function(root){function Context(a,b,c,d){this.stack=a,this.global=b,this.blocks=c,this.templateName=d}function Stack(a,b,c,d){this.tail=b,this.isObject=a&&"object"==typeof a,this.head=a,this.index=c,this.of=d}function Stub(a){this.head=new Chunk(this),this.callback=a,this.out=""}function Stream(){this.head=new Chunk(this)}function Chunk(a,b,c){this.root=a,this.next=b,this.data=[],this.flushable=!1,this.taps=c}function Tap(a,b){this.head=a,this.tail=b}var dust={},NONE="NONE",ERROR="ERROR",WARN="WARN",INFO="INFO",DEBUG="DEBUG",loggingLevels=[DEBUG,INFO,WARN,ERROR,NONE],EMPTY_FUNC=function(){},logger={},originalLog,loggerContext;dust.debugLevel=NONE,dust.silenceErrors=!1,root&&root.console&&root.console.log&&(loggerContext=root.console,originalLog=root.console.log),logger.log=loggerContext?function(){logger.log="function"==typeof originalLog?function(){originalLog.apply(loggerContext,arguments)}:function(){var a=Array.prototype.slice.apply(arguments).join(" ");originalLog(a)},logger.log.apply(this,arguments)}:function(){},dust.log=function(a,b){if(b=b||INFO,dust.debugLevel!==NONE&&dust.indexInArray(loggingLevels,b)>=dust.indexInArray(loggingLevels,dust.debugLevel)&&(dust.logQueue||(dust.logQueue=[]),dust.logQueue.push({message:a,type:b}),logger.log("[DUST "+b+"]: "+a)),!dust.silenceErrors&&b===ERROR)throw"string"==typeof a?new Error(a):a},dust.onError=function(a,b){if(logger.log("[!!!DEPRECATION WARNING!!!]: dust.onError will no longer return a chunk object."),dust.log(a.message||a,ERROR),dust.silenceErrors)return b;throw a},dust.helpers={},dust.cache={},dust.register=function(a,b){a&&(dust.cache[a]=b)},dust.render=function(a,b,c){var d=new Stub(c).head;try{dust.load(a,d,Context.wrap(b,a)).end()}catch(e){dust.log(e,ERROR)}},dust.stream=function(a,b){var c=new Stream;return dust.nextTick(function(){try{dust.load(a,c.head,Context.wrap(b,a)).end()}catch(d){dust.log(d,ERROR)}}),c},dust.renderSource=function(a,b,c){return dust.compileFn(a)(b,c)},dust.compileFn=function(a,b){b=b||null;var c=dust.loadSource(dust.compile(a,b));return function(a,d){var e=d?new Stub(d):new Stream;return dust.nextTick(function(){"function"==typeof c?c(e.head,Context.wrap(a,b)).end():dust.log(new Error("Template ["+b+"] cannot be resolved to a Dust function"),ERROR)}),e}},dust.load=function(a,b,c){var d=dust.cache[a];return d?d(b,c):dust.onLoad?b.map(function(b){dust.onLoad(a,function(d,e){return d?b.setError(d):(dust.cache[a]||dust.loadSource(dust.compile(e,a)),void dust.cache[a](b,c).end())})}):b.setError(new Error("Template Not Found: "+a))},dust.loadSource=function(source,path){return eval(source)},dust.isArray=Array.isArray?Array.isArray:function(a){return"[object Array]"===Object.prototype.toString.call(a)},dust.indexInArray=function(a,b,c){if(c=+c||0,Array.prototype.indexOf)return a.indexOf(b,c);if(void 0===a||null===a)throw new TypeError('cannot call method "indexOf" of null');var d=a.length;for(1/0===Math.abs(c)&&(c=0),0>c&&(c+=d,0>c&&(c=0));d>c;c++)if(a[c]===b)return c;return-1},dust.nextTick=function(){return function(a){setTimeout(a,0)}}(),dust.isEmpty=function(a){return dust.isArray(a)&&!a.length?!0:0===a?!1:!a},dust.filter=function(a,b,c){if(c)for(var d=0,e=c.length;e>d;d++){var f=c[d];"s"===f?b=null:"function"==typeof dust.filters[f]?a=dust.filters[f](a):dust.log("Invalid filter ["+f+"]",WARN)}return b&&(a=dust.filters[b](a)),a},dust.filters={h:function(a){return dust.escapeHtml(a)},j:function(a){return dust.escapeJs(a)},u:encodeURI,uc:encodeURIComponent,js:function(a){return JSON?JSON.stringify(a):(dust.log("JSON is undefined. JSON stringify has not been used on ["+a+"]",WARN),a)},jp:function(a){return JSON?JSON.parse(a):(dust.log("JSON is undefined. JSON parse has not been used on ["+a+"]",WARN),a)}},dust.makeBase=function(a){return new Context(new Stack,a)},Context.wrap=function(a,b){return a instanceof Context?a:new Context(new Stack(a),{},null,b)},Context.prototype.get=function(a,b){return"string"==typeof a&&("."===a[0]&&(b=!0,a=a.substr(1)),a=a.split(".")),this._get(b,a)},Context.prototype._get=function(a,b){var c,d,e,f,g=this.stack,h=1;if(d=b[0],e=b.length,a&&0===e)f=g,g=g.head;else{if(a)g&&(g=g.head?g.head[d]:void 0);else{for(;g&&(!g.isObject||(f=g.head,c=g.head[d],void 0===c));)g=g.tail;g=void 0!==c?c:this.global?this.global[d]:void 0}for(;g&&e>h;)f=g,g=g[b[h]],h++}if("function"==typeof g){var i=function(){try{return g.apply(f,arguments)}catch(a){return dust.log(a,ERROR)}};return i.isFunction=!0,i}return void 0===g&&dust.log("Cannot find the value for reference [{"+b.join(".")+"}] in template ["+this.getTemplateName()+"]"),g},Context.prototype.getPath=function(a,b){return this._get(a,b)},Context.prototype.push=function(a,b,c){return new Context(new Stack(a,this.stack,b,c),this.global,this.blocks,this.getTemplateName())},Context.prototype.rebase=function(a){return new Context(new Stack(a),this.global,this.blocks,this.getTemplateName())},Context.prototype.current=function(){return this.stack.head},Context.prototype.getBlock=function(a){if("function"==typeof a){var b=new Chunk;a=a(b,this).data.join("")}var c=this.blocks;if(!c)return void dust.log("No blocks for context[{"+a+"}] in template ["+this.getTemplateName()+"]",DEBUG);for(var d,e=c.length;e--;)if(d=c[e][a])return d},Context.prototype.shiftBlocks=function(a){var b,c=this.blocks;return a?(b=c?c.concat([a]):[a],new Context(this.stack,this.global,b,this.getTemplateName())):this},Context.prototype.getTemplateName=function(){return this.templateName},Stub.prototype.flush=function(){for(var a=this.head;a;){if(!a.flushable)return a.error?(this.callback(a.error),dust.log("Chunk error ["+a.error+"] thrown. Ceasing to render this template.",WARN),void(this.flush=EMPTY_FUNC)):void 0;this.out+=a.data.join(""),a=a.next,this.head=a}this.callback(null,this.out)},Stream.prototype.flush=function(){for(var a=this.head;a;){if(!a.flushable)return a.error?(this.emit("error",a.error),dust.log("Chunk error ["+a.error+"] thrown. Ceasing to render this template.",WARN),void(this.flush=EMPTY_FUNC)):void 0;this.emit("data",a.data.join("")),a=a.next,this.head=a}this.emit("end")},Stream.prototype.emit=function(a,b){if(!this.events)return dust.log("No events to emit",INFO),!1;var c=this.events[a];if(!c)return dust.log("Event type ["+a+"] does not exist",WARN),!1;if("function"==typeof c)c(b);else if(dust.isArray(c))for(var d=c.slice(0),e=0,f=d.length;f>e;e++)d[e](b);else dust.log("Event Handler ["+c+"] is not of a type that is handled by emit",WARN)},Stream.prototype.on=function(a,b){return this.events||(this.events={}),this.events[a]?"function"==typeof this.events[a]?this.events[a]=[this.events[a],b]:this.events[a].push(b):(dust.log("Event type ["+a+"] does not exist. Using just the specified callback.",WARN),b?this.events[a]=b:dust.log("Callback for type ["+a+"] does not exist. Listener not registered.",WARN)),this},Stream.prototype.pipe=function(a){return this.on("data",function(b){try{a.write(b,"utf8")}catch(c){dust.log(c,ERROR)}}).on("end",function(){try{return a.end()}catch(b){dust.log(b,ERROR)}}).on("error",function(b){a.error(b)}),this},Chunk.prototype.write=function(a){var b=this.taps;return b&&(a=b.go(a)),this.data.push(a),this},Chunk.prototype.end=function(a){return a&&this.write(a),this.flushable=!0,this.root.flush(),this},Chunk.prototype.map=function(a){var b=new Chunk(this.root,this.next,this.taps),c=new Chunk(this.root,b,this.taps);return this.next=c,this.flushable=!0,a(c),b},Chunk.prototype.tap=function(a){var b=this.taps;return this.taps=b?b.push(a):new Tap(a),this},Chunk.prototype.untap=function(){return this.taps=this.taps.tail,this},Chunk.prototype.render=function(a,b){return a(this,b)},Chunk.prototype.reference=function(a,b,c,d){return"function"==typeof a&&(a.isFunction=!0,a=a.apply(b.current(),[this,b,null,{auto:c,filters:d}]),a instanceof Chunk)?a:dust.isEmpty(a)?this:this.write(dust.filter(a,c,d))},Chunk.prototype.section=function(a,b,c,d){if("function"==typeof a&&(a=a.apply(b.current(),[this,b,c,d]),a instanceof Chunk))return a;var e=c.block,f=c["else"];if(d&&(b=b.push(d)),dust.isArray(a)){if(e){var g=a.length,h=this;if(g>0){b.stack.head&&(b.stack.head.$len=g);for(var i=0;g>i;i++)b.stack.head&&(b.stack.head.$idx=i),h=e(h,b.push(a[i],i,g));return b.stack.head&&(b.stack.head.$idx=void 0,b.stack.head.$len=void 0),h}if(f)return f(this,b)}}else if(a===!0){if(e)return e(this,b)}else if(a||0===a){if(e)return e(this,b.push(a))}else if(f)return f(this,b);return dust.log("Not rendering section (#) block in template ["+b.getTemplateName()+"], because above key was not found",DEBUG),this},Chunk.prototype.exists=function(a,b,c){var d=c.block,e=c["else"];if(dust.isEmpty(a)){if(e)return e(this,b)}else if(d)return d(this,b);return dust.log("Not rendering exists (?) block in template ["+b.getTemplateName()+"], because above key was not found",DEBUG),this},Chunk.prototype.notexists=function(a,b,c){var d=c.block,e=c["else"];if(dust.isEmpty(a)){if(d)return d(this,b)}else if(e)return e(this,b);return dust.log("Not rendering not exists (^) block check in template ["+b.getTemplateName()+"], because above key was found",DEBUG),this},Chunk.prototype.block=function(a,b,c){var d=c.block;return a&&(d=a),d?d(this,b):this},Chunk.prototype.partial=function(a,b,c){var d;d=dust.makeBase(b.global),d.blocks=b.blocks,b.stack&&b.stack.tail&&(d.stack=b.stack.tail),c&&(d=d.push(c)),"string"==typeof a&&(d.templateName=a),d=d.push(b.stack.head);var e;return e="function"==typeof a?this.capture(a,d,function(a,b){d.templateName=d.templateName||a,dust.load(a,b,d).end()}):dust.load(a,this,d)},Chunk.prototype.helper=function(a,b,c,d){var e=this;try{return dust.helpers[a]?dust.helpers[a](e,b,c,d):(dust.log("Invalid helper ["+a+"]",WARN),e)}catch(f){return dust.log(f,ERROR),e}},Chunk.prototype.capture=function(a,b,c){return this.map(function(d){var e=new Stub(function(a,b){a?d.setError(a):c(b,d)});a(e.head,b).end()})},Chunk.prototype.setError=function(a){return this.error=a,this.root.flush(),this},Tap.prototype.push=function(a){return new Tap(a,this)},Tap.prototype.go=function(a){for(var b=this;b;)a=b.head(a),b=b.tail;return a};var HCHARS=new RegExp(/[&<>\"\']/),AMP=/&/g,LT=//g,QUOT=/\"/g,SQUOT=/\'/g;dust.escapeHtml=function(a){return"string"==typeof a?HCHARS.test(a)?a.replace(AMP,"&").replace(LT,"<").replace(GT,">").replace(QUOT,""").replace(SQUOT,"'"):a:a};var BS=/\\/g,FS=/\//g,CR=/\r/g,LS=/\u2028/g,PS=/\u2029/g,NL=/\n/g,LF=/\f/g,SQ=/'/g,DQ=/"/g,TB=/\t/g;dust.escapeJs=function(a){return"string"==typeof a?a.replace(BS,"\\\\").replace(FS,"\\/").replace(DQ,'\\"').replace(SQ,"\\'").replace(CR,"\\r").replace(LS,"\\u2028").replace(PS,"\\u2029").replace(NL,"\\n").replace(LF,"\\f").replace(TB,"\\t"):a},"object"==typeof exports?module.exports=dust:root.dust=dust}(function(){return this}()),function(a,b){"object"==typeof exports?module.exports=b(require("./dust")):b(a.dust)}(this,function(dust){var a=function(){function b(a){return'"'+a.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\x08/g,"\\b").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\f/g,"\\f").replace(/\r/g,"\\r").replace(/[\x00-\x07\x0B\x0E-\x1F\x80-\uFFFF]/g,escape)+'"'}var c={parse:function(c,d){function e(a){var b={};for(var c in a)b[c]=a[c];return b}function f(a,b){for(var d=a.offset+b,e=a.offset;d>e;e++){var f=c.charAt(e);"\n"===f?(a.seenCR||a.line++,a.column=1,a.seenCR=!1):"\r"===f||"\u2028"===f||"\u2029"===f?(a.line++,a.column=1,a.seenCR=!0):(a.column++,a.seenCR=!1)}a.offset+=b}function g(a){R.offsetT.offset&&(T=e(R),U=[]),U.push(a))}function h(){var a,b,c;for(c=e(R),a=[],b=i();null!==b;)a.push(b),b=i();return null!==a&&(a=function(a,b,c,d){return["body"].concat(d).concat([["line",b],["col",c]])}(c.offset,c.line,c.column,a)),null===a&&(R=e(c)),a}function i(){var a;return a=G(),null===a&&(a=H(),null===a&&(a=j(),null===a&&(a=q(),null===a&&(a=s(),null===a&&(a=p(),null===a&&(a=D())))))),a}function j(){var a,b,d,i,j,m,n,p,q;if(S++,p=e(R),q=e(R),a=k(),null!==a){for(b=[],d=O();null!==d;)b.push(d),d=O();null!==b?(d=K(),null!==d?(i=h(),null!==i?(j=o(),null!==j?(m=l(),m=null!==m?m:"",null!==m?(n=function(a,b,c,d,e,f,g){if(!g||d[1].text!==g.text)throw new Error("Expected end tag for "+d[1].text+" but it was not found. At line : "+b+", column : "+c);return!0}(R.offset,R.line,R.column,a,i,j,m)?"":null,null!==n?a=[a,b,d,i,j,m,n]:(a=null,R=e(q))):(a=null,R=e(q))):(a=null,R=e(q))):(a=null,R=e(q))):(a=null,R=e(q))):(a=null,R=e(q))}else a=null,R=e(q);if(null!==a&&(a=function(a,b,c,d,e,f){return f.push(["param",["literal","block"],e]),d.push(f),d.concat([["line",b],["col",c]])}(p.offset,p.line,p.column,a[0],a[3],a[4],a[5])),null===a&&(R=e(p)),null===a){if(p=e(R),q=e(R),a=k(),null!==a){for(b=[],d=O();null!==d;)b.push(d),d=O();null!==b?(47===c.charCodeAt(R.offset)?(d="/",f(R,1)):(d=null,0===S&&g('"/"')),null!==d?(i=K(),null!==i?a=[a,b,d,i]:(a=null,R=e(q))):(a=null,R=e(q))):(a=null,R=e(q))}else a=null,R=e(q);null!==a&&(a=function(a,b,c,d){return d.push(["bodies"]),d.concat([["line",b],["col",c]])}(p.offset,p.line,p.column,a[0])),null===a&&(R=e(p))}return S--,0===S&&null===a&&g("section"),a}function k(){var a,b,d,h,i,j,k,l;if(k=e(R),l=e(R),a=J(),null!==a)if(/^[#?^<+@%]/.test(c.charAt(R.offset))?(b=c.charAt(R.offset),f(R,1)):(b=null,0===S&&g("[#?^<+@%]")),null!==b){for(d=[],h=O();null!==h;)d.push(h),h=O();null!==d?(h=t(),null!==h?(i=m(),null!==i?(j=n(),null!==j?a=[a,b,d,h,i,j]:(a=null,R=e(l))):(a=null,R=e(l))):(a=null,R=e(l))):(a=null,R=e(l))}else a=null,R=e(l);else a=null,R=e(l);return null!==a&&(a=function(a,b,c,d,e,f,g){return[d,e,f,g]}(k.offset,k.line,k.column,a[1],a[3],a[4],a[5])),null===a&&(R=e(k)),a}function l(){var a,b,d,h,i,j,k,l;if(S++,k=e(R),l=e(R),a=J(),null!==a)if(47===c.charCodeAt(R.offset)?(b="/",f(R,1)):(b=null,0===S&&g('"/"')),null!==b){for(d=[],h=O();null!==h;)d.push(h),h=O();if(null!==d)if(h=t(),null!==h){for(i=[],j=O();null!==j;)i.push(j),j=O();null!==i?(j=K(),null!==j?a=[a,b,d,h,i,j]:(a=null,R=e(l))):(a=null,R=e(l))}else a=null,R=e(l);else a=null,R=e(l)}else a=null,R=e(l);else a=null,R=e(l);return null!==a&&(a=function(a,b,c,d){return d}(k.offset,k.line,k.column,a[3])),null===a&&(R=e(k)),S--,0===S&&null===a&&g("end tag"),a}function m(){var a,b,d,h,i;return d=e(R),h=e(R),i=e(R),58===c.charCodeAt(R.offset)?(a=":",f(R,1)):(a=null,0===S&&g('":"')),null!==a?(b=t(),null!==b?a=[a,b]:(a=null,R=e(i))):(a=null,R=e(i)),null!==a&&(a=function(a,b,c,d){return d}(h.offset,h.line,h.column,a[1])),null===a&&(R=e(h)),a=null!==a?a:"",null!==a&&(a=function(a,b,c,d){return d?["context",d]:["context"]}(d.offset,d.line,d.column,a)),null===a&&(R=e(d)),a}function n(){var a,b,d,h,i,j,k,l;if(S++,j=e(R),a=[],k=e(R),l=e(R),d=O(),null!==d)for(b=[];null!==d;)b.push(d),d=O();else b=null;for(null!==b?(d=y(),null!==d?(61===c.charCodeAt(R.offset)?(h="=",f(R,1)):(h=null,0===S&&g('"="')),null!==h?(i=u(),null===i&&(i=t(),null===i&&(i=B())),null!==i?b=[b,d,h,i]:(b=null,R=e(l))):(b=null,R=e(l))):(b=null,R=e(l))):(b=null,R=e(l)),null!==b&&(b=function(a,b,c,d,e){return["param",["literal",d],e]}(k.offset,k.line,k.column,b[1],b[3])),null===b&&(R=e(k));null!==b;){if(a.push(b),k=e(R),l=e(R),d=O(),null!==d)for(b=[];null!==d;)b.push(d),d=O();else b=null;null!==b?(d=y(),null!==d?(61===c.charCodeAt(R.offset)?(h="=",f(R,1)):(h=null,0===S&&g('"="')),null!==h?(i=u(),null===i&&(i=t(),null===i&&(i=B())),null!==i?b=[b,d,h,i]:(b=null,R=e(l))):(b=null,R=e(l))):(b=null,R=e(l))):(b=null,R=e(l)),null!==b&&(b=function(a,b,c,d,e){return["param",["literal",d],e]}(k.offset,k.line,k.column,b[1],b[3])),null===b&&(R=e(k))}return null!==a&&(a=function(a,b,c,d){return["params"].concat(d)}(j.offset,j.line,j.column,a)),null===a&&(R=e(j)),S--,0===S&&null===a&&g("params"),a}function o(){var a,b,d,i,j,k,l,m,n;for(S++,l=e(R),a=[],m=e(R),n=e(R),b=J(),null!==b?(58===c.charCodeAt(R.offset)?(d=":",f(R,1)):(d=null,0===S&&g('":"')),null!==d?(i=y(),null!==i?(j=K(),null!==j?(k=h(),null!==k?b=[b,d,i,j,k]:(b=null,R=e(n))):(b=null,R=e(n))):(b=null,R=e(n))):(b=null,R=e(n))):(b=null,R=e(n)),null!==b&&(b=function(a,b,c,d,e){return["param",["literal",d],e]}(m.offset,m.line,m.column,b[2],b[4])),null===b&&(R=e(m));null!==b;)a.push(b),m=e(R),n=e(R),b=J(),null!==b?(58===c.charCodeAt(R.offset)?(d=":",f(R,1)):(d=null,0===S&&g('":"')),null!==d?(i=y(),null!==i?(j=K(),null!==j?(k=h(),null!==k?b=[b,d,i,j,k]:(b=null,R=e(n))):(b=null,R=e(n))):(b=null,R=e(n))):(b=null,R=e(n))):(b=null,R=e(n)),null!==b&&(b=function(a,b,c,d,e){return["param",["literal",d],e]}(m.offset,m.line,m.column,b[2],b[4])),null===b&&(R=e(m));return null!==a&&(a=function(a,b,c,d){return["bodies"].concat(d)}(l.offset,l.line,l.column,a)),null===a&&(R=e(l)),S--,0===S&&null===a&&g("bodies"),a}function p(){var a,b,c,d,f,h;return S++,f=e(R),h=e(R),a=J(),null!==a?(b=t(),null!==b?(c=r(),null!==c?(d=K(),null!==d?a=[a,b,c,d]:(a=null,R=e(h))):(a=null,R=e(h))):(a=null,R=e(h))):(a=null,R=e(h)),null!==a&&(a=function(a,b,c,d,e){return["reference",d,e].concat([["line",b],["col",c]])}(f.offset,f.line,f.column,a[1],a[2])),null===a&&(R=e(f)),S--,0===S&&null===a&&g("reference"),a}function q(){var a,b,d,h,i,j,k,l,o,p,q,r;if(S++,p=e(R),q=e(R),a=J(),null!==a)if(62===c.charCodeAt(R.offset)?(b=">",f(R,1)):(b=null,0===S&&g('">"')),null===b&&(43===c.charCodeAt(R.offset)?(b="+",f(R,1)):(b=null,0===S&&g('"+"'))),null!==b){for(d=[],h=O();null!==h;)d.push(h),h=O();if(null!==d)if(r=e(R),h=y(),null!==h&&(h=function(a,b,c,d){return["literal",d]}(r.offset,r.line,r.column,h)),null===h&&(R=e(r)),null===h&&(h=B()),null!==h)if(i=m(),null!==i)if(j=n(),null!==j){for(k=[],l=O();null!==l;)k.push(l),l=O();null!==k?(47===c.charCodeAt(R.offset)?(l="/",f(R,1)):(l=null,0===S&&g('"/"')),null!==l?(o=K(),null!==o?a=[a,b,d,h,i,j,k,l,o]:(a=null,R=e(q))):(a=null,R=e(q))):(a=null,R=e(q))}else a=null,R=e(q);else a=null,R=e(q);else a=null,R=e(q);else a=null,R=e(q)}else a=null,R=e(q);else a=null,R=e(q);return null!==a&&(a=function(a,b,c,d,e,f,g){var h=">"===d?"partial":d;return[h,e,f,g].concat([["line",b],["col",c]])}(p.offset,p.line,p.column,a[1],a[3],a[4],a[5])),null===a&&(R=e(p)),S--,0===S&&null===a&&g("partial"),a}function r(){var a,b,d,h,i,j;for(S++,h=e(R),a=[],i=e(R),j=e(R),124===c.charCodeAt(R.offset)?(b="|",f(R,1)):(b=null,0===S&&g('"|"')),null!==b?(d=y(),null!==d?b=[b,d]:(b=null,R=e(j))):(b=null,R=e(j)),null!==b&&(b=function(a,b,c,d){return d}(i.offset,i.line,i.column,b[1])),null===b&&(R=e(i));null!==b;)a.push(b),i=e(R),j=e(R),124===c.charCodeAt(R.offset)?(b="|",f(R,1)):(b=null,0===S&&g('"|"')),null!==b?(d=y(),null!==d?b=[b,d]:(b=null,R=e(j))):(b=null,R=e(j)),null!==b&&(b=function(a,b,c,d){return d}(i.offset,i.line,i.column,b[1])),null===b&&(R=e(i));return null!==a&&(a=function(a,b,c,d){return["filters"].concat(d)}(h.offset,h.line,h.column,a)),null===a&&(R=e(h)),S--,0===S&&null===a&&g("filters"),a}function s(){var a,b,d,h,i,j;return S++,i=e(R),j=e(R),a=J(),null!==a?(126===c.charCodeAt(R.offset)?(b="~",f(R,1)):(b=null,0===S&&g('"~"')),null!==b?(d=y(),null!==d?(h=K(),null!==h?a=[a,b,d,h]:(a=null,R=e(j))):(a=null,R=e(j))):(a=null,R=e(j))):(a=null,R=e(j)),null!==a&&(a=function(a,b,c,d){return["special",d].concat([["line",b],["col",c]])}(i.offset,i.line,i.column,a[2])),null===a&&(R=e(i)),S--,0===S&&null===a&&g("special"),a}function t(){var a,b;return S++,b=e(R),a=x(),null!==a&&(a=function(a,b,c,d){var e=["path"].concat(d);return e.text=d[1].join("."),e}(b.offset,b.line,b.column,a)),null===a&&(R=e(b)),null===a&&(b=e(R),a=y(),null!==a&&(a=function(a,b,c,d){var e=["key",d];return e.text=d,e}(b.offset,b.line,b.column,a)),null===a&&(R=e(b))),S--,0===S&&null===a&&g("identifier"),a}function u(){var a,b;return S++,b=e(R),a=v(),null===a&&(a=w()),null!==a&&(a=function(a,b,c,d){return["literal",d]}(b.offset,b.line,b.column,a)),null===a&&(R=e(b)),S--,0===S&&null===a&&g("number"),a}function v(){var a,b,d,h,i,j;if(S++,i=e(R),j=e(R),a=w(),null!==a)if(46===c.charCodeAt(R.offset)?(b=".",f(R,1)):(b=null,0===S&&g('"."')),null!==b){if(h=w(),null!==h)for(d=[];null!==h;)d.push(h),h=w();else d=null;null!==d?a=[a,b,d]:(a=null,R=e(j))}else a=null,R=e(j);else a=null,R=e(j);return null!==a&&(a=function(a,b,c,d,e){return parseFloat(d+"."+e.join(""))}(i.offset,i.line,i.column,a[0],a[2])),null===a&&(R=e(i)),S--,0===S&&null===a&&g("float"),a}function w(){var a,b,d;if(S++,d=e(R),/^[0-9]/.test(c.charAt(R.offset))?(b=c.charAt(R.offset),f(R,1)):(b=null,0===S&&g("[0-9]")),null!==b)for(a=[];null!==b;)a.push(b),/^[0-9]/.test(c.charAt(R.offset))?(b=c.charAt(R.offset),f(R,1)):(b=null,0===S&&g("[0-9]"));else a=null;return null!==a&&(a=function(a,b,c,d){return parseInt(d.join(""),10)}(d.offset,d.line,d.column,a)),null===a&&(R=e(d)),S--,0===S&&null===a&&g("integer"),a}function x(){var a,b,d,h,i;if(S++,h=e(R),i=e(R),a=y(),a=null!==a?a:"",null!==a){if(d=A(),null===d&&(d=z()),null!==d)for(b=[];null!==d;)b.push(d),d=A(),null===d&&(d=z());else b=null;null!==b?a=[a,b]:(a=null,R=e(i))}else a=null,R=e(i);if(null!==a&&(a=function(a,b,c,d,e){return e=e[0],d&&e?(e.unshift(d),[!1,e].concat([["line",b],["col",c]])):[!0,e].concat([["line",b],["col",c]])}(h.offset,h.line,h.column,a[0],a[1])),null===a&&(R=e(h)),null===a){if(h=e(R),i=e(R),46===c.charCodeAt(R.offset)?(a=".",f(R,1)):(a=null,0===S&&g('"."')),null!==a){for(b=[],d=A(),null===d&&(d=z());null!==d;)b.push(d),d=A(),null===d&&(d=z());null!==b?a=[a,b]:(a=null,R=e(i))}else a=null,R=e(i);null!==a&&(a=function(a,b,c,d){return d.length>0?[!0,d[0]].concat([["line",b],["col",c]]):[!0,[]].concat([["line",b],["col",c]])}(h.offset,h.line,h.column,a[1])),null===a&&(R=e(h))}return S--,0===S&&null===a&&g("path"),a}function y(){var a,b,d,h,i;if(S++,h=e(R),i=e(R),/^[a-zA-Z_$]/.test(c.charAt(R.offset))?(a=c.charAt(R.offset),f(R,1)):(a=null,0===S&&g("[a-zA-Z_$]")),null!==a){for(b=[],/^[0-9a-zA-Z_$\-]/.test(c.charAt(R.offset))?(d=c.charAt(R.offset),f(R,1)):(d=null,0===S&&g("[0-9a-zA-Z_$\\-]"));null!==d;)b.push(d),/^[0-9a-zA-Z_$\-]/.test(c.charAt(R.offset))?(d=c.charAt(R.offset),f(R,1)):(d=null,0===S&&g("[0-9a-zA-Z_$\\-]"));null!==b?a=[a,b]:(a=null,R=e(i))}else a=null,R=e(i);return null!==a&&(a=function(a,b,c,d,e){return d+e.join("")}(h.offset,h.line,h.column,a[0],a[1])),null===a&&(R=e(h)),S--,0===S&&null===a&&g("key"),a}function z(){var a,b,d,h,i,j,k,l;if(S++,h=e(R),i=e(R),j=e(R),k=e(R),a=L(),null!==a){if(l=e(R),/^[0-9]/.test(c.charAt(R.offset))?(d=c.charAt(R.offset),f(R,1)):(d=null,0===S&&g("[0-9]")),null!==d)for(b=[];null!==d;)b.push(d),/^[0-9]/.test(c.charAt(R.offset))?(d=c.charAt(R.offset),f(R,1)):(d=null,0===S&&g("[0-9]"));else b=null;null!==b&&(b=function(a,b,c,d){return d.join("")}(l.offset,l.line,l.column,b)),null===b&&(R=e(l)),null===b&&(b=t()),null!==b?(d=M(),null!==d?a=[a,b,d]:(a=null,R=e(k))):(a=null,R=e(k))}else a=null,R=e(k);return null!==a&&(a=function(a,b,c,d){return d}(j.offset,j.line,j.column,a[1])),null===a&&(R=e(j)),null!==a?(b=A(),b=null!==b?b:"",null!==b?a=[a,b]:(a=null,R=e(i))):(a=null,R=e(i)),null!==a&&(a=function(a,b,c,d,e){return e?e.unshift(d):e=[d],e}(h.offset,h.line,h.column,a[0],a[1])),null===a&&(R=e(h)),S--,0===S&&null===a&&g("array"),a}function A(){var a,b,d,h,i,j,k;if(S++,h=e(R),i=e(R),j=e(R),k=e(R),46===c.charCodeAt(R.offset)?(b=".",f(R,1)):(b=null,0===S&&g('"."')),null!==b?(d=y(),null!==d?b=[b,d]:(b=null,R=e(k))):(b=null,R=e(k)),null!==b&&(b=function(a,b,c,d){return d}(j.offset,j.line,j.column,b[1])),null===b&&(R=e(j)),null!==b)for(a=[];null!==b;)a.push(b),j=e(R),k=e(R),46===c.charCodeAt(R.offset)?(b=".",f(R,1)):(b=null,0===S&&g('"."')),null!==b?(d=y(),null!==d?b=[b,d]:(b=null,R=e(k))):(b=null,R=e(k)),null!==b&&(b=function(a,b,c,d){return d}(j.offset,j.line,j.column,b[1])),null===b&&(R=e(j));else a=null;return null!==a?(b=z(),b=null!==b?b:"",null!==b?a=[a,b]:(a=null,R=e(i))):(a=null,R=e(i)),null!==a&&(a=function(a,b,c,d,e){return e?d.concat(e):d}(h.offset,h.line,h.column,a[0],a[1])),null===a&&(R=e(h)),S--,0===S&&null===a&&g("array_part"),a}function B(){var a,b,d,h,i;if(S++,h=e(R),i=e(R),34===c.charCodeAt(R.offset)?(a='"',f(R,1)):(a=null,0===S&&g('"\\""')),null!==a?(34===c.charCodeAt(R.offset)?(b='"',f(R,1)):(b=null,0===S&&g('"\\""')),null!==b?a=[a,b]:(a=null,R=e(i))):(a=null,R=e(i)),null!==a&&(a=function(a,b,c){return["literal",""].concat([["line",b],["col",c]])}(h.offset,h.line,h.column)),null===a&&(R=e(h)),null===a&&(h=e(R),i=e(R),34===c.charCodeAt(R.offset)?(a='"',f(R,1)):(a=null,0===S&&g('"\\""')),null!==a?(b=E(),null!==b?(34===c.charCodeAt(R.offset)?(d='"',f(R,1)):(d=null,0===S&&g('"\\""')),null!==d?a=[a,b,d]:(a=null,R=e(i))):(a=null,R=e(i))):(a=null,R=e(i)),null!==a&&(a=function(a,b,c,d){return["literal",d].concat([["line",b],["col",c]])}(h.offset,h.line,h.column,a[1])),null===a&&(R=e(h)),null===a)){if(h=e(R),i=e(R),34===c.charCodeAt(R.offset)?(a='"',f(R,1)):(a=null,0===S&&g('"\\""')),null!==a){if(d=C(),null!==d)for(b=[];null!==d;)b.push(d),d=C();else b=null;null!==b?(34===c.charCodeAt(R.offset)?(d='"',f(R,1)):(d=null,0===S&&g('"\\""')),null!==d?a=[a,b,d]:(a=null,R=e(i))):(a=null,R=e(i))}else a=null,R=e(i);null!==a&&(a=function(a,b,c,d){return["body"].concat(d).concat([["line",b],["col",c]])}(h.offset,h.line,h.column,a[1])),null===a&&(R=e(h))}return S--,0===S&&null===a&&g("inline"),a}function C(){var a,b;return a=s(),null===a&&(a=p(),null===a&&(b=e(R),a=E(),null!==a&&(a=function(a,b,c,d){return["buffer",d]}(b.offset,b.line,b.column,a)),null===a&&(R=e(b)))),a}function D(){var a,b,d,h,i,j,k,l,m,n;if(S++,k=e(R),l=e(R),a=N(),null!==a){for(b=[],d=O();null!==d;)b.push(d),d=O();null!==b?a=[a,b]:(a=null,R=e(l))}else a=null,R=e(l);if(null!==a&&(a=function(a,b,c,d,e){return["format",d,e.join("")].concat([["line",b],["col",c]])}(k.offset,k.line,k.column,a[0],a[1])),null===a&&(R=e(k)),null===a){if(k=e(R),l=e(R),m=e(R),n=e(R),S++,b=I(),S--,null===b?b="":(b=null,R=e(n)),null!==b?(n=e(R),S++,d=G(),S--,null===d?d="":(d=null,R=e(n)),null!==d?(n=e(R),S++,h=H(),S--,null===h?h="":(h=null,R=e(n)),null!==h?(n=e(R),S++,i=N(),S--,null===i?i="":(i=null,R=e(n)),null!==i?(c.length>R.offset?(j=c.charAt(R.offset),f(R,1)):(j=null,0===S&&g("any character")),null!==j?b=[b,d,h,i,j]:(b=null,R=e(m))):(b=null,R=e(m))):(b=null,R=e(m))):(b=null,R=e(m))):(b=null,R=e(m)),null!==b&&(b=function(a,b,c,d){return d}(l.offset,l.line,l.column,b[4])),null===b&&(R=e(l)),null!==b)for(a=[];null!==b;)a.push(b),l=e(R),m=e(R),n=e(R),S++,b=I(),S--,null===b?b="":(b=null,R=e(n)),null!==b?(n=e(R),S++,d=G(),S--,null===d?d="":(d=null,R=e(n)),null!==d?(n=e(R),S++,h=H(),S--,null===h?h="":(h=null,R=e(n)),null!==h?(n=e(R),S++,i=N(),S--,null===i?i="":(i=null,R=e(n)),null!==i?(c.length>R.offset?(j=c.charAt(R.offset),f(R,1)):(j=null,0===S&&g("any character")),null!==j?b=[b,d,h,i,j]:(b=null,R=e(m))):(b=null,R=e(m))):(b=null,R=e(m))):(b=null,R=e(m))):(b=null,R=e(m)),null!==b&&(b=function(a,b,c,d){return d}(l.offset,l.line,l.column,b[4])),null===b&&(R=e(l));else a=null;null!==a&&(a=function(a,b,c,d){return["buffer",d.join("")].concat([["line",b],["col",c]])}(k.offset,k.line,k.column,a)),null===a&&(R=e(k))}return S--,0===S&&null===a&&g("buffer"),a}function E(){var a,b,d,h,i,j,k;if(S++,h=e(R),i=e(R),j=e(R),k=e(R),S++,b=I(),S--,null===b?b="":(b=null,R=e(k)),null!==b?(d=F(),null===d&&(/^[^"]/.test(c.charAt(R.offset))?(d=c.charAt(R.offset),f(R,1)):(d=null,0===S&&g('[^"]'))),null!==d?b=[b,d]:(b=null,R=e(j))):(b=null,R=e(j)),null!==b&&(b=function(a,b,c,d){return d}(i.offset,i.line,i.column,b[1])),null===b&&(R=e(i)),null!==b)for(a=[];null!==b;)a.push(b),i=e(R),j=e(R),k=e(R),S++,b=I(),S--,null===b?b="":(b=null,R=e(k)),null!==b?(d=F(),null===d&&(/^[^"]/.test(c.charAt(R.offset))?(d=c.charAt(R.offset),f(R,1)):(d=null,0===S&&g('[^"]'))),null!==d?b=[b,d]:(b=null,R=e(j))):(b=null,R=e(j)),null!==b&&(b=function(a,b,c,d){return d}(i.offset,i.line,i.column,b[1])),null===b&&(R=e(i));else a=null;return null!==a&&(a=function(a,b,c,d){return d.join("")}(h.offset,h.line,h.column,a)),null===a&&(R=e(h)),S--,0===S&&null===a&&g("literal"),a}function F(){var a,b;return b=e(R),'\\"'===c.substr(R.offset,2)?(a='\\"',f(R,2)):(a=null,0===S&&g('"\\\\\\""')),null!==a&&(a=function(){return'"'}(b.offset,b.line,b.column)),null===a&&(R=e(b)),a}function G(){var a,b,d,h,i,j,k,l,m;if(S++,i=e(R),j=e(R),"{`"===c.substr(R.offset,2)?(a="{`",f(R,2)):(a=null,0===S&&g('"{`"')),null!==a){for(b=[],k=e(R),l=e(R),m=e(R),S++,"`}"===c.substr(R.offset,2)?(d="`}",f(R,2)):(d=null,0===S&&g('"`}"')),S--,null===d?d="":(d=null,R=e(m)),null!==d?(c.length>R.offset?(h=c.charAt(R.offset),f(R,1)):(h=null,0===S&&g("any character")),null!==h?d=[d,h]:(d=null,R=e(l))):(d=null,R=e(l)),null!==d&&(d=function(a,b,c,d){return d}(k.offset,k.line,k.column,d[1])),null===d&&(R=e(k));null!==d;)b.push(d),k=e(R),l=e(R),m=e(R),S++,"`}"===c.substr(R.offset,2)?(d="`}",f(R,2)):(d=null,0===S&&g('"`}"')),S--,null===d?d="":(d=null,R=e(m)),null!==d?(c.length>R.offset?(h=c.charAt(R.offset),f(R,1)):(h=null,0===S&&g("any character")),null!==h?d=[d,h]:(d=null,R=e(l))):(d=null,R=e(l)),null!==d&&(d=function(a,b,c,d){return d}(k.offset,k.line,k.column,d[1])),null===d&&(R=e(k));null!==b?("`}"===c.substr(R.offset,2)?(d="`}",f(R,2)):(d=null,0===S&&g('"`}"')),null!==d?a=[a,b,d]:(a=null,R=e(j))):(a=null,R=e(j))}else a=null,R=e(j);return null!==a&&(a=function(a,b,c,d){return["raw",d.join("")].concat([["line",b],["col",c]])}(i.offset,i.line,i.column,a[1])),null===a&&(R=e(i)),S--,0===S&&null===a&&g("raw"),a}function H(){var a,b,d,h,i,j,k,l,m;if(S++,i=e(R),j=e(R),"{!"===c.substr(R.offset,2)?(a="{!",f(R,2)):(a=null,0===S&&g('"{!"')),null!==a){for(b=[],k=e(R),l=e(R),m=e(R),S++,"!}"===c.substr(R.offset,2)?(d="!}",f(R,2)):(d=null,0===S&&g('"!}"')),S--,null===d?d="":(d=null,R=e(m)),null!==d?(c.length>R.offset?(h=c.charAt(R.offset),f(R,1)):(h=null,0===S&&g("any character")),null!==h?d=[d,h]:(d=null,R=e(l))):(d=null,R=e(l)),null!==d&&(d=function(a,b,c,d){return d}(k.offset,k.line,k.column,d[1])),null===d&&(R=e(k));null!==d;)b.push(d),k=e(R),l=e(R),m=e(R),S++,"!}"===c.substr(R.offset,2)?(d="!}",f(R,2)):(d=null,0===S&&g('"!}"')),S--,null===d?d="":(d=null,R=e(m)),null!==d?(c.length>R.offset?(h=c.charAt(R.offset),f(R,1)):(h=null,0===S&&g("any character")),null!==h?d=[d,h]:(d=null,R=e(l))):(d=null,R=e(l)),null!==d&&(d=function(a,b,c,d){return d}(k.offset,k.line,k.column,d[1])),null===d&&(R=e(k));null!==b?("!}"===c.substr(R.offset,2)?(d="!}",f(R,2)):(d=null,0===S&&g('"!}"')),null!==d?a=[a,b,d]:(a=null,R=e(j))):(a=null,R=e(j))}else a=null,R=e(j);return null!==a&&(a=function(a,b,c,d){return["comment",d.join("")].concat([["line",b],["col",c]])}(i.offset,i.line,i.column,a[1])),null===a&&(R=e(i)),S--,0===S&&null===a&&g("comment"),a}function I(){var a,b,d,h,i,j,k,l,m,n,o;if(m=e(R),a=J(),null!==a){for(b=[],d=O();null!==d;)b.push(d),d=O();if(null!==b)if(/^[#?^><+%:@\/~%]/.test(c.charAt(R.offset))?(d=c.charAt(R.offset),f(R,1)):(d=null,0===S&&g("[#?^><+%:@\\/~%]")),null!==d){for(h=[],i=O();null!==i;)h.push(i),i=O();if(null!==h){if(n=e(R),o=e(R),S++,j=K(),S--,null===j?j="":(j=null,R=e(o)),null!==j?(o=e(R),S++,k=N(),S--,null===k?k="":(k=null,R=e(o)),null!==k?(c.length>R.offset?(l=c.charAt(R.offset),f(R,1)):(l=null,0===S&&g("any character")),null!==l?j=[j,k,l]:(j=null,R=e(n))):(j=null,R=e(n))):(j=null,R=e(n)),null!==j)for(i=[];null!==j;)i.push(j),n=e(R),o=e(R),S++,j=K(),S--,null===j?j="":(j=null,R=e(o)),null!==j?(o=e(R),S++,k=N(),S--,null===k?k="":(k=null,R=e(o)),null!==k?(c.length>R.offset?(l=c.charAt(R.offset),f(R,1)):(l=null,0===S&&g("any character")),null!==l?j=[j,k,l]:(j=null,R=e(n))):(j=null,R=e(n))):(j=null,R=e(n));else i=null;if(null!==i){for(j=[],k=O();null!==k;)j.push(k),k=O();null!==j?(k=K(),null!==k?a=[a,b,d,h,i,j,k]:(a=null,R=e(m))):(a=null,R=e(m))}else a=null,R=e(m)}else a=null,R=e(m)}else a=null,R=e(m);else a=null,R=e(m)}else a=null,R=e(m);return null===a&&(a=p()),a}function J(){var a;return 123===c.charCodeAt(R.offset)?(a="{",f(R,1)):(a=null,0===S&&g('"{"')),a}function K(){var a;return 125===c.charCodeAt(R.offset)?(a="}",f(R,1)):(a=null,0===S&&g('"}"')),a}function L(){var a;return 91===c.charCodeAt(R.offset)?(a="[",f(R,1)):(a=null,0===S&&g('"["')),a}function M(){var a;return 93===c.charCodeAt(R.offset)?(a="]",f(R,1)):(a=null,0===S&&g('"]"')),a -}function N(){var a;return 10===c.charCodeAt(R.offset)?(a="\n",f(R,1)):(a=null,0===S&&g('"\\n"')),null===a&&("\r\n"===c.substr(R.offset,2)?(a="\r\n",f(R,2)):(a=null,0===S&&g('"\\r\\n"')),null===a&&(13===c.charCodeAt(R.offset)?(a="\r",f(R,1)):(a=null,0===S&&g('"\\r"')),null===a&&(8232===c.charCodeAt(R.offset)?(a="\u2028",f(R,1)):(a=null,0===S&&g('"\\u2028"')),null===a&&(8233===c.charCodeAt(R.offset)?(a="\u2029",f(R,1)):(a=null,0===S&&g('"\\u2029"')))))),a}function O(){var a;return/^[\t\x0B\f \xA0\uFEFF]/.test(c.charAt(R.offset))?(a=c.charAt(R.offset),f(R,1)):(a=null,0===S&&g("[\\t\\x0B\\f \\xA0\\uFEFF]")),null===a&&(a=N()),a}function P(a){a.sort();for(var b=null,c=[],d=0;dT.offset?R:T;throw new a.SyntaxError(P(U),X,W,Y.line,Y.column)}return V},toSource:function(){return this._source}};return c.SyntaxError=function(a,c,d,e,f){function g(a,c){var d,e;switch(a.length){case 0:d="end of input";break;case 1:d=a[0];break;default:d=a.slice(0,a.length-1).join(", ")+" or "+a[a.length-1]}return e=c?b(c):"end of input","Expected "+d+" but "+e+" found."}this.name="SyntaxError",this.expected=a,this.found=c,this.message=g(a,c),this.offset=d,this.line=e,this.column=f},c.SyntaxError.prototype=Error.prototype,c}();return dust.parse=a.parse,a}),function(a,b){"object"==typeof exports?module.exports=b(require("./parser").parse,require("./dust")):b(a.dust.parse,a.dust)}(this,function(a,dust){function b(a){var b={};return n.filterNode(b,a)}function c(a,b){var c,d,e,f=[b[0]];for(c=1,d=b.length;d>c;c++)e=n.filterNode(a,b[c]),e&&f.push(e);return f}function d(a,b){var c,d,e,f,g=[b[0]];for(d=1,e=b.length;e>d;d++)f=n.filterNode(a,b[d]),f&&("buffer"===f[0]?c?c[1]+=f[1]:(c=f,g.push(f)):(c=null,g.push(f)));return g}function e(a,b){return["buffer",p[b[1]]]}function f(a,b){return b}function g(){}function h(a,b){var c={name:b,bodies:[],blocks:{},index:0,auto:"h"};return"(function(){dust.register("+(b?'"'+b+'"':"null")+","+n.compileNode(c,a)+");"+i(c)+j(c)+"return body_0;})();"}function i(a){var b,c=[],d=a.blocks;for(b in d)c.push('"'+b+'":'+d[b]);return c.length?(a.blocks="ctx=ctx.shiftBlocks(blocks);","var blocks={"+c.join(",")+"};"):a.blocks=""}function j(a){var b,c,d=[],e=a.bodies,f=a.blocks;for(b=0,c=e.length;c>b;b++)d[b]="function body_"+b+"(chk,ctx){"+f+"return chk"+e[b]+";}";return d.join("")}function k(a,b){var c,d,e="";for(c=1,d=b.length;d>c;c++)e+=n.compileNode(a,b[c]);return e}function l(a,b,c){return"."+c+"("+n.compileNode(a,b[1])+","+n.compileNode(a,b[2])+","+n.compileNode(a,b[4])+","+n.compileNode(a,b[3])+")"}function m(a){return a.replace(q,"\\\\").replace(r,'\\"').replace(s,"\\f").replace(t,"\\n").replace(u,"\\r").replace(v,"\\t")}var n={},o=dust.isArray;n.compile=function(c,d){d||null===d||dust.log(new Error("Template name parameter cannot be undefined when calling dust.compile"),"ERROR");try{var e=b(a(c));return h(e,d)}catch(f){if(!f.line||!f.column)throw f;throw new SyntaxError(f.message+" At line : "+f.line+", column : "+f.column)}},n.filterNode=function(a,b){return n.optimizers[b[0]](a,b)},n.optimizers={body:d,buffer:f,special:e,format:g,reference:c,"#":c,"?":c,"^":c,"<":c,"+":c,"@":c,"%":c,partial:c,context:c,params:c,bodies:c,param:c,filters:f,key:f,path:f,literal:f,raw:f,comment:g,line:g,col:g},n.pragmas={esc:function(a,b,c){var d,e=a.auto;return b||(b="h"),a.auto="s"===b?"":b,d=k(a,c.block),a.auto=e,d}};var p={s:" ",n:"\n",r:"\r",lb:"{",rb:"}"};n.compileNode=function(a,b){return n.nodes[b[0]](a,b)},n.nodes={body:function(a,b){var c=a.index++,d="body_"+c;return a.bodies[c]=k(a,b),d},buffer:function(a,b){return".write("+w(b[1])+")"},format:function(a,b){return".write("+w(b[1]+b[2])+")"},reference:function(a,b){return".reference("+n.compileNode(a,b[1])+",ctx,"+n.compileNode(a,b[2])+")"},"#":function(a,b){return l(a,b,"section")},"?":function(a,b){return l(a,b,"exists")},"^":function(a,b){return l(a,b,"notexists")},"<":function(a,b){for(var c=b[4],d=1,e=c.length;e>d;d++){var f=c[d],g=f[1][1];if("block"===g)return a.blocks[b[1].text]=n.compileNode(a,f[2]),""}return""},"+":function(a,b){return"undefined"==typeof b[1].text&&"undefined"==typeof b[4]?".block(ctx.getBlock("+n.compileNode(a,b[1])+",chk, ctx),"+n.compileNode(a,b[2])+", {},"+n.compileNode(a,b[3])+")":".block(ctx.getBlock("+w(b[1].text)+"),"+n.compileNode(a,b[2])+","+n.compileNode(a,b[4])+","+n.compileNode(a,b[3])+")"},"@":function(a,b){return".helper("+w(b[1].text)+","+n.compileNode(a,b[2])+","+n.compileNode(a,b[4])+","+n.compileNode(a,b[3])+")"},"%":function(a,b){var c,d,e,f,g,h,i,j,k,l=b[1][1];if(!n.pragmas[l])return"";for(c=b[4],d={},j=1,k=c.length;k>j;j++)h=c[j],d[h[1][1]]=h[2];for(e=b[3],f={},j=1,k=e.length;k>j;j++)i=e[j],f[i[1][1]]=i[2][1];return g=b[2][1]?b[2][1].text:null,n.pragmas[l](a,g,d,f)},partial:function(a,b){return".partial("+n.compileNode(a,b[1])+","+n.compileNode(a,b[2])+","+n.compileNode(a,b[3])+")"},context:function(a,b){return b[1]?"ctx.rebase("+n.compileNode(a,b[1])+")":"ctx"},params:function(a,b){for(var c=[],d=1,e=b.length;e>d;d++)c.push(n.compileNode(a,b[d]));return c.length?"{"+c.join(",")+"}":"null"},bodies:function(a,b){for(var c=[],d=1,e=b.length;e>d;d++)c.push(n.compileNode(a,b[d]));return"{"+c.join(",")+"}"},param:function(a,b){return n.compileNode(a,b[1])+":"+n.compileNode(a,b[2])},filters:function(a,b){for(var c=[],d=1,e=b.length;e>d;d++){var f=b[d];c.push('"'+f+'"')}return'"'+a.auto+'"'+(c.length?",["+c.join(",")+"]":"")},key:function(a,b){return'ctx.get(["'+b[1]+'"], false)'},path:function(a,b){for(var c=b[1],d=b[2],e=[],f=0,g=d.length;g>f;f++)e.push(o(d[f])?n.compileNode(a,d[f]):'"'+d[f]+'"');return"ctx.getPath("+c+", ["+e.join(",")+"])"},literal:function(a,b){return w(b[1])},raw:function(a,b){return".write("+w(b[1])+")"}};var q=/\\/g,r=/"/g,s=/\f/g,t=/\n/g,u=/\r/g,v=/\t/g,w="undefined"==typeof JSON?function(a){return'"'+m(a)+'"'}:JSON.stringify;return dust.compile=n.compile,dust.filterNode=n.filterNode,dust.optimizers=n.optimizers,dust.pragmas=n.pragmas,dust.compileNode=n.compileNode,dust.nodes=n.nodes,n}); \ No newline at end of file +!function(root){function Context(a,b,c,d){this.stack=a,this.global=b,this.blocks=c,this.templateName=d}function Stack(a,b,c,d){this.tail=b,this.isObject=a&&"object"==typeof a,this.head=a,this.index=c,this.of=d}function Stub(a){this.head=new Chunk(this),this.callback=a,this.out=""}function Stream(){this.head=new Chunk(this)}function Chunk(a,b,c){this.root=a,this.next=b,this.data=[],this.flushable=!1,this.taps=c}function Tap(a,b){this.head=a,this.tail=b}var dust={},NONE="NONE",ERROR="ERROR",WARN="WARN",INFO="INFO",DEBUG="DEBUG",loggingLevels=[DEBUG,INFO,WARN,ERROR,NONE],EMPTY_FUNC=function(){},logger={},originalLog,loggerContext;dust.debugLevel=NONE,dust.silenceErrors=!1,root&&root.console&&root.console.log&&(loggerContext=root.console,originalLog=root.console.log),logger.log=loggerContext?function(){logger.log="function"==typeof originalLog?function(){originalLog.apply(loggerContext,arguments)}:function(){var a=Array.prototype.slice.apply(arguments).join(" ");originalLog(a)},logger.log.apply(this,arguments)}:function(){},dust.log=function(a,b){if(b=b||INFO,dust.debugLevel!==NONE&&dust.indexInArray(loggingLevels,b)>=dust.indexInArray(loggingLevels,dust.debugLevel)&&(dust.logQueue||(dust.logQueue=[]),dust.logQueue.push({message:a,type:b}),logger.log("[DUST "+b+"]: "+a)),!dust.silenceErrors&&b===ERROR)throw"string"==typeof a?new Error(a):a},dust.onError=function(a,b){if(logger.log("[!!!DEPRECATION WARNING!!!]: dust.onError will no longer return a chunk object."),dust.log(a.message||a,ERROR),dust.silenceErrors)return b;throw a},dust.helpers={},dust.cache={},dust.register=function(a,b){a&&(dust.cache[a]=b)},dust.render=function(a,b,c){var d=new Stub(c).head;try{dust.load(a,d,Context.wrap(b,a)).end()}catch(e){dust.log(e,ERROR)}},dust.stream=function(a,b){var c=new Stream;return dust.nextTick(function(){try{dust.load(a,c.head,Context.wrap(b,a)).end()}catch(d){dust.log(d,ERROR)}}),c},dust.renderSource=function(a,b,c){return dust.compileFn(a)(b,c)},dust.compileFn=function(a,b){b=b||null;var c=dust.loadSource(dust.compile(a,b));return function(a,d){var e=d?new Stub(d):new Stream;return dust.nextTick(function(){"function"==typeof c?c(e.head,Context.wrap(a,b)).end():dust.log(new Error("Template ["+b+"] cannot be resolved to a Dust function"),ERROR)}),e}},dust.load=function(a,b,c){var d=dust.cache[a];return d?d(b,c):dust.onLoad?b.map(function(b){dust.onLoad(a,function(d,e){return d?b.setError(d):(dust.cache[a]||dust.loadSource(dust.compile(e,a)),void dust.cache[a](b,c).end())})}):b.setError(new Error("Template Not Found: "+a))},dust.loadSource=function(source,path){return eval(source)},dust.isArray=Array.isArray?Array.isArray:function(a){return"[object Array]"===Object.prototype.toString.call(a)},dust.indexInArray=function(a,b,c){if(c=+c||0,Array.prototype.indexOf)return a.indexOf(b,c);if(void 0===a||null===a)throw new TypeError('cannot call method "indexOf" of null');var d=a.length;for(1/0===Math.abs(c)&&(c=0),0>c&&(c+=d,0>c&&(c=0));d>c;c++)if(a[c]===b)return c;return-1},dust.nextTick=function(){return function(a){setTimeout(a,0)}}(),dust.isEmpty=function(a){return dust.isArray(a)&&!a.length?!0:0===a?!1:!a},dust.filter=function(a,b,c){if(c)for(var d=0,e=c.length;e>d;d++){var f=c[d];"s"===f?b=null:"function"==typeof dust.filters[f]?a=dust.filters[f](a):dust.log("Invalid filter ["+f+"]",WARN)}return b&&(a=dust.filters[b](a)),a},dust.filters={h:function(a){return dust.escapeHtml(a)},j:function(a){return dust.escapeJs(a)},u:encodeURI,uc:encodeURIComponent,js:function(a){return JSON?JSON.stringify(a):(dust.log("JSON is undefined. JSON stringify has not been used on ["+a+"]",WARN),a)},jp:function(a){return JSON?JSON.parse(a):(dust.log("JSON is undefined. JSON parse has not been used on ["+a+"]",WARN),a)}},dust.makeBase=function(a){return new Context(new Stack,a)},Context.wrap=function(a,b){return a instanceof Context?a:new Context(new Stack(a),{},null,b)},Context.prototype.get=function(a,b){return"string"==typeof a&&("."===a[0]&&(b=!0,a=a.substr(1)),a=a.split(".")),this._get(b,a)},Context.prototype._get=function(a,b){var c,d,e,f,g=this.stack,h=1;if(d=b[0],e=b.length,a&&0===e)f=g,g=g.head;else{if(a)g&&(g=g.head?g.head[d]:void 0);else{for(;g&&(!g.isObject||(f=g.head,c=g.head[d],void 0===c));)g=g.tail;g=void 0!==c?c:this.global?this.global[d]:void 0}for(;g&&e>h;)f=g,g=g[b[h]],h++}if("function"==typeof g){var i=function(){try{return g.apply(f,arguments)}catch(a){return dust.log(a,ERROR)}};return i.isFunction=!0,i}return void 0===g&&dust.log("Cannot find the value for reference [{"+b.join(".")+"}] in template ["+this.getTemplateName()+"]"),g},Context.prototype.getPath=function(a,b){return this._get(a,b)},Context.prototype.push=function(a,b,c){return new Context(new Stack(a,this.stack,b,c),this.global,this.blocks,this.getTemplateName())},Context.prototype.rebase=function(a){return new Context(new Stack(a),this.global,this.blocks,this.getTemplateName())},Context.prototype.current=function(){return this.stack.head},Context.prototype.getBlock=function(a){if("function"==typeof a){var b=new Chunk;a=a(b,this).data.join("")}var c=this.blocks;if(!c)return void dust.log("No blocks for context[{"+a+"}] in template ["+this.getTemplateName()+"]",DEBUG);for(var d,e=c.length;e--;)if(d=c[e][a])return d},Context.prototype.shiftBlocks=function(a){var b,c=this.blocks;return a?(b=c?c.concat([a]):[a],new Context(this.stack,this.global,b,this.getTemplateName())):this},Context.prototype.getTemplateName=function(){return this.templateName},Stub.prototype.flush=function(){for(var a=this.head;a;){if(!a.flushable)return a.error?(this.callback(a.error),dust.log("Chunk error ["+a.error+"] thrown. Ceasing to render this template.",WARN),void(this.flush=EMPTY_FUNC)):void 0;this.out+=a.data.join(""),a=a.next,this.head=a}this.callback(null,this.out)},Stream.prototype.flush=function(){for(var a=this.head;a;){if(!a.flushable)return a.error?(this.emit("error",a.error),dust.log("Chunk error ["+a.error+"] thrown. Ceasing to render this template.",WARN),void(this.flush=EMPTY_FUNC)):void 0;this.emit("data",a.data.join("")),a=a.next,this.head=a}this.emit("end")},Stream.prototype.emit=function(a,b){if(!this.events)return dust.log("No events to emit",INFO),!1;var c=this.events[a];if(!c)return dust.log("Event type ["+a+"] does not exist",WARN),!1;if("function"==typeof c)c(b);else if(dust.isArray(c))for(var d=c.slice(0),e=0,f=d.length;f>e;e++)d[e](b);else dust.log("Event Handler ["+c+"] is not of a type that is handled by emit",WARN)},Stream.prototype.on=function(a,b){return this.events||(this.events={}),this.events[a]?"function"==typeof this.events[a]?this.events[a]=[this.events[a],b]:this.events[a].push(b):(dust.log("Event type ["+a+"] does not exist. Using just the specified callback.",WARN),b?this.events[a]=b:dust.log("Callback for type ["+a+"] does not exist. Listener not registered.",WARN)),this},Stream.prototype.pipe=function(a){return this.on("data",function(b){try{a.write(b,"utf8")}catch(c){dust.log(c,ERROR)}}).on("end",function(){try{return a.end()}catch(b){dust.log(b,ERROR)}}).on("error",function(b){a.error(b)}),this},Chunk.prototype.write=function(a){var b=this.taps;return b&&(a=b.go(a)),this.data.push(a),this},Chunk.prototype.end=function(a){return a&&this.write(a),this.flushable=!0,this.root.flush(),this},Chunk.prototype.map=function(a){var b=new Chunk(this.root,this.next,this.taps),c=new Chunk(this.root,b,this.taps);return this.next=c,this.flushable=!0,a(c),b},Chunk.prototype.tap=function(a){var b=this.taps;return this.taps=b?b.push(a):new Tap(a),this},Chunk.prototype.untap=function(){return this.taps=this.taps.tail,this},Chunk.prototype.render=function(a,b){return a(this,b)},Chunk.prototype.reference=function(a,b,c,d){return"function"==typeof a&&(a.isFunction=!0,a=a.apply(b.current(),[this,b,null,{auto:c,filters:d}]),a instanceof Chunk)?a:dust.isEmpty(a)?this:this.write(dust.filter(a,c,d))},Chunk.prototype.section=function(a,b,c,d){if("function"==typeof a&&(a=a.apply(b.current(),[this,b,c,d]),a instanceof Chunk))return a;var e=c.block,f=c["else"];if(d&&(b=b.push(d)),dust.isArray(a)){if(e){var g=a.length,h=this;if(g>0){b.stack.head&&(b.stack.head.$len=g);for(var i=0;g>i;i++)b.stack.head&&(b.stack.head.$idx=i),h=e(h,b.push(a[i],i,g));return b.stack.head&&(b.stack.head.$idx=void 0,b.stack.head.$len=void 0),h}if(f)return f(this,b)}}else if(a===!0){if(e)return e(this,b)}else if(a||0===a){if(e)return e(this,b.push(a))}else if(f)return f(this,b);return dust.log("Not rendering section (#) block in template ["+b.getTemplateName()+"], because above key was not found",DEBUG),this},Chunk.prototype.exists=function(a,b,c){var d=c.block,e=c["else"];if(dust.isEmpty(a)){if(e)return e(this,b)}else if(d)return d(this,b);return dust.log("Not rendering exists (?) block in template ["+b.getTemplateName()+"], because above key was not found",DEBUG),this},Chunk.prototype.notexists=function(a,b,c){var d=c.block,e=c["else"];if(dust.isEmpty(a)){if(d)return d(this,b)}else if(e)return e(this,b);return dust.log("Not rendering not exists (^) block check in template ["+b.getTemplateName()+"], because above key was found",DEBUG),this},Chunk.prototype.block=function(a,b,c){var d=c.block;return a&&(d=a),d?d(this,b):this},Chunk.prototype.partial=function(a,b,c){var d;d=dust.makeBase(b.global),d.blocks=b.blocks,b.stack&&b.stack.tail&&(d.stack=b.stack.tail),c&&(d=d.push(c)),"string"==typeof a&&(d.templateName=a),d=d.push(b.stack.head);var e;return e="function"==typeof a?this.capture(a,d,function(a,b){d.templateName=d.templateName||a,dust.load(a,b,d).end()}):dust.load(a,this,d)},Chunk.prototype.helper=function(a,b,c,d){var e=this;try{return dust.helpers[a]?dust.helpers[a](e,b,c,d):(dust.log("Invalid helper ["+a+"]",WARN),e)}catch(f){return dust.log(f,ERROR),e}},Chunk.prototype.capture=function(a,b,c){return this.map(function(d){var e=new Stub(function(a,b){a?d.setError(a):c(b,d)});a(e.head,b).end()})},Chunk.prototype.setError=function(a){return this.error=a,this.root.flush(),this},Tap.prototype.push=function(a){return new Tap(a,this)},Tap.prototype.go=function(a){for(var b=this;b;)a=b.head(a),b=b.tail;return a};var HCHARS=new RegExp(/[&<>\"\']/),AMP=/&/g,LT=//g,QUOT=/\"/g,SQUOT=/\'/g;dust.escapeHtml=function(a){return"string"==typeof a&&HCHARS.test(a)?a.replace(AMP,"&").replace(LT,"<").replace(GT,">").replace(QUOT,""").replace(SQUOT,"'"):a};var BS=/\\/g,FS=/\//g,CR=/\r/g,LS=/\u2028/g,PS=/\u2029/g,NL=/\n/g,LF=/\f/g,SQ=/'/g,DQ=/"/g,TB=/\t/g;dust.escapeJs=function(a){return"string"==typeof a?a.replace(BS,"\\\\").replace(FS,"\\/").replace(DQ,'\\"').replace(SQ,"\\'").replace(CR,"\\r").replace(LS,"\\u2028").replace(PS,"\\u2029").replace(NL,"\\n").replace(LF,"\\f").replace(TB,"\\t"):a},"object"==typeof exports?module.exports=dust:root.dust=dust}(function(){return this}()),function(a,b){"object"==typeof exports?module.exports=b(require("./dust")):b(a.dust)}(this,function(dust){var a=function(){function a(a,b){function c(){this.constructor=a}c.prototype=b.prototype,a.prototype=new c}function b(a,b,c,d,e,f){this.message=a,this.expected=b,this.found=c,this.offset=d,this.line=e,this.column=f,this.name="SyntaxError"}function c(a){function c(){return f(nd).line}function d(){return f(nd).column}function e(a){throw h(a,null,nd)}function f(b){function c(b,c,d){var e,f;for(e=c;d>e;e++)f=a.charAt(e),"\n"===f?(b.seenCR||b.line++,b.column=1,b.seenCR=!1):"\r"===f||"\u2028"===f||"\u2029"===f?(b.line++,b.column=1,b.seenCR=!0):(b.column++,b.seenCR=!1)}return od!==b&&(od>b&&(od=0,pd={line:1,column:1,seenCR:!1}),c(pd,od,b),od=b),pd}function g(a){qd>md||(md>qd&&(qd=md,rd=[]),rd.push(a))}function h(c,d,e){function g(a){var b=1;for(a.sort(function(a,b){return a.descriptionb.description?1:0});b1?g.slice(0,-1).join(", ")+" or "+g[a.length-1]:g[0],e=b?'"'+c(b)+'"':"end of input","Expected "+d+" but "+e+" found."}var i=f(e),j=emd?(j=a.charAt(md),md++):(j=T,0===sd&&g(vc)),j!==T?(nd=d,e=wc(j),d=e):(md=d,d=Y)):(md=d,d=Y)):(md=d,d=Y)):(md=d,d=Y)):(md=d,d=Y),d!==T)for(;d!==T;)c.push(d),d=md,e=md,sd++,f=K(),sd--,f===T?e=_:(md=e,e=Y),e!==T?(f=md,sd++,h=I(),sd--,h===T?f=_:(md=f,f=Y),f!==T?(h=md,sd++,i=J(),sd--,i===T?h=_:(md=h,h=Y),h!==T?(i=md,sd++,j=P(),sd--,j===T?i=_:(md=i,i=Y),i!==T?(a.length>md?(j=a.charAt(md),md++):(j=T,0===sd&&g(vc)),j!==T?(nd=d,e=wc(j),d=e):(md=d,d=Y)):(md=d,d=Y)):(md=d,d=Y)):(md=d,d=Y)):(md=d,d=Y);else c=Y;c!==T&&(nd=b,c=xc(c)),b=c}return sd--,b===T&&(c=T,0===sd&&g(tc)),b}function G(){var b,c,d,e,f;if(sd++,b=md,c=[],d=md,e=md,sd++,f=K(),sd--,f===T?e=_:(md=e,e=Y),e!==T?(f=H(),f===T&&(zc.test(a.charAt(md))?(f=a.charAt(md),md++):(f=T,0===sd&&g(Ac))),f!==T?(nd=d,e=wc(f),d=e):(md=d,d=Y)):(md=d,d=Y),d!==T)for(;d!==T;)c.push(d),d=md,e=md,sd++,f=K(),sd--,f===T?e=_:(md=e,e=Y),e!==T?(f=H(),f===T&&(zc.test(a.charAt(md))?(f=a.charAt(md),md++):(f=T,0===sd&&g(Ac))),f!==T?(nd=d,e=wc(f),d=e):(md=d,d=Y)):(md=d,d=Y);else c=Y;return c!==T&&(nd=b,c=Bc(c)),b=c,sd--,b===T&&(c=T,0===sd&&g(yc)),b}function H(){var b,c;return b=md,a.substr(md,2)===Cc?(c=Cc,md+=2):(c=T,0===sd&&g(Dc)),c!==T&&(nd=b,c=Ec()),b=c}function I(){var b,c,d,e,f,h;if(sd++,b=md,a.substr(md,2)===Gc?(c=Gc,md+=2):(c=T,0===sd&&g(Hc)),c!==T){for(d=[],e=md,f=md,sd++,a.substr(md,2)===Ic?(h=Ic,md+=2):(h=T,0===sd&&g(Jc)),sd--,h===T?f=_:(md=f,f=Y),f!==T?(a.length>md?(h=a.charAt(md),md++):(h=T,0===sd&&g(vc)),h!==T?(nd=e,f=Kc(h),e=f):(md=e,e=Y)):(md=e,e=Y);e!==T;)d.push(e),e=md,f=md,sd++,a.substr(md,2)===Ic?(h=Ic,md+=2):(h=T,0===sd&&g(Jc)),sd--,h===T?f=_:(md=f,f=Y),f!==T?(a.length>md?(h=a.charAt(md),md++):(h=T,0===sd&&g(vc)),h!==T?(nd=e,f=Kc(h),e=f):(md=e,e=Y)):(md=e,e=Y);d!==T?(a.substr(md,2)===Ic?(e=Ic,md+=2):(e=T,0===sd&&g(Jc)),e!==T?(nd=b,c=Lc(d),b=c):(md=b,b=Y)):(md=b,b=Y)}else md=b,b=Y;return sd--,b===T&&(c=T,0===sd&&g(Fc)),b}function J(){var b,c,d,e,f,h;if(sd++,b=md,a.substr(md,2)===Nc?(c=Nc,md+=2):(c=T,0===sd&&g(Oc)),c!==T){for(d=[],e=md,f=md,sd++,a.substr(md,2)===Pc?(h=Pc,md+=2):(h=T,0===sd&&g(Qc)),sd--,h===T?f=_:(md=f,f=Y),f!==T?(a.length>md?(h=a.charAt(md),md++):(h=T,0===sd&&g(vc)),h!==T?(nd=e,f=wc(h),e=f):(md=e,e=Y)):(md=e,e=Y);e!==T;)d.push(e),e=md,f=md,sd++,a.substr(md,2)===Pc?(h=Pc,md+=2):(h=T,0===sd&&g(Qc)),sd--,h===T?f=_:(md=f,f=Y),f!==T?(a.length>md?(h=a.charAt(md),md++):(h=T,0===sd&&g(vc)),h!==T?(nd=e,f=wc(h),e=f):(md=e,e=Y)):(md=e,e=Y);d!==T?(a.substr(md,2)===Pc?(e=Pc,md+=2):(e=T,0===sd&&g(Qc)),e!==T?(nd=b,c=Rc(d),b=c):(md=b,b=Y)):(md=b,b=Y)}else md=b,b=Y;return sd--,b===T&&(c=T,0===sd&&g(Mc)),b}function K(){var b,c,d,e,f,h,i,j,k,l;if(b=md,c=L(),c!==T){for(d=[],e=Q();e!==T;)d.push(e),e=Q();if(d!==T)if(Sc.test(a.charAt(md))?(e=a.charAt(md),md++):(e=T,0===sd&&g(Tc)),e!==T){for(f=[],h=Q();h!==T;)f.push(h),h=Q();if(f!==T){if(h=[],i=md,j=md,sd++,k=M(),sd--,k===T?j=_:(md=j,j=Y),j!==T?(k=md,sd++,l=P(),sd--,l===T?k=_:(md=k,k=Y),k!==T?(a.length>md?(l=a.charAt(md),md++):(l=T,0===sd&&g(vc)),l!==T?(j=[j,k,l],i=j):(md=i,i=Y)):(md=i,i=Y)):(md=i,i=Y),i!==T)for(;i!==T;)h.push(i),i=md,j=md,sd++,k=M(),sd--,k===T?j=_:(md=j,j=Y),j!==T?(k=md,sd++,l=P(),sd--,l===T?k=_:(md=k,k=Y),k!==T?(a.length>md?(l=a.charAt(md),md++):(l=T,0===sd&&g(vc)),l!==T?(j=[j,k,l],i=j):(md=i,i=Y)):(md=i,i=Y)):(md=i,i=Y);else h=Y;if(h!==T){for(i=[],j=Q();j!==T;)i.push(j),j=Q();i!==T?(j=M(),j!==T?(c=[c,d,e,f,h,i,j],b=c):(md=b,b=Y)):(md=b,b=Y)}else md=b,b=Y}else md=b,b=Y}else md=b,b=Y;else md=b,b=Y}else md=b,b=Y;return b===T&&(b=r()),b}function L(){var b;return 123===a.charCodeAt(md)?(b=Uc,md++):(b=T,0===sd&&g(Vc)),b}function M(){var b;return 125===a.charCodeAt(md)?(b=Wc,md++):(b=T,0===sd&&g(Xc)),b}function N(){var b;return 91===a.charCodeAt(md)?(b=Yc,md++):(b=T,0===sd&&g(Zc)),b}function O(){var b;return 93===a.charCodeAt(md)?(b=$c,md++):(b=T,0===sd&&g(_c)),b}function P(){var b;return 10===a.charCodeAt(md)?(b=ad,md++):(b=T,0===sd&&g(bd)),b===T&&(a.substr(md,2)===cd?(b=cd,md+=2):(b=T,0===sd&&g(dd)),b===T&&(13===a.charCodeAt(md)?(b=ed,md++):(b=T,0===sd&&g(fd)),b===T&&(8232===a.charCodeAt(md)?(b=gd,md++):(b=T,0===sd&&g(hd)),b===T&&(8233===a.charCodeAt(md)?(b=id,md++):(b=T,0===sd&&g(jd)))))),b}function Q(){var b;return kd.test(a.charAt(md))?(b=a.charAt(md),md++):(b=T,0===sd&&g(ld)),b===T&&(b=P()),b}var R,S=arguments.length>1?arguments[1]:{},T={},U={start:i},V=i,W=function(a){return["body"].concat(a).concat([["line",c()],["col",d()]])},X={type:"other",description:"section"},Y=T,Z=null,$=function(a,b,c,d){return d&&a[1].text===d.text||e("Expected end tag for "+a[1].text+" but it was not found."),!0},_=void 0,ab=function(a,b,e){return e.push(["param",["literal","block"],b]),a.push(e),a.concat([["line",c()],["col",d()]])},bb="/",cb={type:"literal",value:"/",description:'"/"'},db=function(a){return a.push(["bodies"]),a.concat([["line",c()],["col",d()]])},eb=/^[#?\^<+@%]/,fb={type:"class",value:"[#?\\^<+@%]",description:"[#?\\^<+@%]"},gb=function(a,b,c,d){return[a,b,c,d]},hb={type:"other",description:"end tag"},ib=function(a){return a},jb=":",kb={type:"literal",value:":",description:'":"'},lb=function(a){return a},mb=function(a){return a?["context",a]:["context"]},nb={type:"other",description:"params"},ob="=",pb={type:"literal",value:"=",description:'"="'},qb=function(a,b){return["param",["literal",a],b]},rb=function(a){return["params"].concat(a)},sb={type:"other",description:"bodies"},tb=function(a){return["bodies"].concat(a)},ub={type:"other",description:"reference"},vb=function(a,b){return["reference",a,b].concat([["line",c()],["col",d()]])},wb={type:"other",description:"partial"},xb=">",yb={type:"literal",value:">",description:'">"'},zb="+",Ab={type:"literal",value:"+",description:'"+"'},Bb=function(a){return["literal",a]},Cb=function(a,b,e,f){var g=">"===a?"partial":a;return[g,b,e,f].concat([["line",c()],["col",d()]])},Db={type:"other",description:"filters"},Eb="|",Fb={type:"literal",value:"|",description:'"|"'},Gb=function(a){return["filters"].concat(a)},Hb={type:"other",description:"special"},Ib="~",Jb={type:"literal",value:"~",description:'"~"'},Kb=function(a){return["special",a].concat([["line",c()],["col",d()]])},Lb={type:"other",description:"identifier"},Mb=function(a){var b=["path"].concat(a);return b.text=a[1].join("."),b},Nb=function(a){var b=["key",a];return b.text=a,b},Ob={type:"other",description:"number"},Pb=function(a){return["literal",a]},Qb={type:"other",description:"float"},Rb=".",Sb={type:"literal",value:".",description:'"."'},Tb=function(a,b){return parseFloat(a+"."+b.join(""))},Ub={type:"other",description:"integer"},Vb=/^[0-9]/,Wb={type:"class",value:"[0-9]",description:"[0-9]"},Xb=function(a){return parseInt(a.join(""),10)},Yb={type:"other",description:"path"},Zb=function(a,b){return b=b[0],a&&b?(b.unshift(a),[!1,b].concat([["line",c()],["col",d()]])):[!0,b].concat([["line",c()],["col",d()]])},$b=function(a){return a.length>0?[!0,a[0]].concat([["line",c()],["col",d()]]):[!0,[]].concat([["line",c()],["col",d()]])},_b={type:"other",description:"key"},ac=/^[a-zA-Z_$]/,bc={type:"class",value:"[a-zA-Z_$]",description:"[a-zA-Z_$]"},cc=/^[0-9a-zA-Z_$\-]/,dc={type:"class",value:"[0-9a-zA-Z_$\\-]",description:"[0-9a-zA-Z_$\\-]"},ec=function(a,b){return a+b.join("")},fc={type:"other",description:"array"},gc=function(a){return a.join("")},hc=function(a){return a},ic=function(a,b){return b?b.unshift(a):b=[a],b},jc={type:"other",description:"array_part"},kc=function(a){return a},lc=function(a,b){return b?a.concat(b):a},mc={type:"other",description:"inline"},nc='"',oc={type:"literal",value:'"',description:'"\\""'},pc=function(){return["literal",""].concat([["line",c()],["col",d()]])},qc=function(a){return["literal",a].concat([["line",c()],["col",d()]])},rc=function(a){return["body"].concat(a).concat([["line",c()],["col",d()]])},sc=function(a){return["buffer",a]},tc={type:"other",description:"buffer"},uc=function(a,b){return["format",a,b.join("")].concat([["line",c()],["col",d()]])},vc={type:"any",description:"any character"},wc=function(a){return a},xc=function(a){return["buffer",a.join("")].concat([["line",c()],["col",d()]])},yc={type:"other",description:"literal"},zc=/^[^"]/,Ac={type:"class",value:'[^"]',description:'[^"]'},Bc=function(a){return a.join("")},Cc='\\"',Dc={type:"literal",value:'\\"',description:'"\\\\\\""'},Ec=function(){return'"'},Fc={type:"other",description:"raw"},Gc="{`",Hc={type:"literal",value:"{`",description:'"{`"'},Ic="`}",Jc={type:"literal",value:"`}",description:'"`}"'},Kc=function(a){return a},Lc=function(a){return["raw",a.join("")].concat([["line",c()],["col",d()]])},Mc={type:"other",description:"comment"},Nc="{!",Oc={type:"literal",value:"{!",description:'"{!"'},Pc="!}",Qc={type:"literal",value:"!}",description:'"!}"'},Rc=function(a){return["comment",a.join("")].concat([["line",c()],["col",d()]])},Sc=/^[#?\^><+%:@\/~%]/,Tc={type:"class",value:"[#?\\^><+%:@\\/~%]",description:"[#?\\^><+%:@\\/~%]"},Uc="{",Vc={type:"literal",value:"{",description:'"{"'},Wc="}",Xc={type:"literal",value:"}",description:'"}"'},Yc="[",Zc={type:"literal",value:"[",description:'"["'},$c="]",_c={type:"literal",value:"]",description:'"]"'},ad="\n",bd={type:"literal",value:"\n",description:'"\\n"'},cd="\r\n",dd={type:"literal",value:"\r\n",description:'"\\r\\n"'},ed="\r",fd={type:"literal",value:"\r",description:'"\\r"'},gd="\u2028",hd={type:"literal",value:"\u2028",description:'"\\u2028"'},id="\u2029",jd={type:"literal",value:"\u2029",description:'"\\u2029"'},kd=/^[\t\x0B\f \xA0\uFEFF]/,ld={type:"class",value:"[\\t\\x0B\\f \\xA0\\uFEFF]",description:"[\\t\\x0B\\f \\xA0\\uFEFF]"},md=0,nd=0,od=0,pd={line:1,column:1,seenCR:!1},qd=0,rd=[],sd=0;if("startRule"in S){if(!(S.startRule in U))throw new Error("Can't start parsing from rule \""+S.startRule+'".');V=U[S.startRule]}if(R=V(),R!==T&&md===a.length)return R;throw R!==T&&mdc;c++)e=n.filterNode(a,b[c]),e&&f.push(e);return f}function d(a,b){var c,d,e,f,g=[b[0]];for(d=1,e=b.length;e>d;d++)f=n.filterNode(a,b[d]),f&&("buffer"===f[0]?c?c[1]+=f[1]:(c=f,g.push(f)):(c=null,g.push(f)));return g}function e(a,b){return["buffer",p[b[1]]]}function f(a,b){return b}function g(){}function h(a,b){var c={name:b,bodies:[],blocks:{},index:0,auto:"h"};return"(function(){dust.register("+(b?'"'+b+'"':"null")+","+n.compileNode(c,a)+");"+i(c)+j(c)+"return body_0;})();"}function i(a){var b,c=[],d=a.blocks;for(b in d)c.push('"'+b+'":'+d[b]);return c.length?(a.blocks="ctx=ctx.shiftBlocks(blocks);","var blocks={"+c.join(",")+"};"):a.blocks=""}function j(a){var b,c,d=[],e=a.bodies,f=a.blocks;for(b=0,c=e.length;c>b;b++)d[b]="function body_"+b+"(chk,ctx){"+f+"return chk"+e[b]+";}";return d.join("")}function k(a,b){var c,d,e="";for(c=1,d=b.length;d>c;c++)e+=n.compileNode(a,b[c]);return e}function l(a,b,c){return"."+c+"("+n.compileNode(a,b[1])+","+n.compileNode(a,b[2])+","+n.compileNode(a,b[4])+","+n.compileNode(a,b[3])+")"}function m(a){return a.replace(q,"\\\\").replace(r,'\\"').replace(s,"\\f").replace(t,"\\n").replace(u,"\\r").replace(v,"\\t") +}var n={},o=dust.isArray;n.compile=function(c,d){d||null===d||dust.log(new Error("Template name parameter cannot be undefined when calling dust.compile"),"ERROR");try{var e=b(a(c));return h(e,d)}catch(f){if(!f.line||!f.column)throw f;throw new SyntaxError(f.message+" At line : "+f.line+", column : "+f.column)}},n.filterNode=function(a,b){return n.optimizers[b[0]](a,b)},n.optimizers={body:d,buffer:f,special:e,format:g,reference:c,"#":c,"?":c,"^":c,"<":c,"+":c,"@":c,"%":c,partial:c,context:c,params:c,bodies:c,param:c,filters:f,key:f,path:f,literal:f,raw:f,comment:g,line:g,col:g},n.pragmas={esc:function(a,b,c){var d,e=a.auto;return b||(b="h"),a.auto="s"===b?"":b,d=k(a,c.block),a.auto=e,d}};var p={s:" ",n:"\n",r:"\r",lb:"{",rb:"}"};n.compileNode=function(a,b){return n.nodes[b[0]](a,b)},n.nodes={body:function(a,b){var c=a.index++,d="body_"+c;return a.bodies[c]=k(a,b),d},buffer:function(a,b){return".write("+w(b[1])+")"},format:function(a,b){return".write("+w(b[1]+b[2])+")"},reference:function(a,b){return".reference("+n.compileNode(a,b[1])+",ctx,"+n.compileNode(a,b[2])+")"},"#":function(a,b){return l(a,b,"section")},"?":function(a,b){return l(a,b,"exists")},"^":function(a,b){return l(a,b,"notexists")},"<":function(a,b){for(var c=b[4],d=1,e=c.length;e>d;d++){var f=c[d],g=f[1][1];if("block"===g)return a.blocks[b[1].text]=n.compileNode(a,f[2]),""}return""},"+":function(a,b){return"undefined"==typeof b[1].text&&"undefined"==typeof b[4]?".block(ctx.getBlock("+n.compileNode(a,b[1])+",chk, ctx),"+n.compileNode(a,b[2])+", {},"+n.compileNode(a,b[3])+")":".block(ctx.getBlock("+w(b[1].text)+"),"+n.compileNode(a,b[2])+","+n.compileNode(a,b[4])+","+n.compileNode(a,b[3])+")"},"@":function(a,b){return".helper("+w(b[1].text)+","+n.compileNode(a,b[2])+","+n.compileNode(a,b[4])+","+n.compileNode(a,b[3])+")"},"%":function(a,b){var c,d,e,f,g,h,i,j,k,l=b[1][1];if(!n.pragmas[l])return"";for(c=b[4],d={},j=1,k=c.length;k>j;j++)h=c[j],d[h[1][1]]=h[2];for(e=b[3],f={},j=1,k=e.length;k>j;j++)i=e[j],f[i[1][1]]=i[2][1];return g=b[2][1]?b[2][1].text:null,n.pragmas[l](a,g,d,f)},partial:function(a,b){return".partial("+n.compileNode(a,b[1])+","+n.compileNode(a,b[2])+","+n.compileNode(a,b[3])+")"},context:function(a,b){return b[1]?"ctx.rebase("+n.compileNode(a,b[1])+")":"ctx"},params:function(a,b){for(var c=[],d=1,e=b.length;e>d;d++)c.push(n.compileNode(a,b[d]));return c.length?"{"+c.join(",")+"}":"null"},bodies:function(a,b){for(var c=[],d=1,e=b.length;e>d;d++)c.push(n.compileNode(a,b[d]));return"{"+c.join(",")+"}"},param:function(a,b){return n.compileNode(a,b[1])+":"+n.compileNode(a,b[2])},filters:function(a,b){for(var c=[],d=1,e=b.length;e>d;d++){var f=b[d];c.push('"'+f+'"')}return'"'+a.auto+'"'+(c.length?",["+c.join(",")+"]":"")},key:function(a,b){return'ctx.get(["'+b[1]+'"], false)'},path:function(a,b){for(var c=b[1],d=b[2],e=[],f=0,g=d.length;g>f;f++)e.push(o(d[f])?n.compileNode(a,d[f]):'"'+d[f]+'"');return"ctx.getPath("+c+", ["+e.join(",")+"])"},literal:function(a,b){return w(b[1])},raw:function(a,b){return".write("+w(b[1])+")"}};var q=/\\/g,r=/"/g,s=/\f/g,t=/\n/g,u=/\r/g,v=/\t/g,w="undefined"==typeof JSON?function(a){return'"'+m(a)+'"'}:JSON.stringify;return dust.compile=n.compile,dust.filterNode=n.filterNode,dust.optimizers=n.optimizers,dust.pragmas=n.pragmas,dust.compileNode=n.compileNode,dust.nodes=n.nodes,n}); \ No newline at end of file diff --git a/package.json b/package.json index 1ddd398a..90c74765 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "dustjs-linkedin", "title": "Dust - Asynchronous Templating", - "version": "2.3.5", + "version": "2.3.6", "author": { "name": "Aleksander Williams", "url": "http://akdubya.github.com/dustjs"