case "STRN.DOUBLE_QUOTE": // used for object lit detection..
case "STRN.SINGLE_QUOTE":
//println("<i>"+token.data+"</i>");
case "STRN.DOUBLE_QUOTE": // used for object lit detection..
case "STRN.SINGLE_QUOTE":
//println("<i>"+token.data+"</i>");
// then we are in an object lit.. -> we need to flag the brace as such...
isObjectLitAr.pop();
isObjectLitAr.push(true);
}
var isInObjectLitAr = isObjectLitAr[isObjectLitAr.length-1];
// then we are in an object lit.. -> we need to flag the brace as such...
isObjectLitAr.pop();
isObjectLitAr.push(true);
}
var isInObjectLitAr = isObjectLitAr[isObjectLitAr.length-1];
- if (isInObjectLitAr && this.ts.look(1).data == ':' &&
- ( this.ts.look(-1).data == '{' || this.ts.look(-1).data == ':' )) {
+ if (isInObjectLitAr && this.ts.lookTok(1).data == ':' &&
+ ( this.ts.lookTok(-1).data == '{' || this.ts.lookTok(-1).data == ':' )) {
// see if we can replace..
// remove the quotes..
// should do a bit more checking!!!! (what about wierd char's in the string..
// see if we can replace..
// remove the quotes..
// should do a bit more checking!!!! (what about wierd char's in the string..
// skip, it's an object lit key..
//println("<i>"+token.data+"</i>");
break;
// skip, it's an object lit key..
//println("<i>"+token.data+"</i>");
break;
// skip, it's an object prop.
//println("<i>"+token.data+"</i>");
break;
// skip, it's an object prop.
//println("<i>"+token.data+"</i>");
break;
- if (isInObjectLitAr && this.ts.look(1).data = ":" &&
- ( this.ts.look(-1).data == "{" || this.ts.look(-1).data == "," )) {
+ if (isInObjectLitAr && this.ts.lookTok(1).data = ":" &&
+ ( this.ts.lookTok(-1).data == "{" || this.ts.lookTok(-1).data == "," )) {
// see if we can replace..
// remove the quotes..
var str = token.data.substring(1,token.data.length-1);
// see if we can replace..
// remove the quotes..
var str = token.data.substring(1,token.data.length-1);
// then we are in an object lit.. -> we need to flag the brace as such...
isObjectLitAr.pop();
isObjectLitAr.push(true);
break;
}
var isInObjectLitAr = isObjectLitAr[isObjectLitAr.length-1];
// then we are in an object lit.. -> we need to flag the brace as such...
isObjectLitAr.pop();
isObjectLitAr.push(true);
break;
}
var isInObjectLitAr = isObjectLitAr[isObjectLitAr.length-1];