# Conflicts:
#	contributors.txt
This commit is contained in:
Tom Everett 2017-03-09 19:52:01 -07:00
commit a1d76e33a2
3 changed files with 11 additions and 4 deletions

View File

@ -1,4 +1,4 @@
ANTLR Project Contributors Certification of Origin and Rights
ANTLR Project Contributors Certification of Origin and Rights
All contributors to ANTLR v4 must formally agree to abide by this
certificate of origin by signing on the bottom with their github
@ -138,5 +138,5 @@ YYYY/MM/DD, github id, Full name, email
2017/02/14, xied75, Dong Xie, xied75@gmail.com
2017/02/20, Thomasb81, Thomas Burg, thomasb81@gmail.com
2017/02/26, jvasileff, John Vasileff, john@vasileff.com
2017/03/08, harry-tallbelt, Igor Vysokopoyasny, harry.tallbelt@gmail.com
2017/03/09, teverett, Tom Everett, tom@khubla.com

View File

@ -39,6 +39,7 @@ Resolving deltas: 100% (31898/31898), done.
Checking connectivity... done.
$ cd antlr4
$ export MAVEN_OPTS="-Xmx1G" # don't forget this on linux
$ mvn clean # must be separate, not part of install/compile
$ mvn -DskipTests install
...
[INFO] ------------------------------------------------------------------------
@ -61,7 +62,7 @@ $ mvn -DskipTests install
[INFO] ------------------------------------------------------------------------
```
We do `install` not `compile` as tool tests and such refer to modules that must be pulled from the maven install local cache.
**NOTE:** We do `install` not `compile` as tool tests and such refer to modules that must be pulled from the maven install local cache.
# Installing libs to mvn cache locally

View File

@ -119,8 +119,11 @@ ParserRuleContext.prototype.addErrorNode = function(badToken) {
ParserRuleContext.prototype.getChild = function(i, type) {
type = type || null;
if (this.children === null || i < 0 || i >= this.children.length) {
return null;
}
if (type === null) {
return this.children.length>=i ? this.children[i] : null;
return this.children[i];
} else {
for(var j=0; j<this.children.length; j++) {
var child = this.children[j];
@ -138,6 +141,9 @@ ParserRuleContext.prototype.getChild = function(i, type) {
ParserRuleContext.prototype.getToken = function(ttype, i) {
if (this.children === null || i < 0 || i >= this.children.length) {
return null;
}
for(var j=0; j<this.children.length; j++) {
var child = this.children[j];
if (child instanceof TerminalNode) {