|
|
|
@ -121,11 +121,18 @@
|
|
|
|
|
descriptions.length = j;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return descriptions.length > 1
|
|
|
|
|
? descriptions.slice(0, -1).join(", ")
|
|
|
|
|
+ " or "
|
|
|
|
|
+ descriptions[descriptions.length - 1]
|
|
|
|
|
: descriptions[0];
|
|
|
|
|
switch (descriptions.length) {
|
|
|
|
|
case 1:
|
|
|
|
|
return descriptions[0];
|
|
|
|
|
|
|
|
|
|
case 2:
|
|
|
|
|
return descriptions[0] + " or " + descriptions[1];
|
|
|
|
|
|
|
|
|
|
default:
|
|
|
|
|
return descriptions.slice(0, -1).join(", ")
|
|
|
|
|
+ ", or "
|
|
|
|
|
+ descriptions[descriptions.length - 1];
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function describeFound(found) {
|
|
|
|
@ -138,9 +145,7 @@
|
|
|
|
|
function peg$parse(input, options) {
|
|
|
|
|
options = options !== void 0 ? options : {};
|
|
|
|
|
|
|
|
|
|
var parser = this,
|
|
|
|
|
|
|
|
|
|
peg$FAILED = {},
|
|
|
|
|
var peg$FAILED = {},
|
|
|
|
|
|
|
|
|
|
peg$startRuleFunctions = { Grammar: peg$parseGrammar },
|
|
|
|
|
peg$startRuleFunction = peg$parseGrammar,
|
|
|
|
|