mirror of
https://github.com/github/codeql.git
synced 2026-04-30 19:26:02 +02:00
Merge pull request #461 from xiemaisi/js/bye-bye-rhino
Approved by esben-semmle
This commit is contained in:
@@ -21,6 +21,10 @@ public class SourceLocation {
|
||||
this(source, start, null);
|
||||
}
|
||||
|
||||
public SourceLocation(SourceLocation that) {
|
||||
this(that.source, that.start, that.end);
|
||||
}
|
||||
|
||||
/**
|
||||
* The source code contained in this location.
|
||||
*/
|
||||
|
||||
@@ -7,6 +7,20 @@ import com.semmle.js.ast.SourceLocation;
|
||||
* An error encountered while parsing a regular expression.
|
||||
*/
|
||||
public class Error extends SourceElement {
|
||||
public static final int UNEXPECTED_EOS = 0;
|
||||
public static final int UNEXPECTED_CHARACTER = 1;
|
||||
public static final int EXPECTED_DIGIT = 2;
|
||||
public static final int EXPECTED_HEX_DIGIT = 3;
|
||||
public static final int EXPECTED_CONTROL_LETTER = 4;
|
||||
public static final int EXPECTED_CLOSING_PAREN = 5;
|
||||
public static final int EXPECTED_CLOSING_BRACE = 6;
|
||||
public static final int EXPECTED_EOS = 7;
|
||||
public static final int OCTAL_ESCAPE = 8;
|
||||
public static final int INVALID_BACKREF = 9;
|
||||
public static final int EXPECTED_RBRACKET = 10;
|
||||
public static final int EXPECTED_IDENTIFIER = 11;
|
||||
public static final int EXPECTED_CLOSING_ANGLE = 12;
|
||||
|
||||
private final int code;
|
||||
|
||||
public Error(SourceLocation loc, Number code) {
|
||||
|
||||
@@ -39,7 +39,7 @@ public class Main {
|
||||
* such a way that it may produce different tuples for the same file under the same
|
||||
* {@link ExtractorConfig}.
|
||||
*/
|
||||
public static final String EXTRACTOR_VERSION = "2018-10-16";
|
||||
public static final String EXTRACTOR_VERSION = "2018-11-12";
|
||||
|
||||
public static final Pattern NEWLINE = Pattern.compile("\n");
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,17 +1,9 @@
|
||||
package com.semmle.js.parser;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.mozilla.javascript.Function;
|
||||
import org.mozilla.javascript.NativeArray;
|
||||
import org.mozilla.javascript.NativeObject;
|
||||
import org.mozilla.javascript.ScriptableObject;
|
||||
|
||||
import com.semmle.js.ast.Position;
|
||||
import com.semmle.js.ast.SourceLocation;
|
||||
import com.semmle.js.ast.regexp.BackReference;
|
||||
import com.semmle.js.ast.regexp.Caret;
|
||||
@@ -47,54 +39,9 @@ import com.semmle.js.ast.regexp.ZeroWidthPositiveLookahead;
|
||||
import com.semmle.js.ast.regexp.ZeroWidthPositiveLookbehind;
|
||||
|
||||
/**
|
||||
* Wrapper for invoking esregex through Rhino.
|
||||
* A parser for ECMAScript 2018 regular expressions.
|
||||
*/
|
||||
public class RegExpParser extends ScriptLoader {
|
||||
/**
|
||||
* Specification for esregex AST types.
|
||||
*/
|
||||
private static final Map<Class<? extends RegExpTerm>, List<String>> spec = new LinkedHashMap<Class<? extends RegExpTerm>, List<String>>();
|
||||
static {
|
||||
spec.put(BackReference.class, Arrays.asList("value", "raw"));
|
||||
spec.put(Caret.class, Collections.<String>emptyList());
|
||||
spec.put(CharacterClass.class, Arrays.asList("elements", "inverted"));
|
||||
spec.put(CharacterClassEscape.class, Arrays.asList("class", "raw"));
|
||||
spec.put(CharacterClassRange.class, Arrays.asList("left", "right"));
|
||||
spec.put(Constant.class, Arrays.asList("value"));
|
||||
spec.put(ControlEscape.class, Arrays.asList("value", "codepoint", "raw"));
|
||||
spec.put(ControlLetter.class, Arrays.asList("value", "codepoint", "raw"));
|
||||
spec.put(DecimalEscape.class, Arrays.asList("value", "codepoint", "raw"));
|
||||
spec.put(Disjunction.class, Arrays.asList("disjuncts"));
|
||||
spec.put(Dollar.class, Collections.<String>emptyList());
|
||||
spec.put(Dot.class, Collections.<String>emptyList());
|
||||
spec.put(Group.class, Arrays.asList("capture", "number", "name", "operand"));
|
||||
spec.put(HexEscapeSequence.class, Arrays.asList("value", "codepoint", "raw"));
|
||||
spec.put(IdentityEscape.class, Arrays.asList("value", "codepoint", "raw"));
|
||||
spec.put(NamedBackReference.class, Arrays.asList("name", "raw"));
|
||||
spec.put(NonWordBoundary.class, Collections.<String>emptyList());
|
||||
spec.put(OctalEscape.class, Arrays.asList("value", "codepoint", "raw"));
|
||||
spec.put(Opt.class, Arrays.asList("operand", "greedy"));
|
||||
spec.put(Plus.class, Arrays.asList("operand", "greedy"));
|
||||
spec.put(Range.class, Arrays.asList("operand", "greedy", "lo", "hi"));
|
||||
spec.put(Sequence.class, Arrays.asList("elements"));
|
||||
spec.put(Star.class, Arrays.asList("operand", "greedy"));
|
||||
spec.put(UnicodeEscapeSequence.class, Arrays.asList("value", "codepoint", "raw"));
|
||||
spec.put(WordBoundary.class, Collections.<String>emptyList());
|
||||
spec.put(ZeroWidthNegativeLookahead.class, Arrays.asList("operand"));
|
||||
spec.put(ZeroWidthPositiveLookahead.class, Arrays.asList("operand"));
|
||||
spec.put(ZeroWidthNegativeLookbehind.class, Arrays.asList("operand"));
|
||||
spec.put(ZeroWidthPositiveLookbehind.class, Arrays.asList("operand"));
|
||||
spec.put(UnicodePropertyEscape.class, Arrays.asList("name", "value", "raw"));
|
||||
}
|
||||
|
||||
/**
|
||||
* Specification for esregex parse errors.
|
||||
*/
|
||||
private static final Map<Class<? extends Error>, List<String>> errspec = new LinkedHashMap<Class<? extends Error>, List<String>>();
|
||||
static {
|
||||
errspec.put(Error.class, Arrays.asList("code"));
|
||||
}
|
||||
|
||||
public class RegExpParser {
|
||||
/**
|
||||
* The result of a parse.
|
||||
*/
|
||||
@@ -102,12 +49,12 @@ public class RegExpParser extends ScriptLoader {
|
||||
/**
|
||||
* The root of the parsed AST.
|
||||
*/
|
||||
private final RegExpTerm ast;
|
||||
public final RegExpTerm ast;
|
||||
|
||||
/**
|
||||
* A list of errors encountered during parsing.
|
||||
*/
|
||||
private final List<Error> errors;
|
||||
public final List<Error> errors;
|
||||
|
||||
public Result(RegExpTerm ast, List<Error> errors) {
|
||||
this.ast = ast;
|
||||
@@ -123,28 +70,450 @@ public class RegExpParser extends ScriptLoader {
|
||||
}
|
||||
}
|
||||
|
||||
public RegExpParser() {
|
||||
super("/regexparser.js");
|
||||
}
|
||||
private String src;
|
||||
private int pos;
|
||||
private List<Error> errors;
|
||||
private List<BackReference> backrefs;
|
||||
private int maxbackref;
|
||||
|
||||
/**
|
||||
* Parse the given string as a regular expression.
|
||||
*/
|
||||
public Result parse(String src) {
|
||||
Function ctor = (Function)readGlobal("RegExpParser");
|
||||
ScriptableObject parser = construct(ctor, src);
|
||||
NativeObject ast = (NativeObject)callMethod(parser, "Pattern");
|
||||
NativeArray errors = (NativeArray)readProperty(parser, "errors");
|
||||
JSObjectDecoder<RegExpTerm> decoder = new JSObjectDecoder<RegExpTerm>(src, this, "com.semmle.js.ast.regexp", spec);
|
||||
List<Error> errs = null;
|
||||
RegExpTerm term = null;
|
||||
try {
|
||||
term = decoder.decodeObject(ast);
|
||||
errs = new JSObjectDecoder<Error>(src, this, "com.semmle.js.ast.regexp", errspec).decodeObjects(errors);
|
||||
} catch (ParseError e) {
|
||||
errs = new ArrayList<Error>();
|
||||
errs.add(new Error(new SourceLocation("", e.getPosition(), e.getPosition()), 1));
|
||||
this.src = src;
|
||||
this.pos = 0;
|
||||
this.errors = new ArrayList<>();
|
||||
this.backrefs = new ArrayList<>();
|
||||
this.maxbackref = 0;
|
||||
RegExpTerm root = parsePattern();
|
||||
for (BackReference backref : backrefs)
|
||||
if (backref.getValue() > maxbackref)
|
||||
errors.add(new Error(backref.getLoc(), Error.INVALID_BACKREF));
|
||||
return new Result(root, errors);
|
||||
}
|
||||
|
||||
private static String fromCodePoint(int codepoint) {
|
||||
if (Character.isValidCodePoint(codepoint))
|
||||
return new String(Character.toChars(codepoint));
|
||||
// replacement character
|
||||
return "\ufffd";
|
||||
}
|
||||
|
||||
private Position pos() {
|
||||
return new Position(1, pos, pos);
|
||||
}
|
||||
|
||||
private void error(int code, int start, int end) {
|
||||
Position startPos, endPos;
|
||||
startPos = new Position(1, start, start);
|
||||
endPos = new Position(1, end, end);
|
||||
this.errors.add(new Error(new SourceLocation(inputSubstring(start, end), startPos, endPos), code));
|
||||
}
|
||||
|
||||
private void error(int code, int start) {
|
||||
error(code, start, start+1);
|
||||
}
|
||||
|
||||
private void error(int code) {
|
||||
error(code, this.pos);
|
||||
}
|
||||
|
||||
private boolean atEOS() {
|
||||
return pos >= src.length();
|
||||
}
|
||||
|
||||
private char peekChar(boolean opt) {
|
||||
if (this.atEOS()) {
|
||||
if (!opt)
|
||||
this.error(Error.UNEXPECTED_EOS);
|
||||
return '\0';
|
||||
} else {
|
||||
return this.src.charAt(this.pos);
|
||||
}
|
||||
return new Result(term, errs);
|
||||
}
|
||||
|
||||
private char nextChar() {
|
||||
char c = peekChar(false);
|
||||
if (this.pos < src.length())
|
||||
++this.pos;
|
||||
return c;
|
||||
}
|
||||
|
||||
private String readHexDigit() {
|
||||
char c = this.peekChar(false);
|
||||
if (c >= '0' && c <= '9' || c >= 'a' && c <= 'f' || c >= 'A' && c <= 'F') {
|
||||
++this.pos;
|
||||
return String.valueOf(c);
|
||||
}
|
||||
if (c != '\0')
|
||||
this.error(Error.EXPECTED_HEX_DIGIT, this.pos);
|
||||
return "";
|
||||
}
|
||||
|
||||
private String readHexDigits(int n) {
|
||||
StringBuilder res = new StringBuilder();
|
||||
while (n-->0) {
|
||||
res.append(readHexDigit());
|
||||
}
|
||||
if (res.length() == 0)
|
||||
return "0";
|
||||
return res.toString();
|
||||
}
|
||||
|
||||
private String readDigits(boolean opt) {
|
||||
StringBuilder res = new StringBuilder();
|
||||
for (char c=peekChar(true); c >= '0' && c <= '9'; nextChar(), c=peekChar(true))
|
||||
res.append(c);
|
||||
if (res.length() == 0 && !opt)
|
||||
this.error(Error.EXPECTED_DIGIT);
|
||||
return res.toString();
|
||||
}
|
||||
|
||||
private Double toNumber(String s) {
|
||||
if (s.isEmpty())
|
||||
return 0.0;
|
||||
return Double.valueOf(s);
|
||||
}
|
||||
|
||||
private String readIdentifier() {
|
||||
StringBuilder res = new StringBuilder();
|
||||
for (char c=peekChar(true);
|
||||
c != '\0' && Character.isJavaIdentifierPart(c);
|
||||
nextChar(), c=peekChar(true))
|
||||
res.append(c);
|
||||
if (res.length() == 0)
|
||||
this.error(Error.EXPECTED_IDENTIFIER);
|
||||
return res.toString();
|
||||
}
|
||||
|
||||
private void expectRParen() {
|
||||
if (!this.match(")"))
|
||||
this.error(Error.EXPECTED_CLOSING_PAREN, this.pos-1);
|
||||
}
|
||||
|
||||
private void expectRBrace() {
|
||||
if (!this.match("}"))
|
||||
this.error(Error.EXPECTED_CLOSING_BRACE, this.pos-1);
|
||||
}
|
||||
|
||||
private void expectRAngle() {
|
||||
if (!this.match(">"))
|
||||
this.error(Error.EXPECTED_CLOSING_ANGLE, this.pos-1);
|
||||
}
|
||||
|
||||
private boolean lookahead(String... arguments) {
|
||||
for (String prefix : arguments) {
|
||||
if (prefix == null) {
|
||||
if (atEOS())
|
||||
return true;
|
||||
} else if (inputSubstring(pos, pos+prefix.length()).equals(prefix)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private boolean match(String... arguments) {
|
||||
for (String prefix : arguments) {
|
||||
if (this.lookahead(prefix)) {
|
||||
if (prefix == null)
|
||||
prefix = "";
|
||||
this.pos += prefix.length();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private RegExpTerm parsePattern() {
|
||||
RegExpTerm res = parseDisjunction();
|
||||
if (!this.atEOS())
|
||||
this.error(Error.EXPECTED_EOS);
|
||||
return res;
|
||||
}
|
||||
|
||||
protected String inputSubstring(int start, int end) {
|
||||
if (start >= src.length())
|
||||
return "";
|
||||
if (end > src.length())
|
||||
end = src.length();
|
||||
return src.substring(start, end);
|
||||
}
|
||||
|
||||
private <T extends RegExpTerm> T finishTerm(T term) {
|
||||
SourceLocation loc = term.getLoc();
|
||||
Position end = pos();
|
||||
loc.setSource(inputSubstring(loc.getStart().getOffset(), end.getOffset()));
|
||||
loc.setEnd(end);
|
||||
return term;
|
||||
}
|
||||
|
||||
private RegExpTerm parseDisjunction() {
|
||||
SourceLocation loc = new SourceLocation(pos());
|
||||
List<RegExpTerm> disjuncts = new ArrayList<>();
|
||||
disjuncts.add(this.parseAlternative());
|
||||
while (this.match("|"))
|
||||
disjuncts.add(this.parseAlternative());
|
||||
if (disjuncts.size() == 1)
|
||||
return disjuncts.get(0);
|
||||
return this.finishTerm(new Disjunction(loc, disjuncts));
|
||||
}
|
||||
|
||||
private RegExpTerm parseAlternative() {
|
||||
SourceLocation loc = new SourceLocation(pos());
|
||||
List<RegExpTerm> elements = new ArrayList<>();
|
||||
while (!this.lookahead(null, "|", ")"))
|
||||
elements.add(this.parseTerm());
|
||||
if (elements.size() == 1)
|
||||
return elements.get(0);
|
||||
return this.finishTerm(new Sequence(loc, elements));
|
||||
}
|
||||
|
||||
private RegExpTerm parseTerm() {
|
||||
SourceLocation loc = new SourceLocation(pos());
|
||||
|
||||
if (this.match("^"))
|
||||
return this.finishTerm(new Caret(loc));
|
||||
|
||||
if (this.match("$"))
|
||||
return this.finishTerm(new Dollar(loc));
|
||||
|
||||
if (this.match("\\b"))
|
||||
return this.finishTerm(new WordBoundary(loc));
|
||||
|
||||
if (this.match("\\B"))
|
||||
return this.finishTerm(new NonWordBoundary(loc));
|
||||
|
||||
if (this.match("(?=")) {
|
||||
RegExpTerm dis = this.parseDisjunction();
|
||||
this.expectRParen();
|
||||
return this.finishTerm(new ZeroWidthPositiveLookahead(loc, dis));
|
||||
}
|
||||
|
||||
if (this.match("(?!")) {
|
||||
RegExpTerm dis = this.parseDisjunction();
|
||||
this.expectRParen();
|
||||
return this.finishTerm(new ZeroWidthNegativeLookahead(loc, dis));
|
||||
}
|
||||
|
||||
if (this.match("(?<=")) {
|
||||
RegExpTerm dis = this.parseDisjunction();
|
||||
this.expectRParen();
|
||||
return this.finishTerm(new ZeroWidthPositiveLookbehind(loc, dis));
|
||||
}
|
||||
|
||||
if (this.match("(?<!")) {
|
||||
RegExpTerm dis = this.parseDisjunction();
|
||||
this.expectRParen();
|
||||
return this.finishTerm(new ZeroWidthNegativeLookbehind(loc, dis));
|
||||
}
|
||||
|
||||
return this.finishTerm(this.parseQuantifierOpt(loc, this.parseAtom()));
|
||||
}
|
||||
|
||||
private RegExpTerm parseQuantifierOpt(SourceLocation loc, RegExpTerm atom) {
|
||||
if (this.match("*"))
|
||||
return this.finishTerm(new Star(loc, atom, !this.match("?")));
|
||||
if (this.match("+"))
|
||||
return this.finishTerm(new Plus(loc, atom, !this.match("?")));
|
||||
if (this.match("?"))
|
||||
return this.finishTerm(new Opt(loc, atom, !this.match("?")));
|
||||
if (this.match("{")) {
|
||||
Double lo = toNumber(this.readDigits(false)),
|
||||
hi = null;
|
||||
if (this.match(",") && !this.lookahead("}"))
|
||||
hi = toNumber(this.readDigits(false));
|
||||
this.expectRBrace();
|
||||
return this.finishTerm(new Range(loc, atom, !this.match("?"), lo, hi));
|
||||
}
|
||||
return atom;
|
||||
}
|
||||
|
||||
private RegExpTerm parseAtom() {
|
||||
SourceLocation loc = new SourceLocation(pos());
|
||||
|
||||
if (this.match("."))
|
||||
return this.finishTerm(new Dot(loc));
|
||||
|
||||
if (this.match("\\"))
|
||||
return this.parseAtomEscape(loc, false);
|
||||
|
||||
if (this.lookahead("["))
|
||||
return this.parseCharacterClass();
|
||||
|
||||
if (this.match("(")) {
|
||||
boolean capture = !this.match("?:");
|
||||
String name = null;
|
||||
|
||||
if (this.match("?<")) {
|
||||
name = this.readIdentifier();
|
||||
this.expectRAngle();
|
||||
}
|
||||
|
||||
if (capture)
|
||||
++this.maxbackref;
|
||||
int number = this.maxbackref;
|
||||
RegExpTerm dis = this.parseDisjunction();
|
||||
this.expectRParen();
|
||||
return this.finishTerm(new Group(loc, capture, number, name, dis));
|
||||
}
|
||||
|
||||
char c = this.nextChar();
|
||||
if ("^$\\.*+?()[]{}|".indexOf(c) != -1)
|
||||
this.error(Error.UNEXPECTED_CHARACTER, this.pos-1);
|
||||
return this.finishTerm(new Constant(loc, String.valueOf(c)));
|
||||
}
|
||||
|
||||
private RegExpTerm parseAtomEscape(SourceLocation loc, boolean inCharClass) {
|
||||
String raw, value;
|
||||
double codepoint;
|
||||
|
||||
if (this.match("x")) {
|
||||
raw = this.readHexDigits(2);
|
||||
codepoint = Integer.parseInt(raw, 16);
|
||||
value = fromCodePoint((int) codepoint);
|
||||
return this.finishTerm(new HexEscapeSequence(loc, value, (double)codepoint, "\\x" + raw));
|
||||
}
|
||||
|
||||
if (this.match("u")) {
|
||||
if (this.match("{")) {
|
||||
int closePos = this.src.indexOf("}", this.pos);
|
||||
int n;
|
||||
if (closePos == -1) {
|
||||
// don't attempt to read any digits, but
|
||||
// report missing `}`
|
||||
n = 0;
|
||||
} else if (closePos == this.pos) {
|
||||
// empty escape sequence, trigger an error
|
||||
n = 1;
|
||||
} else {
|
||||
n = closePos - this.pos;
|
||||
}
|
||||
raw = this.readHexDigits(n);
|
||||
this.expectRBrace();
|
||||
try {
|
||||
codepoint = Long.parseLong(raw, 16);
|
||||
} catch (NumberFormatException nfe) {
|
||||
codepoint = 0;
|
||||
}
|
||||
raw = "{" + raw + "}";
|
||||
} else {
|
||||
raw = this.readHexDigits(4);
|
||||
codepoint = Integer.parseInt(raw, 16);
|
||||
}
|
||||
value = fromCodePoint((int) codepoint);
|
||||
return this.finishTerm(new UnicodeEscapeSequence(loc, value, (double)codepoint, "\\u" + raw));
|
||||
}
|
||||
|
||||
if (this.match("k<")) {
|
||||
String name = this.readIdentifier();
|
||||
this.expectRAngle();
|
||||
return this.finishTerm(new NamedBackReference(loc, name, "\\k<" + name + ">"));
|
||||
}
|
||||
|
||||
if (this.match("p{", "P{")) {
|
||||
String name = this.readIdentifier();
|
||||
if (this.match("=")) {
|
||||
value = this.readIdentifier();
|
||||
raw = "\\p{" + name + "=" + value + "}";
|
||||
} else {
|
||||
value = null;
|
||||
raw = "\\p{" + name + "}";
|
||||
}
|
||||
this.expectRBrace();
|
||||
return this.finishTerm(new UnicodePropertyEscape(loc, name, value, raw));
|
||||
}
|
||||
|
||||
int startpos = this.pos-1;
|
||||
char c = this.nextChar();
|
||||
|
||||
if (c >= '0' && c <= '9') {
|
||||
raw = c + this.readDigits(true);
|
||||
if (c == '0' || inCharClass) {
|
||||
int base = c == '0' && raw.length() > 1 ? 8 : 10;
|
||||
try {
|
||||
codepoint = Long.parseLong(raw, base);
|
||||
value = fromCodePoint((int) codepoint);
|
||||
} catch (NumberFormatException nfe) {
|
||||
codepoint = 0;
|
||||
value = "\0";
|
||||
}
|
||||
if (base == 8) {
|
||||
this.error(Error.OCTAL_ESCAPE, startpos, this.pos);
|
||||
return this.finishTerm(new OctalEscape(loc, value, (double)codepoint, "\\" + raw));
|
||||
} else {
|
||||
return this.finishTerm(new DecimalEscape(loc, value, (double)codepoint, "\\" + raw));
|
||||
}
|
||||
} else {
|
||||
try {
|
||||
codepoint = Long.parseLong(raw, 10);
|
||||
} catch (NumberFormatException nfe) {
|
||||
codepoint = 0;
|
||||
}
|
||||
BackReference br = this.finishTerm(new BackReference(loc, (double)codepoint, "\\" + raw));
|
||||
this.backrefs.add(br);
|
||||
return br;
|
||||
}
|
||||
}
|
||||
|
||||
String ctrltab = "f\fn\nr\rt\tv\u000b";
|
||||
int idx;
|
||||
if ((idx=ctrltab.indexOf(c)) % 2 == 0) {
|
||||
codepoint = ctrltab.charAt(idx+1);
|
||||
value = String.valueOf((char)codepoint);
|
||||
return this.finishTerm(new ControlEscape(loc, value, codepoint, "\\" + c));
|
||||
}
|
||||
|
||||
if (c == 'c') {
|
||||
c = this.nextChar();
|
||||
if (!(c >= 'a' && c <= 'z' || c >= 'A' && c <= 'Z'))
|
||||
this.error(Error.EXPECTED_CONTROL_LETTER, this.pos-1);
|
||||
codepoint = c % 32;
|
||||
value = String.valueOf((char)codepoint);
|
||||
return this.finishTerm(new ControlLetter(loc, value, codepoint, "\\c" + c));
|
||||
}
|
||||
|
||||
if ("dDsSwW".indexOf(c) >= 0) {
|
||||
return this.finishTerm(new CharacterClassEscape(loc, String.valueOf(c), "\\" + c));
|
||||
}
|
||||
|
||||
codepoint = c;
|
||||
value = String.valueOf((char)codepoint);
|
||||
return this.finishTerm(new IdentityEscape(loc, value, codepoint, "\\" + c));
|
||||
}
|
||||
|
||||
private RegExpTerm parseCharacterClass() {
|
||||
SourceLocation loc = new SourceLocation(pos());
|
||||
List<RegExpTerm> elements = new ArrayList<>();
|
||||
|
||||
this.match("[");
|
||||
boolean inverted = this.match("^");
|
||||
while (!this.match("]")) {
|
||||
if (this.atEOS()) {
|
||||
this.error(Error.EXPECTED_RBRACKET);
|
||||
break;
|
||||
}
|
||||
elements.add(this.parseCharacterClassElement());
|
||||
}
|
||||
return this.finishTerm(new CharacterClass(loc, elements, inverted));
|
||||
}
|
||||
|
||||
private RegExpTerm parseCharacterClassElement() {
|
||||
SourceLocation loc = new SourceLocation(pos());
|
||||
RegExpTerm atom = this.parseCharacterClassAtom();
|
||||
if (!this.lookahead("-]") && this.match("-"))
|
||||
return this.finishTerm(new CharacterClassRange(loc, atom, this.parseCharacterClassAtom()));
|
||||
return atom;
|
||||
}
|
||||
|
||||
private RegExpTerm parseCharacterClassAtom() {
|
||||
SourceLocation loc = new SourceLocation(pos());
|
||||
char c = this.nextChar();
|
||||
if (c == '\\') {
|
||||
if (this.match("b"))
|
||||
return this.finishTerm(new ControlEscape(loc, "\b", 8, "\\b"));
|
||||
return this.finishTerm(this.parseAtomEscape(loc, true));
|
||||
}
|
||||
return this.finishTerm(new Constant(loc, String.valueOf(c)));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,3 +15,28 @@
|
||||
* @param {Function(DOMNode)}
|
||||
* @param {Function(DOMNode)} x
|
||||
*/
|
||||
|
||||
/**
|
||||
* @{link a}
|
||||
*/
|
||||
|
||||
/**
|
||||
* @typedef
|
||||
* {a}
|
||||
*/
|
||||
|
||||
/**
|
||||
* [resize description]
|
||||
* @param {[type]} w [description]
|
||||
* @param { } h [description]
|
||||
* @return {[type]} [description]
|
||||
*/
|
||||
|
||||
/**
|
||||
* @exports R
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
* @typedef {{0: number}}
|
||||
*/
|
||||
|
||||
@@ -10,8 +10,8 @@ hasLocation(#10000,#10002)
|
||||
scopes(#20000,0)
|
||||
#20001=@"script;{#10000},1,1"
|
||||
toplevels(#20001,0)
|
||||
#20002=@"loc,{#10000},1,1,18,0"
|
||||
locations_default(#20002,#10000,1,1,18,0)
|
||||
#20002=@"loc,{#10000},1,1,43,0"
|
||||
locations_default(#20002,#10000,1,1,43,0)
|
||||
hasLocation(#20001,#20002)
|
||||
#20003=*
|
||||
comments(#20003,2,#20001,"
|
||||
@@ -51,253 +51,537 @@ comments(#20011,2,#20001,"
|
||||
locations_default(#20012,#10000,14,1,17,3)
|
||||
hasLocation(#20011,#20012)
|
||||
#20013=*
|
||||
lines(#20013,#20001,"/**","
|
||||
")
|
||||
#20014=@"loc,{#10000},1,1,1,3"
|
||||
locations_default(#20014,#10000,1,1,1,3)
|
||||
comments(#20013,2,#20001,"
|
||||
* @{link a}
|
||||
","/**\n * @{link a}\n */")
|
||||
#20014=@"loc,{#10000},19,1,21,3"
|
||||
locations_default(#20014,#10000,19,1,21,3)
|
||||
hasLocation(#20013,#20014)
|
||||
#20015=*
|
||||
lines(#20015,#20001," * This is a constant.","
|
||||
")
|
||||
#20016=@"loc,{#10000},2,1,2,22"
|
||||
locations_default(#20016,#10000,2,1,2,22)
|
||||
comments(#20015,2,#20001,"
|
||||
* @typedef
|
||||
* {a}
|
||||
","/**\n * ... {a}\n */")
|
||||
#20016=@"loc,{#10000},23,1,26,3"
|
||||
locations_default(#20016,#10000,23,1,26,3)
|
||||
hasLocation(#20015,#20016)
|
||||
indentation(#10000,2," ",1)
|
||||
#20017=*
|
||||
lines(#20017,#20001," * ","
|
||||
")
|
||||
#20018=@"loc,{#10000},3,1,3,3"
|
||||
locations_default(#20018,#10000,3,1,3,3)
|
||||
comments(#20017,2,#20001,"
|
||||
* [resize description]
|
||||
* @param {[type]} w [description]
|
||||
* @param { } h [description]
|
||||
* @return {[type]} [description]
|
||||
","/**\n * ... on]\n */")
|
||||
#20018=@"loc,{#10000},28,1,33,3"
|
||||
locations_default(#20018,#10000,28,1,33,3)
|
||||
hasLocation(#20017,#20018)
|
||||
indentation(#10000,3," ",1)
|
||||
#20019=*
|
||||
lines(#20019,#20001," * @const x","
|
||||
")
|
||||
#20020=@"loc,{#10000},4,1,4,11"
|
||||
locations_default(#20020,#10000,4,1,4,11)
|
||||
comments(#20019,2,#20001,"
|
||||
* @exports R
|
||||
*
|
||||
","/**\n* @ ... R\n*\n*/")
|
||||
#20020=@"loc,{#10000},35,1,38,2"
|
||||
locations_default(#20020,#10000,35,1,38,2)
|
||||
hasLocation(#20019,#20020)
|
||||
indentation(#10000,4," ",1)
|
||||
#20021=*
|
||||
lines(#20021,#20001," */","
|
||||
")
|
||||
#20022=@"loc,{#10000},5,1,5,3"
|
||||
locations_default(#20022,#10000,5,1,5,3)
|
||||
comments(#20021,2,#20001,"
|
||||
* @typedef {{0: number}}
|
||||
","/**\n * ... r}}\n */")
|
||||
#20022=@"loc,{#10000},40,1,42,3"
|
||||
locations_default(#20022,#10000,40,1,42,3)
|
||||
hasLocation(#20021,#20022)
|
||||
indentation(#10000,5," ",1)
|
||||
#20023=*
|
||||
lines(#20023,#20001,"/** @class {Object} klass */","
|
||||
lines(#20023,#20001,"/**","
|
||||
")
|
||||
hasLocation(#20023,#20006)
|
||||
#20024=*
|
||||
lines(#20024,#20001,"/** @deprecated */","
|
||||
")
|
||||
hasLocation(#20024,#20008)
|
||||
#20024=@"loc,{#10000},1,1,1,3"
|
||||
locations_default(#20024,#10000,1,1,1,3)
|
||||
hasLocation(#20023,#20024)
|
||||
#20025=*
|
||||
lines(#20025,#20001,"/** @param {(int|bool)} x","
|
||||
lines(#20025,#20001," * This is a constant.","
|
||||
")
|
||||
#20026=@"loc,{#10000},8,1,8,25"
|
||||
locations_default(#20026,#10000,8,1,8,25)
|
||||
#20026=@"loc,{#10000},2,1,2,22"
|
||||
locations_default(#20026,#10000,2,1,2,22)
|
||||
hasLocation(#20025,#20026)
|
||||
indentation(#10000,2," ",1)
|
||||
#20027=*
|
||||
lines(#20027,#20001," * @param {Array.<String, Number>} ys","
|
||||
lines(#20027,#20001," * ","
|
||||
")
|
||||
#20028=@"loc,{#10000},9,1,9,38"
|
||||
locations_default(#20028,#10000,9,1,9,38)
|
||||
#20028=@"loc,{#10000},3,1,3,3"
|
||||
locations_default(#20028,#10000,3,1,3,3)
|
||||
hasLocation(#20027,#20028)
|
||||
indentation(#10000,9," ",1)
|
||||
indentation(#10000,3," ",1)
|
||||
#20029=*
|
||||
lines(#20029,#20001," * @param {String[]} zs","
|
||||
lines(#20029,#20001," * @const x","
|
||||
")
|
||||
#20030=@"loc,{#10000},10,1,10,24"
|
||||
locations_default(#20030,#10000,10,1,10,24)
|
||||
#20030=@"loc,{#10000},4,1,4,11"
|
||||
locations_default(#20030,#10000,4,1,4,11)
|
||||
hasLocation(#20029,#20030)
|
||||
indentation(#10000,10," ",1)
|
||||
indentation(#10000,4," ",1)
|
||||
#20031=*
|
||||
lines(#20031,#20001," * @param {function(new:goog.ui.Menu, ?string=, number=): void} f","
|
||||
lines(#20031,#20001," */","
|
||||
")
|
||||
#20032=@"loc,{#10000},11,1,11,66"
|
||||
locations_default(#20032,#10000,11,1,11,66)
|
||||
#20032=@"loc,{#10000},5,1,5,3"
|
||||
locations_default(#20032,#10000,5,1,5,3)
|
||||
hasLocation(#20031,#20032)
|
||||
indentation(#10000,11," ",1)
|
||||
indentation(#10000,5," ",1)
|
||||
#20033=*
|
||||
lines(#20033,#20001," * @param {...number} var_args","
|
||||
lines(#20033,#20001,"/** @class {Object} klass */","
|
||||
")
|
||||
#20034=@"loc,{#10000},12,1,12,31"
|
||||
locations_default(#20034,#10000,12,1,12,31)
|
||||
hasLocation(#20033,#20034)
|
||||
indentation(#10000,12," ",1)
|
||||
hasLocation(#20033,#20006)
|
||||
#20034=*
|
||||
lines(#20034,#20001,"/** @deprecated */","
|
||||
")
|
||||
hasLocation(#20034,#20008)
|
||||
#20035=*
|
||||
lines(#20035,#20001," */","
|
||||
lines(#20035,#20001,"/** @param {(int|bool)} x","
|
||||
")
|
||||
#20036=@"loc,{#10000},13,1,13,3"
|
||||
locations_default(#20036,#10000,13,1,13,3)
|
||||
#20036=@"loc,{#10000},8,1,8,25"
|
||||
locations_default(#20036,#10000,8,1,8,25)
|
||||
hasLocation(#20035,#20036)
|
||||
indentation(#10000,13," ",1)
|
||||
#20037=*
|
||||
lines(#20037,#20001,"/**","
|
||||
lines(#20037,#20001," * @param {Array.<String, Number>} ys","
|
||||
")
|
||||
#20038=@"loc,{#10000},14,1,14,3"
|
||||
locations_default(#20038,#10000,14,1,14,3)
|
||||
#20038=@"loc,{#10000},9,1,9,38"
|
||||
locations_default(#20038,#10000,9,1,9,38)
|
||||
hasLocation(#20037,#20038)
|
||||
indentation(#10000,9," ",1)
|
||||
#20039=*
|
||||
lines(#20039,#20001," * @param {Function(DOMNode)}","
|
||||
lines(#20039,#20001," * @param {String[]} zs","
|
||||
")
|
||||
#20040=@"loc,{#10000},15,1,15,29"
|
||||
locations_default(#20040,#10000,15,1,15,29)
|
||||
#20040=@"loc,{#10000},10,1,10,24"
|
||||
locations_default(#20040,#10000,10,1,10,24)
|
||||
hasLocation(#20039,#20040)
|
||||
indentation(#10000,15," ",1)
|
||||
indentation(#10000,10," ",1)
|
||||
#20041=*
|
||||
lines(#20041,#20001," * @param {Function(DOMNode)} x","
|
||||
lines(#20041,#20001," * @param {function(new:goog.ui.Menu, ?string=, number=): void} f","
|
||||
")
|
||||
#20042=@"loc,{#10000},16,1,16,31"
|
||||
locations_default(#20042,#10000,16,1,16,31)
|
||||
#20042=@"loc,{#10000},11,1,11,66"
|
||||
locations_default(#20042,#10000,11,1,11,66)
|
||||
hasLocation(#20041,#20042)
|
||||
indentation(#10000,16," ",1)
|
||||
indentation(#10000,11," ",1)
|
||||
#20043=*
|
||||
lines(#20043,#20001," */","
|
||||
lines(#20043,#20001," * @param {...number} var_args","
|
||||
")
|
||||
#20044=@"loc,{#10000},17,1,17,3"
|
||||
locations_default(#20044,#10000,17,1,17,3)
|
||||
#20044=@"loc,{#10000},12,1,12,31"
|
||||
locations_default(#20044,#10000,12,1,12,31)
|
||||
hasLocation(#20043,#20044)
|
||||
indentation(#10000,17," ",1)
|
||||
numlines(#20001,17,0,17)
|
||||
indentation(#10000,12," ",1)
|
||||
#20045=*
|
||||
tokeninfo(#20045,0,#20001,0,"")
|
||||
#20046=@"loc,{#10000},18,1,18,0"
|
||||
locations_default(#20046,#10000,18,1,18,0)
|
||||
lines(#20045,#20001," */","
|
||||
")
|
||||
#20046=@"loc,{#10000},13,1,13,3"
|
||||
locations_default(#20046,#10000,13,1,13,3)
|
||||
hasLocation(#20045,#20046)
|
||||
next_token(#20003,#20045)
|
||||
next_token(#20005,#20045)
|
||||
next_token(#20007,#20045)
|
||||
next_token(#20009,#20045)
|
||||
next_token(#20011,#20045)
|
||||
indentation(#10000,13," ",1)
|
||||
#20047=*
|
||||
entry_cfg_node(#20047,#20001)
|
||||
#20048=@"loc,{#10000},1,1,1,0"
|
||||
locations_default(#20048,#10000,1,1,1,0)
|
||||
lines(#20047,#20001,"/**","
|
||||
")
|
||||
#20048=@"loc,{#10000},14,1,14,3"
|
||||
locations_default(#20048,#10000,14,1,14,3)
|
||||
hasLocation(#20047,#20048)
|
||||
#20049=*
|
||||
exit_cfg_node(#20049,#20001)
|
||||
hasLocation(#20049,#20046)
|
||||
successor(#20047,#20049)
|
||||
#20050=*
|
||||
jsdoc(#20050,"This is a constant.",#20003)
|
||||
hasLocation(#20050,#20004)
|
||||
lines(#20049,#20001," * @param {Function(DOMNode)}","
|
||||
")
|
||||
#20050=@"loc,{#10000},15,1,15,29"
|
||||
locations_default(#20050,#10000,15,1,15,29)
|
||||
hasLocation(#20049,#20050)
|
||||
indentation(#10000,15," ",1)
|
||||
#20051=*
|
||||
jsdoc_tags(#20051,"const",#20050,0,"@const")
|
||||
#20052=@"loc,{#10000},4,4,4,9"
|
||||
locations_default(#20052,#10000,4,4,4,9)
|
||||
lines(#20051,#20001," * @param {Function(DOMNode)} x","
|
||||
")
|
||||
#20052=@"loc,{#10000},16,1,16,31"
|
||||
locations_default(#20052,#10000,16,1,16,31)
|
||||
hasLocation(#20051,#20052)
|
||||
jsdoc_tag_names(#20051,"x")
|
||||
indentation(#10000,16," ",1)
|
||||
#20053=*
|
||||
jsdoc(#20053,"",#20005)
|
||||
hasLocation(#20053,#20006)
|
||||
#20054=*
|
||||
jsdoc_tags(#20054,"class",#20053,0,"@class")
|
||||
#20055=@"loc,{#10000},6,5,6,10"
|
||||
locations_default(#20055,#10000,6,5,6,10)
|
||||
hasLocation(#20054,#20055)
|
||||
jsdoc_tag_names(#20054,"klass")
|
||||
#20056=*
|
||||
jsdoc_type_exprs(#20056,5,#20054,0,"Object")
|
||||
lines(#20053,#20001," */","
|
||||
")
|
||||
#20054=@"loc,{#10000},17,1,17,3"
|
||||
locations_default(#20054,#10000,17,1,17,3)
|
||||
hasLocation(#20053,#20054)
|
||||
indentation(#10000,17," ",1)
|
||||
#20055=*
|
||||
lines(#20055,#20001,"","
|
||||
")
|
||||
#20056=@"loc,{#10000},18,1,18,0"
|
||||
locations_default(#20056,#10000,18,1,18,0)
|
||||
hasLocation(#20055,#20056)
|
||||
#20057=*
|
||||
jsdoc(#20057,"",#20007)
|
||||
hasLocation(#20057,#20008)
|
||||
#20058=*
|
||||
jsdoc_tags(#20058,"deprecated",#20057,0,"@deprecated")
|
||||
#20059=@"loc,{#10000},7,5,7,15"
|
||||
locations_default(#20059,#10000,7,5,7,15)
|
||||
hasLocation(#20058,#20059)
|
||||
#20060=*
|
||||
jsdoc(#20060,"",#20009)
|
||||
hasLocation(#20060,#20010)
|
||||
lines(#20057,#20001,"/**","
|
||||
")
|
||||
#20058=@"loc,{#10000},19,1,19,3"
|
||||
locations_default(#20058,#10000,19,1,19,3)
|
||||
hasLocation(#20057,#20058)
|
||||
#20059=*
|
||||
lines(#20059,#20001," * @{link a}","
|
||||
")
|
||||
#20060=@"loc,{#10000},20,1,20,12"
|
||||
locations_default(#20060,#10000,20,1,20,12)
|
||||
hasLocation(#20059,#20060)
|
||||
indentation(#10000,20," ",1)
|
||||
#20061=*
|
||||
jsdoc_tags(#20061,"param",#20060,0,"@param")
|
||||
#20062=@"loc,{#10000},8,5,8,10"
|
||||
locations_default(#20062,#10000,8,5,8,10)
|
||||
lines(#20061,#20001," */","
|
||||
")
|
||||
#20062=@"loc,{#10000},21,1,21,3"
|
||||
locations_default(#20062,#10000,21,1,21,3)
|
||||
hasLocation(#20061,#20062)
|
||||
jsdoc_tag_names(#20061,"x")
|
||||
indentation(#10000,21," ",1)
|
||||
#20063=*
|
||||
jsdoc_type_exprs(#20063,11,#20061,0,"(int|bool)")
|
||||
#20064=*
|
||||
jsdoc_type_exprs(#20064,5,#20063,0,"int")
|
||||
lines(#20063,#20001,"","
|
||||
")
|
||||
#20064=@"loc,{#10000},22,1,22,0"
|
||||
locations_default(#20064,#10000,22,1,22,0)
|
||||
hasLocation(#20063,#20064)
|
||||
#20065=*
|
||||
jsdoc_type_exprs(#20065,5,#20063,1,"bool")
|
||||
#20066=*
|
||||
jsdoc_tags(#20066,"param",#20060,1,"@param")
|
||||
#20067=@"loc,{#10000},9,5,9,10"
|
||||
locations_default(#20067,#10000,9,5,9,10)
|
||||
hasLocation(#20066,#20067)
|
||||
jsdoc_tag_names(#20066,"ys")
|
||||
#20068=*
|
||||
jsdoc_type_exprs(#20068,6,#20066,0,"Array.<String, Number>")
|
||||
lines(#20065,#20001,"/**","
|
||||
")
|
||||
#20066=@"loc,{#10000},23,1,23,3"
|
||||
locations_default(#20066,#10000,23,1,23,3)
|
||||
hasLocation(#20065,#20066)
|
||||
#20067=*
|
||||
lines(#20067,#20001," * @typedef","
|
||||
")
|
||||
#20068=@"loc,{#10000},24,1,24,11"
|
||||
locations_default(#20068,#10000,24,1,24,11)
|
||||
hasLocation(#20067,#20068)
|
||||
indentation(#10000,24," ",1)
|
||||
#20069=*
|
||||
jsdoc_type_exprs(#20069,5,#20068,-1,"Array")
|
||||
#20070=*
|
||||
jsdoc_type_exprs(#20070,5,#20068,0,"String")
|
||||
lines(#20069,#20001," * {a}","
|
||||
")
|
||||
#20070=@"loc,{#10000},25,1,25,6"
|
||||
locations_default(#20070,#10000,25,1,25,6)
|
||||
hasLocation(#20069,#20070)
|
||||
indentation(#10000,25," ",1)
|
||||
#20071=*
|
||||
jsdoc_type_exprs(#20071,5,#20068,1,"Number")
|
||||
#20072=*
|
||||
jsdoc_tags(#20072,"param",#20060,2,"@param")
|
||||
#20073=@"loc,{#10000},10,5,10,10"
|
||||
locations_default(#20073,#10000,10,5,10,10)
|
||||
hasLocation(#20072,#20073)
|
||||
jsdoc_tag_names(#20072,"zs")
|
||||
#20074=*
|
||||
jsdoc_type_exprs(#20074,6,#20072,0,"Array.<String>")
|
||||
lines(#20071,#20001," */","
|
||||
")
|
||||
#20072=@"loc,{#10000},26,1,26,3"
|
||||
locations_default(#20072,#10000,26,1,26,3)
|
||||
hasLocation(#20071,#20072)
|
||||
indentation(#10000,26," ",1)
|
||||
#20073=*
|
||||
lines(#20073,#20001,"","
|
||||
")
|
||||
#20074=@"loc,{#10000},27,1,27,0"
|
||||
locations_default(#20074,#10000,27,1,27,0)
|
||||
hasLocation(#20073,#20074)
|
||||
#20075=*
|
||||
jsdoc_type_exprs(#20075,5,#20074,-1,"Array")
|
||||
#20076=*
|
||||
jsdoc_type_exprs(#20076,5,#20074,0,"String")
|
||||
lines(#20075,#20001,"/**","
|
||||
")
|
||||
#20076=@"loc,{#10000},28,1,28,3"
|
||||
locations_default(#20076,#10000,28,1,28,3)
|
||||
hasLocation(#20075,#20076)
|
||||
#20077=*
|
||||
jsdoc_tags(#20077,"param",#20060,3,"@param")
|
||||
#20078=@"loc,{#10000},11,5,11,10"
|
||||
locations_default(#20078,#10000,11,5,11,10)
|
||||
lines(#20077,#20001," * [resize description]","
|
||||
")
|
||||
#20078=@"loc,{#10000},29,1,29,23"
|
||||
locations_default(#20078,#10000,29,1,29,23)
|
||||
hasLocation(#20077,#20078)
|
||||
jsdoc_tag_names(#20077,"f")
|
||||
indentation(#10000,29," ",1)
|
||||
#20079=*
|
||||
jsdoc_type_exprs(#20079,12,#20077,0,"function (new: goog.ui.Menu, ?string=, number=): void")
|
||||
#20080=*
|
||||
jsdoc_type_exprs(#20080,13,#20079,0,"?string=")
|
||||
lines(#20079,#20001," * @param {[type]} w [description]","
|
||||
")
|
||||
#20080=@"loc,{#10000},30,1,30,35"
|
||||
locations_default(#20080,#10000,30,1,30,35)
|
||||
hasLocation(#20079,#20080)
|
||||
indentation(#10000,30," ",1)
|
||||
#20081=*
|
||||
jsdoc_type_exprs(#20081,7,#20080,0,"?string")
|
||||
#20082=*
|
||||
jsdoc_type_exprs(#20082,5,#20081,0,"string")
|
||||
jsdoc_prefix_qualifier(#20081)
|
||||
lines(#20081,#20001," * @param { } h [description]","
|
||||
")
|
||||
#20082=@"loc,{#10000},31,1,31,31"
|
||||
locations_default(#20082,#10000,31,1,31,31)
|
||||
hasLocation(#20081,#20082)
|
||||
indentation(#10000,31," ",1)
|
||||
#20083=*
|
||||
jsdoc_type_exprs(#20083,13,#20079,1,"number=")
|
||||
#20084=*
|
||||
jsdoc_type_exprs(#20084,5,#20083,0,"number")
|
||||
lines(#20083,#20001," * @return {[type]} [description]","
|
||||
")
|
||||
#20084=@"loc,{#10000},32,1,32,35"
|
||||
locations_default(#20084,#10000,32,1,32,35)
|
||||
hasLocation(#20083,#20084)
|
||||
indentation(#10000,32," ",1)
|
||||
#20085=*
|
||||
jsdoc_type_exprs(#20085,4,#20079,-1,"void")
|
||||
#20086=*
|
||||
jsdoc_type_exprs(#20086,5,#20079,-2,"goog.ui.Menu")
|
||||
jsdoc_has_new_parameter(#20079)
|
||||
lines(#20085,#20001," */","
|
||||
")
|
||||
#20086=@"loc,{#10000},33,1,33,3"
|
||||
locations_default(#20086,#10000,33,1,33,3)
|
||||
hasLocation(#20085,#20086)
|
||||
indentation(#10000,33," ",1)
|
||||
#20087=*
|
||||
jsdoc_tags(#20087,"param",#20060,4,"@param")
|
||||
#20088=@"loc,{#10000},12,5,12,10"
|
||||
locations_default(#20088,#10000,12,5,12,10)
|
||||
lines(#20087,#20001,"","
|
||||
")
|
||||
#20088=@"loc,{#10000},34,1,34,0"
|
||||
locations_default(#20088,#10000,34,1,34,0)
|
||||
hasLocation(#20087,#20088)
|
||||
jsdoc_tag_names(#20087,"var_args")
|
||||
#20089=*
|
||||
jsdoc_type_exprs(#20089,14,#20087,0,"...number")
|
||||
#20090=*
|
||||
jsdoc_type_exprs(#20090,5,#20089,0,"number")
|
||||
lines(#20089,#20001,"/**","
|
||||
")
|
||||
#20090=@"loc,{#10000},35,1,35,3"
|
||||
locations_default(#20090,#10000,35,1,35,3)
|
||||
hasLocation(#20089,#20090)
|
||||
#20091=*
|
||||
jsdoc(#20091,"",#20011)
|
||||
hasLocation(#20091,#20012)
|
||||
#20092=*
|
||||
jsdoc_tags(#20092,"param",#20091,0,"@param")
|
||||
#20093=@"loc,{#10000},15,4,15,9"
|
||||
locations_default(#20093,#10000,15,4,15,9)
|
||||
hasLocation(#20092,#20093)
|
||||
#20094=*
|
||||
jsdoc_errors(#20094,#20092,"Missing or invalid tag name","Missing ... ag name")
|
||||
lines(#20091,#20001,"* @exports R","
|
||||
")
|
||||
#20092=@"loc,{#10000},36,1,36,12"
|
||||
locations_default(#20092,#10000,36,1,36,12)
|
||||
hasLocation(#20091,#20092)
|
||||
#20093=*
|
||||
lines(#20093,#20001,"*","
|
||||
")
|
||||
#20094=@"loc,{#10000},37,1,37,1"
|
||||
locations_default(#20094,#10000,37,1,37,1)
|
||||
hasLocation(#20093,#20094)
|
||||
#20095=*
|
||||
jsdoc_tags(#20095,"param",#20091,1,"@param")
|
||||
#20096=@"loc,{#10000},16,4,16,9"
|
||||
locations_default(#20096,#10000,16,4,16,9)
|
||||
lines(#20095,#20001,"*/","
|
||||
")
|
||||
#20096=@"loc,{#10000},38,1,38,2"
|
||||
locations_default(#20096,#10000,38,1,38,2)
|
||||
hasLocation(#20095,#20096)
|
||||
jsdoc_tag_names(#20095,"x")
|
||||
numlines(#10000,17,0,17)
|
||||
#20097=*
|
||||
lines(#20097,#20001,"","
|
||||
")
|
||||
#20098=@"loc,{#10000},39,1,39,0"
|
||||
locations_default(#20098,#10000,39,1,39,0)
|
||||
hasLocation(#20097,#20098)
|
||||
#20099=*
|
||||
lines(#20099,#20001,"/**","
|
||||
")
|
||||
#20100=@"loc,{#10000},40,1,40,3"
|
||||
locations_default(#20100,#10000,40,1,40,3)
|
||||
hasLocation(#20099,#20100)
|
||||
#20101=*
|
||||
lines(#20101,#20001," * @typedef {{0: number}}","
|
||||
")
|
||||
#20102=@"loc,{#10000},41,1,41,25"
|
||||
locations_default(#20102,#10000,41,1,41,25)
|
||||
hasLocation(#20101,#20102)
|
||||
indentation(#10000,41," ",1)
|
||||
#20103=*
|
||||
lines(#20103,#20001," */","
|
||||
")
|
||||
#20104=@"loc,{#10000},42,1,42,3"
|
||||
locations_default(#20104,#10000,42,1,42,3)
|
||||
hasLocation(#20103,#20104)
|
||||
indentation(#10000,42," ",1)
|
||||
numlines(#20001,42,0,37)
|
||||
#20105=*
|
||||
tokeninfo(#20105,0,#20001,0,"")
|
||||
#20106=@"loc,{#10000},43,1,43,0"
|
||||
locations_default(#20106,#10000,43,1,43,0)
|
||||
hasLocation(#20105,#20106)
|
||||
next_token(#20003,#20105)
|
||||
next_token(#20005,#20105)
|
||||
next_token(#20007,#20105)
|
||||
next_token(#20009,#20105)
|
||||
next_token(#20011,#20105)
|
||||
next_token(#20013,#20105)
|
||||
next_token(#20015,#20105)
|
||||
next_token(#20017,#20105)
|
||||
next_token(#20019,#20105)
|
||||
next_token(#20021,#20105)
|
||||
#20107=*
|
||||
entry_cfg_node(#20107,#20001)
|
||||
#20108=@"loc,{#10000},1,1,1,0"
|
||||
locations_default(#20108,#10000,1,1,1,0)
|
||||
hasLocation(#20107,#20108)
|
||||
#20109=*
|
||||
exit_cfg_node(#20109,#20001)
|
||||
hasLocation(#20109,#20106)
|
||||
successor(#20107,#20109)
|
||||
#20110=*
|
||||
jsdoc(#20110,"This is a constant.",#20003)
|
||||
hasLocation(#20110,#20004)
|
||||
#20111=*
|
||||
jsdoc_tags(#20111,"const",#20110,0,"@const")
|
||||
#20112=@"loc,{#10000},4,4,4,9"
|
||||
locations_default(#20112,#10000,4,4,4,9)
|
||||
hasLocation(#20111,#20112)
|
||||
jsdoc_tag_names(#20111,"x")
|
||||
#20113=*
|
||||
jsdoc(#20113,"",#20005)
|
||||
hasLocation(#20113,#20006)
|
||||
#20114=*
|
||||
jsdoc_tags(#20114,"class",#20113,0,"@class")
|
||||
#20115=@"loc,{#10000},6,5,6,10"
|
||||
locations_default(#20115,#10000,6,5,6,10)
|
||||
hasLocation(#20114,#20115)
|
||||
jsdoc_tag_names(#20114,"klass")
|
||||
#20116=*
|
||||
jsdoc_type_exprs(#20116,5,#20114,0,"Object")
|
||||
#20117=*
|
||||
jsdoc(#20117,"",#20007)
|
||||
hasLocation(#20117,#20008)
|
||||
#20118=*
|
||||
jsdoc_tags(#20118,"deprecated",#20117,0,"@deprecated")
|
||||
#20119=@"loc,{#10000},7,5,7,15"
|
||||
locations_default(#20119,#10000,7,5,7,15)
|
||||
hasLocation(#20118,#20119)
|
||||
#20120=*
|
||||
jsdoc(#20120,"",#20009)
|
||||
hasLocation(#20120,#20010)
|
||||
#20121=*
|
||||
jsdoc_tags(#20121,"param",#20120,0,"@param")
|
||||
#20122=@"loc,{#10000},8,5,8,10"
|
||||
locations_default(#20122,#10000,8,5,8,10)
|
||||
hasLocation(#20121,#20122)
|
||||
jsdoc_tag_names(#20121,"x")
|
||||
#20123=*
|
||||
jsdoc_type_exprs(#20123,11,#20121,0,"(int|bool)")
|
||||
#20124=*
|
||||
jsdoc_type_exprs(#20124,5,#20123,0,"int")
|
||||
#20125=*
|
||||
jsdoc_type_exprs(#20125,5,#20123,1,"bool")
|
||||
#20126=*
|
||||
jsdoc_tags(#20126,"param",#20120,1,"@param")
|
||||
#20127=@"loc,{#10000},9,5,9,10"
|
||||
locations_default(#20127,#10000,9,5,9,10)
|
||||
hasLocation(#20126,#20127)
|
||||
jsdoc_tag_names(#20126,"ys")
|
||||
#20128=*
|
||||
jsdoc_type_exprs(#20128,6,#20126,0,"Array.<String, Number>")
|
||||
#20129=*
|
||||
jsdoc_type_exprs(#20129,5,#20128,-1,"Array")
|
||||
#20130=*
|
||||
jsdoc_type_exprs(#20130,5,#20128,0,"String")
|
||||
#20131=*
|
||||
jsdoc_type_exprs(#20131,5,#20128,1,"Number")
|
||||
#20132=*
|
||||
jsdoc_tags(#20132,"param",#20120,2,"@param")
|
||||
#20133=@"loc,{#10000},10,5,10,10"
|
||||
locations_default(#20133,#10000,10,5,10,10)
|
||||
hasLocation(#20132,#20133)
|
||||
jsdoc_tag_names(#20132,"zs")
|
||||
#20134=*
|
||||
jsdoc_type_exprs(#20134,6,#20132,0,"Array.<String>")
|
||||
#20135=*
|
||||
jsdoc_type_exprs(#20135,5,#20134,-1,"Array")
|
||||
#20136=*
|
||||
jsdoc_type_exprs(#20136,5,#20134,0,"String")
|
||||
#20137=*
|
||||
jsdoc_tags(#20137,"param",#20120,3,"@param")
|
||||
#20138=@"loc,{#10000},11,5,11,10"
|
||||
locations_default(#20138,#10000,11,5,11,10)
|
||||
hasLocation(#20137,#20138)
|
||||
jsdoc_tag_names(#20137,"f")
|
||||
#20139=*
|
||||
jsdoc_type_exprs(#20139,12,#20137,0,"function (new: goog.ui.Menu, ?string=, number=): void")
|
||||
#20140=*
|
||||
jsdoc_type_exprs(#20140,13,#20139,0,"?string=")
|
||||
#20141=*
|
||||
jsdoc_type_exprs(#20141,7,#20140,0,"?string")
|
||||
#20142=*
|
||||
jsdoc_type_exprs(#20142,5,#20141,0,"string")
|
||||
jsdoc_prefix_qualifier(#20141)
|
||||
#20143=*
|
||||
jsdoc_type_exprs(#20143,13,#20139,1,"number=")
|
||||
#20144=*
|
||||
jsdoc_type_exprs(#20144,5,#20143,0,"number")
|
||||
#20145=*
|
||||
jsdoc_type_exprs(#20145,4,#20139,-1,"void")
|
||||
#20146=*
|
||||
jsdoc_type_exprs(#20146,5,#20139,-2,"goog.ui.Menu")
|
||||
jsdoc_has_new_parameter(#20139)
|
||||
#20147=*
|
||||
jsdoc_tags(#20147,"param",#20120,4,"@param")
|
||||
#20148=@"loc,{#10000},12,5,12,10"
|
||||
locations_default(#20148,#10000,12,5,12,10)
|
||||
hasLocation(#20147,#20148)
|
||||
jsdoc_tag_names(#20147,"var_args")
|
||||
#20149=*
|
||||
jsdoc_type_exprs(#20149,14,#20147,0,"...number")
|
||||
#20150=*
|
||||
jsdoc_type_exprs(#20150,5,#20149,0,"number")
|
||||
#20151=*
|
||||
jsdoc(#20151,"",#20011)
|
||||
hasLocation(#20151,#20012)
|
||||
#20152=*
|
||||
jsdoc_tags(#20152,"param",#20151,0,"@param")
|
||||
#20153=@"loc,{#10000},15,4,15,9"
|
||||
locations_default(#20153,#10000,15,4,15,9)
|
||||
hasLocation(#20152,#20153)
|
||||
#20154=*
|
||||
jsdoc_errors(#20154,#20152,"Missing or invalid tag name","Missing ... ag name")
|
||||
#20155=*
|
||||
jsdoc_tags(#20155,"param",#20151,1,"@param")
|
||||
#20156=@"loc,{#10000},16,4,16,9"
|
||||
locations_default(#20156,#10000,16,4,16,9)
|
||||
hasLocation(#20155,#20156)
|
||||
jsdoc_tag_names(#20155,"x")
|
||||
#20157=*
|
||||
jsdoc(#20157,"",#20013)
|
||||
hasLocation(#20157,#20014)
|
||||
#20158=*
|
||||
jsdoc_tags(#20158,"",#20157,0,"@")
|
||||
#20159=@"loc,{#10000},20,4,20,4"
|
||||
locations_default(#20159,#10000,20,4,20,4)
|
||||
hasLocation(#20158,#20159)
|
||||
jsdoc_tag_descriptions(#20158,"{link a}")
|
||||
#20160=*
|
||||
jsdoc_errors(#20160,#20158,"Missing or invalid title","Missing ... d title")
|
||||
#20161=*
|
||||
jsdoc(#20161,"",#20015)
|
||||
hasLocation(#20161,#20016)
|
||||
#20162=*
|
||||
jsdoc_tags(#20162,"typedef",#20161,0,"@typedef")
|
||||
#20163=@"loc,{#10000},24,4,24,11"
|
||||
locations_default(#20163,#10000,24,4,24,11)
|
||||
hasLocation(#20162,#20163)
|
||||
jsdoc_tag_descriptions(#20162,"{a}")
|
||||
#20164=*
|
||||
jsdoc_errors(#20164,#20162,"Missing or invalid tag type","Missing ... ag type")
|
||||
#20165=*
|
||||
jsdoc(#20165,"[resize description]",#20017)
|
||||
hasLocation(#20165,#20018)
|
||||
#20166=*
|
||||
jsdoc_tags(#20166,"param",#20165,0,"@param")
|
||||
#20167=@"loc,{#10000},30,4,30,9"
|
||||
locations_default(#20167,#10000,30,4,30,9)
|
||||
hasLocation(#20166,#20167)
|
||||
jsdoc_tag_descriptions(#20166,"[description]
|
||||
")
|
||||
jsdoc_tag_names(#20166,"w")
|
||||
#20168=*
|
||||
jsdoc_type_exprs(#20168,10,#20166,0,"[type]")
|
||||
#20169=*
|
||||
jsdoc_type_exprs(#20169,5,#20168,0,"type")
|
||||
#20170=*
|
||||
jsdoc_tags(#20170,"param",#20165,1,"@param")
|
||||
#20171=@"loc,{#10000},31,4,31,9"
|
||||
locations_default(#20171,#10000,31,4,31,9)
|
||||
hasLocation(#20170,#20171)
|
||||
jsdoc_tag_descriptions(#20170,"[description]
|
||||
")
|
||||
#20172=*
|
||||
jsdoc_tags(#20172,"return",#20165,2,"@return")
|
||||
#20173=@"loc,{#10000},32,4,32,10"
|
||||
locations_default(#20173,#10000,32,4,32,10)
|
||||
hasLocation(#20172,#20173)
|
||||
jsdoc_tag_descriptions(#20172,"[description]")
|
||||
#20174=*
|
||||
jsdoc_type_exprs(#20174,10,#20172,0,"[type]")
|
||||
#20175=*
|
||||
jsdoc_type_exprs(#20175,5,#20174,0,"type")
|
||||
#20176=*
|
||||
jsdoc(#20176,"",#20019)
|
||||
hasLocation(#20176,#20020)
|
||||
#20177=*
|
||||
jsdoc_tags(#20177,"exports",#20176,0,"@exports")
|
||||
#20178=@"loc,{#10000},36,3,36,10"
|
||||
locations_default(#20178,#10000,36,3,36,10)
|
||||
hasLocation(#20177,#20178)
|
||||
jsdoc_tag_descriptions(#20177,"R
|
||||
")
|
||||
#20179=*
|
||||
jsdoc(#20179,"",#20021)
|
||||
hasLocation(#20179,#20022)
|
||||
#20180=*
|
||||
jsdoc_tags(#20180,"typedef",#20179,0,"@typedef")
|
||||
#20181=@"loc,{#10000},41,4,41,11"
|
||||
locations_default(#20181,#10000,41,4,41,11)
|
||||
hasLocation(#20180,#20181)
|
||||
#20182=*
|
||||
jsdoc_type_exprs(#20182,9,#20180,0,"{0: number}")
|
||||
jsdoc_record_field_name(#20182,0,"0")
|
||||
#20183=*
|
||||
jsdoc_type_exprs(#20183,5,#20182,0,"number")
|
||||
numlines(#10000,42,0,37)
|
||||
filetype(#10000,"javascript")
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -3,3 +3,4 @@
|
||||
/(?<!.)/;
|
||||
/\p{Number}/u;
|
||||
/\P{Script=Greek}/u;
|
||||
/\k</;
|
||||
|
||||
2
javascript/extractor/tests/regexp/input/tst.js
Normal file
2
javascript/extractor/tests/regexp/input/tst.js
Normal file
@@ -0,0 +1,2 @@
|
||||
/\u{10400}/;
|
||||
/\c/;
|
||||
@@ -10,8 +10,8 @@ hasLocation(#10000,#10002)
|
||||
scopes(#20000,0)
|
||||
#20001=@"script;{#10000},1,1"
|
||||
toplevels(#20001,0)
|
||||
#20002=@"loc,{#10000},1,1,6,0"
|
||||
locations_default(#20002,#10000,1,1,6,0)
|
||||
#20002=@"loc,{#10000},1,1,7,0"
|
||||
locations_default(#20002,#10000,1,1,7,0)
|
||||
hasLocation(#20001,#20002)
|
||||
#20003=*
|
||||
stmts(#20003,2,#20001,0,"/^(?<ws ... <ws>$/;")
|
||||
@@ -169,81 +169,125 @@ hasLocation(#20051,#20052)
|
||||
unicodePropertyEscapeName(#20051,"Script")
|
||||
unicodePropertyEscapeValue(#20051,"Greek")
|
||||
#20053=*
|
||||
lines(#20053,#20001,"/^(?<ws>\s+)\w+\k<ws>$/;","
|
||||
")
|
||||
hasLocation(#20053,#20004)
|
||||
#20054=*
|
||||
lines(#20054,#20001,"/(?<=.)/;","
|
||||
")
|
||||
hasLocation(#20054,#20026)
|
||||
stmts(#20053,2,#20001,5,"/\k</;")
|
||||
#20054=@"loc,{#10000},6,1,6,6"
|
||||
locations_default(#20054,#10000,6,1,6,6)
|
||||
hasLocation(#20053,#20054)
|
||||
stmtContainers(#20053,#20001)
|
||||
#20055=*
|
||||
lines(#20055,#20001,"/(?<!.)/;","
|
||||
")
|
||||
hasLocation(#20055,#20034)
|
||||
#20056=*
|
||||
lines(#20056,#20001,"/\p{Number}/u;","
|
||||
")
|
||||
hasLocation(#20056,#20042)
|
||||
exprs(#20055,5,#20053,0,"/\k</")
|
||||
#20056=@"loc,{#10000},6,1,6,5"
|
||||
locations_default(#20056,#10000,6,1,6,5)
|
||||
hasLocation(#20055,#20056)
|
||||
enclosingStmt(#20055,#20053)
|
||||
exprContainers(#20055,#20001)
|
||||
literals("/\k</","/\k</",#20055)
|
||||
#20057=*
|
||||
lines(#20057,#20001,"/\P{Script=Greek}/u;","
|
||||
")
|
||||
hasLocation(#20057,#20048)
|
||||
numlines(#20001,5,5,0)
|
||||
#20058=*
|
||||
tokeninfo(#20058,5,#20001,0,"/^(?<ws>\s+)\w+\k<ws>$/")
|
||||
hasLocation(#20058,#20006)
|
||||
regexpterm(#20057,22,#20055,0,"\k<")
|
||||
#20058=@"loc,{#10000},6,2,6,4"
|
||||
locations_default(#20058,#10000,6,2,6,4)
|
||||
hasLocation(#20057,#20058)
|
||||
namedBackref(#20057,"")
|
||||
#20059=*
|
||||
tokeninfo(#20059,8,#20001,1,";")
|
||||
#20060=@"loc,{#10000},1,24,1,24"
|
||||
locations_default(#20060,#10000,1,24,1,24)
|
||||
regexpParseErrors(#20059,#20057,"expected identifier")
|
||||
#20060=@"loc,{#10000},6,5,6,5"
|
||||
locations_default(#20060,#10000,6,5,6,5)
|
||||
hasLocation(#20059,#20060)
|
||||
#20061=*
|
||||
tokeninfo(#20061,5,#20001,2,"/(?<=.)/")
|
||||
hasLocation(#20061,#20028)
|
||||
#20062=*
|
||||
tokeninfo(#20062,8,#20001,3,";")
|
||||
#20063=@"loc,{#10000},2,9,2,9"
|
||||
locations_default(#20063,#10000,2,9,2,9)
|
||||
hasLocation(#20062,#20063)
|
||||
regexpParseErrors(#20061,#20057,"expected '>'")
|
||||
#20062=@"loc,{#10000},6,4,6,4"
|
||||
locations_default(#20062,#10000,6,4,6,4)
|
||||
hasLocation(#20061,#20062)
|
||||
#20063=*
|
||||
lines(#20063,#20001,"/^(?<ws>\s+)\w+\k<ws>$/;","
|
||||
")
|
||||
hasLocation(#20063,#20004)
|
||||
#20064=*
|
||||
tokeninfo(#20064,5,#20001,4,"/(?<!.)/")
|
||||
hasLocation(#20064,#20036)
|
||||
lines(#20064,#20001,"/(?<=.)/;","
|
||||
")
|
||||
hasLocation(#20064,#20026)
|
||||
#20065=*
|
||||
tokeninfo(#20065,8,#20001,5,";")
|
||||
#20066=@"loc,{#10000},3,9,3,9"
|
||||
locations_default(#20066,#10000,3,9,3,9)
|
||||
hasLocation(#20065,#20066)
|
||||
lines(#20065,#20001,"/(?<!.)/;","
|
||||
")
|
||||
hasLocation(#20065,#20034)
|
||||
#20066=*
|
||||
lines(#20066,#20001,"/\p{Number}/u;","
|
||||
")
|
||||
hasLocation(#20066,#20042)
|
||||
#20067=*
|
||||
tokeninfo(#20067,5,#20001,6,"/\p{Number}/u")
|
||||
hasLocation(#20067,#20044)
|
||||
lines(#20067,#20001,"/\P{Script=Greek}/u;","
|
||||
")
|
||||
hasLocation(#20067,#20048)
|
||||
#20068=*
|
||||
tokeninfo(#20068,8,#20001,7,";")
|
||||
#20069=@"loc,{#10000},4,14,4,14"
|
||||
locations_default(#20069,#10000,4,14,4,14)
|
||||
hasLocation(#20068,#20069)
|
||||
lines(#20068,#20001,"/\k</;","
|
||||
")
|
||||
hasLocation(#20068,#20054)
|
||||
numlines(#20001,6,6,0)
|
||||
#20069=*
|
||||
tokeninfo(#20069,5,#20001,0,"/^(?<ws>\s+)\w+\k<ws>$/")
|
||||
hasLocation(#20069,#20006)
|
||||
#20070=*
|
||||
tokeninfo(#20070,5,#20001,8,"/\P{Script=Greek}/u")
|
||||
hasLocation(#20070,#20050)
|
||||
#20071=*
|
||||
tokeninfo(#20071,8,#20001,9,";")
|
||||
#20072=@"loc,{#10000},5,20,5,20"
|
||||
locations_default(#20072,#10000,5,20,5,20)
|
||||
hasLocation(#20071,#20072)
|
||||
tokeninfo(#20070,8,#20001,1,";")
|
||||
#20071=@"loc,{#10000},1,24,1,24"
|
||||
locations_default(#20071,#10000,1,24,1,24)
|
||||
hasLocation(#20070,#20071)
|
||||
#20072=*
|
||||
tokeninfo(#20072,5,#20001,2,"/(?<=.)/")
|
||||
hasLocation(#20072,#20028)
|
||||
#20073=*
|
||||
tokeninfo(#20073,0,#20001,10,"")
|
||||
#20074=@"loc,{#10000},6,1,6,0"
|
||||
locations_default(#20074,#10000,6,1,6,0)
|
||||
tokeninfo(#20073,8,#20001,3,";")
|
||||
#20074=@"loc,{#10000},2,9,2,9"
|
||||
locations_default(#20074,#10000,2,9,2,9)
|
||||
hasLocation(#20073,#20074)
|
||||
#20075=*
|
||||
entry_cfg_node(#20075,#20001)
|
||||
#20076=@"loc,{#10000},1,1,1,0"
|
||||
locations_default(#20076,#10000,1,1,1,0)
|
||||
hasLocation(#20075,#20076)
|
||||
#20077=*
|
||||
exit_cfg_node(#20077,#20001)
|
||||
hasLocation(#20077,#20074)
|
||||
tokeninfo(#20075,5,#20001,4,"/(?<!.)/")
|
||||
hasLocation(#20075,#20036)
|
||||
#20076=*
|
||||
tokeninfo(#20076,8,#20001,5,";")
|
||||
#20077=@"loc,{#10000},3,9,3,9"
|
||||
locations_default(#20077,#10000,3,9,3,9)
|
||||
hasLocation(#20076,#20077)
|
||||
#20078=*
|
||||
tokeninfo(#20078,5,#20001,6,"/\p{Number}/u")
|
||||
hasLocation(#20078,#20044)
|
||||
#20079=*
|
||||
tokeninfo(#20079,8,#20001,7,";")
|
||||
#20080=@"loc,{#10000},4,14,4,14"
|
||||
locations_default(#20080,#10000,4,14,4,14)
|
||||
hasLocation(#20079,#20080)
|
||||
#20081=*
|
||||
tokeninfo(#20081,5,#20001,8,"/\P{Script=Greek}/u")
|
||||
hasLocation(#20081,#20050)
|
||||
#20082=*
|
||||
tokeninfo(#20082,8,#20001,9,";")
|
||||
#20083=@"loc,{#10000},5,20,5,20"
|
||||
locations_default(#20083,#10000,5,20,5,20)
|
||||
hasLocation(#20082,#20083)
|
||||
#20084=*
|
||||
tokeninfo(#20084,5,#20001,10,"/\k</")
|
||||
hasLocation(#20084,#20056)
|
||||
#20085=*
|
||||
tokeninfo(#20085,8,#20001,11,";")
|
||||
#20086=@"loc,{#10000},6,6,6,6"
|
||||
locations_default(#20086,#10000,6,6,6,6)
|
||||
hasLocation(#20085,#20086)
|
||||
#20087=*
|
||||
tokeninfo(#20087,0,#20001,12,"")
|
||||
#20088=@"loc,{#10000},7,1,7,0"
|
||||
locations_default(#20088,#10000,7,1,7,0)
|
||||
hasLocation(#20087,#20088)
|
||||
#20089=*
|
||||
entry_cfg_node(#20089,#20001)
|
||||
#20090=@"loc,{#10000},1,1,1,0"
|
||||
locations_default(#20090,#10000,1,1,1,0)
|
||||
hasLocation(#20089,#20090)
|
||||
#20091=*
|
||||
exit_cfg_node(#20091,#20001)
|
||||
hasLocation(#20091,#20088)
|
||||
successor(#20053,#20055)
|
||||
successor(#20055,#20091)
|
||||
successor(#20047,#20049)
|
||||
successor(#20049,#20077)
|
||||
successor(#20049,#20053)
|
||||
successor(#20041,#20043)
|
||||
successor(#20043,#20047)
|
||||
successor(#20033,#20035)
|
||||
@@ -252,6 +296,6 @@ successor(#20025,#20027)
|
||||
successor(#20027,#20033)
|
||||
successor(#20003,#20005)
|
||||
successor(#20005,#20025)
|
||||
successor(#20075,#20003)
|
||||
numlines(#10000,5,5,0)
|
||||
successor(#20089,#20003)
|
||||
numlines(#10000,6,6,0)
|
||||
filetype(#10000,"javascript")
|
||||
|
||||
BIN
javascript/extractor/tests/regexp/output/trap/tst.js.trap
Normal file
BIN
javascript/extractor/tests/regexp/output/trap/tst.js.trap
Normal file
Binary file not shown.
Reference in New Issue
Block a user