id
int32
0
12.9k
code
sequencelengths
2
264k
6,700
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "classgen", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassCodeVisitorSupport", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ConstructorNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Parameter", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "PropertyNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Variable", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "BinaryExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstantExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "DeclarationExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "GStringExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MapEntryExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MethodCallExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "PropertyExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "TupleExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "VariableExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "CatchStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "MetaClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "Types", ";", "import", "static", "java", ".", "lang", ".", "reflect", ".", "Modifier", ".", "*", ";", "public", "class", "ClassCompletionVerifier", "extends", "ClassCodeVisitorSupport", "{", "private", "ClassNode", "currentClass", ";", "private", "SourceUnit", "source", ";", "private", "boolean", "inConstructor", "=", "false", ";", "private", "boolean", "inStaticConstructor", "=", "false", ";", "public", "ClassCompletionVerifier", "(", "SourceUnit", "source", ")", "{", "this", ".", "source", "=", "source", ";", "}", "public", "ClassNode", "getClassNode", "(", ")", "{", "return", "currentClass", ";", "}", "public", "void", "visitClass", "(", "ClassNode", "node", ")", "{", "ClassNode", "oldClass", "=", "currentClass", ";", "currentClass", "=", "node", ";", "checkImplementsAndExtends", "(", "node", ")", ";", "if", "(", "source", "!=", "null", "&&", "!", "source", ".", "getErrorCollector", "(", ")", ".", "hasErrors", "(", ")", ")", "{", "checkClassForIncorrectModifiers", "(", "node", ")", ";", "checkClassForOverwritingFinal", "(", "node", ")", ";", "checkMethodsForIncorrectModifiers", "(", "node", ")", ";", "checkMethodsForWeakerAccess", "(", "node", ")", ";", "checkMethodsForOverridingFinal", "(", "node", ")", ";", "checkNoAbstractMethodsNonabstractClass", "(", "node", ")", ";", "}", "super", ".", "visitClass", "(", "node", ")", ";", "currentClass", "=", "oldClass", ";", "}", "private", "void", "checkNoAbstractMethodsNonabstractClass", "(", "ClassNode", "node", ")", "{", "if", "(", "isAbstract", "(", "node", ".", "getModifiers", "(", ")", ")", ")", "return", ";", "List", "<", "MethodNode", ">", "abstractMethods", "=", "node", ".", "getAbstractMethods", "(", ")", ";", "if", "(", "abstractMethods", "==", "null", ")", "return", ";", "for", "(", "MethodNode", "method", ":", "abstractMethods", ")", "{", "addTypeError", "(", "\"\"", "+", "\"", "The", "\"", "+", "getDescription", "(", "node", ")", "+", "\"\"", "+", "\"", "the", "\"", "+", "getDescription", "(", "method", ")", "+", "\"\"", ",", "node", ")", ";", "}", "}", "private", "void", "checkClassForIncorrectModifiers", "(", "ClassNode", "node", ")", "{", "checkClassForAbstractAndFinal", "(", "node", ")", ";", "checkClassForOtherModifiers", "(", "node", ")", ";", "}", "private", "void", "checkClassForAbstractAndFinal", "(", "ClassNode", "node", ")", "{", "if", "(", "!", "isAbstract", "(", "node", ".", "getModifiers", "(", ")", ")", ")", "return", ";", "if", "(", "!", "isFinal", "(", "node", ".", "getModifiers", "(", ")", ")", ")", "return", ";", "if", "(", "node", ".", "isInterface", "(", ")", ")", "{", "addError", "(", "\"The", "\"", "+", "getDescription", "(", "node", ")", "+", "\"\"", ",", "node", ")", ";", "}", "else", "{", "addError", "(", "\"The", "\"", "+", "getDescription", "(", "node", ")", "+", "\"\"", ",", "node", ")", ";", "}", "}", "private", "void", "checkClassForOtherModifiers", "(", "ClassNode", "node", ")", "{", "checkClassForModifier", "(", "node", ",", "isTransient", "(", "node", ".", "getModifiers", "(", ")", ")", ",", "\"transient\"", ")", ";", "checkClassForModifier", "(", "node", ",", "isVolatile", "(", "node", ".", "getModifiers", "(", ")", ")", ",", "\"volatile\"", ")", ";", "checkClassForModifier", "(", "node", ",", "isNative", "(", "node", ".", "getModifiers", "(", ")", ")", ",", "\"native\"", ")", ";", "}", "private", "void", "checkMethodForModifier", "(", "MethodNode", "node", ",", "boolean", "condition", ",", "String", "modifierName", ")", "{", "if", "(", "!", "condition", ")", "return", ";", "addError", "(", "\"The", "\"", "+", "getDescription", "(", "node", ")", "+", "\"\"", "+", "modifierName", "+", "\".\"", ",", "node", ")", ";", "}", "private", "void", "checkClassForModifier", "(", "ClassNode", "node", ",", "boolean", "condition", ",", "String", "modifierName", ")", "{", "if", "(", "!", "condition", ")", "return", ";", "addError", "(", "\"The", "\"", "+", "getDescription", "(", "node", ")", "+", "\"\"", "+", "modifierName", "+", "\".\"", ",", "node", ")", ";", "}", "private", "String", "getDescription", "(", "ClassNode", "node", ")", "{", "return", "(", "node", ".", "isInterface", "(", ")", "?", "\"interface\"", ":", "\"class\"", ")", "+", "\"", "'\"", "+", "node", ".", "getName", "(", ")", "+", "\"'\"", ";", "}", "private", "String", "getDescription", "(", "MethodNode", "node", ")", "{", "return", "\"method", "'\"", "+", "node", ".", "getTypeDescriptor", "(", ")", "+", "\"'\"", ";", "}", "private", "String", "getDescription", "(", "FieldNode", "node", ")", "{", "return", "\"field", "'\"", "+", "node", ".", "getName", "(", ")", "+", "\"'\"", ";", "}", "private", "void", "checkAbstractDeclaration", "(", "MethodNode", "methodNode", ")", "{", "if", "(", "!", "isAbstract", "(", "methodNode", ".", "getModifiers", "(", ")", ")", ")", "return", ";", "if", "(", "isAbstract", "(", "currentClass", ".", "getModifiers", "(", ")", ")", ")", "return", ";", "addError", "(", "\"\"", "+", "\"", "The", "\"", "+", "getDescription", "(", "currentClass", ")", "+", "\"\"", "+", "methodNode", ".", "getTypeDescriptor", "(", ")", "+", "\"\"", ",", "methodNode", ")", ";", "}", "private", "void", "checkClassForOverwritingFinal", "(", "ClassNode", "cn", ")", "{", "ClassNode", "superCN", "=", "cn", ".", "getSuperClass", "(", ")", ";", "if", "(", "superCN", "==", "null", ")", "return", ";", "if", "(", "!", "isFinal", "(", "superCN", ".", "getModifiers", "(", ")", ")", ")", "return", ";", "StringBuffer", "msg", "=", "new", "StringBuffer", "(", ")", ";", "msg", ".", "append", "(", "\"\"", ")", ";", "msg", ".", "append", "(", "getDescription", "(", "superCN", ")", ")", ";", "msg", ".", "append", "(", "\".\"", ")", ";", "addError", "(", "msg", ".", "toString", "(", ")", ",", "cn", ")", ";", "}", "private", "void", "checkImplementsAndExtends", "(", "ClassNode", "node", ")", "{", "ClassNode", "cn", "=", "node", ".", "getSuperClass", "(", ")", ";", "if", "(", "cn", ".", "isInterface", "(", ")", "&&", "!", "node", ".", "isInterface", "(", ")", ")", "{", "addTypeError", "(", "\"\"", "+", "getDescription", "(", "cn", ")", "+", "\"\"", ",", "node", ")", ";", "}", "for", "(", "ClassNode", "anInterface", ":", "node", ".", "getInterfaces", "(", ")", ")", "{", "cn", "=", "anInterface", ";", "if", "(", "!", "cn", ".", "isInterface", "(", ")", ")", "{", "addTypeError", "(", "\"\"", "+", "getDescription", "(", "cn", ")", "+", "\"\"", ",", "node", ")", ";", "}", "}", "}", "private", "void", "checkMethodsForIncorrectModifiers", "(", "ClassNode", "cn", ")", "{", "if", "(", "!", "cn", ".", "isInterface", "(", ")", ")", "return", ";", "for", "(", "MethodNode", "method", ":", "cn", ".", "getMethods", "(", ")", ")", "{", "if", "(", "isFinal", "(", "method", ".", "getModifiers", "(", ")", ")", ")", "{", "addError", "(", "\"The", "\"", "+", "getDescription", "(", "method", ")", "+", "\"", "from", "\"", "+", "getDescription", "(", "cn", ")", "+", "\"\"", ",", "method", ")", ";", "}", "if", "(", "isStatic", "(", "method", ".", "getModifiers", "(", ")", ")", "&&", "!", "isConstructor", "(", "method", ")", ")", "{", "addError", "(", "\"The", "\"", "+", "getDescription", "(", "method", ")", "+", "\"", "from", "\"", "+", "getDescription", "(", "cn", ")", "+", "\"\"", ",", "method", ")", ";", "}", "}", "}", "private", "void", "checkMethodsForWeakerAccess", "(", "ClassNode", "cn", ")", "{", "for", "(", "MethodNode", "method", ":", "cn", ".", "getMethods", "(", ")", ")", "{", "checkMethodForWeakerAccessPrivileges", "(", "method", ",", "cn", ")", ";", "}", "}", "private", "boolean", "isConstructor", "(", "MethodNode", "method", ")", "{", "return", "method", ".", "getName", "(", ")", ".", "equals", "(", "\"<clinit>\"", ")", ";", "}", "private", "void", "checkMethodsForOverridingFinal", "(", "ClassNode", "cn", ")", "{", "for", "(", "MethodNode", "method", ":", "cn", ".", "getMethods", "(", ")", ")", "{", "Parameter", "[", "]", "params", "=", "method", ".", "getParameters", "(", ")", ";", "for", "(", "MethodNode", "superMethod", ":", "cn", ".", "getSuperClass", "(", ")", ".", "getMethods", "(", "method", ".", "getName", "(", ")", ")", ")", "{", "Parameter", "[", "]", "superParams", "=", "superMethod", ".", "getParameters", "(", ")", ";", "if", "(", "!", "hasEqualParameterTypes", "(", "params", ",", "superParams", ")", ")", "continue", ";", "if", "(", "!", "isFinal", "(", "superMethod", ".", "getModifiers", "(", ")", ")", ")", "break", ";", "addInvalidUseOfFinalError", "(", "method", ",", "params", ",", "superMethod", ".", "getDeclaringClass", "(", ")", ")", ";", "return", ";", "}", "}", "}", "private", "void", "addInvalidUseOfFinalError", "(", "MethodNode", "method", ",", "Parameter", "[", "]", "parameters", ",", "ClassNode", "superCN", ")", "{", "StringBuffer", "msg", "=", "new", "StringBuffer", "(", ")", ";", "msg", ".", "append", "(", "\"\"", ")", ".", "append", "(", "method", ".", "getName", "(", ")", ")", ";", "msg", ".", "append", "(", "\"(\"", ")", ";", "boolean", "needsComma", "=", "false", ";", "for", "(", "Parameter", "parameter", ":", "parameters", ")", "{", "if", "(", "needsComma", ")", "{", "msg", ".", "append", "(", "\",\"", ")", ";", "}", "else", "{", "needsComma", "=", "true", ";", "}", "msg", ".", "append", "(", "parameter", ".", "getType", "(", ")", ")", ";", "}", "msg", ".", "append", "(", "\")", "from", "\"", ")", ".", "append", "(", "getDescription", "(", "superCN", ")", ")", ";", "msg", ".", "append", "(", "\".\"", ")", ";", "addError", "(", "msg", ".", "toString", "(", ")", ",", "method", ")", ";", "}", "private", "void", "addWeakerAccessError", "(", "ClassNode", "cn", ",", "MethodNode", "method", ",", "Parameter", "[", "]", "parameters", ",", "MethodNode", "superMethod", ")", "{", "StringBuffer", "msg", "=", "new", "StringBuffer", "(", ")", ";", "msg", ".", "append", "(", "method", ".", "getName", "(", ")", ")", ";", "msg", ".", "append", "(", "\"(\"", ")", ";", "boolean", "needsComma", "=", "false", ";", "for", "(", "Parameter", "parameter", ":", "parameters", ")", "{", "if", "(", "needsComma", ")", "{", "msg", ".", "append", "(", "\",\"", ")", ";", "}", "else", "{", "needsComma", "=", "true", ";", "}", "msg", ".", "append", "(", "parameter", ".", "getType", "(", ")", ")", ";", "}", "msg", ".", "append", "(", "\")", "in", "\"", ")", ";", "msg", ".", "append", "(", "cn", ".", "getName", "(", ")", ")", ";", "msg", ".", "append", "(", "\"\"", ")", ";", "msg", ".", "append", "(", "superMethod", ".", "getName", "(", ")", ")", ";", "msg", ".", "append", "(", "\"", "in", "\"", ")", ";", "msg", ".", "append", "(", "superMethod", ".", "getDeclaringClass", "(", ")", ".", "getName", "(", ")", ")", ";", "msg", ".", "append", "(", "\"\"", ")", ";", "msg", ".", "append", "(", "isPublic", "(", "superMethod", ".", "getModifiers", "(", ")", ")", "?", "\"public\"", ":", "\"protected\"", ")", ";", "addError", "(", "msg", ".", "toString", "(", ")", ",", "method", ")", ";", "}", "private", "boolean", "hasEqualParameterTypes", "(", "Parameter", "[", "]", "first", ",", "Parameter", "[", "]", "second", ")", "{", "if", "(", "first", ".", "length", "!=", "second", ".", "length", ")", "return", "false", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "first", ".", "length", ";", "i", "++", ")", "{", "String", "ft", "=", "first", "[", "i", "]", ".", "getType", "(", ")", ".", "getName", "(", ")", ";", "String", "st", "=", "second", "[", "i", "]", ".", "getType", "(", ")", ".", "getName", "(", ")", ";", "if", "(", "ft", ".", "equals", "(", "st", ")", ")", "continue", ";", "return", "false", ";", "}", "return", "true", ";", "}", "protected", "SourceUnit", "getSourceUnit", "(", ")", "{", "return", "source", ";", "}", "public", "void", "visitMethod", "(", "MethodNode", "node", ")", "{", "inConstructor", "=", "false", ";", "inStaticConstructor", "=", "node", ".", "isStaticConstructor", "(", ")", ";", "checkAbstractDeclaration", "(", "node", ")", ";", "checkRepetitiveMethod", "(", "node", ")", ";", "checkOverloadingPrivateAndPublic", "(", "node", ")", ";", "checkMethodModifiers", "(", "node", ")", ";", "super", ".", "visitMethod", "(", "node", ")", ";", "}", "private", "void", "checkMethodModifiers", "(", "MethodNode", "node", ")", "{", "if", "(", "(", "this", ".", "currentClass", ".", "getModifiers", "(", ")", "&", "Opcodes", ".", "ACC_INTERFACE", ")", "!=", "0", ")", "{", "checkMethodForModifier", "(", "node", ",", "isStrict", "(", "node", ".", "getModifiers", "(", ")", ")", ",", "\"strictfp\"", ")", ";", "checkMethodForModifier", "(", "node", ",", "isSynchronized", "(", "node", ".", "getModifiers", "(", ")", ")", ",", "\"synchronized\"", ")", ";", "checkMethodForModifier", "(", "node", ",", "isNative", "(", "node", ".", "getModifiers", "(", ")", ")", ",", "\"native\"", ")", ";", "}", "}", "private", "void", "checkMethodForWeakerAccessPrivileges", "(", "MethodNode", "mn", ",", "ClassNode", "cn", ")", "{", "Parameter", "[", "]", "params", "=", "mn", ".", "getParameters", "(", ")", ";", "for", "(", "MethodNode", "superMethod", ":", "cn", ".", "getSuperClass", "(", ")", ".", "getMethods", "(", "mn", ".", "getName", "(", ")", ")", ")", "{", "Parameter", "[", "]", "superParams", "=", "superMethod", ".", "getParameters", "(", ")", ";", "if", "(", "!", "hasEqualParameterTypes", "(", "params", ",", "superParams", ")", ")", "continue", ";", "if", "(", "(", "isPrivate", "(", "mn", ".", "getModifiers", "(", ")", ")", "&&", "!", "isPrivate", "(", "superMethod", ".", "getModifiers", "(", ")", ")", ")", "||", "(", "isProtected", "(", "mn", ".", "getModifiers", "(", ")", ")", "&&", "isPublic", "(", "superMethod", ".", "getModifiers", "(", ")", ")", ")", ")", "{", "addWeakerAccessError", "(", "cn", ",", "mn", ",", "params", ",", "superMethod", ")", ";", "return", ";", "}", "}", "}", "private", "void", "checkOverloadingPrivateAndPublic", "(", "MethodNode", "node", ")", "{", "if", "(", "isConstructor", "(", "node", ")", ")", "return", ";", "boolean", "hasPrivate", "=", "false", ";", "boolean", "hasPublic", "=", "false", ";", "for", "(", "MethodNode", "method", ":", "currentClass", ".", "getMethods", "(", "node", ".", "getName", "(", ")", ")", ")", "{", "if", "(", "method", "==", "node", ")", "continue", ";", "if", "(", "!", "method", ".", "getDeclaringClass", "(", ")", ".", "equals", "(", "node", ".", "getDeclaringClass", "(", ")", ")", ")", "continue", ";", "int", "modifiers", "=", "method", ".", "getModifiers", "(", ")", ";", "if", "(", "isPublic", "(", "modifiers", ")", "||", "isProtected", "(", "modifiers", ")", ")", "{", "hasPublic", "=", "true", ";", "}", "else", "{", "hasPrivate", "=", "true", ";", "}", "}", "if", "(", "hasPrivate", "&&", "hasPublic", ")", "{", "addError", "(", "\"\"", ",", "node", ")", ";", "}", "}", "private", "void", "checkRepetitiveMethod", "(", "MethodNode", "node", ")", "{", "if", "(", "isConstructor", "(", "node", ")", ")", "return", ";", "for", "(", "MethodNode", "method", ":", "currentClass", ".", "getMethods", "(", "node", ".", "getName", "(", ")", ")", ")", "{", "if", "(", "method", "==", "node", ")", "continue", ";", "if", "(", "!", "method", ".", "getDeclaringClass", "(", ")", ".", "equals", "(", "node", ".", "getDeclaringClass", "(", ")", ")", ")", "continue", ";", "Parameter", "[", "]", "p1", "=", "node", ".", "getParameters", "(", ")", ";", "Parameter", "[", "]", "p2", "=", "method", ".", "getParameters", "(", ")", ";", "if", "(", "p1", ".", "length", "!=", "p2", ".", "length", ")", "continue", ";", "addErrorIfParamsAndReturnTypeEqual", "(", "p2", ",", "p1", ",", "node", ",", "method", ")", ";", "}", "}", "private", "void", "addErrorIfParamsAndReturnTypeEqual", "(", "Parameter", "[", "]", "p2", ",", "Parameter", "[", "]", "p1", ",", "MethodNode", "node", ",", "MethodNode", "element", ")", "{", "boolean", "isEqual", "=", "true", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "p2", ".", "length", ";", "i", "++", ")", "{", "isEqual", "&=", "p1", "[", "i", "]", ".", "getType", "(", ")", ".", "equals", "(", "p2", "[", "i", "]", ".", "getType", "(", ")", ")", ";", "}", "isEqual", "&=", "node", ".", "getReturnType", "(", ")", ".", "equals", "(", "element", ".", "getReturnType", "(", ")", ")", ";", "if", "(", "isEqual", ")", "{", "addError", "(", "\"\"", "+", "getDescription", "(", "node", ")", "+", "\"", "in", "\"", "+", "getDescription", "(", "currentClass", ")", "+", "\".\"", ",", "node", ")", ";", "}", "}", "public", "void", "visitField", "(", "FieldNode", "node", ")", "{", "if", "(", "currentClass", ".", "getDeclaredField", "(", "node", ".", "getName", "(", ")", ")", "!=", "node", ")", "{", "addError", "(", "\"The", "\"", "+", "getDescription", "(", "node", ")", "+", "\"\"", ",", "node", ")", ";", "}", "checkInterfaceFieldModifiers", "(", "node", ")", ";", "super", ".", "visitField", "(", "node", ")", ";", "}", "public", "void", "visitProperty", "(", "PropertyNode", "node", ")", "{", "checkDuplicateProperties", "(", "node", ")", ";", "super", ".", "visitProperty", "(", "node", ")", ";", "}", "private", "void", "checkDuplicateProperties", "(", "PropertyNode", "node", ")", "{", "ClassNode", "cn", "=", "node", ".", "getDeclaringClass", "(", ")", ";", "String", "name", "=", "node", ".", "getName", "(", ")", ";", "String", "getterName", "=", "\"get\"", "+", "MetaClassHelper", ".", "capitalize", "(", "name", ")", ";", "if", "(", "Character", ".", "isUpperCase", "(", "name", ".", "charAt", "(", "0", ")", ")", ")", "{", "for", "(", "PropertyNode", "propNode", ":", "cn", ".", "getProperties", "(", ")", ")", "{", "String", "otherName", "=", "propNode", ".", "getField", "(", ")", ".", "getName", "(", ")", ";", "String", "otherGetterName", "=", "\"get\"", "+", "MetaClassHelper", ".", "capitalize", "(", "otherName", ")", ";", "if", "(", "node", "!=", "propNode", "&&", "getterName", ".", "equals", "(", "otherGetterName", ")", ")", "{", "String", "msg", "=", "\"The", "field", "\"", "+", "name", "+", "\"", "and", "\"", "+", "otherName", "+", "\"\"", "+", "cn", ".", "getName", "(", ")", "+", "\"\"", ";", "addError", "(", "msg", ",", "node", ")", ";", "}", "}", "}", "}", "private", "void", "checkInterfaceFieldModifiers", "(", "FieldNode", "node", ")", "{", "if", "(", "!", "currentClass", ".", "isInterface", "(", ")", ")", "return", ";", "if", "(", "(", "node", ".", "getModifiers", "(", ")", "&", "(", "Opcodes", ".", "ACC_PUBLIC", "|", "Opcodes", ".", "ACC_STATIC", "|", "Opcodes", ".", "ACC_FINAL", ")", ")", "==", "0", ")", "{", "addError", "(", "\"The", "\"", "+", "getDescription", "(", "node", ")", "+", "\"\"", "+", "getDescription", "(", "currentClass", ")", "+", "\".\"", ",", "node", ")", ";", "}", "}", "public", "void", "visitBinaryExpression", "(", "BinaryExpression", "expression", ")", "{", "if", "(", "expression", ".", "getOperation", "(", ")", ".", "getType", "(", ")", "==", "Types", ".", "LEFT_SQUARE_BRACKET", "&&", "expression", ".", "getRightExpression", "(", ")", "instanceof", "MapEntryExpression", ")", "{", "addError", "(", "\"\"", "+", "\"\"", ",", "expression", ".", "getRightExpression", "(", ")", ")", ";", "}", "super", ".", "visitBinaryExpression", "(", "expression", ")", ";", "switch", "(", "expression", ".", "getOperation", "(", ")", ".", "getType", "(", ")", ")", "{", "case", "Types", ".", "EQUAL", ":", "case", "Types", ".", "BITWISE_AND_EQUAL", ":", "case", "Types", ".", "BITWISE_OR_EQUAL", ":", "case", "Types", ".", "BITWISE_XOR_EQUAL", ":", "case", "Types", ".", "PLUS_EQUAL", ":", "case", "Types", ".", "MINUS_EQUAL", ":", "case", "Types", ".", "MULTIPLY_EQUAL", ":", "case", "Types", ".", "DIVIDE_EQUAL", ":", "case", "Types", ".", "INTDIV_EQUAL", ":", "case", "Types", ".", "MOD_EQUAL", ":", "case", "Types", ".", "POWER_EQUAL", ":", "case", "Types", ".", "LEFT_SHIFT_EQUAL", ":", "case", "Types", ".", "RIGHT_SHIFT_EQUAL", ":", "case", "Types", ".", "RIGHT_SHIFT_UNSIGNED_EQUAL", ":", "checkFinalFieldAccess", "(", "expression", ".", "getLeftExpression", "(", ")", ")", ";", "break", ";", "default", ":", "break", ";", "}", "}", "private", "void", "checkFinalFieldAccess", "(", "Expression", "expression", ")", "{", "if", "(", "!", "(", "expression", "instanceof", "VariableExpression", ")", "&&", "!", "(", "expression", "instanceof", "PropertyExpression", ")", ")", "return", ";", "Variable", "v", "=", "null", ";", "if", "(", "expression", "instanceof", "VariableExpression", ")", "{", "VariableExpression", "ve", "=", "(", "VariableExpression", ")", "expression", ";", "v", "=", "ve", ".", "getAccessedVariable", "(", ")", ";", "}", "else", "{", "PropertyExpression", "propExp", "=", "(", "(", "PropertyExpression", ")", "expression", ")", ";", "Expression", "objectExpression", "=", "propExp", ".", "getObjectExpression", "(", ")", ";", "if", "(", "objectExpression", "instanceof", "VariableExpression", ")", "{", "VariableExpression", "varExp", "=", "(", "VariableExpression", ")", "objectExpression", ";", "if", "(", "varExp", ".", "isThisExpression", "(", ")", ")", "{", "v", "=", "currentClass", ".", "getDeclaredField", "(", "propExp", ".", "getPropertyAsString", "(", ")", ")", ";", "}", "}", "}", "if", "(", "v", "instanceof", "FieldNode", ")", "{", "FieldNode", "fn", "=", "(", "FieldNode", ")", "v", ";", "int", "modifiers", "=", "fn", ".", "getModifiers", "(", ")", ";", "boolean", "isFinal", "=", "(", "modifiers", "&", "Opcodes", ".", "ACC_FINAL", ")", "!=", "0", ";", "boolean", "isStatic", "=", "(", "modifiers", "&", "Opcodes", ".", "ACC_STATIC", ")", "!=", "0", ";", "boolean", "error", "=", "isFinal", "&&", "(", "(", "isStatic", "&&", "!", "inStaticConstructor", ")", "||", "(", "!", "isStatic", "&&", "!", "inConstructor", ")", ")", ";", "if", "(", "error", ")", "addError", "(", "\"\"", "+", "(", "isStatic", "?", "\"", "static\"", ":", "\"\"", ")", "+", "\"\"", "+", "fn", ".", "getName", "(", ")", "+", "\"\"", "+", "(", "isStatic", "?", "\"\"", ":", "\"constructor.\"", ")", ",", "expression", ")", ";", "}", "}", "public", "void", "visitConstructor", "(", "ConstructorNode", "node", ")", "{", "inConstructor", "=", "true", ";", "inStaticConstructor", "=", "node", ".", "isStaticConstructor", "(", ")", ";", "super", ".", "visitConstructor", "(", "node", ")", ";", "}", "public", "void", "visitCatchStatement", "(", "CatchStatement", "cs", ")", "{", "if", "(", "!", "(", "cs", ".", "getExceptionType", "(", ")", ".", "isDerivedFrom", "(", "ClassHelper", ".", "make", "(", "Throwable", ".", "class", ")", ")", ")", ")", "{", "addError", "(", "\"\"", ",", "cs", ")", ";", "}", "super", ".", "visitCatchStatement", "(", "cs", ")", ";", "}", "public", "void", "visitMethodCallExpression", "(", "MethodCallExpression", "mce", ")", "{", "super", ".", "visitMethodCallExpression", "(", "mce", ")", ";", "Expression", "aexp", "=", "mce", ".", "getArguments", "(", ")", ";", "if", "(", "aexp", "instanceof", "TupleExpression", ")", "{", "TupleExpression", "arguments", "=", "(", "TupleExpression", ")", "aexp", ";", "for", "(", "Expression", "e", ":", "arguments", ".", "getExpressions", "(", ")", ")", "{", "checkForInvalidDeclaration", "(", "e", ")", ";", "}", "}", "else", "{", "checkForInvalidDeclaration", "(", "aexp", ")", ";", "}", "}", "private", "void", "checkForInvalidDeclaration", "(", "Expression", "exp", ")", "{", "if", "(", "!", "(", "exp", "instanceof", "DeclarationExpression", ")", ")", "return", ";", "addError", "(", "\"\"", ",", "exp", ")", ";", "}", "public", "void", "visitConstantExpression", "(", "ConstantExpression", "expression", ")", "{", "super", ".", "visitConstantExpression", "(", "expression", ")", ";", "checkStringExceedingMaximumLength", "(", "expression", ")", ";", "}", "public", "void", "visitGStringExpression", "(", "GStringExpression", "expression", ")", "{", "super", ".", "visitGStringExpression", "(", "expression", ")", ";", "for", "(", "ConstantExpression", "ce", ":", "expression", ".", "getStrings", "(", ")", ")", "{", "checkStringExceedingMaximumLength", "(", "ce", ")", ";", "}", "}", "private", "void", "checkStringExceedingMaximumLength", "(", "ConstantExpression", "expression", ")", "{", "Object", "value", "=", "expression", ".", "getValue", "(", ")", ";", "if", "(", "value", "instanceof", "String", ")", "{", "String", "s", "=", "(", "String", ")", "value", ";", "if", "(", "s", ".", "length", "(", ")", ">", "65535", ")", "{", "addError", "(", "\"\"", "+", "s", ".", "length", "(", ")", "+", "\"\"", ",", "expression", ")", ";", "}", "}", "}", "}", "</s>" ]
6,701
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "java", ".", "io", ".", "IOException", ";", "import", "java", ".", "io", ".", "Reader", ";", "import", "antlr", ".", "CharScanner", ";", "import", "antlr", ".", "Token", ";", "import", "antlr", ".", "TokenStreamException", ";", "public", "class", "UnicodeEscapingReader", "extends", "Reader", "{", "private", "final", "Reader", "reader", ";", "private", "CharScanner", "lexer", ";", "private", "boolean", "hasNextChar", "=", "false", ";", "private", "int", "nextChar", ";", "private", "final", "SourceBuffer", "sourceBuffer", ";", "private", "int", "previousLine", ";", "private", "int", "numUnicodeEscapesFound", "=", "0", ";", "private", "int", "numUnicodeEscapesFoundOnCurrentLine", "=", "0", ";", "private", "static", "class", "DummyLexer", "extends", "CharScanner", "{", "final", "private", "Token", "t", "=", "new", "Token", "(", ")", ";", "public", "Token", "nextToken", "(", ")", "throws", "TokenStreamException", "{", "return", "t", ";", "}", "@", "Override", "public", "int", "getColumn", "(", ")", "{", "return", "0", ";", "}", "@", "Override", "public", "int", "getLine", "(", ")", "{", "return", "0", ";", "}", "}", "public", "UnicodeEscapingReader", "(", "Reader", "reader", ",", "SourceBuffer", "sourceBuffer", ")", "{", "this", ".", "reader", "=", "reader", ";", "this", ".", "sourceBuffer", "=", "sourceBuffer", ";", "if", "(", "sourceBuffer", "!=", "null", ")", "{", "sourceBuffer", ".", "setUnescaper", "(", "this", ")", ";", "}", "this", ".", "lexer", "=", "new", "DummyLexer", "(", ")", ";", "}", "public", "void", "setLexer", "(", "CharScanner", "lexer", ")", "{", "this", ".", "lexer", "=", "lexer", ";", "}", "public", "int", "read", "(", "char", "cbuf", "[", "]", ",", "int", "off", ",", "int", "len", ")", "throws", "IOException", "{", "int", "c", "=", "0", ";", "int", "count", "=", "0", ";", "while", "(", "count", "<", "len", "&&", "(", "c", "=", "read", "(", ")", ")", "!=", "-", "1", ")", "{", "cbuf", "[", "off", "+", "count", "]", "=", "(", "char", ")", "c", ";", "count", "++", ";", "}", "return", "(", "count", "==", "0", "&&", "c", "==", "-", "1", ")", "?", "-", "1", ":", "count", ";", "}", "public", "int", "read", "(", ")", "throws", "IOException", "{", "if", "(", "hasNextChar", ")", "{", "hasNextChar", "=", "false", ";", "write", "(", "nextChar", ")", ";", "return", "nextChar", ";", "}", "if", "(", "previousLine", "!=", "lexer", ".", "getLine", "(", ")", ")", "{", "numUnicodeEscapesFoundOnCurrentLine", "=", "0", ";", "previousLine", "=", "lexer", ".", "getLine", "(", ")", ";", "}", "int", "c", "=", "reader", ".", "read", "(", ")", ";", "if", "(", "c", "!=", "'\\\\'", ")", "{", "write", "(", "c", ")", ";", "return", "c", ";", "}", "c", "=", "reader", ".", "read", "(", ")", ";", "if", "(", "c", "!=", "'u'", ")", "{", "hasNextChar", "=", "true", ";", "nextChar", "=", "c", ";", "write", "(", "'\\\\'", ")", ";", "return", "'\\\\'", ";", "}", "int", "numberOfUChars", "=", "0", ";", "do", "{", "numberOfUChars", "++", ";", "c", "=", "reader", ".", "read", "(", ")", ";", "}", "while", "(", "c", "==", "'u'", ")", ";", "checkHexDigit", "(", "c", ")", ";", "StringBuffer", "charNum", "=", "new", "StringBuffer", "(", ")", ";", "charNum", ".", "append", "(", "(", "char", ")", "c", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "3", ";", "i", "++", ")", "{", "c", "=", "reader", ".", "read", "(", ")", ";", "checkHexDigit", "(", "c", ")", ";", "charNum", ".", "append", "(", "(", "char", ")", "c", ")", ";", "}", "int", "rv", "=", "Integer", ".", "parseInt", "(", "charNum", ".", "toString", "(", ")", ",", "16", ")", ";", "write", "(", "rv", ")", ";", "numUnicodeEscapesFound", "+=", "4", "+", "numberOfUChars", ";", "numUnicodeEscapesFoundOnCurrentLine", "+=", "4", "+", "numberOfUChars", ";", "return", "rv", ";", "}", "private", "void", "write", "(", "int", "c", ")", "{", "if", "(", "sourceBuffer", "!=", "null", ")", "{", "sourceBuffer", ".", "write", "(", "c", ")", ";", "}", "}", "private", "void", "checkHexDigit", "(", "int", "c", ")", "throws", "IOException", "{", "if", "(", "c", ">=", "'0'", "&&", "c", "<=", "'9'", ")", "{", "return", ";", "}", "if", "(", "c", ">=", "'a'", "&&", "c", "<=", "'f'", ")", "{", "return", ";", "}", "if", "(", "c", ">=", "'A'", "&&", "c", "<=", "'F'", ")", "{", "return", ";", "}", "hasNextChar", "=", "true", ";", "nextChar", "=", "c", ";", "throw", "new", "IOException", "(", "\"\"", "+", "\"", "line:", "\"", "+", "lexer", ".", "getLine", "(", ")", "+", "\"", "col:\"", "+", "lexer", ".", "getColumn", "(", ")", ")", ";", "}", "public", "int", "getUnescapedUnicodeColumnCount", "(", ")", "{", "return", "numUnicodeEscapesFoundOnCurrentLine", ";", "}", "public", "int", "getUnescapedUnicodeOffsetCount", "(", ")", "{", "return", "numUnicodeEscapesFound", ";", "}", "public", "void", "close", "(", ")", "throws", "IOException", "{", "reader", ".", "close", "(", ")", ";", "}", "}", "</s>" ]
6,702
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "java", ".", "io", ".", "Reader", ";", "class", "NoEscaper", "extends", "UnicodeEscapingReader", "{", "public", "NoEscaper", "(", ")", "{", "super", "(", "null", ",", "null", ")", ";", "}", "public", "int", "getUnescapedUnicodeColumnCount", "(", ")", "{", "return", "0", ";", "}", "public", "int", "getUnescapedUnicodeOffsetCount", "(", ")", "{", "return", "0", ";", "}", "}", "</s>" ]
6,703
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "java", ".", "io", ".", "Reader", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationFailedException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "parser", ".", "GroovyLexer", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "parser", ".", "GroovyRecognizer", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "SyntaxException", ";", "import", "antlr", ".", "RecognitionException", ";", "import", "antlr", ".", "TokenStreamException", ";", "import", "antlr", ".", "TokenStreamIOException", ";", "import", "antlr", ".", "TokenStreamRecognitionException", ";", "public", "class", "ErrorRecoveredCSTParserPlugin", "extends", "AntlrParserPlugin", "{", "private", "final", "ICSTReporter", "reporter", ";", "ErrorRecoveredCSTParserPlugin", "(", "ICSTReporter", "reporter", ")", "{", "this", ".", "reporter", "=", "reporter", ";", "}", "@", "Override", "public", "void", "transformCSTIntoAST", "(", "final", "SourceUnit", "sourceUnit", ",", "Reader", "reader", ",", "SourceBuffer", "sourceBuffer", ")", "throws", "CompilationFailedException", "{", "super", ".", "ast", "=", "null", ";", "setController", "(", "sourceUnit", ")", ";", "UnicodeEscapingReader", "unicodeReader", "=", "new", "UnicodeEscapingReader", "(", "reader", ",", "sourceBuffer", ")", ";", "GroovyLexer", "lexer", "=", "new", "GroovyLexer", "(", "new", "UnicodeLexerSharedInputState", "(", "unicodeReader", ")", ")", ";", "unicodeReader", ".", "setLexer", "(", "lexer", ")", ";", "GroovyRecognizer", "parser", "=", "GroovyRecognizer", ".", "make", "(", "lexer", ")", ";", "parser", ".", "setSourceBuffer", "(", "sourceBuffer", ")", ";", "super", ".", "tokenNames", "=", "parser", ".", "getTokenNames", "(", ")", ";", "parser", ".", "setFilename", "(", "sourceUnit", ".", "getName", "(", ")", ")", ";", "try", "{", "parser", ".", "compilationUnit", "(", ")", ";", "configureLocationSupport", "(", "sourceBuffer", ")", ";", "}", "catch", "(", "TokenStreamRecognitionException", "tsre", ")", "{", "configureLocationSupport", "(", "sourceBuffer", ")", ";", "RecognitionException", "e", "=", "tsre", ".", "recog", ";", "SyntaxException", "se", "=", "new", "SyntaxException", "(", "e", ".", "getMessage", "(", ")", ",", "e", ",", "e", ".", "getLine", "(", ")", ",", "e", ".", "getColumn", "(", ")", ")", ";", "se", ".", "setFatal", "(", "true", ")", ";", "sourceUnit", ".", "addError", "(", "se", ")", ";", "}", "catch", "(", "RecognitionException", "e", ")", "{", "configureLocationSupport", "(", "sourceBuffer", ")", ";", "int", "origLine", "=", "e", ".", "getLine", "(", ")", ";", "int", "origColumn", "=", "e", ".", "getColumn", "(", ")", ";", "int", "[", "]", "newInts", "=", "fixLineColumn", "(", "origLine", ",", "origColumn", ")", ";", "int", "newLine", "=", "newInts", "[", "0", "]", ";", "int", "newColumn", "=", "newInts", "[", "1", "]", ";", "SyntaxException", "se", "=", "new", "SyntaxException", "(", "e", ".", "getMessage", "(", ")", ",", "e", ",", "newLine", ",", "newColumn", ")", ";", "se", ".", "setFatal", "(", "true", ")", ";", "sourceUnit", ".", "addError", "(", "se", ")", ";", "}", "catch", "(", "TokenStreamException", "e", ")", "{", "configureLocationSupport", "(", "sourceBuffer", ")", ";", "boolean", "handled", "=", "false", ";", "if", "(", "e", "instanceof", "TokenStreamIOException", ")", "{", "TokenStreamIOException", "tsioe", "=", "(", "TokenStreamIOException", ")", "e", ";", "String", "m", "=", "e", ".", "getMessage", "(", ")", ";", "if", "(", "m", "!=", "null", "&&", "m", ".", "startsWith", "(", "\"\"", ")", ")", "{", "try", "{", "int", "linepos", "=", "m", ".", "indexOf", "(", "\"line:\"", ")", ";", "int", "colpos", "=", "m", ".", "indexOf", "(", "\"col:\"", ")", ";", "int", "line", "=", "Integer", ".", "valueOf", "(", "m", ".", "substring", "(", "linepos", "+", "5", ",", "colpos", ")", ".", "trim", "(", ")", ")", ";", "int", "col", "=", "Integer", ".", "valueOf", "(", "m", ".", "substring", "(", "colpos", "+", "4", ")", ".", "trim", "(", ")", ")", ";", "SyntaxException", "se", "=", "new", "SyntaxException", "(", "e", ".", "getMessage", "(", ")", ",", "e", ",", "line", ",", "col", ")", ";", "se", ".", "setFatal", "(", "true", ")", ";", "sourceUnit", ".", "addError", "(", "se", ")", ";", "handled", "=", "true", ";", "}", "catch", "(", "Throwable", "t", ")", "{", "System", ".", "err", ".", "println", "(", "m", ")", ";", "t", ".", "printStackTrace", "(", "System", ".", "err", ")", ";", "}", "}", "}", "if", "(", "!", "handled", ")", "{", "sourceUnit", ".", "addException", "(", "e", ")", ";", "}", "}", "super", ".", "ast", "=", "parser", ".", "getAST", "(", ")", ";", "sourceUnit", ".", "setComments", "(", "parser", ".", "getComments", "(", ")", ")", ";", "reportCST", "(", "sourceUnit", ",", "parser", ")", ";", "}", "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "private", "void", "reportCST", "(", "final", "SourceUnit", "sourceUnit", ",", "final", "GroovyRecognizer", "parser", ")", "{", "final", "List", "errorList", "=", "parser", ".", "getErrorList", "(", ")", ";", "final", "GroovySourceAST", "cst", "=", "(", "GroovySourceAST", ")", "parser", ".", "getAST", "(", ")", ";", "if", "(", "reporter", "!=", "null", ")", "{", "if", "(", "cst", "!=", "null", ")", "reporter", ".", "generatedCST", "(", "sourceUnit", ".", "getName", "(", ")", ",", "cst", ")", ";", "if", "(", "errorList", ".", "size", "(", ")", "!=", "0", ")", "reporter", ".", "reportErrors", "(", "sourceUnit", ".", "getName", "(", ")", ",", "Collections", ".", "unmodifiableList", "(", "errorList", ")", ")", ";", "}", "else", "{", "for", "(", "Map", "<", "String", ",", "Object", ">", "error", ":", "(", "List", "<", "Map", "<", "String", ",", "Object", ">", ">", ")", "errorList", ")", "{", "int", "origLine", "=", "(", "(", "Integer", ")", "error", ".", "get", "(", "\"line\"", ")", ")", ".", "intValue", "(", ")", ";", "int", "origColumn", "=", "(", "(", "Integer", ")", "error", ".", "get", "(", "\"column\"", ")", ")", ".", "intValue", "(", ")", ";", "int", "[", "]", "newInts", "=", "fixLineColumn", "(", "origLine", ",", "origColumn", ")", ";", "int", "newLine", "=", "newInts", "[", "0", "]", ";", "int", "newColumn", "=", "newInts", "[", "1", "]", ";", "SyntaxException", "se", "=", "new", "SyntaxException", "(", "(", "String", ")", "error", ".", "get", "(", "\"error\"", ")", ",", "newLine", ",", "newColumn", ")", ";", "sourceUnit", ".", "addError", "(", "se", ")", ";", "}", "}", "}", "private", "int", "[", "]", "fixLineColumn", "(", "int", "origLine", ",", "int", "origColumn", ")", "{", "if", "(", "locations", ".", "isPopulated", "(", ")", ")", "{", "int", "offset", "=", "locations", ".", "findOffset", "(", "origLine", ",", "origColumn", ")", ";", "if", "(", "offset", ">=", "locations", ".", "getEnd", "(", ")", "-", "1", ")", "{", "return", "locations", ".", "getRowCol", "(", "locations", ".", "getEnd", "(", ")", "-", "1", ")", ";", "}", "}", "return", "new", "int", "[", "]", "{", "origLine", ",", "origColumn", "}", ";", "}", "}", "</s>" ]
6,704
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "java", ".", "io", ".", "Reader", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationFailedException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "Reduction", ";", "public", "class", "CSTParserPlugin", "extends", "AntlrParserPlugin", "{", "private", "ICSTReporter", "cstReporter", ";", "CSTParserPlugin", "(", "ICSTReporter", "cstReporter", ")", "{", "this", ".", "cstReporter", "=", "cstReporter", ";", "}", "public", "Reduction", "parseCST", "(", "final", "SourceUnit", "sourceUnit", ",", "Reader", "reader", ")", "throws", "CompilationFailedException", "{", "Reduction", "reduction", "=", "super", ".", "parseCST", "(", "sourceUnit", ",", "reader", ")", ";", "GroovySourceAST", "cst", "=", "(", "GroovySourceAST", ")", "super", ".", "ast", ";", "if", "(", "cst", "!=", "null", ")", "{", "cstReporter", ".", "generatedCST", "(", "sourceUnit", ".", "getName", "(", ")", ",", "cst", ")", ";", "}", "return", "reduction", ";", "}", "}", "</s>" ]
6,705
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "parser", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "*", ";", "import", "java", ".", "util", ".", "*", ";", "import", "java", ".", "io", ".", "InputStream", ";", "import", "java", ".", "io", ".", "Reader", ";", "import", "antlr", ".", "InputBuffer", ";", "import", "antlr", ".", "LexerSharedInputState", ";", "import", "antlr", ".", "CommonToken", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "GroovyBugError", ";", "import", "antlr", ".", "TokenStreamRecognitionException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Comment", ";", "import", "antlr", ".", "TokenBuffer", ";", "import", "antlr", ".", "TokenStreamException", ";", "import", "antlr", ".", "TokenStreamIOException", ";", "import", "antlr", ".", "ANTLRException", ";", "import", "antlr", ".", "LLkParser", ";", "import", "antlr", ".", "Token", ";", "import", "antlr", ".", "TokenStream", ";", "import", "antlr", ".", "RecognitionException", ";", "import", "antlr", ".", "NoViableAltException", ";", "import", "antlr", ".", "MismatchedTokenException", ";", "import", "antlr", ".", "SemanticException", ";", "import", "antlr", ".", "ParserSharedInputState", ";", "import", "antlr", ".", "collections", ".", "impl", ".", "BitSet", ";", "import", "antlr", ".", "collections", ".", "AST", ";", "import", "java", ".", "util", ".", "Hashtable", ";", "import", "antlr", ".", "ASTFactory", ";", "import", "antlr", ".", "ASTPair", ";", "import", "antlr", ".", "collections", ".", "impl", ".", "ASTArray", ";", "public", "class", "GroovyRecognizer", "extends", "antlr", ".", "LLkParser", "implements", "GroovyTokenTypes", "{", "public", "static", "GroovyRecognizer", "make", "(", "GroovyLexer", "lexer", ")", "{", "GroovyRecognizer", "parser", "=", "new", "GroovyRecognizer", "(", "lexer", ".", "plumb", "(", ")", ")", ";", "parser", ".", "lexer", "=", "lexer", ";", "lexer", ".", "parser", "=", "parser", ";", "parser", ".", "getASTFactory", "(", ")", ".", "setASTNodeClass", "(", "GroovySourceAST", ".", "class", ")", ";", "parser", ".", "warningList", "=", "new", "ArrayList", "(", ")", ";", "parser", ".", "errorList", "=", "new", "ArrayList", "(", ")", ";", "return", "parser", ";", "}", "public", "static", "GroovyRecognizer", "make", "(", "InputStream", "in", ")", "{", "return", "make", "(", "new", "GroovyLexer", "(", "in", ")", ")", ";", "}", "public", "static", "GroovyRecognizer", "make", "(", "Reader", "in", ")", "{", "return", "make", "(", "new", "GroovyLexer", "(", "in", ")", ")", ";", "}", "public", "static", "GroovyRecognizer", "make", "(", "InputBuffer", "in", ")", "{", "return", "make", "(", "new", "GroovyLexer", "(", "in", ")", ")", ";", "}", "public", "static", "GroovyRecognizer", "make", "(", "LexerSharedInputState", "in", ")", "{", "return", "make", "(", "new", "GroovyLexer", "(", "in", ")", ")", ";", "}", "private", "static", "GroovySourceAST", "dummyVariableToforceClassLoaderToFindASTClass", "=", "new", "GroovySourceAST", "(", ")", ";", "List", "warningList", ";", "public", "List", "getWarningList", "(", ")", "{", "return", "warningList", ";", "}", "List", "errorList", ";", "public", "List", "getErrorList", "(", ")", "{", "return", "errorList", ";", "}", "List", "<", "Comment", ">", "comments", "=", "new", "ArrayList", "<", "Comment", ">", "(", ")", ";", "public", "List", "<", "Comment", ">", "getComments", "(", ")", "{", "return", "comments", ";", "}", "GroovyLexer", "lexer", ";", "public", "GroovyLexer", "getLexer", "(", ")", "{", "return", "lexer", ";", "}", "public", "void", "setFilename", "(", "String", "f", ")", "{", "super", ".", "setFilename", "(", "f", ")", ";", "lexer", ".", "setFilename", "(", "f", ")", ";", "}", "private", "SourceBuffer", "sourceBuffer", ";", "public", "void", "setSourceBuffer", "(", "SourceBuffer", "sourceBuffer", ")", "{", "this", ".", "sourceBuffer", "=", "sourceBuffer", ";", "}", "public", "AST", "create", "(", "int", "type", ",", "String", "txt", ",", "AST", "first", ")", "{", "AST", "t", "=", "astFactory", ".", "create", "(", "type", ",", "txt", ")", ";", "if", "(", "t", "!=", "null", "&&", "first", "!=", "null", ")", "{", "t", ".", "initialize", "(", "first", ")", ";", "t", ".", "initialize", "(", "type", ",", "txt", ")", ";", "}", "return", "t", ";", "}", "public", "AST", "create2", "(", "int", "type", ",", "String", "txt", ",", "Token", "first", ",", "Token", "last", ")", "{", "return", "setEndLocationBasedOnThisNode", "(", "create", "(", "type", ",", "txt", ",", "astFactory", ".", "create", "(", "first", ")", ")", ",", "last", ")", ";", "}", "private", "AST", "setEndLocationBasedOnThisNode", "(", "AST", "ast", ",", "Object", "node", ")", "{", "if", "(", "(", "ast", "instanceof", "GroovySourceAST", ")", "&&", "(", "node", "instanceof", "SourceInfo", ")", ")", "{", "SourceInfo", "lastInfo", "=", "(", "SourceInfo", ")", "node", ";", "GroovySourceAST", "groovySourceAst", "=", "(", "GroovySourceAST", ")", "ast", ";", "groovySourceAst", ".", "setColumnLast", "(", "lastInfo", ".", "getColumnLast", "(", ")", ")", ";", "groovySourceAst", ".", "setLineLast", "(", "lastInfo", ".", "getLineLast", "(", ")", ")", ";", "}", "return", "ast", ";", "}", "private", "AST", "attachLast", "(", "AST", "t", ",", "Object", "last", ")", "{", "if", "(", "(", "t", "instanceof", "GroovySourceAST", ")", "&&", "(", "last", "instanceof", "SourceInfo", ")", ")", "{", "SourceInfo", "lastInfo", "=", "(", "SourceInfo", ")", "last", ";", "GroovySourceAST", "node", "=", "(", "GroovySourceAST", ")", "t", ";", "node", ".", "setColumnLast", "(", "lastInfo", ".", "getColumn", "(", ")", ")", ";", "node", ".", "setLineLast", "(", "lastInfo", ".", "getLine", "(", ")", ")", ";", "}", "return", "t", ";", "}", "public", "AST", "create", "(", "int", "type", ",", "String", "txt", ",", "Token", "first", ",", "Token", "last", ")", "{", "return", "attachLast", "(", "create", "(", "type", ",", "txt", ",", "astFactory", ".", "create", "(", "first", ")", ")", ",", "last", ")", ";", "}", "public", "AST", "create", "(", "int", "type", ",", "String", "txt", ",", "AST", "first", ",", "Token", "last", ")", "{", "return", "attachLast", "(", "create", "(", "type", ",", "txt", ",", "first", ")", ",", "last", ")", ";", "}", "public", "AST", "create", "(", "int", "type", ",", "String", "txt", ",", "AST", "first", ",", "AST", "last", ")", "{", "return", "attachLast", "(", "create", "(", "type", ",", "txt", ",", "first", ")", ",", "last", ")", ";", "}", "private", "Stack", "<", "Integer", ">", "commentStartPositions", "=", "new", "Stack", "<", "Integer", ">", "(", ")", ";", "public", "void", "startComment", "(", "int", "line", ",", "int", "column", ")", "{", "commentStartPositions", ".", "push", "(", "(", "line", "<<", "16", ")", "+", "column", ")", ";", "}", "public", "void", "endComment", "(", "int", "type", ",", "int", "line", ",", "int", "column", ",", "String", "text", ")", "{", "int", "lineAndColumn", "=", "commentStartPositions", ".", "pop", "(", ")", ";", "int", "startLine", "=", "lineAndColumn", ">>>", "16", ";", "int", "startColumn", "=", "lineAndColumn", "&", "0xffff", ";", "if", "(", "type", "==", "0", ")", "{", "Comment", "comment", "=", "Comment", ".", "makeSingleLineComment", "(", "startLine", ",", "startColumn", ",", "line", ",", "column", ",", "text", ")", ";", "comments", ".", "add", "(", "comment", ")", ";", "}", "else", "if", "(", "type", "==", "1", ")", "{", "Comment", "comment", "=", "Comment", ".", "makeMultiLineComment", "(", "startLine", ",", "startColumn", ",", "line", ",", "column", ",", "text", ")", ";", "comments", ".", "add", "(", "comment", ")", ";", "}", "}", "public", "Token", "cloneToken", "(", "Token", "t", ")", "{", "CommonToken", "clone", "=", "new", "CommonToken", "(", "t", ".", "getType", "(", ")", ",", "t", ".", "getText", "(", ")", ")", ";", "clone", ".", "setLine", "(", "t", ".", "getLine", "(", ")", ")", ";", "clone", ".", "setColumn", "(", "t", ".", "getColumn", "(", ")", ")", ";", "return", "clone", ";", "}", "public", "static", "boolean", "tracing", "=", "false", ";", "public", "void", "traceIn", "(", "String", "rname", ")", "throws", "TokenStreamException", "{", "if", "(", "!", "GroovyRecognizer", ".", "tracing", ")", "return", ";", "super", ".", "traceIn", "(", "rname", ")", ";", "}", "public", "void", "traceOut", "(", "String", "rname", ")", "throws", "TokenStreamException", "{", "if", "(", "!", "GroovyRecognizer", ".", "tracing", ")", "return", ";", "if", "(", "returnAST", "!=", "null", ")", "rname", "+=", "returnAST", ".", "toStringList", "(", ")", ";", "super", ".", "traceOut", "(", "rname", ")", ";", "}", "public", "void", "requireFailed", "(", "String", "problem", ",", "String", "solution", ")", "throws", "SemanticException", "{", "Token", "lt", "=", "null", ";", "int", "lineNum", "=", "Token", ".", "badToken", ".", "getLine", "(", ")", ",", "colNum", "=", "Token", ".", "badToken", ".", "getColumn", "(", ")", ";", "try", "{", "lt", "=", "LT", "(", "1", ")", ";", "if", "(", "lt", "!=", "null", ")", "{", "lineNum", "=", "lt", ".", "getLine", "(", ")", ";", "colNum", "=", "lt", ".", "getColumn", "(", ")", ";", "}", "}", "catch", "(", "TokenStreamException", "ee", ")", "{", "if", "(", "ee", "instanceof", "TokenStreamRecognitionException", ")", "{", "lineNum", "=", "(", "(", "TokenStreamRecognitionException", ")", "ee", ")", ".", "recog", ".", "getLine", "(", ")", ";", "colNum", "=", "(", "(", "TokenStreamRecognitionException", ")", "ee", ")", ".", "recog", ".", "getColumn", "(", ")", ";", "}", "}", "throw", "new", "SemanticException", "(", "problem", "+", "\"\"", "+", "solution", ",", "getFilename", "(", ")", ",", "lineNum", ",", "colNum", ")", ";", "}", "public", "void", "addWarning", "(", "String", "warning", ",", "String", "solution", ")", "{", "Token", "lt", "=", "null", ";", "try", "{", "lt", "=", "LT", "(", "1", ")", ";", "}", "catch", "(", "TokenStreamException", "ee", ")", "{", "}", "if", "(", "lt", "==", "null", ")", "lt", "=", "Token", ".", "badToken", ";", "Map", "row", "=", "new", "HashMap", "(", ")", ";", "row", ".", "put", "(", "\"warning\"", ",", "warning", ")", ";", "row", ".", "put", "(", "\"solution\"", ",", "solution", ")", ";", "row", ".", "put", "(", "\"filename\"", ",", "getFilename", "(", ")", ")", ";", "row", ".", "put", "(", "\"line\"", ",", "Integer", ".", "valueOf", "(", "lt", ".", "getLine", "(", ")", ")", ")", ";", "row", ".", "put", "(", "\"column\"", ",", "Integer", ".", "valueOf", "(", "lt", ".", "getColumn", "(", ")", ")", ")", ";", "warningList", ".", "add", "(", "row", ")", ";", "}", "public", "void", "reportError", "(", "String", "message", ")", "{", "Token", "lt", "=", "null", ";", "try", "{", "lt", "=", "LT", "(", "1", ")", ";", "}", "catch", "(", "TokenStreamException", "ee", ")", "{", "}", "if", "(", "lt", "==", "null", ")", "lt", "=", "Token", ".", "badToken", ";", "Map", "row", "=", "new", "HashMap", "(", ")", ";", "row", ".", "put", "(", "\"error\"", ",", "message", ")", ";", "row", ".", "put", "(", "\"filename\"", ",", "getFilename", "(", ")", ")", ";", "row", ".", "put", "(", "\"line\"", ",", "new", "Integer", "(", "lt", ".", "getLine", "(", ")", ")", ")", ";", "row", ".", "put", "(", "\"column\"", ",", "new", "Integer", "(", "lt", ".", "getColumn", "(", ")", ")", ")", ";", "errorList", ".", "add", "(", "row", ")", ";", "}", "public", "void", "reportError", "(", "String", "message", ",", "Token", "lt", ")", "{", "Map", "row", "=", "new", "HashMap", "(", ")", ";", "row", ".", "put", "(", "\"error\"", ",", "message", ")", ";", "row", ".", "put", "(", "\"filename\"", ",", "getFilename", "(", ")", ")", ";", "row", ".", "put", "(", "\"line\"", ",", "new", "Integer", "(", "lt", ".", "getLine", "(", ")", ")", ")", ";", "row", ".", "put", "(", "\"column\"", ",", "new", "Integer", "(", "lt", ".", "getColumn", "(", ")", ")", ")", ";", "errorList", ".", "add", "(", "row", ")", ";", "}", "public", "void", "reportError", "(", "String", "message", ",", "AST", "lt", ")", "{", "Map", "row", "=", "new", "HashMap", "(", ")", ";", "row", ".", "put", "(", "\"error\"", ",", "message", ")", ";", "row", ".", "put", "(", "\"filename\"", ",", "getFilename", "(", ")", ")", ";", "row", ".", "put", "(", "\"line\"", ",", "new", "Integer", "(", "lt", ".", "getLine", "(", ")", ")", ")", ";", "row", ".", "put", "(", "\"column\"", ",", "new", "Integer", "(", "lt", ".", "getColumn", "(", ")", ")", ")", ";", "errorList", ".", "add", "(", "row", ")", ";", "}", "public", "void", "reportError", "(", "RecognitionException", "e", ")", "{", "Token", "lt", "=", "null", ";", "try", "{", "lt", "=", "LT", "(", "1", ")", ";", "}", "catch", "(", "TokenStreamException", "ee", ")", "{", "}", "if", "(", "lt", "==", "null", ")", "lt", "=", "Token", ".", "badToken", ";", "Map", "row", "=", "new", "HashMap", "(", ")", ";", "row", ".", "put", "(", "\"error\"", ",", "e", ".", "getMessage", "(", ")", ")", ";", "row", ".", "put", "(", "\"filename\"", ",", "getFilename", "(", ")", ")", ";", "row", ".", "put", "(", "\"line\"", ",", "new", "Integer", "(", "lt", ".", "getLine", "(", ")", ")", ")", ";", "row", ".", "put", "(", "\"column\"", ",", "new", "Integer", "(", "lt", ".", "getColumn", "(", ")", ")", ")", ";", "errorList", ".", "add", "(", "row", ")", ";", "}", "private", "void", "require", "(", "boolean", "z", ",", "String", "problem", ",", "String", "solution", ")", "throws", "SemanticException", "{", "if", "(", "!", "z", ")", "requireFailed", "(", "problem", ",", "solution", ")", ";", "}", "private", "boolean", "matchGenericTypeBrackets", "(", "boolean", "z", ",", "String", "problem", ",", "String", "solution", ")", "throws", "SemanticException", "{", "if", "(", "!", "z", ")", "matchGenericTypeBracketsFailed", "(", "problem", ",", "solution", ")", ";", "return", "z", ";", "}", "public", "void", "matchGenericTypeBracketsFailed", "(", "String", "problem", ",", "String", "solution", ")", "throws", "SemanticException", "{", "Token", "lt", "=", "null", ";", "int", "lineNum", "=", "Token", ".", "badToken", ".", "getLine", "(", ")", ",", "colNum", "=", "Token", ".", "badToken", ".", "getColumn", "(", ")", ";", "try", "{", "lt", "=", "LT", "(", "1", ")", ";", "if", "(", "lt", "!=", "null", ")", "{", "lineNum", "=", "lt", ".", "getLine", "(", ")", ";", "colNum", "=", "lt", ".", "getColumn", "(", ")", ";", "}", "}", "catch", "(", "TokenStreamException", "ee", ")", "{", "if", "(", "ee", "instanceof", "TokenStreamRecognitionException", ")", "{", "lineNum", "=", "(", "(", "TokenStreamRecognitionException", ")", "ee", ")", ".", "recog", ".", "getLine", "(", ")", ";", "colNum", "=", "(", "(", "TokenStreamRecognitionException", ")", "ee", ")", ".", "recog", ".", "getColumn", "(", ")", ";", "}", "}", "throw", "new", "SemanticException", "(", "problem", "+", "\"\"", "+", "solution", ",", "getFilename", "(", ")", ",", "lineNum", ",", "colNum", ")", ";", "}", "private", "boolean", "isUpperCase", "(", "Token", "x", ")", "{", "if", "(", "x", "==", "null", "||", "x", ".", "getType", "(", ")", "!=", "IDENT", ")", "return", "false", ";", "String", "xtext", "=", "x", ".", "getText", "(", ")", ";", "return", "(", "xtext", ".", "length", "(", ")", ">", "0", "&&", "Character", ".", "isUpperCase", "(", "xtext", ".", "charAt", "(", "0", ")", ")", ")", ";", "}", "private", "AST", "currentClass", "=", "null", ";", "private", "boolean", "isConstructorIdent", "(", "Token", "x", ")", "{", "if", "(", "currentClass", "==", "null", ")", "return", "false", ";", "if", "(", "currentClass", ".", "getType", "(", ")", "!=", "IDENT", ")", "return", "false", ";", "String", "cname", "=", "currentClass", ".", "getText", "(", ")", ";", "if", "(", "x", "==", "null", "||", "x", ".", "getType", "(", ")", "!=", "IDENT", ")", "return", "false", ";", "return", "cname", ".", "equals", "(", "x", ".", "getText", "(", ")", ")", ";", "}", "private", "int", "sepToken", "=", "EOF", ";", "private", "boolean", "argListHasLabels", "=", "false", ";", "private", "AST", "lastPathExpression", "=", "null", ";", "private", "final", "int", "LC_STMT", "=", "1", ",", "LC_INIT", "=", "2", ";", "private", "int", "ltCounter", "=", "0", ";", "private", "static", "final", "boolean", "ANTLR_LOOP_EXIT", "=", "false", ";", "protected", "GroovyRecognizer", "(", "TokenBuffer", "tokenBuf", ",", "int", "k", ")", "{", "super", "(", "tokenBuf", ",", "k", ")", ";", "tokenNames", "=", "_tokenNames", ";", "buildTokenTypeASTClassMap", "(", ")", ";", "astFactory", "=", "new", "ASTFactory", "(", "getTokenTypeToASTClassMap", "(", ")", ")", ";", "}", "public", "GroovyRecognizer", "(", "TokenBuffer", "tokenBuf", ")", "{", "this", "(", "tokenBuf", ",", "2", ")", ";", "}", "protected", "GroovyRecognizer", "(", "TokenStream", "lexer", ",", "int", "k", ")", "{", "super", "(", "lexer", ",", "k", ")", ";", "tokenNames", "=", "_tokenNames", ";", "buildTokenTypeASTClassMap", "(", ")", ";", "astFactory", "=", "new", "ASTFactory", "(", "getTokenTypeToASTClassMap", "(", ")", ")", ";", "}", "public", "GroovyRecognizer", "(", "TokenStream", "lexer", ")", "{", "this", "(", "lexer", ",", "2", ")", ";", "}", "public", "GroovyRecognizer", "(", "ParserSharedInputState", "state", ")", "{", "super", "(", "state", ",", "2", ")", ";", "tokenNames", "=", "_tokenNames", ";", "buildTokenTypeASTClassMap", "(", ")", ";", "astFactory", "=", "new", "ASTFactory", "(", "getTokenTypeToASTClassMap", "(", ")", ")", ";", "}", "public", "final", "void", "compilationUnit", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "compilationUnit_AST", "=", "null", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SH_COMMENT", ":", "{", "match", "(", "SH_COMMENT", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_try", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "{", "boolean", "synPredMatched5", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_package", "||", "LA", "(", "1", ")", "==", "AT", ")", "&&", "(", "_tokenSet_0", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m5", "=", "mark", "(", ")", ";", "synPredMatched5", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "annotationsOpt", "(", ")", ";", "match", "(", "LITERAL_package", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched5", "=", "false", ";", "}", "rewind", "(", "_m5", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched5", ")", "{", "packageDefinition", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_1", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_try", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "statement", "(", "EOF", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "{", "_loop9", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", "||", "LA", "(", "1", ")", "==", "NLS", ")", ")", "{", "sep", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_try", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "statement", "(", "sepToken", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop9", ";", "}", "}", "while", "(", "true", ")", ";", "}", "match", "(", "Token", ".", "EOF_TYPE", ")", ";", "compilationUnit_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "compilationUnit_AST", ";", "}", "public", "final", "void", "nls", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "nls_AST", "=", "null", ";", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_3", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "match", "(", "NLS", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_3", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_4", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "nls_AST", ";", "}", "public", "final", "void", "annotationsOpt", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationsOpt_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "if", "(", "(", "_tokenSet_5", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_6", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "annotationsInternal", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_7", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_8", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "annotationsOpt_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "annotationsOpt_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "ANNOTATIONS", ",", "\"ANNOTATIONS\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "annotationsOpt_AST", ")", ")", ";", "currentAST", ".", "root", "=", "annotationsOpt_AST", ";", "currentAST", ".", "child", "=", "annotationsOpt_AST", "!=", "null", "&&", "annotationsOpt_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "annotationsOpt_AST", ".", "getFirstChild", "(", ")", ":", "annotationsOpt_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "annotationsOpt_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "annotationsOpt_AST", ";", "}", "public", "final", "void", "packageDefinition", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "packageDefinition_AST", "=", "null", ";", "AST", "an_AST", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "annotationsOpt", "(", ")", ";", "an_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "LITERAL_package", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "identifier", "(", ")", ";", "id_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "EOF", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "packageDefinition_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "id_AST", "==", "null", ")", "{", "reportError", "(", "\"\"", ",", "LT", "(", "0", ")", ")", ";", "}", "else", "{", "packageDefinition_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "PACKAGE_DEF", ",", "\"package\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "an_AST", ")", ".", "add", "(", "id_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "packageDefinition_AST", ";", "currentAST", ".", "child", "=", "packageDefinition_AST", "!=", "null", "&&", "packageDefinition_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "packageDefinition_AST", ".", "getFirstChild", "(", ")", ":", "packageDefinition_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "packageDefinition_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "packageDefinition_AST", ";", "}", "public", "final", "void", "statement", "(", "int", "prevToken", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "statement_AST", "=", "null", ";", "AST", "pfx_AST", "=", "null", ";", "AST", "es_AST", "=", "null", ";", "AST", "ale_AST", "=", "null", ";", "AST", "ifCbs_AST", "=", "null", ";", "AST", "elseCbs_AST", "=", "null", ";", "AST", "while_sce_AST", "=", "null", ";", "Token", "s", "=", "null", ";", "AST", "s_AST", "=", "null", ";", "AST", "while_cbs_AST", "=", "null", ";", "AST", "m_AST", "=", "null", ";", "AST", "switchSce_AST", "=", "null", ";", "AST", "cg_AST", "=", "null", ";", "AST", "synch_sce_AST", "=", "null", ";", "AST", "synch_cs_AST", "=", "null", ";", "boolean", "sce", "=", "false", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "AST", "casesGroup_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_if", ":", "{", "match", "(", "LITERAL_if", ")", ";", "match", "(", "LPAREN", ")", ";", "assignmentLessExpression", "(", ")", ";", "ale_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "nlsWarn", "(", ")", ";", "compatibleBodyStatement", "(", ")", ";", "ifCbs_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "boolean", "synPredMatched292", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_9", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_10", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m292", "=", "mark", "(", ")", ";", "synPredMatched292", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SEMI", ":", "case", "NLS", ":", "{", "sep", "(", ")", ";", "break", ";", "}", "case", "LITERAL_else", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "match", "(", "LITERAL_else", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched292", "=", "false", ";", "}", "rewind", "(", "_m292", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched292", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SEMI", ":", "case", "NLS", ":", "{", "sep", "(", ")", ";", "break", ";", "}", "case", "LITERAL_else", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "match", "(", "LITERAL_else", ")", ";", "nlsWarn", "(", ")", ";", "compatibleBodyStatement", "(", ")", ";", "elseCbs_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "_tokenSet_11", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_12", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "statement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "LITERAL_if", ",", "\"if\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "ale_AST", ")", ".", "add", "(", "ifCbs_AST", ")", ".", "add", "(", "elseCbs_AST", ")", ")", ";", "currentAST", ".", "root", "=", "statement_AST", ";", "currentAST", ".", "child", "=", "statement_AST", "!=", "null", "&&", "statement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "statement_AST", ".", "getFirstChild", "(", ")", ":", "statement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_for", ":", "{", "forStatement", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_while", ":", "{", "match", "(", "LITERAL_while", ")", ";", "match", "(", "LPAREN", ")", ";", "sce", "=", "strictContextExpression", "(", "false", ")", ";", "while_sce_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "nlsWarn", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SEMI", ":", "{", "s", "=", "LT", "(", "1", ")", ";", "s_AST", "=", "astFactory", ".", "create", "(", "s", ")", ";", "match", "(", "SEMI", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_try", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "compatibleBodyStatement", "(", ")", ";", "while_cbs_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "s_AST", "!=", "null", ")", "statement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_while", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "while_sce_AST", ")", ".", "add", "(", "s_AST", ")", ")", ";", "else", "statement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_while", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "while_sce_AST", ")", ".", "add", "(", "while_cbs_AST", ")", ")", ";", "currentAST", ".", "root", "=", "statement_AST", ";", "currentAST", ".", "child", "=", "statement_AST", "!=", "null", "&&", "statement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "statement_AST", ".", "getFirstChild", "(", ")", ":", "statement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_switch", ":", "{", "match", "(", "LITERAL_switch", ")", ";", "match", "(", "LPAREN", ")", ";", "sce", "=", "strictContextExpression", "(", "false", ")", ";", "switchSce_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "nlsWarn", "(", ")", ";", "match", "(", "LCURLY", ")", ";", "nls", "(", ")", ";", "{", "_loop298", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_default", "||", "LA", "(", "1", ")", "==", "LITERAL_case", ")", ")", "{", "casesGroup", "(", ")", ";", "cg_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "casesGroup_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "null", ")", ".", "add", "(", "casesGroup_AST", ")", ".", "add", "(", "cg_AST", ")", ")", ";", "}", "}", "else", "{", "break", "_loop298", ";", "}", "}", "while", "(", "true", ")", ";", "}", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "statement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_switch", ",", "\"switch\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "switchSce_AST", ")", ".", "add", "(", "casesGroup_AST", ")", ")", ";", "currentAST", ".", "root", "=", "statement_AST", ";", "currentAST", ".", "child", "=", "statement_AST", "!=", "null", "&&", "statement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "statement_AST", ".", "getFirstChild", "(", ")", ":", "statement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_try", ":", "{", "tryBlock", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "{", "branchStatement", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "boolean", "synPredMatched279", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_13", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_14", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m279", "=", "mark", "(", ")", ";", "synPredMatched279", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "genericMethodStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched279", "=", "false", ";", "}", "rewind", "(", "_m279", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched279", ")", "{", "genericMethod", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "boolean", "synPredMatched281", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_13", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_15", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m281", "=", "mark", "(", ")", ";", "synPredMatched281", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "multipleAssignmentDeclarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched281", "=", "false", ";", "}", "rewind", "(", "_m281", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched281", ")", "{", "multipleAssignmentDeclaration", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "boolean", "synPredMatched283", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_16", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_17", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m283", "=", "mark", "(", ")", ";", "synPredMatched283", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "declarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched283", "=", "false", ";", "}", "rewind", "(", "_m283", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched283", ")", "{", "declaration", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "boolean", "synPredMatched285", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "LA", "(", "2", ")", "==", "COLON", ")", ")", ")", "{", "int", "_m285", "=", "mark", "(", ")", ";", "synPredMatched285", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "IDENT", ")", ";", "match", "(", "COLON", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched285", "=", "false", ";", "}", "rewind", "(", "_m285", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched285", ")", "{", "statementLabelPrefix", "(", ")", ";", "pfx_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "statement_AST", "=", "pfx_AST", ";", "currentAST", ".", "root", "=", "statement_AST", ";", "currentAST", ".", "child", "=", "statement_AST", "!=", "null", "&&", "statement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "statement_AST", ".", "getFirstChild", "(", ")", ":", "statement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "{", "boolean", "synPredMatched288", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LCURLY", ")", "&&", "(", "_tokenSet_18", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m288", "=", "mark", "(", ")", ";", "synPredMatched288", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "LCURLY", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched288", "=", "false", ";", "}", "rewind", "(", "_m288", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched288", ")", "{", "openOrClosableBlock", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_19", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "statement", "(", "COLON", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "expressionStatement", "(", "prevToken", ")", ";", "es_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "boolean", "synPredMatched296", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_import", "||", "LA", "(", "1", ")", "==", "AT", ")", "&&", "(", "_tokenSet_21", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m296", "=", "mark", "(", ")", ";", "synPredMatched296", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "annotationsOpt", "(", ")", ";", "match", "(", "LITERAL_import", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched296", "=", "false", ";", "}", "rewind", "(", "_m296", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched296", ")", "{", "importStatement", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "_tokenSet_22", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_23", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "modifiersOpt", "(", ")", ";", "m_AST", "=", "(", "AST", ")", "returnAST", ";", "typeDefinitionInternal", "(", "m_AST", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_synchronized", ")", "&&", "(", "LA", "(", "2", ")", "==", "LPAREN", ")", ")", "{", "match", "(", "LITERAL_synchronized", ")", ";", "match", "(", "LPAREN", ")", ";", "sce", "=", "strictContextExpression", "(", "false", ")", ";", "synch_sce_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "nlsWarn", "(", ")", ";", "compoundStatement", "(", ")", ";", "synch_cs_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "statement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_synchronized", ",", "\"synchronized\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "synch_sce_AST", ")", ".", "add", "(", "synch_cs_AST", ")", ")", ";", "currentAST", ".", "root", "=", "statement_AST", ";", "currentAST", ".", "child", "=", "statement_AST", "!=", "null", "&&", "statement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "statement_AST", ".", "getFirstChild", "(", ")", ":", "statement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "statement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "}", "}", "returnAST", "=", "statement_AST", ";", "}", "public", "final", "void", "sep", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "sep_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SEMI", ":", "{", "match", "(", "SEMI", ")", ";", "{", "_loop545", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_24", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "match", "(", "NLS", ")", ";", "}", "else", "{", "break", "_loop545", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "sepToken", "=", "SEMI", ";", "}", "break", ";", "}", "case", "NLS", ":", "{", "match", "(", "NLS", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "sepToken", "=", "NLS", ";", "}", "{", "_loop549", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", ")", "&&", "(", "_tokenSet_24", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "match", "(", "SEMI", ")", ";", "{", "_loop548", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_24", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "match", "(", "NLS", ")", ";", "}", "else", "{", "break", "_loop548", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "sepToken", "=", "SEMI", ";", "}", "}", "else", "{", "break", "_loop549", ";", "}", "}", "while", "(", "true", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "sep_AST", ";", "}", "public", "final", "void", "snippetUnit", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "snippetUnit_AST", "=", "null", ";", "nls", "(", ")", ";", "blockBody", "(", "EOF", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "snippetUnit_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "snippetUnit_AST", ";", "}", "public", "final", "void", "blockBody", "(", "int", "prevToken", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "blockBody_AST", "=", "null", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_try", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "statement", "(", "prevToken", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "_loop273", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", "||", "LA", "(", "1", ")", "==", "NLS", ")", ")", "{", "sep", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_try", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "statement", "(", "sepToken", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop273", ";", "}", "}", "while", "(", "true", ")", ";", "}", "blockBody_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "blockBody_AST", ";", "}", "public", "final", "void", "identifier", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "identifier_AST", "=", "null", ";", "Token", "i1", "=", "null", ";", "AST", "i1_AST", "=", "null", ";", "Token", "d", "=", "null", ";", "AST", "d_AST", "=", "null", ";", "Token", "i2", "=", "null", ";", "AST", "i2_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "i1", "=", "LT", "(", "1", ")", ";", "i1_AST", "=", "astFactory", ".", "create", "(", "i1", ")", ";", "match", "(", "IDENT", ")", ";", "{", "_loop72", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "DOT", ")", ")", "{", "d", "=", "LT", "(", "1", ")", ";", "d_AST", "=", "astFactory", ".", "create", "(", "d", ")", ";", "match", "(", "DOT", ")", ";", "nls", "(", ")", ";", "i2", "=", "LT", "(", "1", ")", ";", "i2_AST", "=", "astFactory", ".", "create", "(", "i2", ")", ";", "match", "(", "IDENT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "i1_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "DOT", ",", "\".\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "i1_AST", ")", ".", "add", "(", "i2_AST", ")", ")", ";", "}", "}", "else", "{", "break", "_loop72", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "identifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "identifier_AST", "=", "i1_AST", ";", "currentAST", ".", "root", "=", "identifier_AST", ";", "currentAST", ".", "child", "=", "identifier_AST", "!=", "null", "&&", "identifier_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "identifier_AST", ".", "getFirstChild", "(", ")", ":", "identifier_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "identifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "identifier_AST", ";", "}", "public", "final", "void", "importStatement", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "importStatement_AST", "=", "null", ";", "AST", "an_AST", "=", "null", ";", "AST", "is_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "boolean", "isStatic", "=", "false", ";", "annotationsOpt", "(", ")", ";", "an_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "match", "(", "LITERAL_import", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_static", ":", "{", "match", "(", "LITERAL_static", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "isStatic", "=", "true", ";", "}", "break", ";", "}", "case", "IDENT", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "identifierStar", "(", ")", ";", "is_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "importStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "isStatic", ")", "importStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "STATIC_IMPORT", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "an_AST", ")", ".", "add", "(", "is_AST", ")", ")", ";", "else", "importStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "IMPORT", ",", "\"import\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "an_AST", ")", ".", "add", "(", "is_AST", ")", ")", ";", "currentAST", ".", "root", "=", "importStatement_AST", ";", "currentAST", ".", "child", "=", "importStatement_AST", "!=", "null", "&&", "importStatement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "importStatement_AST", ".", "getFirstChild", "(", ")", ":", "importStatement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "importStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "importStatement_AST", ";", "}", "public", "final", "void", "identifierStar", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "identifierStar_AST", "=", "null", ";", "Token", "i1", "=", "null", ";", "AST", "i1_AST", "=", "null", ";", "Token", "d1", "=", "null", ";", "AST", "d1_AST", "=", "null", ";", "Token", "i2", "=", "null", ";", "AST", "i2_AST", "=", "null", ";", "Token", "d2", "=", "null", ";", "AST", "d2_AST", "=", "null", ";", "Token", "s", "=", "null", ";", "AST", "s_AST", "=", "null", ";", "Token", "alias", "=", "null", ";", "AST", "alias_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "i1", "=", "LT", "(", "1", ")", ";", "i1_AST", "=", "astFactory", ".", "create", "(", "i1", ")", ";", "match", "(", "IDENT", ")", ";", "{", "_loop75", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "DOT", ")", "&&", "(", "LA", "(", "2", ")", "==", "IDENT", "||", "LA", "(", "2", ")", "==", "NLS", ")", ")", "{", "d1", "=", "LT", "(", "1", ")", ";", "d1_AST", "=", "astFactory", ".", "create", "(", "d1", ")", ";", "match", "(", "DOT", ")", ";", "nls", "(", ")", ";", "i2", "=", "LT", "(", "1", ")", ";", "i2_AST", "=", "astFactory", ".", "create", "(", "i2", ")", ";", "match", "(", "IDENT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "i1_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "DOT", ",", "\".\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "i1_AST", ")", ".", "add", "(", "i2_AST", ")", ")", ";", "}", "}", "else", "{", "break", "_loop75", ";", "}", "}", "while", "(", "true", ")", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "DOT", ":", "{", "d2", "=", "LT", "(", "1", ")", ";", "d2_AST", "=", "astFactory", ".", "create", "(", "d2", ")", ";", "match", "(", "DOT", ")", ";", "nls", "(", ")", ";", "s", "=", "LT", "(", "1", ")", ";", "s_AST", "=", "astFactory", ".", "create", "(", "s", ")", ";", "match", "(", "STAR", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "i1_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "DOT", ",", "\".\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "i1_AST", ")", ".", "add", "(", "s_AST", ")", ")", ";", "}", "break", ";", "}", "case", "LITERAL_as", ":", "{", "match", "(", "LITERAL_as", ")", ";", "nls", "(", ")", ";", "alias", "=", "LT", "(", "1", ")", ";", "alias_AST", "=", "astFactory", ".", "create", "(", "alias", ")", ";", "match", "(", "IDENT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "i1_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_as", ",", "\"as\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "i1_AST", ")", ".", "add", "(", "alias_AST", ")", ")", ";", "}", "break", ";", "}", "case", "EOF", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_else", ":", "case", "LITERAL_case", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "identifierStar_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "identifierStar_AST", "=", "i1_AST", ";", "currentAST", ".", "root", "=", "identifierStar_AST", ";", "currentAST", ".", "child", "=", "identifierStar_AST", "!=", "null", "&&", "identifierStar_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "identifierStar_AST", ".", "getFirstChild", "(", ")", ":", "identifierStar_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "identifierStar_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "identifierStar_AST", ";", "}", "protected", "final", "void", "typeDefinitionInternal", "(", "AST", "mods", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeDefinitionInternal_AST", "=", "null", ";", "AST", "cd_AST", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "AST", "ed_AST", "=", "null", ";", "AST", "ad_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_class", ":", "{", "classDefinition", "(", "mods", ")", ";", "cd_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeDefinitionInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "typeDefinitionInternal_AST", "=", "cd_AST", ";", "currentAST", ".", "root", "=", "typeDefinitionInternal_AST", ";", "currentAST", ".", "child", "=", "typeDefinitionInternal_AST", "!=", "null", "&&", "typeDefinitionInternal_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeDefinitionInternal_AST", ".", "getFirstChild", "(", ")", ":", "typeDefinitionInternal_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeDefinitionInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_interface", ":", "{", "interfaceDefinition", "(", "mods", ")", ";", "id_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeDefinitionInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "typeDefinitionInternal_AST", "=", "id_AST", ";", "currentAST", ".", "root", "=", "typeDefinitionInternal_AST", ";", "currentAST", ".", "child", "=", "typeDefinitionInternal_AST", "!=", "null", "&&", "typeDefinitionInternal_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeDefinitionInternal_AST", ".", "getFirstChild", "(", ")", ":", "typeDefinitionInternal_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeDefinitionInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_enum", ":", "{", "enumDefinition", "(", "mods", ")", ";", "ed_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeDefinitionInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "typeDefinitionInternal_AST", "=", "ed_AST", ";", "currentAST", ".", "root", "=", "typeDefinitionInternal_AST", ";", "currentAST", ".", "child", "=", "typeDefinitionInternal_AST", "!=", "null", "&&", "typeDefinitionInternal_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeDefinitionInternal_AST", ".", "getFirstChild", "(", ")", ":", "typeDefinitionInternal_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeDefinitionInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "AT", ":", "{", "annotationDefinition", "(", "mods", ")", ";", "ad_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeDefinitionInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "typeDefinitionInternal_AST", "=", "ad_AST", ";", "currentAST", ".", "root", "=", "typeDefinitionInternal_AST", ";", "currentAST", ".", "child", "=", "typeDefinitionInternal_AST", "!=", "null", "&&", "typeDefinitionInternal_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeDefinitionInternal_AST", ".", "getFirstChild", "(", ")", ":", "typeDefinitionInternal_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeDefinitionInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "typeDefinitionInternal_AST", ";", "}", "public", "final", "void", "classDefinition", "(", "AST", "modifiers", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "classDefinition_AST", "=", "null", ";", "AST", "tp_AST", "=", "null", ";", "AST", "sc_AST", "=", "null", ";", "AST", "ic_AST", "=", "null", ";", "AST", "cb_AST", "=", "null", ";", "Token", "first", "=", "cloneToken", "(", "LT", "(", "1", ")", ")", ";", "AST", "prevCurrentClass", "=", "currentClass", ";", "if", "(", "modifiers", "!=", "null", ")", "{", "first", ".", "setLine", "(", "modifiers", ".", "getLine", "(", ")", ")", ";", "first", ".", "setColumn", "(", "modifiers", ".", "getColumn", "(", ")", ")", ";", "}", "match", "(", "LITERAL_class", ")", ";", "AST", "tmp29_AST", "=", "null", ";", "tmp29_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "IDENT", ")", ";", "nls", "(", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "currentClass", "=", "tmp29_AST", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "typeParameters", "(", ")", ";", "tp_AST", "=", "(", "AST", ")", "returnAST", ";", "nls", "(", ")", ";", "break", ";", "}", "case", "LITERAL_extends", ":", "case", "LCURLY", ":", "case", "LITERAL_implements", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "superClassClause", "(", ")", ";", "sc_AST", "=", "(", "AST", ")", "returnAST", ";", "implementsClause", "(", ")", ";", "ic_AST", "=", "(", "AST", ")", "returnAST", ";", "classBlock", "(", ")", ";", "cb_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classDefinition_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classDefinition_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "7", ")", ")", ".", "add", "(", "create", "(", "CLASS_DEF", ",", "\"CLASS_DEF\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "modifiers", ")", ".", "add", "(", "tmp29_AST", ")", ".", "add", "(", "tp_AST", ")", ".", "add", "(", "sc_AST", ")", ".", "add", "(", "ic_AST", ")", ".", "add", "(", "cb_AST", ")", ")", ";", "currentAST", ".", "root", "=", "classDefinition_AST", ";", "currentAST", ".", "child", "=", "classDefinition_AST", "!=", "null", "&&", "classDefinition_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classDefinition_AST", ".", "getFirstChild", "(", ")", ":", "classDefinition_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "currentClass", "=", "prevCurrentClass", ";", "}", "returnAST", "=", "classDefinition_AST", ";", "}", "public", "final", "void", "interfaceDefinition", "(", "AST", "modifiers", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "interfaceDefinition_AST", "=", "null", ";", "AST", "tp_AST", "=", "null", ";", "AST", "ie_AST", "=", "null", ";", "AST", "ib_AST", "=", "null", ";", "Token", "first", "=", "cloneToken", "(", "LT", "(", "1", ")", ")", ";", "if", "(", "modifiers", "!=", "null", ")", "{", "first", ".", "setLine", "(", "modifiers", ".", "getLine", "(", ")", ")", ";", "first", ".", "setColumn", "(", "modifiers", ".", "getColumn", "(", ")", ")", ";", "}", "match", "(", "LITERAL_interface", ")", ";", "AST", "tmp31_AST", "=", "null", ";", "tmp31_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "IDENT", ")", ";", "nls", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "typeParameters", "(", ")", ";", "tp_AST", "=", "(", "AST", ")", "returnAST", ";", "nls", "(", ")", ";", "break", ";", "}", "case", "LITERAL_extends", ":", "case", "LCURLY", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "interfaceExtends", "(", ")", ";", "ie_AST", "=", "(", "AST", ")", "returnAST", ";", "interfaceBlock", "(", ")", ";", "ib_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "interfaceDefinition_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "interfaceDefinition_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "6", ")", ")", ".", "add", "(", "create", "(", "INTERFACE_DEF", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "modifiers", ")", ".", "add", "(", "tmp31_AST", ")", ".", "add", "(", "tp_AST", ")", ".", "add", "(", "ie_AST", ")", ".", "add", "(", "ib_AST", ")", ")", ";", "currentAST", ".", "root", "=", "interfaceDefinition_AST", ";", "currentAST", ".", "child", "=", "interfaceDefinition_AST", "!=", "null", "&&", "interfaceDefinition_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "interfaceDefinition_AST", ".", "getFirstChild", "(", ")", ":", "interfaceDefinition_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "interfaceDefinition_AST", ";", "}", "public", "final", "void", "enumDefinition", "(", "AST", "modifiers", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "enumDefinition_AST", "=", "null", ";", "AST", "ic_AST", "=", "null", ";", "AST", "eb_AST", "=", "null", ";", "Token", "first", "=", "cloneToken", "(", "LT", "(", "1", ")", ")", ";", "AST", "prevCurrentClass", "=", "currentClass", ";", "if", "(", "modifiers", "!=", "null", ")", "{", "first", ".", "setLine", "(", "modifiers", ".", "getLine", "(", ")", ")", ";", "first", ".", "setColumn", "(", "modifiers", ".", "getColumn", "(", ")", ")", ";", "}", "match", "(", "LITERAL_enum", ")", ";", "AST", "tmp33_AST", "=", "null", ";", "tmp33_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "IDENT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "currentClass", "=", "tmp33_AST", ";", "}", "nls", "(", ")", ";", "implementsClause", "(", ")", ";", "ic_AST", "=", "(", "AST", ")", "returnAST", ";", "nls", "(", ")", ";", "enumBlock", "(", ")", ";", "eb_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "enumDefinition_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "enumDefinition_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "5", ")", ")", ".", "add", "(", "create", "(", "ENUM_DEF", ",", "\"ENUM_DEF\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "modifiers", ")", ".", "add", "(", "tmp33_AST", ")", ".", "add", "(", "ic_AST", ")", ".", "add", "(", "eb_AST", ")", ")", ";", "currentAST", ".", "root", "=", "enumDefinition_AST", ";", "currentAST", ".", "child", "=", "enumDefinition_AST", "!=", "null", "&&", "enumDefinition_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "enumDefinition_AST", ".", "getFirstChild", "(", ")", ":", "enumDefinition_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "currentClass", "=", "prevCurrentClass", ";", "}", "returnAST", "=", "enumDefinition_AST", ";", "}", "public", "final", "void", "annotationDefinition", "(", "AST", "modifiers", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationDefinition_AST", "=", "null", ";", "AST", "ab_AST", "=", "null", ";", "Token", "first", "=", "cloneToken", "(", "LT", "(", "1", ")", ")", ";", "if", "(", "modifiers", "!=", "null", ")", "{", "first", ".", "setLine", "(", "modifiers", ".", "getLine", "(", ")", ")", ";", "first", ".", "setColumn", "(", "modifiers", ".", "getColumn", "(", ")", ")", ";", "}", "AST", "tmp34_AST", "=", "null", ";", "tmp34_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "AT", ")", ";", "match", "(", "LITERAL_interface", ")", ";", "AST", "tmp36_AST", "=", "null", ";", "tmp36_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "IDENT", ")", ";", "annotationBlock", "(", ")", ";", "ab_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "annotationDefinition_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "annotationDefinition_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "ANNOTATION_DEF", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "modifiers", ")", ".", "add", "(", "tmp36_AST", ")", ".", "add", "(", "ab_AST", ")", ")", ";", "currentAST", ".", "root", "=", "annotationDefinition_AST", ";", "currentAST", ".", "child", "=", "annotationDefinition_AST", "!=", "null", "&&", "annotationDefinition_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "annotationDefinition_AST", ".", "getFirstChild", "(", ")", ":", "annotationDefinition_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "annotationDefinition_AST", ";", "}", "public", "final", "void", "declaration", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "declaration_AST", "=", "null", ";", "AST", "m_AST", "=", "null", ";", "AST", "t_AST", "=", "null", ";", "AST", "v_AST", "=", "null", ";", "AST", "t2_AST", "=", "null", ";", "AST", "v2_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "AT", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "modifiers", "(", ")", ";", "m_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "if", "(", "(", "_tokenSet_25", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_26", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "typeSpec", "(", "false", ")", ";", "t_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", "||", "LA", "(", "1", ")", "==", "STRING_LITERAL", ")", "&&", "(", "_tokenSet_27", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "variableDefinitions", "(", "m_AST", ",", "t_AST", ")", ";", "v_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "declaration_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "declaration_AST", "=", "v_AST", ";", "currentAST", ".", "root", "=", "declaration_AST", ";", "currentAST", ".", "child", "=", "declaration_AST", "!=", "null", "&&", "declaration_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "declaration_AST", ".", "getFirstChild", "(", ")", ":", "declaration_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "case", "IDENT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "typeSpec", "(", "false", ")", ";", "t2_AST", "=", "(", "AST", ")", "returnAST", ";", "variableDefinitions", "(", "null", ",", "t2_AST", ")", ";", "v2_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "declaration_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "declaration_AST", "=", "v2_AST", ";", "currentAST", ".", "root", "=", "declaration_AST", ";", "currentAST", ".", "child", "=", "declaration_AST", "!=", "null", "&&", "declaration_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "declaration_AST", ".", "getFirstChild", "(", ")", ":", "declaration_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "declaration_AST", ";", "}", "public", "final", "void", "modifiers", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "modifiers_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "modifiersInternal", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "modifiers_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "modifiers_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "MODIFIERS", ",", "\"MODIFIERS\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "modifiers_AST", ")", ")", ";", "currentAST", ".", "root", "=", "modifiers_AST", ";", "currentAST", ".", "child", "=", "modifiers_AST", "!=", "null", "&&", "modifiers_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "modifiers_AST", ".", "getFirstChild", "(", ")", ":", "modifiers_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "modifiers_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "modifiers_AST", ";", "}", "public", "final", "void", "typeSpec", "(", "boolean", "addImagNode", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeSpec_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "classTypeSpec", "(", "addImagNode", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "typeSpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "builtInTypeSpec", "(", "addImagNode", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "typeSpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "typeSpec_AST", ";", "}", "public", "final", "void", "variableDefinitions", "(", "AST", "mods", ",", "AST", "t", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "variableDefinitions_AST", "=", "null", ";", "Token", "id", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "Token", "qid", "=", "null", ";", "AST", "qid_AST", "=", "null", ";", "AST", "param_AST", "=", "null", ";", "AST", "tc_AST", "=", "null", ";", "AST", "mb_AST", "=", "null", ";", "Token", "first", "=", "cloneToken", "(", "LT", "(", "1", ")", ")", ";", "if", "(", "mods", "!=", "null", ")", "{", "first", ".", "setLine", "(", "mods", ".", "getLine", "(", ")", ")", ";", "first", ".", "setColumn", "(", "mods", ".", "getColumn", "(", ")", ")", ";", "}", "else", "if", "(", "t", "!=", "null", ")", "{", "first", ".", "setLine", "(", "t", ".", "getLine", "(", ")", ")", ";", "first", ".", "setColumn", "(", "t", ".", "getColumn", "(", ")", ")", ";", "}", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "_tokenSet_28", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "listOfVariables", "(", "mods", ",", "t", ",", "first", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "variableDefinitions_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", "||", "LA", "(", "1", ")", "==", "STRING_LITERAL", ")", "&&", "(", "LA", "(", "2", ")", "==", "LPAREN", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "id", "=", "LT", "(", "1", ")", ";", "id_AST", "=", "astFactory", ".", "create", "(", "id", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "id_AST", ")", ";", "match", "(", "IDENT", ")", ";", "break", ";", "}", "case", "STRING_LITERAL", ":", "{", "qid", "=", "LT", "(", "1", ")", ";", "qid_AST", "=", "astFactory", ".", "create", "(", "qid", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "qid_AST", ")", ";", "match", "(", "STRING_LITERAL", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "qid_AST", ".", "setType", "(", "IDENT", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "match", "(", "LPAREN", ")", ";", "parameterDeclarationList", "(", ")", ";", "param_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "{", "boolean", "synPredMatched231", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_throws", "||", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_29", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m231", "=", "mark", "(", ")", ";", "synPredMatched231", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "nls", "(", ")", ";", "match", "(", "LITERAL_throws", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched231", "=", "false", ";", "}", "rewind", "(", "_m231", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched231", ")", "{", "throwsClause", "(", ")", ";", "tc_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "_tokenSet_30", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_12", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "{", "boolean", "synPredMatched234", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LCURLY", "||", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_31", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m234", "=", "mark", "(", ")", ";", "synPredMatched234", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "nls", "(", ")", ";", "match", "(", "LCURLY", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched234", "=", "false", ";", "}", "rewind", "(", "_m234", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched234", ")", "{", "{", "nlsWarn", "(", ")", ";", "openBlock", "(", ")", ";", "mb_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "}", "else", "if", "(", "(", "_tokenSet_11", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_12", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "variableDefinitions_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "qid_AST", "!=", "null", ")", "id_AST", "=", "qid_AST", ";", "variableDefinitions_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "7", ")", ")", ".", "add", "(", "create", "(", "METHOD_DEF", ",", "\"METHOD_DEF\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "mods", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "t", ")", ")", ")", ".", "add", "(", "id_AST", ")", ".", "add", "(", "param_AST", ")", ".", "add", "(", "tc_AST", ")", ".", "add", "(", "mb_AST", ")", ")", ";", "currentAST", ".", "root", "=", "variableDefinitions_AST", ";", "currentAST", ".", "child", "=", "variableDefinitions_AST", "!=", "null", "&&", "variableDefinitions_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "variableDefinitions_AST", ".", "getFirstChild", "(", ")", ":", "variableDefinitions_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "variableDefinitions_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "returnAST", "=", "variableDefinitions_AST", ";", "}", "public", "final", "void", "genericMethod", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "genericMethod_AST", "=", "null", ";", "AST", "m_AST", "=", "null", ";", "AST", "p_AST", "=", "null", ";", "AST", "t_AST", "=", "null", ";", "AST", "v_AST", "=", "null", ";", "modifiers", "(", ")", ";", "m_AST", "=", "(", "AST", ")", "returnAST", ";", "typeParameters", "(", ")", ";", "p_AST", "=", "(", "AST", ")", "returnAST", ";", "typeSpec", "(", "false", ")", ";", "t_AST", "=", "(", "AST", ")", "returnAST", ";", "variableDefinitions", "(", "m_AST", ",", "t_AST", ")", ";", "v_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "genericMethod_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "genericMethod_AST", "=", "v_AST", ";", "AST", "old", "=", "v_AST", ".", "getFirstChild", "(", ")", ";", "genericMethod_AST", ".", "setFirstChild", "(", "p_AST", ")", ";", "p_AST", ".", "setNextSibling", "(", "old", ")", ";", "currentAST", ".", "root", "=", "genericMethod_AST", ";", "currentAST", ".", "child", "=", "genericMethod_AST", "!=", "null", "&&", "genericMethod_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "genericMethod_AST", ".", "getFirstChild", "(", ")", ":", "genericMethod_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "genericMethod_AST", ";", "}", "public", "final", "void", "typeParameters", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeParameters_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "int", "currentLtLevel", "=", "0", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "currentLtLevel", "=", "ltCounter", ";", "}", "match", "(", "LT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "ltCounter", "++", ";", "}", "nls", "(", ")", ";", "typeParameter", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop110", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "typeParameter", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop110", ";", "}", "}", "while", "(", "true", ")", ";", "}", "nls", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "GT", ":", "case", "SR", ":", "case", "BSR", ":", "{", "typeArgumentsOrParametersEnd", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "IDENT", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LCURLY", ":", "case", "LITERAL_implements", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "!", "(", "matchGenericTypeBrackets", "(", "(", "(", "currentLtLevel", "!=", "0", ")", "||", "ltCounter", "==", "currentLtLevel", ")", ",", "\"\"", ",", "\"\"", ")", ")", ")", "throw", "new", "SemanticException", "(", "\"\"", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeParameters_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "typeParameters_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE_PARAMETERS", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "typeParameters_AST", ")", ")", ";", "currentAST", ".", "root", "=", "typeParameters_AST", ";", "currentAST", ".", "child", "=", "typeParameters_AST", "!=", "null", "&&", "typeParameters_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeParameters_AST", ".", "getFirstChild", "(", ")", ":", "typeParameters_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeParameters_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "typeParameters_AST", ";", "}", "public", "final", "void", "singleDeclarationNoInit", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "singleDeclarationNoInit_AST", "=", "null", ";", "AST", "m_AST", "=", "null", ";", "AST", "t_AST", "=", "null", ";", "AST", "v_AST", "=", "null", ";", "AST", "t2_AST", "=", "null", ";", "AST", "v2_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "AT", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "modifiers", "(", ")", ";", "m_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "if", "(", "(", "_tokenSet_25", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_32", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "typeSpec", "(", "false", ")", ";", "t_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "_tokenSet_33", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "singleVariable", "(", "m_AST", ",", "t_AST", ")", ";", "v_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "singleDeclarationNoInit_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "singleDeclarationNoInit_AST", "=", "v_AST", ";", "currentAST", ".", "root", "=", "singleDeclarationNoInit_AST", ";", "currentAST", ".", "child", "=", "singleDeclarationNoInit_AST", "!=", "null", "&&", "singleDeclarationNoInit_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "singleDeclarationNoInit_AST", ".", "getFirstChild", "(", ")", ":", "singleDeclarationNoInit_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "case", "IDENT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "typeSpec", "(", "false", ")", ";", "t2_AST", "=", "(", "AST", ")", "returnAST", ";", "singleVariable", "(", "null", ",", "t2_AST", ")", ";", "v2_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "singleDeclarationNoInit_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "singleDeclarationNoInit_AST", "=", "v2_AST", ";", "currentAST", ".", "root", "=", "singleDeclarationNoInit_AST", ";", "currentAST", ".", "child", "=", "singleDeclarationNoInit_AST", "!=", "null", "&&", "singleDeclarationNoInit_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "singleDeclarationNoInit_AST", ".", "getFirstChild", "(", ")", ":", "singleDeclarationNoInit_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "singleDeclarationNoInit_AST", ";", "}", "public", "final", "void", "singleVariable", "(", "AST", "mods", ",", "AST", "t", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "singleVariable_AST", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "variableName", "(", ")", ";", "id_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "singleVariable_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "singleVariable_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "VARIABLE_DEF", ",", "\"VARIABLE_DEF\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "mods", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "t", ")", ")", ")", ".", "add", "(", "id_AST", ")", ")", ";", "currentAST", ".", "root", "=", "singleVariable_AST", ";", "currentAST", ".", "child", "=", "singleVariable_AST", "!=", "null", "&&", "singleVariable_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "singleVariable_AST", ".", "getFirstChild", "(", ")", ":", "singleVariable_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "singleVariable_AST", ";", "}", "public", "final", "void", "singleDeclaration", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "singleDeclaration_AST", "=", "null", ";", "AST", "sd_AST", "=", "null", ";", "singleDeclarationNoInit", "(", ")", ";", "sd_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "singleDeclaration_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "singleDeclaration_AST", "=", "sd_AST", ";", "currentAST", ".", "root", "=", "singleDeclaration_AST", ";", "currentAST", ".", "child", "=", "singleDeclaration_AST", "!=", "null", "&&", "singleDeclaration_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "singleDeclaration_AST", ".", "getFirstChild", "(", ")", ":", "singleDeclaration_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "ASSIGN", ":", "{", "varInitializer", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "RBRACK", ":", "case", "COMMA", ":", "case", "RPAREN", ":", "case", "SEMI", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "singleDeclaration_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "singleDeclaration_AST", ";", "}", "public", "final", "void", "varInitializer", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "varInitializer_AST", "=", "null", ";", "AST", "tmp41_AST", "=", "null", ";", "tmp41_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp41_AST", ")", ";", "match", "(", "ASSIGN", ")", ";", "nls", "(", ")", ";", "expression", "(", "LC_INIT", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "varInitializer_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "varInitializer_AST", ";", "}", "public", "final", "void", "declarationStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "declarationStart_AST", "=", "null", ";", "{", "int", "_cnt30", "=", "0", ";", "_loop30", ":", "do", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_def", ":", "{", "{", "match", "(", "LITERAL_def", ")", ";", "nls", "(", ")", ";", "}", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "modifier", "(", ")", ";", "nls", "(", ")", ";", "break", ";", "}", "case", "AT", ":", "{", "annotation", "(", ")", ";", "nls", "(", ")", ";", "break", ";", "}", "default", ":", "if", "(", "(", "_tokenSet_25", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_34", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "_tokenSet_35", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "upperCaseIdent", "(", ")", ";", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "LITERAL_void", "&&", "LA", "(", "1", ")", "<=", "LITERAL_double", ")", ")", ")", "{", "builtInType", "(", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "LA", "(", "2", ")", "==", "DOT", ")", ")", "{", "qualifiedTypeName", "(", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "typeArguments", "(", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "_loop29", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LBRACK", ")", ")", "{", "AST", "tmp43_AST", "=", "null", ";", "tmp43_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "LBRACK", ")", ";", "balancedTokens", "(", ")", ";", "AST", "tmp44_AST", "=", "null", ";", "tmp44_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "RBRACK", ")", ";", "}", "else", "{", "break", "_loop29", ";", "}", "}", "while", "(", "true", ")", ";", "}", "}", "else", "{", "if", "(", "_cnt30", ">=", "1", ")", "{", "break", "_loop30", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "_cnt30", "++", ";", "}", "while", "(", "true", ")", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "AST", "tmp45_AST", "=", "null", ";", "tmp45_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "IDENT", ")", ";", "break", ";", "}", "case", "STRING_LITERAL", ":", "{", "AST", "tmp46_AST", "=", "null", ";", "tmp46_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "STRING_LITERAL", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "returnAST", "=", "declarationStart_AST", ";", "}", "public", "final", "void", "modifier", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "modifier_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_private", ":", "{", "AST", "tmp47_AST", "=", "null", ";", "tmp47_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp47_AST", ")", ";", "match", "(", "LITERAL_private", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_public", ":", "{", "AST", "tmp48_AST", "=", "null", ";", "tmp48_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp48_AST", ")", ";", "match", "(", "LITERAL_public", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_protected", ":", "{", "AST", "tmp49_AST", "=", "null", ";", "tmp49_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp49_AST", ")", ";", "match", "(", "LITERAL_protected", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_static", ":", "{", "AST", "tmp50_AST", "=", "null", ";", "tmp50_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp50_AST", ")", ";", "match", "(", "LITERAL_static", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_transient", ":", "{", "AST", "tmp51_AST", "=", "null", ";", "tmp51_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp51_AST", ")", ";", "match", "(", "LITERAL_transient", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "FINAL", ":", "{", "AST", "tmp52_AST", "=", "null", ";", "tmp52_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp52_AST", ")", ";", "match", "(", "FINAL", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "ABSTRACT", ":", "{", "AST", "tmp53_AST", "=", "null", ";", "tmp53_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp53_AST", ")", ";", "match", "(", "ABSTRACT", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_native", ":", "{", "AST", "tmp54_AST", "=", "null", ";", "tmp54_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp54_AST", ")", ";", "match", "(", "LITERAL_native", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_threadsafe", ":", "{", "AST", "tmp55_AST", "=", "null", ";", "tmp55_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp55_AST", ")", ";", "match", "(", "LITERAL_threadsafe", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_synchronized", ":", "{", "AST", "tmp56_AST", "=", "null", ";", "tmp56_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp56_AST", ")", ";", "match", "(", "LITERAL_synchronized", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_volatile", ":", "{", "AST", "tmp57_AST", "=", "null", ";", "tmp57_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp57_AST", ")", ";", "match", "(", "LITERAL_volatile", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "STRICTFP", ":", "{", "AST", "tmp58_AST", "=", "null", ";", "tmp58_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp58_AST", ")", ";", "match", "(", "STRICTFP", ")", ";", "modifier_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "modifier_AST", ";", "}", "public", "final", "void", "annotation", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotation_AST", "=", "null", ";", "AST", "i_AST", "=", "null", ";", "AST", "args_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "AT", ")", ";", "identifier", "(", ")", ";", "i_AST", "=", "(", "AST", ")", "returnAST", ";", "nls", "(", ")", ";", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LPAREN", ")", "&&", "(", "_tokenSet_36", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "match", "(", "LPAREN", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "annotationArguments", "(", ")", ";", "args_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "RPAREN", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "match", "(", "RPAREN", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_37", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_38", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "annotation_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "annotation_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "ANNOTATION", ",", "\"ANNOTATION\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "i_AST", ")", ".", "add", "(", "args_AST", ")", ")", ";", "currentAST", ".", "root", "=", "annotation_AST", ";", "currentAST", ".", "child", "=", "annotation_AST", "!=", "null", "&&", "annotation_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "annotation_AST", ".", "getFirstChild", "(", ")", ":", "annotation_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "annotation_AST", ";", "}", "public", "final", "void", "upperCaseIdent", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "upperCaseIdent_AST", "=", "null", ";", "if", "(", "!", "(", "isUpperCase", "(", "LT", "(", "1", ")", ")", ")", ")", "throw", "new", "SemanticException", "(", "\"\"", ")", ";", "AST", "tmp62_AST", "=", "null", ";", "tmp62_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp62_AST", ")", ";", "match", "(", "IDENT", ")", ";", "upperCaseIdent_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "upperCaseIdent_AST", ";", "}", "public", "final", "void", "builtInType", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "builtInType_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_void", ":", "{", "AST", "tmp63_AST", "=", "null", ";", "tmp63_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp63_AST", ")", ";", "match", "(", "LITERAL_void", ")", ";", "builtInType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_boolean", ":", "{", "AST", "tmp64_AST", "=", "null", ";", "tmp64_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp64_AST", ")", ";", "match", "(", "LITERAL_boolean", ")", ";", "builtInType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_byte", ":", "{", "AST", "tmp65_AST", "=", "null", ";", "tmp65_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp65_AST", ")", ";", "match", "(", "LITERAL_byte", ")", ";", "builtInType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_char", ":", "{", "AST", "tmp66_AST", "=", "null", ";", "tmp66_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp66_AST", ")", ";", "match", "(", "LITERAL_char", ")", ";", "builtInType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_short", ":", "{", "AST", "tmp67_AST", "=", "null", ";", "tmp67_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp67_AST", ")", ";", "match", "(", "LITERAL_short", ")", ";", "builtInType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_int", ":", "{", "AST", "tmp68_AST", "=", "null", ";", "tmp68_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp68_AST", ")", ";", "match", "(", "LITERAL_int", ")", ";", "builtInType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_float", ":", "{", "AST", "tmp69_AST", "=", "null", ";", "tmp69_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp69_AST", ")", ";", "match", "(", "LITERAL_float", ")", ";", "builtInType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_long", ":", "{", "AST", "tmp70_AST", "=", "null", ";", "tmp70_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp70_AST", ")", ";", "match", "(", "LITERAL_long", ")", ";", "builtInType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_double", ":", "{", "AST", "tmp71_AST", "=", "null", ";", "tmp71_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp71_AST", ")", ";", "match", "(", "LITERAL_double", ")", ";", "builtInType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "builtInType_AST", ";", "}", "public", "final", "void", "qualifiedTypeName", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "qualifiedTypeName_AST", "=", "null", ";", "AST", "tmp72_AST", "=", "null", ";", "tmp72_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "IDENT", ")", ";", "AST", "tmp73_AST", "=", "null", ";", "tmp73_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "DOT", ")", ";", "{", "_loop37", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "LA", "(", "2", ")", "==", "DOT", ")", ")", "{", "AST", "tmp74_AST", "=", "null", ";", "tmp74_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "IDENT", ")", ";", "AST", "tmp75_AST", "=", "null", ";", "tmp75_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "DOT", ")", ";", "}", "else", "{", "break", "_loop37", ";", "}", "}", "while", "(", "true", ")", ";", "}", "upperCaseIdent", "(", ")", ";", "returnAST", "=", "qualifiedTypeName_AST", ";", "}", "public", "final", "void", "typeArguments", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeArguments_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "int", "currentLtLevel", "=", "0", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "currentLtLevel", "=", "ltCounter", ";", "}", "match", "(", "LT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "ltCounter", "++", ";", "}", "nls", "(", ")", ";", "typeArgument", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop58", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", "&&", "(", "_tokenSet_39", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "&&", "(", "inputState", ".", "guessing", "!=", "0", "||", "ltCounter", "==", "currentLtLevel", "+", "1", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "typeArgument", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop58", ";", "}", "}", "while", "(", "true", ")", ";", "}", "nls", "(", ")", ";", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "GT", "&&", "LA", "(", "1", ")", "<=", "BSR", ")", ")", "&&", "(", "_tokenSet_40", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "typeArgumentsOrParametersEnd", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_40", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_4", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "!", "(", "matchGenericTypeBrackets", "(", "(", "(", "currentLtLevel", "!=", "0", ")", "||", "ltCounter", "==", "currentLtLevel", ")", ",", "\"\"", ",", "\"\"", ")", ")", ")", "throw", "new", "SemanticException", "(", "\"\"", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeArguments_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "typeArguments_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE_ARGUMENTS", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "typeArguments_AST", ")", ")", ";", "currentAST", ".", "root", "=", "typeArguments_AST", ";", "currentAST", ".", "child", "=", "typeArguments_AST", "!=", "null", "&&", "typeArguments_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeArguments_AST", ".", "getFirstChild", "(", ")", ":", "typeArguments_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeArguments_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "typeArguments_AST", ";", "}", "public", "final", "void", "balancedTokens", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "balancedTokens_AST", "=", "null", ";", "{", "_loop542", ":", "do", "{", "if", "(", "(", "_tokenSet_41", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "balancedBrackets", "(", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_42", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "match", "(", "_tokenSet_42", ")", ";", "}", "}", "else", "{", "break", "_loop542", ";", "}", "}", "while", "(", "true", ")", ";", "}", "returnAST", "=", "balancedTokens_AST", ";", "}", "public", "final", "void", "genericMethodStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "genericMethodStart_AST", "=", "null", ";", "{", "int", "_cnt34", "=", "0", ";", "_loop34", ":", "do", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_def", ":", "{", "match", "(", "LITERAL_def", ")", ";", "nls", "(", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "modifier", "(", ")", ";", "nls", "(", ")", ";", "break", ";", "}", "case", "AT", ":", "{", "annotation", "(", ")", ";", "nls", "(", ")", ";", "break", ";", "}", "default", ":", "{", "if", "(", "_cnt34", ">=", "1", ")", "{", "break", "_loop34", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "_cnt34", "++", ";", "}", "while", "(", "true", ")", ";", "}", "AST", "tmp80_AST", "=", "null", ";", "tmp80_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "LT", ")", ";", "returnAST", "=", "genericMethodStart_AST", ";", "}", "public", "final", "void", "constructorStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "constructorStart_AST", "=", "null", ";", "Token", "id", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "modifiersOpt", "(", ")", ";", "id", "=", "LT", "(", "1", ")", ";", "id_AST", "=", "astFactory", ".", "create", "(", "id", ")", ";", "match", "(", "IDENT", ")", ";", "if", "(", "!", "(", "isConstructorIdent", "(", "id", ")", ")", ")", "throw", "new", "SemanticException", "(", "\"\"", ")", ";", "nls", "(", ")", ";", "match", "(", "LPAREN", ")", ";", "returnAST", "=", "constructorStart_AST", ";", "}", "public", "final", "void", "modifiersOpt", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "modifiersOpt_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "if", "(", "(", "_tokenSet_13", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_43", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "modifiersInternal", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_44", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_45", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "modifiersOpt_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "modifiersOpt_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "MODIFIERS", ",", "\"MODIFIERS\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "modifiersOpt_AST", ")", ")", ";", "currentAST", ".", "root", "=", "modifiersOpt_AST", ";", "currentAST", ".", "child", "=", "modifiersOpt_AST", "!=", "null", "&&", "modifiersOpt_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "modifiersOpt_AST", ".", "getFirstChild", "(", ")", ":", "modifiersOpt_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "modifiersOpt_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "modifiersOpt_AST", ";", "}", "public", "final", "void", "typeDeclarationStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeDeclarationStart_AST", "=", "null", ";", "modifiersOpt", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_class", ":", "{", "match", "(", "LITERAL_class", ")", ";", "break", ";", "}", "case", "LITERAL_interface", ":", "{", "match", "(", "LITERAL_interface", ")", ";", "break", ";", "}", "case", "LITERAL_enum", ":", "{", "match", "(", "LITERAL_enum", ")", ";", "break", ";", "}", "case", "AT", ":", "{", "AST", "tmp85_AST", "=", "null", ";", "tmp85_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "AT", ")", ";", "match", "(", "LITERAL_interface", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "returnAST", "=", "typeDeclarationStart_AST", ";", "}", "public", "final", "void", "classTypeSpec", "(", "boolean", "addImagNode", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "classTypeSpec_AST", "=", "null", ";", "AST", "ct_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "classOrInterfaceType", "(", "false", ")", ";", "ct_AST", "=", "(", "AST", ")", "returnAST", ";", "declaratorBrackets", "(", "ct_AST", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classTypeSpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "addImagNode", ")", "{", "classTypeSpec_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "classTypeSpec_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "classTypeSpec_AST", ";", "currentAST", ".", "child", "=", "classTypeSpec_AST", "!=", "null", "&&", "classTypeSpec_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classTypeSpec_AST", ".", "getFirstChild", "(", ")", ":", "classTypeSpec_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "classTypeSpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "classTypeSpec_AST", ";", "}", "public", "final", "void", "builtInTypeSpec", "(", "boolean", "addImagNode", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "builtInTypeSpec_AST", "=", "null", ";", "AST", "bt_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "builtInType", "(", ")", ";", "bt_AST", "=", "(", "AST", ")", "returnAST", ";", "declaratorBrackets", "(", "bt_AST", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "builtInTypeSpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "addImagNode", ")", "{", "builtInTypeSpec_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "builtInTypeSpec_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "builtInTypeSpec_AST", ";", "currentAST", ".", "child", "=", "builtInTypeSpec_AST", "!=", "null", "&&", "builtInTypeSpec_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "builtInTypeSpec_AST", ".", "getFirstChild", "(", ")", ":", "builtInTypeSpec_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "builtInTypeSpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "builtInTypeSpec_AST", ";", "}", "public", "final", "void", "classOrInterfaceType", "(", "boolean", "addImagNode", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "classOrInterfaceType_AST", "=", "null", ";", "Token", "i1", "=", "null", ";", "AST", "i1_AST", "=", "null", ";", "Token", "d", "=", "null", ";", "AST", "d_AST", "=", "null", ";", "Token", "i2", "=", "null", ";", "AST", "i2_AST", "=", "null", ";", "AST", "ta_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "i1", "=", "LT", "(", "1", ")", ";", "i1_AST", "=", "astFactory", ".", "create", "(", "i1", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "i1_AST", ")", ";", "match", "(", "IDENT", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "typeArguments", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "RBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "DOT", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "QUESTION", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_super", ":", "case", "COMMA", ":", "case", "GT", ":", "case", "SR", ":", "case", "BSR", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "RPAREN", ":", "case", "ASSIGN", ":", "case", "BAND", ":", "case", "LCURLY", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_this", ":", "case", "TRIPLE_DOT", ":", "case", "CLOSABLE_BLOCK_OP", ":", "case", "COLON", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "PLUS_ASSIGN", ":", "case", "MINUS_ASSIGN", ":", "case", "STAR_ASSIGN", ":", "case", "DIV_ASSIGN", ":", "case", "MOD_ASSIGN", ":", "case", "SR_ASSIGN", ":", "case", "BSR_ASSIGN", ":", "case", "SL_ASSIGN", ":", "case", "BAND_ASSIGN", ":", "case", "BXOR_ASSIGN", ":", "case", "BOR_ASSIGN", ":", "case", "STAR_STAR_ASSIGN", ":", "case", "ELVIS_OPERATOR", ":", "case", "LOR", ":", "case", "LAND", ":", "case", "BOR", ":", "case", "BXOR", ":", "case", "REGEX_FIND", ":", "case", "REGEX_MATCH", ":", "case", "NOT_EQUAL", ":", "case", "EQUAL", ":", "case", "IDENTICAL", ":", "case", "NOT_IDENTICAL", ":", "case", "COMPARE_TO", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "_loop48", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "DOT", ")", "&&", "(", "LA", "(", "2", ")", "==", "IDENT", ")", ")", "{", "d", "=", "LT", "(", "1", ")", ";", "d_AST", "=", "astFactory", ".", "create", "(", "d", ")", ";", "match", "(", "DOT", ")", ";", "i2", "=", "LT", "(", "1", ")", ";", "i2_AST", "=", "astFactory", ".", "create", "(", "i2", ")", ";", "match", "(", "IDENT", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "typeArguments", "(", ")", ";", "ta_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "EOF", ":", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "RBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "DOT", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "QUESTION", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_super", ":", "case", "COMMA", ":", "case", "GT", ":", "case", "SR", ":", "case", "BSR", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "RPAREN", ":", "case", "ASSIGN", ":", "case", "BAND", ":", "case", "LCURLY", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_this", ":", "case", "TRIPLE_DOT", ":", "case", "CLOSABLE_BLOCK_OP", ":", "case", "COLON", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "PLUS_ASSIGN", ":", "case", "MINUS_ASSIGN", ":", "case", "STAR_ASSIGN", ":", "case", "DIV_ASSIGN", ":", "case", "MOD_ASSIGN", ":", "case", "SR_ASSIGN", ":", "case", "BSR_ASSIGN", ":", "case", "SL_ASSIGN", ":", "case", "BAND_ASSIGN", ":", "case", "BXOR_ASSIGN", ":", "case", "BOR_ASSIGN", ":", "case", "STAR_STAR_ASSIGN", ":", "case", "ELVIS_OPERATOR", ":", "case", "LOR", ":", "case", "LAND", ":", "case", "BOR", ":", "case", "BXOR", ":", "case", "REGEX_FIND", ":", "case", "REGEX_MATCH", ":", "case", "NOT_EQUAL", ":", "case", "EQUAL", ":", "case", "IDENTICAL", ":", "case", "NOT_IDENTICAL", ":", "case", "COMPARE_TO", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "i1_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "DOT", ",", "\".\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "i1_AST", ")", ".", "add", "(", "i2_AST", ")", ".", "add", "(", "ta_AST", ")", ")", ";", "}", "}", "else", "{", "break", "_loop48", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classOrInterfaceType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classOrInterfaceType_AST", "=", "i1_AST", ";", "if", "(", "addImagNode", ")", "{", "classOrInterfaceType_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "classOrInterfaceType_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "classOrInterfaceType_AST", ";", "currentAST", ".", "child", "=", "classOrInterfaceType_AST", "!=", "null", "&&", "classOrInterfaceType_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classOrInterfaceType_AST", ".", "getFirstChild", "(", ")", ":", "classOrInterfaceType_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "classOrInterfaceType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "classOrInterfaceType_AST", ";", "}", "public", "final", "void", "declaratorBrackets", "(", "AST", "typ", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "declaratorBrackets_AST", "=", "null", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "declaratorBrackets_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "declaratorBrackets_AST", "=", "typ", ";", "currentAST", ".", "root", "=", "declaratorBrackets_AST", ";", "currentAST", ".", "child", "=", "declaratorBrackets_AST", "!=", "null", "&&", "declaratorBrackets_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "declaratorBrackets_AST", ".", "getFirstChild", "(", ")", ":", "declaratorBrackets_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "{", "_loop246", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LBRACK", ")", "&&", "(", "LA", "(", "2", ")", "==", "RBRACK", ")", ")", "{", "match", "(", "LBRACK", ")", ";", "match", "(", "RBRACK", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "declaratorBrackets_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "declaratorBrackets_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "ARRAY_DECLARATOR", ",", "\"[\"", ",", "typ", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "declaratorBrackets_AST", ")", ")", ";", "currentAST", ".", "root", "=", "declaratorBrackets_AST", ";", "currentAST", ".", "child", "=", "declaratorBrackets_AST", "!=", "null", "&&", "declaratorBrackets_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "declaratorBrackets_AST", ".", "getFirstChild", "(", ")", ":", "declaratorBrackets_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "{", "break", "_loop246", ";", "}", "}", "while", "(", "true", ")", ";", "}", "declaratorBrackets_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "declaratorBrackets_AST", ";", "}", "public", "final", "void", "typeArgumentSpec", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeArgumentSpec_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "classTypeSpec", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "typeArgumentSpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "builtInTypeArraySpec", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "typeArgumentSpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "typeArgumentSpec_AST", ";", "}", "public", "final", "void", "builtInTypeArraySpec", "(", "boolean", "addImagNode", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "builtInTypeArraySpec_AST", "=", "null", ";", "AST", "bt_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "builtInType", "(", ")", ";", "bt_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "boolean", "synPredMatched66", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_40", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_4", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m66", "=", "mark", "(", ")", ";", "synPredMatched66", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "LBRACK", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched66", "=", "false", ";", "}", "rewind", "(", "_m66", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched66", ")", "{", "declaratorBrackets", "(", "bt_AST", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_40", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_4", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "require", "(", "false", ",", "\"\"", ",", "\"\"", ")", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "builtInTypeArraySpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "addImagNode", ")", "{", "builtInTypeArraySpec_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "builtInTypeArraySpec_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "builtInTypeArraySpec_AST", ";", "currentAST", ".", "child", "=", "builtInTypeArraySpec_AST", "!=", "null", "&&", "builtInTypeArraySpec_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "builtInTypeArraySpec_AST", ".", "getFirstChild", "(", ")", ":", "builtInTypeArraySpec_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "builtInTypeArraySpec_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "builtInTypeArraySpec_AST", ";", "}", "public", "final", "void", "typeArgument", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeArgument_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "typeArgumentSpec", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "QUESTION", ":", "{", "wildcardType", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeArgument_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "typeArgument_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE_ARGUMENT", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "typeArgument_AST", ")", ")", ";", "currentAST", ".", "root", "=", "typeArgument_AST", ";", "currentAST", ".", "child", "=", "typeArgument_AST", "!=", "null", "&&", "typeArgument_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeArgument_AST", ".", "getFirstChild", "(", ")", ":", "typeArgument_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeArgument_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "typeArgument_AST", ";", "}", "public", "final", "void", "wildcardType", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "wildcardType_AST", "=", "null", ";", "AST", "tmp89_AST", "=", "null", ";", "tmp89_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp89_AST", ")", ";", "match", "(", "QUESTION", ")", ";", "{", "boolean", "synPredMatched55", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_extends", "||", "LA", "(", "1", ")", "==", "LITERAL_super", ")", "&&", "(", "LA", "(", "2", ")", "==", "IDENT", "||", "LA", "(", "2", ")", "==", "NLS", ")", ")", ")", "{", "int", "_m55", "=", "mark", "(", ")", ";", "synPredMatched55", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_extends", ":", "{", "match", "(", "LITERAL_extends", ")", ";", "break", ";", "}", "case", "LITERAL_super", ":", "{", "match", "(", "LITERAL_super", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched55", "=", "false", ";", "}", "rewind", "(", "_m55", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched55", ")", "{", "typeArgumentBounds", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_40", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_4", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "wildcardType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "wildcardType_AST", ".", "setType", "(", "WILDCARD_TYPE", ")", ";", "}", "wildcardType_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "wildcardType_AST", ";", "}", "public", "final", "void", "typeArgumentBounds", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeArgumentBounds_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "boolean", "isUpperBounds", "=", "false", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_extends", ":", "{", "match", "(", "LITERAL_extends", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "isUpperBounds", "=", "true", ";", "}", "break", ";", "}", "case", "LITERAL_super", ":", "{", "match", "(", "LITERAL_super", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "classOrInterfaceType", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "nls", "(", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeArgumentBounds_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "isUpperBounds", ")", "{", "typeArgumentBounds_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE_UPPER_BOUNDS", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "typeArgumentBounds_AST", ")", ")", ";", "}", "else", "{", "typeArgumentBounds_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE_LOWER_BOUNDS", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "typeArgumentBounds_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "typeArgumentBounds_AST", ";", "currentAST", ".", "child", "=", "typeArgumentBounds_AST", "!=", "null", "&&", "typeArgumentBounds_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeArgumentBounds_AST", ".", "getFirstChild", "(", ")", ":", "typeArgumentBounds_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeArgumentBounds_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "typeArgumentBounds_AST", ";", "}", "protected", "final", "void", "typeArgumentsOrParametersEnd", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeArgumentsOrParametersEnd_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "GT", ":", "{", "match", "(", "GT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "ltCounter", "-=", "1", ";", "}", "typeArgumentsOrParametersEnd_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "SR", ":", "{", "match", "(", "SR", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "ltCounter", "-=", "2", ";", "}", "typeArgumentsOrParametersEnd_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "BSR", ":", "{", "match", "(", "BSR", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "ltCounter", "-=", "3", ";", "}", "typeArgumentsOrParametersEnd_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "typeArgumentsOrParametersEnd_AST", ";", "}", "public", "final", "void", "type", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "type_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "classOrInterfaceType", "(", "false", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "type_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "builtInType", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "type_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "type_AST", ";", "}", "public", "final", "void", "modifiersInternal", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "modifiersInternal_AST", "=", "null", ";", "int", "seenDef", "=", "0", ";", "{", "int", "_cnt79", "=", "0", ";", "_loop79", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_def", ")", ")", "&&", "(", "seenDef", "++", "==", "0", ")", ")", "{", "match", "(", "LITERAL_def", ")", ";", "nls", "(", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_46", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "modifier", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "nls", "(", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "AT", ")", "&&", "(", "LA", "(", "2", ")", "==", "LITERAL_interface", ")", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "break", ";", "}", "AST", "tmp96_AST", "=", "null", ";", "tmp96_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp96_AST", ")", ";", "match", "(", "AT", ")", ";", "AST", "tmp97_AST", "=", "null", ";", "tmp97_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp97_AST", ")", ";", "match", "(", "LITERAL_interface", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "AT", ")", "&&", "(", "LA", "(", "2", ")", "==", "IDENT", ")", ")", "{", "annotation", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "nls", "(", ")", ";", "}", "else", "{", "if", "(", "_cnt79", ">=", "1", ")", "{", "break", "_loop79", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "_cnt79", "++", ";", "}", "while", "(", "true", ")", ";", "}", "modifiersInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "modifiersInternal_AST", ";", "}", "public", "final", "void", "annotationArguments", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationArguments_AST", "=", "null", ";", "AST", "v_AST", "=", "null", ";", "if", "(", "(", "_tokenSet_47", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_48", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "annotationMemberValueInitializer", "(", ")", ";", "v_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "annotationArguments_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "Token", "itkn", "=", "new", "Token", "(", "IDENT", ",", "\"value\"", ")", ";", "AST", "i", ";", "i", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "1", ")", ")", ".", "add", "(", "create", "(", "IDENT", ",", "\"value\"", ",", "itkn", ",", "itkn", ")", ")", ")", ";", "annotationArguments_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "ANNOTATION_MEMBER_VALUE_PAIR", ",", "\"\"", ",", "LT", "(", "1", ")", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "i", ")", ".", "add", "(", "v_AST", ")", ")", ";", "currentAST", ".", "root", "=", "annotationArguments_AST", ";", "currentAST", ".", "child", "=", "annotationArguments_AST", "!=", "null", "&&", "annotationArguments_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "annotationArguments_AST", ".", "getFirstChild", "(", ")", ":", "annotationArguments_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "annotationArguments_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "_tokenSet_49", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "LA", "(", "2", ")", "==", "ASSIGN", ")", ")", "{", "annotationMemberValuePairs", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "annotationArguments_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "returnAST", "=", "annotationArguments_AST", ";", "}", "public", "final", "void", "annotationsInternal", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationsInternal_AST", "=", "null", ";", "{", "_loop89", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "AT", ")", "&&", "(", "LA", "(", "2", ")", "==", "LITERAL_interface", ")", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "break", ";", "}", "AST", "tmp98_AST", "=", "null", ";", "tmp98_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp98_AST", ")", ";", "match", "(", "AT", ")", ";", "AST", "tmp99_AST", "=", "null", ";", "tmp99_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp99_AST", ")", ";", "match", "(", "LITERAL_interface", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "AT", ")", "&&", "(", "LA", "(", "2", ")", "==", "IDENT", ")", ")", "{", "annotation", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "nls", "(", ")", ";", "}", "else", "{", "break", "_loop89", ";", "}", "}", "while", "(", "true", ")", ";", "}", "annotationsInternal_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "annotationsInternal_AST", ";", "}", "public", "final", "void", "annotationMemberValueInitializer", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationMemberValueInitializer_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "conditionalExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "annotationMemberValueInitializer_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "AT", ":", "{", "annotation", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "annotationMemberValueInitializer_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "annotationMemberValueInitializer_AST", ";", "}", "public", "final", "void", "annotationMemberValuePairs", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationMemberValuePairs_AST", "=", "null", ";", "annotationMemberValuePair", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop95", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "annotationMemberValuePair", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop95", ";", "}", "}", "while", "(", "true", ")", ";", "}", "annotationMemberValuePairs_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "annotationMemberValuePairs_AST", ";", "}", "public", "final", "void", "annotationMemberValuePair", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationMemberValuePair_AST", "=", "null", ";", "AST", "i_AST", "=", "null", ";", "AST", "v_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "annotationIdent", "(", ")", ";", "i_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "ASSIGN", ")", ";", "nls", "(", ")", ";", "annotationMemberValueInitializer", "(", ")", ";", "v_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "annotationMemberValuePair_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "annotationMemberValuePair_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "ANNOTATION_MEMBER_VALUE_PAIR", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "i_AST", ")", ".", "add", "(", "v_AST", ")", ")", ";", "currentAST", ".", "root", "=", "annotationMemberValuePair_AST", ";", "currentAST", ".", "child", "=", "annotationMemberValuePair_AST", "!=", "null", "&&", "annotationMemberValuePair_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "annotationMemberValuePair_AST", ".", "getFirstChild", "(", ")", ":", "annotationMemberValuePair_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "annotationMemberValuePair_AST", ";", "}", "public", "final", "void", "annotationIdent", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationIdent_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "AST", "tmp102_AST", "=", "null", ";", "tmp102_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp102_AST", ")", ";", "match", "(", "IDENT", ")", ";", "annotationIdent_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "{", "keywordPropertyNames", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "annotationIdent_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "annotationIdent_AST", ";", "}", "public", "final", "void", "keywordPropertyNames", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "keywordPropertyNames_AST", "=", "null", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "ABSTRACT", ":", "{", "AST", "tmp103_AST", "=", "null", ";", "tmp103_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp103_AST", ")", ";", "match", "(", "ABSTRACT", ")", ";", "break", ";", "}", "case", "LITERAL_as", ":", "{", "AST", "tmp104_AST", "=", "null", ";", "tmp104_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp104_AST", ")", ";", "match", "(", "LITERAL_as", ")", ";", "break", ";", "}", "case", "LITERAL_assert", ":", "{", "AST", "tmp105_AST", "=", "null", ";", "tmp105_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp105_AST", ")", ";", "match", "(", "LITERAL_assert", ")", ";", "break", ";", "}", "case", "LITERAL_break", ":", "{", "AST", "tmp106_AST", "=", "null", ";", "tmp106_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp106_AST", ")", ";", "match", "(", "LITERAL_break", ")", ";", "break", ";", "}", "case", "LITERAL_case", ":", "{", "AST", "tmp107_AST", "=", "null", ";", "tmp107_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp107_AST", ")", ";", "match", "(", "LITERAL_case", ")", ";", "break", ";", "}", "case", "LITERAL_catch", ":", "{", "AST", "tmp108_AST", "=", "null", ";", "tmp108_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp108_AST", ")", ";", "match", "(", "LITERAL_catch", ")", ";", "break", ";", "}", "case", "LITERAL_class", ":", "{", "AST", "tmp109_AST", "=", "null", ";", "tmp109_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp109_AST", ")", ";", "match", "(", "LITERAL_class", ")", ";", "break", ";", "}", "case", "LITERAL_continue", ":", "{", "AST", "tmp110_AST", "=", "null", ";", "tmp110_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp110_AST", ")", ";", "match", "(", "LITERAL_continue", ")", ";", "break", ";", "}", "case", "LITERAL_def", ":", "{", "AST", "tmp111_AST", "=", "null", ";", "tmp111_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp111_AST", ")", ";", "match", "(", "LITERAL_def", ")", ";", "break", ";", "}", "case", "LITERAL_default", ":", "{", "AST", "tmp112_AST", "=", "null", ";", "tmp112_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp112_AST", ")", ";", "match", "(", "LITERAL_default", ")", ";", "break", ";", "}", "case", "UNUSED_DO", ":", "{", "AST", "tmp113_AST", "=", "null", ";", "tmp113_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp113_AST", ")", ";", "match", "(", "UNUSED_DO", ")", ";", "break", ";", "}", "case", "LITERAL_else", ":", "{", "AST", "tmp114_AST", "=", "null", ";", "tmp114_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp114_AST", ")", ";", "match", "(", "LITERAL_else", ")", ";", "break", ";", "}", "case", "LITERAL_enum", ":", "{", "AST", "tmp115_AST", "=", "null", ";", "tmp115_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp115_AST", ")", ";", "match", "(", "LITERAL_enum", ")", ";", "break", ";", "}", "case", "LITERAL_extends", ":", "{", "AST", "tmp116_AST", "=", "null", ";", "tmp116_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp116_AST", ")", ";", "match", "(", "LITERAL_extends", ")", ";", "break", ";", "}", "case", "LITERAL_false", ":", "{", "AST", "tmp117_AST", "=", "null", ";", "tmp117_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp117_AST", ")", ";", "match", "(", "LITERAL_false", ")", ";", "break", ";", "}", "case", "FINAL", ":", "{", "AST", "tmp118_AST", "=", "null", ";", "tmp118_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp118_AST", ")", ";", "match", "(", "FINAL", ")", ";", "break", ";", "}", "case", "LITERAL_finally", ":", "{", "AST", "tmp119_AST", "=", "null", ";", "tmp119_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp119_AST", ")", ";", "match", "(", "LITERAL_finally", ")", ";", "break", ";", "}", "case", "LITERAL_for", ":", "{", "AST", "tmp120_AST", "=", "null", ";", "tmp120_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp120_AST", ")", ";", "match", "(", "LITERAL_for", ")", ";", "break", ";", "}", "case", "UNUSED_GOTO", ":", "{", "AST", "tmp121_AST", "=", "null", ";", "tmp121_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp121_AST", ")", ";", "match", "(", "UNUSED_GOTO", ")", ";", "break", ";", "}", "case", "LITERAL_if", ":", "{", "AST", "tmp122_AST", "=", "null", ";", "tmp122_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp122_AST", ")", ";", "match", "(", "LITERAL_if", ")", ";", "break", ";", "}", "case", "LITERAL_implements", ":", "{", "AST", "tmp123_AST", "=", "null", ";", "tmp123_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp123_AST", ")", ";", "match", "(", "LITERAL_implements", ")", ";", "break", ";", "}", "case", "LITERAL_import", ":", "{", "AST", "tmp124_AST", "=", "null", ";", "tmp124_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp124_AST", ")", ";", "match", "(", "LITERAL_import", ")", ";", "break", ";", "}", "case", "LITERAL_in", ":", "{", "AST", "tmp125_AST", "=", "null", ";", "tmp125_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp125_AST", ")", ";", "match", "(", "LITERAL_in", ")", ";", "break", ";", "}", "case", "LITERAL_instanceof", ":", "{", "AST", "tmp126_AST", "=", "null", ";", "tmp126_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp126_AST", ")", ";", "match", "(", "LITERAL_instanceof", ")", ";", "break", ";", "}", "case", "LITERAL_interface", ":", "{", "AST", "tmp127_AST", "=", "null", ";", "tmp127_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp127_AST", ")", ";", "match", "(", "LITERAL_interface", ")", ";", "break", ";", "}", "case", "LITERAL_native", ":", "{", "AST", "tmp128_AST", "=", "null", ";", "tmp128_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp128_AST", ")", ";", "match", "(", "LITERAL_native", ")", ";", "break", ";", "}", "case", "LITERAL_new", ":", "{", "AST", "tmp129_AST", "=", "null", ";", "tmp129_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp129_AST", ")", ";", "match", "(", "LITERAL_new", ")", ";", "break", ";", "}", "case", "LITERAL_null", ":", "{", "AST", "tmp130_AST", "=", "null", ";", "tmp130_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp130_AST", ")", ";", "match", "(", "LITERAL_null", ")", ";", "break", ";", "}", "case", "LITERAL_package", ":", "{", "AST", "tmp131_AST", "=", "null", ";", "tmp131_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp131_AST", ")", ";", "match", "(", "LITERAL_package", ")", ";", "break", ";", "}", "case", "LITERAL_private", ":", "{", "AST", "tmp132_AST", "=", "null", ";", "tmp132_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp132_AST", ")", ";", "match", "(", "LITERAL_private", ")", ";", "break", ";", "}", "case", "LITERAL_protected", ":", "{", "AST", "tmp133_AST", "=", "null", ";", "tmp133_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp133_AST", ")", ";", "match", "(", "LITERAL_protected", ")", ";", "break", ";", "}", "case", "LITERAL_public", ":", "{", "AST", "tmp134_AST", "=", "null", ";", "tmp134_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp134_AST", ")", ";", "match", "(", "LITERAL_public", ")", ";", "break", ";", "}", "case", "LITERAL_return", ":", "{", "AST", "tmp135_AST", "=", "null", ";", "tmp135_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp135_AST", ")", ";", "match", "(", "LITERAL_return", ")", ";", "break", ";", "}", "case", "LITERAL_static", ":", "{", "AST", "tmp136_AST", "=", "null", ";", "tmp136_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp136_AST", ")", ";", "match", "(", "LITERAL_static", ")", ";", "break", ";", "}", "case", "STRICTFP", ":", "{", "AST", "tmp137_AST", "=", "null", ";", "tmp137_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp137_AST", ")", ";", "match", "(", "STRICTFP", ")", ";", "break", ";", "}", "case", "LITERAL_switch", ":", "{", "AST", "tmp138_AST", "=", "null", ";", "tmp138_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp138_AST", ")", ";", "match", "(", "LITERAL_switch", ")", ";", "break", ";", "}", "case", "LITERAL_synchronized", ":", "{", "AST", "tmp139_AST", "=", "null", ";", "tmp139_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp139_AST", ")", ";", "match", "(", "LITERAL_synchronized", ")", ";", "break", ";", "}", "case", "LITERAL_threadsafe", ":", "{", "AST", "tmp140_AST", "=", "null", ";", "tmp140_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp140_AST", ")", ";", "match", "(", "LITERAL_threadsafe", ")", ";", "break", ";", "}", "case", "LITERAL_throw", ":", "{", "AST", "tmp141_AST", "=", "null", ";", "tmp141_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp141_AST", ")", ";", "match", "(", "LITERAL_throw", ")", ";", "break", ";", "}", "case", "LITERAL_throws", ":", "{", "AST", "tmp142_AST", "=", "null", ";", "tmp142_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp142_AST", ")", ";", "match", "(", "LITERAL_throws", ")", ";", "break", ";", "}", "case", "LITERAL_transient", ":", "{", "AST", "tmp143_AST", "=", "null", ";", "tmp143_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp143_AST", ")", ";", "match", "(", "LITERAL_transient", ")", ";", "break", ";", "}", "case", "LITERAL_true", ":", "{", "AST", "tmp144_AST", "=", "null", ";", "tmp144_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp144_AST", ")", ";", "match", "(", "LITERAL_true", ")", ";", "break", ";", "}", "case", "LITERAL_try", ":", "{", "AST", "tmp145_AST", "=", "null", ";", "tmp145_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp145_AST", ")", ";", "match", "(", "LITERAL_try", ")", ";", "break", ";", "}", "case", "LITERAL_volatile", ":", "{", "AST", "tmp146_AST", "=", "null", ";", "tmp146_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp146_AST", ")", ";", "match", "(", "LITERAL_volatile", ")", ";", "break", ";", "}", "case", "LITERAL_while", ":", "{", "AST", "tmp147_AST", "=", "null", ";", "tmp147_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp147_AST", ")", ";", "match", "(", "LITERAL_while", ")", ";", "break", ";", "}", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "builtInType", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "keywordPropertyNames_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "keywordPropertyNames_AST", ".", "setType", "(", "IDENT", ")", ";", "}", "keywordPropertyNames_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "keywordPropertyNames_AST", ";", "}", "public", "final", "void", "conditionalExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "conditionalExpression_AST", "=", "null", ";", "logicalOrExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "ELVIS_OPERATOR", ":", "{", "AST", "tmp148_AST", "=", "null", ";", "tmp148_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp148_AST", ")", ";", "match", "(", "ELVIS_OPERATOR", ")", ";", "nls", "(", ")", ";", "conditionalExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "QUESTION", ":", "{", "AST", "tmp149_AST", "=", "null", ";", "tmp149_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp149_AST", ")", ";", "match", "(", "QUESTION", ")", ";", "nls", "(", ")", ";", "assignmentExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "match", "(", "COLON", ")", ";", "nls", "(", ")", ";", "conditionalExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "RBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_super", ":", "case", "COMMA", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "RPAREN", ":", "case", "ASSIGN", ":", "case", "LCURLY", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_this", ":", "case", "CLOSABLE_BLOCK_OP", ":", "case", "COLON", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "PLUS_ASSIGN", ":", "case", "MINUS_ASSIGN", ":", "case", "STAR_ASSIGN", ":", "case", "DIV_ASSIGN", ":", "case", "MOD_ASSIGN", ":", "case", "SR_ASSIGN", ":", "case", "BSR_ASSIGN", ":", "case", "SL_ASSIGN", ":", "case", "BAND_ASSIGN", ":", "case", "BXOR_ASSIGN", ":", "case", "BOR_ASSIGN", ":", "case", "STAR_STAR_ASSIGN", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "conditionalExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "conditionalExpression_AST", ";", "}", "public", "final", "void", "annotationMemberArrayValueInitializer", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationMemberArrayValueInitializer_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "conditionalExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "annotationMemberArrayValueInitializer_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "AT", ":", "{", "annotation", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "nls", "(", ")", ";", "annotationMemberArrayValueInitializer_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "annotationMemberArrayValueInitializer_AST", ";", "}", "public", "final", "void", "superClassClause", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "superClassClause_AST", "=", "null", ";", "AST", "c_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_extends", ":", "{", "match", "(", "LITERAL_extends", ")", ";", "nls", "(", ")", ";", "classOrInterfaceType", "(", "false", ")", ";", "c_AST", "=", "(", "AST", ")", "returnAST", ";", "nls", "(", ")", ";", "break", ";", "}", "case", "LCURLY", ":", "case", "LITERAL_implements", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "superClassClause_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "superClassClause_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "EXTENDS_CLAUSE", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "c_AST", ")", ")", ";", "currentAST", ".", "root", "=", "superClassClause_AST", ";", "currentAST", ".", "child", "=", "superClassClause_AST", "!=", "null", "&&", "superClassClause_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "superClassClause_AST", ".", "getFirstChild", "(", ")", ":", "superClassClause_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "superClassClause_AST", ";", "}", "public", "final", "void", "implementsClause", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "implementsClause_AST", "=", "null", ";", "Token", "i", "=", "null", ";", "AST", "i_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_implements", ":", "{", "i", "=", "LT", "(", "1", ")", ";", "i_AST", "=", "astFactory", ".", "create", "(", "i", ")", ";", "match", "(", "LITERAL_implements", ")", ";", "nls", "(", ")", ";", "classOrInterfaceType", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop187", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "classOrInterfaceType", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop187", ";", "}", "}", "while", "(", "true", ")", ";", "}", "nls", "(", ")", ";", "break", ";", "}", "case", "LCURLY", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "implementsClause_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "implementsClause_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "IMPLEMENTS_CLAUSE", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "implementsClause_AST", ")", ")", ";", "currentAST", ".", "root", "=", "implementsClause_AST", ";", "currentAST", ".", "child", "=", "implementsClause_AST", "!=", "null", "&&", "implementsClause_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "implementsClause_AST", ".", "getFirstChild", "(", ")", ":", "implementsClause_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "implementsClause_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "implementsClause_AST", ";", "}", "public", "final", "void", "classBlock", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "classBlock_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "try", "{", "match", "(", "LCURLY", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "{", "classField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "_loop122", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", "||", "LA", "(", "1", ")", "==", "NLS", ")", ")", "{", "sep", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "{", "classField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop122", ";", "}", "}", "while", "(", "true", ")", ";", "}", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "OBJBLOCK", ",", "\"OBJBLOCK\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "classBlock_AST", ")", ")", ";", "currentAST", ".", "root", "=", "classBlock_AST", ";", "currentAST", ".", "child", "=", "classBlock_AST", "!=", "null", "&&", "classBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classBlock_AST", ".", "getFirstChild", "(", ")", ":", "classBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "classBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "catch", "(", "RecognitionException", "e", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "errorList", ".", "isEmpty", "(", ")", ")", "{", "classBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "reportError", "(", "e", ")", ";", "classBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "OBJBLOCK", ",", "\"OBJBLOCK\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "classBlock_AST", ")", ")", ";", "currentAST", ".", "root", "=", "classBlock_AST", ";", "currentAST", ".", "child", "=", "classBlock_AST", "!=", "null", "&&", "classBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classBlock_AST", ".", "getFirstChild", "(", ")", ":", "classBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "else", "{", "throw", "e", ";", "}", "}", "returnAST", "=", "classBlock_AST", ";", "}", "public", "final", "void", "interfaceExtends", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "interfaceExtends_AST", "=", "null", ";", "Token", "e", "=", "null", ";", "AST", "e_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_extends", ":", "{", "e", "=", "LT", "(", "1", ")", ";", "e_AST", "=", "astFactory", ".", "create", "(", "e", ")", ";", "match", "(", "LITERAL_extends", ")", ";", "nls", "(", ")", ";", "classOrInterfaceType", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop183", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "classOrInterfaceType", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop183", ";", "}", "}", "while", "(", "true", ")", ";", "}", "nls", "(", ")", ";", "break", ";", "}", "case", "LCURLY", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "interfaceExtends_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "interfaceExtends_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "EXTENDS_CLAUSE", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "interfaceExtends_AST", ")", ")", ";", "currentAST", ".", "root", "=", "interfaceExtends_AST", ";", "currentAST", ".", "child", "=", "interfaceExtends_AST", "!=", "null", "&&", "interfaceExtends_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "interfaceExtends_AST", ".", "getFirstChild", "(", ")", ":", "interfaceExtends_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "interfaceExtends_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "interfaceExtends_AST", ";", "}", "public", "final", "void", "interfaceBlock", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "interfaceBlock_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LCURLY", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "interfaceField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "_loop127", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", "||", "LA", "(", "1", ")", "==", "NLS", ")", ")", "{", "sep", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "interfaceField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop127", ";", "}", "}", "while", "(", "true", ")", ";", "}", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "interfaceBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "interfaceBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "OBJBLOCK", ",", "\"OBJBLOCK\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "interfaceBlock_AST", ")", ")", ";", "currentAST", ".", "root", "=", "interfaceBlock_AST", ";", "currentAST", ".", "child", "=", "interfaceBlock_AST", "!=", "null", "&&", "interfaceBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "interfaceBlock_AST", ".", "getFirstChild", "(", ")", ":", "interfaceBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "interfaceBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "interfaceBlock_AST", ";", "}", "public", "final", "void", "enumBlock", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "enumBlock_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LCURLY", ")", ";", "nls", "(", ")", ";", "{", "boolean", "synPredMatched136", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "IDENT", "||", "LA", "(", "1", ")", "==", "AT", ")", "&&", "(", "_tokenSet_50", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m136", "=", "mark", "(", ")", ";", "synPredMatched136", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "enumConstantsStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched136", "=", "false", ";", "}", "rewind", "(", "_m136", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched136", ")", "{", "enumConstants", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_51", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_52", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "{", "classField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "{", "_loop140", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", "||", "LA", "(", "1", ")", "==", "NLS", ")", ")", "{", "sep", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "{", "classField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop140", ";", "}", "}", "while", "(", "true", ")", ";", "}", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "enumBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "enumBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "OBJBLOCK", ",", "\"OBJBLOCK\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "enumBlock_AST", ")", ")", ";", "currentAST", ".", "root", "=", "enumBlock_AST", ";", "currentAST", ".", "child", "=", "enumBlock_AST", "!=", "null", "&&", "enumBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "enumBlock_AST", ".", "getFirstChild", "(", ")", ":", "enumBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "enumBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "enumBlock_AST", ";", "}", "public", "final", "void", "annotationBlock", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationBlock_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LCURLY", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "annotationField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "_loop132", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", "||", "LA", "(", "1", ")", "==", "NLS", ")", ")", "{", "sep", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "annotationField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop132", ";", "}", "}", "while", "(", "true", ")", ";", "}", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "annotationBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "annotationBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "OBJBLOCK", ",", "\"OBJBLOCK\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "annotationBlock_AST", ")", ")", ";", "currentAST", ".", "root", "=", "annotationBlock_AST", ";", "currentAST", ".", "child", "=", "annotationBlock_AST", "!=", "null", "&&", "annotationBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "annotationBlock_AST", ".", "getFirstChild", "(", ")", ":", "annotationBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "annotationBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "annotationBlock_AST", ";", "}", "public", "final", "void", "typeParameter", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeParameter_AST", "=", "null", ";", "Token", "id", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "id", "=", "LT", "(", "1", ")", ";", "id_AST", "=", "astFactory", ".", "create", "(", "id", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "id_AST", ")", ";", "match", "(", "IDENT", ")", ";", "}", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_extends", ")", "&&", "(", "LA", "(", "2", ")", "==", "IDENT", "||", "LA", "(", "2", ")", "==", "NLS", ")", ")", "{", "typeParameterBounds", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_53", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_54", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeParameter_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "typeParameter_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE_PARAMETER", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "typeParameter_AST", ")", ")", ";", "currentAST", ".", "root", "=", "typeParameter_AST", ";", "currentAST", ".", "child", "=", "typeParameter_AST", "!=", "null", "&&", "typeParameter_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeParameter_AST", ".", "getFirstChild", "(", ")", ":", "typeParameter_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeParameter_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "typeParameter_AST", ";", "}", "public", "final", "void", "typeParameterBounds", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeParameterBounds_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LITERAL_extends", ")", ";", "nls", "(", ")", ";", "classOrInterfaceType", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop117", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "BAND", ")", ")", "{", "match", "(", "BAND", ")", ";", "nls", "(", ")", ";", "classOrInterfaceType", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop117", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "typeParameterBounds_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "typeParameterBounds_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE_UPPER_BOUNDS", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "typeParameterBounds_AST", ")", ")", ";", "currentAST", ".", "root", "=", "typeParameterBounds_AST", ";", "currentAST", ".", "child", "=", "typeParameterBounds_AST", "!=", "null", "&&", "typeParameterBounds_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "typeParameterBounds_AST", ".", "getFirstChild", "(", ")", ":", "typeParameterBounds_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "typeParameterBounds_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "typeParameterBounds_AST", ";", "}", "public", "final", "void", "classField", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "classField_AST", "=", "null", ";", "AST", "mc_AST", "=", "null", ";", "AST", "ctor_AST", "=", "null", ";", "AST", "dg_AST", "=", "null", ";", "AST", "mad_AST", "=", "null", ";", "AST", "dd_AST", "=", "null", ";", "AST", "mods_AST", "=", "null", ";", "AST", "td_AST", "=", "null", ";", "AST", "s3_AST", "=", "null", ";", "AST", "s4_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "try", "{", "boolean", "synPredMatched190", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_55", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_56", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m190", "=", "mark", "(", ")", ";", "synPredMatched190", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "constructorStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched190", "=", "false", ";", "}", "rewind", "(", "_m190", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched190", ")", "{", "modifiersOpt", "(", ")", ";", "mc_AST", "=", "(", "AST", ")", "returnAST", ";", "constructorDefinition", "(", "mc_AST", ")", ";", "ctor_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classField_AST", "=", "ctor_AST", ";", "currentAST", ".", "root", "=", "classField_AST", ";", "currentAST", ".", "child", "=", "classField_AST", "!=", "null", "&&", "classField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classField_AST", ".", "getFirstChild", "(", ")", ":", "classField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "{", "boolean", "synPredMatched192", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_13", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_14", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m192", "=", "mark", "(", ")", ";", "synPredMatched192", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "genericMethodStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched192", "=", "false", ";", "}", "rewind", "(", "_m192", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched192", ")", "{", "genericMethod", "(", ")", ";", "dg_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classField_AST", "=", "dg_AST", ";", "currentAST", ".", "root", "=", "classField_AST", ";", "currentAST", ".", "child", "=", "classField_AST", "!=", "null", "&&", "classField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classField_AST", ".", "getFirstChild", "(", ")", ":", "classField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "{", "boolean", "synPredMatched194", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_13", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_15", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m194", "=", "mark", "(", ")", ";", "synPredMatched194", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "multipleAssignmentDeclarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched194", "=", "false", ";", "}", "rewind", "(", "_m194", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched194", ")", "{", "multipleAssignmentDeclaration", "(", ")", ";", "mad_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classField_AST", "=", "mad_AST", ";", "currentAST", ".", "root", "=", "classField_AST", ";", "currentAST", ".", "child", "=", "classField_AST", "!=", "null", "&&", "classField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classField_AST", ".", "getFirstChild", "(", ")", ":", "classField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "{", "boolean", "synPredMatched196", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_16", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_17", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m196", "=", "mark", "(", ")", ";", "synPredMatched196", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "declarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched196", "=", "false", ";", "}", "rewind", "(", "_m196", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched196", ")", "{", "declaration", "(", ")", ";", "dd_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classField_AST", "=", "dd_AST", ";", "currentAST", ".", "root", "=", "classField_AST", ";", "currentAST", ".", "child", "=", "classField_AST", "!=", "null", "&&", "classField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classField_AST", ".", "getFirstChild", "(", ")", ":", "classField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "{", "boolean", "synPredMatched198", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_22", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_23", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m198", "=", "mark", "(", ")", ";", "synPredMatched198", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "typeDeclarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched198", "=", "false", ";", "}", "rewind", "(", "_m198", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched198", ")", "{", "modifiersOpt", "(", ")", ";", "mods_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "typeDefinitionInternal", "(", "mods_AST", ")", ";", "td_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classField_AST", "=", "td_AST", ";", "currentAST", ".", "root", "=", "classField_AST", ";", "currentAST", ".", "child", "=", "classField_AST", "!=", "null", "&&", "classField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classField_AST", ".", "getFirstChild", "(", ")", ":", "classField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_static", ")", "&&", "(", "LA", "(", "2", ")", "==", "LCURLY", "||", "LA", "(", "2", ")", "==", "NLS", ")", ")", "{", "match", "(", "LITERAL_static", ")", ";", "nls", "(", ")", ";", "compoundStatement", "(", ")", ";", "s3_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classField_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "STATIC_INIT", ",", "\"STATIC_INIT\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "s3_AST", ")", ")", ";", "currentAST", ".", "root", "=", "classField_AST", ";", "currentAST", ".", "child", "=", "classField_AST", "!=", "null", "&&", "classField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classField_AST", ".", "getFirstChild", "(", ")", ":", "classField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "LCURLY", ")", ")", "{", "compoundStatement", "(", ")", ";", "s4_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "classField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "classField_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "INSTANCE_INIT", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "s4_AST", ")", ")", ";", "currentAST", ".", "root", "=", "classField_AST", ";", "currentAST", ".", "child", "=", "classField_AST", "!=", "null", "&&", "classField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "classField_AST", ".", "getFirstChild", "(", ")", ":", "classField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "}", "}", "catch", "(", "RecognitionException", "e", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "reportError", "(", "e", ")", ";", "classField_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "VARIABLE_DEF", ",", "\"VARIABLE_DEF\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "null", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"\"", ",", "LT", "(", "1", ")", ",", "LT", "(", "2", ")", ")", ")", ".", "add", "(", "create", "(", "IDENT", ",", "first", ".", "getText", "(", ")", ",", "LT", "(", "1", ")", ",", "LT", "(", "2", ")", ")", ")", ")", ";", "consumeUntil", "(", "NLS", ")", ";", "}", "else", "{", "throw", "e", ";", "}", "}", "returnAST", "=", "classField_AST", ";", "}", "public", "final", "void", "interfaceField", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "interfaceField_AST", "=", "null", ";", "AST", "d_AST", "=", "null", ";", "AST", "mods_AST", "=", "null", ";", "AST", "td_AST", "=", "null", ";", "boolean", "synPredMatched202", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_16", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_17", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m202", "=", "mark", "(", ")", ";", "synPredMatched202", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "declarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched202", "=", "false", ";", "}", "rewind", "(", "_m202", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched202", ")", "{", "declaration", "(", ")", ";", "d_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "interfaceField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "interfaceField_AST", "=", "d_AST", ";", "currentAST", ".", "root", "=", "interfaceField_AST", ";", "currentAST", ".", "child", "=", "interfaceField_AST", "!=", "null", "&&", "interfaceField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "interfaceField_AST", ".", "getFirstChild", "(", ")", ":", "interfaceField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "{", "boolean", "synPredMatched204", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_22", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_23", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m204", "=", "mark", "(", ")", ";", "synPredMatched204", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "typeDeclarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched204", "=", "false", ";", "}", "rewind", "(", "_m204", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched204", ")", "{", "modifiersOpt", "(", ")", ";", "mods_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "typeDefinitionInternal", "(", "mods_AST", ")", ";", "td_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "interfaceField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "interfaceField_AST", "=", "td_AST", ";", "currentAST", ".", "root", "=", "interfaceField_AST", ";", "currentAST", ".", "child", "=", "interfaceField_AST", "!=", "null", "&&", "interfaceField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "interfaceField_AST", ".", "getFirstChild", "(", ")", ":", "interfaceField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "interfaceField_AST", ";", "}", "public", "final", "void", "annotationField", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "annotationField_AST", "=", "null", ";", "AST", "mods_AST", "=", "null", ";", "AST", "td_AST", "=", "null", ";", "AST", "t_AST", "=", "null", ";", "Token", "i", "=", "null", ";", "AST", "i_AST", "=", "null", ";", "AST", "amvi_AST", "=", "null", ";", "AST", "v_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "modifiersOpt", "(", ")", ";", "mods_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "{", "typeDefinitionInternal", "(", "mods_AST", ")", ";", "td_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "annotationField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "annotationField_AST", "=", "td_AST", ";", "currentAST", ".", "root", "=", "annotationField_AST", ";", "currentAST", ".", "child", "=", "annotationField_AST", "!=", "null", "&&", "annotationField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "annotationField_AST", ".", "getFirstChild", "(", ")", ":", "annotationField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "case", "IDENT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "typeSpec", "(", "false", ")", ";", "t_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "boolean", "synPredMatched160", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "LA", "(", "2", ")", "==", "LPAREN", ")", ")", ")", "{", "int", "_m160", "=", "mark", "(", ")", ";", "synPredMatched160", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "IDENT", ")", ";", "match", "(", "LPAREN", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched160", "=", "false", ";", "}", "rewind", "(", "_m160", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched160", ")", "{", "i", "=", "LT", "(", "1", ")", ";", "i_AST", "=", "astFactory", ".", "create", "(", "i", ")", ";", "match", "(", "IDENT", ")", ";", "match", "(", "LPAREN", ")", ";", "match", "(", "RPAREN", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_default", ":", "{", "match", "(", "LITERAL_default", ")", ";", "nls", "(", ")", ";", "annotationMemberValueInitializer", "(", ")", ";", "amvi_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "annotationField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "annotationField_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "5", ")", ")", ".", "add", "(", "create", "(", "ANNOTATION_FIELD_DEF", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "mods_AST", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "t_AST", ")", ")", ")", ".", "add", "(", "i_AST", ")", ".", "add", "(", "amvi_AST", ")", ")", ";", "currentAST", ".", "root", "=", "annotationField_AST", ";", "currentAST", ".", "child", "=", "annotationField_AST", "!=", "null", "&&", "annotationField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "annotationField_AST", ".", "getFirstChild", "(", ")", ":", "annotationField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", "||", "LA", "(", "1", ")", "==", "STRING_LITERAL", ")", "&&", "(", "_tokenSet_57", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "variableDefinitions", "(", "mods_AST", ",", "t_AST", ")", ";", "v_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "annotationField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "annotationField_AST", "=", "v_AST", ";", "currentAST", ".", "root", "=", "annotationField_AST", ";", "currentAST", ".", "child", "=", "annotationField_AST", "!=", "null", "&&", "annotationField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "annotationField_AST", ".", "getFirstChild", "(", ")", ":", "annotationField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "returnAST", "=", "annotationField_AST", ";", "}", "public", "final", "void", "enumConstantsStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "enumConstantsStart_AST", "=", "null", ";", "annotationsOpt", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "AST", "tmp168_AST", "=", "null", ";", "tmp168_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp168_AST", ")", ";", "match", "(", "IDENT", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LCURLY", ":", "{", "AST", "tmp169_AST", "=", "null", ";", "tmp169_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp169_AST", ")", ";", "match", "(", "LCURLY", ")", ";", "break", ";", "}", "case", "LPAREN", ":", "{", "AST", "tmp170_AST", "=", "null", ";", "tmp170_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp170_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "AT", ":", "case", "COMMA", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "nls", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SEMI", ":", "{", "AST", "tmp171_AST", "=", "null", ";", "tmp171_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp171_AST", ")", ";", "match", "(", "SEMI", ")", ";", "break", ";", "}", "case", "COMMA", ":", "{", "AST", "tmp172_AST", "=", "null", ";", "tmp172_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp172_AST", ")", ";", "match", "(", "COMMA", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "declarationStart", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "{", "AST", "tmp173_AST", "=", "null", ";", "tmp173_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp173_AST", ")", ";", "match", "(", "RCURLY", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "enumConstantsStart_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "enumConstantsStart_AST", ";", "}", "public", "final", "void", "enumConstants", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "enumConstants_AST", "=", "null", ";", "enumConstant", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop155", ":", "do", "{", "boolean", "synPredMatched148", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_58", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_59", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m148", "=", "mark", "(", ")", ";", "synPredMatched148", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "nls", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "RCURLY", ":", "{", "match", "(", "RCURLY", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "{", "classField", "(", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched148", "=", "false", ";", "}", "rewind", "(", "_m148", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched148", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "break", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", "||", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_60", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "nls", "(", ")", ";", "match", "(", "COMMA", ")", ";", "{", "boolean", "synPredMatched152", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_58", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_59", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m152", "=", "mark", "(", ")", ";", "synPredMatched152", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "nls", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "RCURLY", ":", "{", "match", "(", "RCURLY", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "{", "classField", "(", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched152", "=", "false", ";", "}", "rewind", "(", "_m152", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched152", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "break", ";", "}", "}", "else", "{", "boolean", "synPredMatched154", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_61", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_62", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m154", "=", "mark", "(", ")", ";", "synPredMatched154", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "nls", "(", ")", ";", "annotationsOpt", "(", ")", ";", "match", "(", "IDENT", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched154", "=", "false", ";", "}", "rewind", "(", "_m154", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched154", ")", "{", "nls", "(", ")", ";", "enumConstant", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop155", ";", "}", "}", "while", "(", "true", ")", ";", "}", "enumConstants_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "enumConstants_AST", ";", "}", "public", "final", "void", "enumConstant", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "enumConstant_AST", "=", "null", ";", "AST", "an_AST", "=", "null", ";", "Token", "i", "=", "null", ";", "AST", "i_AST", "=", "null", ";", "AST", "a_AST", "=", "null", ";", "AST", "b_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "annotationsOpt", "(", ")", ";", "an_AST", "=", "(", "AST", ")", "returnAST", ";", "i", "=", "LT", "(", "1", ")", ";", "i_AST", "=", "astFactory", ".", "create", "(", "i", ")", ";", "match", "(", "IDENT", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LPAREN", ":", "{", "match", "(", "LPAREN", ")", ";", "argList", "(", ")", ";", "a_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "break", ";", "}", "case", "COMMA", ":", "case", "LCURLY", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LCURLY", ":", "{", "enumConstantBlock", "(", ")", ";", "b_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "COMMA", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "enumConstant_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "enumConstant_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "5", ")", ")", ".", "add", "(", "create", "(", "ENUM_CONSTANT_DEF", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "an_AST", ")", ".", "add", "(", "i_AST", ")", ".", "add", "(", "a_AST", ")", ".", "add", "(", "b_AST", ")", ")", ";", "currentAST", ".", "root", "=", "enumConstant_AST", ";", "currentAST", ".", "child", "=", "enumConstant_AST", "!=", "null", "&&", "enumConstant_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "enumConstant_AST", ".", "getFirstChild", "(", ")", ":", "enumConstant_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "enumConstant_AST", ";", "}", "public", "final", "void", "argList", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "argList_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "Token", "lastComma", "=", "null", ";", "int", "hls", "=", "0", ",", "hls2", "=", "0", ";", "boolean", "hasClosureList", "=", "false", ";", "boolean", "trailingComma", "=", "false", ";", "boolean", "sce", "=", "false", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "STAR", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "hls", "=", "argument", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SEMI", ":", "{", "{", "{", "int", "_cnt510", "=", "0", ";", "_loop510", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", ")", ")", "{", "match", "(", "SEMI", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "hasClosureList", "=", "true", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "sce", "=", "strictContextExpression", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RBRACK", ":", "case", "RPAREN", ":", "case", "SEMI", ":", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "astFactory", ".", "create", "(", "EMPTY_STAT", ",", "\"EMPTY_STAT\"", ")", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "if", "(", "_cnt510", ">=", "1", ")", "{", "break", "_loop510", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "_cnt510", "++", ";", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "argList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "argList_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "CLOSURE_LIST", ",", "\"CLOSURE_LIST\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "argList_AST", ")", ")", ";", "currentAST", ".", "root", "=", "argList_AST", ";", "currentAST", ".", "child", "=", "argList_AST", "!=", "null", "&&", "argList_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "argList_AST", ".", "getFirstChild", "(", ")", ":", "argList_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "break", ";", "}", "case", "RBRACK", ":", "case", "COMMA", ":", "case", "RPAREN", ":", "{", "{", "{", "_loop516", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "lastComma", "=", "LT", "(", "1", ")", ";", "}", "match", "(", "COMMA", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "STAR", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "{", "hls2", "=", "argument", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "hls", "|=", "hls2", ";", "}", "}", "break", ";", "}", "case", "RBRACK", ":", "case", "COMMA", ":", "case", "RPAREN", ":", "{", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "trailingComma", ")", "throw", "new", "NoViableAltException", "(", "lastComma", ",", "getFilename", "(", ")", ")", ";", "trailingComma", "=", "true", ";", "}", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop516", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "argList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "argList_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "ELIST", ",", "\"ELIST\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "argList_AST", ")", ")", ";", "currentAST", ".", "root", "=", "argList_AST", ";", "currentAST", ".", "child", "=", "argList_AST", "!=", "null", "&&", "argList_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "argList_AST", ".", "getFirstChild", "(", ")", ":", "argList_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "break", ";", "}", "case", "RBRACK", ":", "case", "RPAREN", ":", "{", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "argList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "argList_AST", "=", "create", "(", "ELIST", ",", "\"ELIST\"", ",", "first", ",", "LT", "(", "1", ")", ")", ";", "currentAST", ".", "root", "=", "argList_AST", ";", "currentAST", ".", "child", "=", "argList_AST", "!=", "null", "&&", "argList_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "argList_AST", ".", "getFirstChild", "(", ")", ":", "argList_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "argListHasLabels", "=", "(", "hls", "&", "1", ")", "!=", "0", ";", "}", "argList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "argList_AST", ";", "}", "public", "final", "void", "enumConstantBlock", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "enumConstantBlock_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LCURLY", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "{", "enumConstantField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "_loop169", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", "||", "LA", "(", "1", ")", "==", "NLS", ")", ")", "{", "sep", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "{", "enumConstantField", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop169", ";", "}", "}", "while", "(", "true", ")", ";", "}", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "enumConstantBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "enumConstantBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "OBJBLOCK", ",", "\"OBJBLOCK\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "enumConstantBlock_AST", ")", ")", ";", "currentAST", ".", "root", "=", "enumConstantBlock_AST", ";", "currentAST", ".", "child", "=", "enumConstantBlock_AST", "!=", "null", "&&", "enumConstantBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "enumConstantBlock_AST", ".", "getFirstChild", "(", ")", ":", "enumConstantBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "enumConstantBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "enumConstantBlock_AST", ";", "}", "public", "final", "void", "enumConstantField", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "enumConstantField_AST", "=", "null", ";", "AST", "mods_AST", "=", "null", ";", "AST", "td_AST", "=", "null", ";", "AST", "tp_AST", "=", "null", ";", "AST", "t_AST", "=", "null", ";", "AST", "param_AST", "=", "null", ";", "AST", "tc_AST", "=", "null", ";", "AST", "s2_AST", "=", "null", ";", "AST", "v_AST", "=", "null", ";", "AST", "s4_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "LT", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "modifiersOpt", "(", ")", ";", "mods_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "{", "typeDefinitionInternal", "(", "mods_AST", ")", ";", "td_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "enumConstantField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "enumConstantField_AST", "=", "td_AST", ";", "currentAST", ".", "root", "=", "enumConstantField_AST", ";", "currentAST", ".", "child", "=", "enumConstantField_AST", "!=", "null", "&&", "enumConstantField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "enumConstantField_AST", ".", "getFirstChild", "(", ")", ":", "enumConstantField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "case", "IDENT", ":", "case", "LT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "typeParameters", "(", ")", ";", "tp_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "IDENT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "typeSpec", "(", "false", ")", ";", "t_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "boolean", "synPredMatched175", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "LA", "(", "2", ")", "==", "LPAREN", ")", ")", ")", "{", "int", "_m175", "=", "mark", "(", ")", ";", "synPredMatched175", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "IDENT", ")", ";", "match", "(", "LPAREN", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched175", "=", "false", ";", "}", "rewind", "(", "_m175", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched175", ")", "{", "AST", "tmp181_AST", "=", "null", ";", "tmp181_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "IDENT", ")", ";", "match", "(", "LPAREN", ")", ";", "parameterDeclarationList", "(", ")", ";", "param_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "{", "boolean", "synPredMatched178", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_throws", "||", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_29", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m178", "=", "mark", "(", ")", ";", "synPredMatched178", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "nls", "(", ")", ";", "match", "(", "LITERAL_throws", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched178", "=", "false", ";", "}", "rewind", "(", "_m178", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched178", ")", "{", "throwsClause", "(", ")", ";", "tc_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "_tokenSet_63", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_64", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LCURLY", ":", "{", "compoundStatement", "(", ")", ";", "s2_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "enumConstantField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "enumConstantField_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "8", ")", ")", ".", "add", "(", "create", "(", "METHOD_DEF", ",", "\"METHOD_DEF\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "mods_AST", ")", ".", "add", "(", "tp_AST", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "t_AST", ")", ")", ")", ".", "add", "(", "tmp181_AST", ")", ".", "add", "(", "param_AST", ")", ".", "add", "(", "tc_AST", ")", ".", "add", "(", "s2_AST", ")", ")", ";", "currentAST", ".", "root", "=", "enumConstantField_AST", ";", "currentAST", ".", "child", "=", "enumConstantField_AST", "!=", "null", "&&", "enumConstantField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "enumConstantField_AST", ".", "getFirstChild", "(", ")", ":", "enumConstantField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", "||", "LA", "(", "1", ")", "==", "STRING_LITERAL", ")", "&&", "(", "_tokenSet_57", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "variableDefinitions", "(", "mods_AST", ",", "t_AST", ")", ";", "v_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "enumConstantField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "enumConstantField_AST", "=", "v_AST", ";", "currentAST", ".", "root", "=", "enumConstantField_AST", ";", "currentAST", ".", "child", "=", "enumConstantField_AST", "!=", "null", "&&", "enumConstantField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "enumConstantField_AST", ".", "getFirstChild", "(", ")", ":", "enumConstantField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "break", ";", "}", "case", "LCURLY", ":", "{", "compoundStatement", "(", ")", ";", "s4_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "enumConstantField_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "enumConstantField_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "INSTANCE_INIT", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "s4_AST", ")", ")", ";", "currentAST", ".", "root", "=", "enumConstantField_AST", ";", "currentAST", ".", "child", "=", "enumConstantField_AST", "!=", "null", "&&", "enumConstantField_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "enumConstantField_AST", ".", "getFirstChild", "(", ")", ":", "enumConstantField_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "enumConstantField_AST", ";", "}", "public", "final", "void", "parameterDeclarationList", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "parameterDeclarationList_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "AT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "TRIPLE_DOT", ":", "{", "parameterDeclaration", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop254", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "parameterDeclaration", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop254", ";", "}", "}", "while", "(", "true", ")", ";", "}", "break", ";", "}", "case", "RPAREN", ":", "case", "CLOSABLE_BLOCK_OP", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "parameterDeclarationList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "parameterDeclarationList_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "PARAMETERS", ",", "\"PARAMETERS\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "parameterDeclarationList_AST", ")", ")", ";", "currentAST", ".", "root", "=", "parameterDeclarationList_AST", ";", "currentAST", ".", "child", "=", "parameterDeclarationList_AST", "!=", "null", "&&", "parameterDeclarationList_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "parameterDeclarationList_AST", ".", "getFirstChild", "(", ")", ":", "parameterDeclarationList_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "parameterDeclarationList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "parameterDeclarationList_AST", ";", "}", "public", "final", "void", "throwsClause", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "throwsClause_AST", "=", "null", ";", "nls", "(", ")", ";", "AST", "tmp185_AST", "=", "null", ";", "tmp185_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp185_AST", ")", ";", "match", "(", "LITERAL_throws", ")", ";", "nls", "(", ")", ";", "identifier", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop250", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "identifier", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop250", ";", "}", "}", "while", "(", "true", ")", ";", "}", "throwsClause_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "throwsClause_AST", ";", "}", "public", "final", "void", "compoundStatement", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "compoundStatement_AST", "=", "null", ";", "openBlock", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "compoundStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "compoundStatement_AST", ";", "}", "public", "final", "void", "constructorDefinition", "(", "AST", "mods", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "constructorDefinition_AST", "=", "null", ";", "Token", "id", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "AST", "param_AST", "=", "null", ";", "AST", "tc_AST", "=", "null", ";", "AST", "cb_AST", "=", "null", ";", "Token", "first", "=", "cloneToken", "(", "LT", "(", "1", ")", ")", ";", "if", "(", "mods", "!=", "null", ")", "{", "first", ".", "setLine", "(", "mods", ".", "getLine", "(", ")", ")", ";", "first", ".", "setColumn", "(", "mods", ".", "getColumn", "(", ")", ")", ";", "}", "id", "=", "LT", "(", "1", ")", ";", "id_AST", "=", "astFactory", ".", "create", "(", "id", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "id_AST", ")", ";", "match", "(", "IDENT", ")", ";", "match", "(", "LPAREN", ")", ";", "parameterDeclarationList", "(", ")", ";", "param_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "{", "boolean", "synPredMatched239", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_throws", "||", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_29", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m239", "=", "mark", "(", ")", ";", "synPredMatched239", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "nls", "(", ")", ";", "match", "(", "LITERAL_throws", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched239", "=", "false", ";", "}", "rewind", "(", "_m239", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched239", ")", "{", "throwsClause", "(", ")", ";", "tc_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "LCURLY", "||", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_65", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "nlsWarn", "(", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "isConstructorIdent", "(", "id", ")", ";", "}", "constructorBody", "(", ")", ";", "cb_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "constructorDefinition_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "constructorDefinition_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "5", ")", ")", ".", "add", "(", "create", "(", "CTOR_IDENT", ",", "\"CTOR_IDENT\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "mods", ")", ".", "add", "(", "param_AST", ")", ".", "add", "(", "tc_AST", ")", ".", "add", "(", "cb_AST", ")", ")", ";", "currentAST", ".", "root", "=", "constructorDefinition_AST", ";", "currentAST", ".", "child", "=", "constructorDefinition_AST", "!=", "null", "&&", "constructorDefinition_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "constructorDefinition_AST", ".", "getFirstChild", "(", ")", ":", "constructorDefinition_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "constructorDefinition_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "constructorDefinition_AST", ";", "}", "public", "final", "void", "multipleAssignmentDeclarationStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "multipleAssignmentDeclarationStart_AST", "=", "null", ";", "{", "_loop219", ":", "do", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "{", "modifier", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "nls", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "AT", ":", "{", "annotation", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "nls", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "default", ":", "{", "break", "_loop219", ";", "}", "}", "}", "while", "(", "true", ")", ";", "}", "AST", "tmp189_AST", "=", "null", ";", "tmp189_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp189_AST", ")", ";", "match", "(", "LITERAL_def", ")", ";", "nls", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "AST", "tmp190_AST", "=", "null", ";", "tmp190_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp190_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "multipleAssignmentDeclarationStart_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "multipleAssignmentDeclarationStart_AST", ";", "}", "public", "final", "void", "multipleAssignmentDeclaration", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "multipleAssignmentDeclaration_AST", "=", "null", ";", "AST", "mods_AST", "=", "null", ";", "AST", "t_AST", "=", "null", ";", "Token", "first", "=", "cloneToken", "(", "LT", "(", "1", ")", ")", ";", "modifiers", "(", ")", ";", "mods_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "typeSpec", "(", "false", ")", ";", "t_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "LPAREN", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "AST", "tmp191_AST", "=", "null", ";", "tmp191_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp191_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "nls", "(", ")", ";", "typeNamePairs", "(", "mods_AST", ",", "first", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "match", "(", "RPAREN", ")", ";", "AST", "tmp193_AST", "=", "null", ";", "tmp193_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp193_AST", ")", ";", "match", "(", "ASSIGN", ")", ";", "nls", "(", ")", ";", "assignmentExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "multipleAssignmentDeclaration_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "multipleAssignmentDeclaration_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "VARIABLE_DEF", ",", "\"VARIABLE_DEF\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "mods_AST", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "t_AST", ")", ")", ")", ".", "add", "(", "multipleAssignmentDeclaration_AST", ")", ")", ";", "currentAST", ".", "root", "=", "multipleAssignmentDeclaration_AST", ";", "currentAST", ".", "child", "=", "multipleAssignmentDeclaration_AST", "!=", "null", "&&", "multipleAssignmentDeclaration_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "multipleAssignmentDeclaration_AST", ".", "getFirstChild", "(", ")", ":", "multipleAssignmentDeclaration_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "multipleAssignmentDeclaration_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "multipleAssignmentDeclaration_AST", ";", "}", "public", "final", "void", "constructorBody", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "constructorBody_AST", "=", "null", ";", "AST", "eci_AST", "=", "null", ";", "AST", "bb1_AST", "=", "null", ";", "AST", "bb2_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LCURLY", ")", ";", "nls", "(", ")", ";", "{", "boolean", "synPredMatched209", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_66", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_67", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m209", "=", "mark", "(", ")", ";", "synPredMatched209", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "explicitConstructorInvocation", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched209", "=", "false", ";", "}", "rewind", "(", "_m209", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched209", ")", "{", "explicitConstructorInvocation", "(", ")", ";", "eci_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SEMI", ":", "case", "NLS", ":", "{", "sep", "(", ")", ";", "blockBody", "(", "sepToken", ")", ";", "bb1_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "RCURLY", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "if", "(", "(", "_tokenSet_31", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_68", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "blockBody", "(", "EOF", ")", ";", "bb2_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "constructorBody_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "eci_AST", "!=", "null", ")", "constructorBody_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "SLIST", ",", "\"{\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "eci_AST", ")", ".", "add", "(", "bb1_AST", ")", ")", ";", "else", "constructorBody_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "SLIST", ",", "\"{\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "bb2_AST", ")", ")", ";", "currentAST", ".", "root", "=", "constructorBody_AST", ";", "currentAST", ".", "child", "=", "constructorBody_AST", "!=", "null", "&&", "constructorBody_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "constructorBody_AST", ".", "getFirstChild", "(", ")", ":", "constructorBody_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "constructorBody_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "constructorBody_AST", ";", "}", "public", "final", "void", "explicitConstructorInvocation", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "explicitConstructorInvocation_AST", "=", "null", ";", "Token", "lp1", "=", "null", ";", "AST", "lp1_AST", "=", "null", ";", "Token", "lp2", "=", "null", ";", "AST", "lp2_AST", "=", "null", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "typeArguments", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "LITERAL_super", ":", "case", "LITERAL_this", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_this", ":", "{", "match", "(", "LITERAL_this", ")", ";", "lp1", "=", "LT", "(", "1", ")", ";", "lp1_AST", "=", "astFactory", ".", "create", "(", "lp1", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "lp1_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "argList", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "match", "(", "RPAREN", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "lp1_AST", ".", "setType", "(", "CTOR_CALL", ")", ";", "}", "break", ";", "}", "case", "LITERAL_super", ":", "{", "match", "(", "LITERAL_super", ")", ";", "lp2", "=", "LT", "(", "1", ")", ";", "lp2_AST", "=", "astFactory", ".", "create", "(", "lp2", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "lp2_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "argList", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "match", "(", "RPAREN", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "lp2_AST", ".", "setType", "(", "SUPER_CTOR_CALL", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "explicitConstructorInvocation_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "explicitConstructorInvocation_AST", ";", "}", "public", "final", "void", "listOfVariables", "(", "AST", "mods", ",", "AST", "t", ",", "Token", "first", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "listOfVariables_AST", "=", "null", ";", "variableDeclarator", "(", "getASTFactory", "(", ")", ".", "dupTree", "(", "mods", ")", ",", "getASTFactory", "(", ")", ".", "dupTree", "(", "t", ")", ",", "first", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop216", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "first", "=", "LT", "(", "1", ")", ";", "}", "variableDeclarator", "(", "getASTFactory", "(", ")", ".", "dupTree", "(", "mods", ")", ",", "getASTFactory", "(", ")", ".", "dupTree", "(", "t", ")", ",", "first", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop216", ";", "}", "}", "while", "(", "true", ")", ";", "}", "listOfVariables_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "listOfVariables_AST", ";", "}", "public", "final", "void", "variableDeclarator", "(", "AST", "mods", ",", "AST", "t", ",", "Token", "first", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "variableDeclarator_AST", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "AST", "v_AST", "=", "null", ";", "variableName", "(", ")", ";", "id_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "ASSIGN", ":", "{", "varInitializer", "(", ")", ";", "v_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "EOF", ":", "case", "COMMA", ":", "case", "RPAREN", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_else", ":", "case", "LITERAL_case", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "variableDeclarator_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "variableDeclarator_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "5", ")", ")", ".", "add", "(", "create", "(", "VARIABLE_DEF", ",", "\"VARIABLE_DEF\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "mods", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "t", ")", ")", ")", ".", "add", "(", "id_AST", ")", ".", "add", "(", "v_AST", ")", ")", ";", "currentAST", ".", "root", "=", "variableDeclarator_AST", ";", "currentAST", ".", "child", "=", "variableDeclarator_AST", "!=", "null", "&&", "variableDeclarator_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "variableDeclarator_AST", ".", "getFirstChild", "(", ")", ":", "variableDeclarator_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "variableDeclarator_AST", ";", "}", "public", "final", "void", "typeNamePairs", "(", "AST", "mods", ",", "Token", "first", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "typeNamePairs_AST", "=", "null", ";", "AST", "t_AST", "=", "null", ";", "AST", "tn_AST", "=", "null", ";", "{", "if", "(", "(", "_tokenSet_25", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_32", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "typeSpec", "(", "false", ")", ";", "t_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "LA", "(", "2", ")", "==", "COMMA", "||", "LA", "(", "2", ")", "==", "RPAREN", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "singleVariable", "(", "getASTFactory", "(", ")", ".", "dupTree", "(", "mods", ")", ",", "t_AST", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop224", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "first", "=", "LT", "(", "1", ")", ";", "}", "{", "if", "(", "(", "_tokenSet_25", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_32", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "typeSpec", "(", "false", ")", ";", "tn_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "LA", "(", "2", ")", "==", "COMMA", "||", "LA", "(", "2", ")", "==", "RPAREN", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "singleVariable", "(", "getASTFactory", "(", ")", ".", "dupTree", "(", "mods", ")", ",", "tn_AST", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop224", ";", "}", "}", "while", "(", "true", ")", ";", "}", "typeNamePairs_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "typeNamePairs_AST", ";", "}", "public", "final", "void", "assignmentExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "assignmentExpression_AST", "=", "null", ";", "conditionalExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "ASSIGN", ":", "case", "PLUS_ASSIGN", ":", "case", "MINUS_ASSIGN", ":", "case", "STAR_ASSIGN", ":", "case", "DIV_ASSIGN", ":", "case", "MOD_ASSIGN", ":", "case", "SR_ASSIGN", ":", "case", "BSR_ASSIGN", ":", "case", "SL_ASSIGN", ":", "case", "BAND_ASSIGN", ":", "case", "BXOR_ASSIGN", ":", "case", "BOR_ASSIGN", ":", "case", "STAR_STAR_ASSIGN", ":", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "ASSIGN", ":", "{", "AST", "tmp202_AST", "=", "null", ";", "tmp202_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp202_AST", ")", ";", "match", "(", "ASSIGN", ")", ";", "break", ";", "}", "case", "PLUS_ASSIGN", ":", "{", "AST", "tmp203_AST", "=", "null", ";", "tmp203_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp203_AST", ")", ";", "match", "(", "PLUS_ASSIGN", ")", ";", "break", ";", "}", "case", "MINUS_ASSIGN", ":", "{", "AST", "tmp204_AST", "=", "null", ";", "tmp204_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp204_AST", ")", ";", "match", "(", "MINUS_ASSIGN", ")", ";", "break", ";", "}", "case", "STAR_ASSIGN", ":", "{", "AST", "tmp205_AST", "=", "null", ";", "tmp205_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp205_AST", ")", ";", "match", "(", "STAR_ASSIGN", ")", ";", "break", ";", "}", "case", "DIV_ASSIGN", ":", "{", "AST", "tmp206_AST", "=", "null", ";", "tmp206_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp206_AST", ")", ";", "match", "(", "DIV_ASSIGN", ")", ";", "break", ";", "}", "case", "MOD_ASSIGN", ":", "{", "AST", "tmp207_AST", "=", "null", ";", "tmp207_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp207_AST", ")", ";", "match", "(", "MOD_ASSIGN", ")", ";", "break", ";", "}", "case", "SR_ASSIGN", ":", "{", "AST", "tmp208_AST", "=", "null", ";", "tmp208_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp208_AST", ")", ";", "match", "(", "SR_ASSIGN", ")", ";", "break", ";", "}", "case", "BSR_ASSIGN", ":", "{", "AST", "tmp209_AST", "=", "null", ";", "tmp209_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp209_AST", ")", ";", "match", "(", "BSR_ASSIGN", ")", ";", "break", ";", "}", "case", "SL_ASSIGN", ":", "{", "AST", "tmp210_AST", "=", "null", ";", "tmp210_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp210_AST", ")", ";", "match", "(", "SL_ASSIGN", ")", ";", "break", ";", "}", "case", "BAND_ASSIGN", ":", "{", "AST", "tmp211_AST", "=", "null", ";", "tmp211_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp211_AST", ")", ";", "match", "(", "BAND_ASSIGN", ")", ";", "break", ";", "}", "case", "BXOR_ASSIGN", ":", "{", "AST", "tmp212_AST", "=", "null", ";", "tmp212_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp212_AST", ")", ";", "match", "(", "BXOR_ASSIGN", ")", ";", "break", ";", "}", "case", "BOR_ASSIGN", ":", "{", "AST", "tmp213_AST", "=", "null", ";", "tmp213_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp213_AST", ")", ";", "match", "(", "BOR_ASSIGN", ")", ";", "break", ";", "}", "case", "STAR_STAR_ASSIGN", ":", "{", "AST", "tmp214_AST", "=", "null", ";", "tmp214_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp214_AST", ")", ";", "match", "(", "STAR_STAR_ASSIGN", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "assignmentExpression", "(", "lc_stmt", "==", "LC_STMT", "?", "LC_INIT", ":", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "RBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_super", ":", "case", "COMMA", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "RPAREN", ":", "case", "LCURLY", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_this", ":", "case", "CLOSABLE_BLOCK_OP", ":", "case", "COLON", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "assignmentExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "assignmentExpression_AST", ";", "}", "public", "final", "void", "nlsWarn", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "nlsWarn_AST", "=", "null", ";", "{", "boolean", "synPredMatched555", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_69", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m555", "=", "mark", "(", ")", ";", "synPredMatched555", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "NLS", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched555", "=", "false", ";", "}", "rewind", "(", "_m555", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched555", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "addWarning", "(", "\"\"", ",", "\"\"", ")", ";", "}", "}", "else", "if", "(", "(", "_tokenSet_69", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "nls", "(", ")", ";", "returnAST", "=", "nlsWarn_AST", ";", "}", "public", "final", "void", "openBlock", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "openBlock_AST", "=", "null", ";", "AST", "bb_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LCURLY", ")", ";", "nls", "(", ")", ";", "blockBody", "(", "EOF", ")", ";", "bb_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "openBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "openBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "SLIST", ",", "\"{\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "bb_AST", ")", ")", ";", "currentAST", ".", "root", "=", "openBlock_AST", ";", "currentAST", ".", "child", "=", "openBlock_AST", "!=", "null", "&&", "openBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "openBlock_AST", ".", "getFirstChild", "(", ")", ":", "openBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "openBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "openBlock_AST", ";", "}", "public", "final", "void", "variableName", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "variableName_AST", "=", "null", ";", "AST", "tmp217_AST", "=", "null", ";", "tmp217_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp217_AST", ")", ";", "match", "(", "IDENT", ")", ";", "variableName_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "variableName_AST", ";", "}", "public", "final", "void", "expression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "expression_AST", "=", "null", ";", "Token", "lp", "=", "null", ";", "AST", "lp_AST", "=", "null", ";", "AST", "m_AST", "=", "null", ";", "boolean", "synPredMatched369", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LPAREN", ")", "&&", "(", "_tokenSet_25", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m369", "=", "mark", "(", ")", ";", "synPredMatched369", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "LPAREN", ")", ";", "typeSpec", "(", "true", ")", ";", "match", "(", "RPAREN", ")", ";", "expression", "(", "lc_stmt", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched369", "=", "false", ";", "}", "rewind", "(", "_m369", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched369", ")", "{", "lp", "=", "LT", "(", "1", ")", ";", "lp_AST", "=", "astFactory", ".", "create", "(", "lp", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "lp_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "lp_AST", ".", "setType", "(", "TYPECAST", ")", ";", "}", "typeSpec", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "match", "(", "RPAREN", ")", ";", "expression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "expression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "boolean", "synPredMatched373", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LPAREN", ")", "&&", "(", "LA", "(", "2", ")", "==", "IDENT", "||", "LA", "(", "2", ")", "==", "NLS", ")", ")", ")", "{", "int", "_m373", "=", "mark", "(", ")", ";", "synPredMatched373", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "LPAREN", ")", ";", "nls", "(", ")", ";", "match", "(", "IDENT", ")", ";", "{", "_loop372", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "match", "(", "IDENT", ")", ";", "}", "else", "{", "break", "_loop372", ";", "}", "}", "while", "(", "true", ")", ";", "}", "match", "(", "RPAREN", ")", ";", "match", "(", "ASSIGN", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched373", "=", "false", ";", "}", "rewind", "(", "_m373", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched373", ")", "{", "multipleAssignment", "(", "lc_stmt", ")", ";", "m_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "expression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "expression_AST", "=", "m_AST", ";", "currentAST", ".", "root", "=", "expression_AST", ";", "currentAST", ".", "child", "=", "expression_AST", "!=", "null", "&&", "expression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "expression_AST", ".", "getFirstChild", "(", ")", ":", "expression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "expression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_38", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "assignmentExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "expression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "expression_AST", ";", "}", "public", "final", "void", "parameterDeclaration", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "parameterDeclaration_AST", "=", "null", ";", "AST", "pm_AST", "=", "null", ";", "AST", "t_AST", "=", "null", ";", "Token", "id", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "AST", "exp_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "boolean", "spreadParam", "=", "false", ";", "parameterModifiersOpt", "(", ")", ";", "pm_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "if", "(", "(", "_tokenSet_25", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_70", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "typeSpec", "(", "false", ")", ";", "t_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", "||", "LA", "(", "1", ")", "==", "TRIPLE_DOT", ")", "&&", "(", "_tokenSet_71", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "TRIPLE_DOT", ":", "{", "match", "(", "TRIPLE_DOT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "spreadParam", "=", "true", ";", "}", "break", ";", "}", "case", "IDENT", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "id", "=", "LT", "(", "1", ")", ";", "id_AST", "=", "astFactory", ".", "create", "(", "id", ")", ";", "match", "(", "IDENT", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "ASSIGN", ":", "{", "varInitializer", "(", ")", ";", "exp_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "COMMA", ":", "case", "RPAREN", ":", "case", "CLOSABLE_BLOCK_OP", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "parameterDeclaration_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "spreadParam", ")", "{", "parameterDeclaration_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "5", ")", ")", ".", "add", "(", "create", "(", "VARIABLE_PARAMETER_DEF", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "pm_AST", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "t_AST", ")", ")", ")", ".", "add", "(", "id_AST", ")", ".", "add", "(", "exp_AST", ")", ")", ";", "}", "else", "{", "parameterDeclaration_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "5", ")", ")", ".", "add", "(", "create", "(", "PARAMETER_DEF", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "pm_AST", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "t_AST", ")", ")", ")", ".", "add", "(", "id_AST", ")", ".", "add", "(", "exp_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "parameterDeclaration_AST", ";", "currentAST", ".", "child", "=", "parameterDeclaration_AST", "!=", "null", "&&", "parameterDeclaration_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "parameterDeclaration_AST", ".", "getFirstChild", "(", ")", ":", "parameterDeclaration_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "parameterDeclaration_AST", ";", "}", "public", "final", "void", "parameterModifiersOpt", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "parameterModifiersOpt_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "int", "seenDef", "=", "0", ";", "{", "_loop261", ":", "do", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "{", "AST", "tmp220_AST", "=", "null", ";", "tmp220_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp220_AST", ")", ";", "match", "(", "FINAL", ")", ";", "nls", "(", ")", ";", "break", ";", "}", "case", "AT", ":", "{", "annotation", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "nls", "(", ")", ";", "break", ";", "}", "default", ":", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_def", ")", ")", "&&", "(", "seenDef", "++", "==", "0", ")", ")", "{", "match", "(", "LITERAL_def", ")", ";", "nls", "(", ")", ";", "}", "else", "{", "break", "_loop261", ";", "}", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "parameterModifiersOpt_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "parameterModifiersOpt_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "MODIFIERS", ",", "\"MODIFIERS\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "parameterModifiersOpt_AST", ")", ")", ";", "currentAST", ".", "root", "=", "parameterModifiersOpt_AST", ";", "currentAST", ".", "child", "=", "parameterModifiersOpt_AST", "!=", "null", "&&", "parameterModifiersOpt_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "parameterModifiersOpt_AST", ".", "getFirstChild", "(", ")", ":", "parameterModifiersOpt_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "parameterModifiersOpt_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "parameterModifiersOpt_AST", ";", "}", "public", "final", "void", "closableBlockParamsOpt", "(", "boolean", "addImplicit", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "closableBlockParamsOpt_AST", "=", "null", ";", "boolean", "synPredMatched264", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_72", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_73", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m264", "=", "mark", "(", ")", ";", "synPredMatched264", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "parameterDeclarationList", "(", ")", ";", "nls", "(", ")", ";", "match", "(", "CLOSABLE_BLOCK_OP", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched264", "=", "false", ";", "}", "rewind", "(", "_m264", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched264", ")", "{", "parameterDeclarationList", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "nls", "(", ")", ";", "match", "(", "CLOSABLE_BLOCK_OP", ")", ";", "nls", "(", ")", ";", "closableBlockParamsOpt_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "(", "_tokenSet_31", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_74", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "&&", "(", "addImplicit", ")", ")", "{", "implicitParameters", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "closableBlockParamsOpt_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "_tokenSet_31", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_74", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "closableBlockParamsOpt_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "returnAST", "=", "closableBlockParamsOpt_AST", ";", "}", "public", "final", "void", "implicitParameters", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "implicitParameters_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "implicitParameters_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "implicitParameters_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "1", ")", ")", ".", "add", "(", "create", "(", "IMPLICIT_PARAMETERS", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ")", ";", "currentAST", ".", "root", "=", "implicitParameters_AST", ";", "currentAST", ".", "child", "=", "implicitParameters_AST", "!=", "null", "&&", "implicitParameters_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "implicitParameters_AST", ".", "getFirstChild", "(", ")", ":", "implicitParameters_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "implicitParameters_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "implicitParameters_AST", ";", "}", "public", "final", "void", "closableBlockParamsStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "closableBlockParamsStart_AST", "=", "null", ";", "parameterDeclarationList", "(", ")", ";", "nls", "(", ")", ";", "AST", "tmp223_AST", "=", "null", ";", "tmp223_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "CLOSABLE_BLOCK_OP", ")", ";", "returnAST", "=", "closableBlockParamsStart_AST", ";", "}", "public", "final", "void", "closableBlockParam", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "closableBlockParam_AST", "=", "null", ";", "Token", "id", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "id", "=", "LT", "(", "1", ")", ";", "id_AST", "=", "astFactory", ".", "create", "(", "id", ")", ";", "match", "(", "IDENT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "closableBlockParam_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "closableBlockParam_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "PARAMETER_DEF", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "1", ")", ")", ".", "add", "(", "create", "(", "MODIFIERS", ",", "\"MODIFIERS\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ")", ")", ".", "add", "(", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "1", ")", ")", ".", "add", "(", "create", "(", "TYPE", ",", "\"TYPE\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ")", ")", ".", "add", "(", "id_AST", ")", ")", ";", "currentAST", ".", "root", "=", "closableBlockParam_AST", ";", "currentAST", ".", "child", "=", "closableBlockParam_AST", "!=", "null", "&&", "closableBlockParam_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "closableBlockParam_AST", ".", "getFirstChild", "(", ")", ":", "closableBlockParam_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "returnAST", "=", "closableBlockParam_AST", ";", "}", "public", "final", "void", "closableBlock", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "closableBlock_AST", "=", "null", ";", "AST", "cbp_AST", "=", "null", ";", "AST", "bb_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LCURLY", ")", ";", "nls", "(", ")", ";", "closableBlockParamsOpt", "(", "true", ")", ";", "cbp_AST", "=", "(", "AST", ")", "returnAST", ";", "blockBody", "(", "EOF", ")", ";", "bb_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "closableBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "closableBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "CLOSABLE_BLOCK", ",", "\"{\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "cbp_AST", ")", ".", "add", "(", "bb_AST", ")", ")", ";", "currentAST", ".", "root", "=", "closableBlock_AST", ";", "currentAST", ".", "child", "=", "closableBlock_AST", "!=", "null", "&&", "closableBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "closableBlock_AST", ".", "getFirstChild", "(", ")", ":", "closableBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "closableBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "closableBlock_AST", ";", "}", "public", "final", "void", "openOrClosableBlock", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "openOrClosableBlock_AST", "=", "null", ";", "AST", "cp_AST", "=", "null", ";", "AST", "bb_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LCURLY", ")", ";", "nls", "(", ")", ";", "closableBlockParamsOpt", "(", "false", ")", ";", "cp_AST", "=", "(", "AST", ")", "returnAST", ";", "blockBody", "(", "EOF", ")", ";", "bb_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RCURLY", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "openOrClosableBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "cp_AST", "==", "null", ")", "openOrClosableBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "SLIST", ",", "\"{\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "bb_AST", ")", ")", ";", "else", "openOrClosableBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "CLOSABLE_BLOCK", ",", "\"{\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "cp_AST", ")", ".", "add", "(", "bb_AST", ")", ")", ";", "currentAST", ".", "root", "=", "openOrClosableBlock_AST", ";", "currentAST", ".", "child", "=", "openOrClosableBlock_AST", "!=", "null", "&&", "openOrClosableBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "openOrClosableBlock_AST", ".", "getFirstChild", "(", ")", ":", "openOrClosableBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "openOrClosableBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "openOrClosableBlock_AST", ";", "}", "public", "final", "void", "statementLabelPrefix", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "statementLabelPrefix_AST", "=", "null", ";", "Token", "c", "=", "null", ";", "AST", "c_AST", "=", "null", ";", "AST", "tmp228_AST", "=", "null", ";", "tmp228_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp228_AST", ")", ";", "match", "(", "IDENT", ")", ";", "c", "=", "LT", "(", "1", ")", ";", "c_AST", "=", "astFactory", ".", "create", "(", "c", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "c_AST", ")", ";", "match", "(", "COLON", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "c_AST", ".", "setType", "(", "LABELED_STAT", ")", ";", "}", "nls", "(", ")", ";", "statementLabelPrefix_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "statementLabelPrefix_AST", ";", "}", "public", "final", "void", "expressionStatement", "(", "int", "prevToken", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "expressionStatement_AST", "=", "null", ";", "AST", "head_AST", "=", "null", ";", "AST", "cmd_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "boolean", "isPathExpr", "=", "false", ";", "{", "boolean", "synPredMatched327", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m327", "=", "mark", "(", ")", ";", "synPredMatched327", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "suspiciousExpressionStatementStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched327", "=", "false", ";", "}", "rewind", "(", "_m327", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched327", ")", "{", "checkSuspiciousExpressionStatement", "(", "prevToken", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "expression", "(", "LC_STMT", ")", ";", "head_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "isPathExpr", "=", "(", "head_AST", "==", "lastPathExpression", ")", ";", "}", "{", "if", "(", "(", "(", "_tokenSet_75", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_76", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "&&", "(", "isPathExpr", ")", ")", "{", "commandArguments", "(", "head_AST", ")", ";", "cmd_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "expressionStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "expressionStatement_AST", "=", "cmd_AST", ";", "currentAST", ".", "root", "=", "expressionStatement_AST", ";", "currentAST", ".", "child", "=", "expressionStatement_AST", "!=", "null", "&&", "expressionStatement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "expressionStatement_AST", ".", "getFirstChild", "(", ")", ":", "expressionStatement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "}", "else", "if", "(", "(", "_tokenSet_11", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_12", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "expressionStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "expressionStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "EXPR", ",", "\"EXPR\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "expressionStatement_AST", ")", ")", ";", "currentAST", ".", "root", "=", "expressionStatement_AST", ";", "currentAST", ".", "child", "=", "expressionStatement_AST", "!=", "null", "&&", "expressionStatement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "expressionStatement_AST", ".", "getFirstChild", "(", ")", ":", "expressionStatement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "expressionStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "expressionStatement_AST", ";", "}", "public", "final", "void", "assignmentLessExpression", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "assignmentLessExpression_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "conditionalExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "assignmentLessExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "assignmentLessExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "EXPR", ",", "\"EXPR\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "assignmentLessExpression_AST", ")", ")", ";", "currentAST", ".", "root", "=", "assignmentLessExpression_AST", ";", "currentAST", ".", "child", "=", "assignmentLessExpression_AST", "!=", "null", "&&", "assignmentLessExpression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "assignmentLessExpression_AST", ".", "getFirstChild", "(", ")", ":", "assignmentLessExpression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "assignmentLessExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "assignmentLessExpression_AST", ";", "}", "public", "final", "void", "compatibleBodyStatement", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "compatibleBodyStatement_AST", "=", "null", ";", "boolean", "synPredMatched316", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LCURLY", ")", "&&", "(", "_tokenSet_31", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m316", "=", "mark", "(", ")", ";", "synPredMatched316", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "LCURLY", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched316", "=", "false", ";", "}", "rewind", "(", "_m316", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched316", ")", "{", "compoundStatement", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "compatibleBodyStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "_tokenSet_19", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "statement", "(", "EOF", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "compatibleBodyStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "returnAST", "=", "compatibleBodyStatement_AST", ";", "}", "public", "final", "void", "forStatement", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "forStatement_AST", "=", "null", ";", "AST", "cl_AST", "=", "null", ";", "AST", "fic_AST", "=", "null", ";", "Token", "s", "=", "null", ";", "AST", "s_AST", "=", "null", ";", "AST", "forCbs_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LITERAL_for", ")", ";", "match", "(", "LPAREN", ")", ";", "{", "boolean", "synPredMatched303", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_77", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_78", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m303", "=", "mark", "(", ")", ";", "synPredMatched303", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SEMI", ":", "{", "match", "(", "SEMI", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "{", "strictContextExpression", "(", "true", ")", ";", "match", "(", "SEMI", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched303", "=", "false", ";", "}", "rewind", "(", "_m303", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched303", ")", "{", "closureList", "(", ")", ";", "cl_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "_tokenSet_16", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_79", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "forInClause", "(", ")", ";", "fic_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "match", "(", "RPAREN", ")", ";", "nls", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SEMI", ":", "{", "s", "=", "LT", "(", "1", ")", ";", "s_AST", "=", "astFactory", ".", "create", "(", "s", ")", ";", "match", "(", "SEMI", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_try", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "compatibleBodyStatement", "(", ")", ";", "forCbs_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "forStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "cl_AST", "!=", "null", ")", "{", "if", "(", "s_AST", "!=", "null", ")", "forStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_for", ",", "\"for\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "cl_AST", ")", ".", "add", "(", "s_AST", ")", ")", ";", "else", "forStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_for", ",", "\"for\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "cl_AST", ")", ".", "add", "(", "forCbs_AST", ")", ")", ";", "}", "else", "{", "if", "(", "s_AST", "!=", "null", ")", "forStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_for", ",", "\"for\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "fic_AST", ")", ".", "add", "(", "s_AST", ")", ")", ";", "else", "forStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_for", ",", "\"for\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "fic_AST", ")", ".", "add", "(", "forCbs_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "forStatement_AST", ";", "currentAST", ".", "child", "=", "forStatement_AST", "!=", "null", "&&", "forStatement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "forStatement_AST", ".", "getFirstChild", "(", ")", ":", "forStatement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "forStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "forStatement_AST", ";", "}", "public", "final", "boolean", "strictContextExpression", "(", "boolean", "allowDeclaration", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "boolean", "hasDeclaration", "=", "false", ";", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "strictContextExpression_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "boolean", "synPredMatched489", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_16", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_80", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m489", "=", "mark", "(", ")", ";", "synPredMatched489", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "if", "(", "!", "(", "allowDeclaration", ")", ")", "throw", "new", "SemanticException", "(", "\"\"", ")", ";", "declarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched489", "=", "false", ";", "}", "rewind", "(", "_m489", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched489", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "hasDeclaration", "=", "true", ";", "}", "singleDeclaration", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_38", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "expression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "LITERAL_return", "&&", "LA", "(", "1", ")", "<=", "LITERAL_assert", ")", ")", ")", "{", "branchStatement", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "AT", ")", "&&", "(", "LA", "(", "2", ")", "==", "IDENT", ")", ")", "{", "annotation", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "strictContextExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "strictContextExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "EXPR", ",", "\"EXPR\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "strictContextExpression_AST", ")", ")", ";", "currentAST", ".", "root", "=", "strictContextExpression_AST", ";", "currentAST", ".", "child", "=", "strictContextExpression_AST", "!=", "null", "&&", "strictContextExpression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "strictContextExpression_AST", ".", "getFirstChild", "(", ")", ":", "strictContextExpression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "strictContextExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "strictContextExpression_AST", ";", "return", "hasDeclaration", ";", "}", "public", "final", "void", "casesGroup", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "casesGroup_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "int", "_cnt339", "=", "0", ";", "_loop339", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_default", "||", "LA", "(", "1", ")", "==", "LITERAL_case", ")", ")", "{", "aCase", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "if", "(", "_cnt339", ">=", "1", ")", "{", "break", "_loop339", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "_cnt339", "++", ";", "}", "while", "(", "true", ")", ";", "}", "caseSList", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "casesGroup_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "casesGroup_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "CASE_GROUP", ",", "\"CASE_GROUP\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "casesGroup_AST", ")", ")", ";", "currentAST", ".", "root", "=", "casesGroup_AST", ";", "currentAST", ".", "child", "=", "casesGroup_AST", "!=", "null", "&&", "casesGroup_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "casesGroup_AST", ".", "getFirstChild", "(", ")", ":", "casesGroup_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "casesGroup_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "casesGroup_AST", ";", "}", "public", "final", "void", "tryBlock", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "tryBlock_AST", "=", "null", ";", "AST", "tryCs_AST", "=", "null", ";", "AST", "h_AST", "=", "null", ";", "AST", "fc_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "List", "catchNodes", "=", "new", "ArrayList", "(", ")", ";", "AST", "newHandler_AST", "=", "null", ";", "match", "(", "LITERAL_try", ")", ";", "nlsWarn", "(", ")", ";", "compoundStatement", "(", ")", ";", "tryCs_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "_loop356", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_catch", "||", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "LA", "(", "2", ")", "==", "LPAREN", "||", "LA", "(", "2", ")", "==", "LITERAL_catch", ")", ")", "&&", "(", "!", "(", "LA", "(", "1", ")", "==", "NLS", "&&", "LA", "(", "2", ")", "==", "LPAREN", ")", ")", ")", "{", "nls", "(", ")", ";", "handler", "(", ")", ";", "h_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "newHandler_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "null", ")", ".", "add", "(", "newHandler_AST", ")", ".", "add", "(", "h_AST", ")", ")", ";", "}", "}", "else", "{", "break", "_loop356", ";", "}", "}", "while", "(", "true", ")", ";", "}", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_finally", "||", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_81", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "nls", "(", ")", ";", "finallyClause", "(", ")", ";", "fc_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "_tokenSet_11", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_12", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "tryBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "tryBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "LITERAL_try", ",", "\"try\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "tryCs_AST", ")", ".", "add", "(", "newHandler_AST", ")", ".", "add", "(", "fc_AST", ")", ")", ";", "currentAST", ".", "root", "=", "tryBlock_AST", ";", "currentAST", ".", "child", "=", "tryBlock_AST", "!=", "null", "&&", "tryBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "tryBlock_AST", ".", "getFirstChild", "(", ")", ":", "tryBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "tryBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "tryBlock_AST", ";", "}", "public", "final", "void", "branchStatement", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "branchStatement_AST", "=", "null", ";", "AST", "returnE_AST", "=", "null", ";", "Token", "breakI", "=", "null", ";", "AST", "breakI_AST", "=", "null", ";", "Token", "contI", "=", "null", ";", "AST", "contI_AST", "=", "null", ";", "AST", "throwE_AST", "=", "null", ";", "AST", "assertAle_AST", "=", "null", ";", "AST", "assertE_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_return", ":", "{", "match", "(", "LITERAL_return", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "expression", "(", "0", ")", ";", "returnE_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "EOF", ":", "case", "RBRACK", ":", "case", "COMMA", ":", "case", "RPAREN", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_else", ":", "case", "LITERAL_case", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "branchStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create2", "(", "LITERAL_return", ",", "\"return\"", ",", "first", ",", "LT", "(", "0", ")", ")", ")", ".", "add", "(", "returnE_AST", ")", ")", ";", "currentAST", ".", "root", "=", "branchStatement_AST", ";", "currentAST", ".", "child", "=", "branchStatement_AST", "!=", "null", "&&", "branchStatement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "branchStatement_AST", ".", "getFirstChild", "(", ")", ":", "branchStatement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_break", ":", "{", "match", "(", "LITERAL_break", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "breakI", "=", "LT", "(", "1", ")", ";", "breakI_AST", "=", "astFactory", ".", "create", "(", "breakI", ")", ";", "match", "(", "IDENT", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "RBRACK", ":", "case", "COMMA", ":", "case", "RPAREN", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_else", ":", "case", "LITERAL_case", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "branchStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "LITERAL_break", ",", "\"break\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "breakI_AST", ")", ")", ";", "currentAST", ".", "root", "=", "branchStatement_AST", ";", "currentAST", ".", "child", "=", "branchStatement_AST", "!=", "null", "&&", "branchStatement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "branchStatement_AST", ".", "getFirstChild", "(", ")", ":", "branchStatement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_continue", ":", "{", "match", "(", "LITERAL_continue", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "contI", "=", "LT", "(", "1", ")", ";", "contI_AST", "=", "astFactory", ".", "create", "(", "contI", ")", ";", "match", "(", "IDENT", ")", ";", "break", ";", "}", "case", "EOF", ":", "case", "RBRACK", ":", "case", "COMMA", ":", "case", "RPAREN", ":", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_else", ":", "case", "LITERAL_case", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "branchStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "LITERAL_continue", ",", "\"continue\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "contI_AST", ")", ")", ";", "currentAST", ".", "root", "=", "branchStatement_AST", ";", "currentAST", ".", "child", "=", "branchStatement_AST", "!=", "null", "&&", "branchStatement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "branchStatement_AST", ".", "getFirstChild", "(", ")", ":", "branchStatement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_throw", ":", "{", "match", "(", "LITERAL_throw", ")", ";", "expression", "(", "0", ")", ";", "throwE_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "branchStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "LITERAL_throw", ",", "\"throw\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "throwE_AST", ")", ")", ";", "currentAST", ".", "root", "=", "branchStatement_AST", ";", "currentAST", ".", "child", "=", "branchStatement_AST", "!=", "null", "&&", "branchStatement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "branchStatement_AST", ".", "getFirstChild", "(", ")", ":", "branchStatement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_assert", ":", "{", "match", "(", "LITERAL_assert", ")", ";", "assignmentLessExpression", "(", ")", ";", "assertAle_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", "||", "LA", "(", "1", ")", "==", "COLON", ")", "&&", "(", "_tokenSet_82", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "COMMA", ":", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "break", ";", "}", "case", "COLON", ":", "{", "match", "(", "COLON", ")", ";", "nls", "(", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "expression", "(", "0", ")", ";", "assertE_AST", "=", "(", "AST", ")", "returnAST", ";", "}", "else", "if", "(", "(", "_tokenSet_83", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_12", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "branchStatement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_assert", ",", "\"assert\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "assertAle_AST", ")", ".", "add", "(", "assertE_AST", ")", ")", ";", "currentAST", ".", "root", "=", "branchStatement_AST", ";", "currentAST", ".", "child", "=", "branchStatement_AST", "!=", "null", "&&", "branchStatement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "branchStatement_AST", ".", "getFirstChild", "(", ")", ":", "branchStatement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "branchStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "branchStatement_AST", ";", "}", "public", "final", "void", "closureList", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "closureList_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "boolean", "sce", "=", "false", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "sce", "=", "strictContextExpression", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "SEMI", ":", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "astFactory", ".", "create", "(", "EMPTY_STAT", ",", "\"EMPTY_STAT\"", ")", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "int", "_cnt308", "=", "0", ";", "_loop308", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", ")", "&&", "(", "_tokenSet_84", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "match", "(", "SEMI", ")", ";", "sce", "=", "strictContextExpression", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", ")", "&&", "(", "LA", "(", "2", ")", "==", "RPAREN", "||", "LA", "(", "2", ")", "==", "SEMI", ")", ")", "{", "match", "(", "SEMI", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "astFactory", ".", "create", "(", "EMPTY_STAT", ",", "\"EMPTY_STAT\"", ")", ")", ";", "}", "}", "else", "{", "if", "(", "_cnt308", ">=", "1", ")", "{", "break", "_loop308", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "_cnt308", "++", ";", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "closureList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "closureList_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "CLOSURE_LIST", ",", "\"CLOSURE_LIST\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "closureList_AST", ")", ")", ";", "currentAST", ".", "root", "=", "closureList_AST", ";", "currentAST", ".", "child", "=", "closureList_AST", "!=", "null", "&&", "closureList_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "closureList_AST", ".", "getFirstChild", "(", ")", ":", "closureList_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "closureList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "closureList_AST", ";", "}", "public", "final", "void", "forInClause", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "forInClause_AST", "=", "null", ";", "AST", "decl_AST", "=", "null", ";", "Token", "i", "=", "null", ";", "AST", "i_AST", "=", "null", ";", "Token", "c", "=", "null", ";", "AST", "c_AST", "=", "null", ";", "{", "boolean", "synPredMatched312", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_16", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_80", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m312", "=", "mark", "(", ")", ";", "synPredMatched312", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "declarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched312", "=", "false", ";", "}", "rewind", "(", "_m312", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched312", ")", "{", "singleDeclarationNoInit", "(", ")", ";", "decl_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "LA", "(", "2", ")", "==", "COLON", "||", "LA", "(", "2", ")", "==", "LITERAL_in", ")", ")", "{", "AST", "tmp242_AST", "=", "null", ";", "tmp242_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp242_AST", ")", ";", "match", "(", "IDENT", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_in", ":", "{", "i", "=", "LT", "(", "1", ")", ";", "i_AST", "=", "astFactory", ".", "create", "(", "i", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "i_AST", ")", ";", "match", "(", "LITERAL_in", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "i_AST", ".", "setType", "(", "FOR_IN_ITERABLE", ")", ";", "}", "shiftExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "COLON", ":", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "addWarning", "(", "\"\"", ",", "\"\"", ")", ";", "require", "(", "decl_AST", "!=", "null", ",", "\"\"", ",", "\"\"", ")", ";", "}", "c", "=", "LT", "(", "1", ")", ";", "c_AST", "=", "astFactory", ".", "create", "(", "c", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "c_AST", ")", ";", "match", "(", "COLON", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "c_AST", ".", "setType", "(", "FOR_IN_ITERABLE", ")", ";", "}", "expression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "forInClause_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "forInClause_AST", ";", "}", "public", "final", "void", "shiftExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "shiftExpression_AST", "=", "null", ";", "additiveExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop440", ":", "do", "{", "if", "(", "(", "_tokenSet_85", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SR", ":", "case", "BSR", ":", "case", "SL", ":", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SL", ":", "{", "AST", "tmp243_AST", "=", "null", ";", "tmp243_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp243_AST", ")", ";", "match", "(", "SL", ")", ";", "break", ";", "}", "case", "SR", ":", "{", "AST", "tmp244_AST", "=", "null", ";", "tmp244_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp244_AST", ")", ";", "match", "(", "SR", ")", ";", "break", ";", "}", "case", "BSR", ":", "{", "AST", "tmp245_AST", "=", "null", ";", "tmp245_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp245_AST", ")", ";", "match", "(", "BSR", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "break", ";", "}", "case", "RANGE_INCLUSIVE", ":", "{", "AST", "tmp246_AST", "=", "null", ";", "tmp246_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp246_AST", ")", ";", "match", "(", "RANGE_INCLUSIVE", ")", ";", "break", ";", "}", "case", "RANGE_EXCLUSIVE", ":", "{", "AST", "tmp247_AST", "=", "null", ";", "tmp247_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp247_AST", ")", ";", "match", "(", "RANGE_EXCLUSIVE", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "additiveExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop440", ";", "}", "}", "while", "(", "true", ")", ";", "}", "shiftExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "shiftExpression_AST", ";", "}", "public", "final", "void", "suspiciousExpressionStatementStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "suspiciousExpressionStatementStart_AST", "=", "null", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "PLUS", ":", "case", "MINUS", ":", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "PLUS", ":", "{", "AST", "tmp248_AST", "=", "null", ";", "tmp248_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp248_AST", ")", ";", "match", "(", "PLUS", ")", ";", "break", ";", "}", "case", "MINUS", ":", "{", "AST", "tmp249_AST", "=", "null", ";", "tmp249_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp249_AST", ")", ";", "match", "(", "MINUS", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "break", ";", "}", "case", "LBRACK", ":", "case", "LPAREN", ":", "case", "LCURLY", ":", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LBRACK", ":", "{", "AST", "tmp250_AST", "=", "null", ";", "tmp250_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp250_AST", ")", ";", "match", "(", "LBRACK", ")", ";", "break", ";", "}", "case", "LPAREN", ":", "{", "AST", "tmp251_AST", "=", "null", ";", "tmp251_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp251_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "break", ";", "}", "case", "LCURLY", ":", "{", "AST", "tmp252_AST", "=", "null", ";", "tmp252_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp252_AST", ")", ";", "match", "(", "LCURLY", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "suspiciousExpressionStatementStart_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "suspiciousExpressionStatementStart_AST", ";", "}", "public", "final", "void", "checkSuspiciousExpressionStatement", "(", "int", "prevToken", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "checkSuspiciousExpressionStatement_AST", "=", "null", ";", "boolean", "synPredMatched331", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m331", "=", "mark", "(", ")", ";", "synPredMatched331", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "if", "(", "(", "_tokenSet_86", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "matchNot", "(", "LCURLY", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "LCURLY", ")", ")", "{", "match", "(", "LCURLY", ")", ";", "closableBlockParamsStart", "(", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched331", "=", "false", ";", "}", "rewind", "(", "_m331", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched331", ")", "{", "{", "if", "(", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "&&", "(", "prevToken", "==", "NLS", ")", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "addWarning", "(", "\"\"", ",", "\"\"", ")", ";", "}", "}", "else", "if", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "checkSuspiciousExpressionStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "&&", "(", "prevToken", "==", "NLS", ")", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "require", "(", "false", ",", "\"\"", "+", "\"\"", ",", "\"\"", "+", "\"\"", "+", "\"\"", ")", ";", "}", "checkSuspiciousExpressionStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "&&", "(", "prevToken", "!=", "NLS", ")", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "require", "(", "false", ",", "\"\"", "+", "\"\"", ",", "\"\"", "+", "\"\"", ")", ";", "}", "checkSuspiciousExpressionStatement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "returnAST", "=", "checkSuspiciousExpressionStatement_AST", ";", "}", "public", "final", "void", "commandArguments", "(", "AST", "head", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "commandArguments_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "int", "hls", "=", "0", ";", "commandArgument", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop362", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "commandArgument", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop362", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "commandArguments_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "AST", "elist", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "ELIST", ",", "\"ELIST\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "commandArguments_AST", ")", ")", ";", "AST", "headid", "=", "getASTFactory", "(", ")", ".", "dup", "(", "head", ")", ";", "headid", ".", "setType", "(", "METHOD_CALL", ")", ";", "headid", ".", "setText", "(", "\"<command>\"", ")", ";", "commandArguments_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "headid", ")", ".", "add", "(", "head", ")", ".", "add", "(", "elist", ")", ")", ";", "currentAST", ".", "root", "=", "commandArguments_AST", ";", "currentAST", ".", "child", "=", "commandArguments_AST", "!=", "null", "&&", "commandArguments_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "commandArguments_AST", ".", "getFirstChild", "(", ")", ":", "commandArguments_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "commandArguments_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "commandArguments_AST", ";", "}", "public", "final", "void", "aCase", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "aCase_AST", "=", "null", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LITERAL_case", ":", "{", "AST", "tmp254_AST", "=", "null", ";", "tmp254_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp254_AST", ")", ";", "match", "(", "LITERAL_case", ")", ";", "expression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "LITERAL_default", ":", "{", "AST", "tmp255_AST", "=", "null", ";", "tmp255_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp255_AST", ")", ";", "match", "(", "LITERAL_default", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "match", "(", "COLON", ")", ";", "nls", "(", ")", ";", "aCase_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "aCase_AST", ";", "}", "public", "final", "void", "caseSList", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "caseSList_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "statement", "(", "COLON", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop345", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", "||", "LA", "(", "1", ")", "==", "NLS", ")", ")", "{", "sep", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_if", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_try", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "statement", "(", "sepToken", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RCURLY", ":", "case", "SEMI", ":", "case", "LITERAL_default", ":", "case", "LITERAL_case", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop345", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "caseSList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "caseSList_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "SLIST", ",", "\"SLIST\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "caseSList_AST", ")", ")", ";", "currentAST", ".", "root", "=", "caseSList_AST", ";", "currentAST", ".", "child", "=", "caseSList_AST", "!=", "null", "&&", "caseSList_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "caseSList_AST", ".", "getFirstChild", "(", ")", ":", "caseSList_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "caseSList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "caseSList_AST", ";", "}", "public", "final", "void", "forInit", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "forInit_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "boolean", "synPredMatched348", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_16", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_17", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m348", "=", "mark", "(", ")", ";", "synPredMatched348", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "declarationStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched348", "=", "false", ";", "}", "rewind", "(", "_m348", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched348", ")", "{", "declaration", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "forInit_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "_tokenSet_87", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_76", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "controlExpressionList", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "forInit_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "forInit_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "FOR_INIT", ",", "\"FOR_INIT\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "forInit_AST", ")", ")", ";", "currentAST", ".", "root", "=", "forInit_AST", ";", "currentAST", ".", "child", "=", "forInit_AST", "!=", "null", "&&", "forInit_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "forInit_AST", ".", "getFirstChild", "(", ")", ":", "forInit_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "forInit_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "returnAST", "=", "forInit_AST", ";", "}", "public", "final", "void", "controlExpressionList", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "controlExpressionList_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "boolean", "sce", "=", "false", ";", "sce", "=", "strictContextExpression", "(", "false", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop377", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "COMMA", ")", ")", "{", "match", "(", "COMMA", ")", ";", "nls", "(", ")", ";", "sce", "=", "strictContextExpression", "(", "false", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop377", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "controlExpressionList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "controlExpressionList_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "ELIST", ",", "\"ELIST\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "controlExpressionList_AST", ")", ")", ";", "currentAST", ".", "root", "=", "controlExpressionList_AST", ";", "currentAST", ".", "child", "=", "controlExpressionList_AST", "!=", "null", "&&", "controlExpressionList_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "controlExpressionList_AST", ".", "getFirstChild", "(", ")", ":", "controlExpressionList_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "controlExpressionList_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "controlExpressionList_AST", ";", "}", "public", "final", "void", "forCond", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "forCond_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "boolean", "sce", "=", "false", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "sce", "=", "strictContextExpression", "(", "false", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "forCond_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "forCond_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "FOR_CONDITION", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "forCond_AST", ")", ")", ";", "currentAST", ".", "root", "=", "forCond_AST", ";", "currentAST", ".", "child", "=", "forCond_AST", "!=", "null", "&&", "forCond_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "forCond_AST", ".", "getFirstChild", "(", ")", ":", "forCond_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "forCond_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "forCond_AST", ";", "}", "public", "final", "void", "forIter", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "forIter_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "controlExpressionList", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "EOF", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "forIter_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "forIter_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "FOR_ITERATOR", ",", "\"FOR_ITERATOR\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "forIter_AST", ")", ")", ";", "currentAST", ".", "root", "=", "forIter_AST", ";", "currentAST", ".", "child", "=", "forIter_AST", "!=", "null", "&&", "forIter_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "forIter_AST", ".", "getFirstChild", "(", ")", ":", "forIter_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "forIter_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "forIter_AST", ";", "}", "public", "final", "void", "handler", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "handler_AST", "=", "null", ";", "AST", "pd_AST", "=", "null", ";", "AST", "handlerCs_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LITERAL_catch", ")", ";", "match", "(", "LPAREN", ")", ";", "parameterDeclaration", "(", ")", ";", "pd_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "nlsWarn", "(", ")", ";", "compoundStatement", "(", ")", ";", "handlerCs_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "handler_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "handler_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_catch", ",", "\"catch\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "pd_AST", ")", ".", "add", "(", "handlerCs_AST", ")", ")", ";", "currentAST", ".", "root", "=", "handler_AST", ";", "currentAST", ".", "child", "=", "handler_AST", "!=", "null", "&&", "handler_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "handler_AST", ".", "getFirstChild", "(", ")", ":", "handler_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "handler_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "handler_AST", ";", "}", "public", "final", "void", "finallyClause", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "finallyClause_AST", "=", "null", ";", "AST", "finallyCs_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "match", "(", "LITERAL_finally", ")", ";", "nlsWarn", "(", ")", ";", "compoundStatement", "(", ")", ";", "finallyCs_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "finallyClause_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "finallyClause_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "LITERAL_finally", ",", "\"finally\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "finallyCs_AST", ")", ")", ";", "currentAST", ".", "root", "=", "finallyClause_AST", ";", "currentAST", ".", "child", "=", "finallyClause_AST", "!=", "null", "&&", "finallyClause_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "finallyClause_AST", ".", "getFirstChild", "(", ")", ":", "finallyClause_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "finallyClause_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "finallyClause_AST", ";", "}", "public", "final", "void", "commandArgument", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "commandArgument_AST", "=", "null", ";", "Token", "c", "=", "null", ";", "AST", "c_AST", "=", "null", ";", "boolean", "synPredMatched365", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_88", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_89", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m365", "=", "mark", "(", ")", ";", "synPredMatched365", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "argumentLabel", "(", ")", ";", "match", "(", "COLON", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched365", "=", "false", ";", "}", "rewind", "(", "_m365", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched365", ")", "{", "{", "argumentLabel", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "c", "=", "LT", "(", "1", ")", ";", "c_AST", "=", "astFactory", ".", "create", "(", "c", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "c_AST", ")", ";", "match", "(", "COLON", ")", ";", "expression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "c_AST", ".", "setType", "(", "LABELED_ARG", ")", ";", "}", "}", "commandArgument_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "_tokenSet_20", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_76", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "expression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "commandArgument_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "returnAST", "=", "commandArgument_AST", ";", "}", "public", "final", "void", "argumentLabel", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "argumentLabel_AST", "=", "null", ";", "Token", "id", "=", "null", ";", "AST", "id_AST", "=", "null", ";", "AST", "kw_AST", "=", "null", ";", "boolean", "synPredMatched525", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "IDENT", ")", "&&", "(", "LA", "(", "2", ")", "==", "COLON", ")", ")", ")", "{", "int", "_m525", "=", "mark", "(", ")", ";", "synPredMatched525", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "IDENT", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched525", "=", "false", ";", "}", "rewind", "(", "_m525", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched525", ")", "{", "id", "=", "LT", "(", "1", ")", ";", "id_AST", "=", "astFactory", ".", "create", "(", "id", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "id_AST", ")", ";", "match", "(", "IDENT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "id_AST", ".", "setType", "(", "STRING_LITERAL", ")", ";", "}", "argumentLabel_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "boolean", "synPredMatched527", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_90", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "LA", "(", "2", ")", "==", "COLON", ")", ")", ")", "{", "int", "_m527", "=", "mark", "(", ")", ";", "synPredMatched527", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "keywordPropertyNames", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched527", "=", "false", ";", "}", "rewind", "(", "_m527", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched527", ")", "{", "keywordPropertyNames", "(", ")", ";", "kw_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "kw_AST", ".", "setType", "(", "STRING_LITERAL", ")", ";", "}", "argumentLabel_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "_tokenSet_91", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_89", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "primaryExpression", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "argumentLabel_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "argumentLabel_AST", ";", "}", "public", "final", "void", "multipleAssignment", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "multipleAssignment_AST", "=", "null", ";", "Token", "first", "=", "cloneToken", "(", "LT", "(", "1", ")", ")", ";", "AST", "tmp262_AST", "=", "null", ";", "tmp262_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp262_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "nls", "(", ")", ";", "listOfVariables", "(", "null", ",", "null", ",", "first", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "match", "(", "RPAREN", ")", ";", "AST", "tmp264_AST", "=", "null", ";", "tmp264_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp264_AST", ")", ";", "match", "(", "ASSIGN", ")", ";", "nls", "(", ")", ";", "assignmentExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "multipleAssignment_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "multipleAssignment_AST", ";", "}", "public", "final", "void", "pathExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "pathExpression_AST", "=", "null", ";", "AST", "pre_AST", "=", "null", ";", "AST", "pe_AST", "=", "null", ";", "AST", "apb_AST", "=", "null", ";", "AST", "prefix", "=", "null", ";", "primaryExpression", "(", ")", ";", "pre_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "prefix", "=", "pre_AST", ";", "}", "{", "_loop385", ":", "do", "{", "boolean", "synPredMatched381", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_92", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_93", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m381", "=", "mark", "(", ")", ";", "synPredMatched381", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "pathElementStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched381", "=", "false", ";", "}", "rewind", "(", "_m381", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched381", ")", "{", "nls", "(", ")", ";", "pathElement", "(", "prefix", ")", ";", "pe_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "prefix", "=", "pe_AST", ";", "}", "}", "else", "{", "boolean", "synPredMatched383", "=", "false", ";", "if", "(", "(", "(", "(", "LA", "(", "1", ")", "==", "LCURLY", "||", "LA", "(", "1", ")", "==", "NLS", ")", "&&", "(", "_tokenSet_18", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "&&", "(", "lc_stmt", "==", "LC_STMT", "||", "lc_stmt", "==", "LC_INIT", ")", ")", ")", "{", "int", "_m383", "=", "mark", "(", ")", ";", "synPredMatched383", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "nls", "(", ")", ";", "match", "(", "LCURLY", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched383", "=", "false", ";", "}", "rewind", "(", "_m383", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched383", ")", "{", "nlsWarn", "(", ")", ";", "appendedBlock", "(", "prefix", ")", ";", "apb_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "prefix", "=", "apb_AST", ";", "}", "}", "else", "if", "(", "(", "_tokenSet_94", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_95", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "DOT", ":", "{", "match", "(", "DOT", ")", ";", "break", ";", "}", "case", "SPREAD_DOT", ":", "{", "match", "(", "SPREAD_DOT", ")", ";", "break", ";", "}", "case", "OPTIONAL_DOT", ":", "{", "AST", "tmp267_AST", "=", "null", ";", "tmp267_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp267_AST", ")", ";", "match", "(", "OPTIONAL_DOT", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "reportError", "(", "\"\"", ")", ";", "}", "}", "else", "{", "break", "_loop385", ";", "}", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "pathExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "pathExpression_AST", "=", "prefix", ";", "lastPathExpression", "=", "pathExpression_AST", ";", "currentAST", ".", "root", "=", "pathExpression_AST", ";", "currentAST", ".", "child", "=", "pathExpression_AST", "!=", "null", "&&", "pathExpression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "pathExpression_AST", ".", "getFirstChild", "(", ")", ":", "pathExpression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "pathExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "pathExpression_AST", ";", "}", "public", "final", "void", "primaryExpression", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "primaryExpression_AST", "=", "null", ";", "AST", "pe_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "AST", "tmp268_AST", "=", "null", ";", "tmp268_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp268_AST", ")", ";", "match", "(", "IDENT", ")", ";", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "STRING_LITERAL", ":", "case", "LITERAL_false", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "constant", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_new", ":", "{", "newExpression", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_this", ":", "{", "AST", "tmp269_AST", "=", "null", ";", "tmp269_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp269_AST", ")", ";", "match", "(", "LITERAL_this", ")", ";", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_super", ":", "{", "AST", "tmp270_AST", "=", "null", ";", "tmp270_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp270_AST", ")", ";", "match", "(", "LITERAL_super", ")", ";", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LPAREN", ":", "{", "parenthesizedExpression", "(", ")", ";", "pe_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "primaryExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "EXPR", ",", "\"EXPR\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "pe_AST", ")", ")", ";", "currentAST", ".", "root", "=", "primaryExpression_AST", ";", "currentAST", ".", "child", "=", "primaryExpression_AST", "!=", "null", "&&", "primaryExpression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "primaryExpression_AST", ".", "getFirstChild", "(", ")", ":", "primaryExpression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LCURLY", ":", "{", "closableBlockConstructorExpression", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LBRACK", ":", "{", "listOrMapConstructorExpression", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "STRING_CTOR_START", ":", "{", "stringConstructorExpression", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "builtInType", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "primaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "primaryExpression_AST", ";", "}", "public", "final", "void", "pathElementStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "pathElementStart_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "DOT", ":", "case", "NLS", ":", "{", "{", "nls", "(", ")", ";", "AST", "tmp271_AST", "=", "null", ";", "tmp271_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "DOT", ")", ";", "}", "break", ";", "}", "case", "SPREAD_DOT", ":", "{", "AST", "tmp272_AST", "=", "null", ";", "tmp272_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "SPREAD_DOT", ")", ";", "break", ";", "}", "case", "OPTIONAL_DOT", ":", "{", "AST", "tmp273_AST", "=", "null", ";", "tmp273_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "OPTIONAL_DOT", ")", ";", "break", ";", "}", "case", "MEMBER_POINTER", ":", "{", "AST", "tmp274_AST", "=", "null", ";", "tmp274_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "MEMBER_POINTER", ")", ";", "break", ";", "}", "case", "LBRACK", ":", "{", "AST", "tmp275_AST", "=", "null", ";", "tmp275_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "LBRACK", ")", ";", "break", ";", "}", "case", "LPAREN", ":", "{", "AST", "tmp276_AST", "=", "null", ";", "tmp276_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "LPAREN", ")", ";", "break", ";", "}", "case", "LCURLY", ":", "{", "AST", "tmp277_AST", "=", "null", ";", "tmp277_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "LCURLY", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "pathElementStart_AST", ";", "}", "public", "final", "void", "pathElement", "(", "AST", "prefix", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "pathElement_AST", "=", "null", ";", "AST", "ta_AST", "=", "null", ";", "AST", "np_AST", "=", "null", ";", "AST", "mca_AST", "=", "null", ";", "AST", "apb_AST", "=", "null", ";", "AST", "ipa_AST", "=", "null", ";", "Token", "thisPart", "=", "null", ";", "AST", "thisPart_AST", "=", "null", ";", "Token", "operator", "=", "LT", "(", "1", ")", ";", "try", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LPAREN", ":", "{", "methodCallArgs", "(", "prefix", ")", ";", "mca_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "pathElement_AST", "=", "mca_AST", ";", "currentAST", ".", "root", "=", "pathElement_AST", ";", "currentAST", ".", "child", "=", "pathElement_AST", "!=", "null", "&&", "pathElement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "pathElement_AST", ".", "getFirstChild", "(", ")", ":", "pathElement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LCURLY", ":", "{", "appendedBlock", "(", "prefix", ")", ";", "apb_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "pathElement_AST", "=", "apb_AST", ";", "currentAST", ".", "root", "=", "pathElement_AST", ";", "currentAST", ".", "child", "=", "pathElement_AST", "!=", "null", "&&", "pathElement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "pathElement_AST", ".", "getFirstChild", "(", ")", ":", "pathElement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LBRACK", ":", "{", "indexPropertyArgs", "(", "prefix", ")", ";", "ipa_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "pathElement_AST", "=", "ipa_AST", ";", "currentAST", ".", "root", "=", "pathElement_AST", ";", "currentAST", ".", "child", "=", "pathElement_AST", "!=", "null", "&&", "pathElement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "pathElement_AST", ".", "getFirstChild", "(", ")", ":", "pathElement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "if", "(", "(", "_tokenSet_96", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_97", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "pathElement_AST", "=", "prefix", ";", "currentAST", ".", "root", "=", "pathElement_AST", ";", "currentAST", ".", "child", "=", "pathElement_AST", "!=", "null", "&&", "pathElement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "pathElement_AST", ".", "getFirstChild", "(", ")", ":", "pathElement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "SPREAD_DOT", ":", "{", "match", "(", "SPREAD_DOT", ")", ";", "break", ";", "}", "case", "OPTIONAL_DOT", ":", "{", "match", "(", "OPTIONAL_DOT", ")", ";", "break", ";", "}", "case", "MEMBER_POINTER", ":", "{", "match", "(", "MEMBER_POINTER", ")", ";", "break", ";", "}", "case", "DOT", ":", "case", "NLS", ":", "{", "{", "nls", "(", ")", ";", "match", "(", "DOT", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "typeArguments", "(", ")", ";", "ta_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "AT", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "STRING_CTOR_START", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "namePart", "(", ")", ";", "np_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "pathElement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "operator", ".", "getType", "(", ")", ",", "operator", ".", "getText", "(", ")", ",", "prefix", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "prefix", ")", ".", "add", "(", "ta_AST", ")", ".", "add", "(", "np_AST", ")", ")", ";", "currentAST", ".", "root", "=", "pathElement_AST", ";", "currentAST", ".", "child", "=", "pathElement_AST", "!=", "null", "&&", "pathElement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "pathElement_AST", ".", "getFirstChild", "(", ")", ":", "pathElement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "DOT", ")", "&&", "(", "LA", "(", "2", ")", "==", "LITERAL_this", "||", "LA", "(", "2", ")", "==", "NLS", ")", ")", "{", "match", "(", "DOT", ")", ";", "nls", "(", ")", ";", "thisPart", "=", "LT", "(", "1", ")", ";", "thisPart_AST", "=", "astFactory", ".", "create", "(", "thisPart", ")", ";", "match", "(", "LITERAL_this", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "pathElement_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "operator", ".", "getType", "(", ")", ",", "operator", ".", "getText", "(", ")", ",", "prefix", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "prefix", ")", ".", "add", "(", "thisPart_AST", ")", ")", ";", "currentAST", ".", "root", "=", "pathElement_AST", ";", "currentAST", ".", "child", "=", "pathElement_AST", "!=", "null", "&&", "pathElement_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "pathElement_AST", ".", "getFirstChild", "(", ")", ":", "pathElement_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "pathElement_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "catch", "(", "RecognitionException", "e", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "pathElement_AST", "==", "null", ")", "{", "throw", "e", ";", "}", "reportError", "(", "e", ")", ";", "}", "else", "{", "throw", "e", ";", "}", "}", "returnAST", "=", "pathElement_AST", ";", "}", "public", "final", "void", "appendedBlock", "(", "AST", "callee", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "appendedBlock_AST", "=", "null", ";", "AST", "cb_AST", "=", "null", ";", "closableBlock", "(", ")", ";", "cb_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "appendedBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "callee", "!=", "null", "&&", "callee", ".", "getType", "(", ")", "==", "METHOD_CALL", ")", "{", "appendedBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "METHOD_CALL", ",", "\"(\"", ",", "callee", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "callee", ".", "getFirstChild", "(", ")", ")", ".", "add", "(", "cb_AST", ")", ")", ";", "}", "else", "{", "appendedBlock_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "METHOD_CALL", ",", "\"{\"", ",", "callee", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "callee", ")", ".", "add", "(", "cb_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "appendedBlock_AST", ";", "currentAST", ".", "child", "=", "appendedBlock_AST", "!=", "null", "&&", "appendedBlock_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "appendedBlock_AST", ".", "getFirstChild", "(", ")", ":", "appendedBlock_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "appendedBlock_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "appendedBlock_AST", ";", "}", "public", "final", "void", "namePart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "namePart_AST", "=", "null", ";", "Token", "ats", "=", "null", ";", "AST", "ats_AST", "=", "null", ";", "Token", "sl", "=", "null", ";", "AST", "sl_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "AT", ":", "{", "ats", "=", "LT", "(", "1", ")", ";", "ats_AST", "=", "astFactory", ".", "create", "(", "ats", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "ats_AST", ")", ";", "match", "(", "AT", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "ats_AST", ".", "setType", "(", "SELECT_SLOT", ")", ";", "}", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "STRING_CTOR_START", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "AST", "tmp283_AST", "=", "null", ";", "tmp283_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp283_AST", ")", ";", "match", "(", "IDENT", ")", ";", "break", ";", "}", "case", "STRING_LITERAL", ":", "{", "sl", "=", "LT", "(", "1", ")", ";", "sl_AST", "=", "astFactory", ".", "create", "(", "sl", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "sl_AST", ")", ";", "match", "(", "STRING_LITERAL", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "sl_AST", ".", "setType", "(", "IDENT", ")", ";", "}", "break", ";", "}", "case", "LPAREN", ":", "case", "STRING_CTOR_START", ":", "{", "dynamicMemberName", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "LCURLY", ":", "{", "openBlock", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "{", "keywordPropertyNames", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "namePart_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "namePart_AST", ";", "}", "public", "final", "void", "methodCallArgs", "(", "AST", "callee", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "methodCallArgs_AST", "=", "null", ";", "AST", "al_AST", "=", "null", ";", "match", "(", "LPAREN", ")", ";", "argList", "(", ")", ";", "al_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RPAREN", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "methodCallArgs_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "callee", "!=", "null", "&&", "callee", ".", "getFirstChild", "(", ")", "!=", "null", ")", "{", "methodCallArgs_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "METHOD_CALL", ",", "\"(\"", ",", "callee", ".", "getFirstChild", "(", ")", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "callee", ")", ".", "add", "(", "al_AST", ")", ")", ";", "}", "else", "{", "methodCallArgs_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "METHOD_CALL", ",", "\"(\"", ",", "callee", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "callee", ")", ".", "add", "(", "al_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "methodCallArgs_AST", ";", "currentAST", ".", "child", "=", "methodCallArgs_AST", "!=", "null", "&&", "methodCallArgs_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "methodCallArgs_AST", ".", "getFirstChild", "(", ")", ":", "methodCallArgs_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "methodCallArgs_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "methodCallArgs_AST", ";", "}", "public", "final", "void", "indexPropertyArgs", "(", "AST", "indexee", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "indexPropertyArgs_AST", "=", "null", ";", "Token", "lb", "=", "null", ";", "AST", "lb_AST", "=", "null", ";", "AST", "al_AST", "=", "null", ";", "lb", "=", "LT", "(", "1", ")", ";", "lb_AST", "=", "astFactory", ".", "create", "(", "lb", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "lb_AST", ")", ";", "match", "(", "LBRACK", ")", ";", "argList", "(", ")", ";", "al_AST", "=", "(", "AST", ")", "returnAST", ";", "match", "(", "RBRACK", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "indexPropertyArgs_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "indexee", "!=", "null", "&&", "indexee", ".", "getFirstChild", "(", ")", "!=", "null", ")", "{", "indexPropertyArgs_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "INDEX_OP", ",", "\"INDEX_OP\"", ",", "indexee", ".", "getFirstChild", "(", ")", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "lb_AST", ")", ".", "add", "(", "indexee", ")", ".", "add", "(", "al_AST", ")", ")", ";", "}", "else", "{", "indexPropertyArgs_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "INDEX_OP", ",", "\"INDEX_OP\"", ",", "indexee", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "lb_AST", ")", ".", "add", "(", "indexee", ")", ".", "add", "(", "al_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "indexPropertyArgs_AST", ";", "currentAST", ".", "child", "=", "indexPropertyArgs_AST", "!=", "null", "&&", "indexPropertyArgs_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "indexPropertyArgs_AST", ".", "getFirstChild", "(", ")", ":", "indexPropertyArgs_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "indexPropertyArgs_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "indexPropertyArgs_AST", ";", "}", "public", "final", "void", "dynamicMemberName", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "dynamicMemberName_AST", "=", "null", ";", "AST", "pe_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LPAREN", ":", "{", "parenthesizedExpression", "(", ")", ";", "pe_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "dynamicMemberName_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "dynamicMemberName_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "EXPR", ",", "\"EXPR\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "pe_AST", ")", ")", ";", "currentAST", ".", "root", "=", "dynamicMemberName_AST", ";", "currentAST", ".", "child", "=", "dynamicMemberName_AST", "!=", "null", "&&", "dynamicMemberName_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "dynamicMemberName_AST", ".", "getFirstChild", "(", ")", ":", "dynamicMemberName_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "case", "STRING_CTOR_START", ":", "{", "stringConstructorExpression", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "dynamicMemberName_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "dynamicMemberName_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "DYNAMIC_MEMBER", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "dynamicMemberName_AST", ")", ")", ";", "currentAST", ".", "root", "=", "dynamicMemberName_AST", ";", "currentAST", ".", "child", "=", "dynamicMemberName_AST", "!=", "null", "&&", "dynamicMemberName_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "dynamicMemberName_AST", ".", "getFirstChild", "(", ")", ":", "dynamicMemberName_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "dynamicMemberName_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "dynamicMemberName_AST", ";", "}", "public", "final", "void", "parenthesizedExpression", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "parenthesizedExpression_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "Token", "declaration", "=", "null", ";", "boolean", "hasClosureList", "=", "false", ";", "boolean", "firstContainsDeclaration", "=", "false", ";", "boolean", "sce", "=", "false", ";", "match", "(", "LPAREN", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "declaration", "=", "LT", "(", "1", ")", ";", "}", "firstContainsDeclaration", "=", "strictContextExpression", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop485", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "SEMI", ")", ")", "{", "match", "(", "SEMI", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "hasClosureList", "=", "true", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "sce", "=", "strictContextExpression", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RPAREN", ":", "case", "SEMI", ":", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "astFactory", ".", "create", "(", "EMPTY_STAT", ",", "\"EMPTY_STAT\"", ")", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "{", "break", "_loop485", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "firstContainsDeclaration", "&&", "!", "hasClosureList", ")", "throw", "new", "NoViableAltException", "(", "declaration", ",", "getFilename", "(", ")", ")", ";", "}", "match", "(", "RPAREN", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "parenthesizedExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "if", "(", "hasClosureList", ")", "{", "parenthesizedExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "CLOSURE_LIST", ",", "\"CLOSURE_LIST\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "parenthesizedExpression_AST", ")", ")", ";", "}", "currentAST", ".", "root", "=", "parenthesizedExpression_AST", ";", "currentAST", ".", "child", "=", "parenthesizedExpression_AST", "!=", "null", "&&", "parenthesizedExpression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "parenthesizedExpression_AST", ".", "getFirstChild", "(", ")", ":", "parenthesizedExpression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "parenthesizedExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "parenthesizedExpression_AST", ";", "}", "public", "final", "void", "stringConstructorExpression", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "stringConstructorExpression_AST", "=", "null", ";", "Token", "cs", "=", "null", ";", "AST", "cs_AST", "=", "null", ";", "Token", "cm", "=", "null", ";", "AST", "cm_AST", "=", "null", ";", "Token", "ce", "=", "null", ";", "AST", "ce_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "cs", "=", "LT", "(", "1", ")", ";", "cs_AST", "=", "astFactory", ".", "create", "(", "cs", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "cs_AST", ")", ";", "match", "(", "STRING_CTOR_START", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "cs_AST", ".", "setType", "(", "STRING_LITERAL", ")", ";", "}", "stringConstructorValuePart", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop495", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "STRING_CTOR_MIDDLE", ")", ")", "{", "cm", "=", "LT", "(", "1", ")", ";", "cm_AST", "=", "astFactory", ".", "create", "(", "cm", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "cm_AST", ")", ";", "match", "(", "STRING_CTOR_MIDDLE", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "cm_AST", ".", "setType", "(", "STRING_LITERAL", ")", ";", "}", "stringConstructorValuePart", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop495", ";", "}", "}", "while", "(", "true", ")", ";", "}", "ce", "=", "LT", "(", "1", ")", ";", "ce_AST", "=", "astFactory", ".", "create", "(", "ce", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "ce_AST", ")", ";", "match", "(", "STRING_CTOR_END", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "stringConstructorExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "ce_AST", ".", "setType", "(", "STRING_LITERAL", ")", ";", "stringConstructorExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "STRING_CONSTRUCTOR", ",", "\"\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "stringConstructorExpression_AST", ")", ")", ";", "currentAST", ".", "root", "=", "stringConstructorExpression_AST", ";", "currentAST", ".", "child", "=", "stringConstructorExpression_AST", "!=", "null", "&&", "stringConstructorExpression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "stringConstructorExpression_AST", ".", "getFirstChild", "(", ")", ":", "stringConstructorExpression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "stringConstructorExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "stringConstructorExpression_AST", ";", "}", "public", "final", "void", "logicalOrExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "logicalOrExpression_AST", "=", "null", ";", "logicalAndExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop411", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LOR", ")", ")", "{", "AST", "tmp290_AST", "=", "null", ";", "tmp290_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp290_AST", ")", ";", "match", "(", "LOR", ")", ";", "nls", "(", ")", ";", "logicalAndExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop411", ";", "}", "}", "while", "(", "true", ")", ";", "}", "logicalOrExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "logicalOrExpression_AST", ";", "}", "public", "final", "void", "logicalAndExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "logicalAndExpression_AST", "=", "null", ";", "inclusiveOrExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop414", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LAND", ")", ")", "{", "AST", "tmp291_AST", "=", "null", ";", "tmp291_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp291_AST", ")", ";", "match", "(", "LAND", ")", ";", "nls", "(", ")", ";", "inclusiveOrExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop414", ";", "}", "}", "while", "(", "true", ")", ";", "}", "logicalAndExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "logicalAndExpression_AST", ";", "}", "public", "final", "void", "inclusiveOrExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "inclusiveOrExpression_AST", "=", "null", ";", "exclusiveOrExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop417", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "BOR", ")", ")", "{", "AST", "tmp292_AST", "=", "null", ";", "tmp292_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp292_AST", ")", ";", "match", "(", "BOR", ")", ";", "nls", "(", ")", ";", "exclusiveOrExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop417", ";", "}", "}", "while", "(", "true", ")", ";", "}", "inclusiveOrExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "inclusiveOrExpression_AST", ";", "}", "public", "final", "void", "exclusiveOrExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "exclusiveOrExpression_AST", "=", "null", ";", "andExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop420", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "BXOR", ")", ")", "{", "AST", "tmp293_AST", "=", "null", ";", "tmp293_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp293_AST", ")", ";", "match", "(", "BXOR", ")", ";", "nls", "(", ")", ";", "andExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop420", ";", "}", "}", "while", "(", "true", ")", ";", "}", "exclusiveOrExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "exclusiveOrExpression_AST", ";", "}", "public", "final", "void", "andExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "andExpression_AST", "=", "null", ";", "regexExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop423", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "BAND", ")", ")", "{", "AST", "tmp294_AST", "=", "null", ";", "tmp294_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp294_AST", ")", ";", "match", "(", "BAND", ")", ";", "nls", "(", ")", ";", "regexExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop423", ";", "}", "}", "while", "(", "true", ")", ";", "}", "andExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "andExpression_AST", ";", "}", "public", "final", "void", "regexExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "regexExpression_AST", "=", "null", ";", "equalityExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop427", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "REGEX_FIND", "||", "LA", "(", "1", ")", "==", "REGEX_MATCH", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "REGEX_FIND", ":", "{", "AST", "tmp295_AST", "=", "null", ";", "tmp295_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp295_AST", ")", ";", "match", "(", "REGEX_FIND", ")", ";", "break", ";", "}", "case", "REGEX_MATCH", ":", "{", "AST", "tmp296_AST", "=", "null", ";", "tmp296_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp296_AST", ")", ";", "match", "(", "REGEX_MATCH", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "equalityExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop427", ";", "}", "}", "while", "(", "true", ")", ";", "}", "regexExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "regexExpression_AST", ";", "}", "public", "final", "void", "equalityExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "equalityExpression_AST", "=", "null", ";", "relationalExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop431", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "NOT_EQUAL", "&&", "LA", "(", "1", ")", "<=", "COMPARE_TO", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "NOT_EQUAL", ":", "{", "AST", "tmp297_AST", "=", "null", ";", "tmp297_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp297_AST", ")", ";", "match", "(", "NOT_EQUAL", ")", ";", "break", ";", "}", "case", "EQUAL", ":", "{", "AST", "tmp298_AST", "=", "null", ";", "tmp298_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp298_AST", ")", ";", "match", "(", "EQUAL", ")", ";", "break", ";", "}", "case", "IDENTICAL", ":", "{", "AST", "tmp299_AST", "=", "null", ";", "tmp299_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp299_AST", ")", ";", "match", "(", "IDENTICAL", ")", ";", "break", ";", "}", "case", "NOT_IDENTICAL", ":", "{", "AST", "tmp300_AST", "=", "null", ";", "tmp300_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp300_AST", ")", ";", "match", "(", "NOT_IDENTICAL", ")", ";", "break", ";", "}", "case", "COMPARE_TO", ":", "{", "AST", "tmp301_AST", "=", "null", ";", "tmp301_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp301_AST", ")", ";", "match", "(", "COMPARE_TO", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "relationalExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop431", ";", "}", "}", "while", "(", "true", ")", ";", "}", "equalityExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "equalityExpression_AST", ";", "}", "public", "final", "void", "relationalExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "relationalExpression_AST", "=", "null", ";", "shiftExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "if", "(", "(", "_tokenSet_98", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_82", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "AST", "tmp302_AST", "=", "null", ";", "tmp302_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp302_AST", ")", ";", "match", "(", "LT", ")", ";", "break", ";", "}", "case", "GT", ":", "{", "AST", "tmp303_AST", "=", "null", ";", "tmp303_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp303_AST", ")", ";", "match", "(", "GT", ")", ";", "break", ";", "}", "case", "LE", ":", "{", "AST", "tmp304_AST", "=", "null", ";", "tmp304_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp304_AST", ")", ";", "match", "(", "LE", ")", ";", "break", ";", "}", "case", "GE", ":", "{", "AST", "tmp305_AST", "=", "null", ";", "tmp305_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp305_AST", ")", ";", "match", "(", "GE", ")", ";", "break", ";", "}", "case", "LITERAL_in", ":", "{", "AST", "tmp306_AST", "=", "null", ";", "tmp306_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp306_AST", ")", ";", "match", "(", "LITERAL_in", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "shiftExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_instanceof", ")", "&&", "(", "_tokenSet_99", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "AST", "tmp307_AST", "=", "null", ";", "tmp307_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp307_AST", ")", ";", "match", "(", "LITERAL_instanceof", ")", ";", "nls", "(", ")", ";", "typeSpec", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "LITERAL_as", ")", "&&", "(", "_tokenSet_99", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "AST", "tmp308_AST", "=", "null", ";", "tmp308_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp308_AST", ")", ";", "match", "(", "LITERAL_as", ")", ";", "nls", "(", ")", ";", "typeSpec", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_100", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_74", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "relationalExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "relationalExpression_AST", ";", "}", "public", "final", "void", "additiveExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "additiveExpression_AST", "=", "null", ";", "multiplicativeExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop444", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "PLUS", "||", "LA", "(", "1", ")", "==", "MINUS", ")", "&&", "(", "_tokenSet_82", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "PLUS", ":", "{", "AST", "tmp309_AST", "=", "null", ";", "tmp309_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp309_AST", ")", ";", "match", "(", "PLUS", ")", ";", "break", ";", "}", "case", "MINUS", ":", "{", "AST", "tmp310_AST", "=", "null", ";", "tmp310_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp310_AST", ")", ";", "match", "(", "MINUS", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "multiplicativeExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop444", ";", "}", "}", "while", "(", "true", ")", ";", "}", "additiveExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "additiveExpression_AST", ";", "}", "public", "final", "void", "multiplicativeExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "multiplicativeExpression_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "INC", ":", "{", "{", "AST", "tmp311_AST", "=", "null", ";", "tmp311_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp311_AST", ")", ";", "match", "(", "INC", ")", ";", "nls", "(", ")", ";", "powerExpressionNotPlusMinus", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop449", ":", "do", "{", "if", "(", "(", "_tokenSet_101", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "STAR", ":", "{", "AST", "tmp312_AST", "=", "null", ";", "tmp312_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp312_AST", ")", ";", "match", "(", "STAR", ")", ";", "break", ";", "}", "case", "DIV", ":", "{", "AST", "tmp313_AST", "=", "null", ";", "tmp313_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp313_AST", ")", ";", "match", "(", "DIV", ")", ";", "break", ";", "}", "case", "MOD", ":", "{", "AST", "tmp314_AST", "=", "null", ";", "tmp314_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp314_AST", ")", ";", "match", "(", "MOD", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "powerExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop449", ";", "}", "}", "while", "(", "true", ")", ";", "}", "}", "multiplicativeExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "DEC", ":", "{", "{", "AST", "tmp315_AST", "=", "null", ";", "tmp315_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp315_AST", ")", ";", "match", "(", "DEC", ")", ";", "nls", "(", ")", ";", "powerExpressionNotPlusMinus", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop453", ":", "do", "{", "if", "(", "(", "_tokenSet_101", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "STAR", ":", "{", "AST", "tmp316_AST", "=", "null", ";", "tmp316_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp316_AST", ")", ";", "match", "(", "STAR", ")", ";", "break", ";", "}", "case", "DIV", ":", "{", "AST", "tmp317_AST", "=", "null", ";", "tmp317_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp317_AST", ")", ";", "match", "(", "DIV", ")", ";", "break", ";", "}", "case", "MOD", ":", "{", "AST", "tmp318_AST", "=", "null", ";", "tmp318_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp318_AST", ")", ";", "match", "(", "MOD", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "powerExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop453", ";", "}", "}", "while", "(", "true", ")", ";", "}", "}", "multiplicativeExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "MINUS", ":", "{", "{", "AST", "tmp319_AST", "=", "null", ";", "tmp319_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp319_AST", ")", ";", "match", "(", "MINUS", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "tmp319_AST", ".", "setType", "(", "UNARY_MINUS", ")", ";", "}", "nls", "(", ")", ";", "powerExpressionNotPlusMinus", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop457", ":", "do", "{", "if", "(", "(", "_tokenSet_101", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "STAR", ":", "{", "AST", "tmp320_AST", "=", "null", ";", "tmp320_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp320_AST", ")", ";", "match", "(", "STAR", ")", ";", "break", ";", "}", "case", "DIV", ":", "{", "AST", "tmp321_AST", "=", "null", ";", "tmp321_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp321_AST", ")", ";", "match", "(", "DIV", ")", ";", "break", ";", "}", "case", "MOD", ":", "{", "AST", "tmp322_AST", "=", "null", ";", "tmp322_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp322_AST", ")", ";", "match", "(", "MOD", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "powerExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop457", ";", "}", "}", "while", "(", "true", ")", ";", "}", "}", "multiplicativeExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "PLUS", ":", "{", "{", "AST", "tmp323_AST", "=", "null", ";", "tmp323_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp323_AST", ")", ";", "match", "(", "PLUS", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "tmp323_AST", ".", "setType", "(", "UNARY_PLUS", ")", ";", "}", "nls", "(", ")", ";", "powerExpressionNotPlusMinus", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop461", ":", "do", "{", "if", "(", "(", "_tokenSet_101", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "STAR", ":", "{", "AST", "tmp324_AST", "=", "null", ";", "tmp324_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp324_AST", ")", ";", "match", "(", "STAR", ")", ";", "break", ";", "}", "case", "DIV", ":", "{", "AST", "tmp325_AST", "=", "null", ";", "tmp325_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp325_AST", ")", ";", "match", "(", "DIV", ")", ";", "break", ";", "}", "case", "MOD", ":", "{", "AST", "tmp326_AST", "=", "null", ";", "tmp326_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp326_AST", ")", ";", "match", "(", "MOD", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "powerExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop461", ";", "}", "}", "while", "(", "true", ")", ";", "}", "}", "multiplicativeExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "{", "powerExpressionNotPlusMinus", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop465", ":", "do", "{", "if", "(", "(", "_tokenSet_101", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "STAR", ":", "{", "AST", "tmp327_AST", "=", "null", ";", "tmp327_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp327_AST", ")", ";", "match", "(", "STAR", ")", ";", "break", ";", "}", "case", "DIV", ":", "{", "AST", "tmp328_AST", "=", "null", ";", "tmp328_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp328_AST", ")", ";", "match", "(", "DIV", ")", ";", "break", ";", "}", "case", "MOD", ":", "{", "AST", "tmp329_AST", "=", "null", ";", "tmp329_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp329_AST", ")", ";", "match", "(", "MOD", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "nls", "(", ")", ";", "powerExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop465", ";", "}", "}", "while", "(", "true", ")", ";", "}", "}", "multiplicativeExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "multiplicativeExpression_AST", ";", "}", "public", "final", "void", "powerExpressionNotPlusMinus", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "powerExpressionNotPlusMinus_AST", "=", "null", ";", "unaryExpressionNotPlusMinus", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop471", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "STAR_STAR", ")", ")", "{", "AST", "tmp330_AST", "=", "null", ";", "tmp330_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp330_AST", ")", ";", "match", "(", "STAR_STAR", ")", ";", "nls", "(", ")", ";", "unaryExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop471", ";", "}", "}", "while", "(", "true", ")", ";", "}", "powerExpressionNotPlusMinus_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "powerExpressionNotPlusMinus_AST", ";", "}", "public", "final", "void", "powerExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "powerExpression_AST", "=", "null", ";", "unaryExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "_loop468", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "STAR_STAR", ")", ")", "{", "AST", "tmp331_AST", "=", "null", ";", "tmp331_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp331_AST", ")", ";", "match", "(", "STAR_STAR", ")", ";", "nls", "(", ")", ";", "unaryExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "break", "_loop468", ";", "}", "}", "while", "(", "true", ")", ";", "}", "powerExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "powerExpression_AST", ";", "}", "public", "final", "void", "unaryExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "unaryExpression_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "INC", ":", "{", "AST", "tmp332_AST", "=", "null", ";", "tmp332_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp332_AST", ")", ";", "match", "(", "INC", ")", ";", "nls", "(", ")", ";", "unaryExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "unaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "DEC", ":", "{", "AST", "tmp333_AST", "=", "null", ";", "tmp333_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp333_AST", ")", ";", "match", "(", "DEC", ")", ";", "nls", "(", ")", ";", "unaryExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "unaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "MINUS", ":", "{", "AST", "tmp334_AST", "=", "null", ";", "tmp334_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp334_AST", ")", ";", "match", "(", "MINUS", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "tmp334_AST", ".", "setType", "(", "UNARY_MINUS", ")", ";", "}", "nls", "(", ")", ";", "unaryExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "unaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "PLUS", ":", "{", "AST", "tmp335_AST", "=", "null", ";", "tmp335_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp335_AST", ")", ";", "match", "(", "PLUS", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "tmp335_AST", ".", "setType", "(", "UNARY_PLUS", ")", ";", "}", "nls", "(", ")", ";", "unaryExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "unaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "unaryExpressionNotPlusMinus", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "unaryExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "unaryExpression_AST", ";", "}", "public", "final", "void", "unaryExpressionNotPlusMinus", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "unaryExpressionNotPlusMinus_AST", "=", "null", ";", "Token", "lpb", "=", "null", ";", "AST", "lpb_AST", "=", "null", ";", "Token", "lp", "=", "null", ";", "AST", "lp_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "BNOT", ":", "{", "AST", "tmp336_AST", "=", "null", ";", "tmp336_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp336_AST", ")", ";", "match", "(", "BNOT", ")", ";", "nls", "(", ")", ";", "unaryExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "unaryExpressionNotPlusMinus_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LNOT", ":", "{", "AST", "tmp337_AST", "=", "null", ";", "tmp337_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "tmp337_AST", ")", ";", "match", "(", "LNOT", ")", ";", "nls", "(", ")", ";", "unaryExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "unaryExpressionNotPlusMinus_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "{", "boolean", "synPredMatched476", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LPAREN", ")", "&&", "(", "(", "LA", "(", "2", ")", ">=", "LITERAL_void", "&&", "LA", "(", "2", ")", "<=", "LITERAL_double", ")", ")", ")", ")", "{", "int", "_m476", "=", "mark", "(", ")", ";", "synPredMatched476", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "LPAREN", ")", ";", "builtInTypeSpec", "(", "true", ")", ";", "match", "(", "RPAREN", ")", ";", "unaryExpression", "(", "0", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched476", "=", "false", ";", "}", "rewind", "(", "_m476", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched476", ")", "{", "lpb", "=", "LT", "(", "1", ")", ";", "lpb_AST", "=", "astFactory", ".", "create", "(", "lpb", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "lpb_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "lpb_AST", ".", "setType", "(", "TYPECAST", ")", ";", "}", "builtInTypeSpec", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "match", "(", "RPAREN", ")", ";", "unaryExpression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "boolean", "synPredMatched478", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "LPAREN", ")", "&&", "(", "LA", "(", "2", ")", "==", "IDENT", ")", ")", ")", "{", "int", "_m478", "=", "mark", "(", ")", ";", "synPredMatched478", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "LPAREN", ")", ";", "classTypeSpec", "(", "true", ")", ";", "match", "(", "RPAREN", ")", ";", "unaryExpressionNotPlusMinus", "(", "0", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched478", "=", "false", ";", "}", "rewind", "(", "_m478", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched478", ")", "{", "lp", "=", "LT", "(", "1", ")", ";", "lp_AST", "=", "astFactory", ".", "create", "(", "lp", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "lp_AST", ")", ";", "match", "(", "LPAREN", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "lp_AST", ".", "setType", "(", "TYPECAST", ")", ";", "}", "classTypeSpec", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "match", "(", "RPAREN", ")", ";", "unaryExpressionNotPlusMinus", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_91", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_38", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "postfixExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "unaryExpressionNotPlusMinus_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "unaryExpressionNotPlusMinus_AST", ";", "}", "public", "final", "void", "postfixExpression", "(", "int", "lc_stmt", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "postfixExpression_AST", "=", "null", ";", "Token", "in", "=", "null", ";", "AST", "in_AST", "=", "null", ";", "Token", "de", "=", "null", ";", "AST", "de_AST", "=", "null", ";", "pathExpression", "(", "lc_stmt", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "INC", ")", "&&", "(", "_tokenSet_102", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "in", "=", "LT", "(", "1", ")", ";", "in_AST", "=", "astFactory", ".", "create", "(", "in", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "in_AST", ")", ";", "match", "(", "INC", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "in_AST", ".", "setType", "(", "POST_INC", ")", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "DEC", ")", "&&", "(", "_tokenSet_102", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "de", "=", "LT", "(", "1", ")", ";", "de_AST", "=", "astFactory", ".", "create", "(", "de", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "de_AST", ")", ";", "match", "(", "DEC", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "de_AST", ".", "setType", "(", "POST_DEC", ")", ";", "}", "}", "else", "if", "(", "(", "_tokenSet_102", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_74", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "postfixExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "postfixExpression_AST", ";", "}", "public", "final", "void", "constant", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "constant_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "constantNumber", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "constant_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "STRING_LITERAL", ":", "{", "AST", "tmp340_AST", "=", "null", ";", "tmp340_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp340_AST", ")", ";", "match", "(", "STRING_LITERAL", ")", ";", "constant_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_true", ":", "{", "AST", "tmp341_AST", "=", "null", ";", "tmp341_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp341_AST", ")", ";", "match", "(", "LITERAL_true", ")", ";", "constant_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_false", ":", "{", "AST", "tmp342_AST", "=", "null", ";", "tmp342_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp342_AST", ")", ";", "match", "(", "LITERAL_false", ")", ";", "constant_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "LITERAL_null", ":", "{", "AST", "tmp343_AST", "=", "null", ";", "tmp343_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp343_AST", ")", ";", "match", "(", "LITERAL_null", ")", ";", "constant_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "constant_AST", ";", "}", "public", "final", "void", "newExpression", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "newExpression_AST", "=", "null", ";", "AST", "ta_AST", "=", "null", ";", "AST", "t_AST", "=", "null", ";", "AST", "mca_AST", "=", "null", ";", "AST", "cb_AST", "=", "null", ";", "AST", "ad_AST", "=", "null", ";", "Token", "first", "=", "LT", "(", "1", ")", ";", "int", "jumpBack", "=", "mark", "(", ")", ";", "try", "{", "match", "(", "LITERAL_new", ")", ";", "nls", "(", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LT", ":", "{", "typeArguments", "(", ")", ";", "ta_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "LPAREN", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "{", "type", "(", ")", ";", "t_AST", "=", "(", "AST", ")", "returnAST", ";", "break", ";", "}", "case", "LBRACK", ":", "case", "LPAREN", ":", "case", "NLS", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LPAREN", ":", "case", "NLS", ":", "{", "nls", "(", ")", ";", "methodCallArgs", "(", "null", ")", ";", "mca_AST", "=", "(", "AST", ")", "returnAST", ";", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LCURLY", ")", "&&", "(", "_tokenSet_51", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "classBlock", "(", ")", ";", "cb_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_95", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_74", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "newExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "mca_AST", "=", "mca_AST", ".", "getFirstChild", "(", ")", ";", "newExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "5", ")", ")", ".", "add", "(", "create", "(", "LITERAL_new", ",", "\"new\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "ta_AST", ")", ".", "add", "(", "t_AST", ")", ".", "add", "(", "mca_AST", ")", ".", "add", "(", "cb_AST", ")", ")", ";", "currentAST", ".", "root", "=", "newExpression_AST", ";", "currentAST", ".", "child", "=", "newExpression_AST", "!=", "null", "&&", "newExpression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "newExpression_AST", ".", "getFirstChild", "(", ")", ":", "newExpression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "case", "LBRACK", ":", "{", "newArrayDeclarator", "(", ")", ";", "ad_AST", "=", "(", "AST", ")", "returnAST", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "newExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "newExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "4", ")", ")", ".", "add", "(", "create", "(", "LITERAL_new", ",", "\"new\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "ta_AST", ")", ".", "add", "(", "t_AST", ")", ".", "add", "(", "ad_AST", ")", ")", ";", "currentAST", ".", "root", "=", "newExpression_AST", ";", "currentAST", ".", "child", "=", "newExpression_AST", "!=", "null", "&&", "newExpression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "newExpression_AST", ".", "getFirstChild", "(", ")", ":", "newExpression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "newExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "catch", "(", "RecognitionException", "e", ")", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "t_AST", "==", "null", ")", "{", "reportError", "(", "\"\"", ",", "first", ")", ";", "newExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_new", ",", "\"new\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "ta_AST", ")", ".", "add", "(", "null", ")", ")", ";", "if", "(", "e", "instanceof", "MismatchedTokenException", "||", "e", "instanceof", "NoViableAltException", ")", "{", "rewind", "(", "jumpBack", ")", ";", "consumeUntil", "(", "NLS", ")", ";", "}", "}", "else", "if", "(", "mca_AST", "==", "null", "&&", "ad_AST", "==", "null", ")", "{", "reportError", "(", "\"\"", ",", "t_AST", ")", ";", "newExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "3", ")", ")", ".", "add", "(", "create", "(", "LITERAL_new", ",", "\"new\"", ",", "first", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "ta_AST", ")", ".", "add", "(", "t_AST", ")", ")", ";", "if", "(", "e", "instanceof", "MismatchedTokenException", ")", "{", "Token", "t", "=", "(", "(", "MismatchedTokenException", ")", "e", ")", ".", "token", ";", "int", "i", "=", "(", "(", "MismatchedTokenException", ")", "e", ")", ".", "token", ".", "getType", "(", ")", ";", "rewind", "(", "jumpBack", ")", ";", "consume", "(", ")", ";", "consumeUntil", "(", "NLS", ")", ";", "}", "}", "else", "{", "throw", "e", ";", "}", "}", "else", "{", "throw", "e", ";", "}", "}", "returnAST", "=", "newExpression_AST", ";", "}", "public", "final", "void", "closableBlockConstructorExpression", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "closableBlockConstructorExpression_AST", "=", "null", ";", "closableBlock", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "closableBlockConstructorExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "closableBlockConstructorExpression_AST", ";", "}", "public", "final", "void", "listOrMapConstructorExpression", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "listOrMapConstructorExpression_AST", "=", "null", ";", "Token", "lcon", "=", "null", ";", "AST", "lcon_AST", "=", "null", ";", "AST", "args_AST", "=", "null", ";", "Token", "emcon", "=", "null", ";", "AST", "emcon_AST", "=", "null", ";", "boolean", "hasLabels", "=", "false", ";", "if", "(", "(", "LA", "(", "1", ")", "==", "LBRACK", ")", "&&", "(", "_tokenSet_103", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "lcon", "=", "LT", "(", "1", ")", ";", "lcon_AST", "=", "astFactory", ".", "create", "(", "lcon", ")", ";", "match", "(", "LBRACK", ")", ";", "argList", "(", ")", ";", "args_AST", "=", "(", "AST", ")", "returnAST", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "hasLabels", "|=", "argListHasLabels", ";", "}", "match", "(", "RBRACK", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "listOrMapConstructorExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "int", "type", "=", "hasLabels", "?", "MAP_CONSTRUCTOR", ":", "LIST_CONSTRUCTOR", ";", "listOrMapConstructorExpression_AST", "=", "(", "AST", ")", "astFactory", ".", "make", "(", "(", "new", "ASTArray", "(", "2", ")", ")", ".", "add", "(", "create", "(", "type", ",", "\"[\"", ",", "lcon_AST", ",", "LT", "(", "1", ")", ")", ")", ".", "add", "(", "args_AST", ")", ")", ";", "currentAST", ".", "root", "=", "listOrMapConstructorExpression_AST", ";", "currentAST", ".", "child", "=", "listOrMapConstructorExpression_AST", "!=", "null", "&&", "listOrMapConstructorExpression_AST", ".", "getFirstChild", "(", ")", "!=", "null", "?", "listOrMapConstructorExpression_AST", ".", "getFirstChild", "(", ")", ":", "listOrMapConstructorExpression_AST", ";", "currentAST", ".", "advanceChildToEnd", "(", ")", ";", "}", "listOrMapConstructorExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "LBRACK", ")", "&&", "(", "LA", "(", "2", ")", "==", "COLON", ")", ")", "{", "emcon", "=", "LT", "(", "1", ")", ";", "emcon_AST", "=", "astFactory", ".", "create", "(", "emcon", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "emcon_AST", ")", ";", "match", "(", "LBRACK", ")", ";", "match", "(", "COLON", ")", ";", "match", "(", "RBRACK", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "emcon_AST", ".", "setType", "(", "MAP_CONSTRUCTOR", ")", ";", "}", "listOrMapConstructorExpression_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "returnAST", "=", "listOrMapConstructorExpression_AST", ";", "}", "public", "final", "void", "stringConstructorValuePart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "stringConstructorValuePart_AST", "=", "null", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "identifier", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "LITERAL_this", ":", "{", "AST", "tmp348_AST", "=", "null", ";", "tmp348_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp348_AST", ")", ";", "match", "(", "LITERAL_this", ")", ";", "break", ";", "}", "case", "LITERAL_super", ":", "{", "AST", "tmp349_AST", "=", "null", ";", "tmp349_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp349_AST", ")", ";", "match", "(", "LITERAL_super", ")", ";", "break", ";", "}", "case", "LCURLY", ":", "{", "openOrClosableBlock", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "stringConstructorValuePart_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "stringConstructorValuePart_AST", ";", "}", "public", "final", "void", "newArrayDeclarator", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "newArrayDeclarator_AST", "=", "null", ";", "Token", "lb", "=", "null", ";", "AST", "lb_AST", "=", "null", ";", "{", "int", "_cnt535", "=", "0", ";", "_loop535", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "LBRACK", ")", "&&", "(", "_tokenSet_104", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "lb", "=", "LT", "(", "1", ")", ";", "lb_AST", "=", "astFactory", ".", "create", "(", "lb", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "lb_AST", ")", ";", "match", "(", "LBRACK", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "lb_AST", ".", "setType", "(", "ARRAY_DECLARATOR", ")", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "expression", "(", "0", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "break", ";", "}", "case", "RBRACK", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "match", "(", "RBRACK", ")", ";", "}", "else", "{", "if", "(", "_cnt535", ">=", "1", ")", "{", "break", "_loop535", ";", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "_cnt535", "++", ";", "}", "while", "(", "true", ")", ";", "}", "newArrayDeclarator_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "newArrayDeclarator_AST", ";", "}", "public", "final", "byte", "argument", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "byte", "hasLabelOrSpread", "=", "0", ";", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "argument_AST", "=", "null", ";", "Token", "c", "=", "null", ";", "AST", "c_AST", "=", "null", ";", "Token", "sp", "=", "null", ";", "AST", "sp_AST", "=", "null", ";", "boolean", "sce", "=", "false", ";", "{", "boolean", "synPredMatched521", "=", "false", ";", "if", "(", "(", "(", "_tokenSet_88", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_89", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", ")", "{", "int", "_m521", "=", "mark", "(", ")", ";", "synPredMatched521", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "argumentLabelStart", "(", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched521", "=", "false", ";", "}", "rewind", "(", "_m521", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched521", ")", "{", "argumentLabel", "(", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "c", "=", "LT", "(", "1", ")", ";", "c_AST", "=", "astFactory", ".", "create", "(", "c", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "c_AST", ")", ";", "match", "(", "COLON", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "c_AST", ".", "setType", "(", "LABELED_ARG", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "hasLabelOrSpread", "|=", "1", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "STAR", ")", ")", "{", "sp", "=", "LT", "(", "1", ")", ";", "sp_AST", "=", "astFactory", ".", "create", "(", "sp", ")", ";", "astFactory", ".", "makeASTRoot", "(", "currentAST", ",", "sp_AST", ")", ";", "match", "(", "STAR", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "sp_AST", ".", "setType", "(", "SPREAD_ARG", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "hasLabelOrSpread", "|=", "2", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "COLON", ":", "{", "match", "(", "COLON", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "sp_AST", ".", "setType", "(", "SPREAD_MAP_ARG", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "hasLabelOrSpread", "|=", "1", ";", "}", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "STRICTFP", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LBRACK", ":", "case", "IDENT", ":", "case", "STRING_LITERAL", ":", "case", "LPAREN", ":", "case", "AT", ":", "case", "LITERAL_super", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LCURLY", ":", "case", "LITERAL_this", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "PLUS", ":", "case", "MINUS", ":", "case", "LITERAL_false", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "case", "INC", ":", "case", "DEC", ":", "case", "BNOT", ":", "case", "LNOT", ":", "case", "STRING_CTOR_START", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "}", "else", "if", "(", "(", "_tokenSet_84", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "_tokenSet_105", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "sce", "=", "strictContextExpression", "(", "true", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "returnAST", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "require", "(", "LA", "(", "1", ")", "!=", "COLON", ",", "\"\"", ",", "\"\"", ")", ";", "}", "argument_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "returnAST", "=", "argument_AST", ";", "return", "hasLabelOrSpread", ";", "}", "public", "final", "void", "argumentLabelStart", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "argumentLabelStart_AST", "=", "null", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "IDENT", ":", "{", "AST", "tmp352_AST", "=", "null", ";", "tmp352_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "IDENT", ")", ";", "break", ";", "}", "case", "FINAL", ":", "case", "ABSTRACT", ":", "case", "UNUSED_GOTO", ":", "case", "UNUSED_DO", ":", "case", "STRICTFP", ":", "case", "LITERAL_package", ":", "case", "LITERAL_import", ":", "case", "LITERAL_static", ":", "case", "LITERAL_def", ":", "case", "LITERAL_class", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_enum", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_void", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_short", ":", "case", "LITERAL_int", ":", "case", "LITERAL_float", ":", "case", "LITERAL_long", ":", "case", "LITERAL_double", ":", "case", "LITERAL_as", ":", "case", "LITERAL_private", ":", "case", "LITERAL_public", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_native", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_volatile", ":", "case", "LITERAL_default", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_if", ":", "case", "LITERAL_else", ":", "case", "LITERAL_while", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_for", ":", "case", "LITERAL_in", ":", "case", "LITERAL_return", ":", "case", "LITERAL_break", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_assert", ":", "case", "LITERAL_case", ":", "case", "LITERAL_try", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_false", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_true", ":", "{", "keywordPropertyNames", "(", ")", ";", "break", ";", "}", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "{", "constantNumber", "(", ")", ";", "break", ";", "}", "case", "STRING_LITERAL", ":", "{", "AST", "tmp353_AST", "=", "null", ";", "tmp353_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "STRING_LITERAL", ")", ";", "break", ";", "}", "case", "LBRACK", ":", "case", "LPAREN", ":", "case", "LCURLY", ":", "case", "STRING_CTOR_START", ":", "{", "balancedBrackets", "(", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "}", "AST", "tmp354_AST", "=", "null", ";", "tmp354_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "COLON", ")", ";", "returnAST", "=", "argumentLabelStart_AST", ";", "}", "public", "final", "void", "constantNumber", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "constantNumber_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "NUM_INT", ":", "{", "AST", "tmp355_AST", "=", "null", ";", "tmp355_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp355_AST", ")", ";", "match", "(", "NUM_INT", ")", ";", "constantNumber_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "NUM_FLOAT", ":", "{", "AST", "tmp356_AST", "=", "null", ";", "tmp356_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp356_AST", ")", ";", "match", "(", "NUM_FLOAT", ")", ";", "constantNumber_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "NUM_LONG", ":", "{", "AST", "tmp357_AST", "=", "null", ";", "tmp357_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp357_AST", ")", ";", "match", "(", "NUM_LONG", ")", ";", "constantNumber_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "NUM_DOUBLE", ":", "{", "AST", "tmp358_AST", "=", "null", ";", "tmp358_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp358_AST", ")", ";", "match", "(", "NUM_DOUBLE", ")", ";", "constantNumber_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "NUM_BIG_INT", ":", "{", "AST", "tmp359_AST", "=", "null", ";", "tmp359_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp359_AST", ")", ";", "match", "(", "NUM_BIG_INT", ")", ";", "constantNumber_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "case", "NUM_BIG_DECIMAL", ":", "{", "AST", "tmp360_AST", "=", "null", ";", "tmp360_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "astFactory", ".", "addASTChild", "(", "currentAST", ",", "tmp360_AST", ")", ";", "match", "(", "NUM_BIG_DECIMAL", ")", ";", "constantNumber_AST", "=", "(", "AST", ")", "currentAST", ".", "root", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "constantNumber_AST", ";", "}", "public", "final", "void", "balancedBrackets", "(", ")", "throws", "RecognitionException", ",", "TokenStreamException", "{", "returnAST", "=", "null", ";", "ASTPair", "currentAST", "=", "new", "ASTPair", "(", ")", ";", "AST", "balancedBrackets_AST", "=", "null", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "LPAREN", ":", "{", "AST", "tmp361_AST", "=", "null", ";", "tmp361_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "LPAREN", ")", ";", "balancedTokens", "(", ")", ";", "AST", "tmp362_AST", "=", "null", ";", "tmp362_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "RPAREN", ")", ";", "break", ";", "}", "case", "LBRACK", ":", "{", "AST", "tmp363_AST", "=", "null", ";", "tmp363_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "LBRACK", ")", ";", "balancedTokens", "(", ")", ";", "AST", "tmp364_AST", "=", "null", ";", "tmp364_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "RBRACK", ")", ";", "break", ";", "}", "case", "LCURLY", ":", "{", "AST", "tmp365_AST", "=", "null", ";", "tmp365_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "LCURLY", ")", ";", "balancedTokens", "(", ")", ";", "AST", "tmp366_AST", "=", "null", ";", "tmp366_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "RCURLY", ")", ";", "break", ";", "}", "case", "STRING_CTOR_START", ":", "{", "AST", "tmp367_AST", "=", "null", ";", "tmp367_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "STRING_CTOR_START", ")", ";", "balancedTokens", "(", ")", ";", "AST", "tmp368_AST", "=", "null", ";", "tmp368_AST", "=", "astFactory", ".", "create", "(", "LT", "(", "1", ")", ")", ";", "match", "(", "STRING_CTOR_END", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltException", "(", "LT", "(", "1", ")", ",", "getFilename", "(", ")", ")", ";", "}", "}", "returnAST", "=", "balancedBrackets_AST", ";", "}", "public", "static", "final", "String", "[", "]", "_tokenNames", "=", "{", "\"<0>\"", ",", "\"EOF\"", ",", "\"<2>\"", ",", "\"\"", ",", "\"BLOCK\"", ",", "\"MODIFIERS\"", ",", "\"OBJBLOCK\"", ",", "\"SLIST\"", ",", "\"METHOD_DEF\"", ",", "\"VARIABLE_DEF\"", ",", "\"\"", ",", "\"STATIC_INIT\"", ",", "\"TYPE\"", ",", "\"CLASS_DEF\"", ",", "\"\"", ",", "\"PACKAGE_DEF\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"PARAMETERS\"", ",", "\"\"", ",", "\"LABELED_STAT\"", ",", "\"TYPECAST\"", ",", "\"INDEX_OP\"", ",", "\"POST_INC\"", ",", "\"POST_DEC\"", ",", "\"METHOD_CALL\"", ",", "\"EXPR\"", ",", "\"IMPORT\"", ",", "\"UNARY_MINUS\"", ",", "\"UNARY_PLUS\"", ",", "\"CASE_GROUP\"", ",", "\"ELIST\"", ",", "\"FOR_INIT\"", ",", "\"\"", ",", "\"FOR_ITERATOR\"", ",", "\"EMPTY_STAT\"", ",", "\"\\\"final\\\"\"", ",", "\"\\\"abstract\\\"\"", ",", "\"\\\"goto\\\"\"", ",", "\"\\\"const\\\"\"", ",", "\"\\\"do\\\"\"", ",", "\"\\\"strictfp\\\"\"", ",", "\"\"", ",", "\"CTOR_CALL\"", ",", "\"CTOR_IDENT\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"SELECT_SLOT\"", ",", "\"\"", ",", "\"LABELED_ARG\"", ",", "\"SPREAD_ARG\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"ENUM_DEF\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"ANNOTATIONS\"", ",", "\"ANNOTATION\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"CLOSURE_LIST\"", ",", "\"\"", ",", "\"\\\"package\\\"\"", ",", "\"\\\"import\\\"\"", ",", "\"\\\"static\\\"\"", ",", "\"\\\"def\\\"\"", ",", "\"'['\"", ",", "\"']'\"", ",", "\"\"", ",", "\"\"", ",", "\"'<'\"", ",", "\"'.'\"", ",", "\"'('\"", ",", "\"\\\"class\\\"\"", ",", "\"\\\"interface\\\"\"", ",", "\"\\\"enum\\\"\"", ",", "\"'@'\"", ",", "\"'?'\"", ",", "\"\\\"extends\\\"\"", ",", "\"\\\"super\\\"\"", ",", "\"','\"", ",", "\"'>'\"", ",", "\"'>>'\"", ",", "\"'>>>'\"", ",", "\"\\\"void\\\"\"", ",", "\"\\\"boolean\\\"\"", ",", "\"\\\"byte\\\"\"", ",", "\"\\\"char\\\"\"", ",", "\"\\\"short\\\"\"", ",", "\"\\\"int\\\"\"", ",", "\"\\\"float\\\"\"", ",", "\"\\\"long\\\"\"", ",", "\"\\\"double\\\"\"", ",", "\"'*'\"", ",", "\"\\\"as\\\"\"", ",", "\"\\\"private\\\"\"", ",", "\"\\\"public\\\"\"", ",", "\"\\\"protected\\\"\"", ",", "\"\\\"transient\\\"\"", ",", "\"\\\"native\\\"\"", ",", "\"\\\"threadsafe\\\"\"", ",", "\"\"", ",", "\"\\\"volatile\\\"\"", ",", "\"')'\"", ",", "\"'='\"", ",", "\"'&'\"", ",", "\"'{'\"", ",", "\"'}'\"", ",", "\"';'\"", ",", "\"\\\"default\\\"\"", ",", "\"\\\"throws\\\"\"", ",", "\"\\\"implements\\\"\"", ",", "\"\\\"this\\\"\"", ",", "\"'...'\"", ",", "\"'->'\"", ",", "\"':'\"", ",", "\"\\\"if\\\"\"", ",", "\"\\\"else\\\"\"", ",", "\"\\\"while\\\"\"", ",", "\"\\\"switch\\\"\"", ",", "\"\\\"for\\\"\"", ",", "\"\\\"in\\\"\"", ",", "\"\\\"return\\\"\"", ",", "\"\\\"break\\\"\"", ",", "\"\\\"continue\\\"\"", ",", "\"\\\"throw\\\"\"", ",", "\"\\\"assert\\\"\"", ",", "\"'+'\"", ",", "\"'-'\"", ",", "\"\\\"case\\\"\"", ",", "\"\\\"try\\\"\"", ",", "\"\\\"finally\\\"\"", ",", "\"\\\"catch\\\"\"", ",", "\"'*.'\"", ",", "\"'?.'\"", ",", "\"'.&'\"", ",", "\"\\\"false\\\"\"", ",", "\"\\\"instanceof\\\"\"", ",", "\"\\\"new\\\"\"", ",", "\"\\\"null\\\"\"", ",", "\"\\\"true\\\"\"", ",", "\"'+='\"", ",", "\"'-='\"", ",", "\"'*='\"", ",", "\"'/='\"", ",", "\"'%='\"", ",", "\"'>>='\"", ",", "\"'>>>='\"", ",", "\"'<<='\"", ",", "\"'&='\"", ",", "\"'^='\"", ",", "\"'|='\"", ",", "\"'**='\"", ",", "\"'?:'\"", ",", "\"'||'\"", ",", "\"'&&'\"", ",", "\"'|'\"", ",", "\"'^'\"", ",", "\"'=~'\"", ",", "\"'==~'\"", ",", "\"'!='\"", ",", "\"'=='\"", ",", "\"'==='\"", ",", "\"'!=='\"", ",", "\"'<=>'\"", ",", "\"'<='\"", ",", "\"'>='\"", ",", "\"'<<'\"", ",", "\"'..'\"", ",", "\"'..<'\"", ",", "\"'++'\"", ",", "\"'/'\"", ",", "\"'%'\"", ",", "\"'--'\"", ",", "\"'**'\"", ",", "\"'~'\"", ",", "\"'!'\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"NUM_FLOAT\"", ",", "\"NUM_LONG\"", ",", "\"NUM_DOUBLE\"", ",", "\"NUM_BIG_INT\"", ",", "\"\"", ",", "\"\"", ",", "\"'$'\"", ",", "\"whitespace\"", ",", "\"a", "newline\"", ",", "\"a", "newline\"", ",", "\"\"", ",", "\"a", "comment\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"\"", ",", "\"a", "character\"", ",", "\"a", "letter\"", ",", "\"a", "digit\"", ",", "\"an", "exponent\"", ",", "\"\"", ",", "\"\"", "}", ";", "protected", "void", "buildTokenTypeASTClassMap", "(", ")", "{", "tokenTypeToASTClassMap", "=", "null", ";", "}", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_0", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "2L", ";", "data", "[", "1", "]", "=", "1152921504675004416L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_0", "=", "new", "BitSet", "(", "mk_tokenSet_0", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_1", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371522L", ";", "data", "[", "1", "]", "=", "1477075058612994048L", ";", "data", "[", "2", "]", "=", "-", "6629298651002438191L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_1", "=", "new", "BitSet", "(", "mk_tokenSet_1", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_2", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440962L", ";", "data", "[", "1", "]", "=", "-", "36028801313947648L", ";", "data", "[", "2", "]", "=", "-", "1L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_2", "=", "new", "BitSet", "(", "mk_tokenSet_2", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_3", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440962L", ";", "data", "[", "1", "]", "=", "-", "16384L", ";", "data", "[", "2", "]", "=", "-", "6620291452234629121L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_3", "=", "new", "BitSet", "(", "mk_tokenSet_3", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_4", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "16", "]", ";", "data", "[", "0", "]", "=", "-", "14L", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "2", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "data", "[", "3", "]", "=", "536870911L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_4", "=", "new", "BitSet", "(", "mk_tokenSet_4", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_5", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "269533184L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_5", "=", "new", "BitSet", "(", "mk_tokenSet_5", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_6", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371522L", ";", "data", "[", "1", "]", "=", "2053535812893736960L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_6", "=", "new", "BitSet", "(", "mk_tokenSet_6", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_7", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "1097728L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_7", "=", "new", "BitSet", "(", "mk_tokenSet_7", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_8", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371522L", ";", "data", "[", "1", "]", "=", "2053535812826628096L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_8", "=", "new", "BitSet", "(", "mk_tokenSet_8", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_9", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "1152921504606846976L", ";", "data", "[", "2", "]", "=", "32L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_9", "=", "new", "BitSet", "(", "mk_tokenSet_9", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_10", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "1477075058612994048L", ";", "data", "[", "2", "]", "=", "-", "6629298651002438159L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_10", "=", "new", "BitSet", "(", "mk_tokenSet_10", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_11", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "2L", ";", "data", "[", "1", "]", "=", "4035225266123964416L", ";", "data", "[", "2", "]", "=", "131104L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_11", "=", "new", "BitSet", "(", "mk_tokenSet_11", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_12", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "289034119151618L", ";", "data", "[", "1", "]", "=", "-", "16384L", ";", "data", "[", "2", "]", "=", "-", "3L", ";", "data", "[", "3", "]", "=", "1023L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_12", "=", "new", "BitSet", "(", "mk_tokenSet_12", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_13", "(", ")", "{", "long", "[", "]", "data", "=", "{", "4810363371520L", ",", "35888059799240704L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_13", "=", "new", "BitSet", "(", "mk_tokenSet_13", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_14", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "35888059871592448L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_14", "=", "new", "BitSet", "(", "mk_tokenSet_14", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_15", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "35923175536787456L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_15", "=", "new", "BitSet", "(", "mk_tokenSet_15", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_16", "(", ")", "{", "long", "[", "]", "data", "=", "{", "4810363371520L", ",", "35923175452901376L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_16", "=", "new", "BitSet", "(", "mk_tokenSet_16", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_17", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "35923175534952448L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_17", "=", "new", "BitSet", "(", "mk_tokenSet_17", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_18", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "2053535810916417536L", ";", "data", "[", "2", "]", "=", "-", "6629298651002438185L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_18", "=", "new", "BitSet", "(", "mk_tokenSet_18", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_19", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "324153554006147072L", ";", "data", "[", "2", "]", "=", "-", "6629298651002438191L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_19", "=", "new", "BitSet", "(", "mk_tokenSet_19", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_20", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "288265493971992576L", ";", "data", "[", "2", "]", "=", "-", "6629298651002732543L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_20", "=", "new", "BitSet", "(", "mk_tokenSet_20", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_21", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "68222976L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_21", "=", "new", "BitSet", "(", "mk_tokenSet_21", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_22", "(", ")", "{", "long", "[", "]", "data", "=", "{", "4810363371520L", ",", "35888060034121728L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_22", "=", "new", "BitSet", "(", "mk_tokenSet_22", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_23", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "35888060035170304L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_23", "=", "new", "BitSet", "(", "mk_tokenSet_23", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_24", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371522L", ";", "data", "[", "1", "]", "=", "4359378820134305792L", ";", "data", "[", "2", "]", "=", "-", "6629298651002307087L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_24", "=", "new", "BitSet", "(", "mk_tokenSet_24", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_25", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "35115653660672L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_25", "=", "new", "BitSet", "(", "mk_tokenSet_25", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_26", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "15990784L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_26", "=", "new", "BitSet", "(", "mk_tokenSet_26", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_27", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "2L", ";", "data", "[", "1", "]", "=", "4107282864473636864L", ";", "data", "[", "2", "]", "=", "131104L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_27", "=", "new", "BitSet", "(", "mk_tokenSet_27", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_28", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "2L", ";", "data", "[", "1", "]", "=", "4107282864456859648L", ";", "data", "[", "2", "]", "=", "131104L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_28", "=", "new", "BitSet", "(", "mk_tokenSet_28", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_29", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "4611686018428436480L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_29", "=", "new", "BitSet", "(", "mk_tokenSet_29", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_30", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "2L", ";", "data", "[", "1", "]", "=", "4323455642275676160L", ";", "data", "[", "2", "]", "=", "131104L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_30", "=", "new", "BitSet", "(", "mk_tokenSet_30", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_31", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "2053535810916417536L", ";", "data", "[", "2", "]", "=", "-", "6629298651002438191L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_31", "=", "new", "BitSet", "(", "mk_tokenSet_31", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_32", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "13893632L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_32", "=", "new", "BitSet", "(", "mk_tokenSet_32", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_33", "(", ")", "{", "long", "[", "]", "data", "=", "{", "2L", ",", "1261007899959230464L", ",", "520L", ",", "0L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_33", "=", "new", "BitSet", "(", "mk_tokenSet_33", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_34", "(", ")", "{", "long", "[", "]", "data", "=", "{", "4810363371520L", ",", "35923175467843584L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_34", "=", "new", "BitSet", "(", "mk_tokenSet_34", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_35", "(", ")", "{", "long", "[", "]", "data", "=", "{", "4810363371520L", ",", "35923175459454976L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_35", "=", "new", "BitSet", "(", "mk_tokenSet_35", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_36", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "1945590288370647040L", ";", "data", "[", "2", "]", "=", "-", "6629298650967179279L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_36", "=", "new", "BitSet", "(", "mk_tokenSet_36", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_37", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371522L", ";", "data", "[", "1", "]", "=", "1801334233935626240L", ";", "data", "[", "2", "]", "=", "2L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_37", "=", "new", "BitSet", "(", "mk_tokenSet_37", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_38", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440962L", ";", "data", "[", "1", "]", "=", "-", "16384L", ";", "data", "[", "2", "]", "=", "-", "1L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_38", "=", "new", "BitSet", "(", "mk_tokenSet_38", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_39", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "35116190531584L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_39", "=", "new", "BitSet", "(", "mk_tokenSet_39", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_40", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440962L", ";", "data", "[", "1", "]", "=", "-", "35184376299520L", ";", "data", "[", "2", "]", "=", "-", "6620291452249309185L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_40", "=", "new", "BitSet", "(", "mk_tokenSet_40", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_41", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "288230376168751104L", ";", "data", "[", "3", "]", "=", "2L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_41", "=", "new", "BitSet", "(", "mk_tokenSet_41", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_42", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "16", "]", ";", "data", "[", "0", "]", "=", "-", "16L", ";", "data", "[", "1", "]", "=", "-", "900719925491662849L", ";", "data", "[", "2", "]", "=", "-", "1L", ";", "data", "[", "3", "]", "=", "536870905L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_42", "=", "new", "BitSet", "(", "mk_tokenSet_42", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_43", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "35923175691976704L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_43", "=", "new", "BitSet", "(", "mk_tokenSet_43", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_44", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "35116161171456L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_44", "=", "new", "BitSet", "(", "mk_tokenSet_44", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_45", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "2L", ";", "data", "[", "1", "]", "=", "99876864L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_45", "=", "new", "BitSet", "(", "mk_tokenSet_45", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_46", "(", ")", "{", "long", "[", "]", "data", "=", "{", "4810363371520L", ",", "35888059530674176L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_46", "=", "new", "BitSet", "(", "mk_tokenSet_46", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_47", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "288265494240428032L", ";", "data", "[", "2", "]", "=", "-", "6629298651002732543L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_47", "=", "new", "BitSet", "(", "mk_tokenSet_47", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_48", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "72057598332911616L", ";", "data", "[", "2", "]", "=", "-", "2198486384641L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_48", "=", "new", "BitSet", "(", "mk_tokenSet_48", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_49", "(", ")", "{", "long", "[", "]", "data", "=", "{", "7559142440960L", ",", "-", "2269849463976378368L", ",", "522092528L", ",", "0L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_49", "=", "new", "BitSet", "(", "mk_tokenSet_49", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_50", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "2017612637441884160L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_50", "=", "new", "BitSet", "(", "mk_tokenSet_50", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_51", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "2053535808749764608L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_51", "=", "new", "BitSet", "(", "mk_tokenSet_51", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_52", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371522L", ";", "data", "[", "1", "]", "=", "4359378820142694400L", ";", "data", "[", "2", "]", "=", "-", "6629298651002307087L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_52", "=", "new", "BitSet", "(", "mk_tokenSet_52", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_53", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "-", "8935106479551152128L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_53", "=", "new", "BitSet", "(", "mk_tokenSet_53", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_54", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "-", "7169836166886785024L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_54", "=", "new", "BitSet", "(", "mk_tokenSet_54", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_55", "(", ")", "{", "long", "[", "]", "data", "=", "{", "4810363371520L", ",", "35888059800289280L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_55", "=", "new", "BitSet", "(", "mk_tokenSet_55", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_56", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "35888059884175360L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_56", "=", "new", "BitSet", "(", "mk_tokenSet_56", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_57", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "1801439855259942912L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_57", "=", "new", "BitSet", "(", "mk_tokenSet_57", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_58", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "1729382261205237760L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_58", "=", "new", "BitSet", "(", "mk_tokenSet_58", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_59", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371522L", ";", "data", "[", "1", "]", "=", "4359378822258425856L", ";", "data", "[", "2", "]", "=", "131104L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_59", "=", "new", "BitSet", "(", "mk_tokenSet_59", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_60", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "1729382261474721792L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_60", "=", "new", "BitSet", "(", "mk_tokenSet_60", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_61", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "269484032L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_61", "=", "new", "BitSet", "(", "mk_tokenSet_61", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_62", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "2017612637710319616L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_62", "=", "new", "BitSet", "(", "mk_tokenSet_62", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_63", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "2017612633061982208L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_63", "=", "new", "BitSet", "(", "mk_tokenSet_63", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_64", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "2053535815215579136L", ";", "data", "[", "2", "]", "=", "-", "6629298651002438191L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_64", "=", "new", "BitSet", "(", "mk_tokenSet_64", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_65", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "2053535810920611840L", ";", "data", "[", "2", "]", "=", "-", "6629298651002438191L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_65", "=", "new", "BitSet", "(", "mk_tokenSet_65", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_66", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "2151677952L", ",", "1L", ",", "0L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_66", "=", "new", "BitSet", "(", "mk_tokenSet_66", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_67", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "35116207308800L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_67", "=", "new", "BitSet", "(", "mk_tokenSet_67", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_68", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "36028801313947648L", ";", "data", "[", "2", "]", "=", "-", "1L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_68", "=", "new", "BitSet", "(", "mk_tokenSet_68", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_69", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "1477075058612994048L", ";", "data", "[", "2", "]", "=", "-", "6629298651002438191L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_69", "=", "new", "BitSet", "(", "mk_tokenSet_69", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_70", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "13893632L", ",", "2L", ",", "0L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_70", "=", "new", "BitSet", "(", "mk_tokenSet_70", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_71", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "108086395352907776L", ";", "data", "[", "2", "]", "=", "4L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_71", "=", "new", "BitSet", "(", "mk_tokenSet_71", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_72", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "137438953472L", ";", "data", "[", "1", "]", "=", "35115922227200L", ";", "data", "[", "2", "]", "=", "6L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_72", "=", "new", "BitSet", "(", "mk_tokenSet_72", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_73", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "2125593409261895680L", ";", "data", "[", "2", "]", "=", "-", "6629298651002438185L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_73", "=", "new", "BitSet", "(", "mk_tokenSet_73", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_74", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "289034119151618L", ";", "data", "[", "1", "]", "=", "-", "16384L", ";", "data", "[", "2", "]", "=", "-", "1L", ";", "data", "[", "3", "]", "=", "1023L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_74", "=", "new", "BitSet", "(", "mk_tokenSet_74", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_75", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "1981619085658046464L", ";", "data", "[", "2", "]", "=", "-", "6629298650967179279L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_75", "=", "new", "BitSet", "(", "mk_tokenSet_75", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_76", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440962L", ";", "data", "[", "1", "]", "=", "-", "36028797018980352L", ";", "data", "[", "2", "]", "=", "-", "1L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_76", "=", "new", "BitSet", "(", "mk_tokenSet_76", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_77", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "1477075058378080256L", ";", "data", "[", "2", "]", "=", "-", "6629298651002700799L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_77", "=", "new", "BitSet", "(", "mk_tokenSet_77", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_78", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "4294983680L", ";", "data", "[", "2", "]", "=", "-", "1L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_78", "=", "new", "BitSet", "(", "mk_tokenSet_78", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_79", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "35923175532855296L", ";", "data", "[", "2", "]", "=", "520L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_79", "=", "new", "BitSet", "(", "mk_tokenSet_79", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_80", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "35923175532855296L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_80", "=", "new", "BitSet", "(", "mk_tokenSet_80", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_81", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "288230376151711744L", ";", "data", "[", "2", "]", "=", "524288L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_81", "=", "new", "BitSet", "(", "mk_tokenSet_81", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_82", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "288265493971992576L", ";", "data", "[", "2", "]", "=", "-", "6629298651002732543L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_82", "=", "new", "BitSet", "(", "mk_tokenSet_82", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_83", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "2L", ";", "data", "[", "1", "]", "=", "4071254067438419968L", ";", "data", "[", "2", "]", "=", "131104L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_83", "=", "new", "BitSet", "(", "mk_tokenSet_83", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_84", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371520L", ";", "data", "[", "1", "]", "=", "324153553771233280L", ";", "data", "[", "2", "]", "=", "-", "6629298651002700799L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_84", "=", "new", "BitSet", "(", "mk_tokenSet_84", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_85", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "51539607552L", ",", "252201579132747776L", ",", "0L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_85", "=", "new", "BitSet", "(", "mk_tokenSet_85", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_86", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "-", "16L", ";", "data", "[", "1", "]", "=", "-", "288230376151711745L", ";", "data", "[", "2", "]", "=", "-", "1L", ";", "data", "[", "3", "]", "=", "536870911L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_86", "=", "new", "BitSet", "(", "mk_tokenSet_86", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_87", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "4810363371522L", ";", "data", "[", "1", "]", "=", "324153553771233280L", ";", "data", "[", "2", "]", "=", "-", "6629298651002700799L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_87", "=", "new", "BitSet", "(", "mk_tokenSet_87", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_88", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "1981619085658046464L", ";", "data", "[", "2", "]", "=", "522092529L", ";", "data", "[", "3", "]", "=", "506L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_88", "=", "new", "BitSet", "(", "mk_tokenSet_88", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_89", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "252201644102533120L", ";", "data", "[", "2", "]", "=", "-", "6629298650967179265L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_89", "=", "new", "BitSet", "(", "mk_tokenSet_89", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_90", "(", ")", "{", "long", "[", "]", "data", "=", "{", "7559142440960L", ",", "-", "2269849463977426944L", ",", "522092528L", ",", "0L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_90", "=", "new", "BitSet", "(", "mk_tokenSet_90", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_91", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "288265493971992576L", ";", "data", "[", "2", "]", "=", "486539265L", ";", "data", "[", "3", "]", "=", "506L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_91", "=", "new", "BitSet", "(", "mk_tokenSet_91", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_92", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "288230376177139712L", ";", "data", "[", "2", "]", "=", "14680064L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_92", "=", "new", "BitSet", "(", "mk_tokenSet_92", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_93", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "216172847075180544L", ";", "data", "[", "2", "]", "=", "-", "6629298650952499209L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_93", "=", "new", "BitSet", "(", "mk_tokenSet_93", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_94", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "8388608L", ",", "6291456L", ",", "0L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_94", "=", "new", "BitSet", "(", "mk_tokenSet_94", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_95", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440962L", ";", "data", "[", "1", "]", "=", "-", "268451840L", ";", "data", "[", "2", "]", "=", "-", "3L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_95", "=", "new", "BitSet", "(", "mk_tokenSet_95", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_96", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "8388608L", ";", "data", "[", "2", "]", "=", "14680064L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_96", "=", "new", "BitSet", "(", "mk_tokenSet_96", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_97", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "1981619087524773888L", ";", "data", "[", "2", "]", "=", "522092528L", ";", "data", "[", "3", "]", "=", "514L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_97", "=", "new", "BitSet", "(", "mk_tokenSet_97", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_98", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "8594128896L", ",", "27021597764223488L", ",", "0L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_98", "=", "new", "BitSet", "(", "mk_tokenSet_98", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_99", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "35115653660672L", ";", "data", "[", "3", "]", "=", "512L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_99", "=", "new", "BitSet", "(", "mk_tokenSet_99", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_100", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440962L", ";", "data", "[", "1", "]", "=", "-", "35244782665728L", ";", "data", "[", "2", "]", "=", "-", "6620291452249309187L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_100", "=", "new", "BitSet", "(", "mk_tokenSet_100", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_101", "(", ")", "{", "long", "[", "]", "data", "=", "{", "0L", ",", "35184372088832L", ",", "1729382256910270464L", ",", "0L", ",", "0L", ",", "0L", "}", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_101", "=", "new", "BitSet", "(", "mk_tokenSet_101", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_102", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440962L", ";", "data", "[", "1", "]", "=", "-", "276840448L", ";", "data", "[", "2", "]", "=", "-", "14680067L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_102", "=", "new", "BitSet", "(", "mk_tokenSet_102", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_103", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "1981583901016997888L", ";", "data", "[", "2", "]", "=", "-", "6629298650967179279L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_103", "=", "new", "BitSet", "(", "mk_tokenSet_103", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_104", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "1", "]", "=", "288265493972516864L", ";", "data", "[", "2", "]", "=", "-", "6629298651002732543L", ";", "data", "[", "3", "]", "=", "507L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_104", "=", "new", "BitSet", "(", "mk_tokenSet_104", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_105", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "8", "]", ";", "data", "[", "0", "]", "=", "7559142440960L", ";", "data", "[", "1", "]", "=", "-", "16384L", ";", "data", "[", "2", "]", "=", "-", "1L", ";", "data", "[", "3", "]", "=", "1019L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_105", "=", "new", "BitSet", "(", "mk_tokenSet_105", "(", ")", ")", ";", "}", "</s>" ]
6,706
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "parser", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "*", ";", "import", "java", ".", "util", ".", "*", ";", "import", "java", ".", "io", ".", "InputStream", ";", "import", "java", ".", "io", ".", "Reader", ";", "import", "antlr", ".", "InputBuffer", ";", "import", "antlr", ".", "LexerSharedInputState", ";", "import", "antlr", ".", "CommonToken", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "GroovyBugError", ";", "import", "antlr", ".", "TokenStreamRecognitionException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Comment", ";", "import", "java", ".", "io", ".", "InputStream", ";", "import", "antlr", ".", "TokenStreamException", ";", "import", "antlr", ".", "TokenStreamIOException", ";", "import", "antlr", ".", "TokenStreamRecognitionException", ";", "import", "antlr", ".", "CharStreamException", ";", "import", "antlr", ".", "CharStreamIOException", ";", "import", "antlr", ".", "ANTLRException", ";", "import", "java", ".", "io", ".", "Reader", ";", "import", "java", ".", "util", ".", "Hashtable", ";", "import", "antlr", ".", "CharScanner", ";", "import", "antlr", ".", "InputBuffer", ";", "import", "antlr", ".", "ByteBuffer", ";", "import", "antlr", ".", "CharBuffer", ";", "import", "antlr", ".", "Token", ";", "import", "antlr", ".", "CommonToken", ";", "import", "antlr", ".", "RecognitionException", ";", "import", "antlr", ".", "NoViableAltForCharException", ";", "import", "antlr", ".", "MismatchedCharException", ";", "import", "antlr", ".", "TokenStream", ";", "import", "antlr", ".", "ANTLRHashString", ";", "import", "antlr", ".", "LexerSharedInputState", ";", "import", "antlr", ".", "collections", ".", "impl", ".", "BitSet", ";", "import", "antlr", ".", "SemanticException", ";", "public", "class", "GroovyLexer", "extends", "antlr", ".", "CharScanner", "implements", "GroovyTokenTypes", ",", "TokenStream", "{", "private", "boolean", "assertEnabled", "=", "true", ";", "private", "boolean", "enumEnabled", "=", "true", ";", "private", "boolean", "whitespaceIncluded", "=", "false", ";", "public", "void", "enableAssert", "(", "boolean", "shouldEnable", ")", "{", "assertEnabled", "=", "shouldEnable", ";", "}", "public", "boolean", "isAssertEnabled", "(", ")", "{", "return", "assertEnabled", ";", "}", "public", "void", "enableEnum", "(", "boolean", "shouldEnable", ")", "{", "enumEnabled", "=", "shouldEnable", ";", "}", "public", "boolean", "isEnumEnabled", "(", ")", "{", "return", "enumEnabled", ";", "}", "public", "void", "setWhitespaceIncluded", "(", "boolean", "z", ")", "{", "whitespaceIncluded", "=", "z", ";", "}", "public", "boolean", "isWhitespaceIncluded", "(", ")", "{", "return", "whitespaceIncluded", ";", "}", "{", "setTabSize", "(", "1", ")", ";", "}", "protected", "int", "parenLevel", "=", "0", ";", "protected", "int", "suppressNewline", "=", "0", ";", "protected", "static", "final", "int", "SCS_TYPE", "=", "3", ",", "SCS_VAL", "=", "4", ",", "SCS_LIT", "=", "8", ",", "SCS_LIMIT", "=", "16", ";", "protected", "static", "final", "int", "SCS_SQ_TYPE", "=", "0", ",", "SCS_TQ_TYPE", "=", "1", ",", "SCS_RE_TYPE", "=", "2", ";", "protected", "int", "stringCtorState", "=", "0", ";", "protected", "ArrayList", "parenLevelStack", "=", "new", "ArrayList", "(", ")", ";", "protected", "int", "lastSigTokenType", "=", "EOF", ";", "public", "void", "setTokenObjectClass", "(", "String", "name", ")", "{", "}", "protected", "Token", "makeToken", "(", "int", "t", ")", "{", "GroovySourceToken", "tok", "=", "new", "GroovySourceToken", "(", "t", ")", ";", "tok", ".", "setColumn", "(", "inputState", ".", "getTokenStartColumn", "(", ")", ")", ";", "tok", ".", "setLine", "(", "inputState", ".", "getTokenStartLine", "(", ")", ")", ";", "tok", ".", "setColumnLast", "(", "inputState", ".", "getColumn", "(", ")", ")", ";", "tok", ".", "setLineLast", "(", "inputState", ".", "getLine", "(", ")", ")", ";", "return", "tok", ";", "}", "protected", "void", "pushParenLevel", "(", ")", "{", "parenLevelStack", ".", "add", "(", "Integer", ".", "valueOf", "(", "parenLevel", "*", "SCS_LIMIT", "+", "stringCtorState", ")", ")", ";", "parenLevel", "=", "0", ";", "stringCtorState", "=", "0", ";", "}", "protected", "void", "popParenLevel", "(", ")", "{", "int", "npl", "=", "parenLevelStack", ".", "size", "(", ")", ";", "if", "(", "npl", "==", "0", ")", "return", ";", "int", "i", "=", "(", "(", "Integer", ")", "parenLevelStack", ".", "remove", "(", "--", "npl", ")", ")", ".", "intValue", "(", ")", ";", "parenLevel", "=", "i", "/", "SCS_LIMIT", ";", "stringCtorState", "=", "i", "%", "SCS_LIMIT", ";", "}", "protected", "void", "restartStringCtor", "(", "boolean", "expectLiteral", ")", "{", "if", "(", "stringCtorState", "!=", "0", ")", "{", "stringCtorState", "=", "(", "expectLiteral", "?", "SCS_LIT", ":", "SCS_VAL", ")", "+", "(", "stringCtorState", "&", "SCS_TYPE", ")", ";", "}", "}", "protected", "boolean", "allowRegexpLiteral", "(", ")", "{", "return", "!", "isExpressionEndingToken", "(", "lastSigTokenType", ")", ";", "}", "protected", "static", "boolean", "isExpressionEndingToken", "(", "int", "ttype", ")", "{", "switch", "(", "ttype", ")", "{", "case", "INC", ":", "case", "DEC", ":", "case", "RPAREN", ":", "case", "RBRACK", ":", "case", "RCURLY", ":", "case", "STRING_LITERAL", ":", "case", "STRING_CTOR_END", ":", "case", "NUM_INT", ":", "case", "NUM_FLOAT", ":", "case", "NUM_LONG", ":", "case", "NUM_DOUBLE", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_BIG_DECIMAL", ":", "case", "IDENT", ":", "case", "LITERAL_as", ":", "case", "LITERAL_assert", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_break", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_case", ":", "case", "LITERAL_catch", ":", "case", "LITERAL_char", ":", "case", "LITERAL_class", ":", "case", "LITERAL_continue", ":", "case", "LITERAL_def", ":", "case", "LITERAL_default", ":", "case", "LITERAL_double", ":", "case", "LITERAL_else", ":", "case", "LITERAL_enum", ":", "case", "LITERAL_extends", ":", "case", "LITERAL_false", ":", "case", "LITERAL_finally", ":", "case", "LITERAL_float", ":", "case", "LITERAL_for", ":", "case", "LITERAL_if", ":", "case", "LITERAL_implements", ":", "case", "LITERAL_import", ":", "case", "LITERAL_in", ":", "case", "LITERAL_instanceof", ":", "case", "LITERAL_int", ":", "case", "LITERAL_interface", ":", "case", "LITERAL_long", ":", "case", "LITERAL_native", ":", "case", "LITERAL_new", ":", "case", "LITERAL_null", ":", "case", "LITERAL_package", ":", "case", "LITERAL_private", ":", "case", "LITERAL_protected", ":", "case", "LITERAL_public", ":", "case", "LITERAL_return", ":", "case", "LITERAL_short", ":", "case", "LITERAL_static", ":", "case", "LITERAL_super", ":", "case", "LITERAL_switch", ":", "case", "LITERAL_synchronized", ":", "case", "LITERAL_this", ":", "case", "LITERAL_threadsafe", ":", "case", "LITERAL_throw", ":", "case", "LITERAL_throws", ":", "case", "LITERAL_transient", ":", "case", "LITERAL_true", ":", "case", "LITERAL_try", ":", "case", "LITERAL_void", ":", "case", "LITERAL_volatile", ":", "case", "LITERAL_while", ":", "return", "true", ";", "default", ":", "return", "false", ";", "}", "}", "protected", "void", "newlineCheck", "(", "boolean", "check", ")", "throws", "RecognitionException", "{", "if", "(", "check", "&&", "suppressNewline", ">", "0", ")", "{", "require", "(", "suppressNewline", "==", "0", ",", "\"\"", ",", "\"\"", ")", ";", "suppressNewline", "=", "0", ";", "}", "newline", "(", ")", ";", "}", "protected", "boolean", "atValidDollarEscape", "(", ")", "throws", "CharStreamException", "{", "int", "k", "=", "1", ";", "char", "lc", "=", "LA", "(", "k", "++", ")", ";", "if", "(", "lc", "!=", "'$'", ")", "return", "false", ";", "lc", "=", "LA", "(", "k", "++", ")", ";", "if", "(", "lc", "==", "'*'", ")", "lc", "=", "LA", "(", "k", "++", ")", ";", "return", "(", "lc", "==", "'{'", "||", "(", "lc", "!=", "'$'", "&&", "Character", ".", "isJavaIdentifierStart", "(", "lc", ")", ")", ")", ";", "}", "public", "TokenStream", "plumb", "(", ")", "{", "return", "new", "TokenStream", "(", ")", "{", "public", "Token", "nextToken", "(", ")", "throws", "TokenStreamException", "{", "if", "(", "stringCtorState", ">=", "SCS_LIT", ")", "{", "int", "quoteType", "=", "(", "stringCtorState", "&", "SCS_TYPE", ")", ";", "stringCtorState", "=", "0", ";", "resetText", "(", ")", ";", "try", "{", "switch", "(", "quoteType", ")", "{", "case", "SCS_SQ_TYPE", ":", "mSTRING_CTOR_END", "(", "true", ",", "false", ",", "false", ")", ";", "break", ";", "case", "SCS_TQ_TYPE", ":", "mSTRING_CTOR_END", "(", "true", ",", "false", ",", "true", ")", ";", "break", ";", "case", "SCS_RE_TYPE", ":", "mREGEXP_CTOR_END", "(", "true", ",", "false", ")", ";", "break", ";", "default", ":", "throw", "new", "AssertionError", "(", "false", ")", ";", "}", "lastSigTokenType", "=", "_returnToken", ".", "getType", "(", ")", ";", "return", "_returnToken", ";", "}", "catch", "(", "RecognitionException", "e", ")", "{", "throw", "new", "TokenStreamRecognitionException", "(", "e", ")", ";", "}", "catch", "(", "CharStreamException", "cse", ")", "{", "if", "(", "cse", "instanceof", "CharStreamIOException", ")", "{", "throw", "new", "TokenStreamIOException", "(", "(", "(", "CharStreamIOException", ")", "cse", ")", ".", "io", ")", ";", "}", "else", "{", "throw", "new", "TokenStreamException", "(", "cse", ".", "getMessage", "(", ")", ")", ";", "}", "}", "}", "Token", "token", "=", "GroovyLexer", ".", "this", ".", "nextToken", "(", ")", ";", "int", "lasttype", "=", "token", ".", "getType", "(", ")", ";", "if", "(", "whitespaceIncluded", ")", "{", "switch", "(", "lasttype", ")", "{", "case", "WS", ":", "case", "ONE_NL", ":", "case", "SL_COMMENT", ":", "case", "ML_COMMENT", ":", "lasttype", "=", "lastSigTokenType", ";", "}", "}", "lastSigTokenType", "=", "lasttype", ";", "return", "token", ";", "}", "}", ";", "}", "public", "static", "boolean", "tracing", "=", "false", ";", "public", "void", "traceIn", "(", "String", "rname", ")", "throws", "CharStreamException", "{", "if", "(", "!", "GroovyLexer", ".", "tracing", ")", "return", ";", "super", ".", "traceIn", "(", "rname", ")", ";", "}", "public", "void", "traceOut", "(", "String", "rname", ")", "throws", "CharStreamException", "{", "if", "(", "!", "GroovyLexer", ".", "tracing", ")", "return", ";", "if", "(", "_returnToken", "!=", "null", ")", "rname", "+=", "tokenStringOf", "(", "_returnToken", ")", ";", "super", ".", "traceOut", "(", "rname", ")", ";", "}", "private", "static", "java", ".", "util", ".", "HashMap", "ttypes", ";", "private", "static", "String", "tokenStringOf", "(", "Token", "t", ")", "{", "if", "(", "ttypes", "==", "null", ")", "{", "java", ".", "util", ".", "HashMap", "map", "=", "new", "java", ".", "util", ".", "HashMap", "(", ")", ";", "java", ".", "lang", ".", "reflect", ".", "Field", "[", "]", "fields", "=", "GroovyTokenTypes", ".", "class", ".", "getDeclaredFields", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "fields", ".", "length", ";", "i", "++", ")", "{", "if", "(", "fields", "[", "i", "]", ".", "getType", "(", ")", "!=", "int", ".", "class", ")", "continue", ";", "try", "{", "map", ".", "put", "(", "fields", "[", "i", "]", ".", "get", "(", "null", ")", ",", "fields", "[", "i", "]", ".", "getName", "(", ")", ")", ";", "}", "catch", "(", "IllegalAccessException", "ee", ")", "{", "}", "}", "ttypes", "=", "map", ";", "}", "Integer", "tt", "=", "Integer", ".", "valueOf", "(", "t", ".", "getType", "(", ")", ")", ";", "Object", "ttn", "=", "ttypes", ".", "get", "(", "tt", ")", ";", "if", "(", "ttn", "==", "null", ")", "ttn", "=", "\"<\"", "+", "tt", "+", "\">\"", ";", "return", "\"[\"", "+", "ttn", "+", "\",\\\"\"", "+", "t", ".", "getText", "(", ")", "+", "\"\\\"]\"", ";", "}", "protected", "GroovyRecognizer", "parser", ";", "private", "void", "require", "(", "boolean", "z", ",", "String", "problem", ",", "String", "solution", ")", "throws", "SemanticException", "{", "if", "(", "!", "z", ")", "parser", ".", "requireFailed", "(", "problem", ",", "solution", ")", ";", "}", "public", "GroovyLexer", "(", "InputStream", "in", ")", "{", "this", "(", "new", "ByteBuffer", "(", "in", ")", ")", ";", "}", "public", "GroovyLexer", "(", "Reader", "in", ")", "{", "this", "(", "new", "CharBuffer", "(", "in", ")", ")", ";", "}", "public", "GroovyLexer", "(", "InputBuffer", "ib", ")", "{", "this", "(", "new", "LexerSharedInputState", "(", "ib", ")", ")", ";", "}", "public", "GroovyLexer", "(", "LexerSharedInputState", "state", ")", "{", "super", "(", "state", ")", ";", "caseSensitiveLiterals", "=", "true", ";", "setCaseSensitive", "(", "true", ")", ";", "literals", "=", "new", "Hashtable", "(", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"byte\"", ",", "this", ")", ",", "new", "Integer", "(", "102", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"public\"", ",", "this", ")", ",", "new", "Integer", "(", "112", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"case\"", ",", "this", ")", ",", "new", "Integer", "(", "145", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"short\"", ",", "this", ")", ",", "new", "Integer", "(", "104", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"break\"", ",", "this", ")", ",", "new", "Integer", "(", "139", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"while\"", ",", "this", ")", ",", "new", "Integer", "(", "134", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"new\"", ",", "this", ")", ",", "new", "Integer", "(", "154", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"instanceof\"", ",", "this", ")", ",", "new", "Integer", "(", "153", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"implements\"", ",", "this", ")", ",", "new", "Integer", "(", "127", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"synchronized\"", ",", "this", ")", ",", "new", "Integer", "(", "117", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"const\"", ",", "this", ")", ",", "new", "Integer", "(", "40", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"float\"", ",", "this", ")", ",", "new", "Integer", "(", "106", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"package\"", ",", "this", ")", ",", "new", "Integer", "(", "78", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"return\"", ",", "this", ")", ",", "new", "Integer", "(", "138", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"throw\"", ",", "this", ")", ",", "new", "Integer", "(", "141", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"null\"", ",", "this", ")", ",", "new", "Integer", "(", "155", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"def\"", ",", "this", ")", ",", "new", "Integer", "(", "81", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"threadsafe\"", ",", "this", ")", ",", "new", "Integer", "(", "116", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"protected\"", ",", "this", ")", ",", "new", "Integer", "(", "113", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"class\"", ",", "this", ")", ",", "new", "Integer", "(", "89", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"throws\"", ",", "this", ")", ",", "new", "Integer", "(", "126", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"do\"", ",", "this", ")", ",", "new", "Integer", "(", "41", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"strictfp\"", ",", "this", ")", ",", "new", "Integer", "(", "42", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"super\"", ",", "this", ")", ",", "new", "Integer", "(", "95", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"transient\"", ",", "this", ")", ",", "new", "Integer", "(", "114", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"native\"", ",", "this", ")", ",", "new", "Integer", "(", "115", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"interface\"", ",", "this", ")", ",", "new", "Integer", "(", "90", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"final\"", ",", "this", ")", ",", "new", "Integer", "(", "37", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"if\"", ",", "this", ")", ",", "new", "Integer", "(", "132", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"double\"", ",", "this", ")", ",", "new", "Integer", "(", "108", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"volatile\"", ",", "this", ")", ",", "new", "Integer", "(", "118", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"as\"", ",", "this", ")", ",", "new", "Integer", "(", "110", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"assert\"", ",", "this", ")", ",", "new", "Integer", "(", "142", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"catch\"", ",", "this", ")", ",", "new", "Integer", "(", "148", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"try\"", ",", "this", ")", ",", "new", "Integer", "(", "146", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"goto\"", ",", "this", ")", ",", "new", "Integer", "(", "39", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"enum\"", ",", "this", ")", ",", "new", "Integer", "(", "91", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"int\"", ",", "this", ")", ",", "new", "Integer", "(", "105", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"for\"", ",", "this", ")", ",", "new", "Integer", "(", "136", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"extends\"", ",", "this", ")", ",", "new", "Integer", "(", "94", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"boolean\"", ",", "this", ")", ",", "new", "Integer", "(", "101", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"char\"", ",", "this", ")", ",", "new", "Integer", "(", "103", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"private\"", ",", "this", ")", ",", "new", "Integer", "(", "111", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"default\"", ",", "this", ")", ",", "new", "Integer", "(", "125", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"false\"", ",", "this", ")", ",", "new", "Integer", "(", "152", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"this\"", ",", "this", ")", ",", "new", "Integer", "(", "128", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"static\"", ",", "this", ")", ",", "new", "Integer", "(", "80", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"abstract\"", ",", "this", ")", ",", "new", "Integer", "(", "38", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"continue\"", ",", "this", ")", ",", "new", "Integer", "(", "140", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"finally\"", ",", "this", ")", ",", "new", "Integer", "(", "147", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"else\"", ",", "this", ")", ",", "new", "Integer", "(", "133", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"import\"", ",", "this", ")", ",", "new", "Integer", "(", "79", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"in\"", ",", "this", ")", ",", "new", "Integer", "(", "137", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"void\"", ",", "this", ")", ",", "new", "Integer", "(", "100", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"switch\"", ",", "this", ")", ",", "new", "Integer", "(", "135", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"true\"", ",", "this", ")", ",", "new", "Integer", "(", "156", ")", ")", ";", "literals", ".", "put", "(", "new", "ANTLRHashString", "(", "\"long\"", ",", "this", ")", ",", "new", "Integer", "(", "107", ")", ")", ";", "}", "public", "Token", "nextToken", "(", ")", "throws", "TokenStreamException", "{", "Token", "theRetToken", "=", "null", ";", "tryAgain", ":", "for", "(", ";", ";", ")", "{", "Token", "_token", "=", "null", ";", "int", "_ttype", "=", "Token", ".", "INVALID_TYPE", ";", "resetText", "(", ")", ";", "try", "{", "try", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'('", ":", "{", "mLPAREN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "')'", ":", "{", "mRPAREN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "'['", ":", "{", "mLBRACK", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "']'", ":", "{", "mRBRACK", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "'{'", ":", "{", "mLCURLY", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "'}'", ":", "{", "mRCURLY", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "':'", ":", "{", "mCOLON", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "','", ":", "{", "mCOMMA", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "'~'", ":", "{", "mBNOT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "';'", ":", "{", "mSEMI", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "'\\t'", ":", "case", "'", "'", ":", "case", "'", "'", ":", "case", "'\\\\'", ":", "{", "mWS", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "'\\n'", ":", "case", "'\\r'", ":", "{", "mNLS", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "'\"'", ":", "case", "'\\''", ":", "{", "mSTRING_LITERAL", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "'0'", ":", "case", "'1'", ":", "case", "'2'", ":", "case", "'3'", ":", "case", "'4'", ":", "case", "'5'", ":", "case", "'6'", ":", "case", "'7'", ":", "case", "'8'", ":", "case", "'9'", ":", "{", "mNUM_INT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "case", "'@'", ":", "{", "mAT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "break", ";", "}", "default", ":", "if", "(", "(", "LA", "(", "1", ")", "==", "'>'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'>'", ")", "&&", "(", "LA", "(", "3", ")", "==", "'>'", ")", "&&", "(", "LA", "(", "4", ")", "==", "'='", ")", ")", "{", "mBSR_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'<'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", "&&", "(", "LA", "(", "3", ")", "==", "'>'", ")", ")", "{", "mCOMPARE_TO", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'='", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", "&&", "(", "LA", "(", "3", ")", "==", "'='", ")", ")", "{", "mIDENTICAL", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'!'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", "&&", "(", "LA", "(", "3", ")", "==", "'='", ")", ")", "{", "mNOT_IDENTICAL", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'>'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'>'", ")", "&&", "(", "LA", "(", "3", ")", "==", "'='", ")", ")", "{", "mSR_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'>'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'>'", ")", "&&", "(", "LA", "(", "3", ")", "==", "'>'", ")", "&&", "(", "true", ")", ")", "{", "mBSR", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'<'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'<'", ")", "&&", "(", "LA", "(", "3", ")", "==", "'='", ")", ")", "{", "mSL_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'.'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'.'", ")", "&&", "(", "LA", "(", "3", ")", "==", "'<'", ")", ")", "{", "mRANGE_EXCLUSIVE", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'.'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'.'", ")", "&&", "(", "LA", "(", "3", ")", "==", "'.'", ")", ")", "{", "mTRIPLE_DOT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'='", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", "&&", "(", "LA", "(", "3", ")", "==", "'~'", ")", ")", "{", "mREGEX_MATCH", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'*'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'*'", ")", "&&", "(", "LA", "(", "3", ")", "==", "'='", ")", ")", "{", "mSTAR_STAR_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'='", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", "&&", "(", "true", ")", ")", "{", "mEQUAL", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'!'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", "&&", "(", "true", ")", ")", "{", "mNOT_EQUAL", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'+'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", ")", "{", "mPLUS_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'+'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'+'", ")", ")", "{", "mINC", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'-'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", ")", "{", "mMINUS_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'-'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'-'", ")", ")", "{", "mDEC", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'*'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", ")", "{", "mSTAR_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'%'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", ")", "{", "mMOD_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'>'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'>'", ")", "&&", "(", "true", ")", ")", "{", "mSR", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'>'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", ")", "{", "mGE", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'<'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'<'", ")", "&&", "(", "true", ")", ")", "{", "mSL", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'<'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", "&&", "(", "true", ")", ")", "{", "mLE", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'^'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", ")", "{", "mBXOR_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'|'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", ")", "{", "mBOR_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'|'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'|'", ")", ")", "{", "mLOR", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'&'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", ")", "{", "mBAND_ASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'&'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'&'", ")", ")", "{", "mLAND", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'.'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'.'", ")", "&&", "(", "true", ")", ")", "{", "mRANGE_INCLUSIVE", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'*'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'.'", ")", ")", "{", "mSPREAD_DOT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'?'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'.'", ")", ")", "{", "mOPTIONAL_DOT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'?'", ")", "&&", "(", "LA", "(", "2", ")", "==", "':'", ")", ")", "{", "mELVIS_OPERATOR", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'.'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'&'", ")", ")", "{", "mMEMBER_POINTER", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'='", ")", "&&", "(", "LA", "(", "2", ")", "==", "'~'", ")", ")", "{", "mREGEX_FIND", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'*'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'*'", ")", "&&", "(", "true", ")", ")", "{", "mSTAR_STAR", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'-'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'>'", ")", ")", "{", "mCLOSABLE_BLOCK_OP", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'/'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'/'", ")", ")", "{", "mSL_COMMENT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'/'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'*'", ")", ")", "{", "mML_COMMENT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'?'", ")", "&&", "(", "true", ")", ")", "{", "mQUESTION", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'.'", ")", "&&", "(", "true", ")", ")", "{", "mDOT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'='", ")", "&&", "(", "true", ")", ")", "{", "mASSIGN", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'!'", ")", "&&", "(", "true", ")", ")", "{", "mLNOT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'+'", ")", "&&", "(", "true", ")", ")", "{", "mPLUS", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'-'", ")", "&&", "(", "true", ")", ")", "{", "mMINUS", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'*'", ")", "&&", "(", "true", ")", ")", "{", "mSTAR", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'%'", ")", "&&", "(", "true", ")", ")", "{", "mMOD", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'>'", ")", "&&", "(", "true", ")", ")", "{", "mGT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'<'", ")", "&&", "(", "true", ")", ")", "{", "mLT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'^'", ")", "&&", "(", "true", ")", ")", "{", "mBXOR", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'|'", ")", "&&", "(", "true", ")", ")", "{", "mBOR", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'&'", ")", "&&", "(", "true", ")", ")", "{", "mBAND", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'#'", ")", ")", "&&", "(", "getLine", "(", ")", "==", "1", "&&", "getColumn", "(", ")", "==", "1", ")", ")", "{", "mSH_COMMENT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'/'", ")", "&&", "(", "true", ")", ")", "{", "mREGEXP_LITERAL", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "if", "(", "(", "_tokenSet_0", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "mIDENT", "(", "true", ")", ";", "theRetToken", "=", "_returnToken", ";", "}", "else", "{", "if", "(", "LA", "(", "1", ")", "==", "EOF_CHAR", ")", "{", "uponEOF", "(", ")", ";", "_returnToken", "=", "makeToken", "(", "Token", ".", "EOF_TYPE", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "if", "(", "_returnToken", "==", "null", ")", "continue", "tryAgain", ";", "_ttype", "=", "_returnToken", ".", "getType", "(", ")", ";", "_returnToken", ".", "setType", "(", "_ttype", ")", ";", "return", "_returnToken", ";", "}", "catch", "(", "RecognitionException", "e", ")", "{", "throw", "new", "TokenStreamRecognitionException", "(", "e", ")", ";", "}", "}", "catch", "(", "CharStreamException", "cse", ")", "{", "if", "(", "cse", "instanceof", "CharStreamIOException", ")", "{", "throw", "new", "TokenStreamIOException", "(", "(", "(", "CharStreamIOException", ")", "cse", ")", ".", "io", ")", ";", "}", "else", "{", "throw", "new", "TokenStreamException", "(", "cse", ".", "getMessage", "(", ")", ")", ";", "}", "}", "}", "}", "public", "final", "void", "mQUESTION", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "QUESTION", ";", "int", "_saveIndex", ";", "match", "(", "'?'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mLPAREN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "LPAREN", ";", "int", "_saveIndex", ";", "match", "(", "'('", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "++", "parenLevel", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mRPAREN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "RPAREN", ";", "int", "_saveIndex", ";", "match", "(", "')'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "--", "parenLevel", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mLBRACK", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "LBRACK", ";", "int", "_saveIndex", ";", "match", "(", "'['", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "++", "parenLevel", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mRBRACK", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "RBRACK", ";", "int", "_saveIndex", ";", "match", "(", "']'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "--", "parenLevel", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mLCURLY", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "LCURLY", ";", "int", "_saveIndex", ";", "match", "(", "'{'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "pushParenLevel", "(", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mRCURLY", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "RCURLY", ";", "int", "_saveIndex", ";", "match", "(", "'}'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "popParenLevel", "(", ")", ";", "if", "(", "stringCtorState", "!=", "0", ")", "restartStringCtor", "(", "true", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mCOLON", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "COLON", ";", "int", "_saveIndex", ";", "match", "(", "':'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mCOMMA", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "COMMA", ";", "int", "_saveIndex", ";", "match", "(", "','", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mDOT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "DOT", ";", "int", "_saveIndex", ";", "match", "(", "'.'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "'='", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mCOMPARE_TO", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "COMPARE_TO", ";", "int", "_saveIndex", ";", "match", "(", "\"<=>\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mEQUAL", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "EQUAL", ";", "int", "_saveIndex", ";", "match", "(", "\"==\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mIDENTICAL", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "IDENTICAL", ";", "int", "_saveIndex", ";", "match", "(", "\"===\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mLNOT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "LNOT", ";", "int", "_saveIndex", ";", "match", "(", "'!'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mBNOT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BNOT", ";", "int", "_saveIndex", ";", "match", "(", "'~'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mNOT_EQUAL", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "NOT_EQUAL", ";", "int", "_saveIndex", ";", "match", "(", "\"!=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mNOT_IDENTICAL", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "NOT_IDENTICAL", ";", "int", "_saveIndex", ";", "match", "(", "\"!==\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mDIV", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "DIV", ";", "int", "_saveIndex", ";", "match", "(", "'/'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mDIV_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "DIV_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"/=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mPLUS", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "PLUS", ";", "int", "_saveIndex", ";", "match", "(", "'+'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mPLUS_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "PLUS_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"+=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mINC", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "INC", ";", "int", "_saveIndex", ";", "match", "(", "\"++\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mMINUS", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "MINUS", ";", "int", "_saveIndex", ";", "match", "(", "'-'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mMINUS_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "MINUS_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"-=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mDEC", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "DEC", ";", "int", "_saveIndex", ";", "match", "(", "\"--\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSTAR", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "STAR", ";", "int", "_saveIndex", ";", "match", "(", "'*'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSTAR_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "STAR_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"*=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mMOD", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "MOD", ";", "int", "_saveIndex", ";", "match", "(", "'%'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mMOD_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "MOD_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"%=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSR", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "SR", ";", "int", "_saveIndex", ";", "match", "(", "\">>\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSR_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "SR_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\">>=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mBSR", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BSR", ";", "int", "_saveIndex", ";", "match", "(", "\">>>\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mBSR_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BSR_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\">>>=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mGE", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "GE", ";", "int", "_saveIndex", ";", "match", "(", "\">=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mGT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "GT", ";", "int", "_saveIndex", ";", "match", "(", "\">\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSL", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "SL", ";", "int", "_saveIndex", ";", "match", "(", "\"<<\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSL_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "SL_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"<<=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mLE", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "LE", ";", "int", "_saveIndex", ";", "match", "(", "\"<=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mLT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "LT", ";", "int", "_saveIndex", ";", "match", "(", "'<'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mBXOR", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BXOR", ";", "int", "_saveIndex", ";", "match", "(", "'^'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mBXOR_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BXOR_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"^=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mBOR", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BOR", ";", "int", "_saveIndex", ";", "match", "(", "'|'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mBOR_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BOR_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"|=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mLOR", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "LOR", ";", "int", "_saveIndex", ";", "match", "(", "\"||\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mBAND", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BAND", ";", "int", "_saveIndex", ";", "match", "(", "'&'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mBAND_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BAND_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"&=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mLAND", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "LAND", ";", "int", "_saveIndex", ";", "match", "(", "\"&&\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSEMI", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "SEMI", ";", "int", "_saveIndex", ";", "match", "(", "';'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mDOLLAR", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "DOLLAR", ";", "int", "_saveIndex", ";", "match", "(", "'$'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mRANGE_INCLUSIVE", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "RANGE_INCLUSIVE", ";", "int", "_saveIndex", ";", "match", "(", "\"..\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mRANGE_EXCLUSIVE", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "RANGE_EXCLUSIVE", ";", "int", "_saveIndex", ";", "match", "(", "\"..<\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mTRIPLE_DOT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "TRIPLE_DOT", ";", "int", "_saveIndex", ";", "match", "(", "\"...\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSPREAD_DOT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "SPREAD_DOT", ";", "int", "_saveIndex", ";", "match", "(", "\"*.\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mOPTIONAL_DOT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "OPTIONAL_DOT", ";", "int", "_saveIndex", ";", "match", "(", "\"?.\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mELVIS_OPERATOR", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "ELVIS_OPERATOR", ";", "int", "_saveIndex", ";", "match", "(", "\"?:\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mMEMBER_POINTER", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "MEMBER_POINTER", ";", "int", "_saveIndex", ";", "match", "(", "\".&\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mREGEX_FIND", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "REGEX_FIND", ";", "int", "_saveIndex", ";", "match", "(", "\"=~\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mREGEX_MATCH", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "REGEX_MATCH", ";", "int", "_saveIndex", ";", "match", "(", "\"==~\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSTAR_STAR", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "STAR_STAR", ";", "int", "_saveIndex", ";", "match", "(", "\"**\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSTAR_STAR_ASSIGN", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "STAR_STAR_ASSIGN", ";", "int", "_saveIndex", ";", "match", "(", "\"**=\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mCLOSABLE_BLOCK_OP", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "CLOSABLE_BLOCK_OP", ";", "int", "_saveIndex", ";", "match", "(", "\"->\"", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mWS", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "WS", ";", "int", "_saveIndex", ";", "{", "int", "_cnt620", "=", "0", ";", "_loop620", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\\\'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'\\n'", "||", "LA", "(", "2", ")", "==", "'\\r'", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "match", "(", "'\\\\'", ")", ";", "mONE_NL", "(", "false", ",", "false", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'", "'", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "match", "(", "'", "'", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\t'", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "match", "(", "'\\t'", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'", "'", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "match", "(", "'\\f'", ")", ";", "}", "else", "{", "if", "(", "_cnt620", ">=", "1", ")", "{", "break", "_loop620", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "_cnt620", "++", ";", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "!", "whitespaceIncluded", ")", "_ttype", "=", "Token", ".", "SKIP", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mONE_NL", "(", "boolean", "_createToken", ",", "boolean", "check", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "ONE_NL", ";", "int", "_saveIndex", ";", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\r'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'\\n'", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "\"rn\"", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\r'", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'\\r'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\n'", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'\\n'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "newlineCheck", "(", "check", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mONE_NL_KEEP", "(", "boolean", "_createToken", ",", "boolean", "check", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "ONE_NL_KEEP", ";", "int", "_saveIndex", ";", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\r'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'\\n'", ")", "&&", "(", "(", "LA", "(", "3", ")", ">=", "'\u0000'", "&&", "LA", "(", "3", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "(", "LA", "(", "4", ")", ">=", "'\u0000'", "&&", "LA", "(", "4", ")", "<=", "'-UNK-'", ")", ")", ")", "{", "match", "(", "\"rn\"", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\r'", ")", "&&", "(", "(", "LA", "(", "2", ")", ">=", "'\u0000'", "&&", "LA", "(", "2", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "(", "LA", "(", "3", ")", ">=", "'\u0000'", "&&", "LA", "(", "3", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", ")", "{", "match", "(", "'\\r'", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\n'", ")", ")", "{", "match", "(", "'\\n'", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "newlineCheck", "(", "check", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mNLS", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "NLS", ";", "int", "_saveIndex", ";", "mONE_NL", "(", "false", ",", "true", ")", ";", "{", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'\\t'", "||", "LA", "(", "1", ")", "==", "'\\n'", "||", "LA", "(", "1", ")", "==", "'", "'", "||", "LA", "(", "1", ")", "==", "'\\r'", "||", "LA", "(", "1", ")", "==", "'", "'", "||", "LA", "(", "1", ")", "==", "'/'", "||", "LA", "(", "1", ")", "==", "'\\\\'", ")", ")", "&&", "(", "!", "whitespaceIncluded", ")", ")", "{", "{", "int", "_cnt628", "=", "0", ";", "_loop628", ":", "do", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'\\n'", ":", "case", "'\\r'", ":", "{", "mONE_NL", "(", "false", ",", "true", ")", ";", "break", ";", "}", "case", "'\\t'", ":", "case", "'", "'", ":", "case", "'", "'", ":", "case", "'\\\\'", ":", "{", "mWS", "(", "false", ")", ";", "break", ";", "}", "default", ":", "if", "(", "(", "LA", "(", "1", ")", "==", "'/'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'/'", ")", ")", "{", "mSL_COMMENT", "(", "false", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'/'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'*'", ")", ")", "{", "mML_COMMENT", "(", "false", ")", ";", "}", "else", "{", "if", "(", "_cnt628", ">=", "1", ")", "{", "break", "_loop628", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "_cnt628", "++", ";", "}", "while", "(", "true", ")", ";", "}", "}", "else", "{", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "whitespaceIncluded", ")", "{", "}", "else", "if", "(", "parenLevel", "!=", "0", ")", "{", "_ttype", "=", "Token", ".", "SKIP", ";", "}", "else", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "\"<newline>\"", ")", ";", "}", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSL_COMMENT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "SL_COMMENT", ";", "int", "_saveIndex", ";", "match", "(", "\"//\"", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "parser", "!=", "null", ")", "{", "parser", ".", "startComment", "(", "inputState", ".", "getLine", "(", ")", ",", "inputState", ".", "getColumn", "(", ")", "-", "2", ")", ";", "}", "}", "{", "_loop632", ":", "do", "{", "if", "(", "(", "_tokenSet_1", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "{", "match", "(", "_tokenSet_1", ")", ";", "}", "}", "else", "{", "break", "_loop632", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "parser", "!=", "null", ")", "{", "parser", ".", "endComment", "(", "0", ",", "inputState", ".", "getLine", "(", ")", ",", "inputState", ".", "getColumn", "(", ")", ",", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "if", "(", "!", "whitespaceIncluded", ")", "_ttype", "=", "Token", ".", "SKIP", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mML_COMMENT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "ML_COMMENT", ";", "int", "_saveIndex", ";", "match", "(", "\"/*\"", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "parser", "!=", "null", ")", "{", "parser", ".", "startComment", "(", "inputState", ".", "getLine", "(", ")", ",", "inputState", ".", "getColumn", "(", ")", "-", "2", ")", ";", "}", "}", "{", "_loop642", ":", "do", "{", "boolean", "synPredMatched640", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'*'", ")", "&&", "(", "(", "LA", "(", "2", ")", ">=", "'\u0000'", "&&", "LA", "(", "2", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "(", "LA", "(", "3", ")", ">=", "'\u0000'", "&&", "LA", "(", "3", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", ")", ")", "{", "int", "_m640", "=", "mark", "(", ")", ";", "synPredMatched640", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "'*'", ")", ";", "matchNot", "(", "'/'", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched640", "=", "false", ";", "}", "rewind", "(", "_m640", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched640", ")", "{", "match", "(", "'*'", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\n'", "||", "LA", "(", "1", ")", "==", "'\\r'", ")", ")", "{", "mONE_NL_KEEP", "(", "false", ",", "true", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "match", "(", "_tokenSet_2", ")", ";", "}", "}", "else", "{", "break", "_loop642", ";", "}", "}", "while", "(", "true", ")", ";", "}", "match", "(", "\"*/\"", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "parser", "!=", "null", ")", "{", "parser", ".", "endComment", "(", "1", ",", "inputState", ".", "getLine", "(", ")", ",", "inputState", ".", "getColumn", "(", ")", ",", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "if", "(", "!", "whitespaceIncluded", ")", "_ttype", "=", "Token", ".", "SKIP", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSH_COMMENT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "SH_COMMENT", ";", "int", "_saveIndex", ";", "if", "(", "!", "(", "getLine", "(", ")", "==", "1", "&&", "getColumn", "(", ")", "==", "1", ")", ")", "throw", "new", "SemanticException", "(", "\"\"", ")", ";", "match", "(", "\"#!\"", ")", ";", "{", "_loop636", ":", "do", "{", "if", "(", "(", "_tokenSet_1", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "match", "(", "_tokenSet_1", ")", ";", "}", "}", "else", "{", "break", "_loop636", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "!", "whitespaceIncluded", ")", "_ttype", "=", "Token", ".", "SKIP", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mSTRING_LITERAL", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "STRING_LITERAL", ";", "int", "_saveIndex", ";", "int", "tt", "=", "0", ";", "boolean", "synPredMatched645", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'\\''", ")", "&&", "(", "LA", "(", "2", ")", "==", "'\\''", ")", "&&", "(", "LA", "(", "3", ")", "==", "'\\''", ")", "&&", "(", "(", "LA", "(", "4", ")", ">=", "'\u0000'", "&&", "LA", "(", "4", ")", "<=", "'-UNK-'", ")", ")", ")", ")", "{", "int", "_m645", "=", "mark", "(", ")", ";", "synPredMatched645", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "\"'''\"", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched645", "=", "false", ";", "}", "rewind", "(", "_m645", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched645", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "\"'''\"", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "{", "_loop650", ":", "do", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'\\\\'", ":", "{", "mESC", "(", "false", ")", ";", "break", ";", "}", "case", "'\"'", ":", "{", "match", "(", "'\"'", ")", ";", "break", ";", "}", "case", "'$'", ":", "{", "match", "(", "'$'", ")", ";", "break", ";", "}", "case", "'\\n'", ":", "case", "'\\r'", ":", "{", "mSTRING_NL", "(", "false", ",", "true", ")", ";", "break", ";", "}", "default", ":", "boolean", "synPredMatched649", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'\\''", ")", "&&", "(", "(", "LA", "(", "2", ")", ">=", "'\u0000'", "&&", "LA", "(", "2", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "(", "LA", "(", "3", ")", ">=", "'\u0000'", "&&", "LA", "(", "3", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "(", "LA", "(", "4", ")", ">=", "'\u0000'", "&&", "LA", "(", "4", ")", "<=", "'-UNK-'", ")", ")", ")", ")", "{", "int", "_m649", "=", "mark", "(", ")", ";", "synPredMatched649", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "'\\''", ")", ";", "{", "if", "(", "(", "_tokenSet_3", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "matchNot", "(", "'\\''", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\''", ")", ")", "{", "match", "(", "'\\''", ")", ";", "matchNot", "(", "'\\''", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched649", "=", "false", ";", "}", "rewind", "(", "_m649", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched649", ")", "{", "match", "(", "'\\''", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_4", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "mSTRING_CH", "(", "false", ")", ";", "}", "else", "{", "break", "_loop650", ";", "}", "}", "}", "while", "(", "true", ")", ";", "}", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "\"'''\"", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "}", "else", "{", "boolean", "synPredMatched654", "=", "false", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'\"'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'\"'", ")", "&&", "(", "LA", "(", "3", ")", "==", "'\"'", ")", "&&", "(", "(", "LA", "(", "4", ")", ">=", "'\u0000'", "&&", "LA", "(", "4", ")", "<=", "'-UNK-'", ")", ")", ")", ")", "{", "int", "_m654", "=", "mark", "(", ")", ";", "synPredMatched654", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "\"\\\"\\\"\\\"\"", ")", ";", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched654", "=", "false", ";", "}", "rewind", "(", "_m654", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched654", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "\"\\\"\\\"\\\"\"", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "tt", "=", "mSTRING_CTOR_END", "(", "false", ",", "true", ",", "true", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "tt", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\''", ")", "&&", "(", "_tokenSet_1", ".", "member", "(", "LA", "(", "2", ")", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'\\''", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "++", "suppressNewline", ";", "}", "{", "_loop652", ":", "do", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'\\\\'", ":", "{", "mESC", "(", "false", ")", ";", "break", ";", "}", "case", "'\"'", ":", "{", "match", "(", "'\"'", ")", ";", "break", ";", "}", "case", "'$'", ":", "{", "match", "(", "'$'", ")", ";", "break", ";", "}", "default", ":", "if", "(", "(", "_tokenSet_4", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "mSTRING_CH", "(", "false", ")", ";", "}", "else", "{", "break", "_loop652", ";", "}", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "--", "suppressNewline", ";", "}", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'\\''", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\"'", ")", "&&", "(", "(", "LA", "(", "2", ")", ">=", "'\u0000'", "&&", "LA", "(", "2", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'\"'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "++", "suppressNewline", ";", "}", "tt", "=", "mSTRING_CTOR_END", "(", "false", ",", "true", ",", "false", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "tt", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mSTRING_CH", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "STRING_CH", ";", "int", "_saveIndex", ";", "{", "match", "(", "_tokenSet_4", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mESC", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "ESC", ";", "int", "_saveIndex", ";", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\\\'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'\"'", "||", "LA", "(", "2", ")", "==", "'$'", "||", "LA", "(", "2", ")", "==", "'\\''", "||", "LA", "(", "2", ")", "==", "'0'", "||", "LA", "(", "2", ")", "==", "'1'", "||", "LA", "(", "2", ")", "==", "'2'", "||", "LA", "(", "2", ")", "==", "'3'", "||", "LA", "(", "2", ")", "==", "'4'", "||", "LA", "(", "2", ")", "==", "'5'", "||", "LA", "(", "2", ")", "==", "'6'", "||", "LA", "(", "2", ")", "==", "'7'", "||", "LA", "(", "2", ")", "==", "'\\\\'", "||", "LA", "(", "2", ")", "==", "'b'", "||", "LA", "(", "2", ")", "==", "'f'", "||", "LA", "(", "2", ")", "==", "'n'", "||", "LA", "(", "2", ")", "==", "'r'", "||", "LA", "(", "2", ")", "==", "'t'", "||", "LA", "(", "2", ")", "==", "'u'", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'\\\\'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'n'", ":", "{", "match", "(", "'n'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "\"n\"", ")", ";", "}", "break", ";", "}", "case", "'r'", ":", "{", "match", "(", "'r'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "\"r\"", ")", ";", "}", "break", ";", "}", "case", "'t'", ":", "{", "match", "(", "'t'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "\"t\"", ")", ";", "}", "break", ";", "}", "case", "'b'", ":", "{", "match", "(", "'b'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "\"\b\"", ")", ";", "}", "break", ";", "}", "case", "'f'", ":", "{", "match", "(", "'f'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "\"", "\"", ")", ";", "}", "break", ";", "}", "case", "'\"'", ":", "{", "match", "(", "'\"'", ")", ";", "break", ";", "}", "case", "'\\''", ":", "{", "match", "(", "'\\''", ")", ";", "break", ";", "}", "case", "'\\\\'", ":", "{", "match", "(", "'\\\\'", ")", ";", "break", ";", "}", "case", "'$'", ":", "{", "match", "(", "'$'", ")", ";", "break", ";", "}", "case", "'u'", ":", "{", "{", "int", "_cnt679", "=", "0", ";", "_loop679", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "'u'", ")", ")", "{", "match", "(", "'u'", ")", ";", "}", "else", "{", "if", "(", "_cnt679", ">=", "1", ")", "{", "break", "_loop679", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "_cnt679", "++", ";", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "\"\"", ")", ";", "}", "mHEX_DIGIT", "(", "false", ")", ";", "mHEX_DIGIT", "(", "false", ")", ";", "mHEX_DIGIT", "(", "false", ")", ";", "mHEX_DIGIT", "(", "false", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "char", "ch", "=", "(", "char", ")", "Integer", ".", "parseInt", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ",", "16", ")", ";", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "ch", ")", ";", "}", "break", ";", "}", "case", "'0'", ":", "case", "'1'", ":", "case", "'2'", ":", "case", "'3'", ":", "{", "matchRange", "(", "'0'", ",", "'3'", ")", ";", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'7'", ")", ")", "&&", "(", "(", "LA", "(", "2", ")", ">=", "'\u0000'", "&&", "LA", "(", "2", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "matchRange", "(", "'0'", ",", "'7'", ")", ";", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'7'", ")", ")", "&&", "(", "(", "LA", "(", "2", ")", ">=", "'\u0000'", "&&", "LA", "(", "2", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "matchRange", "(", "'0'", ",", "'7'", ")", ";", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'\u0000'", "&&", "LA", "(", "1", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'\u0000'", "&&", "LA", "(", "1", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "char", "ch", "=", "(", "char", ")", "Integer", ".", "parseInt", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ",", "8", ")", ";", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "ch", ")", ";", "}", "break", ";", "}", "case", "'4'", ":", "case", "'5'", ":", "case", "'6'", ":", "case", "'7'", ":", "{", "matchRange", "(", "'4'", ",", "'7'", ")", ";", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'7'", ")", ")", "&&", "(", "(", "LA", "(", "2", ")", ">=", "'\u0000'", "&&", "LA", "(", "2", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "matchRange", "(", "'0'", ",", "'7'", ")", ";", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'\u0000'", "&&", "LA", "(", "1", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "char", "ch", "=", "(", "char", ")", "Integer", ".", "parseInt", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ",", "8", ")", ";", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "ch", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\\\'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'\\n'", "||", "LA", "(", "2", ")", "==", "'\\r'", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'\\\\'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "mONE_NL", "(", "false", ",", "false", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mSTRING_NL", "(", "boolean", "_createToken", ",", "boolean", "allowNewline", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "STRING_NL", ";", "int", "_saveIndex", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "!", "allowNewline", ")", "throw", "new", "MismatchedCharException", "(", "'\\n'", ",", "'\\n'", ",", "true", ",", "this", ")", ";", "}", "mONE_NL", "(", "false", ",", "false", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "'\\n'", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "int", "mSTRING_CTOR_END", "(", "boolean", "_createToken", ",", "boolean", "fromStart", ",", "boolean", "tripleQuote", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "tt", "=", "STRING_CTOR_END", ";", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "STRING_CTOR_END", ";", "int", "_saveIndex", ";", "boolean", "dollarOK", "=", "false", ";", "{", "_loop660", ":", "do", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'\\\\'", ":", "{", "mESC", "(", "false", ")", ";", "break", ";", "}", "case", "'\\''", ":", "{", "match", "(", "'\\''", ")", ";", "break", ";", "}", "case", "'\\n'", ":", "case", "'\\r'", ":", "{", "mSTRING_NL", "(", "false", ",", "tripleQuote", ")", ";", "break", ";", "}", "default", ":", "boolean", "synPredMatched659", "=", "false", ";", "if", "(", "(", "(", "(", "LA", "(", "1", ")", "==", "'\"'", ")", "&&", "(", "(", "LA", "(", "2", ")", ">=", "'\u0000'", "&&", "LA", "(", "2", ")", "<=", "'-UNK-'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "&&", "(", "tripleQuote", ")", ")", ")", "{", "int", "_m659", "=", "mark", "(", ")", ";", "synPredMatched659", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "match", "(", "'\"'", ")", ";", "{", "if", "(", "(", "_tokenSet_5", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "matchNot", "(", "'\"'", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\"'", ")", ")", "{", "match", "(", "'\"'", ")", ";", "matchNot", "(", "'\"'", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched659", "=", "false", ";", "}", "rewind", "(", "_m659", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched659", ")", "{", "match", "(", "'\"'", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_4", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "mSTRING_CH", "(", "false", ")", ";", "}", "else", "{", "break", "_loop660", ";", "}", "}", "}", "while", "(", "true", ")", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'\"'", ":", "{", "{", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'\"'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'\"'", ")", ")", "&&", "(", "tripleQuote", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "\"\\\"\\\"\\\"\"", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'\"'", ")", "&&", "(", "true", ")", ")", "&&", "(", "!", "tripleQuote", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "\"\\\"\"", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "fromStart", ")", "tt", "=", "STRING_LITERAL", ";", "if", "(", "!", "tripleQuote", ")", "{", "--", "suppressNewline", ";", "}", "}", "break", ";", "}", "case", "'$'", ":", "{", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "dollarOK", "=", "atValidDollarEscape", "(", ")", ";", "}", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'$'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "require", "(", "dollarOK", ",", "\"\"", ",", "\"\"", ")", ";", "tt", "=", "(", "fromStart", "?", "STRING_CTOR_START", ":", "STRING_CTOR_MIDDLE", ")", ";", "stringCtorState", "=", "SCS_VAL", "+", "(", "tripleQuote", "?", "SCS_TQ_TYPE", ":", "SCS_SQ_TYPE", ")", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "tt", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "return", "tt", ";", "}", "public", "final", "void", "mREGEXP_LITERAL", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "REGEXP_LITERAL", ";", "int", "_saveIndex", ";", "int", "tt", "=", "0", ";", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'/'", ")", "&&", "(", "_tokenSet_6", ".", "member", "(", "LA", "(", "2", ")", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "&&", "(", "allowRegexpLiteral", "(", ")", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'/'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "++", "suppressNewline", ";", "}", "{", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'$'", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "&&", "(", "!", "atValidDollarEscape", "(", ")", ")", ")", "{", "match", "(", "'$'", ")", ";", "tt", "=", "mREGEXP_CTOR_END", "(", "false", ",", "true", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_7", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "mREGEXP_SYMBOL", "(", "false", ")", ";", "tt", "=", "mREGEXP_CTOR_END", "(", "false", ",", "true", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'$'", ")", "&&", "(", "true", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'$'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "tt", "=", "STRING_CTOR_START", ";", "stringCtorState", "=", "SCS_VAL", "+", "SCS_RE_TYPE", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "tt", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'/'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'='", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "mDIV_ASSIGN", "(", "false", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "DIV_ASSIGN", ";", "}", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'/'", ")", "&&", "(", "true", ")", ")", "{", "mDIV", "(", "false", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "DIV", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mREGEXP_SYMBOL", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "REGEXP_SYMBOL", ";", "int", "_saveIndex", ";", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\\\'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'/'", ")", "&&", "(", "_tokenSet_1", ".", "member", "(", "LA", "(", "3", ")", ")", ")", "&&", "(", "true", ")", ")", "{", "match", "(", "'\\\\'", ")", ";", "match", "(", "'/'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "'/'", ")", ";", "}", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'\\\\'", ")", "&&", "(", "_tokenSet_1", ".", "member", "(", "LA", "(", "2", ")", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "&&", "(", "LA", "(", "2", ")", "!=", "'/'", "&&", "LA", "(", "2", ")", "!=", "'\\n'", "&&", "LA", "(", "2", ")", "!=", "'\\r'", ")", ")", "{", "match", "(", "'\\\\'", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'\\\\'", ")", "&&", "(", "LA", "(", "2", ")", "==", "'\\n'", "||", "LA", "(", "2", ")", "==", "'\\r'", ")", ")", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'\\\\'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "mONE_NL", "(", "false", ",", "false", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "text", ".", "setLength", "(", "_begin", ")", ";", "text", ".", "append", "(", "'\\n'", ")", ";", "}", "}", "else", "if", "(", "(", "_tokenSet_8", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "{", "match", "(", "_tokenSet_8", ")", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "{", "_loop675", ":", "do", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "'*'", ")", ")", "{", "match", "(", "'*'", ")", ";", "}", "else", "{", "break", "_loop675", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "int", "mREGEXP_CTOR_END", "(", "boolean", "_createToken", ",", "boolean", "fromStart", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "tt", "=", "STRING_CTOR_END", ";", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "REGEXP_CTOR_END", ";", "int", "_saveIndex", ";", "{", "_loop669", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", "==", "'$'", ")", "&&", "(", "_tokenSet_2", ".", "member", "(", "LA", "(", "2", ")", ")", ")", ")", "&&", "(", "!", "atValidDollarEscape", "(", ")", ")", ")", "{", "match", "(", "'$'", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_7", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "mREGEXP_SYMBOL", "(", "false", ")", ";", "}", "else", "{", "break", "_loop669", ";", "}", "}", "while", "(", "true", ")", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'/'", ":", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'/'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "fromStart", ")", "tt", "=", "STRING_LITERAL", ";", "{", "--", "suppressNewline", ";", "}", "}", "break", ";", "}", "case", "'$'", ":", "{", "_saveIndex", "=", "text", ".", "length", "(", ")", ";", "match", "(", "'$'", ")", ";", "text", ".", "setLength", "(", "_saveIndex", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "tt", "=", "(", "fromStart", "?", "STRING_CTOR_START", ":", "STRING_CTOR_MIDDLE", ")", ";", "stringCtorState", "=", "SCS_VAL", "+", "SCS_RE_TYPE", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "tt", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "return", "tt", ";", "}", "protected", "final", "void", "mHEX_DIGIT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "HEX_DIGIT", ";", "int", "_saveIndex", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'0'", ":", "case", "'1'", ":", "case", "'2'", ":", "case", "'3'", ":", "case", "'4'", ":", "case", "'5'", ":", "case", "'6'", ":", "case", "'7'", ":", "case", "'8'", ":", "case", "'9'", ":", "{", "matchRange", "(", "'0'", ",", "'9'", ")", ";", "break", ";", "}", "case", "'A'", ":", "case", "'B'", ":", "case", "'C'", ":", "case", "'D'", ":", "case", "'E'", ":", "case", "'F'", ":", "{", "matchRange", "(", "'A'", ",", "'F'", ")", ";", "break", ";", "}", "case", "'a'", ":", "case", "'b'", ":", "case", "'c'", ":", "case", "'d'", ":", "case", "'e'", ":", "case", "'f'", ":", "{", "matchRange", "(", "'a'", ",", "'f'", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mVOCAB", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "VOCAB", ";", "int", "_saveIndex", ";", "matchRange", "(", "'\\3'", ",", "'\\377'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mIDENT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "IDENT", ";", "int", "_saveIndex", ";", "{", "if", "(", "(", "(", "_tokenSet_0", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "&&", "(", "stringCtorState", "==", "0", ")", ")", "{", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "'$'", ")", ")", "{", "mDOLLAR", "(", "false", ")", ";", "}", "else", "if", "(", "(", "_tokenSet_9", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "mLETTER", "(", "false", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "{", "_loop691", ":", "do", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'0'", ":", "case", "'1'", ":", "case", "'2'", ":", "case", "'3'", ":", "case", "'4'", ":", "case", "'5'", ":", "case", "'6'", ":", "case", "'7'", ":", "case", "'8'", ":", "case", "'9'", ":", "{", "mDIGIT", "(", "false", ")", ";", "break", ";", "}", "case", "'$'", ":", "{", "mDOLLAR", "(", "false", ")", ";", "break", ";", "}", "default", ":", "if", "(", "(", "_tokenSet_9", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "mLETTER", "(", "false", ")", ";", "}", "else", "{", "break", "_loop691", ";", "}", "}", "}", "while", "(", "true", ")", ";", "}", "}", "else", "if", "(", "(", "_tokenSet_9", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "mLETTER", "(", "false", ")", ";", "{", "_loop693", ":", "do", "{", "if", "(", "(", "_tokenSet_9", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "mLETTER", "(", "false", ")", ";", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'9'", ")", ")", ")", "{", "mDIGIT", "(", "false", ")", ";", "}", "else", "{", "break", "_loop693", ";", "}", "}", "while", "(", "true", ")", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "if", "(", "stringCtorState", "!=", "0", ")", "{", "if", "(", "LA", "(", "1", ")", "==", "'.'", "&&", "LA", "(", "2", ")", "!=", "'$'", "&&", "Character", ".", "isJavaIdentifierStart", "(", "LA", "(", "2", ")", ")", ")", "{", "restartStringCtor", "(", "false", ")", ";", "}", "else", "{", "restartStringCtor", "(", "true", ")", ";", "}", "}", "int", "ttype", "=", "testLiteralsTable", "(", "IDENT", ")", ";", "if", "(", "(", "ttype", "==", "LITERAL_as", "||", "ttype", "==", "LITERAL_def", "||", "ttype", "==", "LITERAL_in", ")", "&&", "(", "LA", "(", "1", ")", "==", "'.'", "||", "lastSigTokenType", "==", "DOT", "||", "lastSigTokenType", "==", "LITERAL_package", ")", ")", "{", "ttype", "=", "IDENT", ";", "}", "if", "(", "ttype", "==", "LITERAL_static", "&&", "LA", "(", "1", ")", "==", "'.'", ")", "{", "ttype", "=", "IDENT", ";", "}", "_ttype", "=", "ttype", ";", "if", "(", "assertEnabled", "&&", "\"assert\"", ".", "equals", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ")", "{", "_ttype", "=", "LITERAL_assert", ";", "}", "if", "(", "enumEnabled", "&&", "\"enum\"", ".", "equals", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ")", "{", "_ttype", "=", "LITERAL_enum", ";", "}", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mLETTER", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "LETTER", ";", "int", "_saveIndex", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'a'", ":", "case", "'b'", ":", "case", "'c'", ":", "case", "'d'", ":", "case", "'e'", ":", "case", "'f'", ":", "case", "'g'", ":", "case", "'h'", ":", "case", "'i'", ":", "case", "'j'", ":", "case", "'k'", ":", "case", "'l'", ":", "case", "'m'", ":", "case", "'n'", ":", "case", "'o'", ":", "case", "'p'", ":", "case", "'q'", ":", "case", "'r'", ":", "case", "'s'", ":", "case", "'t'", ":", "case", "'u'", ":", "case", "'v'", ":", "case", "'w'", ":", "case", "'x'", ":", "case", "'y'", ":", "case", "'z'", ":", "{", "matchRange", "(", "'a'", ",", "'z'", ")", ";", "break", ";", "}", "case", "'A'", ":", "case", "'B'", ":", "case", "'C'", ":", "case", "'D'", ":", "case", "'E'", ":", "case", "'F'", ":", "case", "'G'", ":", "case", "'H'", ":", "case", "'I'", ":", "case", "'J'", ":", "case", "'K'", ":", "case", "'L'", ":", "case", "'M'", ":", "case", "'N'", ":", "case", "'O'", ":", "case", "'P'", ":", "case", "'Q'", ":", "case", "'R'", ":", "case", "'S'", ":", "case", "'T'", ":", "case", "'U'", ":", "case", "'V'", ":", "case", "'W'", ":", "case", "'X'", ":", "case", "'Y'", ":", "case", "'Z'", ":", "{", "matchRange", "(", "'A'", ",", "'Z'", ")", ";", "break", ";", "}", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "{", "matchRange", "(", "'-UNK-'", ",", "'-UNK-'", ")", ";", "break", ";", "}", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "{", "matchRange", "(", "'-UNK-'", ",", "'-UNK-'", ")", ";", "break", ";", "}", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "case", "'-UNK-'", ":", "{", "matchRange", "(", "'-UNK-'", ",", "'-UNK-'", ")", ";", "break", ";", "}", "case", "'_'", ":", "{", "match", "(", "'_'", ")", ";", "break", ";", "}", "default", ":", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'-UNK-'", "&&", "LA", "(", "1", ")", "<=", "'-UNK-'", ")", ")", ")", "{", "matchRange", "(", "'-UNK-'", ",", "'-UNK-'", ")", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mDIGIT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "DIGIT", ";", "int", "_saveIndex", ";", "matchRange", "(", "'0'", ",", "'9'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mNUM_INT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "NUM_INT", ";", "int", "_saveIndex", ";", "Token", "f2", "=", "null", ";", "Token", "g2", "=", "null", ";", "Token", "f3", "=", "null", ";", "Token", "g3", "=", "null", ";", "Token", "f4", "=", "null", ";", "boolean", "isDecimal", "=", "false", ";", "Token", "t", "=", "null", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'0'", ":", "{", "match", "(", "'0'", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "isDecimal", "=", "true", ";", "}", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "'X'", "||", "LA", "(", "1", ")", "==", "'x'", ")", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'x'", ":", "{", "match", "(", "'x'", ")", ";", "break", ";", "}", "case", "'X'", ":", "{", "match", "(", "'X'", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "isDecimal", "=", "false", ";", "}", "{", "int", "_cnt701", "=", "0", ";", "_loop701", ":", "do", "{", "if", "(", "(", "_tokenSet_10", ".", "member", "(", "LA", "(", "1", ")", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "mHEX_DIGIT", "(", "false", ")", ";", "}", "else", "{", "if", "(", "_cnt701", ">=", "1", ")", "{", "break", "_loop701", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "_cnt701", "++", ";", "}", "while", "(", "true", ")", ";", "}", "}", "else", "{", "boolean", "synPredMatched707", "=", "false", ";", "if", "(", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'9'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", ")", "{", "int", "_m707", "=", "mark", "(", ")", ";", "synPredMatched707", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "{", "int", "_cnt704", "=", "0", ";", "_loop704", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'9'", ")", ")", ")", "{", "matchRange", "(", "'0'", ",", "'9'", ")", ";", "}", "else", "{", "if", "(", "_cnt704", ">=", "1", ")", "{", "break", "_loop704", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "_cnt704", "++", ";", "}", "while", "(", "true", ")", ";", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'.'", ":", "{", "match", "(", "'.'", ")", ";", "{", "matchRange", "(", "'0'", ",", "'9'", ")", ";", "}", "break", ";", "}", "case", "'E'", ":", "case", "'e'", ":", "{", "mEXPONENT", "(", "false", ")", ";", "break", ";", "}", "case", "'D'", ":", "case", "'F'", ":", "case", "'d'", ":", "case", "'f'", ":", "{", "mFLOAT_SUFFIX", "(", "false", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched707", "=", "false", ";", "}", "rewind", "(", "_m707", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched707", ")", "{", "{", "int", "_cnt709", "=", "0", ";", "_loop709", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'9'", ")", ")", ")", "{", "matchRange", "(", "'0'", ",", "'9'", ")", ";", "}", "else", "{", "if", "(", "_cnt709", ">=", "1", ")", "{", "break", "_loop709", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "_cnt709", "++", ";", "}", "while", "(", "true", ")", ";", "}", "}", "else", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'7'", ")", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", "&&", "(", "true", ")", ")", "{", "{", "int", "_cnt711", "=", "0", ";", "_loop711", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'7'", ")", ")", ")", "{", "matchRange", "(", "'0'", ",", "'7'", ")", ";", "}", "else", "{", "if", "(", "_cnt711", ">=", "1", ")", "{", "break", "_loop711", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "_cnt711", "++", ";", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "isDecimal", "=", "false", ";", "}", "}", "else", "{", "}", "}", "}", "break", ";", "}", "case", "'1'", ":", "case", "'2'", ":", "case", "'3'", ":", "case", "'4'", ":", "case", "'5'", ":", "case", "'6'", ":", "case", "'7'", ":", "case", "'8'", ":", "case", "'9'", ":", "{", "{", "matchRange", "(", "'1'", ",", "'9'", ")", ";", "}", "{", "_loop714", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'9'", ")", ")", ")", "{", "matchRange", "(", "'0'", ",", "'9'", ")", ";", "}", "else", "{", "break", "_loop714", ";", "}", "}", "while", "(", "true", ")", ";", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "isDecimal", "=", "true", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'L'", ":", "case", "'l'", ":", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'l'", ":", "{", "match", "(", "'l'", ")", ";", "break", ";", "}", "case", "'L'", ":", "{", "match", "(", "'L'", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "NUM_LONG", ";", "}", "break", ";", "}", "case", "'I'", ":", "case", "'i'", ":", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'i'", ":", "{", "match", "(", "'i'", ")", ";", "break", ";", "}", "case", "'I'", ":", "{", "match", "(", "'I'", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "NUM_INT", ";", "}", "break", ";", "}", "case", "'G'", ":", "case", "'g'", ":", "{", "mBIG_SUFFIX", "(", "false", ")", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "_ttype", "=", "NUM_BIG_INT", ";", "}", "break", ";", "}", "default", ":", "boolean", "synPredMatched720", "=", "false", ";", "if", "(", "(", "(", "(", "LA", "(", "1", ")", "==", "'.'", "||", "LA", "(", "1", ")", "==", "'D'", "||", "LA", "(", "1", ")", "==", "'E'", "||", "LA", "(", "1", ")", "==", "'F'", "||", "LA", "(", "1", ")", "==", "'d'", "||", "LA", "(", "1", ")", "==", "'e'", "||", "LA", "(", "1", ")", "==", "'f'", ")", ")", "&&", "(", "isDecimal", ")", ")", ")", "{", "int", "_m720", "=", "mark", "(", ")", ";", "synPredMatched720", "=", "true", ";", "inputState", ".", "guessing", "++", ";", "try", "{", "{", "if", "(", "(", "_tokenSet_11", ".", "member", "(", "LA", "(", "1", ")", ")", ")", ")", "{", "matchNot", "(", "'.'", ")", ";", "}", "else", "if", "(", "(", "LA", "(", "1", ")", "==", "'.'", ")", ")", "{", "match", "(", "'.'", ")", ";", "{", "matchRange", "(", "'0'", ",", "'9'", ")", ";", "}", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "catch", "(", "RecognitionException", "pe", ")", "{", "synPredMatched720", "=", "false", ";", "}", "rewind", "(", "_m720", ")", ";", "inputState", ".", "guessing", "--", ";", "}", "if", "(", "synPredMatched720", ")", "{", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'.'", ":", "{", "match", "(", "'.'", ")", ";", "{", "int", "_cnt723", "=", "0", ";", "_loop723", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'9'", ")", ")", ")", "{", "matchRange", "(", "'0'", ",", "'9'", ")", ";", "}", "else", "{", "if", "(", "_cnt723", ">=", "1", ")", "{", "break", "_loop723", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "_cnt723", "++", ";", "}", "while", "(", "true", ")", ";", "}", "{", "if", "(", "(", "LA", "(", "1", ")", "==", "'E'", "||", "LA", "(", "1", ")", "==", "'e'", ")", ")", "{", "mEXPONENT", "(", "false", ")", ";", "}", "else", "{", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'D'", ":", "case", "'F'", ":", "case", "'d'", ":", "case", "'f'", ":", "{", "mFLOAT_SUFFIX", "(", "true", ")", ";", "f2", "=", "_returnToken", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "t", "=", "f2", ";", "}", "break", ";", "}", "case", "'G'", ":", "case", "'g'", ":", "{", "mBIG_SUFFIX", "(", "true", ")", ";", "g2", "=", "_returnToken", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "t", "=", "g2", ";", "}", "break", ";", "}", "default", ":", "{", "}", "}", "}", "break", ";", "}", "case", "'E'", ":", "case", "'e'", ":", "{", "mEXPONENT", "(", "false", ")", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'D'", ":", "case", "'F'", ":", "case", "'d'", ":", "case", "'f'", ":", "{", "mFLOAT_SUFFIX", "(", "true", ")", ";", "f3", "=", "_returnToken", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "t", "=", "f3", ";", "}", "break", ";", "}", "case", "'G'", ":", "case", "'g'", ":", "{", "mBIG_SUFFIX", "(", "true", ")", ";", "g3", "=", "_returnToken", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "t", "=", "g3", ";", "}", "break", ";", "}", "default", ":", "{", "}", "}", "}", "break", ";", "}", "case", "'D'", ":", "case", "'F'", ":", "case", "'d'", ":", "case", "'f'", ":", "{", "mFLOAT_SUFFIX", "(", "true", ")", ";", "f4", "=", "_returnToken", ";", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "t", "=", "f4", ";", "}", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "if", "(", "inputState", ".", "guessing", "==", "0", ")", "{", "String", "txt", "=", "(", "t", "==", "null", "?", "\"\"", ":", "t", ".", "getText", "(", ")", ".", "toUpperCase", "(", ")", ")", ";", "if", "(", "txt", ".", "indexOf", "(", "'F'", ")", ">=", "0", ")", "{", "_ttype", "=", "NUM_FLOAT", ";", "}", "else", "if", "(", "txt", ".", "indexOf", "(", "'G'", ")", ">=", "0", ")", "{", "_ttype", "=", "NUM_BIG_DECIMAL", ";", "}", "else", "{", "_ttype", "=", "NUM_DOUBLE", ";", "}", "}", "}", "else", "{", "}", "}", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mEXPONENT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "EXPONENT", ";", "int", "_saveIndex", ";", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'e'", ":", "{", "match", "(", "'e'", ")", ";", "break", ";", "}", "case", "'E'", ":", "{", "match", "(", "'E'", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "{", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'+'", ":", "{", "match", "(", "'+'", ")", ";", "break", ";", "}", "case", "'-'", ":", "{", "match", "(", "'-'", ")", ";", "break", ";", "}", "case", "'0'", ":", "case", "'1'", ":", "case", "'2'", ":", "case", "'3'", ":", "case", "'4'", ":", "case", "'5'", ":", "case", "'6'", ":", "case", "'7'", ":", "case", "'8'", ":", "case", "'9'", ":", "{", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "}", "{", "int", "_cnt732", "=", "0", ";", "_loop732", ":", "do", "{", "if", "(", "(", "(", "LA", "(", "1", ")", ">=", "'0'", "&&", "LA", "(", "1", ")", "<=", "'9'", ")", ")", ")", "{", "matchRange", "(", "'0'", ",", "'9'", ")", ";", "}", "else", "{", "if", "(", "_cnt732", ">=", "1", ")", "{", "break", "_loop732", ";", "}", "else", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "_cnt732", "++", ";", "}", "while", "(", "true", ")", ";", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mFLOAT_SUFFIX", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "FLOAT_SUFFIX", ";", "int", "_saveIndex", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'f'", ":", "{", "match", "(", "'f'", ")", ";", "break", ";", "}", "case", "'F'", ":", "{", "match", "(", "'F'", ")", ";", "break", ";", "}", "case", "'d'", ":", "{", "match", "(", "'d'", ")", ";", "break", ";", "}", "case", "'D'", ":", "{", "match", "(", "'D'", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "protected", "final", "void", "mBIG_SUFFIX", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "BIG_SUFFIX", ";", "int", "_saveIndex", ";", "switch", "(", "LA", "(", "1", ")", ")", "{", "case", "'g'", ":", "{", "match", "(", "'g'", ")", ";", "break", ";", "}", "case", "'G'", ":", "{", "match", "(", "'G'", ")", ";", "break", ";", "}", "default", ":", "{", "throw", "new", "NoViableAltForCharException", "(", "(", "char", ")", "LA", "(", "1", ")", ",", "getFilename", "(", ")", ",", "getLine", "(", ")", ",", "getColumn", "(", ")", ")", ";", "}", "}", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "public", "final", "void", "mAT", "(", "boolean", "_createToken", ")", "throws", "RecognitionException", ",", "CharStreamException", ",", "TokenStreamException", "{", "int", "_ttype", ";", "Token", "_token", "=", "null", ";", "int", "_begin", "=", "text", ".", "length", "(", ")", ";", "_ttype", "=", "AT", ";", "int", "_saveIndex", ";", "match", "(", "'@'", ")", ";", "if", "(", "_createToken", "&&", "_token", "==", "null", "&&", "_ttype", "!=", "Token", ".", "SKIP", ")", "{", "_token", "=", "makeToken", "(", "_ttype", ")", ";", "_token", ".", "setText", "(", "new", "String", "(", "text", ".", "getBuffer", "(", ")", ",", "_begin", ",", "text", ".", "length", "(", ")", "-", "_begin", ")", ")", ";", "}", "_returnToken", "=", "_token", ";", "}", "private", "static", "final", "long", "[", "]", "mk_tokenSet_0", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2560", "]", ";", "data", "[", "0", "]", "=", "68719476736L", ";", "data", "[", "1", "]", "=", "576460745995190270L", ";", "data", "[", "3", "]", "=", "-", "36028797027352577L", ";", "for", "(", "int", "i", "=", "4", ";", "i", "<=", "1022", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "data", "[", "1023", "]", "=", "9223372036854775807L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_0", "=", "new", "BitSet", "(", "mk_tokenSet_0", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_1", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2048", "]", ";", "data", "[", "0", "]", "=", "-", "9217L", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "1022", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "data", "[", "1023", "]", "=", "9223372036854775807L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_1", "=", "new", "BitSet", "(", "mk_tokenSet_1", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_2", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2048", "]", ";", "data", "[", "0", "]", "=", "-", "4398046520321L", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "1022", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "data", "[", "1023", "]", "=", "9223372036854775807L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_2", "=", "new", "BitSet", "(", "mk_tokenSet_2", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_3", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2048", "]", ";", "data", "[", "0", "]", "=", "-", "549755813889L", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "1023", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_3", "=", "new", "BitSet", "(", "mk_tokenSet_3", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_4", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2048", "]", ";", "data", "[", "0", "]", "=", "-", "635655169025L", ";", "data", "[", "1", "]", "=", "-", "268435457L", ";", "for", "(", "int", "i", "=", "2", ";", "i", "<=", "1022", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "data", "[", "1023", "]", "=", "9223372036854775807L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_4", "=", "new", "BitSet", "(", "mk_tokenSet_4", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_5", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2048", "]", ";", "data", "[", "0", "]", "=", "-", "17179869185L", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "1023", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_5", "=", "new", "BitSet", "(", "mk_tokenSet_5", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_6", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2048", "]", ";", "data", "[", "0", "]", "=", "-", "145135534875649L", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "1022", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "data", "[", "1023", "]", "=", "9223372036854775807L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_6", "=", "new", "BitSet", "(", "mk_tokenSet_6", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_7", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2048", "]", ";", "data", "[", "0", "]", "=", "-", "145204254352385L", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "1022", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "data", "[", "1023", "]", "=", "9223372036854775807L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_7", "=", "new", "BitSet", "(", "mk_tokenSet_7", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_8", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2048", "]", ";", "data", "[", "0", "]", "=", "-", "145204254352385L", ";", "data", "[", "1", "]", "=", "-", "268435457L", ";", "for", "(", "int", "i", "=", "2", ";", "i", "<=", "1022", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "data", "[", "1023", "]", "=", "9223372036854775807L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_8", "=", "new", "BitSet", "(", "mk_tokenSet_8", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_9", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2560", "]", ";", "data", "[", "1", "]", "=", "576460745995190270L", ";", "data", "[", "3", "]", "=", "-", "36028797027352577L", ";", "for", "(", "int", "i", "=", "4", ";", "i", "<=", "1022", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "data", "[", "1023", "]", "=", "9223372036854775807L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_9", "=", "new", "BitSet", "(", "mk_tokenSet_9", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_10", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "1025", "]", ";", "data", "[", "0", "]", "=", "287948901175001088L", ";", "data", "[", "1", "]", "=", "541165879422L", ";", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_10", "=", "new", "BitSet", "(", "mk_tokenSet_10", "(", ")", ")", ";", "private", "static", "final", "long", "[", "]", "mk_tokenSet_11", "(", ")", "{", "long", "[", "]", "data", "=", "new", "long", "[", "2048", "]", ";", "data", "[", "0", "]", "=", "-", "70368744177665L", ";", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "1023", ";", "i", "++", ")", "{", "data", "[", "i", "]", "=", "-", "1L", ";", "}", "return", "data", ";", "}", "public", "static", "final", "BitSet", "_tokenSet_11", "=", "new", "BitSet", "(", "mk_tokenSet_11", "(", ")", ")", ";", "}", "</s>" ]
6,707
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "parser", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "*", ";", "import", "java", ".", "util", ".", "*", ";", "import", "java", ".", "io", ".", "InputStream", ";", "import", "java", ".", "io", ".", "Reader", ";", "import", "antlr", ".", "InputBuffer", ";", "import", "antlr", ".", "LexerSharedInputState", ";", "import", "antlr", ".", "CommonToken", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "GroovyBugError", ";", "import", "antlr", ".", "TokenStreamRecognitionException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Comment", ";", "public", "interface", "GroovyTokenTypes", "{", "int", "EOF", "=", "1", ";", "int", "NULL_TREE_LOOKAHEAD", "=", "3", ";", "int", "BLOCK", "=", "4", ";", "int", "MODIFIERS", "=", "5", ";", "int", "OBJBLOCK", "=", "6", ";", "int", "SLIST", "=", "7", ";", "int", "METHOD_DEF", "=", "8", ";", "int", "VARIABLE_DEF", "=", "9", ";", "int", "INSTANCE_INIT", "=", "10", ";", "int", "STATIC_INIT", "=", "11", ";", "int", "TYPE", "=", "12", ";", "int", "CLASS_DEF", "=", "13", ";", "int", "INTERFACE_DEF", "=", "14", ";", "int", "PACKAGE_DEF", "=", "15", ";", "int", "ARRAY_DECLARATOR", "=", "16", ";", "int", "EXTENDS_CLAUSE", "=", "17", ";", "int", "IMPLEMENTS_CLAUSE", "=", "18", ";", "int", "PARAMETERS", "=", "19", ";", "int", "PARAMETER_DEF", "=", "20", ";", "int", "LABELED_STAT", "=", "21", ";", "int", "TYPECAST", "=", "22", ";", "int", "INDEX_OP", "=", "23", ";", "int", "POST_INC", "=", "24", ";", "int", "POST_DEC", "=", "25", ";", "int", "METHOD_CALL", "=", "26", ";", "int", "EXPR", "=", "27", ";", "int", "IMPORT", "=", "28", ";", "int", "UNARY_MINUS", "=", "29", ";", "int", "UNARY_PLUS", "=", "30", ";", "int", "CASE_GROUP", "=", "31", ";", "int", "ELIST", "=", "32", ";", "int", "FOR_INIT", "=", "33", ";", "int", "FOR_CONDITION", "=", "34", ";", "int", "FOR_ITERATOR", "=", "35", ";", "int", "EMPTY_STAT", "=", "36", ";", "int", "FINAL", "=", "37", ";", "int", "ABSTRACT", "=", "38", ";", "int", "UNUSED_GOTO", "=", "39", ";", "int", "UNUSED_CONST", "=", "40", ";", "int", "UNUSED_DO", "=", "41", ";", "int", "STRICTFP", "=", "42", ";", "int", "SUPER_CTOR_CALL", "=", "43", ";", "int", "CTOR_CALL", "=", "44", ";", "int", "CTOR_IDENT", "=", "45", ";", "int", "VARIABLE_PARAMETER_DEF", "=", "46", ";", "int", "STRING_CONSTRUCTOR", "=", "47", ";", "int", "STRING_CTOR_MIDDLE", "=", "48", ";", "int", "CLOSABLE_BLOCK", "=", "49", ";", "int", "IMPLICIT_PARAMETERS", "=", "50", ";", "int", "SELECT_SLOT", "=", "51", ";", "int", "DYNAMIC_MEMBER", "=", "52", ";", "int", "LABELED_ARG", "=", "53", ";", "int", "SPREAD_ARG", "=", "54", ";", "int", "SPREAD_MAP_ARG", "=", "55", ";", "int", "LIST_CONSTRUCTOR", "=", "56", ";", "int", "MAP_CONSTRUCTOR", "=", "57", ";", "int", "FOR_IN_ITERABLE", "=", "58", ";", "int", "STATIC_IMPORT", "=", "59", ";", "int", "ENUM_DEF", "=", "60", ";", "int", "ENUM_CONSTANT_DEF", "=", "61", ";", "int", "FOR_EACH_CLAUSE", "=", "62", ";", "int", "ANNOTATION_DEF", "=", "63", ";", "int", "ANNOTATIONS", "=", "64", ";", "int", "ANNOTATION", "=", "65", ";", "int", "ANNOTATION_MEMBER_VALUE_PAIR", "=", "66", ";", "int", "ANNOTATION_FIELD_DEF", "=", "67", ";", "int", "ANNOTATION_ARRAY_INIT", "=", "68", ";", "int", "TYPE_ARGUMENTS", "=", "69", ";", "int", "TYPE_ARGUMENT", "=", "70", ";", "int", "TYPE_PARAMETERS", "=", "71", ";", "int", "TYPE_PARAMETER", "=", "72", ";", "int", "WILDCARD_TYPE", "=", "73", ";", "int", "TYPE_UPPER_BOUNDS", "=", "74", ";", "int", "TYPE_LOWER_BOUNDS", "=", "75", ";", "int", "CLOSURE_LIST", "=", "76", ";", "int", "SH_COMMENT", "=", "77", ";", "int", "LITERAL_package", "=", "78", ";", "int", "LITERAL_import", "=", "79", ";", "int", "LITERAL_static", "=", "80", ";", "int", "LITERAL_def", "=", "81", ";", "int", "LBRACK", "=", "82", ";", "int", "RBRACK", "=", "83", ";", "int", "IDENT", "=", "84", ";", "int", "STRING_LITERAL", "=", "85", ";", "int", "LT", "=", "86", ";", "int", "DOT", "=", "87", ";", "int", "LPAREN", "=", "88", ";", "int", "LITERAL_class", "=", "89", ";", "int", "LITERAL_interface", "=", "90", ";", "int", "LITERAL_enum", "=", "91", ";", "int", "AT", "=", "92", ";", "int", "QUESTION", "=", "93", ";", "int", "LITERAL_extends", "=", "94", ";", "int", "LITERAL_super", "=", "95", ";", "int", "COMMA", "=", "96", ";", "int", "GT", "=", "97", ";", "int", "SR", "=", "98", ";", "int", "BSR", "=", "99", ";", "int", "LITERAL_void", "=", "100", ";", "int", "LITERAL_boolean", "=", "101", ";", "int", "LITERAL_byte", "=", "102", ";", "int", "LITERAL_char", "=", "103", ";", "int", "LITERAL_short", "=", "104", ";", "int", "LITERAL_int", "=", "105", ";", "int", "LITERAL_float", "=", "106", ";", "int", "LITERAL_long", "=", "107", ";", "int", "LITERAL_double", "=", "108", ";", "int", "STAR", "=", "109", ";", "int", "LITERAL_as", "=", "110", ";", "int", "LITERAL_private", "=", "111", ";", "int", "LITERAL_public", "=", "112", ";", "int", "LITERAL_protected", "=", "113", ";", "int", "LITERAL_transient", "=", "114", ";", "int", "LITERAL_native", "=", "115", ";", "int", "LITERAL_threadsafe", "=", "116", ";", "int", "LITERAL_synchronized", "=", "117", ";", "int", "LITERAL_volatile", "=", "118", ";", "int", "RPAREN", "=", "119", ";", "int", "ASSIGN", "=", "120", ";", "int", "BAND", "=", "121", ";", "int", "LCURLY", "=", "122", ";", "int", "RCURLY", "=", "123", ";", "int", "SEMI", "=", "124", ";", "int", "LITERAL_default", "=", "125", ";", "int", "LITERAL_throws", "=", "126", ";", "int", "LITERAL_implements", "=", "127", ";", "int", "LITERAL_this", "=", "128", ";", "int", "TRIPLE_DOT", "=", "129", ";", "int", "CLOSABLE_BLOCK_OP", "=", "130", ";", "int", "COLON", "=", "131", ";", "int", "LITERAL_if", "=", "132", ";", "int", "LITERAL_else", "=", "133", ";", "int", "LITERAL_while", "=", "134", ";", "int", "LITERAL_switch", "=", "135", ";", "int", "LITERAL_for", "=", "136", ";", "int", "LITERAL_in", "=", "137", ";", "int", "LITERAL_return", "=", "138", ";", "int", "LITERAL_break", "=", "139", ";", "int", "LITERAL_continue", "=", "140", ";", "int", "LITERAL_throw", "=", "141", ";", "int", "LITERAL_assert", "=", "142", ";", "int", "PLUS", "=", "143", ";", "int", "MINUS", "=", "144", ";", "int", "LITERAL_case", "=", "145", ";", "int", "LITERAL_try", "=", "146", ";", "int", "LITERAL_finally", "=", "147", ";", "int", "LITERAL_catch", "=", "148", ";", "int", "SPREAD_DOT", "=", "149", ";", "int", "OPTIONAL_DOT", "=", "150", ";", "int", "MEMBER_POINTER", "=", "151", ";", "int", "LITERAL_false", "=", "152", ";", "int", "LITERAL_instanceof", "=", "153", ";", "int", "LITERAL_new", "=", "154", ";", "int", "LITERAL_null", "=", "155", ";", "int", "LITERAL_true", "=", "156", ";", "int", "PLUS_ASSIGN", "=", "157", ";", "int", "MINUS_ASSIGN", "=", "158", ";", "int", "STAR_ASSIGN", "=", "159", ";", "int", "DIV_ASSIGN", "=", "160", ";", "int", "MOD_ASSIGN", "=", "161", ";", "int", "SR_ASSIGN", "=", "162", ";", "int", "BSR_ASSIGN", "=", "163", ";", "int", "SL_ASSIGN", "=", "164", ";", "int", "BAND_ASSIGN", "=", "165", ";", "int", "BXOR_ASSIGN", "=", "166", ";", "int", "BOR_ASSIGN", "=", "167", ";", "int", "STAR_STAR_ASSIGN", "=", "168", ";", "int", "ELVIS_OPERATOR", "=", "169", ";", "int", "LOR", "=", "170", ";", "int", "LAND", "=", "171", ";", "int", "BOR", "=", "172", ";", "int", "BXOR", "=", "173", ";", "int", "REGEX_FIND", "=", "174", ";", "int", "REGEX_MATCH", "=", "175", ";", "int", "NOT_EQUAL", "=", "176", ";", "int", "EQUAL", "=", "177", ";", "int", "IDENTICAL", "=", "178", ";", "int", "NOT_IDENTICAL", "=", "179", ";", "int", "COMPARE_TO", "=", "180", ";", "int", "LE", "=", "181", ";", "int", "GE", "=", "182", ";", "int", "SL", "=", "183", ";", "int", "RANGE_INCLUSIVE", "=", "184", ";", "int", "RANGE_EXCLUSIVE", "=", "185", ";", "int", "INC", "=", "186", ";", "int", "DIV", "=", "187", ";", "int", "MOD", "=", "188", ";", "int", "DEC", "=", "189", ";", "int", "STAR_STAR", "=", "190", ";", "int", "BNOT", "=", "191", ";", "int", "LNOT", "=", "192", ";", "int", "STRING_CTOR_START", "=", "193", ";", "int", "STRING_CTOR_END", "=", "194", ";", "int", "NUM_INT", "=", "195", ";", "int", "NUM_FLOAT", "=", "196", ";", "int", "NUM_LONG", "=", "197", ";", "int", "NUM_DOUBLE", "=", "198", ";", "int", "NUM_BIG_INT", "=", "199", ";", "int", "NUM_BIG_DECIMAL", "=", "200", ";", "int", "NLS", "=", "201", ";", "int", "DOLLAR", "=", "202", ";", "int", "WS", "=", "203", ";", "int", "ONE_NL", "=", "204", ";", "int", "ONE_NL_KEEP", "=", "220", ";", "int", "SL_COMMENT", "=", "205", ";", "int", "ML_COMMENT", "=", "206", ";", "int", "STRING_CH", "=", "207", ";", "int", "REGEXP_LITERAL", "=", "208", ";", "int", "REGEXP_CTOR_END", "=", "209", ";", "int", "REGEXP_SYMBOL", "=", "210", ";", "int", "ESC", "=", "211", ";", "int", "STRING_NL", "=", "212", ";", "int", "HEX_DIGIT", "=", "213", ";", "int", "VOCAB", "=", "214", ";", "int", "LETTER", "=", "215", ";", "int", "DIGIT", "=", "216", ";", "int", "EXPONENT", "=", "217", ";", "int", "FLOAT_SUFFIX", "=", "218", ";", "int", "BIG_SUFFIX", "=", "219", ";", "}", "</s>" ]
6,708
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "List", ";", "public", "class", "SourceBuffer", "{", "private", "final", "List", "lines", ";", "private", "StringBuffer", "current", ";", "private", "final", "List", "<", "Integer", ">", "lineEndings", ";", "private", "UnicodeEscapingReader", "unescaper", ";", "public", "SourceBuffer", "(", ")", "{", "lines", "=", "new", "ArrayList", "(", ")", ";", "lineEndings", "=", "new", "ArrayList", "<", "Integer", ">", "(", ")", ";", "lineEndings", ".", "add", "(", "0", ")", ";", "unescaper", "=", "new", "NoEscaper", "(", ")", ";", "current", "=", "new", "StringBuffer", "(", ")", ";", "lines", ".", "add", "(", "current", ")", ";", "}", "public", "String", "getSnippet", "(", "LineColumn", "start", ",", "LineColumn", "end", ")", "{", "if", "(", "start", "==", "null", "||", "end", "==", "null", ")", "{", "return", "null", ";", "}", "if", "(", "start", ".", "equals", "(", "end", ")", ")", "{", "return", "null", ";", "}", "if", "(", "lines", ".", "size", "(", ")", "==", "1", "&&", "current", ".", "length", "(", ")", "==", "0", ")", "{", "return", "null", ";", "}", "int", "startLine", "=", "start", ".", "getLine", "(", ")", ";", "int", "startColumn", "=", "start", ".", "getColumn", "(", ")", ";", "int", "endLine", "=", "end", ".", "getLine", "(", ")", ";", "int", "endColumn", "=", "end", ".", "getColumn", "(", ")", ";", "if", "(", "startLine", "<", "1", ")", "{", "startLine", "=", "1", ";", "}", "if", "(", "endLine", "<", "1", ")", "{", "endLine", "=", "1", ";", "}", "if", "(", "startColumn", "<", "1", ")", "{", "startColumn", "=", "1", ";", "}", "if", "(", "endColumn", "<", "1", ")", "{", "endColumn", "=", "1", ";", "}", "if", "(", "startLine", ">", "lines", ".", "size", "(", ")", ")", "{", "startLine", "=", "lines", ".", "size", "(", ")", ";", "}", "if", "(", "endLine", ">", "lines", ".", "size", "(", ")", ")", "{", "endLine", "=", "lines", ".", "size", "(", ")", ";", "}", "StringBuffer", "snippet", "=", "new", "StringBuffer", "(", ")", ";", "for", "(", "int", "i", "=", "startLine", "-", "1", ";", "i", "<", "endLine", ";", "i", "++", ")", "{", "String", "line", "=", "(", "(", "StringBuffer", ")", "lines", ".", "get", "(", "i", ")", ")", ".", "toString", "(", ")", ";", "if", "(", "startLine", "==", "endLine", ")", "{", "if", "(", "startColumn", ">", "line", ".", "length", "(", ")", ")", "{", "startColumn", "=", "line", ".", "length", "(", ")", ";", "}", "if", "(", "startColumn", "<", "1", ")", "{", "startColumn", "=", "1", ";", "}", "if", "(", "endColumn", ">", "line", ".", "length", "(", ")", ")", "{", "endColumn", "=", "line", ".", "length", "(", ")", "+", "1", ";", "}", "if", "(", "endColumn", "<", "1", ")", "{", "endColumn", "=", "1", ";", "}", "line", "=", "line", ".", "substring", "(", "startColumn", "-", "1", ",", "endColumn", "-", "1", ")", ";", "}", "else", "{", "if", "(", "i", "==", "startLine", "-", "1", ")", "{", "if", "(", "startColumn", "-", "1", "<", "line", ".", "length", "(", ")", ")", "{", "line", "=", "line", ".", "substring", "(", "startColumn", "-", "1", ")", ";", "}", "}", "if", "(", "i", "==", "endLine", "-", "1", ")", "{", "if", "(", "endColumn", "-", "1", "<", "line", ".", "length", "(", ")", ")", "{", "line", "=", "line", ".", "substring", "(", "0", ",", "endColumn", "-", "1", ")", ";", "}", "}", "}", "snippet", ".", "append", "(", "line", ")", ";", "}", "return", "snippet", ".", "toString", "(", ")", ";", "}", "public", "void", "setUnescaper", "(", "UnicodeEscapingReader", "unicodeEscapingReader", ")", "{", "this", ".", "unescaper", "=", "unicodeEscapingReader", ";", "}", "private", "boolean", "prevWasCarriageReturn", "=", "false", ";", "private", "int", "col", "=", "0", ";", "public", "void", "write", "(", "int", "c", ")", "{", "if", "(", "c", "!=", "-", "1", ")", "{", "col", "++", ";", "current", ".", "append", "(", "(", "char", ")", "c", ")", ";", "}", "if", "(", "c", "==", "'\\n'", ")", "{", "if", "(", "!", "prevWasCarriageReturn", ")", "{", "current", "=", "new", "StringBuffer", "(", ")", ";", "lines", ".", "add", "(", "current", ")", ";", "lineEndings", ".", "add", "(", "col", "+", "unescaper", ".", "getUnescapedUnicodeOffsetCount", "(", ")", ")", ";", "}", "else", "{", "current", "=", "new", "StringBuffer", "(", ")", ";", "(", "(", "StringBuffer", ")", "lines", ".", "get", "(", "lines", ".", "size", "(", ")", "-", "1", ")", ")", ".", "append", "(", "'\\n'", ")", ";", "lineEndings", ".", "remove", "(", "lineEndings", ".", "size", "(", ")", "-", "1", ")", ";", "lineEndings", ".", "add", "(", "col", "+", "unescaper", ".", "getUnescapedUnicodeOffsetCount", "(", ")", ")", ";", "}", "}", "if", "(", "c", "==", "'\\r'", ")", "{", "current", "=", "new", "StringBuffer", "(", ")", ";", "lines", ".", "add", "(", "current", ")", ";", "lineEndings", ".", "add", "(", "col", "+", "unescaper", ".", "getUnescapedUnicodeOffsetCount", "(", ")", ")", ";", "prevWasCarriageReturn", "=", "true", ";", "}", "else", "{", "prevWasCarriageReturn", "=", "false", ";", "}", "}", "public", "LocationSupport", "getLocationSupport", "(", ")", "{", "lineEndings", ".", "add", "(", "col", "+", "unescaper", ".", "getUnescapedUnicodeOffsetCount", "(", ")", ")", ";", "int", "[", "]", "lineEndingsArray", "=", "new", "int", "[", "lineEndings", ".", "size", "(", ")", "]", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "lineEndings", ".", "size", "(", ")", ";", "i", "<", "max", ";", "i", "++", ")", "{", "lineEndingsArray", "[", "i", "]", "=", "lineEndings", ".", "get", "(", "i", ")", ".", "intValue", "(", ")", ";", "}", "return", "new", "LocationSupport", "(", "lineEndingsArray", ")", ";", "}", "}", "</s>" ]
6,709
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ParserPlugin", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ParserPluginFactory", ";", "public", "class", "CSTParserPluginFactory", "extends", "ParserPluginFactory", "{", "private", "ICSTReporter", "cstReporter", ";", "public", "CSTParserPluginFactory", "(", "ICSTReporter", "cstReporter", ")", "{", "this", ".", "cstReporter", "=", "cstReporter", ";", "}", "public", "ParserPlugin", "createParserPlugin", "(", ")", "{", "return", "new", "CSTParserPlugin", "(", "cstReporter", ")", ";", "}", "}", "</s>" ]
6,710
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "antlr", ".", "LexerSharedInputState", ";", "public", "class", "UnicodeLexerSharedInputState", "extends", "LexerSharedInputState", "{", "private", "final", "UnicodeEscapingReader", "escapingReader", ";", "private", "int", "prevUnescape", ";", "public", "UnicodeLexerSharedInputState", "(", "UnicodeEscapingReader", "in", ")", "{", "super", "(", "in", ")", ";", "escapingReader", "=", "in", ";", "}", "@", "Override", "public", "int", "getColumn", "(", ")", "{", "prevUnescape", "=", "escapingReader", ".", "getUnescapedUnicodeColumnCount", "(", ")", ";", "return", "super", ".", "getColumn", "(", ")", "+", "prevUnescape", ";", "}", "@", "Override", "public", "int", "getTokenStartColumn", "(", ")", "{", "if", "(", "line", "==", "tokenStartLine", ")", "{", "return", "super", ".", "getTokenStartColumn", "(", ")", "+", "escapingReader", ".", "getUnescapedUnicodeColumnCount", "(", ")", ";", "}", "else", "{", "return", "super", ".", "getTokenStartColumn", "(", ")", "+", "prevUnescape", ";", "}", "}", "}", "</s>" ]
6,711
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "antlr", ".", "RecognitionException", ";", "import", "antlr", ".", "TokenStreamException", ";", "import", "antlr", ".", "TokenStreamRecognitionException", ";", "import", "antlr", ".", "collections", ".", "AST", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "GroovyBugError", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "parser", ".", "GroovyLexer", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "parser", ".", "GroovyRecognizer", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "parser", ".", "GroovyTokenTypes", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "treewalker", ".", "*", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "*", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "*", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "*", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationFailedException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ParserPlugin", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "*", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "import", "java", ".", "io", ".", "*", ";", "import", "java", ".", "security", ".", "AccessController", ";", "import", "java", ".", "security", ".", "PrivilegedAction", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "LinkedList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Set", ";", "public", "class", "AntlrParserPlugin", "extends", "ASTHelper", "implements", "ParserPlugin", ",", "GroovyTokenTypes", "{", "private", "static", "class", "AnonymousInnerClassCarrier", "extends", "Expression", "{", "ClassNode", "innerClass", ";", "public", "Expression", "transformExpression", "(", "ExpressionTransformer", "transformer", ")", "{", "return", "null", ";", "}", "}", "protected", "AST", "ast", ";", "private", "ClassNode", "classNode", ";", "protected", "String", "[", "]", "tokenNames", ";", "private", "int", "innerClassCounter", "=", "1", ";", "private", "boolean", "enumConstantBeingDef", "=", "false", ";", "private", "boolean", "forStatementBeingDef", "=", "false", ";", "protected", "LocationSupport", "locations", "=", "LocationSupport", ".", "NO_LOCATIONS", ";", "public", "Reduction", "parseCST", "(", "final", "SourceUnit", "sourceUnit", ",", "Reader", "reader", ")", "throws", "CompilationFailedException", "{", "final", "SourceBuffer", "sourceBuffer", "=", "new", "SourceBuffer", "(", ")", ";", "transformCSTIntoAST", "(", "sourceUnit", ",", "reader", ",", "sourceBuffer", ")", ";", "processAST", "(", ")", ";", "return", "outputAST", "(", "sourceUnit", ",", "sourceBuffer", ")", ";", "}", "protected", "void", "transformCSTIntoAST", "(", "SourceUnit", "sourceUnit", ",", "Reader", "reader", ",", "SourceBuffer", "sourceBuffer", ")", "throws", "CompilationFailedException", "{", "ast", "=", "null", ";", "setController", "(", "sourceUnit", ")", ";", "UnicodeEscapingReader", "unicodeReader", "=", "new", "UnicodeEscapingReader", "(", "reader", ",", "sourceBuffer", ")", ";", "UnicodeLexerSharedInputState", "inputState", "=", "new", "UnicodeLexerSharedInputState", "(", "unicodeReader", ")", ";", "GroovyLexer", "lexer", "=", "new", "GroovyLexer", "(", "inputState", ")", ";", "unicodeReader", ".", "setLexer", "(", "lexer", ")", ";", "GroovyRecognizer", "parser", "=", "GroovyRecognizer", ".", "make", "(", "lexer", ")", ";", "parser", ".", "setSourceBuffer", "(", "sourceBuffer", ")", ";", "tokenNames", "=", "parser", ".", "getTokenNames", "(", ")", ";", "parser", ".", "setFilename", "(", "sourceUnit", ".", "getName", "(", ")", ")", ";", "try", "{", "parser", ".", "compilationUnit", "(", ")", ";", "}", "catch", "(", "TokenStreamRecognitionException", "tsre", ")", "{", "RecognitionException", "e", "=", "tsre", ".", "recog", ";", "SyntaxException", "se", "=", "new", "SyntaxException", "(", "e", ".", "getMessage", "(", ")", ",", "e", ",", "e", ".", "getLine", "(", ")", ",", "e", ".", "getColumn", "(", ")", ")", ";", "se", ".", "setFatal", "(", "true", ")", ";", "sourceUnit", ".", "addError", "(", "se", ")", ";", "}", "catch", "(", "RecognitionException", "e", ")", "{", "SyntaxException", "se", "=", "new", "SyntaxException", "(", "e", ".", "getMessage", "(", ")", ",", "e", ",", "e", ".", "getLine", "(", ")", ",", "e", ".", "getColumn", "(", ")", ")", ";", "se", ".", "setFatal", "(", "true", ")", ";", "sourceUnit", ".", "addError", "(", "se", ")", ";", "}", "catch", "(", "TokenStreamException", "e", ")", "{", "sourceUnit", ".", "addException", "(", "e", ")", ";", "}", "configureLocationSupport", "(", "sourceBuffer", ")", ";", "ast", "=", "parser", ".", "getAST", "(", ")", ";", "}", "protected", "void", "configureLocationSupport", "(", "SourceBuffer", "sourceBuffer", ")", "{", "locations", "=", "sourceBuffer", ".", "getLocationSupport", "(", ")", ";", "}", "protected", "void", "processAST", "(", ")", "{", "AntlrASTProcessor", "snippets", "=", "new", "AntlrASTProcessSnippets", "(", ")", ";", "ast", "=", "snippets", ".", "process", "(", "ast", ")", ";", "}", "public", "Reduction", "outputAST", "(", "final", "SourceUnit", "sourceUnit", ",", "final", "SourceBuffer", "sourceBuffer", ")", "{", "AccessController", ".", "doPrivileged", "(", "new", "PrivilegedAction", "(", ")", "{", "public", "Object", "run", "(", ")", "{", "outputASTInVariousFormsIfNeeded", "(", "sourceUnit", ",", "sourceBuffer", ")", ";", "return", "null", ";", "}", "}", ")", ";", "return", "null", ";", "}", "protected", "void", "outputASTInVariousFormsIfNeeded", "(", "SourceUnit", "sourceUnit", ",", "SourceBuffer", "sourceBuffer", ")", "{", "if", "(", "\"groovy\"", ".", "equals", "(", "System", ".", "getProperty", "(", "\"antlr.ast\"", ")", ")", ")", "{", "try", "{", "PrintStream", "out", "=", "new", "PrintStream", "(", "new", "FileOutputStream", "(", "sourceUnit", ".", "getName", "(", ")", "+", "\"\"", ")", ")", ";", "Visitor", "visitor", "=", "new", "SourcePrinter", "(", "out", ",", "tokenNames", ")", ";", "AntlrASTProcessor", "treewalker", "=", "new", "SourceCodeTraversal", "(", "visitor", ")", ";", "treewalker", ".", "process", "(", "ast", ")", ";", "}", "catch", "(", "FileNotFoundException", "e", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "sourceUnit", ".", "getName", "(", ")", "+", "\"\"", ")", ";", "}", "}", "if", "(", "\"mindmap\"", ".", "equals", "(", "System", ".", "getProperty", "(", "\"antlr.ast\"", ")", ")", ")", "{", "try", "{", "PrintStream", "out", "=", "new", "PrintStream", "(", "new", "FileOutputStream", "(", "sourceUnit", ".", "getName", "(", ")", "+", "\".mm\"", ")", ")", ";", "Visitor", "visitor", "=", "new", "MindMapPrinter", "(", "out", ",", "tokenNames", ")", ";", "AntlrASTProcessor", "treewalker", "=", "new", "PreOrderTraversal", "(", "visitor", ")", ";", "treewalker", ".", "process", "(", "ast", ")", ";", "}", "catch", "(", "FileNotFoundException", "e", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "sourceUnit", ".", "getName", "(", ")", "+", "\".mm\"", ")", ";", "}", "}", "if", "(", "\"\"", ".", "equals", "(", "System", ".", "getProperty", "(", "\"antlr.ast\"", ")", ")", ")", "{", "try", "{", "PrintStream", "out", "=", "new", "PrintStream", "(", "new", "FileOutputStream", "(", "sourceUnit", ".", "getName", "(", ")", "+", "\".mm\"", ")", ")", ";", "Visitor", "visitor", "=", "new", "MindMapPrinter", "(", "out", ",", "tokenNames", ",", "sourceBuffer", ")", ";", "AntlrASTProcessor", "treewalker", "=", "new", "PreOrderTraversal", "(", "visitor", ")", ";", "treewalker", ".", "process", "(", "ast", ")", ";", "}", "catch", "(", "FileNotFoundException", "e", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "sourceUnit", ".", "getName", "(", ")", "+", "\".mm\"", ")", ";", "}", "}", "if", "(", "\"html\"", ".", "equals", "(", "System", ".", "getProperty", "(", "\"antlr.ast\"", ")", ")", ")", "{", "try", "{", "PrintStream", "out", "=", "new", "PrintStream", "(", "new", "FileOutputStream", "(", "sourceUnit", ".", "getName", "(", ")", "+", "\".html\"", ")", ")", ";", "List", "<", "VisitorAdapter", ">", "v", "=", "new", "ArrayList", "<", "VisitorAdapter", ">", "(", ")", ";", "v", ".", "add", "(", "new", "NodeAsHTMLPrinter", "(", "out", ",", "tokenNames", ")", ")", ";", "v", ".", "add", "(", "new", "SourcePrinter", "(", "out", ",", "tokenNames", ")", ")", ";", "Visitor", "visitors", "=", "new", "CompositeVisitor", "(", "v", ")", ";", "AntlrASTProcessor", "treewalker", "=", "new", "SourceCodeTraversal", "(", "visitors", ")", ";", "treewalker", ".", "process", "(", "ast", ")", ";", "}", "catch", "(", "FileNotFoundException", "e", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "sourceUnit", ".", "getName", "(", ")", "+", "\".html\"", ")", ";", "}", "}", "}", "public", "ModuleNode", "buildAST", "(", "SourceUnit", "sourceUnit", ",", "ClassLoader", "classLoader", ",", "Reduction", "cst", ")", "throws", "ParserException", "{", "setClassLoader", "(", "classLoader", ")", ";", "makeModule", "(", ")", ";", "try", "{", "innerClassCounter", "=", "1", ";", "convertGroovy", "(", "ast", ")", ";", "boolean", "hasNoMethods", "=", "output", ".", "getMethods", "(", ")", ".", "isEmpty", "(", ")", ";", "if", "(", "hasNoMethods", "&&", "sourceUnit", ".", "getErrorCollector", "(", ")", ".", "hasErrors", "(", ")", "&&", "looksBroken", "(", "output", ")", ")", "{", "output", ".", "setEncounteredUnrecoverableError", "(", "true", ")", ";", "}", "if", "(", "output", ".", "getStatementBlock", "(", ")", ".", "isEmpty", "(", ")", "&&", "hasNoMethods", "&&", "output", ".", "getClasses", "(", ")", ".", "isEmpty", "(", ")", ")", "{", "if", "(", "ast", "==", "null", "&&", "sourceUnit", ".", "getErrorCollector", "(", ")", ".", "hasErrors", "(", ")", ")", "{", "output", ".", "setEncounteredUnrecoverableError", "(", "true", ")", ";", "}", "output", ".", "addStatement", "(", "ReturnStatement", ".", "RETURN_NULL_OR_VOID", ")", ";", "}", "fixModuleNodeLocations", "(", ")", ";", "}", "catch", "(", "ASTRuntimeException", "e", ")", "{", "throw", "new", "ASTParserException", "(", "e", ".", "getMessage", "(", ")", "+", "\".", "File:", "\"", "+", "sourceUnit", ".", "getName", "(", ")", ",", "e", ")", ";", "}", "return", "output", ";", "}", "private", "boolean", "looksBroken", "(", "ModuleNode", "moduleNode", ")", "{", "List", "<", "ClassNode", ">", "classes", "=", "moduleNode", ".", "getClasses", "(", ")", ";", "if", "(", "classes", ".", "size", "(", ")", "!=", "1", "||", "!", "classes", ".", "get", "(", "0", ")", ".", "isScript", "(", ")", ")", "{", "return", "false", ";", "}", "BlockStatement", "statementBlock", "=", "moduleNode", ".", "getStatementBlock", "(", ")", ";", "if", "(", "statementBlock", ".", "isEmpty", "(", ")", ")", "{", "return", "true", ";", "}", "List", "<", "Statement", ">", "statements", "=", "statementBlock", ".", "getStatements", "(", ")", ";", "if", "(", "statements", "!=", "null", "&&", "statements", ".", "size", "(", ")", "==", "1", ")", "{", "Statement", "statement", "=", "statements", ".", "get", "(", "0", ")", ";", "if", "(", "statement", "instanceof", "ExpressionStatement", ")", "{", "Expression", "expression", "=", "(", "(", "ExpressionStatement", ")", "statement", ")", ".", "getExpression", "(", ")", ";", "if", "(", "expression", "instanceof", "ConstantExpression", ")", "{", "if", "(", "expression", ".", "toString", "(", ")", ".", "equals", "(", "\"\"", ")", ")", "{", "return", "true", ";", "}", "}", "}", "}", "return", "false", ";", "}", "protected", "void", "convertGroovy", "(", "AST", "node", ")", "{", "while", "(", "node", "!=", "null", ")", "{", "int", "type", "=", "node", ".", "getType", "(", ")", ";", "switch", "(", "type", ")", "{", "case", "PACKAGE_DEF", ":", "packageDef", "(", "node", ")", ";", "break", ";", "case", "STATIC_IMPORT", ":", "case", "IMPORT", ":", "importDef", "(", "node", ")", ";", "break", ";", "case", "CLASS_DEF", ":", "classDef", "(", "node", ")", ";", "break", ";", "case", "INTERFACE_DEF", ":", "interfaceDef", "(", "node", ")", ";", "break", ";", "case", "METHOD_DEF", ":", "methodDef", "(", "node", ")", ";", "break", ";", "case", "ENUM_DEF", ":", "enumDef", "(", "node", ")", ";", "break", ";", "case", "ANNOTATION_DEF", ":", "annotationDef", "(", "node", ")", ";", "break", ";", "default", ":", "{", "Statement", "statement", "=", "statement", "(", "node", ")", ";", "output", ".", "addStatement", "(", "statement", ")", ";", "}", "}", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "}", "protected", "void", "packageDef", "(", "AST", "packageDef", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "AST", "node", "=", "packageDef", ".", "getFirstChild", "(", ")", ";", "if", "(", "isType", "(", "ANNOTATIONS", ",", "node", ")", ")", "{", "processAnnotations", "(", "annotations", ",", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "if", "(", "node", "==", "null", ")", "{", "return", ";", "}", "String", "name", "=", "qualifiedName", "(", "node", ")", ";", "setPackageName", "(", "name", ")", ";", "if", "(", "name", "!=", "null", "&&", "name", ".", "length", "(", ")", ">", "0", ")", "{", "name", "+=", "'.'", ";", "}", "PackageNode", "packageNode", "=", "new", "PackageNode", "(", "name", ")", ";", "packageNode", ".", "addAnnotations", "(", "annotations", ")", ";", "output", ".", "setPackage", "(", "packageNode", ")", ";", "configureAST", "(", "packageNode", ",", "node", ")", ";", "}", "protected", "void", "importDef", "(", "AST", "importNode", ")", "{", "boolean", "isStatic", "=", "importNode", ".", "getType", "(", ")", "==", "STATIC_IMPORT", ";", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "AST", "node", "=", "importNode", ".", "getFirstChild", "(", ")", ";", "if", "(", "isType", "(", "ANNOTATIONS", ",", "node", ")", ")", "{", "processAnnotations", "(", "annotations", ",", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "String", "alias", "=", "null", ";", "AST", "aliasNode", "=", "null", ";", "if", "(", "isType", "(", "LITERAL_as", ",", "node", ")", ")", "{", "node", "=", "node", ".", "getFirstChild", "(", ")", ";", "aliasNode", "=", "node", ".", "getNextSibling", "(", ")", ";", "alias", "=", "identifier", "(", "aliasNode", ")", ";", "}", "if", "(", "node", ".", "getNumberOfChildren", "(", ")", "==", "0", ")", "{", "String", "name", "=", "identifier", "(", "node", ")", ";", "ClassNode", "type", "=", "ClassHelper", ".", "make", "(", "name", ")", ";", "configureAST", "(", "type", ",", "importNode", ")", ";", "addImport", "(", "type", ",", "name", ",", "alias", ",", "annotations", ")", ";", "return", ";", "}", "AST", "packageNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "String", "packageName", "=", "qualifiedName", "(", "packageNode", ")", ";", "AST", "nameNode", "=", "packageNode", ".", "getNextSibling", "(", ")", ";", "if", "(", "isType", "(", "STAR", ",", "nameNode", ")", ")", "{", "if", "(", "isStatic", ")", "{", "ClassNode", "type", "=", "ClassHelper", ".", "make", "(", "packageName", ")", ";", "configureAST", "(", "type", ",", "packageNode", ")", ";", "addStaticStarImport", "(", "type", ",", "packageName", ",", "annotations", ")", ";", "ASTNode", "imp", "=", "(", "ASTNode", ")", "output", ".", "getStaticStarImports", "(", ")", ".", "get", "(", "packageName", ")", ";", "configureAST", "(", "imp", ",", "importNode", ")", ";", "}", "else", "{", "addStarImport", "(", "packageName", ",", "annotations", ")", ";", "ASTNode", "imp", "=", "(", "ASTNode", ")", "output", ".", "getStarImports", "(", ")", ".", "get", "(", "output", ".", "getStarImports", "(", ")", ".", "size", "(", ")", "-", "1", ")", ";", "configureAST", "(", "imp", ",", "importNode", ")", ";", "}", "if", "(", "alias", "!=", "null", ")", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "\"\"", ")", ";", "}", "else", "{", "ImportNode", "imp", ";", "String", "name", "=", "identifier", "(", "nameNode", ")", ";", "if", "(", "isStatic", ")", "{", "ClassNode", "type", "=", "ClassHelper", ".", "make", "(", "packageName", ")", ";", "configureAST", "(", "type", ",", "packageNode", ")", ";", "addStaticImport", "(", "type", ",", "name", ",", "alias", ",", "annotations", ")", ";", "imp", "=", "output", ".", "getStaticImports", "(", ")", ".", "get", "(", "alias", "==", "null", "?", "name", ":", "alias", ")", ";", "configureAST", "(", "imp", ",", "importNode", ")", ";", "ConstantExpression", "nameExpr", "=", "new", "ConstantExpression", "(", "name", ")", ";", "configureAST", "(", "nameExpr", ",", "nameNode", ")", ";", "imp", ".", "setFieldNameExpr", "(", "nameExpr", ")", ";", "}", "else", "{", "ClassNode", "type", "=", "ClassHelper", ".", "make", "(", "packageName", "+", "\".\"", "+", "name", ")", ";", "configureAST", "(", "type", ",", "nameNode", ")", ";", "addImport", "(", "type", ",", "name", ",", "alias", ",", "annotations", ")", ";", "imp", "=", "output", ".", "getImport", "(", "alias", "==", "null", "?", "name", ":", "alias", ")", ";", "configureAST", "(", "imp", ",", "importNode", ")", ";", "}", "if", "(", "alias", "!=", "null", ")", "{", "ConstantExpression", "aliasExpr", "=", "new", "ConstantExpression", "(", "alias", ")", ";", "configureAST", "(", "aliasExpr", ",", "aliasNode", ")", ";", "imp", ".", "setAliasExpr", "(", "aliasExpr", ")", ";", "}", "}", "}", "private", "void", "processAnnotations", "(", "List", "<", "AnnotationNode", ">", "annotations", ",", "AST", "node", ")", "{", "AST", "child", "=", "node", ".", "getFirstChild", "(", ")", ";", "while", "(", "child", "!=", "null", ")", "{", "if", "(", "isType", "(", "ANNOTATION", ",", "child", ")", ")", "annotations", ".", "add", "(", "annotation", "(", "child", ")", ")", ";", "child", "=", "child", ".", "getNextSibling", "(", ")", ";", "}", "}", "protected", "void", "annotationDef", "(", "AST", "classDef", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "AST", "node", "=", "classDef", ".", "getFirstChild", "(", ")", ";", "int", "modifiers", "=", "Opcodes", ".", "ACC_PUBLIC", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "modifiers", "=", "modifiers", "(", "node", ",", "annotations", ",", "modifiers", ")", ";", "checkNoInvalidModifier", "(", "classDef", ",", "\"\"", ",", "modifiers", ",", "Opcodes", ".", "ACC_SYNCHRONIZED", ",", "\"synchronized\"", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "modifiers", "|=", "Opcodes", ".", "ACC_ABSTRACT", "|", "Opcodes", ".", "ACC_INTERFACE", "|", "Opcodes", ".", "ACC_ANNOTATION", ";", "String", "name", "=", "identifier", "(", "node", ")", ";", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "node", ";", "int", "nameStart", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLine", "(", ")", ",", "groovySourceAST", ".", "getColumn", "(", ")", ")", ";", "int", "nameEnd", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLineLast", "(", ")", ",", "groovySourceAST", ".", "getColumnLast", "(", ")", ")", "-", "1", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "ClassNode", "superClass", "=", "ClassHelper", ".", "OBJECT_TYPE", ";", "GenericsType", "[", "]", "genericsType", "=", "null", ";", "if", "(", "isType", "(", "TYPE_PARAMETERS", ",", "node", ")", ")", "{", "genericsType", "=", "makeGenericsType", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "ClassNode", "[", "]", "interfaces", "=", "ClassNode", ".", "EMPTY_ARRAY", ";", "if", "(", "isType", "(", "EXTENDS_CLAUSE", ",", "node", ")", ")", "{", "interfaces", "=", "interfaces", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "classNode", "=", "new", "ClassNode", "(", "dot", "(", "getPackageName", "(", ")", ",", "name", ")", ",", "modifiers", ",", "superClass", ",", "interfaces", ",", "null", ")", ";", "classNode", ".", "addAnnotations", "(", "annotations", ")", ";", "classNode", ".", "setGenericsTypes", "(", "genericsType", ")", ";", "classNode", ".", "addInterface", "(", "ClassHelper", ".", "Annotation_TYPE", ")", ";", "classNode", ".", "setNameStart", "(", "nameStart", ")", ";", "classNode", ".", "setNameEnd", "(", "nameEnd", ")", ";", "configureAST", "(", "classNode", ",", "classDef", ")", ";", "assertNodeType", "(", "OBJBLOCK", ",", "node", ")", ";", "objectBlock", "(", "node", ")", ";", "output", ".", "addClass", "(", "classNode", ")", ";", "classNode", "=", "null", ";", "}", "protected", "void", "interfaceDef", "(", "AST", "classDef", ")", "{", "int", "oldInnerClassCounter", "=", "innerClassCounter", ";", "innerInterfaceDef", "(", "classDef", ")", ";", "classNode", "=", "null", ";", "innerClassCounter", "=", "oldInnerClassCounter", ";", "}", "protected", "void", "innerInterfaceDef", "(", "AST", "classDef", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "AST", "node", "=", "classDef", ".", "getFirstChild", "(", ")", ";", "int", "modifiers", "=", "Opcodes", ".", "ACC_PUBLIC", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "modifiers", "=", "modifiers", "(", "node", ",", "annotations", ",", "modifiers", ")", ";", "checkNoInvalidModifier", "(", "classDef", ",", "\"Interface\"", ",", "modifiers", ",", "Opcodes", ".", "ACC_SYNCHRONIZED", ",", "\"synchronized\"", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "modifiers", "|=", "Opcodes", ".", "ACC_ABSTRACT", "|", "Opcodes", ".", "ACC_INTERFACE", ";", "String", "name", "=", "identifier", "(", "node", ")", ";", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "node", ";", "int", "nameStart", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLine", "(", ")", ",", "groovySourceAST", ".", "getColumn", "(", ")", ")", ";", "int", "nameEnd", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLineLast", "(", ")", ",", "groovySourceAST", ".", "getColumnLast", "(", ")", ")", "-", "1", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "ClassNode", "superClass", "=", "ClassHelper", ".", "OBJECT_TYPE", ";", "GenericsType", "[", "]", "genericsType", "=", "null", ";", "if", "(", "isType", "(", "TYPE_PARAMETERS", ",", "node", ")", ")", "{", "genericsType", "=", "makeGenericsType", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "ClassNode", "[", "]", "interfaces", "=", "ClassNode", ".", "EMPTY_ARRAY", ";", "if", "(", "isType", "(", "EXTENDS_CLAUSE", ",", "node", ")", ")", "{", "interfaces", "=", "interfaces", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "ClassNode", "outerClass", "=", "classNode", ";", "if", "(", "classNode", "!=", "null", ")", "{", "name", "=", "classNode", ".", "getNameWithoutPackage", "(", ")", "+", "\"$\"", "+", "name", ";", "String", "fullName", "=", "dot", "(", "classNode", ".", "getPackageName", "(", ")", ",", "name", ")", ";", "classNode", "=", "new", "InnerClassNode", "(", "classNode", ",", "fullName", ",", "modifiers", ",", "superClass", ",", "interfaces", ",", "null", ")", ";", "}", "else", "{", "classNode", "=", "new", "ClassNode", "(", "dot", "(", "getPackageName", "(", ")", ",", "name", ")", ",", "modifiers", ",", "superClass", ",", "interfaces", ",", "null", ")", ";", "}", "classNode", ".", "addAnnotations", "(", "annotations", ")", ";", "classNode", ".", "setGenericsTypes", "(", "genericsType", ")", ";", "configureAST", "(", "classNode", ",", "classDef", ")", ";", "classNode", ".", "setNameStart", "(", "nameStart", ")", ";", "classNode", ".", "setNameEnd", "(", "nameEnd", ")", ";", "int", "oldClassCount", "=", "innerClassCounter", ";", "assertNodeType", "(", "OBJBLOCK", ",", "node", ")", ";", "objectBlock", "(", "node", ")", ";", "output", ".", "addClass", "(", "classNode", ")", ";", "classNode", "=", "outerClass", ";", "innerClassCounter", "=", "oldClassCount", ";", "}", "protected", "void", "classDef", "(", "AST", "classDef", ")", "{", "int", "oldInnerClassCounter", "=", "innerClassCounter", ";", "innerClassDef", "(", "classDef", ")", ";", "classNode", "=", "null", ";", "innerClassCounter", "=", "oldInnerClassCounter", ";", "}", "private", "ClassNode", "getClassOrScript", "(", "ClassNode", "node", ")", "{", "if", "(", "node", "!=", "null", ")", "return", "node", ";", "return", "output", ".", "getScriptClassDummy", "(", ")", ";", "}", "protected", "Expression", "anonymousInnerClassDef", "(", "AST", "node", ")", "{", "ClassNode", "oldNode", "=", "classNode", ";", "ClassNode", "outerClass", "=", "getClassOrScript", "(", "oldNode", ")", ";", "String", "fullName", "=", "outerClass", ".", "getName", "(", ")", "+", "'$'", "+", "innerClassCounter", ";", "innerClassCounter", "++", ";", "if", "(", "enumConstantBeingDef", ")", "{", "classNode", "=", "new", "EnumConstantClassNode", "(", "outerClass", ",", "fullName", ",", "Opcodes", ".", "ACC_PUBLIC", ",", "ClassHelper", ".", "OBJECT_TYPE", ")", ";", "}", "else", "{", "classNode", "=", "new", "InnerClassNode", "(", "outerClass", ",", "fullName", ",", "Opcodes", ".", "ACC_PUBLIC", ",", "ClassHelper", ".", "OBJECT_TYPE", ")", ";", "}", "(", "(", "InnerClassNode", ")", "classNode", ")", ".", "setAnonymous", "(", "true", ")", ";", "assertNodeType", "(", "OBJBLOCK", ",", "node", ")", ";", "objectBlock", "(", "node", ")", ";", "output", ".", "addClass", "(", "classNode", ")", ";", "AnonymousInnerClassCarrier", "ret", "=", "new", "AnonymousInnerClassCarrier", "(", ")", ";", "ret", ".", "innerClass", "=", "classNode", ";", "configureAST", "(", "classNode", ",", "node", ")", ";", "classNode", "=", "oldNode", ";", "return", "ret", ";", "}", "protected", "void", "innerClassDef", "(", "AST", "classDef", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "AST", "node", "=", "classDef", ".", "getFirstChild", "(", ")", ";", "int", "modifiers", "=", "Opcodes", ".", "ACC_PUBLIC", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "modifiers", "=", "modifiers", "(", "node", ",", "annotations", ",", "modifiers", ")", ";", "checkNoInvalidModifier", "(", "classDef", ",", "\"Class\"", ",", "modifiers", ",", "Opcodes", ".", "ACC_SYNCHRONIZED", ",", "\"synchronized\"", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "String", "name", "=", "identifier", "(", "node", ")", ";", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "node", ";", "int", "nameStart", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLine", "(", ")", ",", "groovySourceAST", ".", "getColumn", "(", ")", ")", ";", "int", "nameEnd", "=", "nameStart", "+", "name", ".", "length", "(", ")", "-", "1", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "GenericsType", "[", "]", "genericsType", "=", "null", ";", "if", "(", "isType", "(", "TYPE_PARAMETERS", ",", "node", ")", ")", "{", "genericsType", "=", "makeGenericsType", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "ClassNode", "superClass", "=", "null", ";", "if", "(", "isType", "(", "EXTENDS_CLAUSE", ",", "node", ")", ")", "{", "superClass", "=", "makeTypeWithArguments", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "ClassNode", "[", "]", "interfaces", "=", "ClassNode", ".", "EMPTY_ARRAY", ";", "if", "(", "isType", "(", "IMPLEMENTS_CLAUSE", ",", "node", ")", ")", "{", "interfaces", "=", "interfaces", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "MixinNode", "[", "]", "mixins", "=", "{", "}", ";", "ClassNode", "outerClass", "=", "classNode", ";", "if", "(", "classNode", "!=", "null", ")", "{", "name", "=", "classNode", ".", "getNameWithoutPackage", "(", ")", "+", "\"$\"", "+", "name", ";", "String", "fullName", "=", "dot", "(", "classNode", ".", "getPackageName", "(", ")", ",", "name", ")", ";", "classNode", "=", "new", "InnerClassNode", "(", "classNode", ",", "fullName", ",", "modifiers", ",", "superClass", ",", "interfaces", ",", "mixins", ")", ";", "}", "else", "{", "classNode", "=", "new", "ClassNode", "(", "dot", "(", "getPackageName", "(", ")", ",", "name", ")", ",", "modifiers", ",", "superClass", ",", "interfaces", ",", "mixins", ")", ";", "}", "classNode", ".", "addAnnotations", "(", "annotations", ")", ";", "classNode", ".", "setGenericsTypes", "(", "genericsType", ")", ";", "configureAST", "(", "classNode", ",", "classDef", ")", ";", "classNode", ".", "setNameStart", "(", "nameStart", ")", ";", "classNode", ".", "setNameEnd", "(", "nameEnd", ")", ";", "output", ".", "addClass", "(", "classNode", ")", ";", "int", "oldClassCount", "=", "innerClassCounter", ";", "assertNodeType", "(", "OBJBLOCK", ",", "node", ")", ";", "objectBlock", "(", "node", ")", ";", "classNode", "=", "outerClass", ";", "innerClassCounter", "=", "oldClassCount", ";", "}", "protected", "void", "objectBlock", "(", "AST", "objectBlock", ")", "{", "for", "(", "AST", "node", "=", "objectBlock", ".", "getFirstChild", "(", ")", ";", "node", "!=", "null", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "int", "type", "=", "node", ".", "getType", "(", ")", ";", "switch", "(", "type", ")", "{", "case", "OBJBLOCK", ":", "objectBlock", "(", "node", ")", ";", "break", ";", "case", "ANNOTATION_FIELD_DEF", ":", "case", "METHOD_DEF", ":", "methodDef", "(", "node", ")", ";", "break", ";", "case", "CTOR_IDENT", ":", "constructorDef", "(", "node", ")", ";", "break", ";", "case", "VARIABLE_DEF", ":", "fieldDef", "(", "node", ")", ";", "break", ";", "case", "STATIC_INIT", ":", "staticInit", "(", "node", ")", ";", "break", ";", "case", "INSTANCE_INIT", ":", "objectInit", "(", "node", ")", ";", "break", ";", "case", "ENUM_DEF", ":", "enumDef", "(", "node", ")", ";", "break", ";", "case", "ENUM_CONSTANT_DEF", ":", "enumConstantDef", "(", "node", ")", ";", "break", ";", "case", "CLASS_DEF", ":", "innerClassDef", "(", "node", ")", ";", "break", ";", "case", "INTERFACE_DEF", ":", "innerInterfaceDef", "(", "node", ")", ";", "break", ";", "default", ":", "unknownAST", "(", "node", ")", ";", "}", "}", "}", "protected", "void", "enumDef", "(", "AST", "enumNode", ")", "{", "assertNodeType", "(", "ENUM_DEF", ",", "enumNode", ")", ";", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "AST", "node", "=", "enumNode", ".", "getFirstChild", "(", ")", ";", "int", "modifiers", "=", "Opcodes", ".", "ACC_PUBLIC", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "modifiers", "=", "modifiers", "(", "node", ",", "annotations", ",", "modifiers", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "node", ";", "int", "nameStart", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLine", "(", ")", ",", "groovySourceAST", ".", "getColumn", "(", ")", ")", ";", "int", "nameEnd", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLineLast", "(", ")", ",", "groovySourceAST", ".", "getColumnLast", "(", ")", ")", "-", "1", ";", "String", "name", "=", "identifier", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "ClassNode", "[", "]", "interfaces", "=", "interfaces", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "String", "enumName", "=", "(", "classNode", "!=", "null", "?", "name", ":", "dot", "(", "getPackageName", "(", ")", ",", "name", ")", ")", ";", "ClassNode", "enumClass", "=", "EnumHelper", ".", "makeEnumNode", "(", "enumName", ",", "modifiers", ",", "interfaces", ",", "classNode", ")", ";", "ClassNode", "oldNode", "=", "classNode", ";", "classNode", "=", "enumClass", ";", "assertNodeType", "(", "OBJBLOCK", ",", "node", ")", ";", "objectBlock", "(", "node", ")", ";", "classNode", ".", "setNameStart", "(", "nameStart", ")", ";", "classNode", ".", "setNameEnd", "(", "nameEnd", ")", ";", "configureAST", "(", "classNode", ",", "enumNode", ")", ";", "classNode", "=", "oldNode", ";", "output", ".", "addClass", "(", "enumClass", ")", ";", "}", "protected", "void", "enumConstantDef", "(", "AST", "node", ")", "{", "enumConstantBeingDef", "=", "true", ";", "assertNodeType", "(", "ENUM_CONSTANT_DEF", ",", "node", ")", ";", "AST", "element", "=", "node", ".", "getFirstChild", "(", ")", ";", "if", "(", "isType", "(", "ANNOTATIONS", ",", "element", ")", ")", "{", "element", "=", "element", ".", "getNextSibling", "(", ")", ";", "}", "String", "identifier", "=", "identifier", "(", "element", ")", ";", "Expression", "init", "=", "null", ";", "element", "=", "element", ".", "getNextSibling", "(", ")", ";", "if", "(", "element", "!=", "null", ")", "{", "init", "=", "expression", "(", "element", ")", ";", "ClassNode", "innerClass", "=", "getAnonymousInnerClassNode", "(", "init", ")", ";", "if", "(", "innerClass", "!=", "null", ")", "{", "innerClass", ".", "setSuperClass", "(", "classNode", ")", ";", "innerClass", ".", "setModifiers", "(", "classNode", ".", "getModifiers", "(", ")", "|", "Opcodes", ".", "ACC_FINAL", ")", ";", "init", "=", "new", "ClassExpression", "(", "innerClass", ")", ";", "classNode", ".", "setModifiers", "(", "classNode", ".", "getModifiers", "(", ")", "&", "~", "Opcodes", ".", "ACC_FINAL", ")", ";", "}", "else", "if", "(", "isType", "(", "ELIST", ",", "element", ")", ")", "{", "if", "(", "init", "instanceof", "ListExpression", "&&", "!", "(", "(", "ListExpression", ")", "init", ")", ".", "isWrapped", "(", ")", ")", "{", "ListExpression", "le", "=", "new", "ListExpression", "(", ")", ";", "le", ".", "addExpression", "(", "init", ")", ";", "init", "=", "le", ";", "}", "}", "}", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "node", ";", "int", "nameStart", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLine", "(", ")", ",", "groovySourceAST", ".", "getColumn", "(", ")", ")", ";", "int", "nameEnd", "=", "nameStart", "+", "identifier", ".", "length", "(", ")", "-", "1", ";", "FieldNode", "fn", "=", "EnumHelper", ".", "addEnumConstant", "(", "classNode", ",", "identifier", ",", "init", ")", ";", "fn", ".", "setNameStart", "(", "nameStart", ")", ";", "fn", ".", "setNameEnd", "(", "nameEnd", ")", ";", "enumConstantBeingDef", "=", "false", ";", "}", "protected", "void", "throwsList", "(", "AST", "node", ",", "List", "list", ")", "{", "String", "name", ";", "if", "(", "isType", "(", "DOT", ",", "node", ")", ")", "{", "name", "=", "qualifiedName", "(", "node", ")", ";", "}", "else", "{", "name", "=", "identifier", "(", "node", ")", ";", "}", "ClassNode", "exception", "=", "ClassHelper", ".", "make", "(", "name", ")", ";", "configureAST", "(", "exception", ",", "node", ")", ";", "list", ".", "add", "(", "exception", ")", ";", "AST", "next", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "next", "!=", "null", ")", "throwsList", "(", "next", ",", "list", ")", ";", "}", "protected", "void", "methodDef", "(", "AST", "methodDef", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "AST", "node", "=", "methodDef", ".", "getFirstChild", "(", ")", ";", "GenericsType", "[", "]", "generics", "=", "null", ";", "if", "(", "isType", "(", "TYPE_PARAMETERS", ",", "node", ")", ")", "{", "generics", "=", "makeGenericsType", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "int", "modifiers", "=", "Opcodes", ".", "ACC_PUBLIC", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "modifiers", "=", "modifiers", "(", "node", ",", "annotations", ",", "modifiers", ")", ";", "checkNoInvalidModifier", "(", "methodDef", ",", "\"Method\"", ",", "modifiers", ",", "Opcodes", ".", "ACC_VOLATILE", ",", "\"volatile\"", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "if", "(", "isAnInterface", "(", ")", ")", "{", "modifiers", "|=", "Opcodes", ".", "ACC_ABSTRACT", ";", "}", "ClassNode", "returnType", "=", "null", ";", "if", "(", "isType", "(", "TYPE", ",", "node", ")", ")", "{", "returnType", "=", "makeTypeWithArguments", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "String", "name", "=", "identifier", "(", "node", ")", ";", "if", "(", "classNode", "!=", "null", "&&", "!", "classNode", ".", "isAnnotationDefinition", "(", ")", ")", "{", "if", "(", "classNode", ".", "getNameWithoutPackage", "(", ")", ".", "equals", "(", "name", ")", ")", "{", "if", "(", "isAnInterface", "(", ")", ")", "{", "throw", "new", "ASTRuntimeException", "(", "methodDef", ",", "\"\"", ")", ";", "}", "throw", "new", "ASTRuntimeException", "(", "methodDef", ",", "\"\"", "+", "returnType", ".", "getName", "(", ")", "+", "\"\"", ")", ";", "}", "}", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "node", ";", "int", "nameStart", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLine", "(", ")", ",", "groovySourceAST", ".", "getColumn", "(", ")", ")", ";", "int", "nameEnd", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLine", "(", ")", ",", "groovySourceAST", ".", "getColumnLast", "(", ")", ")", "-", "1", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "Parameter", "[", "]", "parameters", "=", "Parameter", ".", "EMPTY_ARRAY", ";", "ClassNode", "[", "]", "exceptions", "=", "ClassNode", ".", "EMPTY_ARRAY", ";", "if", "(", "classNode", "==", "null", "||", "!", "classNode", ".", "isAnnotationDefinition", "(", ")", ")", "{", "assertNodeType", "(", "PARAMETERS", ",", "node", ")", ";", "parameters", "=", "parameters", "(", "node", ")", ";", "if", "(", "parameters", "==", "null", ")", "parameters", "=", "Parameter", ".", "EMPTY_ARRAY", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "isType", "(", "LITERAL_throws", ",", "node", ")", ")", "{", "AST", "throwsNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "List", "exceptionList", "=", "new", "ArrayList", "(", ")", ";", "throwsList", "(", "throwsNode", ",", "exceptionList", ")", ";", "exceptions", "=", "(", "ClassNode", "[", "]", ")", "exceptionList", ".", "toArray", "(", "exceptions", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "}", "boolean", "hasAnnotationDefault", "=", "false", ";", "Statement", "code", "=", "null", ";", "if", "(", "(", "modifiers", "&", "Opcodes", ".", "ACC_ABSTRACT", ")", "==", "0", ")", "{", "if", "(", "node", "==", "null", ")", "{", "throw", "new", "ASTRuntimeException", "(", "methodDef", ",", "\"\"", ")", ";", "}", "assertNodeType", "(", "SLIST", ",", "node", ")", ";", "code", "=", "statementList", "(", "node", ")", ";", "}", "else", "if", "(", "node", "!=", "null", "&&", "classNode", ".", "isAnnotationDefinition", "(", ")", ")", "{", "code", "=", "statement", "(", "node", ")", ";", "hasAnnotationDefault", "=", "true", ";", "}", "else", "if", "(", "(", "modifiers", "&", "Opcodes", ".", "ACC_ABSTRACT", ")", ">", "0", ")", "{", "if", "(", "node", "!=", "null", ")", "{", "throw", "new", "ASTRuntimeException", "(", "methodDef", ",", "\"\"", ")", ";", "}", "}", "MethodNode", "methodNode", "=", "new", "MethodNode", "(", "name", ",", "modifiers", ",", "returnType", ",", "parameters", ",", "exceptions", ",", "code", ")", ";", "methodNode", ".", "addAnnotations", "(", "annotations", ")", ";", "methodNode", ".", "setGenericsTypes", "(", "generics", ")", ";", "methodNode", ".", "setAnnotationDefault", "(", "hasAnnotationDefault", ")", ";", "configureAST", "(", "methodNode", ",", "methodDef", ")", ";", "methodNode", ".", "setNameStart", "(", "nameStart", ")", ";", "methodNode", ".", "setNameEnd", "(", "nameEnd", ")", ";", "if", "(", "classNode", "!=", "null", ")", "{", "classNode", ".", "addMethod", "(", "methodNode", ")", ";", "}", "else", "{", "output", ".", "addMethod", "(", "methodNode", ")", ";", "}", "}", "private", "void", "checkNoInvalidModifier", "(", "AST", "node", ",", "String", "nodeType", ",", "int", "modifiers", ",", "int", "modifier", ",", "String", "modifierText", ")", "{", "if", "(", "(", "modifiers", "&", "modifier", ")", "!=", "0", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "nodeType", "+", "\"\"", "+", "modifierText", "+", "\"'.\"", ")", ";", "}", "}", "private", "boolean", "isAnInterface", "(", ")", "{", "return", "classNode", "!=", "null", "&&", "(", "classNode", ".", "getModifiers", "(", ")", "&", "Opcodes", ".", "ACC_INTERFACE", ")", ">", "0", ";", "}", "protected", "void", "staticInit", "(", "AST", "staticInit", ")", "{", "BlockStatement", "code", "=", "(", "BlockStatement", ")", "statementList", "(", "staticInit", ")", ";", "classNode", ".", "addStaticInitializerStatements", "(", "code", ".", "getStatements", "(", ")", ",", "false", ")", ";", "}", "protected", "void", "objectInit", "(", "AST", "init", ")", "{", "BlockStatement", "code", "=", "(", "BlockStatement", ")", "statementList", "(", "init", ")", ";", "classNode", ".", "addObjectInitializerStatements", "(", "code", ")", ";", "}", "protected", "void", "constructorDef", "(", "AST", "constructorDef", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "AST", "node", "=", "constructorDef", ".", "getFirstChild", "(", ")", ";", "int", "modifiers", "=", "Opcodes", ".", "ACC_PUBLIC", ";", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "node", ";", "int", "nameStart", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLineLast", "(", ")", ",", "groovySourceAST", ".", "getColumnLast", "(", ")", ")", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "modifiers", "=", "modifiers", "(", "node", ",", "annotations", ",", "modifiers", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "assertNodeType", "(", "PARAMETERS", ",", "node", ")", ";", "Parameter", "[", "]", "parameters", "=", "parameters", "(", "node", ")", ";", "if", "(", "parameters", "==", "null", ")", "parameters", "=", "Parameter", ".", "EMPTY_ARRAY", ";", "int", "nameEnd", "=", "locations", ".", "findOffset", "(", "node", ".", "getLine", "(", ")", ",", "node", ".", "getColumn", "(", ")", ")", "-", "2", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "ClassNode", "[", "]", "exceptions", "=", "ClassNode", ".", "EMPTY_ARRAY", ";", "if", "(", "isType", "(", "LITERAL_throws", ",", "node", ")", ")", "{", "AST", "throwsNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "List", "exceptionList", "=", "new", "ArrayList", "(", ")", ";", "throwsList", "(", "throwsNode", ",", "exceptionList", ")", ";", "exceptions", "=", "(", "ClassNode", "[", "]", ")", "exceptionList", ".", "toArray", "(", "exceptions", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "assertNodeType", "(", "SLIST", ",", "node", ")", ";", "Statement", "code", "=", "statementList", "(", "node", ")", ";", "ConstructorNode", "constructorNode", "=", "classNode", ".", "addConstructor", "(", "modifiers", ",", "parameters", ",", "exceptions", ",", "code", ")", ";", "constructorNode", ".", "addAnnotations", "(", "annotations", ")", ";", "configureAST", "(", "constructorNode", ",", "constructorDef", ")", ";", "constructorNode", ".", "setNameStart", "(", "nameStart", ")", ";", "constructorNode", ".", "setNameEnd", "(", "nameEnd", ")", ";", "}", "protected", "void", "fieldDef", "(", "AST", "fieldDef", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "AST", "node", "=", "fieldDef", ".", "getFirstChild", "(", ")", ";", "int", "modifiers", "=", "0", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "modifiers", "=", "modifiers", "(", "node", ",", "annotations", ",", "modifiers", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "if", "(", "classNode", ".", "isInterface", "(", ")", ")", "{", "modifiers", "|=", "Opcodes", ".", "ACC_STATIC", "|", "Opcodes", ".", "ACC_FINAL", ";", "if", "(", "(", "modifiers", "&", "(", "Opcodes", ".", "ACC_PRIVATE", "|", "Opcodes", ".", "ACC_PROTECTED", ")", ")", "==", "0", ")", "{", "modifiers", "|=", "Opcodes", ".", "ACC_PUBLIC", ";", "}", "}", "ClassNode", "type", "=", "null", ";", "if", "(", "isType", "(", "TYPE", ",", "node", ")", ")", "{", "type", "=", "makeTypeWithArguments", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "String", "name", "=", "identifier", "(", "node", ")", ";", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "node", ";", "int", "nameStart", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLine", "(", ")", ",", "groovySourceAST", ".", "getColumn", "(", ")", ")", ";", "int", "nameEnd", "=", "nameStart", "+", "name", ".", "length", "(", ")", "-", "1", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "Expression", "initialValue", "=", "null", ";", "if", "(", "node", "!=", "null", ")", "{", "assertNodeType", "(", "ASSIGN", ",", "node", ")", ";", "initialValue", "=", "expression", "(", "node", ".", "getFirstChild", "(", ")", ")", ";", "}", "if", "(", "classNode", ".", "isInterface", "(", ")", "&&", "initialValue", "==", "null", "&&", "type", "!=", "null", ")", "{", "if", "(", "type", "==", "ClassHelper", ".", "int_TYPE", ")", "{", "initialValue", "=", "new", "ConstantExpression", "(", "0", ")", ";", "}", "else", "if", "(", "type", "==", "ClassHelper", ".", "long_TYPE", ")", "{", "initialValue", "=", "new", "ConstantExpression", "(", "0L", ")", ";", "}", "else", "if", "(", "type", "==", "ClassHelper", ".", "double_TYPE", ")", "{", "initialValue", "=", "new", "ConstantExpression", "(", "0.0", ")", ";", "}", "else", "if", "(", "type", "==", "ClassHelper", ".", "float_TYPE", ")", "{", "initialValue", "=", "new", "ConstantExpression", "(", "0.0F", ")", ";", "}", "else", "if", "(", "type", "==", "ClassHelper", ".", "boolean_TYPE", ")", "{", "initialValue", "=", "ConstantExpression", ".", "FALSE", ";", "}", "else", "if", "(", "type", "==", "ClassHelper", ".", "short_TYPE", ")", "{", "initialValue", "=", "new", "ConstantExpression", "(", "(", "short", ")", "0", ")", ";", "}", "else", "if", "(", "type", "==", "ClassHelper", ".", "byte_TYPE", ")", "{", "initialValue", "=", "new", "ConstantExpression", "(", "(", "byte", ")", "0", ")", ";", "}", "else", "if", "(", "type", "==", "ClassHelper", ".", "char_TYPE", ")", "{", "initialValue", "=", "new", "ConstantExpression", "(", "(", "char", ")", "0", ")", ";", "}", "}", "FieldNode", "fieldNode", "=", "new", "FieldNode", "(", "name", ",", "modifiers", ",", "type", ",", "classNode", ",", "initialValue", ")", ";", "fieldNode", ".", "addAnnotations", "(", "annotations", ")", ";", "configureAST", "(", "fieldNode", ",", "fieldDef", ")", ";", "fieldNode", ".", "setNameStart", "(", "nameStart", ")", ";", "fieldNode", ".", "setNameEnd", "(", "nameEnd", ")", ";", "if", "(", "!", "hasVisibility", "(", "modifiers", ")", ")", "{", "int", "fieldModifiers", "=", "0", ";", "int", "flags", "=", "Opcodes", ".", "ACC_STATIC", "|", "Opcodes", ".", "ACC_TRANSIENT", "|", "Opcodes", ".", "ACC_VOLATILE", "|", "Opcodes", ".", "ACC_FINAL", ";", "if", "(", "!", "hasVisibility", "(", "modifiers", ")", ")", "{", "modifiers", "|=", "Opcodes", ".", "ACC_PUBLIC", ";", "fieldModifiers", "|=", "Opcodes", ".", "ACC_PRIVATE", ";", "}", "fieldModifiers", "|=", "(", "modifiers", "&", "flags", ")", ";", "fieldNode", ".", "setModifiers", "(", "fieldModifiers", ")", ";", "fieldNode", ".", "setSynthetic", "(", "true", ")", ";", "FieldNode", "storedNode", "=", "classNode", ".", "getDeclaredField", "(", "fieldNode", ".", "getName", "(", ")", ")", ";", "if", "(", "storedNode", "!=", "null", "&&", "!", "classNode", ".", "hasProperty", "(", "name", ")", ")", "{", "fieldNode", "=", "storedNode", ";", "classNode", ".", "getFields", "(", ")", ".", "remove", "(", "storedNode", ")", ";", "}", "PropertyNode", "propertyNode", "=", "new", "PropertyNode", "(", "fieldNode", ",", "modifiers", ",", "null", ",", "null", ")", ";", "configureAST", "(", "propertyNode", ",", "fieldDef", ")", ";", "classNode", ".", "addProperty", "(", "propertyNode", ")", ";", "}", "else", "{", "fieldNode", ".", "setModifiers", "(", "modifiers", ")", ";", "PropertyNode", "pn", "=", "classNode", ".", "getProperty", "(", "name", ")", ";", "if", "(", "pn", "!=", "null", "&&", "pn", ".", "getField", "(", ")", ".", "isSynthetic", "(", ")", ")", "{", "classNode", ".", "getFields", "(", ")", ".", "remove", "(", "pn", ".", "getField", "(", ")", ")", ";", "pn", ".", "setField", "(", "fieldNode", ")", ";", "}", "classNode", ".", "addField", "(", "fieldNode", ")", ";", "}", "}", "protected", "ClassNode", "[", "]", "interfaces", "(", "AST", "node", ")", "{", "List", "<", "ClassNode", ">", "interfaceList", "=", "new", "ArrayList", "<", "ClassNode", ">", "(", ")", ";", "for", "(", "AST", "implementNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "implementNode", "!=", "null", ";", "implementNode", "=", "implementNode", ".", "getNextSibling", "(", ")", ")", "{", "ClassNode", "cn", "=", "makeTypeWithArguments", "(", "implementNode", ")", ";", "configureAST", "(", "cn", ",", "implementNode", ")", ";", "interfaceList", ".", "add", "(", "cn", ")", ";", "}", "ClassNode", "[", "]", "interfaces", "=", "ClassNode", ".", "EMPTY_ARRAY", ";", "if", "(", "!", "interfaceList", ".", "isEmpty", "(", ")", ")", "{", "interfaces", "=", "new", "ClassNode", "[", "interfaceList", ".", "size", "(", ")", "]", ";", "interfaceList", ".", "toArray", "(", "interfaces", ")", ";", "}", "return", "interfaces", ";", "}", "protected", "Parameter", "[", "]", "parameters", "(", "AST", "parametersNode", ")", "{", "AST", "node", "=", "parametersNode", ".", "getFirstChild", "(", ")", ";", "if", "(", "node", "==", "null", ")", "{", "if", "(", "isType", "(", "IMPLICIT_PARAMETERS", ",", "parametersNode", ")", ")", "return", "Parameter", ".", "EMPTY_ARRAY", ";", "return", "null", ";", "}", "else", "{", "List", "<", "Parameter", ">", "parameters", "=", "new", "ArrayList", "<", "Parameter", ">", "(", ")", ";", "do", "{", "parameters", ".", "add", "(", "parameter", "(", "node", ")", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "while", "(", "node", "!=", "null", ")", ";", "Parameter", "[", "]", "answer", "=", "new", "Parameter", "[", "parameters", ".", "size", "(", ")", "]", ";", "parameters", ".", "toArray", "(", "answer", ")", ";", "return", "answer", ";", "}", "}", "protected", "Parameter", "parameter", "(", "AST", "paramNode", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "boolean", "variableParameterDef", "=", "isType", "(", "VARIABLE_PARAMETER_DEF", ",", "paramNode", ")", ";", "AST", "node", "=", "paramNode", ".", "getFirstChild", "(", ")", ";", "int", "modifiers", "=", "0", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "modifiers", "=", "modifiers", "(", "node", ",", "annotations", ",", "modifiers", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "ClassNode", "type", "=", "ClassHelper", ".", "DYNAMIC_TYPE", ";", "if", "(", "isType", "(", "TYPE", ",", "node", ")", ")", "{", "type", "=", "makeTypeWithArguments", "(", "node", ")", ";", "if", "(", "variableParameterDef", ")", "type", "=", "type", ".", "makeArray", "(", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "String", "name", "=", "identifier", "(", "node", ")", ";", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "node", ";", "int", "nameStart", "=", "locations", ".", "findOffset", "(", "groovySourceAST", ".", "getLine", "(", ")", ",", "groovySourceAST", ".", "getColumn", "(", ")", ")", ";", "int", "nameEnd", "=", "nameStart", "+", "name", ".", "length", "(", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "VariableExpression", "leftExpression", "=", "new", "VariableExpression", "(", "name", ",", "type", ")", ";", "configureAST", "(", "leftExpression", ",", "paramNode", ")", ";", "Parameter", "parameter", "=", "null", ";", "if", "(", "node", "!=", "null", ")", "{", "assertNodeType", "(", "ASSIGN", ",", "node", ")", ";", "Expression", "rightExpression", "=", "expression", "(", "node", ".", "getFirstChild", "(", ")", ")", ";", "if", "(", "isAnInterface", "(", ")", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", "+", "name", "+", "\"", "=", "\"", "+", "rightExpression", ".", "getText", "(", ")", "+", "\"\"", ")", ";", "}", "parameter", "=", "new", "Parameter", "(", "type", ",", "name", ",", "rightExpression", ")", ";", "}", "else", "parameter", "=", "new", "Parameter", "(", "type", ",", "name", ")", ";", "configureAST", "(", "parameter", ",", "paramNode", ")", ";", "parameter", ".", "setNameStart", "(", "nameStart", ")", ";", "parameter", ".", "setNameEnd", "(", "nameEnd", ")", ";", "parameter", ".", "addAnnotations", "(", "annotations", ")", ";", "return", "parameter", ";", "}", "protected", "int", "modifiers", "(", "AST", "modifierNode", ",", "List", "<", "AnnotationNode", ">", "annotations", ",", "int", "defaultModifiers", ")", "{", "assertNodeType", "(", "MODIFIERS", ",", "modifierNode", ")", ";", "boolean", "access", "=", "false", ";", "int", "answer", "=", "0", ";", "for", "(", "AST", "node", "=", "modifierNode", ".", "getFirstChild", "(", ")", ";", "node", "!=", "null", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "int", "type", "=", "node", ".", "getType", "(", ")", ";", "switch", "(", "type", ")", "{", "case", "STATIC_IMPORT", ":", "break", ";", "case", "ANNOTATION", ":", "annotations", ".", "add", "(", "annotation", "(", "node", ")", ")", ";", "break", ";", "case", "LITERAL_private", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_PRIVATE", ")", ";", "access", "=", "setAccessTrue", "(", "node", ",", "access", ")", ";", "break", ";", "case", "LITERAL_protected", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_PROTECTED", ")", ";", "access", "=", "setAccessTrue", "(", "node", ",", "access", ")", ";", "break", ";", "case", "LITERAL_public", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_PUBLIC", ")", ";", "access", "=", "setAccessTrue", "(", "node", ",", "access", ")", ";", "break", ";", "case", "ABSTRACT", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_ABSTRACT", ")", ";", "break", ";", "case", "FINAL", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_FINAL", ")", ";", "break", ";", "case", "LITERAL_native", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_NATIVE", ")", ";", "break", ";", "case", "LITERAL_static", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_STATIC", ")", ";", "break", ";", "case", "STRICTFP", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_STRICT", ")", ";", "break", ";", "case", "LITERAL_synchronized", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_SYNCHRONIZED", ")", ";", "break", ";", "case", "LITERAL_transient", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_TRANSIENT", ")", ";", "break", ";", "case", "LITERAL_volatile", ":", "answer", "=", "setModifierBit", "(", "node", ",", "answer", ",", "Opcodes", ".", "ACC_VOLATILE", ")", ";", "break", ";", "default", ":", "unknownAST", "(", "node", ")", ";", "}", "}", "if", "(", "!", "access", ")", "{", "answer", "|=", "defaultModifiers", ";", "}", "return", "answer", ";", "}", "protected", "boolean", "setAccessTrue", "(", "AST", "node", ",", "boolean", "access", ")", "{", "if", "(", "!", "access", ")", "{", "return", "true", ";", "}", "else", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", "+", "node", ".", "getText", "(", ")", "+", "\"\"", ")", ";", "}", "}", "protected", "int", "setModifierBit", "(", "AST", "node", ",", "int", "answer", ",", "int", "bit", ")", "{", "if", "(", "(", "answer", "&", "bit", ")", "!=", "0", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", "+", "node", ".", "getText", "(", ")", ")", ";", "}", "return", "answer", "|", "bit", ";", "}", "protected", "AnnotationNode", "annotation", "(", "AST", "annotationNode", ")", "{", "AST", "node", "=", "annotationNode", ".", "getFirstChild", "(", ")", ";", "String", "name", "=", "qualifiedName", "(", "node", ")", ";", "AnnotationNode", "annotatedNode", "=", "new", "AnnotationNode", "(", "ClassHelper", ".", "make", "(", "name", ")", ")", ";", "configureAnnotationAST", "(", "annotatedNode", ",", "annotationNode", ")", ";", "while", "(", "true", ")", "{", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "isType", "(", "ANNOTATION_MEMBER_VALUE_PAIR", ",", "node", ")", ")", "{", "AST", "memberNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "String", "param", "=", "identifier", "(", "memberNode", ")", ";", "Expression", "expression", "=", "expression", "(", "memberNode", ".", "getNextSibling", "(", ")", ")", ";", "if", "(", "annotatedNode", ".", "getMember", "(", "param", ")", "!=", "null", ")", "{", "throw", "new", "ASTRuntimeException", "(", "memberNode", ",", "\"\"", "+", "param", "+", "\"\"", ")", ";", "}", "annotatedNode", ".", "setMember", "(", "param", ",", "expression", ")", ";", "}", "else", "{", "break", ";", "}", "}", "return", "annotatedNode", ";", "}", "protected", "Statement", "statement", "(", "AST", "node", ")", "{", "if", "(", "node", "==", "null", ")", "{", "return", "new", "EmptyStatement", "(", ")", ";", "}", "Statement", "statement", "=", "null", ";", "int", "type", "=", "node", ".", "getType", "(", ")", ";", "switch", "(", "type", ")", "{", "case", "SLIST", ":", "case", "LITERAL_finally", ":", "statement", "=", "statementList", "(", "node", ")", ";", "break", ";", "case", "METHOD_CALL", ":", "statement", "=", "methodCall", "(", "node", ")", ";", "break", ";", "case", "VARIABLE_DEF", ":", "statement", "=", "variableDef", "(", "node", ")", ";", "break", ";", "case", "LABELED_STAT", ":", "statement", "=", "labelledStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_assert", ":", "statement", "=", "assertStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_break", ":", "statement", "=", "breakStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_continue", ":", "statement", "=", "continueStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_if", ":", "statement", "=", "ifStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_for", ":", "statement", "=", "forStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_return", ":", "statement", "=", "returnStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_synchronized", ":", "statement", "=", "synchronizedStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_switch", ":", "statement", "=", "switchStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_try", ":", "statement", "=", "tryStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_throw", ":", "statement", "=", "throwStatement", "(", "node", ")", ";", "break", ";", "case", "LITERAL_while", ":", "statement", "=", "whileStatement", "(", "node", ")", ";", "break", ";", "default", ":", "statement", "=", "new", "ExpressionStatement", "(", "expression", "(", "node", ")", ")", ";", "}", "if", "(", "statement", "!=", "null", "&&", "type", "!=", "LABELED_STAT", ")", "{", "configureAST", "(", "statement", ",", "node", ")", ";", "}", "return", "statement", ";", "}", "protected", "Statement", "statementList", "(", "AST", "code", ")", "{", "return", "statementListNoChild", "(", "code", ".", "getFirstChild", "(", ")", ",", "code", ")", ";", "}", "protected", "Statement", "statementListNoChild", "(", "AST", "node", ",", "AST", "alternativeConfigureNode", ")", "{", "BlockStatement", "block", "=", "new", "BlockStatement", "(", ")", ";", "if", "(", "alternativeConfigureNode", "!=", "null", ")", "{", "configureAST", "(", "block", ",", "alternativeConfigureNode", ")", ";", "}", "else", "if", "(", "node", "!=", "null", ")", "{", "configureAST", "(", "block", ",", "node", ")", ";", "}", "for", "(", ";", "node", "!=", "null", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "block", ".", "addStatement", "(", "statement", "(", "node", ")", ")", ";", "}", "return", "block", ";", "}", "protected", "Statement", "assertStatement", "(", "AST", "assertNode", ")", "{", "AST", "node", "=", "assertNode", ".", "getFirstChild", "(", ")", ";", "BooleanExpression", "booleanExpression", "=", "booleanExpression", "(", "node", ")", ";", "Expression", "messageExpression", "=", "null", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "node", "!=", "null", ")", "{", "messageExpression", "=", "expression", "(", "node", ")", ";", "}", "else", "{", "messageExpression", "=", "ConstantExpression", ".", "NULL", ";", "}", "AssertStatement", "assertStatement", "=", "new", "AssertStatement", "(", "booleanExpression", ",", "messageExpression", ")", ";", "configureAST", "(", "assertStatement", ",", "assertNode", ")", ";", "return", "assertStatement", ";", "}", "protected", "Statement", "breakStatement", "(", "AST", "node", ")", "{", "BreakStatement", "breakStatement", "=", "new", "BreakStatement", "(", "label", "(", "node", ")", ")", ";", "configureAST", "(", "breakStatement", ",", "node", ")", ";", "return", "breakStatement", ";", "}", "protected", "Statement", "continueStatement", "(", "AST", "node", ")", "{", "ContinueStatement", "continueStatement", "=", "new", "ContinueStatement", "(", "label", "(", "node", ")", ")", ";", "configureAST", "(", "continueStatement", ",", "node", ")", ";", "return", "continueStatement", ";", "}", "protected", "Statement", "forStatement", "(", "AST", "forNode", ")", "{", "AST", "inNode", "=", "forNode", ".", "getFirstChild", "(", ")", ";", "Expression", "collectionExpression", ";", "Parameter", "forParameter", ";", "if", "(", "isType", "(", "CLOSURE_LIST", ",", "inNode", ")", ")", "{", "forStatementBeingDef", "=", "true", ";", "ClosureListExpression", "clist", "=", "closureListExpression", "(", "inNode", ")", ";", "forStatementBeingDef", "=", "false", ";", "int", "size", "=", "clist", ".", "getExpressions", "(", ")", ".", "size", "(", ")", ";", "if", "(", "size", "!=", "3", ")", "{", "throw", "new", "ASTRuntimeException", "(", "inNode", ",", "\"\"", "+", "size", ")", ";", "}", "collectionExpression", "=", "clist", ";", "forParameter", "=", "ForStatement", ".", "FOR_LOOP_DUMMY", ";", "}", "else", "{", "AST", "variableNode", "=", "inNode", ".", "getFirstChild", "(", ")", ";", "AST", "collectionNode", "=", "variableNode", ".", "getNextSibling", "(", ")", ";", "ClassNode", "type", "=", "ClassHelper", ".", "OBJECT_TYPE", ";", "if", "(", "isType", "(", "VARIABLE_DEF", ",", "variableNode", ")", ")", "{", "AST", "node", "=", "variableNode", ".", "getFirstChild", "(", ")", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "int", "modifiersMask", "=", "modifiers", "(", "node", ",", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ",", "0", ")", ";", "if", "(", "(", "modifiersMask", "&", "~", "Opcodes", ".", "ACC_FINAL", ")", "!=", "0", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", ")", ";", "}", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "type", "=", "makeTypeWithArguments", "(", "node", ")", ";", "variableNode", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "String", "variable", "=", "identifier", "(", "variableNode", ")", ";", "collectionExpression", "=", "expression", "(", "collectionNode", ")", ";", "forParameter", "=", "new", "Parameter", "(", "type", ",", "variable", ")", ";", "configureAST", "(", "forParameter", ",", "variableNode", ")", ";", "forParameter", ".", "setNameStart", "(", "forParameter", ".", "getStart", "(", ")", ")", ";", "forParameter", ".", "setNameEnd", "(", "forParameter", ".", "getEnd", "(", ")", ")", ";", "}", "final", "AST", "node", "=", "inNode", ".", "getNextSibling", "(", ")", ";", "Statement", "block", ";", "if", "(", "isType", "(", "SEMI", ",", "node", ")", ")", "{", "block", "=", "EmptyStatement", ".", "INSTANCE", ";", "}", "else", "{", "block", "=", "statement", "(", "node", ")", ";", "}", "ForStatement", "forStatement", "=", "new", "ForStatement", "(", "forParameter", ",", "collectionExpression", ",", "block", ")", ";", "configureAST", "(", "forStatement", ",", "forNode", ")", ";", "return", "forStatement", ";", "}", "protected", "Statement", "ifStatement", "(", "AST", "ifNode", ")", "{", "AST", "node", "=", "ifNode", ".", "getFirstChild", "(", ")", ";", "assertNodeType", "(", "EXPR", ",", "node", ")", ";", "BooleanExpression", "booleanExpression", "=", "booleanExpression", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "Statement", "ifBlock", "=", "statement", "(", "node", ")", ";", "Statement", "elseBlock", "=", "EmptyStatement", ".", "INSTANCE", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "node", "!=", "null", ")", "{", "elseBlock", "=", "statement", "(", "node", ")", ";", "}", "IfStatement", "ifStatement", "=", "new", "IfStatement", "(", "booleanExpression", ",", "ifBlock", ",", "elseBlock", ")", ";", "configureAST", "(", "ifStatement", ",", "ifNode", ")", ";", "return", "ifStatement", ";", "}", "protected", "Statement", "labelledStatement", "(", "AST", "labelNode", ")", "{", "AST", "node", "=", "labelNode", ".", "getFirstChild", "(", ")", ";", "String", "label", "=", "identifier", "(", "node", ")", ";", "Statement", "statement", "=", "statement", "(", "node", ".", "getNextSibling", "(", ")", ")", ";", "if", "(", "statement", ".", "getStatementLabel", "(", ")", "==", "null", ")", "statement", ".", "setStatementLabel", "(", "label", ")", ";", "return", "statement", ";", "}", "protected", "Statement", "methodCall", "(", "AST", "code", ")", "{", "Expression", "expression", "=", "methodCallExpression", "(", "code", ")", ";", "ExpressionStatement", "expressionStatement", "=", "new", "ExpressionStatement", "(", "expression", ")", ";", "configureAST", "(", "expressionStatement", ",", "code", ")", ";", "return", "expressionStatement", ";", "}", "protected", "Expression", "declarationExpression", "(", "AST", "variableDef", ")", "{", "AST", "node", "=", "variableDef", ".", "getFirstChild", "(", ")", ";", "ClassNode", "type", "=", "null", ";", "List", "<", "AnnotationNode", ">", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ";", "boolean", "staticVariable", "=", "false", ";", "AST", "modifierNode", "=", "null", ";", "if", "(", "isType", "(", "MODIFIERS", ",", "node", ")", ")", "{", "int", "modifiers", "=", "modifiers", "(", "node", ",", "annotations", ",", "0", ")", ";", "if", "(", "(", "modifiers", "&", "Opcodes", ".", "ACC_STATIC", ")", "!=", "0", ")", "{", "modifierNode", "=", "node", ";", "staticVariable", "=", "true", ";", "}", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "if", "(", "isType", "(", "TYPE", ",", "node", ")", ")", "{", "type", "=", "makeTypeWithArguments", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "Expression", "leftExpression", ";", "Expression", "rightExpression", "=", "ConstantExpression", ".", "NULL", ";", "AST", "right", ";", "if", "(", "isType", "(", "ASSIGN", ",", "node", ")", ")", "{", "node", "=", "node", ".", "getFirstChild", "(", ")", ";", "AST", "left", "=", "node", ".", "getFirstChild", "(", ")", ";", "ArgumentListExpression", "alist", "=", "new", "ArgumentListExpression", "(", ")", ";", "for", "(", "AST", "varDef", "=", "left", ";", "varDef", "!=", "null", ";", "varDef", "=", "varDef", ".", "getNextSibling", "(", ")", ")", "{", "assertNodeType", "(", "VARIABLE_DEF", ",", "varDef", ")", ";", "DeclarationExpression", "de", "=", "(", "DeclarationExpression", ")", "declarationExpression", "(", "varDef", ")", ";", "alist", ".", "addExpression", "(", "de", ".", "getVariableExpression", "(", ")", ")", ";", "}", "leftExpression", "=", "alist", ";", "right", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "right", "!=", "null", ")", "rightExpression", "=", "expression", "(", "right", ")", ";", "}", "else", "{", "if", "(", "staticVariable", ")", "{", "throw", "new", "ASTRuntimeException", "(", "modifierNode", ",", "\"\"", ")", ";", "}", "String", "name", "=", "identifier", "(", "node", ")", ";", "VariableExpression", "ve", "=", "new", "VariableExpression", "(", "name", ",", "type", ")", ";", "ve", ".", "addAnnotations", "(", "annotations", ")", ";", "leftExpression", "=", "ve", ";", "right", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "right", "!=", "null", ")", "{", "assertNodeType", "(", "ASSIGN", ",", "right", ")", ";", "rightExpression", "=", "expression", "(", "right", ".", "getFirstChild", "(", ")", ")", ";", "}", "}", "configureAST", "(", "leftExpression", ",", "node", ")", ";", "Token", "token", "=", "makeToken", "(", "Types", ".", "ASSIGN", ",", "variableDef", ")", ";", "DeclarationExpression", "expression", "=", "new", "DeclarationExpression", "(", "leftExpression", ",", "token", ",", "rightExpression", ")", ";", "configureAST", "(", "expression", ",", "variableDef", ")", ";", "ExpressionStatement", "expressionStatement", "=", "new", "ExpressionStatement", "(", "expression", ")", ";", "configureAST", "(", "expressionStatement", ",", "variableDef", ")", ";", "return", "expression", ";", "}", "protected", "Statement", "variableDef", "(", "AST", "variableDef", ")", "{", "ExpressionStatement", "expressionStatement", "=", "new", "ExpressionStatement", "(", "declarationExpression", "(", "variableDef", ")", ")", ";", "configureAST", "(", "expressionStatement", ",", "variableDef", ")", ";", "return", "expressionStatement", ";", "}", "protected", "Statement", "returnStatement", "(", "AST", "node", ")", "{", "AST", "exprNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Expression", "expression", "=", "exprNode", "==", "null", "?", "ConstantExpression", ".", "NULL", ":", "expression", "(", "exprNode", ")", ";", "ReturnStatement", "returnStatement", "=", "new", "ReturnStatement", "(", "expression", ")", ";", "configureAST", "(", "returnStatement", ",", "node", ")", ";", "return", "returnStatement", ";", "}", "protected", "Statement", "switchStatement", "(", "AST", "switchNode", ")", "{", "AST", "node", "=", "switchNode", ".", "getFirstChild", "(", ")", ";", "Expression", "expression", "=", "expression", "(", "node", ")", ";", "Statement", "defaultStatement", "=", "EmptyStatement", ".", "INSTANCE", ";", "List", "list", "=", "new", "ArrayList", "(", ")", ";", "for", "(", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "isType", "(", "CASE_GROUP", ",", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "Statement", "tmpDefaultStatement", ";", "AST", "child", "=", "node", ".", "getFirstChild", "(", ")", ";", "if", "(", "isType", "(", "LITERAL_case", ",", "child", ")", ")", "{", "List", "cases", "=", "new", "LinkedList", "(", ")", ";", "tmpDefaultStatement", "=", "caseStatements", "(", "child", ",", "cases", ")", ";", "list", ".", "addAll", "(", "cases", ")", ";", "}", "else", "{", "tmpDefaultStatement", "=", "statement", "(", "child", ".", "getNextSibling", "(", ")", ")", ";", "}", "if", "(", "tmpDefaultStatement", "!=", "EmptyStatement", ".", "INSTANCE", ")", "{", "if", "(", "defaultStatement", "==", "EmptyStatement", ".", "INSTANCE", ")", "{", "defaultStatement", "=", "tmpDefaultStatement", ";", "}", "else", "{", "throw", "new", "ASTRuntimeException", "(", "switchNode", ",", "\"\"", ")", ";", "}", "}", "}", "if", "(", "node", "!=", "null", ")", "{", "unknownAST", "(", "node", ")", ";", "}", "SwitchStatement", "switchStatement", "=", "new", "SwitchStatement", "(", "expression", ",", "list", ",", "defaultStatement", ")", ";", "configureAST", "(", "switchStatement", ",", "switchNode", ")", ";", "return", "switchStatement", ";", "}", "protected", "Statement", "caseStatements", "(", "AST", "node", ",", "List", "cases", ")", "{", "List", "<", "Expression", ">", "expressions", "=", "new", "LinkedList", "<", "Expression", ">", "(", ")", ";", "Statement", "statement", "=", "EmptyStatement", ".", "INSTANCE", ";", "Statement", "defaultStatement", "=", "EmptyStatement", ".", "INSTANCE", ";", "AST", "nextSibling", "=", "node", ";", "do", "{", "Expression", "expression", "=", "expression", "(", "nextSibling", ".", "getFirstChild", "(", ")", ")", ";", "expressions", ".", "add", "(", "expression", ")", ";", "nextSibling", "=", "nextSibling", ".", "getNextSibling", "(", ")", ";", "}", "while", "(", "isType", "(", "LITERAL_case", ",", "nextSibling", ")", ")", ";", "if", "(", "nextSibling", "!=", "null", ")", "{", "if", "(", "isType", "(", "LITERAL_default", ",", "nextSibling", ")", ")", "{", "defaultStatement", "=", "statement", "(", "nextSibling", ".", "getNextSibling", "(", ")", ")", ";", "statement", "=", "EmptyStatement", ".", "INSTANCE", ";", "}", "else", "{", "statement", "=", "statement", "(", "nextSibling", ")", ";", "}", "}", "for", "(", "Iterator", "iterator", "=", "expressions", ".", "iterator", "(", ")", ";", "iterator", ".", "hasNext", "(", ")", ";", ")", "{", "Expression", "expr", "=", "(", "Expression", ")", "iterator", ".", "next", "(", ")", ";", "Statement", "stmt", ";", "if", "(", "iterator", ".", "hasNext", "(", ")", ")", "{", "stmt", "=", "new", "CaseStatement", "(", "expr", ",", "EmptyStatement", ".", "INSTANCE", ")", ";", "}", "else", "{", "stmt", "=", "new", "CaseStatement", "(", "expr", ",", "statement", ")", ";", "}", "configureAST", "(", "stmt", ",", "node", ")", ";", "cases", ".", "add", "(", "stmt", ")", ";", "}", "return", "defaultStatement", ";", "}", "protected", "Statement", "synchronizedStatement", "(", "AST", "syncNode", ")", "{", "AST", "node", "=", "syncNode", ".", "getFirstChild", "(", ")", ";", "Expression", "expression", "=", "expression", "(", "node", ")", ";", "Statement", "code", "=", "statement", "(", "node", ".", "getNextSibling", "(", ")", ")", ";", "SynchronizedStatement", "synchronizedStatement", "=", "new", "SynchronizedStatement", "(", "expression", ",", "code", ")", ";", "configureAST", "(", "synchronizedStatement", ",", "syncNode", ")", ";", "return", "synchronizedStatement", ";", "}", "protected", "Statement", "throwStatement", "(", "AST", "node", ")", "{", "AST", "expressionNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "if", "(", "expressionNode", "==", "null", ")", "{", "expressionNode", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "if", "(", "expressionNode", "==", "null", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", ")", ";", "}", "ThrowStatement", "throwStatement", "=", "new", "ThrowStatement", "(", "expression", "(", "expressionNode", ")", ")", ";", "configureAST", "(", "throwStatement", ",", "node", ")", ";", "return", "throwStatement", ";", "}", "protected", "Statement", "tryStatement", "(", "AST", "tryStatementNode", ")", "{", "AST", "tryNode", "=", "tryStatementNode", ".", "getFirstChild", "(", ")", ";", "Statement", "tryStatement", "=", "statement", "(", "tryNode", ")", ";", "Statement", "finallyStatement", "=", "EmptyStatement", ".", "INSTANCE", ";", "AST", "node", "=", "tryNode", ".", "getNextSibling", "(", ")", ";", "List", "<", "CatchStatement", ">", "catches", "=", "new", "ArrayList", "<", "CatchStatement", ">", "(", ")", ";", "for", "(", ";", "node", "!=", "null", "&&", "isType", "(", "LITERAL_catch", ",", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "catches", ".", "add", "(", "catchStatement", "(", "node", ")", ")", ";", "}", "if", "(", "isType", "(", "LITERAL_finally", ",", "node", ")", ")", "{", "finallyStatement", "=", "statement", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "if", "(", "finallyStatement", "instanceof", "EmptyStatement", "&&", "catches", ".", "size", "(", ")", "==", "0", ")", "{", "throw", "new", "ASTRuntimeException", "(", "tryStatementNode", ",", "\"\"", ")", ";", "}", "TryCatchStatement", "tryCatchStatement", "=", "new", "TryCatchStatement", "(", "tryStatement", ",", "finallyStatement", ")", ";", "configureAST", "(", "tryCatchStatement", ",", "tryStatementNode", ")", ";", "for", "(", "CatchStatement", "statement", ":", "catches", ")", "{", "tryCatchStatement", ".", "addCatch", "(", "statement", ")", ";", "}", "return", "tryCatchStatement", ";", "}", "protected", "CatchStatement", "catchStatement", "(", "AST", "catchNode", ")", "{", "AST", "node", "=", "catchNode", ".", "getFirstChild", "(", ")", ";", "Parameter", "parameter", "=", "parameter", "(", "node", ")", ";", "ClassNode", "exceptionType", "=", "parameter", ".", "getType", "(", ")", ";", "String", "variable", "=", "parameter", ".", "getName", "(", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "Statement", "code", "=", "statement", "(", "node", ")", ";", "Parameter", "catchParameter", "=", "new", "Parameter", "(", "exceptionType", ",", "variable", ")", ";", "CatchStatement", "answer", "=", "new", "CatchStatement", "(", "catchParameter", ",", "code", ")", ";", "configureAST", "(", "answer", ",", "catchNode", ")", ";", "catchParameter", ".", "setSourcePosition", "(", "parameter", ")", ";", "return", "answer", ";", "}", "protected", "Statement", "whileStatement", "(", "AST", "whileNode", ")", "{", "AST", "node", "=", "whileNode", ".", "getFirstChild", "(", ")", ";", "assertNodeType", "(", "EXPR", ",", "node", ")", ";", "if", "(", "isType", "(", "VARIABLE_DEF", ",", "node", ".", "getFirstChild", "(", ")", ")", ")", "{", "throw", "new", "ASTRuntimeException", "(", "whileNode", ",", "\"\"", ")", ";", "}", "BooleanExpression", "booleanExpression", "=", "booleanExpression", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "Statement", "block", ";", "if", "(", "isType", "(", "SEMI", ",", "node", ")", ")", "{", "block", "=", "EmptyStatement", ".", "INSTANCE", ";", "}", "else", "{", "block", "=", "statement", "(", "node", ")", ";", "}", "WhileStatement", "whileStatement", "=", "new", "WhileStatement", "(", "booleanExpression", ",", "block", ")", ";", "configureAST", "(", "whileStatement", ",", "whileNode", ")", ";", "return", "whileStatement", ";", "}", "protected", "Expression", "expression", "(", "AST", "node", ")", "{", "return", "expression", "(", "node", ",", "false", ")", ";", "}", "protected", "Expression", "expression", "(", "AST", "node", ",", "boolean", "convertToConstant", ")", "{", "if", "(", "node", "==", "null", ")", "{", "return", "new", "ConstantExpression", "(", "\"ERROR\"", ")", ";", "}", "Expression", "expression", "=", "expressionSwitch", "(", "node", ")", ";", "if", "(", "convertToConstant", "&&", "expression", "instanceof", "VariableExpression", ")", "{", "VariableExpression", "ve", "=", "(", "VariableExpression", ")", "expression", ";", "if", "(", "!", "ve", ".", "isThisExpression", "(", ")", "&&", "!", "ve", ".", "isSuperExpression", "(", ")", ")", "{", "expression", "=", "new", "ConstantExpression", "(", "ve", ".", "getName", "(", ")", ")", ";", "}", "}", "configureAST", "(", "expression", ",", "node", ")", ";", "return", "expression", ";", "}", "protected", "Expression", "expressionSwitch", "(", "AST", "node", ")", "{", "int", "type", "=", "node", ".", "getType", "(", ")", ";", "switch", "(", "type", ")", "{", "case", "EXPR", ":", "Expression", "expression", "=", "expression", "(", "node", ".", "getFirstChild", "(", ")", ")", ";", "if", "(", "expression", "instanceof", "BinaryExpression", ")", "{", "configureAST", "(", "expression", ",", "node", ")", ";", "}", "return", "expression", ";", "case", "ELIST", ":", "return", "expressionList", "(", "node", ")", ";", "case", "SLIST", ":", "return", "blockExpression", "(", "node", ")", ";", "case", "CLOSABLE_BLOCK", ":", "return", "closureExpression", "(", "node", ")", ";", "case", "SUPER_CTOR_CALL", ":", "return", "specialConstructorCallExpression", "(", "node", ",", "ClassNode", ".", "SUPER", ")", ";", "case", "METHOD_CALL", ":", "return", "methodCallExpression", "(", "node", ")", ";", "case", "LITERAL_new", ":", "return", "constructorCallExpression", "(", "node", ")", ";", "case", "CTOR_CALL", ":", "return", "specialConstructorCallExpression", "(", "node", ",", "ClassNode", ".", "THIS", ")", ";", "case", "QUESTION", ":", "case", "ELVIS_OPERATOR", ":", "return", "ternaryExpression", "(", "node", ")", ";", "case", "OPTIONAL_DOT", ":", "case", "SPREAD_DOT", ":", "case", "DOT", ":", "return", "dotExpression", "(", "node", ")", ";", "case", "IDENT", ":", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_double", ":", "case", "LITERAL_float", ":", "case", "LITERAL_int", ":", "case", "LITERAL_long", ":", "case", "LITERAL_short", ":", "case", "LITERAL_void", ":", "case", "LITERAL_this", ":", "case", "LITERAL_super", ":", "return", "variableExpression", "(", "node", ")", ";", "case", "LIST_CONSTRUCTOR", ":", "return", "listExpression", "(", "node", ")", ";", "case", "MAP_CONSTRUCTOR", ":", "return", "mapExpression", "(", "node", ")", ";", "case", "LABELED_ARG", ":", "return", "mapEntryExpression", "(", "node", ")", ";", "case", "SPREAD_ARG", ":", "return", "spreadExpression", "(", "node", ")", ";", "case", "SPREAD_MAP_ARG", ":", "return", "spreadMapExpression", "(", "node", ")", ";", "case", "MEMBER_POINTER", ":", "return", "methodPointerExpression", "(", "node", ")", ";", "case", "INDEX_OP", ":", "return", "indexExpression", "(", "node", ")", ";", "case", "LITERAL_instanceof", ":", "return", "instanceofExpression", "(", "node", ")", ";", "case", "LITERAL_as", ":", "return", "asExpression", "(", "node", ")", ";", "case", "TYPECAST", ":", "return", "castExpression", "(", "node", ")", ";", "case", "LITERAL_true", ":", "return", "literalExpression", "(", "node", ",", "Boolean", ".", "TRUE", ")", ";", "case", "LITERAL_false", ":", "return", "literalExpression", "(", "node", ",", "Boolean", ".", "FALSE", ")", ";", "case", "LITERAL_null", ":", "return", "literalExpression", "(", "node", ",", "null", ")", ";", "case", "STRING_LITERAL", ":", "return", "literalExpression", "(", "node", ",", "node", ".", "getText", "(", ")", ")", ";", "case", "STRING_CONSTRUCTOR", ":", "return", "gstring", "(", "node", ")", ";", "case", "NUM_DOUBLE", ":", "case", "NUM_FLOAT", ":", "case", "NUM_BIG_DECIMAL", ":", "return", "decimalExpression", "(", "node", ")", ";", "case", "NUM_BIG_INT", ":", "case", "NUM_INT", ":", "case", "NUM_LONG", ":", "return", "integerExpression", "(", "node", ")", ";", "case", "LNOT", ":", "NotExpression", "notExpression", "=", "new", "NotExpression", "(", "expression", "(", "node", ".", "getFirstChild", "(", ")", ")", ")", ";", "configureAST", "(", "notExpression", ",", "node", ")", ";", "return", "notExpression", ";", "case", "UNARY_MINUS", ":", "return", "unaryMinusExpression", "(", "node", ")", ";", "case", "BNOT", ":", "BitwiseNegationExpression", "bitwiseNegationExpression", "=", "new", "BitwiseNegationExpression", "(", "expression", "(", "node", ".", "getFirstChild", "(", ")", ")", ")", ";", "configureAST", "(", "bitwiseNegationExpression", ",", "node", ")", ";", "return", "bitwiseNegationExpression", ";", "case", "UNARY_PLUS", ":", "return", "unaryPlusExpression", "(", "node", ")", ";", "case", "INC", ":", "return", "prefixExpression", "(", "node", ",", "Types", ".", "PLUS_PLUS", ")", ";", "case", "DEC", ":", "return", "prefixExpression", "(", "node", ",", "Types", ".", "MINUS_MINUS", ")", ";", "case", "POST_INC", ":", "return", "postfixExpression", "(", "node", ",", "Types", ".", "PLUS_PLUS", ")", ";", "case", "POST_DEC", ":", "return", "postfixExpression", "(", "node", ",", "Types", ".", "MINUS_MINUS", ")", ";", "case", "ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "ASSIGN", ",", "node", ")", ";", "case", "EQUAL", ":", "return", "binaryExpression", "(", "Types", ".", "COMPARE_EQUAL", ",", "node", ")", ";", "case", "IDENTICAL", ":", "return", "binaryExpression", "(", "Types", ".", "COMPARE_IDENTICAL", ",", "node", ")", ";", "case", "NOT_EQUAL", ":", "return", "binaryExpression", "(", "Types", ".", "COMPARE_NOT_EQUAL", ",", "node", ")", ";", "case", "NOT_IDENTICAL", ":", "return", "binaryExpression", "(", "Types", ".", "COMPARE_NOT_IDENTICAL", ",", "node", ")", ";", "case", "COMPARE_TO", ":", "return", "binaryExpression", "(", "Types", ".", "COMPARE_TO", ",", "node", ")", ";", "case", "LE", ":", "return", "binaryExpression", "(", "Types", ".", "COMPARE_LESS_THAN_EQUAL", ",", "node", ")", ";", "case", "LT", ":", "return", "binaryExpression", "(", "Types", ".", "COMPARE_LESS_THAN", ",", "node", ")", ";", "case", "GT", ":", "return", "binaryExpression", "(", "Types", ".", "COMPARE_GREATER_THAN", ",", "node", ")", ";", "case", "GE", ":", "return", "binaryExpression", "(", "Types", ".", "COMPARE_GREATER_THAN_EQUAL", ",", "node", ")", ";", "case", "LAND", ":", "return", "binaryExpression", "(", "Types", ".", "LOGICAL_AND", ",", "node", ")", ";", "case", "LOR", ":", "return", "binaryExpression", "(", "Types", ".", "LOGICAL_OR", ",", "node", ")", ";", "case", "BAND", ":", "return", "binaryExpression", "(", "Types", ".", "BITWISE_AND", ",", "node", ")", ";", "case", "BAND_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "BITWISE_AND_EQUAL", ",", "node", ")", ";", "case", "BOR", ":", "return", "binaryExpression", "(", "Types", ".", "BITWISE_OR", ",", "node", ")", ";", "case", "BOR_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "BITWISE_OR_EQUAL", ",", "node", ")", ";", "case", "BXOR", ":", "return", "binaryExpression", "(", "Types", ".", "BITWISE_XOR", ",", "node", ")", ";", "case", "BXOR_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "BITWISE_XOR_EQUAL", ",", "node", ")", ";", "case", "PLUS", ":", "return", "binaryExpression", "(", "Types", ".", "PLUS", ",", "node", ")", ";", "case", "PLUS_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "PLUS_EQUAL", ",", "node", ")", ";", "case", "MINUS", ":", "return", "binaryExpression", "(", "Types", ".", "MINUS", ",", "node", ")", ";", "case", "MINUS_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "MINUS_EQUAL", ",", "node", ")", ";", "case", "STAR", ":", "return", "binaryExpression", "(", "Types", ".", "MULTIPLY", ",", "node", ")", ";", "case", "STAR_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "MULTIPLY_EQUAL", ",", "node", ")", ";", "case", "STAR_STAR", ":", "return", "binaryExpression", "(", "Types", ".", "POWER", ",", "node", ")", ";", "case", "STAR_STAR_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "POWER_EQUAL", ",", "node", ")", ";", "case", "DIV", ":", "return", "binaryExpression", "(", "Types", ".", "DIVIDE", ",", "node", ")", ";", "case", "DIV_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "DIVIDE_EQUAL", ",", "node", ")", ";", "case", "MOD", ":", "return", "binaryExpression", "(", "Types", ".", "MOD", ",", "node", ")", ";", "case", "MOD_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "MOD_EQUAL", ",", "node", ")", ";", "case", "SL", ":", "return", "binaryExpression", "(", "Types", ".", "LEFT_SHIFT", ",", "node", ")", ";", "case", "SL_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "LEFT_SHIFT_EQUAL", ",", "node", ")", ";", "case", "SR", ":", "return", "binaryExpression", "(", "Types", ".", "RIGHT_SHIFT", ",", "node", ")", ";", "case", "SR_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "RIGHT_SHIFT_EQUAL", ",", "node", ")", ";", "case", "BSR", ":", "return", "binaryExpression", "(", "Types", ".", "RIGHT_SHIFT_UNSIGNED", ",", "node", ")", ";", "case", "BSR_ASSIGN", ":", "return", "binaryExpression", "(", "Types", ".", "RIGHT_SHIFT_UNSIGNED_EQUAL", ",", "node", ")", ";", "case", "VARIABLE_DEF", ":", "return", "declarationExpression", "(", "node", ")", ";", "case", "REGEX_FIND", ":", "return", "binaryExpression", "(", "Types", ".", "FIND_REGEX", ",", "node", ")", ";", "case", "REGEX_MATCH", ":", "return", "binaryExpression", "(", "Types", ".", "MATCH_REGEX", ",", "node", ")", ";", "case", "RANGE_INCLUSIVE", ":", "return", "rangeExpression", "(", "node", ",", "true", ")", ";", "case", "RANGE_EXCLUSIVE", ":", "return", "rangeExpression", "(", "node", ",", "false", ")", ";", "case", "DYNAMIC_MEMBER", ":", "return", "dynamicMemberExpression", "(", "node", ")", ";", "case", "LITERAL_in", ":", "return", "binaryExpression", "(", "Types", ".", "KEYWORD_IN", ",", "node", ")", ";", "case", "ANNOTATION", ":", "return", "new", "AnnotationConstantExpression", "(", "annotation", "(", "node", ")", ")", ";", "case", "CLOSURE_LIST", ":", "return", "closureListExpression", "(", "node", ")", ";", "case", "LBRACK", ":", "case", "LPAREN", ":", "return", "tupleExpression", "(", "node", ")", ";", "case", "OBJBLOCK", ":", "return", "anonymousInnerClassDef", "(", "node", ")", ";", "default", ":", "return", "unknownAST", "(", "node", ")", ";", "}", "}", "private", "TupleExpression", "tupleExpression", "(", "AST", "node", ")", "{", "TupleExpression", "exp", "=", "new", "TupleExpression", "(", ")", ";", "configureAST", "(", "exp", ",", "node", ")", ";", "node", "=", "node", ".", "getFirstChild", "(", ")", ";", "while", "(", "node", "!=", "null", ")", "{", "assertNodeType", "(", "VARIABLE_DEF", ",", "node", ")", ";", "AST", "nameNode", "=", "node", ".", "getFirstChild", "(", ")", ".", "getNextSibling", "(", ")", ";", "VariableExpression", "varExp", "=", "new", "VariableExpression", "(", "nameNode", ".", "getText", "(", ")", ")", ";", "configureAST", "(", "varExp", ",", "nameNode", ")", ";", "exp", ".", "addExpression", "(", "varExp", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "}", "return", "exp", ";", "}", "private", "ClosureListExpression", "closureListExpression", "(", "AST", "node", ")", "{", "isClosureListExpressionAllowedHere", "(", "node", ")", ";", "AST", "exprNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "List", "<", "Expression", ">", "list", "=", "new", "LinkedList", "<", "Expression", ">", "(", ")", ";", "while", "(", "exprNode", "!=", "null", ")", "{", "if", "(", "isType", "(", "EXPR", ",", "exprNode", ")", ")", "{", "Expression", "expr", "=", "expression", "(", "exprNode", ")", ";", "configureAST", "(", "expr", ",", "exprNode", ")", ";", "list", ".", "add", "(", "expr", ")", ";", "}", "else", "{", "assertNodeType", "(", "EMPTY_STAT", ",", "exprNode", ")", ";", "list", ".", "add", "(", "EmptyExpression", ".", "INSTANCE", ")", ";", "}", "exprNode", "=", "exprNode", ".", "getNextSibling", "(", ")", ";", "}", "ClosureListExpression", "cle", "=", "new", "ClosureListExpression", "(", "list", ")", ";", "configureAST", "(", "cle", ",", "node", ")", ";", "return", "cle", ";", "}", "private", "void", "isClosureListExpressionAllowedHere", "(", "AST", "node", ")", "{", "if", "(", "!", "forStatementBeingDef", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", ")", ";", "}", "}", "protected", "Expression", "dynamicMemberExpression", "(", "AST", "dynamicMemberNode", ")", "{", "AST", "node", "=", "dynamicMemberNode", ".", "getFirstChild", "(", ")", ";", "return", "expression", "(", "node", ")", ";", "}", "protected", "Expression", "ternaryExpression", "(", "AST", "ternaryNode", ")", "{", "AST", "node", "=", "ternaryNode", ".", "getFirstChild", "(", ")", ";", "Expression", "base", "=", "expression", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "Expression", "left", "=", "expression", "(", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "Expression", "ret", ";", "if", "(", "node", "==", "null", ")", "{", "ret", "=", "new", "ElvisOperatorExpression", "(", "base", ",", "left", ")", ";", "}", "else", "{", "Expression", "right", "=", "expression", "(", "node", ")", ";", "BooleanExpression", "booleanExpression", "=", "new", "BooleanExpression", "(", "base", ")", ";", "booleanExpression", ".", "setSourcePosition", "(", "base", ")", ";", "ret", "=", "new", "TernaryExpression", "(", "booleanExpression", ",", "left", ",", "right", ")", ";", "}", "configureAST", "(", "ret", ",", "ternaryNode", ")", ";", "return", "ret", ";", "}", "protected", "Expression", "variableExpression", "(", "AST", "node", ")", "{", "String", "text", "=", "node", ".", "getText", "(", ")", ";", "VariableExpression", "variableExpression", "=", "new", "VariableExpression", "(", "text", ")", ";", "configureAST", "(", "variableExpression", ",", "node", ")", ";", "return", "variableExpression", ";", "}", "protected", "Expression", "literalExpression", "(", "AST", "node", ",", "Object", "value", ")", "{", "ConstantExpression", "constantExpression", "=", "new", "ConstantExpression", "(", "value", ")", ";", "configureAST", "(", "constantExpression", ",", "node", ")", ";", "return", "constantExpression", ";", "}", "protected", "Expression", "rangeExpression", "(", "AST", "rangeNode", ",", "boolean", "inclusive", ")", "{", "AST", "node", "=", "rangeNode", ".", "getFirstChild", "(", ")", ";", "Expression", "left", "=", "expression", "(", "node", ")", ";", "Expression", "right", "=", "expression", "(", "node", ".", "getNextSibling", "(", ")", ")", ";", "RangeExpression", "rangeExpression", "=", "new", "RangeExpression", "(", "left", ",", "right", ",", "inclusive", ")", ";", "configureAST", "(", "rangeExpression", ",", "rangeNode", ")", ";", "return", "rangeExpression", ";", "}", "protected", "Expression", "spreadExpression", "(", "AST", "node", ")", "{", "AST", "exprNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "AST", "listNode", "=", "exprNode", ".", "getFirstChild", "(", ")", ";", "Expression", "right", "=", "expression", "(", "listNode", ")", ";", "SpreadExpression", "spreadExpression", "=", "new", "SpreadExpression", "(", "right", ")", ";", "configureAST", "(", "spreadExpression", ",", "node", ")", ";", "return", "spreadExpression", ";", "}", "protected", "Expression", "spreadMapExpression", "(", "AST", "node", ")", "{", "AST", "exprNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Expression", "expr", "=", "expression", "(", "exprNode", ")", ";", "SpreadMapExpression", "spreadMapExpression", "=", "new", "SpreadMapExpression", "(", "expr", ")", ";", "configureAST", "(", "spreadMapExpression", ",", "node", ")", ";", "return", "spreadMapExpression", ";", "}", "protected", "Expression", "methodPointerExpression", "(", "AST", "node", ")", "{", "AST", "exprNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Expression", "objectExpression", "=", "expression", "(", "exprNode", ")", ";", "AST", "mNode", "=", "exprNode", ".", "getNextSibling", "(", ")", ";", "Expression", "methodName", ";", "if", "(", "isType", "(", "DYNAMIC_MEMBER", ",", "mNode", ")", ")", "{", "methodName", "=", "expression", "(", "mNode", ")", ";", "}", "else", "{", "methodName", "=", "new", "ConstantExpression", "(", "identifier", "(", "mNode", ")", ")", ";", "}", "configureAST", "(", "methodName", ",", "mNode", ")", ";", "MethodPointerExpression", "methodPointerExpression", "=", "new", "MethodPointerExpression", "(", "objectExpression", ",", "methodName", ")", ";", "configureAST", "(", "methodPointerExpression", ",", "node", ")", ";", "return", "methodPointerExpression", ";", "}", "protected", "Expression", "listExpression", "(", "AST", "listNode", ")", "{", "List", "<", "Expression", ">", "expressions", "=", "new", "ArrayList", "<", "Expression", ">", "(", ")", ";", "AST", "elist", "=", "listNode", ".", "getFirstChild", "(", ")", ";", "assertNodeType", "(", "ELIST", ",", "elist", ")", ";", "for", "(", "AST", "node", "=", "elist", ".", "getFirstChild", "(", ")", ";", "node", "!=", "null", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "switch", "(", "node", ".", "getType", "(", ")", ")", "{", "case", "LABELED_ARG", ":", "assertNodeType", "(", "COMMA", ",", "node", ")", ";", "break", ";", "case", "SPREAD_MAP_ARG", ":", "assertNodeType", "(", "SPREAD_ARG", ",", "node", ")", ";", "break", ";", "}", "expressions", ".", "add", "(", "expression", "(", "node", ")", ")", ";", "}", "ListExpression", "listExpression", "=", "new", "ListExpression", "(", "expressions", ")", ";", "configureAST", "(", "listExpression", ",", "listNode", ")", ";", "return", "listExpression", ";", "}", "protected", "Expression", "mapExpression", "(", "AST", "mapNode", ")", "{", "List", "expressions", "=", "new", "ArrayList", "(", ")", ";", "AST", "elist", "=", "mapNode", ".", "getFirstChild", "(", ")", ";", "if", "(", "elist", "!=", "null", ")", "{", "assertNodeType", "(", "ELIST", ",", "elist", ")", ";", "for", "(", "AST", "node", "=", "elist", ".", "getFirstChild", "(", ")", ";", "node", "!=", "null", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "switch", "(", "node", ".", "getType", "(", ")", ")", "{", "case", "LABELED_ARG", ":", "case", "SPREAD_MAP_ARG", ":", "break", ";", "case", "SPREAD_ARG", ":", "assertNodeType", "(", "SPREAD_MAP_ARG", ",", "node", ")", ";", "break", ";", "default", ":", "assertNodeType", "(", "LABELED_ARG", ",", "node", ")", ";", "break", ";", "}", "expressions", ".", "add", "(", "mapEntryExpression", "(", "node", ")", ")", ";", "}", "}", "MapExpression", "mapExpression", "=", "new", "MapExpression", "(", "expressions", ")", ";", "configureAST", "(", "mapExpression", ",", "mapNode", ")", ";", "if", "(", "expressions", ".", "size", "(", ")", "==", "0", "&&", "mapExpression", ".", "getLength", "(", ")", "<=", "1", ")", "{", "mapExpression", ".", "setEnd", "(", "mapExpression", ".", "getStart", "(", ")", "+", "3", ")", ";", "mapExpression", ".", "setLastColumnNumber", "(", "mapExpression", ".", "getColumnNumber", "(", ")", "+", "3", ")", ";", "}", "return", "mapExpression", ";", "}", "protected", "MapEntryExpression", "mapEntryExpression", "(", "AST", "node", ")", "{", "if", "(", "node", ".", "getType", "(", ")", "==", "SPREAD_MAP_ARG", ")", "{", "AST", "rightNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Expression", "keyExpression", "=", "spreadMapExpression", "(", "node", ")", ";", "Expression", "rightExpression", "=", "expression", "(", "rightNode", ")", ";", "MapEntryExpression", "mapEntryExpression", "=", "new", "MapEntryExpression", "(", "keyExpression", ",", "rightExpression", ")", ";", "configureAST", "(", "mapEntryExpression", ",", "node", ")", ";", "return", "mapEntryExpression", ";", "}", "else", "{", "AST", "keyNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Expression", "keyExpression", "=", "expression", "(", "keyNode", ")", ";", "AST", "valueNode", "=", "keyNode", ".", "getNextSibling", "(", ")", ";", "Expression", "valueExpression", "=", "expression", "(", "valueNode", ")", ";", "MapEntryExpression", "mapEntryExpression", "=", "new", "MapEntryExpression", "(", "keyExpression", ",", "valueExpression", ")", ";", "mapEntryExpression", ".", "setStart", "(", "keyExpression", ".", "getStart", "(", ")", ")", ";", "mapEntryExpression", ".", "setLineNumber", "(", "keyExpression", ".", "getLineNumber", "(", ")", ")", ";", "mapEntryExpression", ".", "setColumnNumber", "(", "keyExpression", ".", "getColumnNumber", "(", ")", ")", ";", "mapEntryExpression", ".", "setEnd", "(", "valueExpression", ".", "getEnd", "(", ")", ")", ";", "mapEntryExpression", ".", "setLastLineNumber", "(", "valueExpression", ".", "getLastLineNumber", "(", ")", ")", ";", "mapEntryExpression", ".", "setLastColumnNumber", "(", "valueExpression", ".", "getLastColumnNumber", "(", ")", ")", ";", "configureAST", "(", "mapEntryExpression", ",", "node", ")", ";", "return", "mapEntryExpression", ";", "}", "}", "protected", "Expression", "instanceofExpression", "(", "AST", "node", ")", "{", "AST", "leftNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Expression", "leftExpression", "=", "expression", "(", "leftNode", ")", ";", "AST", "rightNode", "=", "leftNode", ".", "getNextSibling", "(", ")", ";", "ClassNode", "type", "=", "buildName", "(", "rightNode", ")", ";", "assertTypeNotNull", "(", "type", ",", "rightNode", ")", ";", "Expression", "rightExpression", "=", "new", "ClassExpression", "(", "type", ")", ";", "configureAST", "(", "rightExpression", ",", "rightNode", ")", ";", "BinaryExpression", "binaryExpression", "=", "new", "BinaryExpression", "(", "leftExpression", ",", "makeToken", "(", "Types", ".", "KEYWORD_INSTANCEOF", ",", "node", ")", ",", "rightExpression", ")", ";", "configureAST", "(", "binaryExpression", ",", "node", ")", ";", "return", "binaryExpression", ";", "}", "protected", "void", "assertTypeNotNull", "(", "ClassNode", "type", ",", "AST", "rightNode", ")", "{", "if", "(", "type", "==", "null", ")", "{", "throw", "new", "ASTRuntimeException", "(", "rightNode", ",", "\"\"", "+", "qualifiedName", "(", "rightNode", ")", ")", ";", "}", "}", "protected", "Expression", "asExpression", "(", "AST", "node", ")", "{", "AST", "leftNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Expression", "leftExpression", "=", "expression", "(", "leftNode", ")", ";", "AST", "rightNode", "=", "leftNode", ".", "getNextSibling", "(", ")", ";", "ClassNode", "type", "=", "makeTypeWithArguments", "(", "rightNode", ")", ";", "CastExpression", "asExpr", "=", "CastExpression", ".", "asExpression", "(", "type", ",", "leftExpression", ")", ";", "asExpr", ".", "setStart", "(", "leftExpression", ".", "getStart", "(", ")", ")", ";", "asExpr", ".", "setLineNumber", "(", "leftExpression", ".", "getLineNumber", "(", ")", ")", ";", "asExpr", ".", "setColumnNumber", "(", "leftExpression", ".", "getColumnNumber", "(", ")", ")", ";", "asExpr", ".", "setEnd", "(", "type", ".", "getEnd", "(", ")", ")", ";", "asExpr", ".", "setLastLineNumber", "(", "type", ".", "getLastLineNumber", "(", ")", ")", ";", "asExpr", ".", "setLastColumnNumber", "(", "type", ".", "getLastColumnNumber", "(", ")", ")", ";", "return", "asExpr", ";", "}", "protected", "Expression", "castExpression", "(", "AST", "castNode", ")", "{", "AST", "node", "=", "castNode", ".", "getFirstChild", "(", ")", ";", "ClassNode", "type", "=", "makeTypeWithArguments", "(", "node", ")", ";", "assertTypeNotNull", "(", "type", ",", "node", ")", ";", "AST", "expressionNode", "=", "node", ".", "getNextSibling", "(", ")", ";", "Expression", "expression", "=", "expression", "(", "expressionNode", ")", ";", "CastExpression", "castExpression", "=", "new", "CastExpression", "(", "type", ",", "expression", ")", ";", "configureAST", "(", "castExpression", ",", "castNode", ")", ";", "return", "castExpression", ";", "}", "protected", "Expression", "indexExpression", "(", "AST", "indexNode", ")", "{", "AST", "bracket", "=", "indexNode", ".", "getFirstChild", "(", ")", ";", "AST", "leftNode", "=", "bracket", ".", "getNextSibling", "(", ")", ";", "Expression", "leftExpression", "=", "expression", "(", "leftNode", ")", ";", "AST", "rightNode", "=", "leftNode", ".", "getNextSibling", "(", ")", ";", "Expression", "rightExpression", "=", "expression", "(", "rightNode", ")", ";", "BinaryExpression", "binaryExpression", "=", "new", "BinaryExpression", "(", "leftExpression", ",", "makeToken", "(", "Types", ".", "LEFT_SQUARE_BRACKET", ",", "bracket", ")", ",", "rightExpression", ")", ";", "configureAST", "(", "binaryExpression", ",", "indexNode", ")", ";", "return", "binaryExpression", ";", "}", "protected", "Expression", "binaryExpression", "(", "int", "type", ",", "AST", "node", ")", "{", "Token", "token", "=", "makeToken", "(", "type", ",", "node", ")", ";", "AST", "leftNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Expression", "leftExpression", "=", "expression", "(", "leftNode", ")", ";", "AST", "rightNode", "=", "leftNode", ".", "getNextSibling", "(", ")", ";", "if", "(", "rightNode", "==", "null", ")", "{", "return", "leftExpression", ";", "}", "if", "(", "Types", ".", "ofType", "(", "type", ",", "Types", ".", "ASSIGNMENT_OPERATOR", ")", ")", "{", "if", "(", "leftExpression", "instanceof", "VariableExpression", "||", "leftExpression", ".", "getClass", "(", ")", "==", "PropertyExpression", ".", "class", "||", "leftExpression", "instanceof", "FieldExpression", "||", "leftExpression", "instanceof", "AttributeExpression", "||", "leftExpression", "instanceof", "DeclarationExpression", "||", "leftExpression", "instanceof", "TupleExpression", ")", "{", "}", "else", "if", "(", "leftExpression", "instanceof", "ConstantExpression", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"n[\"", "+", "(", "(", "ConstantExpression", ")", "leftExpression", ")", ".", "getValue", "(", ")", "+", "\"\"", ")", ";", "}", "else", "if", "(", "leftExpression", "instanceof", "BinaryExpression", ")", "{", "Expression", "leftexp", "=", "(", "(", "BinaryExpression", ")", "leftExpression", ")", ".", "getLeftExpression", "(", ")", ";", "int", "lefttype", "=", "(", "(", "BinaryExpression", ")", "leftExpression", ")", ".", "getOperation", "(", ")", ".", "getType", "(", ")", ";", "if", "(", "!", "Types", ".", "ofType", "(", "lefttype", ",", "Types", ".", "ASSIGNMENT_OPERATOR", ")", "&&", "lefttype", "!=", "Types", ".", "LEFT_SQUARE_BRACKET", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"n\"", "+", "(", "(", "BinaryExpression", ")", "leftExpression", ")", ".", "getText", "(", ")", "+", "\"\"", ")", ";", "}", "}", "else", "if", "(", "leftExpression", "instanceof", "GStringExpression", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"n\\\"\"", "+", "(", "(", "GStringExpression", ")", "leftExpression", ")", ".", "getText", "(", ")", "+", "\"\"", ")", ";", "}", "else", "if", "(", "leftExpression", "instanceof", "MethodCallExpression", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"n\\\"\"", "+", "(", "(", "MethodCallExpression", ")", "leftExpression", ")", ".", "getText", "(", ")", "+", "\"\"", ")", ";", "}", "else", "if", "(", "leftExpression", "instanceof", "MapExpression", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"n'\"", "+", "(", "(", "MapExpression", ")", "leftExpression", ")", ".", "getText", "(", ")", "+", "\"\"", ")", ";", "}", "else", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"n\"", "+", "leftExpression", ".", "getClass", "(", ")", "+", "\"\"", "+", "leftExpression", ".", "getText", "(", ")", "+", "\"\"", ")", ";", "}", "}", "Expression", "rightExpression", "=", "expression", "(", "rightNode", ")", ";", "BinaryExpression", "binaryExpression", "=", "new", "BinaryExpression", "(", "leftExpression", ",", "token", ",", "rightExpression", ")", ";", "binaryExpression", ".", "setStart", "(", "leftExpression", ".", "getStart", "(", ")", ")", ";", "binaryExpression", ".", "setLineNumber", "(", "leftExpression", ".", "getLineNumber", "(", ")", ")", ";", "binaryExpression", ".", "setColumnNumber", "(", "leftExpression", ".", "getColumnNumber", "(", ")", ")", ";", "binaryExpression", ".", "setEnd", "(", "rightExpression", ".", "getEnd", "(", ")", ")", ";", "binaryExpression", ".", "setLastLineNumber", "(", "rightExpression", ".", "getLastLineNumber", "(", ")", ")", ";", "binaryExpression", ".", "setLastColumnNumber", "(", "rightExpression", ".", "getLastColumnNumber", "(", ")", ")", ";", "return", "binaryExpression", ";", "}", "protected", "Expression", "prefixExpression", "(", "AST", "node", ",", "int", "token", ")", "{", "Expression", "expression", "=", "expression", "(", "node", ".", "getFirstChild", "(", ")", ")", ";", "PrefixExpression", "prefixExpression", "=", "new", "PrefixExpression", "(", "makeToken", "(", "token", ",", "node", ")", ",", "expression", ")", ";", "configureAST", "(", "prefixExpression", ",", "node", ")", ";", "return", "prefixExpression", ";", "}", "protected", "Expression", "postfixExpression", "(", "AST", "node", ",", "int", "token", ")", "{", "Expression", "expression", "=", "expression", "(", "node", ".", "getFirstChild", "(", ")", ")", ";", "PostfixExpression", "postfixExpression", "=", "new", "PostfixExpression", "(", "expression", ",", "makeToken", "(", "token", ",", "node", ")", ")", ";", "configureAST", "(", "postfixExpression", ",", "node", ")", ";", "return", "postfixExpression", ";", "}", "protected", "BooleanExpression", "booleanExpression", "(", "AST", "node", ")", "{", "BooleanExpression", "booleanExpression", "=", "new", "BooleanExpression", "(", "expression", "(", "node", ")", ")", ";", "configureAST", "(", "booleanExpression", ",", "node", ")", ";", "return", "booleanExpression", ";", "}", "protected", "Expression", "dotExpression", "(", "AST", "node", ")", "{", "AST", "leftNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "if", "(", "leftNode", "!=", "null", ")", "{", "AST", "identifierNode", "=", "leftNode", ".", "getNextSibling", "(", ")", ";", "if", "(", "identifierNode", "!=", "null", ")", "{", "Expression", "leftExpression", "=", "expression", "(", "leftNode", ")", ";", "if", "(", "isType", "(", "SELECT_SLOT", ",", "identifierNode", ")", ")", "{", "Expression", "field", "=", "expression", "(", "identifierNode", ".", "getFirstChild", "(", ")", ",", "true", ")", ";", "AttributeExpression", "attributeExpression", "=", "new", "AttributeExpression", "(", "leftExpression", ",", "field", ",", "node", ".", "getType", "(", ")", "!=", "DOT", ")", ";", "if", "(", "node", ".", "getType", "(", ")", "==", "SPREAD_DOT", ")", "{", "attributeExpression", ".", "setSpreadSafe", "(", "true", ")", ";", "}", "configureAST", "(", "attributeExpression", ",", "node", ")", ";", "return", "attributeExpression", ";", "}", "if", "(", "isType", "(", "SLIST", ",", "identifierNode", ")", ")", "{", "Statement", "code", "=", "statementList", "(", "identifierNode", ")", ";", "ClosureExpression", "closureExpression", "=", "new", "ClosureExpression", "(", "Parameter", ".", "EMPTY_ARRAY", ",", "code", ")", ";", "configureAST", "(", "closureExpression", ",", "identifierNode", ")", ";", "final", "PropertyExpression", "propertyExpression", "=", "new", "PropertyExpression", "(", "leftExpression", ",", "closureExpression", ")", ";", "if", "(", "node", ".", "getType", "(", ")", "==", "SPREAD_DOT", ")", "{", "propertyExpression", ".", "setSpreadSafe", "(", "true", ")", ";", "}", "configureAST", "(", "propertyExpression", ",", "node", ")", ";", "return", "propertyExpression", ";", "}", "Expression", "property", "=", "expression", "(", "identifierNode", ",", "true", ")", ";", "if", "(", "property", "instanceof", "VariableExpression", ")", "{", "VariableExpression", "ve", "=", "(", "VariableExpression", ")", "property", ";", "property", "=", "new", "ConstantExpression", "(", "ve", ".", "getName", "(", ")", ")", ";", "}", "PropertyExpression", "propertyExpression", "=", "new", "PropertyExpression", "(", "leftExpression", ",", "property", ",", "node", ".", "getType", "(", ")", "!=", "DOT", ")", ";", "if", "(", "node", ".", "getType", "(", ")", "==", "SPREAD_DOT", ")", "{", "propertyExpression", ".", "setSpreadSafe", "(", "true", ")", ";", "}", "configureAST", "(", "propertyExpression", ",", "node", ")", ";", "return", "propertyExpression", ";", "}", "}", "return", "methodCallExpression", "(", "node", ")", ";", "}", "protected", "Expression", "specialConstructorCallExpression", "(", "AST", "methodCallNode", ",", "ClassNode", "special", ")", "{", "AST", "node", "=", "methodCallNode", ".", "getFirstChild", "(", ")", ";", "Expression", "arguments", "=", "arguments", "(", "node", ")", ";", "ConstructorCallExpression", "expression", "=", "new", "ConstructorCallExpression", "(", "special", ",", "arguments", ")", ";", "configureAST", "(", "expression", ",", "methodCallNode", ")", ";", "return", "expression", ";", "}", "private", "int", "getTypeInParenthesis", "(", "AST", "node", ")", "{", "if", "(", "!", "isType", "(", "EXPR", ",", "node", ")", ")", "node", "=", "node", ".", "getFirstChild", "(", ")", ";", "while", "(", "node", "!=", "null", "&&", "isType", "(", "EXPR", ",", "node", ")", "&&", "node", ".", "getNextSibling", "(", ")", "==", "null", ")", "{", "node", "=", "node", ".", "getFirstChild", "(", ")", ";", "}", "if", "(", "node", "==", "null", ")", "return", "-", "1", ";", "return", "node", ".", "getType", "(", ")", ";", "}", "protected", "Expression", "methodCallExpression", "(", "AST", "methodCallNode", ")", "{", "AST", "node", "=", "methodCallNode", ".", "getFirstChild", "(", ")", ";", "Expression", "objectExpression", ";", "AST", "selector", ";", "AST", "elist", "=", "node", ".", "getNextSibling", "(", ")", ";", "List", "<", "GenericsType", ">", "typeArgumentList", "=", "null", ";", "boolean", "implicitThis", "=", "false", ";", "boolean", "safe", "=", "isType", "(", "OPTIONAL_DOT", ",", "node", ")", ";", "boolean", "spreadSafe", "=", "isType", "(", "SPREAD_DOT", ",", "node", ")", ";", "if", "(", "isType", "(", "DOT", ",", "node", ")", "||", "safe", "||", "spreadSafe", ")", "{", "AST", "objectNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "objectExpression", "=", "expression", "(", "objectNode", ")", ";", "selector", "=", "objectNode", ".", "getNextSibling", "(", ")", ";", "}", "else", "{", "implicitThis", "=", "true", ";", "objectExpression", "=", "VariableExpression", ".", "THIS_EXPRESSION", ";", "selector", "=", "node", ";", "}", "if", "(", "isType", "(", "TYPE_ARGUMENTS", ",", "selector", ")", ")", "{", "typeArgumentList", "=", "getTypeArgumentsList", "(", "selector", ")", ";", "selector", "=", "selector", ".", "getNextSibling", "(", ")", ";", "}", "Expression", "name", "=", "null", ";", "if", "(", "isType", "(", "LITERAL_super", ",", "selector", ")", ")", "{", "implicitThis", "=", "true", ";", "name", "=", "new", "ConstantExpression", "(", "\"super\"", ")", ";", "if", "(", "objectExpression", "instanceof", "VariableExpression", "&&", "(", "(", "VariableExpression", ")", "objectExpression", ")", ".", "isThisExpression", "(", ")", ")", "{", "objectExpression", "=", "VariableExpression", ".", "SUPER_EXPRESSION", ";", "}", "}", "else", "if", "(", "isPrimitiveTypeLiteral", "(", "selector", ")", ")", "{", "throw", "new", "ASTRuntimeException", "(", "selector", ",", "\"\"", "+", "selector", ".", "getText", "(", ")", "+", "\"\"", ")", ";", "}", "else", "if", "(", "isType", "(", "SELECT_SLOT", ",", "selector", ")", ")", "{", "Expression", "field", "=", "expression", "(", "selector", ".", "getFirstChild", "(", ")", ",", "true", ")", ";", "AttributeExpression", "attributeExpression", "=", "new", "AttributeExpression", "(", "objectExpression", ",", "field", ",", "node", ".", "getType", "(", ")", "!=", "DOT", ")", ";", "configureAST", "(", "attributeExpression", ",", "node", ")", ";", "Expression", "arguments", "=", "arguments", "(", "elist", ")", ";", "MethodCallExpression", "expression", "=", "new", "MethodCallExpression", "(", "attributeExpression", ",", "\"call\"", ",", "arguments", ")", ";", "setTypeArgumentsOnMethodCallExpression", "(", "expression", ",", "typeArgumentList", ")", ";", "configureAST", "(", "expression", ",", "methodCallNode", ")", ";", "return", "expression", ";", "}", "else", "if", "(", "isType", "(", "DYNAMIC_MEMBER", ",", "selector", ")", "||", "isType", "(", "IDENT", ",", "selector", ")", "||", "isType", "(", "STRING_CONSTRUCTOR", ",", "selector", ")", "||", "isType", "(", "STRING_LITERAL", ",", "selector", ")", ")", "{", "name", "=", "expression", "(", "selector", ",", "true", ")", ";", "}", "else", "{", "implicitThis", "=", "false", ";", "name", "=", "new", "ConstantExpression", "(", "\"call\"", ")", ";", "objectExpression", "=", "expression", "(", "selector", ",", "true", ")", ";", "}", "if", "(", "selector", ".", "getText", "(", ")", ".", "equals", "(", "\"this\"", ")", "||", "selector", ".", "getText", "(", ")", ".", "equals", "(", "\"super\"", ")", ")", "{", "throw", "new", "ASTRuntimeException", "(", "elist", ",", "\"\"", ")", ";", "}", "Expression", "arguments", "=", "arguments", "(", "elist", ")", ";", "MethodCallExpression", "expression", "=", "new", "MethodCallExpression", "(", "objectExpression", ",", "name", ",", "arguments", ")", ";", "expression", ".", "setSafe", "(", "safe", ")", ";", "expression", ".", "setSpreadSafe", "(", "spreadSafe", ")", ";", "expression", ".", "setImplicitThis", "(", "implicitThis", ")", ";", "setTypeArgumentsOnMethodCallExpression", "(", "expression", ",", "typeArgumentList", ")", ";", "Expression", "ret", "=", "expression", ";", "if", "(", "implicitThis", "&&", "\"this\"", ".", "equals", "(", "expression", ".", "getMethodAsString", "(", ")", ")", ")", "{", "ret", "=", "new", "ConstructorCallExpression", "(", "this", ".", "classNode", ",", "arguments", ")", ";", "}", "configureAST", "(", "ret", ",", "methodCallNode", ")", ";", "return", "ret", ";", "}", "private", "void", "setTypeArgumentsOnMethodCallExpression", "(", "MethodCallExpression", "expression", ",", "List", "<", "GenericsType", ">", "typeArgumentList", ")", "{", "if", "(", "typeArgumentList", "!=", "null", "&&", "typeArgumentList", ".", "size", "(", ")", ">", "0", ")", "{", "expression", ".", "setGenericsTypes", "(", "typeArgumentList", ".", "toArray", "(", "new", "GenericsType", "[", "typeArgumentList", ".", "size", "(", ")", "]", ")", ")", ";", "}", "}", "protected", "Expression", "constructorCallExpression", "(", "AST", "node", ")", "{", "AST", "constructorCallNode", "=", "node", ";", "ClassNode", "type", "=", "makeTypeWithArguments", "(", "constructorCallNode", ")", ";", "if", "(", "isType", "(", "CTOR_CALL", ",", "node", ")", "||", "isType", "(", "LITERAL_new", ",", "node", ")", ")", "{", "node", "=", "node", ".", "getFirstChild", "(", ")", ";", "}", "if", "(", "node", "==", "null", ")", "{", "return", "new", "ConstructorCallExpression", "(", "ClassHelper", ".", "OBJECT_TYPE", ",", "new", "ArgumentListExpression", "(", ")", ")", ";", "}", "AST", "elist", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "elist", "==", "null", "&&", "isType", "(", "ELIST", ",", "node", ")", ")", "{", "elist", "=", "node", ";", "if", "(", "\"(\"", ".", "equals", "(", "type", ".", "getName", "(", ")", ")", ")", "{", "type", "=", "classNode", ";", "}", "}", "if", "(", "isType", "(", "ARRAY_DECLARATOR", ",", "elist", ")", ")", "{", "AST", "expressionNode", "=", "elist", ".", "getFirstChild", "(", ")", ";", "if", "(", "expressionNode", "==", "null", ")", "{", "throw", "new", "ASTRuntimeException", "(", "elist", ",", "\"\"", ")", ";", "}", "List", "size", "=", "arraySizeExpression", "(", "expressionNode", ")", ";", "ArrayExpression", "arrayExpression", "=", "new", "ArrayExpression", "(", "type", ",", "null", ",", "size", ")", ";", "configureAST", "(", "arrayExpression", ",", "constructorCallNode", ")", ";", "return", "arrayExpression", ";", "}", "Expression", "arguments", "=", "arguments", "(", "elist", ")", ";", "ClassNode", "innerClass", "=", "getAnonymousInnerClassNode", "(", "arguments", ")", ";", "ConstructorCallExpression", "ret", "=", "new", "ConstructorCallExpression", "(", "type", ",", "arguments", ")", ";", "if", "(", "innerClass", "!=", "null", ")", "{", "ret", ".", "setType", "(", "innerClass", ")", ";", "ret", ".", "setUsingAnonymousInnerClass", "(", "true", ")", ";", "innerClass", ".", "setUnresolvedSuperClass", "(", "type", ")", ";", "}", "configureAST", "(", "ret", ",", "constructorCallNode", ")", ";", "return", "ret", ";", "}", "private", "ClassNode", "getAnonymousInnerClassNode", "(", "Expression", "arguments", ")", "{", "if", "(", "arguments", "instanceof", "TupleExpression", ")", "{", "TupleExpression", "te", "=", "(", "TupleExpression", ")", "arguments", ";", "List", "<", "Expression", ">", "expressions", "=", "te", ".", "getExpressions", "(", ")", ";", "if", "(", "expressions", ".", "size", "(", ")", "==", "0", ")", "return", "null", ";", "Expression", "last", "=", "(", "Expression", ")", "expressions", ".", "remove", "(", "expressions", ".", "size", "(", ")", "-", "1", ")", ";", "if", "(", "last", "instanceof", "AnonymousInnerClassCarrier", ")", "{", "AnonymousInnerClassCarrier", "carrier", "=", "(", "AnonymousInnerClassCarrier", ")", "last", ";", "return", "carrier", ".", "innerClass", ";", "}", "else", "{", "expressions", ".", "add", "(", "last", ")", ";", "}", "}", "else", "if", "(", "arguments", "instanceof", "AnonymousInnerClassCarrier", ")", "{", "AnonymousInnerClassCarrier", "carrier", "=", "(", "AnonymousInnerClassCarrier", ")", "arguments", ";", "return", "carrier", ".", "innerClass", ";", "}", "return", "null", ";", "}", "protected", "List", "arraySizeExpression", "(", "AST", "node", ")", "{", "List", "list", ";", "Expression", "size", "=", "null", ";", "if", "(", "isType", "(", "ARRAY_DECLARATOR", ",", "node", ")", ")", "{", "AST", "right", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "right", "!=", "null", ")", "{", "size", "=", "expression", "(", "right", ")", ";", "}", "else", "{", "size", "=", "ConstantExpression", ".", "EMPTY_EXPRESSION", ";", "}", "list", "=", "arraySizeExpression", "(", "node", ".", "getFirstChild", "(", ")", ")", ";", "}", "else", "{", "size", "=", "expression", "(", "node", ")", ";", "list", "=", "new", "ArrayList", "(", ")", ";", "}", "list", ".", "add", "(", "size", ")", ";", "return", "list", ";", "}", "protected", "Expression", "arguments", "(", "AST", "elist", ")", "{", "List", "expressionList", "=", "new", "ArrayList", "(", ")", ";", "boolean", "namedArguments", "=", "false", ";", "for", "(", "AST", "node", "=", "elist", ";", "node", "!=", "null", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "if", "(", "isType", "(", "ELIST", ",", "node", ")", ")", "{", "for", "(", "AST", "child", "=", "node", ".", "getFirstChild", "(", ")", ";", "child", "!=", "null", ";", "child", "=", "child", ".", "getNextSibling", "(", ")", ")", "{", "namedArguments", "|=", "addArgumentExpression", "(", "child", ",", "expressionList", ")", ";", "}", "}", "else", "{", "namedArguments", "|=", "addArgumentExpression", "(", "node", ",", "expressionList", ")", ";", "}", "}", "if", "(", "namedArguments", ")", "{", "if", "(", "!", "expressionList", ".", "isEmpty", "(", ")", ")", "{", "List", "argumentList", "=", "new", "ArrayList", "(", ")", ";", "for", "(", "Iterator", "iter", "=", "expressionList", ".", "iterator", "(", ")", ";", "iter", ".", "hasNext", "(", ")", ";", ")", "{", "Expression", "expression", "=", "(", "Expression", ")", "iter", ".", "next", "(", ")", ";", "if", "(", "!", "(", "expression", "instanceof", "MapEntryExpression", ")", ")", "{", "argumentList", ".", "add", "(", "expression", ")", ";", "}", "}", "if", "(", "!", "argumentList", ".", "isEmpty", "(", ")", ")", "{", "expressionList", ".", "removeAll", "(", "argumentList", ")", ";", "checkDuplicateNamedParams", "(", "elist", ",", "expressionList", ")", ";", "MapExpression", "mapExpression", "=", "new", "MapExpression", "(", "expressionList", ")", ";", "configureAST", "(", "mapExpression", ",", "elist", ")", ";", "argumentList", ".", "add", "(", "0", ",", "mapExpression", ")", ";", "ArgumentListExpression", "argumentListExpression", "=", "new", "ArgumentListExpression", "(", "argumentList", ")", ";", "configureAST", "(", "argumentListExpression", ",", "elist", ")", ";", "return", "argumentListExpression", ";", "}", "}", "checkDuplicateNamedParams", "(", "elist", ",", "expressionList", ")", ";", "NamedArgumentListExpression", "namedArgumentListExpression", "=", "new", "NamedArgumentListExpression", "(", "expressionList", ")", ";", "configureAST", "(", "namedArgumentListExpression", ",", "elist", ")", ";", "return", "namedArgumentListExpression", ";", "}", "else", "{", "ArgumentListExpression", "argumentListExpression", "=", "new", "ArgumentListExpression", "(", "expressionList", ")", ";", "if", "(", "elist", "!=", "null", ")", "{", "configureAST", "(", "argumentListExpression", ",", "elist", ")", ";", "}", "return", "argumentListExpression", ";", "}", "}", "private", "void", "checkDuplicateNamedParams", "(", "AST", "elist", ",", "List", "expressionList", ")", "{", "if", "(", "expressionList", ".", "isEmpty", "(", ")", ")", "return", ";", "Set", "<", "String", ">", "namedArgumentNames", "=", "new", "HashSet", "<", "String", ">", "(", ")", ";", "MapEntryExpression", "meExp", ";", "for", "(", "Iterator", "iter", "=", "expressionList", ".", "iterator", "(", ")", ";", "iter", ".", "hasNext", "(", ")", ";", ")", "{", "meExp", "=", "(", "MapEntryExpression", ")", "iter", ".", "next", "(", ")", ";", "if", "(", "meExp", ".", "getKeyExpression", "(", ")", "instanceof", "ConstantExpression", ")", "{", "String", "argName", "=", "(", "(", "ConstantExpression", ")", "meExp", ".", "getKeyExpression", "(", ")", ")", ".", "getText", "(", ")", ";", "if", "(", "!", "namedArgumentNames", ".", "contains", "(", "argName", ")", ")", "{", "namedArgumentNames", ".", "add", "(", "argName", ")", ";", "}", "else", "{", "throw", "new", "ASTRuntimeException", "(", "elist", ",", "\"\"", "+", "argName", "+", "\"'", "found.\"", ")", ";", "}", "}", "}", "}", "protected", "boolean", "addArgumentExpression", "(", "AST", "node", ",", "List", "expressionList", ")", "{", "if", "(", "node", ".", "getType", "(", ")", "==", "SPREAD_MAP_ARG", ")", "{", "AST", "rightNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Expression", "keyExpression", "=", "spreadMapExpression", "(", "node", ")", ";", "Expression", "rightExpression", "=", "expression", "(", "rightNode", ")", ";", "MapEntryExpression", "mapEntryExpression", "=", "new", "MapEntryExpression", "(", "keyExpression", ",", "rightExpression", ")", ";", "expressionList", ".", "add", "(", "mapEntryExpression", ")", ";", "return", "true", ";", "}", "else", "{", "Expression", "expression", "=", "expression", "(", "node", ")", ";", "expressionList", ".", "add", "(", "expression", ")", ";", "return", "expression", "instanceof", "MapEntryExpression", ";", "}", "}", "protected", "Expression", "expressionList", "(", "AST", "node", ")", "{", "List", "expressionList", "=", "new", "ArrayList", "(", ")", ";", "for", "(", "AST", "child", "=", "node", ".", "getFirstChild", "(", ")", ";", "child", "!=", "null", ";", "child", "=", "child", ".", "getNextSibling", "(", ")", ")", "{", "expressionList", ".", "add", "(", "expression", "(", "child", ")", ")", ";", "}", "if", "(", "expressionList", ".", "size", "(", ")", "==", "1", ")", "{", "return", "(", "Expression", ")", "expressionList", ".", "get", "(", "0", ")", ";", "}", "else", "{", "ListExpression", "listExpression", "=", "new", "ListExpression", "(", "expressionList", ")", ";", "listExpression", ".", "setWrapped", "(", "true", ")", ";", "configureAST", "(", "listExpression", ",", "node", ")", ";", "return", "listExpression", ";", "}", "}", "protected", "ClosureExpression", "closureExpression", "(", "AST", "node", ")", "{", "AST", "paramNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "Parameter", "[", "]", "parameters", "=", "null", ";", "AST", "codeNode", "=", "paramNode", ";", "if", "(", "isType", "(", "PARAMETERS", ",", "paramNode", ")", "||", "isType", "(", "IMPLICIT_PARAMETERS", ",", "paramNode", ")", ")", "{", "parameters", "=", "parameters", "(", "paramNode", ")", ";", "codeNode", "=", "paramNode", ".", "getNextSibling", "(", ")", ";", "}", "Statement", "code", "=", "statementListNoChild", "(", "codeNode", ",", "node", ")", ";", "ClosureExpression", "closureExpression", "=", "new", "ClosureExpression", "(", "parameters", ",", "code", ")", ";", "configureAST", "(", "closureExpression", ",", "node", ")", ";", "return", "closureExpression", ";", "}", "protected", "Expression", "blockExpression", "(", "AST", "node", ")", "{", "AST", "codeNode", "=", "node", ".", "getFirstChild", "(", ")", ";", "if", "(", "codeNode", "==", "null", ")", "return", "ConstantExpression", ".", "NULL", ";", "if", "(", "codeNode", ".", "getType", "(", ")", "==", "EXPR", "&&", "codeNode", ".", "getNextSibling", "(", ")", "==", "null", ")", "{", "return", "expression", "(", "codeNode", ")", ";", "}", "Parameter", "[", "]", "parameters", "=", "Parameter", ".", "EMPTY_ARRAY", ";", "Statement", "code", "=", "statementListNoChild", "(", "codeNode", ",", "node", ")", ";", "ClosureExpression", "closureExpression", "=", "new", "ClosureExpression", "(", "parameters", ",", "code", ")", ";", "configureAST", "(", "closureExpression", ",", "node", ")", ";", "String", "callName", "=", "\"call\"", ";", "Expression", "noArguments", "=", "new", "ArgumentListExpression", "(", ")", ";", "MethodCallExpression", "call", "=", "new", "MethodCallExpression", "(", "closureExpression", ",", "callName", ",", "noArguments", ")", ";", "configureAST", "(", "call", ",", "node", ")", ";", "return", "call", ";", "}", "protected", "Expression", "unaryMinusExpression", "(", "AST", "unaryMinusExpr", ")", "{", "AST", "node", "=", "unaryMinusExpr", ".", "getFirstChild", "(", ")", ";", "String", "text", "=", "node", ".", "getText", "(", ")", ";", "switch", "(", "node", ".", "getType", "(", ")", ")", "{", "case", "NUM_DOUBLE", ":", "case", "NUM_FLOAT", ":", "case", "NUM_BIG_DECIMAL", ":", "ConstantExpression", "constantExpression", "=", "new", "ConstantExpression", "(", "Numbers", ".", "parseDecimal", "(", "\"-\"", "+", "text", ")", ")", ";", "configureAST", "(", "constantExpression", ",", "unaryMinusExpr", ")", ";", "return", "constantExpression", ";", "case", "NUM_BIG_INT", ":", "case", "NUM_INT", ":", "case", "NUM_LONG", ":", "ConstantExpression", "constantLongExpression", "=", "new", "ConstantExpression", "(", "Numbers", ".", "parseInteger", "(", "\"-\"", "+", "text", ")", ")", ";", "configureAST", "(", "constantLongExpression", ",", "unaryMinusExpr", ")", ";", "return", "constantLongExpression", ";", "default", ":", "UnaryMinusExpression", "unaryMinusExpression", "=", "new", "UnaryMinusExpression", "(", "expression", "(", "node", ")", ")", ";", "configureAST", "(", "unaryMinusExpression", ",", "unaryMinusExpr", ")", ";", "return", "unaryMinusExpression", ";", "}", "}", "protected", "Expression", "unaryPlusExpression", "(", "AST", "unaryPlusExpr", ")", "{", "AST", "node", "=", "unaryPlusExpr", ".", "getFirstChild", "(", ")", ";", "switch", "(", "node", ".", "getType", "(", ")", ")", "{", "case", "NUM_DOUBLE", ":", "case", "NUM_FLOAT", ":", "case", "NUM_BIG_DECIMAL", ":", "case", "NUM_BIG_INT", ":", "case", "NUM_INT", ":", "case", "NUM_LONG", ":", "return", "expression", "(", "node", ")", ";", "default", ":", "UnaryPlusExpression", "unaryPlusExpression", "=", "new", "UnaryPlusExpression", "(", "expression", "(", "node", ")", ")", ";", "configureAST", "(", "unaryPlusExpression", ",", "unaryPlusExpr", ")", ";", "return", "unaryPlusExpression", ";", "}", "}", "protected", "ConstantExpression", "decimalExpression", "(", "AST", "node", ")", "{", "String", "text", "=", "node", ".", "getText", "(", ")", ";", "ConstantExpression", "constantExpression", "=", "new", "ConstantExpression", "(", "Numbers", ".", "parseDecimal", "(", "text", ")", ")", ";", "configureAST", "(", "constantExpression", ",", "node", ")", ";", "return", "constantExpression", ";", "}", "protected", "ConstantExpression", "integerExpression", "(", "AST", "node", ")", "{", "String", "text", "=", "node", ".", "getText", "(", ")", ";", "ConstantExpression", "constantExpression", "=", "new", "ConstantExpression", "(", "Numbers", ".", "parseInteger", "(", "text", ")", ")", ";", "configureAST", "(", "constantExpression", ",", "node", ")", ";", "return", "constantExpression", ";", "}", "protected", "Expression", "gstring", "(", "AST", "gstringNode", ")", "{", "List", "strings", "=", "new", "ArrayList", "(", ")", ";", "List", "values", "=", "new", "ArrayList", "(", ")", ";", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "boolean", "isPrevString", "=", "false", ";", "for", "(", "AST", "node", "=", "gstringNode", ".", "getFirstChild", "(", ")", ";", "node", "!=", "null", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "int", "type", "=", "node", ".", "getType", "(", ")", ";", "String", "text", "=", "null", ";", "switch", "(", "type", ")", "{", "case", "STRING_LITERAL", ":", "if", "(", "isPrevString", ")", "assertNodeType", "(", "IDENT", ",", "node", ")", ";", "isPrevString", "=", "true", ";", "text", "=", "node", ".", "getText", "(", ")", ";", "ConstantExpression", "constantExpression", "=", "new", "ConstantExpression", "(", "text", ")", ";", "configureAST", "(", "constantExpression", ",", "node", ")", ";", "strings", ".", "add", "(", "constantExpression", ")", ";", "buffer", ".", "append", "(", "text", ")", ";", "break", ";", "default", ":", "{", "if", "(", "!", "isPrevString", ")", "assertNodeType", "(", "IDENT", ",", "node", ")", ";", "isPrevString", "=", "false", ";", "Expression", "expression", "=", "expression", "(", "node", ")", ";", "values", ".", "add", "(", "expression", ")", ";", "buffer", ".", "append", "(", "\"$\"", ")", ";", "buffer", ".", "append", "(", "expression", ".", "getText", "(", ")", ")", ";", "}", "break", ";", "}", "}", "GStringExpression", "gStringExpression", "=", "new", "GStringExpression", "(", "buffer", ".", "toString", "(", ")", ",", "strings", ",", "values", ")", ";", "configureAST", "(", "gStringExpression", ",", "gstringNode", ")", ";", "return", "gStringExpression", ";", "}", "protected", "ClassNode", "type", "(", "AST", "typeNode", ")", "{", "return", "buildName", "(", "typeNode", ".", "getFirstChild", "(", ")", ")", ";", "}", "public", "static", "String", "qualifiedName", "(", "AST", "qualifiedNameNode", ")", "{", "if", "(", "isType", "(", "IDENT", ",", "qualifiedNameNode", ")", ")", "{", "return", "qualifiedNameNode", ".", "getText", "(", ")", ";", "}", "if", "(", "isType", "(", "DOT", ",", "qualifiedNameNode", ")", ")", "{", "AST", "node", "=", "qualifiedNameNode", ".", "getFirstChild", "(", ")", ";", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", ")", ";", "boolean", "first", "=", "true", ";", "for", "(", ";", "node", "!=", "null", "&&", "!", "isType", "(", "TYPE_ARGUMENTS", ",", "node", ")", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "if", "(", "first", ")", "{", "first", "=", "false", ";", "}", "else", "{", "buffer", ".", "append", "(", "\".\"", ")", ";", "}", "buffer", ".", "append", "(", "qualifiedName", "(", "node", ")", ")", ";", "}", "return", "buffer", ".", "toString", "(", ")", ";", "}", "else", "{", "return", "qualifiedNameNode", ".", "getText", "(", ")", ";", "}", "}", "private", "static", "AST", "getTypeArgumentsNode", "(", "AST", "root", ")", "{", "while", "(", "root", "!=", "null", "&&", "!", "isType", "(", "TYPE_ARGUMENTS", ",", "root", ")", ")", "{", "root", "=", "root", ".", "getNextSibling", "(", ")", ";", "}", "return", "root", ";", "}", "private", "int", "getBoundType", "(", "AST", "node", ")", "{", "if", "(", "node", "==", "null", ")", "return", "-", "1", ";", "if", "(", "isType", "(", "TYPE_UPPER_BOUNDS", ",", "node", ")", ")", "return", "TYPE_UPPER_BOUNDS", ";", "if", "(", "isType", "(", "TYPE_LOWER_BOUNDS", ",", "node", ")", ")", "return", "TYPE_LOWER_BOUNDS", ";", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", "+", "getTokenName", "(", "node", ")", "+", "\"\"", "+", "getTokenName", "(", "TYPE_UPPER_BOUNDS", ")", "+", "\"", "or", "type:", "\"", "+", "getTokenName", "(", "TYPE_LOWER_BOUNDS", ")", ")", ";", "}", "private", "GenericsType", "makeGenericsArgumentType", "(", "AST", "typeArgument", ")", "{", "GenericsType", "gt", ";", "AST", "rootNode", "=", "typeArgument", ".", "getFirstChild", "(", ")", ";", "if", "(", "isType", "(", "WILDCARD_TYPE", ",", "rootNode", ")", ")", "{", "ClassNode", "base", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "\"?\"", ")", ";", "if", "(", "rootNode", ".", "getNextSibling", "(", ")", "!=", "null", ")", "{", "int", "boundType", "=", "getBoundType", "(", "rootNode", ".", "getNextSibling", "(", ")", ")", ";", "ClassNode", "[", "]", "gts", "=", "makeGenericsBounds", "(", "rootNode", ",", "boundType", ")", ";", "if", "(", "boundType", "==", "TYPE_UPPER_BOUNDS", ")", "{", "gt", "=", "new", "GenericsType", "(", "base", ",", "gts", ",", "null", ")", ";", "}", "else", "{", "gt", "=", "new", "GenericsType", "(", "base", ",", "null", ",", "gts", "[", "0", "]", ")", ";", "}", "}", "else", "{", "gt", "=", "new", "GenericsType", "(", "base", ",", "null", ",", "null", ")", ";", "}", "gt", ".", "setName", "(", "\"?\"", ")", ";", "gt", ".", "setWildcard", "(", "true", ")", ";", "}", "else", "{", "ClassNode", "argument", "=", "makeTypeWithArguments", "(", "rootNode", ")", ";", "gt", "=", "new", "GenericsType", "(", "argument", ")", ";", "}", "configureAST", "(", "gt", ",", "typeArgument", ")", ";", "return", "gt", ";", "}", "protected", "ClassNode", "makeTypeWithArguments", "(", "AST", "rootNode", ")", "{", "ClassNode", "basicType", "=", "makeType", "(", "rootNode", ")", ";", "AST", "node", "=", "rootNode", ".", "getFirstChild", "(", ")", ";", "if", "(", "node", "==", "null", "||", "isType", "(", "INDEX_OP", ",", "node", ")", "||", "isType", "(", "ARRAY_DECLARATOR", ",", "node", ")", ")", "return", "basicType", ";", "if", "(", "!", "isType", "(", "DOT", ",", "node", ")", ")", "{", "node", "=", "node", ".", "getFirstChild", "(", ")", ";", "if", "(", "node", "==", "null", ")", "return", "basicType", ";", "return", "addTypeArguments", "(", "basicType", ",", "node", ")", ";", "}", "else", "{", "node", "=", "node", ".", "getFirstChild", "(", ")", ";", "while", "(", "node", "!=", "null", "&&", "!", "isType", "(", "TYPE_ARGUMENTS", ",", "node", ")", ")", "node", "=", "node", ".", "getNextSibling", "(", ")", ";", "return", "node", "==", "null", "?", "basicType", ":", "addTypeArguments", "(", "basicType", ",", "node", ")", ";", "}", "}", "private", "ClassNode", "addTypeArguments", "(", "ClassNode", "basicType", ",", "AST", "node", ")", "{", "List", "<", "GenericsType", ">", "typeArgumentList", "=", "getTypeArgumentsList", "(", "node", ")", ";", "if", "(", "typeArgumentList", ".", "size", "(", ")", ">", "0", ")", "{", "basicType", ".", "setGenericsTypes", "(", "typeArgumentList", ".", "toArray", "(", "new", "GenericsType", "[", "typeArgumentList", ".", "size", "(", ")", "]", ")", ")", ";", "}", "return", "basicType", ";", "}", "private", "List", "<", "GenericsType", ">", "getTypeArgumentsList", "(", "AST", "node", ")", "{", "assertNodeType", "(", "TYPE_ARGUMENTS", ",", "node", ")", ";", "List", "<", "GenericsType", ">", "typeArgumentList", "=", "new", "LinkedList", "<", "GenericsType", ">", "(", ")", ";", "AST", "typeArgument", "=", "node", ".", "getFirstChild", "(", ")", ";", "while", "(", "typeArgument", "!=", "null", ")", "{", "assertNodeType", "(", "TYPE_ARGUMENT", ",", "typeArgument", ")", ";", "GenericsType", "gt", "=", "makeGenericsArgumentType", "(", "typeArgument", ")", ";", "typeArgumentList", ".", "add", "(", "gt", ")", ";", "typeArgument", "=", "typeArgument", ".", "getNextSibling", "(", ")", ";", "}", "return", "typeArgumentList", ";", "}", "private", "ClassNode", "[", "]", "makeGenericsBounds", "(", "AST", "rn", ",", "int", "boundType", ")", "{", "AST", "boundsRoot", "=", "rn", ".", "getNextSibling", "(", ")", ";", "if", "(", "boundsRoot", "==", "null", ")", "return", "null", ";", "assertNodeType", "(", "boundType", ",", "boundsRoot", ")", ";", "LinkedList", "bounds", "=", "new", "LinkedList", "(", ")", ";", "for", "(", "AST", "boundsNode", "=", "boundsRoot", ".", "getFirstChild", "(", ")", ";", "boundsNode", "!=", "null", ";", "boundsNode", "=", "boundsNode", ".", "getNextSibling", "(", ")", ")", "{", "ClassNode", "bound", "=", "null", ";", "bound", "=", "makeTypeWithArguments", "(", "boundsNode", ")", ";", "configureAST", "(", "bound", ",", "boundsNode", ")", ";", "bounds", ".", "add", "(", "bound", ")", ";", "}", "if", "(", "bounds", ".", "size", "(", ")", "==", "0", ")", "return", "null", ";", "return", "(", "ClassNode", "[", "]", ")", "bounds", ".", "toArray", "(", "new", "ClassNode", "[", "bounds", ".", "size", "(", ")", "]", ")", ";", "}", "protected", "GenericsType", "[", "]", "makeGenericsType", "(", "AST", "rootNode", ")", "{", "AST", "typeParameter", "=", "rootNode", ".", "getFirstChild", "(", ")", ";", "LinkedList", "ret", "=", "new", "LinkedList", "(", ")", ";", "assertNodeType", "(", "TYPE_PARAMETER", ",", "typeParameter", ")", ";", "while", "(", "isType", "(", "TYPE_PARAMETER", ",", "typeParameter", ")", ")", "{", "AST", "typeNode", "=", "typeParameter", ".", "getFirstChild", "(", ")", ";", "ClassNode", "type", "=", "makeType", "(", "typeParameter", ")", ";", "GenericsType", "gt", "=", "new", "GenericsType", "(", "type", ",", "makeGenericsBounds", "(", "typeNode", ",", "TYPE_UPPER_BOUNDS", ")", ",", "null", ")", ";", "configureAST", "(", "gt", ",", "typeParameter", ")", ";", "ret", ".", "add", "(", "gt", ")", ";", "typeParameter", "=", "typeParameter", ".", "getNextSibling", "(", ")", ";", "}", "return", "(", "GenericsType", "[", "]", ")", "ret", ".", "toArray", "(", "new", "GenericsType", "[", "0", "]", ")", ";", "}", "protected", "ClassNode", "makeType", "(", "AST", "typeNode", ")", "{", "ClassNode", "answer", "=", "ClassHelper", ".", "DYNAMIC_TYPE", ";", "AST", "node", "=", "typeNode", ".", "getFirstChild", "(", ")", ";", "if", "(", "node", "!=", "null", ")", "{", "if", "(", "isType", "(", "INDEX_OP", ",", "node", ")", "||", "isType", "(", "ARRAY_DECLARATOR", ",", "node", ")", ")", "{", "answer", "=", "makeType", "(", "node", ")", ".", "makeArray", "(", ")", ";", "}", "else", "{", "answer", "=", "ClassHelper", ".", "make", "(", "qualifiedName", "(", "node", ")", ")", ";", "if", "(", "answer", ".", "isUsingGenerics", "(", ")", ")", "{", "ClassNode", "newAnswer", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "answer", ".", "getName", "(", ")", ")", ";", "newAnswer", ".", "setRedirect", "(", "answer", ")", ";", "answer", "=", "newAnswer", ";", "}", "}", "configureAST", "(", "answer", ",", "node", ")", ";", "}", "return", "answer", ";", "}", "protected", "ClassNode", "buildName", "(", "AST", "node", ")", "{", "if", "(", "isType", "(", "TYPE", ",", "node", ")", ")", "{", "node", "=", "node", ".", "getFirstChild", "(", ")", ";", "}", "ClassNode", "answer", "=", "null", ";", "if", "(", "isType", "(", "DOT", ",", "node", ")", "||", "isType", "(", "OPTIONAL_DOT", ",", "node", ")", ")", "{", "answer", "=", "ClassHelper", ".", "make", "(", "qualifiedName", "(", "node", ")", ")", ";", "}", "else", "if", "(", "isPrimitiveTypeLiteral", "(", "node", ")", ")", "{", "answer", "=", "ClassHelper", ".", "make", "(", "node", ".", "getText", "(", ")", ")", ";", "}", "else", "if", "(", "isType", "(", "INDEX_OP", ",", "node", ")", "||", "isType", "(", "ARRAY_DECLARATOR", ",", "node", ")", ")", "{", "AST", "child", "=", "node", ".", "getFirstChild", "(", ")", ";", "answer", "=", "buildName", "(", "child", ")", ".", "makeArray", "(", ")", ";", "configureAST", "(", "answer", ",", "node", ")", ";", "return", "answer", ";", "}", "else", "{", "String", "identifier", "=", "node", ".", "getText", "(", ")", ";", "answer", "=", "ClassHelper", ".", "make", "(", "identifier", ")", ";", "}", "AST", "nextSibling", "=", "node", ".", "getNextSibling", "(", ")", ";", "if", "(", "isType", "(", "INDEX_OP", ",", "nextSibling", ")", "||", "isType", "(", "ARRAY_DECLARATOR", ",", "node", ")", ")", "{", "answer", "=", "answer", ".", "makeArray", "(", ")", ";", "configureAST", "(", "answer", ",", "node", ")", ";", "return", "answer", ";", "}", "else", "{", "configureAST", "(", "answer", ",", "node", ")", ";", "return", "answer", ";", "}", "}", "protected", "boolean", "isPrimitiveTypeLiteral", "(", "AST", "node", ")", "{", "int", "type", "=", "node", ".", "getType", "(", ")", ";", "switch", "(", "type", ")", "{", "case", "LITERAL_boolean", ":", "case", "LITERAL_byte", ":", "case", "LITERAL_char", ":", "case", "LITERAL_double", ":", "case", "LITERAL_float", ":", "case", "LITERAL_int", ":", "case", "LITERAL_long", ":", "case", "LITERAL_short", ":", "return", "true", ";", "default", ":", "return", "false", ";", "}", "}", "protected", "String", "identifier", "(", "AST", "node", ")", "{", "assertNodeType", "(", "IDENT", ",", "node", ")", ";", "return", "node", ".", "getText", "(", ")", ";", "}", "protected", "String", "label", "(", "AST", "labelNode", ")", "{", "AST", "node", "=", "labelNode", ".", "getFirstChild", "(", ")", ";", "if", "(", "node", "==", "null", ")", "{", "return", "null", ";", "}", "return", "identifier", "(", "node", ")", ";", "}", "protected", "boolean", "hasVisibility", "(", "int", "modifiers", ")", "{", "return", "(", "modifiers", "&", "(", "Opcodes", ".", "ACC_PRIVATE", "|", "Opcodes", ".", "ACC_PROTECTED", "|", "Opcodes", ".", "ACC_PUBLIC", ")", ")", "!=", "0", ";", "}", "protected", "void", "configureAST", "(", "ASTNode", "node", ",", "AST", "ast", ")", "{", "if", "(", "ast", "==", "null", ")", "throw", "new", "ASTRuntimeException", "(", "ast", ",", "\"\"", "+", "node", ".", "getClass", "(", ")", ".", "getName", "(", ")", "+", "\"\"", ")", ";", "int", "startcol", "=", "ast", ".", "getColumn", "(", ")", ";", "int", "startline", "=", "ast", ".", "getLine", "(", ")", ";", "int", "startoffset", "=", "locations", ".", "findOffset", "(", "startline", ",", "startcol", ")", ";", "int", "lastcol", ";", "int", "lastline", ";", "int", "endoffset", ";", "if", "(", "ast", "instanceof", "GroovySourceAST", ")", "{", "GroovySourceAST", "groovySourceAST", "=", "(", "GroovySourceAST", ")", "ast", ";", "lastcol", "=", "groovySourceAST", ".", "getColumnLast", "(", ")", ";", "lastline", "=", "groovySourceAST", ".", "getLineLast", "(", ")", ";", "endoffset", "=", "locations", ".", "findOffset", "(", "lastline", ",", "lastcol", ")", ";", "if", "(", "(", "node", "instanceof", "BinaryExpression", "||", "node", "instanceof", "MapEntryExpression", "||", "node", "instanceof", "MapExpression", "||", "node", "instanceof", "CastExpression", ")", "&&", "(", "node", ".", "getStart", "(", ")", "<=", "startoffset", "&&", "node", ".", "getEnd", "(", ")", ">=", "endoffset", ")", ")", "{", "return", ";", "}", "if", "(", "(", "node", "instanceof", "VariableExpression", "||", "node", "instanceof", "ConstantExpression", ")", "&&", "node", ".", "getEnd", "(", ")", ">", "0", "&&", "(", "startoffset", "<=", "node", ".", "getStart", "(", ")", "&&", "endoffset", ">=", "node", ".", "getEnd", "(", ")", ")", ")", "{", "return", ";", "}", "node", ".", "setLastColumnNumber", "(", "lastcol", ")", ";", "node", ".", "setLastLineNumber", "(", "lastline", ")", ";", "node", ".", "setEnd", "(", "endoffset", ")", ";", "}", "node", ".", "setColumnNumber", "(", "startcol", ")", ";", "node", ".", "setLineNumber", "(", "startline", ")", ";", "node", ".", "setStart", "(", "startoffset", ")", ";", "}", "protected", "static", "Token", "makeToken", "(", "int", "typeCode", ",", "AST", "node", ")", "{", "return", "Token", ".", "newSymbol", "(", "typeCode", ",", "node", ".", "getLine", "(", ")", ",", "node", ".", "getColumn", "(", ")", ")", ";", "}", "protected", "String", "getFirstChildText", "(", "AST", "node", ")", "{", "AST", "child", "=", "node", ".", "getFirstChild", "(", ")", ";", "return", "child", "!=", "null", "?", "child", ".", "getText", "(", ")", ":", "null", ";", "}", "public", "static", "boolean", "isType", "(", "int", "typeCode", ",", "AST", "node", ")", "{", "return", "node", "!=", "null", "&&", "node", ".", "getType", "(", ")", "==", "typeCode", ";", "}", "private", "String", "getTokenName", "(", "int", "token", ")", "{", "if", "(", "tokenNames", "==", "null", ")", "return", "\"\"", "+", "token", ";", "return", "tokenNames", "[", "token", "]", ";", "}", "private", "String", "getTokenName", "(", "AST", "node", ")", "{", "if", "(", "node", "==", "null", ")", "return", "\"null\"", ";", "return", "getTokenName", "(", "node", ".", "getType", "(", ")", ")", ";", "}", "protected", "void", "assertNodeType", "(", "int", "type", ",", "AST", "node", ")", "{", "if", "(", "node", "==", "null", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", "+", "getTokenName", "(", "type", ")", ")", ";", "}", "if", "(", "node", ".", "getType", "(", ")", "!=", "type", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", "+", "getTokenName", "(", "node", ")", "+", "\"\"", "+", "getTokenName", "(", "type", ")", ")", ";", "}", "}", "protected", "void", "notImplementedYet", "(", "AST", "node", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", "+", "getTokenName", "(", "node", ")", ")", ";", "}", "protected", "Expression", "unknownAST", "(", "AST", "node", ")", "{", "if", "(", "node", ".", "getType", "(", ")", "==", "CLASS_DEF", ")", "{", "throw", "new", "ASTRuntimeException", "(", "node", ",", "\"\"", "+", "\"\"", ")", ";", "}", "return", "new", "ConstantExpression", "(", "\"ERROR\"", ")", ";", "}", "protected", "void", "dumpTree", "(", "AST", "ast", ")", "{", "for", "(", "AST", "node", "=", "ast", ".", "getFirstChild", "(", ")", ";", "node", "!=", "null", ";", "node", "=", "node", ".", "getNextSibling", "(", ")", ")", "{", "dump", "(", "node", ")", ";", "}", "}", "protected", "void", "dump", "(", "AST", "node", ")", "{", "System", ".", "out", ".", "println", "(", "\"Type:", "\"", "+", "getTokenName", "(", "node", ")", "+", "\"", "text:", "\"", "+", "node", ".", "getText", "(", ")", ")", ";", "}", "private", "void", "fixModuleNodeLocations", "(", ")", "{", "output", ".", "setStart", "(", "0", ")", ";", "output", ".", "setEnd", "(", "locations", ".", "getEnd", "(", ")", ")", ";", "output", ".", "setLineNumber", "(", "1", ")", ";", "output", ".", "setColumnNumber", "(", "1", ")", ";", "output", ".", "setLastColumnNumber", "(", "locations", ".", "getEndColumn", "(", ")", ")", ";", "output", ".", "setLastLineNumber", "(", "locations", ".", "getEndLine", "(", ")", ")", ";", "BlockStatement", "statements", "=", "output", ".", "getStatementBlock", "(", ")", ";", "List", "<", "MethodNode", ">", "methods", "=", "output", ".", "getMethods", "(", ")", ";", "if", "(", "hasScriptMethodsOrStatements", "(", "statements", ",", "methods", ")", ")", "{", "ASTNode", "first", "=", "getFirst", "(", "statements", ",", "methods", ")", ";", "ASTNode", "last", "=", "getLast", "(", "statements", ",", "methods", ")", ";", "if", "(", "hasScriptStatements", "(", "statements", ")", ")", "{", "statements", ".", "setStart", "(", "first", ".", "getStart", "(", ")", ")", ";", "statements", ".", "setLineNumber", "(", "first", ".", "getLineNumber", "(", ")", ")", ";", "statements", ".", "setColumnNumber", "(", "first", ".", "getColumnNumber", "(", ")", ")", ";", "statements", ".", "setEnd", "(", "last", ".", "getEnd", "(", ")", ")", ";", "statements", ".", "setLastLineNumber", "(", "last", ".", "getLastLineNumber", "(", ")", ")", ";", "statements", ".", "setLastColumnNumber", "(", "last", ".", "getLastColumnNumber", "(", ")", ")", ";", "}", "if", "(", "output", ".", "getClasses", "(", ")", ".", "size", "(", ")", ">", "0", ")", "{", "ClassNode", "scriptClass", "=", "output", ".", "getClasses", "(", ")", ".", "get", "(", "0", ")", ";", "scriptClass", ".", "setStart", "(", "first", ".", "getStart", "(", ")", ")", ";", "scriptClass", ".", "setLineNumber", "(", "first", ".", "getLineNumber", "(", ")", ")", ";", "scriptClass", ".", "setColumnNumber", "(", "first", ".", "getColumnNumber", "(", ")", ")", ";", "scriptClass", ".", "setEnd", "(", "last", ".", "getEnd", "(", ")", ")", ";", "scriptClass", ".", "setLastLineNumber", "(", "last", ".", "getLastLineNumber", "(", ")", ")", ";", "scriptClass", ".", "setLastColumnNumber", "(", "last", ".", "getLastColumnNumber", "(", ")", ")", ";", "MethodNode", "runMethod", "=", "scriptClass", ".", "getDeclaredMethod", "(", "\"run\"", ",", "new", "Parameter", "[", "0", "]", ")", ";", "runMethod", ".", "setStart", "(", "first", ".", "getStart", "(", ")", ")", ";", "runMethod", ".", "setLineNumber", "(", "first", ".", "getLineNumber", "(", ")", ")", ";", "runMethod", ".", "setColumnNumber", "(", "first", ".", "getColumnNumber", "(", ")", ")", ";", "runMethod", ".", "setEnd", "(", "last", ".", "getEnd", "(", ")", ")", ";", "runMethod", ".", "setLastLineNumber", "(", "last", ".", "getLastLineNumber", "(", ")", ")", ";", "runMethod", ".", "setLastColumnNumber", "(", "last", ".", "getLastColumnNumber", "(", ")", ")", ";", "}", "}", "}", "private", "ASTNode", "getFirst", "(", "BlockStatement", "statements", ",", "List", "<", "MethodNode", ">", "methods", ")", "{", "Statement", "firstStatement", "=", "hasScriptStatements", "(", "statements", ")", "?", "statements", ".", "getStatements", "(", ")", ".", "get", "(", "0", ")", ":", "null", ";", "MethodNode", "firstMethod", "=", "hasScriptMethods", "(", "methods", ")", "?", "methods", ".", "get", "(", "0", ")", ":", "null", ";", "if", "(", "firstMethod", "==", "null", "&&", "(", "firstStatement", "==", "null", "||", "(", "firstStatement", ".", "getStart", "(", ")", "==", "0", "&&", "firstStatement", ".", "getLength", "(", ")", "==", "0", ")", ")", ")", "{", "firstStatement", "=", "createSyntheticAfterImports", "(", ")", ";", "}", "int", "statementStart", "=", "firstStatement", "!=", "null", "?", "firstStatement", ".", "getStart", "(", ")", ":", "Integer", ".", "MAX_VALUE", ";", "int", "methodStart", "=", "firstMethod", "!=", "null", "?", "firstMethod", ".", "getStart", "(", ")", ":", "Integer", ".", "MAX_VALUE", ";", "return", "statementStart", "<=", "methodStart", "?", "firstStatement", ":", "firstMethod", ";", "}", "private", "ASTNode", "getLast", "(", "BlockStatement", "statements", ",", "List", "<", "MethodNode", ">", "methods", ")", "{", "Statement", "lastStatement", "=", "hasScriptStatements", "(", "statements", ")", "?", "statements", ".", "getStatements", "(", ")", ".", "get", "(", "statements", ".", "getStatements", "(", ")", ".", "size", "(", ")", "-", "1", ")", ":", "null", ";", "MethodNode", "lastMethod", "=", "hasScriptMethods", "(", "methods", ")", "?", "methods", ".", "get", "(", "methods", ".", "size", "(", ")", "-", "1", ")", ":", "null", ";", "if", "(", "lastMethod", "==", "null", "&&", "(", "lastStatement", "==", "null", "||", "(", "lastStatement", ".", "getStart", "(", ")", "==", "0", "&&", "lastStatement", ".", "getLength", "(", ")", "==", "0", ")", ")", ")", "{", "lastStatement", "=", "createSyntheticAfterImports", "(", ")", ";", "}", "int", "statementStart", "=", "lastStatement", "!=", "null", "?", "lastStatement", ".", "getEnd", "(", ")", ":", "Integer", ".", "MIN_VALUE", ";", "int", "methodStart", "=", "lastMethod", "!=", "null", "?", "lastMethod", ".", "getStart", "(", ")", ":", "Integer", ".", "MIN_VALUE", ";", "return", "statementStart", ">=", "methodStart", "?", "lastStatement", ":", "lastMethod", ";", "}", "private", "Statement", "createSyntheticAfterImports", "(", ")", "{", "ASTNode", "target", "=", "null", ";", "Statement", "synthetic", "=", "ReturnStatement", ".", "RETURN_NULL_OR_VOID", ";", "if", "(", "output", ".", "getImports", "(", ")", "!=", "null", "&&", "output", ".", "getImports", "(", ")", ".", "size", "(", ")", ">", "0", ")", "{", "target", "=", "output", ".", "getImports", "(", ")", ".", "get", "(", "output", ".", "getImports", "(", ")", ".", "size", "(", ")", "-", "1", ")", ";", "}", "else", "if", "(", "output", ".", "hasPackage", "(", ")", ")", "{", "target", "=", "output", ".", "getPackage", "(", ")", ";", "}", "if", "(", "target", "!=", "null", ")", "{", "synthetic", "=", "new", "ReturnStatement", "(", "ConstantExpression", ".", "NULL", ")", ";", "synthetic", ".", "setStart", "(", "target", ".", "getEnd", "(", ")", "+", "1", ")", ";", "synthetic", ".", "setEnd", "(", "target", ".", "getEnd", "(", ")", "+", "1", ")", ";", "synthetic", ".", "setLineNumber", "(", "target", ".", "getLastLineNumber", "(", ")", ")", ";", "synthetic", ".", "setLastLineNumber", "(", "target", ".", "getLineNumber", "(", ")", ")", ";", "synthetic", ".", "setColumnNumber", "(", "target", ".", "getLastColumnNumber", "(", ")", "+", "1", ")", ";", "synthetic", ".", "setLastColumnNumber", "(", "target", ".", "getColumnNumber", "(", ")", "+", "1", ")", ";", "}", "return", "synthetic", ";", "}", "private", "boolean", "hasScriptMethodsOrStatements", "(", "BlockStatement", "statements", ",", "List", "<", "MethodNode", ">", "methods", ")", "{", "return", "hasScriptStatements", "(", "statements", ")", "||", "hasScriptMethods", "(", "methods", ")", ";", "}", "private", "boolean", "hasScriptMethods", "(", "List", "<", "MethodNode", ">", "methods", ")", "{", "return", "methods", "!=", "null", "&&", "methods", ".", "size", "(", ")", ">", "0", ";", "}", "private", "boolean", "hasScriptStatements", "(", "BlockStatement", "statements", ")", "{", "return", "statements", "!=", "null", "&&", "statements", ".", "getStatements", "(", ")", "!=", "null", "&&", "statements", ".", "getStatements", "(", ")", ".", "size", "(", ")", ">", "0", ";", "}", "protected", "void", "configureAnnotationAST", "(", "ASTNode", "node", ",", "AST", "ast", ")", "{", "if", "(", "ast", "==", "null", ")", "{", "throw", "new", "ASTRuntimeException", "(", "ast", ",", "\"\"", "+", "node", ".", "getClass", "(", ")", ".", "getName", "(", ")", "+", "\"\"", ")", ";", "}", "if", "(", "ast", "instanceof", "GroovySourceAST", ")", "{", "GroovySourceAST", "correctAst", "=", "(", "GroovySourceAST", ")", "ast", ";", "correctAst", "=", "(", "GroovySourceAST", ")", "correctAst", ".", "getFirstChild", "(", ")", ";", "setPositions", "(", "node", ",", "correctAst", ".", "getColumn", "(", ")", ",", "correctAst", ".", "getLine", "(", ")", ",", "correctAst", ".", "getColumnLast", "(", ")", ",", "correctAst", ".", "getLineLast", "(", ")", ")", ";", "if", "(", "node", "instanceof", "AnnotationNode", ")", "{", "setPositions", "(", "(", "(", "AnnotationNode", ")", "node", ")", ".", "getClassNode", "(", ")", ",", "correctAst", ".", "getColumn", "(", ")", ",", "correctAst", ".", "getLine", "(", ")", ",", "correctAst", ".", "getColumnLast", "(", ")", "+", "1", ",", "correctAst", ".", "getLineLast", "(", ")", ")", ";", "}", "}", "else", "{", "int", "startcol", "=", "ast", ".", "getColumn", "(", ")", ";", "int", "startline", "=", "ast", ".", "getLine", "(", ")", ";", "node", ".", "setColumnNumber", "(", "startcol", ")", ";", "node", ".", "setLineNumber", "(", "startline", ")", ";", "int", "startoffset", "=", "locations", ".", "findOffset", "(", "startline", ",", "startcol", ")", ";", "node", ".", "setStart", "(", "startoffset", ")", ";", "}", "}", "private", "void", "configureClassNodeForClassDefAST", "(", "ASTNode", "node", ",", "AST", "ast", ")", "{", "if", "(", "ast", "==", "null", ")", "{", "throw", "new", "ASTRuntimeException", "(", "ast", ",", "\"\"", "+", "node", ".", "getClass", "(", ")", ".", "getName", "(", ")", "+", "\"\"", ")", ";", "}", "if", "(", "ast", "instanceof", "GroovySourceAST", ")", "{", "GroovySourceAST", "theAst", "=", "(", "GroovySourceAST", ")", "ast", ";", "theAst", "=", "(", "GroovySourceAST", ")", "theAst", ".", "getFirstChild", "(", ")", ".", "getNextSibling", "(", ")", ";", "setPositions", "(", "node", ",", "theAst", ".", "getColumn", "(", ")", ",", "theAst", ".", "getLine", "(", ")", ",", "theAst", ".", "getColumnLast", "(", ")", ",", "theAst", ".", "getLineLast", "(", ")", ")", ";", "}", "else", "{", "int", "startcol", "=", "ast", ".", "getColumn", "(", ")", ";", "int", "startline", "=", "ast", ".", "getLine", "(", ")", ";", "node", ".", "setColumnNumber", "(", "startcol", ")", ";", "node", ".", "setLineNumber", "(", "startline", ")", ";", "int", "startoffset", "=", "locations", ".", "findOffset", "(", "startline", ",", "startcol", ")", ";", "node", ".", "setStart", "(", "startoffset", ")", ";", "}", "}", "private", "void", "setPositions", "(", "ASTNode", "node", ",", "int", "scol", ",", "int", "sline", ",", "int", "ecol", ",", "int", "eline", ")", "{", "node", ".", "setColumnNumber", "(", "scol", ")", ";", "node", ".", "setLineNumber", "(", "sline", ")", ";", "node", ".", "setStart", "(", "locations", ".", "findOffset", "(", "sline", ",", "scol", ")", ")", ";", "node", ".", "setLastColumnNumber", "(", "ecol", ")", ";", "node", ".", "setLastLineNumber", "(", "eline", ")", ";", "node", ".", "setEnd", "(", "locations", ".", "findOffset", "(", "eline", ",", "ecol", ")", "-", "1", ")", ";", "}", "}", "</s>" ]
6,712
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GenericsType", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "InnerClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MixinNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ListExpression", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "public", "class", "EnumHelper", "{", "private", "static", "final", "int", "FS", "=", "Opcodes", ".", "ACC_FINAL", "|", "Opcodes", ".", "ACC_STATIC", ";", "private", "static", "final", "int", "PUBLIC_FS", "=", "Opcodes", ".", "ACC_PUBLIC", "|", "FS", ";", "public", "static", "ClassNode", "makeEnumNode", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "[", "]", "interfaces", ",", "ClassNode", "outerClass", ")", "{", "modifiers", "=", "modifiers", "|", "Opcodes", ".", "ACC_FINAL", "|", "Opcodes", ".", "ACC_ENUM", ";", "ClassNode", "enumClass", ";", "if", "(", "outerClass", "==", "null", ")", "{", "enumClass", "=", "new", "ClassNode", "(", "name", ",", "modifiers", ",", "null", ",", "interfaces", ",", "MixinNode", ".", "EMPTY_ARRAY", ")", ";", "}", "else", "{", "name", "=", "outerClass", ".", "getName", "(", ")", "+", "\"$\"", "+", "name", ";", "enumClass", "=", "new", "InnerClassNode", "(", "outerClass", ",", "name", ",", "modifiers", ",", "null", ",", "interfaces", ",", "MixinNode", ".", "EMPTY_ARRAY", ")", ";", "}", "GenericsType", "gt", "=", "new", "GenericsType", "(", "enumClass", ")", ";", "ClassNode", "superClass", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "\"\"", ")", ";", "superClass", ".", "setGenericsTypes", "(", "new", "GenericsType", "[", "]", "{", "gt", "}", ")", ";", "enumClass", ".", "setSuperClass", "(", "superClass", ")", ";", "superClass", ".", "setRedirect", "(", "ClassHelper", ".", "Enum_Type", ")", ";", "return", "enumClass", ";", "}", "public", "static", "FieldNode", "addEnumConstant", "(", "ClassNode", "enumClass", ",", "String", "name", ",", "Expression", "init", ")", "{", "int", "modifiers", "=", "PUBLIC_FS", "|", "Opcodes", ".", "ACC_ENUM", ";", "if", "(", "init", "!=", "null", "&&", "!", "(", "init", "instanceof", "ListExpression", ")", ")", "{", "ListExpression", "list", "=", "new", "ListExpression", "(", ")", ";", "list", ".", "addExpression", "(", "init", ")", ";", "init", "=", "list", ";", "}", "FieldNode", "fn", "=", "new", "FieldNode", "(", "name", ",", "modifiers", ",", "enumClass", ",", "enumClass", ",", "init", ")", ";", "enumClass", ".", "addField", "(", "fn", ")", ";", "return", "fn", ";", "}", "}", "</s>" ]
6,713
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ParserPlugin", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ParserPluginFactory", ";", "public", "class", "ErrorRecoveredCSTParserPluginFactory", "extends", "ParserPluginFactory", "{", "private", "ICSTReporter", "cstReporter", ";", "public", "ErrorRecoveredCSTParserPluginFactory", "(", "ICSTReporter", "cstReporter", ")", "{", "this", ".", "cstReporter", "=", "cstReporter", ";", "}", "public", "ErrorRecoveredCSTParserPluginFactory", "(", ")", "{", "this", ".", "cstReporter", "=", "null", ";", "}", "public", "ParserPlugin", "createParserPlugin", "(", ")", "{", "return", "new", "ErrorRecoveredCSTParserPlugin", "(", "cstReporter", ")", ";", "}", "}", "</s>" ]
6,714
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "javax", ".", "swing", ".", "text", ".", "BadLocationException", ";", "public", "class", "LocationSupport", "{", "private", "static", "final", "int", "[", "]", "NO_LINE_ENDINGS", "=", "new", "int", "[", "0", "]", ";", "public", "static", "final", "LocationSupport", "NO_LOCATIONS", "=", "new", "LocationSupport", "(", ")", ";", "private", "final", "int", "[", "]", "lineEndings", ";", "public", "LocationSupport", "(", "char", "[", "]", "contents", ")", "{", "if", "(", "contents", "!=", "null", ")", "{", "lineEndings", "=", "processLineEndings", "(", "contents", ")", ";", "}", "else", "{", "lineEndings", "=", "NO_LINE_ENDINGS", ";", "}", "}", "public", "LocationSupport", "(", "List", "<", "StringBuffer", ">", "lines", ")", "{", "if", "(", "lines", "!=", "null", ")", "{", "lineEndings", "=", "processLineEndings", "(", "lines", ")", ";", "}", "else", "{", "lineEndings", "=", "NO_LINE_ENDINGS", ";", "}", "}", "public", "LocationSupport", "(", "int", "[", "]", "lineEndings", ")", "{", "this", ".", "lineEndings", "=", "lineEndings", ";", "}", "public", "LocationSupport", "(", ")", "{", "lineEndings", "=", "NO_LINE_ENDINGS", ";", "}", "private", "int", "[", "]", "processLineEndings", "(", "List", "<", "StringBuffer", ">", "lines", ")", "{", "int", "[", "]", "newLineEndings", "=", "new", "int", "[", "lines", ".", "size", "(", ")", "+", "1", "]", ";", "int", "total", "=", "0", ";", "int", "current", "=", "1", ";", "for", "(", "StringBuffer", "line", ":", "lines", ")", "{", "newLineEndings", "[", "current", "++", "]", "=", "total", "+=", "(", "line", ".", "length", "(", ")", ")", ";", "}", "return", "newLineEndings", ";", "}", "private", "int", "[", "]", "processLineEndings", "(", "char", "[", "]", "contents", ")", "{", "List", "<", "Integer", ">", "l", "=", "new", "ArrayList", "<", "Integer", ">", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "contents", ".", "length", ";", "i", "++", ")", "{", "if", "(", "contents", "[", "i", "]", "==", "'\\n'", ")", "{", "l", ".", "add", "(", "i", ")", ";", "}", "else", "if", "(", "contents", "[", "i", "]", "==", "'\\r'", ")", "{", "l", ".", "add", "(", "i", ")", ";", "if", "(", "i", "<", "contents", ".", "length", "&&", "contents", "[", "i", "]", "==", "'\\n'", ")", "{", "i", "++", ";", "}", "}", "}", "int", "[", "]", "newLineEndings", "=", "new", "int", "[", "l", ".", "size", "(", ")", "]", ";", "int", "i", "=", "0", ";", "for", "(", "Integer", "integer", ":", "l", ")", "{", "newLineEndings", "[", "i", "]", "=", "integer", ".", "intValue", "(", ")", ";", "}", "return", "newLineEndings", ";", "}", "public", "int", "findOffset", "(", "int", "row", ",", "int", "col", ")", "{", "return", "row", "<=", "lineEndings", ".", "length", "&&", "row", ">", "0", "?", "lineEndings", "[", "row", "-", "1", "]", "+", "col", "-", "1", ":", "0", ";", "}", "public", "int", "getEnd", "(", ")", "{", "return", "lineEndings", ".", "length", ">", "0", "?", "lineEndings", "[", "lineEndings", ".", "length", "-", "1", "]", ":", "0", ";", "}", "public", "int", "getEndColumn", "(", ")", "{", "if", "(", "lineEndings", ".", "length", ">", "1", ")", "{", "return", "lineEndings", "[", "lineEndings", ".", "length", "-", "1", "]", "-", "lineEndings", "[", "lineEndings", ".", "length", "-", "2", "]", ";", "}", "else", "if", "(", "lineEndings", ".", "length", ">", "0", ")", "{", "return", "lineEndings", "[", "0", "]", ";", "}", "else", "{", "return", "0", ";", "}", "}", "public", "int", "getEndLine", "(", ")", "{", "return", "lineEndings", ".", "length", ">", "0", "?", "lineEndings", ".", "length", "-", "1", ":", "0", ";", "}", "public", "int", "[", "]", "getRowCol", "(", "int", "offset", ")", "{", "for", "(", "int", "i", "=", "1", ";", "i", "<", "lineEndings", ".", "length", ";", "i", "++", ")", "{", "if", "(", "lineEndings", "[", "i", "]", ">", "offset", ")", "{", "return", "new", "int", "[", "]", "{", "i", ",", "offset", "-", "lineEndings", "[", "i", "-", "1", "]", "+", "1", "}", ";", "}", "}", "throw", "new", "RuntimeException", "(", "\"\"", "+", "offset", ")", ";", "}", "public", "boolean", "isPopulated", "(", ")", "{", "return", "lineEndings", ".", "length", ">", "0", ";", "}", "}", "</s>" ]
6,715
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "GroovySourceAST", ";", "public", "interface", "ICSTReporter", "{", "public", "void", "generatedCST", "(", "String", "fileName", ",", "GroovySourceAST", "ast", ")", ";", "public", "void", "reportErrors", "(", "String", "fileName", ",", "List", "errors", ")", ";", "}", "</s>" ]
6,716
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "public", "class", "GenericsType", "extends", "ASTNode", "{", "protected", "ClassNode", "[", "]", "upperBounds", ";", "protected", "ClassNode", "lowerBound", ";", "protected", "ClassNode", "type", ";", "protected", "String", "name", ";", "protected", "boolean", "placeholder", ";", "private", "boolean", "resolved", ";", "private", "boolean", "wildcard", ";", "public", "GenericsType", "(", "ClassNode", "type", ",", "ClassNode", "[", "]", "upperBounds", ",", "ClassNode", "lowerBound", ")", "{", "this", ".", "type", "=", "type", ";", "this", ".", "name", "=", "type", ".", "isGenericsPlaceHolder", "(", ")", "?", "type", ".", "getUnresolvedName", "(", ")", ":", "type", ".", "getName", "(", ")", ";", "this", ".", "upperBounds", "=", "upperBounds", ";", "this", ".", "lowerBound", "=", "lowerBound", ";", "placeholder", "=", "type", ".", "isGenericsPlaceHolder", "(", ")", ";", "resolved", "=", "false", ";", "}", "public", "GenericsType", "(", ")", "{", "}", "public", "GenericsType", "(", "ClassNode", "basicType", ")", "{", "this", "(", "basicType", ",", "null", ",", "null", ")", ";", "}", "public", "ClassNode", "getType", "(", ")", "{", "return", "type", ";", "}", "public", "void", "setType", "(", "ClassNode", "type", ")", "{", "this", ".", "type", "=", "type", ";", "}", "public", "String", "toString", "(", ")", "{", "String", "ret", "=", "name", ";", "if", "(", "upperBounds", "!=", "null", ")", "{", "ret", "+=", "\"", "extends", "\"", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "upperBounds", ".", "length", ";", "i", "++", ")", "{", "ret", "+=", "upperBounds", "[", "i", "]", ".", "toString", "(", ")", ";", "if", "(", "i", "+", "1", "<", "upperBounds", ".", "length", ")", "ret", "+=", "\"", "&", "\"", ";", "}", "}", "else", "if", "(", "lowerBound", "!=", "null", ")", "{", "ret", "+=", "\"", "super", "\"", "+", "lowerBound", ";", "}", "return", "ret", ";", "}", "public", "ClassNode", "[", "]", "getUpperBounds", "(", ")", "{", "return", "upperBounds", ";", "}", "public", "String", "getName", "(", ")", "{", "return", "name", ";", "}", "public", "boolean", "isPlaceholder", "(", ")", "{", "return", "placeholder", ";", "}", "public", "void", "setPlaceholder", "(", "boolean", "placeholder", ")", "{", "this", ".", "placeholder", "=", "placeholder", ";", "type", ".", "setGenericsPlaceHolder", "(", "true", ")", ";", "}", "public", "boolean", "isResolved", "(", ")", "{", "return", "resolved", "||", "placeholder", ";", "}", "public", "void", "setResolved", "(", "boolean", "res", ")", "{", "resolved", "=", "res", ";", "}", "public", "void", "setName", "(", "String", "name", ")", "{", "this", ".", "name", "=", "name", ";", "}", "public", "boolean", "isWildcard", "(", ")", "{", "return", "wildcard", ";", "}", "public", "void", "setWildcard", "(", "boolean", "wildcard", ")", "{", "this", ".", "wildcard", "=", "wildcard", ";", "}", "public", "ClassNode", "getLowerBound", "(", ")", "{", "return", "lowerBound", ";", "}", "public", "void", "setUpperBounds", "(", "ClassNode", "[", "]", "bounds", ")", "{", "this", ".", "upperBounds", "=", "bounds", ";", "}", "public", "void", "setLowerBound", "(", "ClassNode", "bound", ")", "{", "this", ".", "lowerBound", "=", "bound", ";", "}", "}", "</s>" ]
6,717
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "*", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "*", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "classgen", ".", "BytecodeExpression", ";", "import", "java", ".", "util", ".", "List", ";", "public", "abstract", "class", "CodeVisitorSupport", "implements", "GroovyCodeVisitor", "{", "public", "void", "visitBlockStatement", "(", "BlockStatement", "block", ")", "{", "for", "(", "Statement", "statement", ":", "block", ".", "getStatements", "(", ")", ")", "{", "statement", ".", "visit", "(", "this", ")", ";", "}", "}", "public", "void", "visitForLoop", "(", "ForStatement", "forLoop", ")", "{", "forLoop", ".", "getCollectionExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "forLoop", ".", "getLoopBlock", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitWhileLoop", "(", "WhileStatement", "loop", ")", "{", "loop", ".", "getBooleanExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "loop", ".", "getLoopBlock", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitDoWhileLoop", "(", "DoWhileStatement", "loop", ")", "{", "loop", ".", "getLoopBlock", "(", ")", ".", "visit", "(", "this", ")", ";", "loop", ".", "getBooleanExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitIfElse", "(", "IfStatement", "ifElse", ")", "{", "ifElse", ".", "getBooleanExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "ifElse", ".", "getIfBlock", "(", ")", ".", "visit", "(", "this", ")", ";", "Statement", "elseBlock", "=", "ifElse", ".", "getElseBlock", "(", ")", ";", "if", "(", "elseBlock", "instanceof", "EmptyStatement", ")", "{", "visitEmptyStatement", "(", "(", "EmptyStatement", ")", "elseBlock", ")", ";", "}", "else", "{", "elseBlock", ".", "visit", "(", "this", ")", ";", "}", "}", "public", "void", "visitExpressionStatement", "(", "ExpressionStatement", "statement", ")", "{", "statement", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitReturnStatement", "(", "ReturnStatement", "statement", ")", "{", "statement", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitAssertStatement", "(", "AssertStatement", "statement", ")", "{", "statement", ".", "getBooleanExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "statement", ".", "getMessageExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitTryCatchFinally", "(", "TryCatchStatement", "statement", ")", "{", "statement", ".", "getTryStatement", "(", ")", ".", "visit", "(", "this", ")", ";", "for", "(", "CatchStatement", "catchStatement", ":", "statement", ".", "getCatchStatements", "(", ")", ")", "{", "catchStatement", ".", "visit", "(", "this", ")", ";", "}", "Statement", "finallyStatement", "=", "statement", ".", "getFinallyStatement", "(", ")", ";", "if", "(", "finallyStatement", "instanceof", "EmptyStatement", ")", "{", "visitEmptyStatement", "(", "(", "EmptyStatement", ")", "finallyStatement", ")", ";", "}", "else", "{", "finallyStatement", ".", "visit", "(", "this", ")", ";", "}", "}", "protected", "void", "visitEmptyStatement", "(", "EmptyStatement", "statement", ")", "{", "}", "public", "void", "visitSwitch", "(", "SwitchStatement", "statement", ")", "{", "statement", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "for", "(", "CaseStatement", "caseStatement", ":", "statement", ".", "getCaseStatements", "(", ")", ")", "{", "caseStatement", ".", "visit", "(", "this", ")", ";", "}", "statement", ".", "getDefaultStatement", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitCaseStatement", "(", "CaseStatement", "statement", ")", "{", "statement", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "statement", ".", "getCode", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitBreakStatement", "(", "BreakStatement", "statement", ")", "{", "}", "public", "void", "visitContinueStatement", "(", "ContinueStatement", "statement", ")", "{", "}", "public", "void", "visitSynchronizedStatement", "(", "SynchronizedStatement", "statement", ")", "{", "statement", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "statement", ".", "getCode", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitThrowStatement", "(", "ThrowStatement", "statement", ")", "{", "statement", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitMethodCallExpression", "(", "MethodCallExpression", "call", ")", "{", "call", ".", "getObjectExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "call", ".", "getMethod", "(", ")", ".", "visit", "(", "this", ")", ";", "call", ".", "getArguments", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitStaticMethodCallExpression", "(", "StaticMethodCallExpression", "call", ")", "{", "call", ".", "getArguments", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitConstructorCallExpression", "(", "ConstructorCallExpression", "call", ")", "{", "call", ".", "getArguments", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitBinaryExpression", "(", "BinaryExpression", "expression", ")", "{", "expression", ".", "getLeftExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "expression", ".", "getRightExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitTernaryExpression", "(", "TernaryExpression", "expression", ")", "{", "expression", ".", "getBooleanExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "expression", ".", "getTrueExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "expression", ".", "getFalseExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitShortTernaryExpression", "(", "ElvisOperatorExpression", "expression", ")", "{", "visitTernaryExpression", "(", "expression", ")", ";", "}", "public", "void", "visitPostfixExpression", "(", "PostfixExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitPrefixExpression", "(", "PrefixExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitBooleanExpression", "(", "BooleanExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitNotExpression", "(", "NotExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitClosureExpression", "(", "ClosureExpression", "expression", ")", "{", "expression", ".", "getCode", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitTupleExpression", "(", "TupleExpression", "expression", ")", "{", "visitListOfExpressions", "(", "expression", ".", "getExpressions", "(", ")", ")", ";", "}", "public", "void", "visitListExpression", "(", "ListExpression", "expression", ")", "{", "visitListOfExpressions", "(", "expression", ".", "getExpressions", "(", ")", ")", ";", "}", "public", "void", "visitArrayExpression", "(", "ArrayExpression", "expression", ")", "{", "visitListOfExpressions", "(", "expression", ".", "getExpressions", "(", ")", ")", ";", "visitListOfExpressions", "(", "expression", ".", "getSizeExpression", "(", ")", ")", ";", "}", "public", "void", "visitMapExpression", "(", "MapExpression", "expression", ")", "{", "visitListOfExpressions", "(", "expression", ".", "getMapEntryExpressions", "(", ")", ")", ";", "}", "public", "void", "visitMapEntryExpression", "(", "MapEntryExpression", "expression", ")", "{", "expression", ".", "getKeyExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "expression", ".", "getValueExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitRangeExpression", "(", "RangeExpression", "expression", ")", "{", "expression", ".", "getFrom", "(", ")", ".", "visit", "(", "this", ")", ";", "expression", ".", "getTo", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitSpreadExpression", "(", "SpreadExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitSpreadMapExpression", "(", "SpreadMapExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitMethodPointerExpression", "(", "MethodPointerExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "expression", ".", "getMethodName", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitUnaryMinusExpression", "(", "UnaryMinusExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitUnaryPlusExpression", "(", "UnaryPlusExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitBitwiseNegationExpression", "(", "BitwiseNegationExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitCastExpression", "(", "CastExpression", "expression", ")", "{", "expression", ".", "getExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitConstantExpression", "(", "ConstantExpression", "expression", ")", "{", "}", "public", "void", "visitClassExpression", "(", "ClassExpression", "expression", ")", "{", "}", "public", "void", "visitVariableExpression", "(", "VariableExpression", "expression", ")", "{", "}", "public", "void", "visitDeclarationExpression", "(", "DeclarationExpression", "expression", ")", "{", "visitBinaryExpression", "(", "expression", ")", ";", "}", "public", "void", "visitPropertyExpression", "(", "PropertyExpression", "expression", ")", "{", "expression", ".", "getObjectExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "expression", ".", "getProperty", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitAttributeExpression", "(", "AttributeExpression", "expression", ")", "{", "expression", ".", "getObjectExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "expression", ".", "getProperty", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitFieldExpression", "(", "FieldExpression", "expression", ")", "{", "}", "@", "Deprecated", "public", "void", "visitRegexExpression", "(", "RegexExpression", "expression", ")", "{", "}", "public", "void", "visitGStringExpression", "(", "GStringExpression", "expression", ")", "{", "visitListOfExpressions", "(", "expression", ".", "getStrings", "(", ")", ")", ";", "visitListOfExpressions", "(", "expression", ".", "getValues", "(", ")", ")", ";", "}", "protected", "void", "visitListOfExpressions", "(", "List", "<", "?", "extends", "Expression", ">", "list", ")", "{", "if", "(", "list", "==", "null", ")", "return", ";", "for", "(", "Expression", "expression", ":", "list", ")", "{", "if", "(", "expression", "instanceof", "SpreadExpression", ")", "{", "Expression", "spread", "=", "(", "(", "SpreadExpression", ")", "expression", ")", ".", "getExpression", "(", ")", ";", "spread", ".", "visit", "(", "this", ")", ";", "}", "else", "{", "if", "(", "expression", "!=", "null", ")", "expression", ".", "visit", "(", "this", ")", ";", "}", "}", "}", "public", "void", "visitCatchStatement", "(", "CatchStatement", "statement", ")", "{", "statement", ".", "getCode", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitArgumentlistExpression", "(", "ArgumentListExpression", "ale", ")", "{", "visitTupleExpression", "(", "ale", ")", ";", "}", "public", "void", "visitClosureListExpression", "(", "ClosureListExpression", "cle", ")", "{", "visitListOfExpressions", "(", "cle", ".", "getExpressions", "(", ")", ")", ";", "}", "public", "void", "visitBytecodeExpression", "(", "BytecodeExpression", "cle", ")", "{", "}", "}", "</s>" ]
6,718
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstantExpression", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "public", "class", "ImportNode", "extends", "AnnotatedNode", "implements", "Opcodes", "{", "private", "final", "ClassNode", "type", ";", "private", "final", "String", "alias", ";", "private", "final", "String", "fieldName", ";", "private", "final", "String", "packageName", ";", "private", "final", "boolean", "isStar", ";", "private", "final", "boolean", "isStatic", ";", "public", "ImportNode", "(", "ClassNode", "type", ",", "String", "alias", ")", "{", "this", ".", "type", "=", "type", ";", "this", ".", "alias", "=", "alias", ";", "this", ".", "isStar", "=", "false", ";", "this", ".", "isStatic", "=", "false", ";", "this", ".", "packageName", "=", "null", ";", "this", ".", "fieldName", "=", "null", ";", "}", "public", "ImportNode", "(", "String", "packageName", ")", "{", "this", ".", "type", "=", "null", ";", "this", ".", "alias", "=", "null", ";", "this", ".", "isStar", "=", "true", ";", "this", ".", "isStatic", "=", "false", ";", "this", ".", "packageName", "=", "packageName", ";", "this", ".", "fieldName", "=", "null", ";", "}", "public", "ImportNode", "(", "ClassNode", "type", ")", "{", "this", ".", "type", "=", "type", ";", "this", ".", "alias", "=", "null", ";", "this", ".", "isStar", "=", "true", ";", "this", ".", "isStatic", "=", "true", ";", "this", ".", "packageName", "=", "null", ";", "this", ".", "fieldName", "=", "null", ";", "}", "public", "ImportNode", "(", "ClassNode", "type", ",", "String", "fieldName", ",", "String", "alias", ")", "{", "this", ".", "type", "=", "type", ";", "this", ".", "alias", "=", "alias", ";", "this", ".", "isStar", "=", "false", ";", "this", ".", "isStatic", "=", "true", ";", "this", ".", "packageName", "=", "null", ";", "this", ".", "fieldName", "=", "fieldName", ";", "}", "public", "String", "getText", "(", ")", "{", "String", "typeName", "=", "getClassName", "(", ")", ";", "if", "(", "isStar", "&&", "!", "isStatic", ")", "{", "return", "\"import", "\"", "+", "packageName", "+", "\"*\"", ";", "}", "if", "(", "isStar", ")", "{", "return", "\"\"", "+", "typeName", "+", "\".*\"", ";", "}", "if", "(", "isStatic", ")", "{", "if", "(", "alias", "!=", "null", "&&", "alias", ".", "length", "(", ")", "!=", "0", "&&", "!", "alias", ".", "equals", "(", "fieldName", ")", ")", "{", "return", "\"\"", "+", "typeName", "+", "\".\"", "+", "fieldName", "+", "\"", "as", "\"", "+", "alias", ";", "}", "return", "\"\"", "+", "typeName", "+", "\".\"", "+", "fieldName", ";", "}", "if", "(", "alias", "==", "null", "||", "alias", ".", "length", "(", ")", "==", "0", ")", "{", "return", "\"import", "\"", "+", "typeName", ";", "}", "return", "\"import", "\"", "+", "typeName", "+", "\"", "as", "\"", "+", "alias", ";", "}", "public", "String", "getPackageName", "(", ")", "{", "return", "packageName", ";", "}", "public", "String", "getFieldName", "(", ")", "{", "return", "fieldName", ";", "}", "public", "boolean", "isStar", "(", ")", "{", "return", "isStar", ";", "}", "public", "boolean", "isStatic", "(", ")", "{", "return", "isStatic", ";", "}", "public", "String", "getAlias", "(", ")", "{", "return", "alias", ";", "}", "public", "ClassNode", "getType", "(", ")", "{", "return", "type", ";", "}", "public", "String", "getClassName", "(", ")", "{", "return", "type", "==", "null", "?", "null", ":", "type", ".", "getName", "(", ")", ";", "}", "public", "void", "visit", "(", "GroovyCodeVisitor", "visitor", ")", "{", "}", "private", "boolean", "unresolvable", "=", "false", ";", "private", "ConstantExpression", "aliasExpr", ";", "private", "ConstantExpression", "fieldNameExpr", ";", "public", "ConstantExpression", "getFieldNameExpr", "(", ")", "{", "return", "fieldNameExpr", ";", "}", "public", "void", "setFieldNameExpr", "(", "ConstantExpression", "fieldNameExpr", ")", "{", "this", ".", "fieldNameExpr", "=", "fieldNameExpr", ";", "}", "public", "ConstantExpression", "getAliasExpr", "(", ")", "{", "return", "aliasExpr", ";", "}", "public", "void", "setAliasExpr", "(", "ConstantExpression", "aliasExpr", ")", "{", "this", ".", "aliasExpr", "=", "aliasExpr", ";", "}", "public", "void", "markAsUnresolvable", "(", ")", "{", "unresolvable", "=", "true", ";", "}", "public", "boolean", "isUnresolvable", "(", ")", "{", "return", "unresolvable", ";", "}", "public", "boolean", "isStaticStar", "(", ")", "{", "return", "type", "!=", "null", "&&", "alias", "==", "null", ";", "}", "}", "</s>" ]
6,719
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "public", "class", "PackageNode", "extends", "AnnotatedNode", "{", "private", "final", "String", "packageName", ";", "public", "PackageNode", "(", "String", "packageName", ")", "{", "this", ".", "packageName", "=", "packageName", ";", "}", "public", "String", "getText", "(", ")", "{", "return", "\"package", "\"", "+", "packageName", ";", "}", "public", "String", "getPackageName", "(", ")", "{", "return", "packageName", ";", "}", "public", "void", "visit", "(", "GroovyCodeVisitor", "visitor", ")", "{", "}", "}", "</s>" ]
6,720
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "java", ".", "util", ".", "Comparator", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "SortedSet", ";", "import", "java", ".", "util", ".", "TreeSet", ";", "public", "class", "ImportNodeCompatibilityWrapper", "{", "private", "class", "ImportNodeComparator", "implements", "Comparator", "<", "ImportNode", ">", "{", "public", "int", "compare", "(", "ImportNode", "i1", ",", "ImportNode", "i2", ")", "{", "int", "start1", "=", "i1", ".", "getStart", "(", ")", ";", "if", "(", "start1", "<=", "0", "&&", "i1", ".", "getType", "(", ")", "!=", "null", ")", "{", "start1", "=", "i1", ".", "getType", "(", ")", ".", "getStart", "(", ")", ";", "}", "int", "start2", "=", "i2", ".", "getStart", "(", ")", ";", "if", "(", "start2", "<=", "0", "&&", "i2", ".", "getType", "(", ")", "!=", "null", ")", "{", "start2", "=", "i2", ".", "getType", "(", ")", ".", "getStart", "(", ")", ";", "}", "return", "start1", "-", "start2", ";", "}", "}", "private", "SortedSet", "<", "ImportNode", ">", "sortedImports", ";", "private", "ModuleNode", "module", ";", "public", "ImportNodeCompatibilityWrapper", "(", "ModuleNode", "module", ")", "{", "if", "(", "module", "==", "null", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"\"", ")", ";", "}", "this", ".", "module", "=", "module", ";", "}", "public", "SortedSet", "<", "ImportNode", ">", "getAllImportNodes", "(", ")", "{", "if", "(", "sortedImports", "==", "null", ")", "{", "initialize", "(", ")", ";", "}", "return", "sortedImports", ";", "}", "private", "void", "initialize", "(", ")", "{", "sortedImports", "=", "new", "TreeSet", "<", "ImportNode", ">", "(", "new", "ImportNodeComparator", "(", ")", ")", ";", "sortedImports", ".", "addAll", "(", "module", ".", "getImports", "(", ")", ")", ";", "sortedImports", ".", "addAll", "(", "module", ".", "getStarImports", "(", ")", ")", ";", "sortedImports", ".", "addAll", "(", "module", ".", "getStaticStarImports", "(", ")", ".", "values", "(", ")", ")", ";", "sortedImports", ".", "addAll", "(", "module", ".", "getStaticImports", "(", ")", ".", "values", "(", ")", ")", ";", "}", "public", "static", "String", "getFieldName", "(", "ImportNode", "node", ")", "{", "return", "node", ".", "getFieldName", "(", ")", ";", "}", "public", "static", "Map", "<", "String", ",", "ImportNode", ">", "getStaticImports", "(", "ModuleNode", "node", ")", "{", "return", "node", ".", "getStaticImports", "(", ")", ";", "}", "public", "static", "Map", "<", "String", ",", "ImportNode", ">", "getStaticStarImports", "(", "ModuleNode", "node", ")", "{", "return", "node", ".", "getStaticStarImports", "(", ")", ";", "}", "public", "static", "List", "<", "ImportNode", ">", "getStarImports", "(", "ModuleNode", "node", ")", "{", "return", "node", ".", "getStarImports", "(", ")", ";", "}", "}", "</s>" ]
6,721
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "groovy", ".", "lang", ".", "Binding", ";", "import", "java", ".", "io", ".", "File", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "LinkedHashMap", ";", "import", "java", ".", "util", ".", "LinkedList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ArgumentListExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ClassExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MethodCallExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "VariableExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "BlockStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ExpressionStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "Statement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "InvokerHelper", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "public", "class", "ModuleNode", "extends", "ASTNode", "implements", "Opcodes", "{", "private", "BlockStatement", "statementBlock", "=", "new", "BlockStatement", "(", ")", ";", "List", "<", "ClassNode", ">", "classes", "=", "new", "LinkedList", "<", "ClassNode", ">", "(", ")", ";", "private", "List", "<", "MethodNode", ">", "methods", "=", "new", "ArrayList", "<", "MethodNode", ">", "(", ")", ";", "private", "Map", "<", "String", ",", "ImportNode", ">", "imports", "=", "new", "HashMap", "<", "String", ",", "ImportNode", ">", "(", ")", ";", "private", "List", "<", "ImportNode", ">", "starImports", "=", "new", "ArrayList", "<", "ImportNode", ">", "(", ")", ";", "private", "Map", "<", "String", ",", "ImportNode", ">", "staticImports", "=", "new", "LinkedHashMap", "<", "String", ",", "ImportNode", ">", "(", ")", ";", "private", "Map", "<", "String", ",", "ImportNode", ">", "staticStarImports", "=", "new", "LinkedHashMap", "<", "String", ",", "ImportNode", ">", "(", ")", ";", "private", "CompileUnit", "unit", ";", "private", "PackageNode", "packageNode", ";", "private", "String", "description", ";", "private", "boolean", "createClassForStatements", "=", "true", ";", "private", "transient", "SourceUnit", "context", ";", "private", "boolean", "importsResolved", "=", "false", ";", "private", "ClassNode", "scriptDummy", ";", "private", "String", "mainClassName", "=", "null", ";", "public", "ModuleNode", "(", "SourceUnit", "context", ")", "{", "this", ".", "context", "=", "context", ";", "}", "public", "ModuleNode", "(", "CompileUnit", "unit", ")", "{", "this", ".", "unit", "=", "unit", ";", "}", "public", "BlockStatement", "getStatementBlock", "(", ")", "{", "return", "statementBlock", ";", "}", "public", "List", "<", "MethodNode", ">", "getMethods", "(", ")", "{", "return", "methods", ";", "}", "public", "List", "<", "ClassNode", ">", "getClasses", "(", ")", "{", "if", "(", "createClassForStatements", "&&", "(", "!", "statementBlock", ".", "isEmpty", "(", ")", "||", "!", "methods", ".", "isEmpty", "(", ")", "||", "isPackageInfo", "(", ")", ")", ")", "{", "ClassNode", "mainClass", "=", "createStatementsClass", "(", ")", ";", "mainClassName", "=", "mainClass", ".", "getName", "(", ")", ";", "createClassForStatements", "=", "false", ";", "classes", ".", "add", "(", "0", ",", "mainClass", ")", ";", "mainClass", ".", "setModule", "(", "this", ")", ";", "addToCompileUnit", "(", "mainClass", ")", ";", "}", "return", "classes", ";", "}", "private", "int", "knowIfPackageInfo", "=", "0", ";", "private", "boolean", "encounteredUnrecoverableError", ";", "public", "void", "setEncounteredUnrecoverableError", "(", "boolean", "b", ")", "{", "encounteredUnrecoverableError", "=", "b", ";", "}", "public", "boolean", "encounteredUnrecoverableError", "(", ")", "{", "return", "encounteredUnrecoverableError", ";", "}", "private", "boolean", "isPackageInfo", "(", ")", "{", "if", "(", "knowIfPackageInfo", "==", "0", ")", "{", "if", "(", "context", "!=", "null", "&&", "context", ".", "getName", "(", ")", "!=", "null", "&&", "context", ".", "getName", "(", ")", ".", "endsWith", "(", "\"\"", ")", ")", "{", "knowIfPackageInfo", "=", "1", ";", "}", "else", "{", "knowIfPackageInfo", "=", "2", ";", "}", "}", "return", "knowIfPackageInfo", "==", "1", ";", "}", "public", "List", "<", "ImportNode", ">", "getImports", "(", ")", "{", "return", "new", "ArrayList", "<", "ImportNode", ">", "(", "imports", ".", "values", "(", ")", ")", ";", "}", "@", "Deprecated", "public", "List", "<", "String", ">", "getImportPackages", "(", ")", "{", "List", "<", "String", ">", "result", "=", "new", "ArrayList", "<", "String", ">", "(", ")", ";", "for", "(", "ImportNode", "importStarNode", ":", "starImports", ")", "{", "result", ".", "add", "(", "importStarNode", ".", "getPackageName", "(", ")", ")", ";", "}", "return", "result", ";", "}", "public", "List", "<", "ImportNode", ">", "getStarImports", "(", ")", "{", "return", "starImports", ";", "}", "public", "ClassNode", "getImportType", "(", "String", "alias", ")", "{", "ImportNode", "importNode", "=", "imports", ".", "get", "(", "alias", ")", ";", "return", "importNode", "==", "null", "?", "null", ":", "importNode", ".", "getType", "(", ")", ";", "}", "public", "ImportNode", "getImport", "(", "String", "alias", ")", "{", "return", "imports", ".", "get", "(", "alias", ")", ";", "}", "public", "void", "addImport", "(", "String", "alias", ",", "ClassNode", "type", ")", "{", "addImport", "(", "alias", ",", "type", ",", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ")", ";", "}", "public", "void", "addImport", "(", "String", "alias", ",", "ClassNode", "type", ",", "List", "<", "AnnotationNode", ">", "annotations", ")", "{", "ImportNode", "importNode", "=", "new", "ImportNode", "(", "type", ",", "alias", ")", ";", "if", "(", "type", "!=", "null", ")", "{", "importNode", ".", "setSourcePosition", "(", "type", ")", ";", "importNode", ".", "setColumnNumber", "(", "1", ")", ";", "importNode", ".", "setStart", "(", "type", ".", "getStart", "(", ")", "-", "type", ".", "getColumnNumber", "(", ")", "+", "1", ")", ";", "}", "imports", ".", "put", "(", "alias", ",", "importNode", ")", ";", "importNode", ".", "addAnnotations", "(", "annotations", ")", ";", "}", "@", "Deprecated", "public", "String", "[", "]", "addImportPackage", "(", "String", "packageName", ")", "{", "addStarImport", "(", "packageName", ")", ";", "return", "new", "String", "[", "]", "{", "}", ";", "}", "public", "void", "addStarImport", "(", "String", "packageName", ")", "{", "addStarImport", "(", "packageName", ",", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ")", ";", "}", "public", "void", "addStarImport", "(", "String", "packageName", ",", "List", "<", "AnnotationNode", ">", "annotations", ")", "{", "ImportNode", "importNode", "=", "new", "ImportNode", "(", "packageName", ")", ";", "importNode", ".", "addAnnotations", "(", "annotations", ")", ";", "starImports", ".", "add", "(", "importNode", ")", ";", "}", "public", "void", "addStatement", "(", "Statement", "node", ")", "{", "statementBlock", ".", "addStatement", "(", "node", ")", ";", "}", "public", "void", "addClass", "(", "ClassNode", "node", ")", "{", "if", "(", "classes", ".", "isEmpty", "(", ")", ")", "mainClassName", "=", "node", ".", "getName", "(", ")", ";", "classes", ".", "add", "(", "node", ")", ";", "node", ".", "setModule", "(", "this", ")", ";", "addToCompileUnit", "(", "node", ")", ";", "}", "private", "void", "addToCompileUnit", "(", "ClassNode", "node", ")", "{", "if", "(", "unit", "!=", "null", ")", "{", "unit", ".", "addClass", "(", "node", ")", ";", "}", "}", "public", "void", "addMethod", "(", "MethodNode", "node", ")", "{", "methods", ".", "add", "(", "node", ")", ";", "}", "public", "void", "visit", "(", "GroovyCodeVisitor", "visitor", ")", "{", "}", "public", "String", "getPackageName", "(", ")", "{", "return", "packageNode", "==", "null", "?", "null", ":", "packageNode", ".", "getPackageName", "(", ")", ";", "}", "public", "PackageNode", "getPackage", "(", ")", "{", "return", "packageNode", ";", "}", "public", "void", "setPackage", "(", "PackageNode", "packageNode", ")", "{", "this", ".", "packageNode", "=", "packageNode", ";", "}", "public", "void", "setPackageName", "(", "String", "packageName", ")", "{", "this", ".", "packageNode", "=", "new", "PackageNode", "(", "packageName", ")", ";", "}", "public", "boolean", "hasPackageName", "(", ")", "{", "return", "packageNode", "!=", "null", "&&", "packageNode", ".", "getPackageName", "(", ")", "!=", "null", ";", "}", "public", "boolean", "hasPackage", "(", ")", "{", "return", "this", ".", "packageNode", "!=", "null", ";", "}", "public", "SourceUnit", "getContext", "(", ")", "{", "return", "context", ";", "}", "public", "String", "getDescription", "(", ")", "{", "if", "(", "context", "!=", "null", ")", "{", "return", "context", ".", "getName", "(", ")", ";", "}", "else", "{", "return", "this", ".", "description", ";", "}", "}", "public", "void", "setDescription", "(", "String", "description", ")", "{", "this", ".", "description", "=", "description", ";", "}", "public", "CompileUnit", "getUnit", "(", ")", "{", "return", "unit", ";", "}", "void", "setUnit", "(", "CompileUnit", "unit", ")", "{", "this", ".", "unit", "=", "unit", ";", "}", "public", "ClassNode", "getScriptClassDummy", "(", ")", "{", "if", "(", "scriptDummy", "!=", "null", ")", "{", "setScriptBaseClassFromConfig", "(", "scriptDummy", ")", ";", "return", "scriptDummy", ";", "}", "String", "name", "=", "getPackageName", "(", ")", ";", "if", "(", "name", "==", "null", ")", "{", "name", "=", "\"\"", ";", "}", "if", "(", "getDescription", "(", ")", "==", "null", ")", "{", "throw", "new", "RuntimeException", "(", "\"\"", ")", ";", "}", "name", "+=", "extractClassFromFileDescription", "(", ")", ";", "ClassNode", "classNode", ";", "if", "(", "isPackageInfo", "(", ")", ")", "{", "classNode", "=", "new", "ClassNode", "(", "name", ",", "ACC_ABSTRACT", "|", "ACC_INTERFACE", ",", "ClassHelper", ".", "OBJECT_TYPE", ")", ";", "}", "else", "{", "classNode", "=", "new", "ClassNode", "(", "name", ",", "ACC_PUBLIC", ",", "ClassHelper", ".", "SCRIPT_TYPE", ")", ";", "setScriptBaseClassFromConfig", "(", "classNode", ")", ";", "classNode", ".", "setScript", "(", "true", ")", ";", "classNode", ".", "setScriptBody", "(", "true", ")", ";", "}", "scriptDummy", "=", "classNode", ";", "return", "classNode", ";", "}", "private", "void", "setScriptBaseClassFromConfig", "(", "ClassNode", "cn", ")", "{", "if", "(", "unit", "!=", "null", ")", "{", "String", "baseClassName", "=", "unit", ".", "getConfig", "(", ")", ".", "getScriptBaseClass", "(", ")", ";", "if", "(", "baseClassName", "!=", "null", ")", "{", "if", "(", "!", "cn", ".", "getSuperClass", "(", ")", ".", "getName", "(", ")", ".", "equals", "(", "baseClassName", ")", ")", "{", "cn", ".", "setSuperClass", "(", "ClassHelper", ".", "make", "(", "baseClassName", ")", ")", ";", "}", "}", "}", "}", "protected", "ClassNode", "createStatementsClass", "(", ")", "{", "ClassNode", "classNode", "=", "getScriptClassDummy", "(", ")", ";", "if", "(", "classNode", ".", "getName", "(", ")", ".", "endsWith", "(", "\"package-info\"", ")", ")", "{", "return", "classNode", ";", "}", "handleMainMethodIfPresent", "(", "methods", ")", ";", "classNode", ".", "addMethod", "(", "new", "MethodNode", "(", "\"main\"", ",", "ACC_PUBLIC", "|", "ACC_STATIC", ",", "ClassHelper", ".", "VOID_TYPE", ",", "new", "Parameter", "[", "]", "{", "new", "Parameter", "(", "ClassHelper", ".", "STRING_TYPE", ".", "makeArray", "(", ")", ",", "\"args\"", ")", "}", ",", "ClassNode", ".", "EMPTY_ARRAY", ",", "new", "ExpressionStatement", "(", "new", "MethodCallExpression", "(", "new", "ClassExpression", "(", "ClassHelper", ".", "make", "(", "InvokerHelper", ".", "class", ")", ")", ",", "\"runScript\"", ",", "new", "ArgumentListExpression", "(", "new", "ClassExpression", "(", "classNode", ")", ",", "new", "VariableExpression", "(", "\"args\"", ")", ")", ")", ")", ")", ")", ";", "classNode", ".", "addMethod", "(", "new", "MethodNode", "(", "\"run\"", ",", "ACC_PUBLIC", ",", "ClassHelper", ".", "OBJECT_TYPE", ",", "Parameter", ".", "EMPTY_ARRAY", ",", "ClassNode", ".", "EMPTY_ARRAY", ",", "statementBlock", ")", ")", ";", "classNode", ".", "addConstructor", "(", "ACC_PUBLIC", ",", "Parameter", ".", "EMPTY_ARRAY", ",", "ClassNode", ".", "EMPTY_ARRAY", ",", "new", "BlockStatement", "(", ")", ")", ";", "Statement", "stmt", "=", "new", "ExpressionStatement", "(", "new", "MethodCallExpression", "(", "new", "VariableExpression", "(", "\"super\"", ")", ",", "\"setBinding\"", ",", "new", "ArgumentListExpression", "(", "new", "VariableExpression", "(", "\"context\"", ")", ")", ")", ")", ";", "classNode", ".", "addConstructor", "(", "ACC_PUBLIC", ",", "new", "Parameter", "[", "]", "{", "new", "Parameter", "(", "ClassHelper", ".", "make", "(", "Binding", ".", "class", ")", ",", "\"context\"", ")", "}", ",", "ClassNode", ".", "EMPTY_ARRAY", ",", "stmt", ")", ";", "for", "(", "MethodNode", "node", ":", "methods", ")", "{", "int", "modifiers", "=", "node", ".", "getModifiers", "(", ")", ";", "if", "(", "(", "modifiers", "&", "ACC_ABSTRACT", ")", "!=", "0", ")", "{", "throw", "new", "RuntimeException", "(", "\"\"", "+", "node", ".", "getName", "(", ")", ")", ";", "}", "node", ".", "setModifiers", "(", "modifiers", ")", ";", "classNode", ".", "addMethod", "(", "node", ")", ";", "}", "return", "classNode", ";", "}", "private", "void", "handleMainMethodIfPresent", "(", "List", "methods", ")", "{", "boolean", "found", "=", "false", ";", "for", "(", "Iterator", "iter", "=", "methods", ".", "iterator", "(", ")", ";", "iter", ".", "hasNext", "(", ")", ";", ")", "{", "MethodNode", "node", "=", "(", "MethodNode", ")", "iter", ".", "next", "(", ")", ";", "if", "(", "node", ".", "getName", "(", ")", ".", "equals", "(", "\"main\"", ")", ")", "{", "int", "modifiers", "=", "node", ".", "getModifiers", "(", ")", ";", "if", "(", "node", ".", "isStatic", "(", ")", "&&", "node", ".", "getParameters", "(", ")", ".", "length", "==", "1", ")", "{", "boolean", "retTypeMatches", ",", "argTypeMatches", ";", "ClassNode", "argType", "=", "node", ".", "getParameters", "(", ")", "[", "0", "]", ".", "getType", "(", ")", ";", "ClassNode", "retType", "=", "node", ".", "getReturnType", "(", ")", ";", "argTypeMatches", "=", "(", "argType", ".", "equals", "(", "ClassHelper", ".", "OBJECT_TYPE", ")", "||", "argType", ".", "getName", "(", ")", ".", "contains", "(", "\"String[]\"", ")", ")", ";", "retTypeMatches", "=", "(", "retType", "==", "ClassHelper", ".", "VOID_TYPE", "||", "retType", "==", "ClassHelper", ".", "OBJECT_TYPE", ")", ";", "if", "(", "retTypeMatches", "&&", "argTypeMatches", ")", "{", "if", "(", "found", ")", "{", "throw", "new", "RuntimeException", "(", "\"\"", ")", ";", "}", "else", "{", "found", "=", "true", ";", "}", "if", "(", "statementBlock", ".", "isEmpty", "(", ")", ")", "{", "addStatement", "(", "node", ".", "getCode", "(", ")", ")", ";", "}", "iter", ".", "remove", "(", ")", ";", "}", "}", "}", "}", "}", "protected", "String", "extractClassFromFileDescription", "(", ")", "{", "String", "answer", "=", "getDescription", "(", ")", ";", "int", "slashIdx", "=", "answer", ".", "lastIndexOf", "(", "'/'", ")", ";", "int", "separatorIdx", "=", "answer", ".", "lastIndexOf", "(", "File", ".", "separatorChar", ")", ";", "int", "dotIdx", "=", "answer", ".", "lastIndexOf", "(", "'.'", ")", ";", "if", "(", "dotIdx", ">", "0", "&&", "dotIdx", ">", "Math", ".", "max", "(", "slashIdx", ",", "separatorIdx", ")", ")", "{", "answer", "=", "answer", ".", "substring", "(", "0", ",", "dotIdx", ")", ";", "}", "if", "(", "slashIdx", ">=", "0", ")", "{", "answer", "=", "answer", ".", "substring", "(", "slashIdx", "+", "1", ")", ";", "}", "separatorIdx", "=", "answer", ".", "lastIndexOf", "(", "File", ".", "separatorChar", ")", ";", "if", "(", "separatorIdx", ">=", "0", ")", "{", "answer", "=", "answer", ".", "substring", "(", "separatorIdx", "+", "1", ")", ";", "}", "return", "answer", ";", "}", "public", "boolean", "isEmpty", "(", ")", "{", "return", "classes", ".", "isEmpty", "(", ")", "&&", "statementBlock", ".", "getStatements", "(", ")", ".", "isEmpty", "(", ")", ";", "}", "public", "void", "sortClasses", "(", ")", "{", "if", "(", "isEmpty", "(", ")", ")", "return", ";", "List", "<", "ClassNode", ">", "classes", "=", "getClasses", "(", ")", ";", "LinkedList", "<", "ClassNode", ">", "sorted", "=", "new", "LinkedList", "<", "ClassNode", ">", "(", ")", ";", "int", "level", "=", "1", ";", "while", "(", "!", "classes", ".", "isEmpty", "(", ")", ")", "{", "for", "(", "Iterator", "<", "ClassNode", ">", "cni", "=", "classes", ".", "iterator", "(", ")", ";", "cni", ".", "hasNext", "(", ")", ";", ")", "{", "ClassNode", "cn", "=", "cni", ".", "next", "(", ")", ";", "ClassNode", "sn", "=", "cn", ";", "for", "(", "int", "i", "=", "0", ";", "sn", "!=", "null", "&&", "i", "<", "level", ";", "i", "++", ")", "sn", "=", "sn", ".", "getSuperClass", "(", ")", ";", "if", "(", "sn", "!=", "null", "&&", "sn", ".", "isPrimaryClassNode", "(", ")", ")", "continue", ";", "cni", ".", "remove", "(", ")", ";", "sorted", ".", "addLast", "(", "cn", ")", ";", "}", "level", "++", ";", "}", "this", ".", "classes", "=", "sorted", ";", "}", "public", "boolean", "hasImportsResolved", "(", ")", "{", "return", "importsResolved", ";", "}", "public", "void", "setImportsResolved", "(", "boolean", "importsResolved", ")", "{", "this", ".", "importsResolved", "=", "importsResolved", ";", "}", "@", "Deprecated", "public", "Map", "<", "String", ",", "ClassNode", ">", "getStaticImportAliases", "(", ")", "{", "Map", "<", "String", ",", "ClassNode", ">", "result", "=", "new", "HashMap", "<", "String", ",", "ClassNode", ">", "(", ")", ";", "for", "(", "Map", ".", "Entry", "<", "String", ",", "ImportNode", ">", "entry", ":", "staticImports", ".", "entrySet", "(", ")", ")", "{", "result", ".", "put", "(", "entry", ".", "getKey", "(", ")", ",", "entry", ".", "getValue", "(", ")", ".", "getType", "(", ")", ")", ";", "}", "return", "result", ";", "}", "@", "Deprecated", "public", "Map", "<", "String", ",", "ClassNode", ">", "getStaticImportClasses", "(", ")", "{", "Map", "<", "String", ",", "ClassNode", ">", "result", "=", "new", "HashMap", "<", "String", ",", "ClassNode", ">", "(", ")", ";", "for", "(", "Map", ".", "Entry", "<", "String", ",", "ImportNode", ">", "entry", ":", "staticStarImports", ".", "entrySet", "(", ")", ")", "{", "result", ".", "put", "(", "entry", ".", "getKey", "(", ")", ",", "entry", ".", "getValue", "(", ")", ".", "getType", "(", ")", ")", ";", "}", "return", "result", ";", "}", "@", "Deprecated", "public", "Map", "<", "String", ",", "String", ">", "getStaticImportFields", "(", ")", "{", "Map", "<", "String", ",", "String", ">", "result", "=", "new", "HashMap", "<", "String", ",", "String", ">", "(", ")", ";", "for", "(", "Map", ".", "Entry", "<", "String", ",", "ImportNode", ">", "entry", ":", "staticImports", ".", "entrySet", "(", ")", ")", "{", "result", ".", "put", "(", "entry", ".", "getKey", "(", ")", ",", "entry", ".", "getValue", "(", ")", ".", "getFieldName", "(", ")", ")", ";", "}", "return", "result", ";", "}", "public", "Map", "<", "String", ",", "ImportNode", ">", "getStaticImports", "(", ")", "{", "return", "staticImports", ";", "}", "public", "Map", "<", "String", ",", "ImportNode", ">", "getStaticStarImports", "(", ")", "{", "return", "staticStarImports", ";", "}", "@", "Deprecated", "public", "void", "addStaticMethodOrField", "(", "ClassNode", "type", ",", "String", "fieldName", ",", "String", "alias", ")", "{", "addStaticImport", "(", "type", ",", "fieldName", ",", "alias", ")", ";", "}", "public", "void", "addStaticImport", "(", "ClassNode", "type", ",", "String", "fieldName", ",", "String", "alias", ")", "{", "addStaticImport", "(", "type", ",", "fieldName", ",", "alias", ",", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ")", ";", "}", "public", "void", "addStaticImport", "(", "ClassNode", "type", ",", "String", "fieldName", ",", "String", "alias", ",", "List", "<", "AnnotationNode", ">", "annotations", ")", "{", "ImportNode", "node", "=", "new", "ImportNode", "(", "type", ",", "fieldName", ",", "alias", ")", ";", "node", ".", "addAnnotations", "(", "annotations", ")", ";", "staticImports", ".", "put", "(", "alias", ",", "node", ")", ";", "}", "@", "Deprecated", "public", "void", "addStaticImportClass", "(", "String", "name", ",", "ClassNode", "type", ")", "{", "addStaticStarImport", "(", "name", ",", "type", ")", ";", "}", "public", "void", "addStaticStarImport", "(", "String", "name", ",", "ClassNode", "type", ")", "{", "addStaticStarImport", "(", "name", ",", "type", ",", "new", "ArrayList", "<", "AnnotationNode", ">", "(", ")", ")", ";", "}", "public", "void", "addStaticStarImport", "(", "String", "name", ",", "ClassNode", "type", ",", "List", "<", "AnnotationNode", ">", "annotations", ")", "{", "ImportNode", "node", "=", "new", "ImportNode", "(", "type", ")", ";", "node", ".", "addAnnotations", "(", "annotations", ")", ";", "staticStarImports", ".", "put", "(", "name", ",", "node", ")", ";", "}", "public", "String", "getMainClassName", "(", ")", "{", "return", "mainClassName", ";", "}", "}", "</s>" ]
6,722
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "public", "class", "TaskEntry", "{", "public", "int", "start", ";", "private", "int", "end", ";", "public", "String", "taskTag", ";", "public", "String", "taskPriority", ";", "public", "TaskEntry", "isAdjacentTo", ";", "private", "String", "commentText", ";", "private", "int", "offsetToStartOfCommentTextInFile", ";", "public", "TaskEntry", "(", "int", "startOffset", ",", "int", "endOffset", ",", "String", "taskTag", ",", "String", "taskPriority", ",", "String", "commentText", ",", "int", "offsetToStartOfCommentTextInFile", ")", "{", "this", ".", "start", "=", "startOffset", ";", "this", ".", "end", "=", "endOffset", ";", "this", ".", "taskTag", "=", "taskTag", ";", "this", ".", "taskPriority", "=", "taskPriority", ";", "this", ".", "commentText", "=", "commentText", ";", "this", ".", "offsetToStartOfCommentTextInFile", "=", "offsetToStartOfCommentTextInFile", ";", "}", "public", "int", "getEnd", "(", ")", "{", "if", "(", "isAdjacentTo", "!=", "null", ")", "{", "return", "isAdjacentTo", ".", "getEnd", "(", ")", ";", "}", "return", "end", ";", "}", "public", "void", "setEnd", "(", "int", "end", ")", "{", "this", ".", "end", "=", "end", ";", "}", "public", "String", "getText", "(", ")", "{", "if", "(", "isAdjacentTo", "!=", "null", ")", "{", "return", "isAdjacentTo", ".", "getText", "(", ")", ";", "}", "else", "{", "int", "commentStartIndex", "=", "start", "-", "offsetToStartOfCommentTextInFile", "+", "taskTag", ".", "length", "(", ")", ";", "int", "commentEndIndex", "=", "end", "-", "offsetToStartOfCommentTextInFile", "+", "1", ";", "return", "commentText", ".", "substring", "(", "commentStartIndex", ",", "commentEndIndex", ")", ".", "trim", "(", ")", ";", "}", "}", "public", "String", "toString", "(", ")", "{", "StringBuffer", "task", "=", "new", "StringBuffer", "(", ")", ";", "task", ".", "append", "(", "\"Task:\"", "+", "taskTag", "+", "\"[\"", "+", "getText", "(", ")", "+", "\"]", "\"", "+", "start", "+", "\"", ">", "\"", "+", "end", "+", "\"(\"", "+", "getEnd", "(", ")", "+", "\")\"", ")", ";", "return", "task", ".", "toString", "(", ")", ";", "}", "}", "</s>" ]
6,723
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "public", "class", "ASTNodeCompatibilityWrapper", "{", "private", "ASTNodeCompatibilityWrapper", "(", ")", "{", "}", "public", "static", "ClassNode", "getScriptClassDummy", "(", "ModuleNode", "module", ")", "{", "return", "module", ".", "getScriptClassDummy", "(", ")", ";", "}", "public", "static", "Iterator", "<", "InnerClassNode", ">", "getInnerClasses", "(", "ClassNode", "clazz", ")", "{", "return", "clazz", ".", "getInnerClasses", "(", ")", ";", "}", "}", "</s>" ]
6,724
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GroovyCodeVisitor", ";", "public", "class", "AnnotationConstantExpression", "extends", "ConstantExpression", "{", "public", "AnnotationConstantExpression", "(", "AnnotationNode", "node", ")", "{", "super", "(", "node", ")", ";", "setType", "(", "node", ".", "getClassNode", "(", ")", ")", ";", "}", "public", "void", "visit", "(", "GroovyCodeVisitor", "visitor", ")", "{", "AnnotationNode", "node", "=", "(", "AnnotationNode", ")", "getValue", "(", ")", ";", "Map", "<", "String", ",", "Expression", ">", "attrs", "=", "node", ".", "getMembers", "(", ")", ";", "for", "(", "Expression", "expr", ":", "attrs", ".", "values", "(", ")", ")", "{", "expr", ".", "visit", "(", "visitor", ")", ";", "}", "super", ".", "visit", "(", "visitor", ")", ";", "}", "}", "</s>" ]
6,725
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "BlockStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "Statement", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "import", "java", ".", "util", ".", "List", ";", "public", "class", "MethodNode", "extends", "AnnotatedNode", "implements", "Opcodes", "{", "private", "final", "String", "name", ";", "private", "int", "modifiers", ";", "private", "ClassNode", "returnType", ";", "private", "Parameter", "[", "]", "parameters", ";", "private", "boolean", "hasDefaultValue", "=", "false", ";", "private", "Statement", "code", ";", "private", "boolean", "dynamicReturnType", ";", "private", "VariableScope", "variableScope", ";", "private", "final", "ClassNode", "[", "]", "exceptions", ";", "private", "final", "boolean", "staticConstructor", ";", "private", "GenericsType", "[", "]", "genericsTypes", "=", "null", ";", "private", "boolean", "hasDefault", ";", "String", "typeDescriptor", ";", "public", "MethodNode", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "returnType", ",", "Parameter", "[", "]", "parameters", ",", "ClassNode", "[", "]", "exceptions", ",", "Statement", "code", ")", "{", "this", ".", "name", "=", "name", ";", "this", ".", "modifiers", "=", "modifiers", ";", "this", ".", "code", "=", "code", ";", "setReturnType", "(", "returnType", ")", ";", "VariableScope", "scope", "=", "new", "VariableScope", "(", ")", ";", "setVariableScope", "(", "scope", ")", ";", "setParameters", "(", "parameters", ")", ";", "this", ".", "hasDefault", "=", "false", ";", "this", ".", "exceptions", "=", "exceptions", ";", "this", ".", "staticConstructor", "=", "(", "name", "!=", "null", "&&", "name", ".", "equals", "(", "\"<clinit>\"", ")", ")", ";", "}", "public", "String", "getTypeDescriptor", "(", ")", "{", "if", "(", "typeDescriptor", "==", "null", ")", "{", "StringBuffer", "buf", "=", "new", "StringBuffer", "(", "name", ".", "length", "(", ")", "+", "parameters", ".", "length", "*", "10", ")", ";", "buf", ".", "append", "(", "returnType", ".", "getName", "(", ")", ")", ";", "buf", ".", "append", "(", "'", "'", ")", ";", "buf", ".", "append", "(", "name", ")", ";", "buf", ".", "append", "(", "'('", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "parameters", ".", "length", ";", "i", "++", ")", "{", "if", "(", "i", ">", "0", ")", "{", "buf", ".", "append", "(", "\",", "\"", ")", ";", "}", "Parameter", "param", "=", "parameters", "[", "i", "]", ";", "buf", ".", "append", "(", "param", ".", "getType", "(", ")", ".", "getName", "(", ")", ")", ";", "}", "buf", ".", "append", "(", "')'", ")", ";", "typeDescriptor", "=", "buf", ".", "toString", "(", ")", ";", "}", "return", "typeDescriptor", ";", "}", "private", "void", "invalidateCachedData", "(", ")", "{", "typeDescriptor", "=", "null", ";", "}", "public", "boolean", "isVoidMethod", "(", ")", "{", "return", "returnType", "==", "ClassHelper", ".", "VOID_TYPE", ";", "}", "public", "Statement", "getCode", "(", ")", "{", "return", "code", ";", "}", "public", "void", "setCode", "(", "Statement", "code", ")", "{", "this", ".", "code", "=", "code", ";", "}", "public", "int", "getModifiers", "(", ")", "{", "return", "modifiers", ";", "}", "public", "void", "setModifiers", "(", "int", "modifiers", ")", "{", "invalidateCachedData", "(", ")", ";", "this", ".", "modifiers", "=", "modifiers", ";", "}", "public", "String", "getName", "(", ")", "{", "return", "name", ";", "}", "public", "Parameter", "[", "]", "getParameters", "(", ")", "{", "return", "parameters", ";", "}", "public", "void", "setParameters", "(", "Parameter", "[", "]", "parameters", ")", "{", "invalidateCachedData", "(", ")", ";", "VariableScope", "scope", "=", "new", "VariableScope", "(", ")", ";", "this", ".", "parameters", "=", "parameters", ";", "if", "(", "parameters", "!=", "null", "&&", "parameters", ".", "length", ">", "0", ")", "{", "for", "(", "Parameter", "para", ":", "parameters", ")", "{", "if", "(", "para", ".", "hasInitialExpression", "(", ")", ")", "{", "this", ".", "hasDefaultValue", "=", "true", ";", "}", "para", ".", "setInStaticContext", "(", "isStatic", "(", ")", ")", ";", "scope", ".", "putDeclaredVariable", "(", "para", ")", ";", "}", "}", "setVariableScope", "(", "scope", ")", ";", "}", "public", "ClassNode", "getReturnType", "(", ")", "{", "return", "returnType", ";", "}", "public", "VariableScope", "getVariableScope", "(", ")", "{", "return", "variableScope", ";", "}", "public", "void", "setVariableScope", "(", "VariableScope", "variableScope", ")", "{", "this", ".", "variableScope", "=", "variableScope", ";", "variableScope", ".", "setInStaticContext", "(", "isStatic", "(", ")", ")", ";", "}", "public", "boolean", "isDynamicReturnType", "(", ")", "{", "return", "dynamicReturnType", ";", "}", "public", "boolean", "isAbstract", "(", ")", "{", "return", "(", "modifiers", "&", "ACC_ABSTRACT", ")", "!=", "0", ";", "}", "public", "boolean", "isStatic", "(", ")", "{", "return", "(", "modifiers", "&", "ACC_STATIC", ")", "!=", "0", ";", "}", "public", "boolean", "isPublic", "(", ")", "{", "return", "(", "modifiers", "&", "ACC_PUBLIC", ")", "!=", "0", ";", "}", "public", "boolean", "isPrivate", "(", ")", "{", "return", "(", "modifiers", "&", "ACC_PRIVATE", ")", "!=", "0", ";", "}", "public", "boolean", "isProtected", "(", ")", "{", "return", "(", "modifiers", "&", "ACC_PROTECTED", ")", "!=", "0", ";", "}", "public", "boolean", "hasDefaultValue", "(", ")", "{", "return", "this", ".", "hasDefaultValue", ";", "}", "public", "String", "toString", "(", ")", "{", "return", "\"MethodNode@\"", "+", "hashCode", "(", ")", "+", "\"[\"", "+", "getTypeDescriptor", "(", ")", "+", "\"]\"", ";", "}", "public", "void", "setReturnType", "(", "ClassNode", "returnType", ")", "{", "invalidateCachedData", "(", ")", ";", "dynamicReturnType", "|=", "ClassHelper", ".", "DYNAMIC_TYPE", "==", "returnType", ";", "this", ".", "returnType", "=", "returnType", ";", "if", "(", "returnType", "==", "null", ")", "this", ".", "returnType", "=", "ClassHelper", ".", "OBJECT_TYPE", ";", "}", "public", "ClassNode", "[", "]", "getExceptions", "(", ")", "{", "return", "exceptions", ";", "}", "public", "Statement", "getFirstStatement", "(", ")", "{", "if", "(", "code", "==", "null", ")", "return", "null", ";", "Statement", "first", "=", "code", ";", "while", "(", "first", "instanceof", "BlockStatement", ")", "{", "List", "<", "Statement", ">", "list", "=", "(", "(", "BlockStatement", ")", "first", ")", ".", "getStatements", "(", ")", ";", "if", "(", "list", ".", "isEmpty", "(", ")", ")", "{", "first", "=", "null", ";", "}", "else", "{", "first", "=", "list", ".", "get", "(", "0", ")", ";", "}", "}", "return", "first", ";", "}", "public", "GenericsType", "[", "]", "getGenericsTypes", "(", ")", "{", "return", "genericsTypes", ";", "}", "public", "void", "setGenericsTypes", "(", "GenericsType", "[", "]", "genericsTypes", ")", "{", "invalidateCachedData", "(", ")", ";", "this", ".", "genericsTypes", "=", "genericsTypes", ";", "}", "public", "void", "setAnnotationDefault", "(", "boolean", "b", ")", "{", "this", ".", "hasDefault", "=", "b", ";", "}", "public", "boolean", "hasAnnotationDefault", "(", ")", "{", "return", "hasDefault", ";", "}", "public", "boolean", "isStaticConstructor", "(", ")", "{", "return", "staticConstructor", ";", "}", "private", "MethodNode", "original", "=", "this", ";", "public", "MethodNode", "getOriginal", "(", ")", "{", "return", "original", ";", "}", "public", "void", "setOriginal", "(", "MethodNode", "original", ")", "{", "this", ".", "original", "=", "original", ";", "}", "public", "boolean", "isScriptBody", "(", ")", "{", "return", "getDeclaringClass", "(", ")", "!=", "null", "&&", "getDeclaringClass", "(", ")", ".", "isScript", "(", ")", "&&", "getName", "(", ")", ".", "equals", "(", "\"run\"", ")", "&&", "(", "parameters", "==", "null", "||", "parameters", ".", "length", "==", "0", ")", "&&", "(", "returnType", "!=", "null", "&&", "returnType", ".", "getName", "(", ")", ".", "equals", "(", "\"\"", ")", ")", ";", "}", "}", "</s>" ]
6,726
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "VariableExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "AssertStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "BlockStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "BreakStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "CaseStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "CatchStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ContinueStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "DoWhileStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ExpressionStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ForStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "IfStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ReturnStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "Statement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "SwitchStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "SynchronizedStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ThrowStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "TryCatchStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "WhileStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "messages", ".", "SyntaxErrorMessage", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "SyntaxException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "PreciseSyntaxException", ";", "public", "abstract", "class", "ClassCodeVisitorSupport", "extends", "CodeVisitorSupport", "implements", "GroovyClassVisitor", "{", "public", "void", "visitClass", "(", "ClassNode", "node", ")", "{", "visitAnnotations", "(", "node", ")", ";", "visitPackage", "(", "node", ".", "getPackage", "(", ")", ")", ";", "visitImports", "(", "node", ".", "getModule", "(", ")", ")", ";", "node", ".", "visitContents", "(", "this", ")", ";", "visitObjectInitializerStatements", "(", "node", ")", ";", "}", "protected", "void", "visitObjectInitializerStatements", "(", "ClassNode", "node", ")", "{", "for", "(", "Statement", "element", ":", "node", ".", "getObjectInitializerStatements", "(", ")", ")", "{", "element", ".", "visit", "(", "this", ")", ";", "}", "}", "public", "void", "visitPackage", "(", "PackageNode", "node", ")", "{", "if", "(", "node", "!=", "null", ")", "{", "visitAnnotations", "(", "node", ")", ";", "node", ".", "visit", "(", "this", ")", ";", "}", "}", "public", "void", "visitImports", "(", "ModuleNode", "node", ")", "{", "if", "(", "node", "!=", "null", ")", "{", "for", "(", "ImportNode", "importNode", ":", "node", ".", "getImports", "(", ")", ")", "{", "visitAnnotations", "(", "importNode", ")", ";", "importNode", ".", "visit", "(", "this", ")", ";", "}", "for", "(", "ImportNode", "importStarNode", ":", "node", ".", "getStarImports", "(", ")", ")", "{", "visitAnnotations", "(", "importStarNode", ")", ";", "importStarNode", ".", "visit", "(", "this", ")", ";", "}", "for", "(", "ImportNode", "importStaticNode", ":", "node", ".", "getStaticImports", "(", ")", ".", "values", "(", ")", ")", "{", "visitAnnotations", "(", "importStaticNode", ")", ";", "importStaticNode", ".", "visit", "(", "this", ")", ";", "}", "for", "(", "ImportNode", "importStaticStarNode", ":", "node", ".", "getStaticStarImports", "(", ")", ".", "values", "(", ")", ")", "{", "visitAnnotations", "(", "importStaticStarNode", ")", ";", "importStaticStarNode", ".", "visit", "(", "this", ")", ";", "}", "}", "}", "public", "void", "visitAnnotations", "(", "AnnotatedNode", "node", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "node", ".", "getAnnotations", "(", ")", ";", "if", "(", "annotations", ".", "isEmpty", "(", ")", ")", "return", ";", "for", "(", "AnnotationNode", "an", ":", "annotations", ")", "{", "if", "(", "an", ".", "isBuiltIn", "(", ")", ")", "continue", ";", "for", "(", "Map", ".", "Entry", "<", "String", ",", "Expression", ">", "member", ":", "an", ".", "getMembers", "(", ")", ".", "entrySet", "(", ")", ")", "{", "member", ".", "getValue", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "}", "}", "protected", "void", "visitClassCodeContainer", "(", "Statement", "code", ")", "{", "if", "(", "code", "!=", "null", ")", "code", ".", "visit", "(", "this", ")", ";", "}", "@", "Override", "public", "void", "visitVariableExpression", "(", "VariableExpression", "expression", ")", "{", "visitAnnotations", "(", "expression", ")", ";", "super", ".", "visitVariableExpression", "(", "expression", ")", ";", "}", "protected", "void", "visitConstructorOrMethod", "(", "MethodNode", "node", ",", "boolean", "isConstructor", ")", "{", "visitAnnotations", "(", "node", ")", ";", "visitClassCodeContainer", "(", "node", ".", "getCode", "(", ")", ")", ";", "for", "(", "Parameter", "param", ":", "node", ".", "getParameters", "(", ")", ")", "{", "visitAnnotations", "(", "param", ")", ";", "}", "}", "public", "void", "visitConstructor", "(", "ConstructorNode", "node", ")", "{", "visitConstructorOrMethod", "(", "node", ",", "true", ")", ";", "}", "public", "void", "visitMethod", "(", "MethodNode", "node", ")", "{", "visitConstructorOrMethod", "(", "node", ",", "false", ")", ";", "}", "public", "void", "visitField", "(", "FieldNode", "node", ")", "{", "visitAnnotations", "(", "node", ")", ";", "Expression", "init", "=", "node", ".", "getInitialExpression", "(", ")", ";", "if", "(", "init", "!=", "null", ")", "init", ".", "visit", "(", "this", ")", ";", "}", "public", "void", "visitProperty", "(", "PropertyNode", "node", ")", "{", "visitAnnotations", "(", "node", ")", ";", "Statement", "statement", "=", "node", ".", "getGetterBlock", "(", ")", ";", "visitClassCodeContainer", "(", "statement", ")", ";", "statement", "=", "node", ".", "getSetterBlock", "(", ")", ";", "visitClassCodeContainer", "(", "statement", ")", ";", "Expression", "init", "=", "node", ".", "getInitialExpression", "(", ")", ";", "if", "(", "init", "!=", "null", ")", "init", ".", "visit", "(", "this", ")", ";", "}", "protected", "void", "addError", "(", "String", "msg", ",", "ASTNode", "expr", ")", "{", "int", "line", "=", "expr", ".", "getLineNumber", "(", ")", ";", "int", "col", "=", "expr", ".", "getColumnNumber", "(", ")", ";", "SourceUnit", "source", "=", "getSourceUnit", "(", ")", ";", "source", ".", "getErrorCollector", "(", ")", ".", "addErrorAndContinue", "(", "new", "SyntaxErrorMessage", "(", "new", "SyntaxException", "(", "msg", "+", "'\\n'", ",", "line", ",", "col", ")", ",", "source", ")", ")", ";", "}", "protected", "void", "addTypeError", "(", "String", "msg", ",", "ClassNode", "expr", ")", "{", "int", "line", "=", "expr", ".", "getLineNumber", "(", ")", ";", "int", "col", "=", "expr", ".", "getColumnNumber", "(", ")", ";", "SourceUnit", "source", "=", "getSourceUnit", "(", ")", ";", "source", ".", "getErrorCollector", "(", ")", ".", "addErrorAndContinue", "(", "new", "SyntaxErrorMessage", "(", "new", "PreciseSyntaxException", "(", "msg", "+", "'\\n'", ",", "line", ",", "col", ",", "expr", ".", "getNameStart", "(", ")", ",", "expr", ".", "getNameEnd", "(", ")", ")", ",", "source", ")", ")", ";", "}", "protected", "abstract", "SourceUnit", "getSourceUnit", "(", ")", ";", "protected", "void", "visitStatement", "(", "Statement", "statement", ")", "{", "}", "public", "void", "visitAssertStatement", "(", "AssertStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitAssertStatement", "(", "statement", ")", ";", "}", "public", "void", "visitBlockStatement", "(", "BlockStatement", "block", ")", "{", "visitStatement", "(", "block", ")", ";", "super", ".", "visitBlockStatement", "(", "block", ")", ";", "}", "public", "void", "visitBreakStatement", "(", "BreakStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitBreakStatement", "(", "statement", ")", ";", "}", "public", "void", "visitCaseStatement", "(", "CaseStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitCaseStatement", "(", "statement", ")", ";", "}", "public", "void", "visitCatchStatement", "(", "CatchStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitCatchStatement", "(", "statement", ")", ";", "}", "public", "void", "visitContinueStatement", "(", "ContinueStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitContinueStatement", "(", "statement", ")", ";", "}", "public", "void", "visitDoWhileLoop", "(", "DoWhileStatement", "loop", ")", "{", "visitStatement", "(", "loop", ")", ";", "super", ".", "visitDoWhileLoop", "(", "loop", ")", ";", "}", "public", "void", "visitExpressionStatement", "(", "ExpressionStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitExpressionStatement", "(", "statement", ")", ";", "}", "public", "void", "visitForLoop", "(", "ForStatement", "forLoop", ")", "{", "visitStatement", "(", "forLoop", ")", ";", "super", ".", "visitForLoop", "(", "forLoop", ")", ";", "}", "public", "void", "visitIfElse", "(", "IfStatement", "ifElse", ")", "{", "visitStatement", "(", "ifElse", ")", ";", "super", ".", "visitIfElse", "(", "ifElse", ")", ";", "}", "public", "void", "visitReturnStatement", "(", "ReturnStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitReturnStatement", "(", "statement", ")", ";", "}", "public", "void", "visitSwitch", "(", "SwitchStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitSwitch", "(", "statement", ")", ";", "}", "public", "void", "visitSynchronizedStatement", "(", "SynchronizedStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitSynchronizedStatement", "(", "statement", ")", ";", "}", "public", "void", "visitThrowStatement", "(", "ThrowStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitThrowStatement", "(", "statement", ")", ";", "}", "public", "void", "visitTryCatchFinally", "(", "TryCatchStatement", "statement", ")", "{", "visitStatement", "(", "statement", ")", ";", "super", ".", "visitTryCatchFinally", "(", "statement", ")", ";", "}", "public", "void", "visitWhileLoop", "(", "WhileStatement", "loop", ")", "{", "visitStatement", "(", "loop", ")", ";", "super", ".", "visitWhileLoop", "(", "loop", ")", ";", "}", "}", "</s>" ]
6,727
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "groovy", ".", "lang", ".", "GroovyObject", ";", "import", "java", ".", "lang", ".", "reflect", ".", "Array", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "EnumMap", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "LinkedHashSet", ";", "import", "java", ".", "util", ".", "LinkedList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "ListIterator", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "Set", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "GroovyBugError", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "BinaryExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "FieldExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MapExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "TupleExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "BlockStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ExpressionStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "Statement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilePhase", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "transform", ".", "ASTTransformation", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "transform", ".", "GroovyASTTransformation", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "vmplugin", ".", "VMPluginFactory", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "public", "class", "ClassNode", "extends", "AnnotatedNode", "implements", "Opcodes", "{", "private", "static", "class", "MapOfLists", "{", "private", "Map", "<", "Object", ",", "List", "<", "MethodNode", ">", ">", "map", "=", "new", "HashMap", "<", "Object", ",", "List", "<", "MethodNode", ">", ">", "(", ")", ";", "public", "List", "<", "MethodNode", ">", "get", "(", "Object", "key", ")", "{", "return", "map", ".", "get", "(", "key", ")", ";", "}", "public", "List", "<", "MethodNode", ">", "getNotNull", "(", "Object", "key", ")", "{", "List", "<", "MethodNode", ">", "ret", "=", "get", "(", "key", ")", ";", "if", "(", "ret", "==", "null", ")", "ret", "=", "Collections", ".", "emptyList", "(", ")", ";", "return", "ret", ";", "}", "public", "void", "put", "(", "Object", "key", ",", "MethodNode", "value", ")", "{", "if", "(", "map", ".", "containsKey", "(", "key", ")", ")", "{", "get", "(", "key", ")", ".", "add", "(", "value", ")", ";", "}", "else", "{", "ArrayList", "<", "MethodNode", ">", "list", "=", "new", "ArrayList", "<", "MethodNode", ">", "(", "2", ")", ";", "list", ".", "add", "(", "value", ")", ";", "map", ".", "put", "(", "key", ",", "list", ")", ";", "}", "}", "}", "public", "static", "final", "ClassNode", "[", "]", "EMPTY_ARRAY", "=", "new", "ClassNode", "[", "0", "]", ";", "public", "static", "final", "ClassNode", "THIS", "=", "new", "ClassNode", "(", "Object", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "SUPER", "=", "new", "ClassNode", "(", "Object", ".", "class", ")", ";", "private", "String", "name", ";", "private", "int", "modifiers", ";", "private", "ClassNode", "[", "]", "interfaces", ";", "private", "MixinNode", "[", "]", "mixins", ";", "private", "List", "<", "ConstructorNode", ">", "constructors", ";", "private", "List", "<", "Statement", ">", "objectInitializers", ";", "private", "MapOfLists", "methods", ";", "private", "List", "<", "MethodNode", ">", "methodsList", ";", "private", "LinkedList", "<", "FieldNode", ">", "fields", ";", "private", "List", "<", "PropertyNode", ">", "properties", ";", "private", "Map", "<", "String", ",", "FieldNode", ">", "fieldIndex", ";", "private", "ModuleNode", "module", ";", "private", "CompileUnit", "compileUnit", ";", "private", "boolean", "staticClass", "=", "false", ";", "private", "boolean", "scriptBody", "=", "false", ";", "private", "boolean", "script", ";", "private", "ClassNode", "superClass", ";", "protected", "boolean", "isPrimaryNode", ";", "protected", "List", "<", "InnerClassNode", ">", "innerClasses", ";", "private", "int", "bitflags", "=", "0x0000", ";", "private", "static", "final", "int", "BIT_INCONSISTENT_HIERARCHY", "=", "0x0001", ";", "public", "boolean", "hasInconsistentHierarchy", "(", ")", "{", "return", "(", "(", "redirect", "(", ")", ".", "bitflags", ")", "&", "BIT_INCONSISTENT_HIERARCHY", ")", "!=", "0", ";", "}", "public", "void", "setHasInconsistentHierarchy", "(", "boolean", "b", ")", "{", "ClassNode", "redirect", "=", "redirect", "(", ")", ";", "if", "(", "b", ")", "{", "redirect", ".", "bitflags", "|=", "BIT_INCONSISTENT_HIERARCHY", ";", "}", "else", "{", "redirect", ".", "bitflags", "&=", "~", "BIT_INCONSISTENT_HIERARCHY", ";", "}", "}", "private", "Map", "<", "CompilePhase", ",", "Map", "<", "Class", "<", "?", "extends", "ASTTransformation", ">", ",", "Set", "<", "ASTNode", ">", ">", ">", "transformInstances", ";", "protected", "Object", "lazyInitLock", "=", "new", "Object", "(", ")", ";", "protected", "Class", "clazz", ";", "protected", "boolean", "lazyInitDone", "=", "true", ";", "protected", "ClassNode", "componentType", "=", "null", ";", "private", "ClassNode", "redirect", "=", "null", ";", "private", "boolean", "annotated", ";", "private", "GenericsType", "[", "]", "genericsTypes", "=", "null", ";", "private", "boolean", "usesGenerics", "=", "false", ";", "private", "boolean", "placeholder", ";", "public", "ClassNode", "redirect", "(", ")", "{", "if", "(", "redirect", "==", "null", ")", "return", "this", ";", "return", "redirect", ".", "redirect", "(", ")", ";", "}", "public", "void", "setRedirect", "(", "ClassNode", "cn", ")", "{", "if", "(", "isPrimaryNode", ")", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "getName", "(", ")", "+", "\"->\"", "+", "cn", ".", "getName", "(", ")", "+", "\").\"", ")", ";", "if", "(", "cn", "!=", "null", ")", "cn", "=", "cn", ".", "redirect", "(", ")", ";", "if", "(", "cn", "==", "this", ")", "return", ";", "redirect", "=", "cn", ";", "}", "public", "ClassNode", "makeArray", "(", ")", "{", "if", "(", "redirect", "!=", "null", ")", "{", "ClassNode", "res", "=", "redirect", "(", ")", ".", "makeArray", "(", ")", ";", "res", ".", "componentType", "=", "this", ";", "return", "res", ";", "}", "ClassNode", "cn", ";", "if", "(", "clazz", "!=", "null", ")", "{", "Class", "ret", "=", "Array", ".", "newInstance", "(", "clazz", ",", "0", ")", ".", "getClass", "(", ")", ";", "cn", "=", "new", "ClassNode", "(", "ret", ",", "this", ")", ";", "}", "else", "{", "cn", "=", "new", "ClassNode", "(", "this", ")", ";", "}", "return", "cn", ";", "}", "public", "boolean", "isPrimaryClassNode", "(", ")", "{", "return", "redirect", "(", ")", ".", "isPrimaryNode", "||", "(", "componentType", "!=", "null", "&&", "componentType", ".", "isPrimaryClassNode", "(", ")", ")", ";", "}", "public", "ClassNode", "(", "ClassNode", "componentType", ")", "{", "this", "(", "computeArrayName", "(", "componentType", ")", ",", "ACC_PUBLIC", ",", "ClassHelper", ".", "OBJECT_TYPE", ")", ";", "this", ".", "componentType", "=", "componentType", ".", "redirect", "(", ")", ";", "isPrimaryNode", "=", "false", ";", "}", "public", "static", "String", "computeArrayName", "(", "ClassNode", "componentType", ")", "{", "String", "n", "=", "componentType", ".", "getName", "(", ")", ";", "if", "(", "componentType", ".", "isPrimitive", "(", ")", ")", "{", "int", "len", "=", "n", ".", "length", "(", ")", ";", "if", "(", "len", "==", "7", ")", "{", "return", "\"[Z\"", ";", "}", "else", "if", "(", "len", "==", "6", ")", "{", "return", "\"[D\"", ";", "}", "else", "if", "(", "len", "==", "5", ")", "{", "if", "(", "n", ".", "charAt", "(", "0", ")", "==", "'f'", ")", "{", "return", "\"[F\"", ";", "}", "else", "{", "return", "\"[S\"", ";", "}", "}", "else", "if", "(", "len", "==", "4", ")", "{", "switch", "(", "n", ".", "charAt", "(", "0", ")", ")", "{", "case", "'b'", ":", "return", "\"[B\"", ";", "case", "'c'", ":", "return", "\"[C\"", ";", "default", ":", "return", "\"[J\"", ";", "}", "}", "else", "{", "return", "\"[I\"", ";", "}", "}", "else", "if", "(", "componentType", ".", "isArray", "(", ")", ")", "{", "if", "(", "n", ".", "charAt", "(", "0", ")", "==", "'['", ")", "{", "return", "new", "StringBuilder", "(", "\"[\"", ")", ".", "append", "(", "n", ")", ".", "toString", "(", ")", ";", "}", "else", "{", "return", "new", "StringBuilder", "(", "n", ")", ".", "append", "(", "\"[]\"", ")", ".", "toString", "(", ")", ";", "}", "}", "else", "{", "return", "new", "StringBuilder", "(", "\"[L\"", ")", ".", "append", "(", "componentType", ".", "getName", "(", ")", ")", ".", "append", "(", "\";\"", ")", ".", "toString", "(", ")", ";", "}", "}", "private", "ClassNode", "(", "Class", "c", ",", "ClassNode", "componentType", ")", "{", "this", "(", "c", ")", ";", "this", ".", "componentType", "=", "componentType", ";", "isPrimaryNode", "=", "false", ";", "}", "public", "ClassNode", "(", "Class", "c", ")", "{", "this", "(", "c", ".", "getName", "(", ")", ",", "c", ".", "getModifiers", "(", ")", ",", "null", ",", "null", ",", "MixinNode", ".", "EMPTY_ARRAY", ")", ";", "clazz", "=", "c", ";", "lazyInitDone", "=", "false", ";", "CompileUnit", "cu", "=", "getCompileUnit", "(", ")", ";", "if", "(", "cu", "!=", "null", ")", "cu", ".", "addClass", "(", "this", ")", ";", "isPrimaryNode", "=", "false", ";", "}", "public", "void", "lazyClassInit", "(", ")", "{", "synchronized", "(", "lazyInitLock", ")", "{", "if", "(", "redirect", "!=", "null", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "\"\"", ")", ";", "}", "if", "(", "lazyInitDone", ")", "return", ";", "VMPluginFactory", ".", "getPlugin", "(", ")", ".", "configureClassNode", "(", "compileUnit", ",", "this", ")", ";", "lazyInitDone", "=", "true", ";", "}", "}", "private", "MethodNode", "enclosingMethod", "=", "null", ";", "public", "MethodNode", "getEnclosingMethod", "(", ")", "{", "return", "redirect", "(", ")", ".", "enclosingMethod", ";", "}", "public", "void", "setEnclosingMethod", "(", "MethodNode", "enclosingMethod", ")", "{", "redirect", "(", ")", ".", "enclosingMethod", "=", "enclosingMethod", ";", "}", "public", "ClassNode", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "superClass", ")", "{", "this", "(", "name", ",", "modifiers", ",", "superClass", ",", "EMPTY_ARRAY", ",", "MixinNode", ".", "EMPTY_ARRAY", ")", ";", "}", "public", "ClassNode", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "superClass", ",", "ClassNode", "[", "]", "interfaces", ",", "MixinNode", "[", "]", "mixins", ")", "{", "this", ".", "name", "=", "name", ";", "this", ".", "modifiers", "=", "modifiers", ";", "this", ".", "superClass", "=", "superClass", ";", "this", ".", "interfaces", "=", "interfaces", ";", "this", ".", "mixins", "=", "mixins", ";", "isPrimaryNode", "=", "true", ";", "if", "(", "superClass", "!=", "null", ")", "{", "usesGenerics", "=", "superClass", ".", "isUsingGenerics", "(", ")", ";", "}", "if", "(", "!", "usesGenerics", "&&", "interfaces", "!=", "null", ")", "{", "for", "(", "ClassNode", "anInterface", ":", "interfaces", ")", "{", "usesGenerics", "=", "usesGenerics", "||", "anInterface", ".", "isUsingGenerics", "(", ")", ";", "}", "}", "this", ".", "methods", "=", "new", "MapOfLists", "(", ")", ";", "this", ".", "methodsList", "=", "new", "ArrayList", "<", "MethodNode", ">", "(", ")", ";", "}", "public", "void", "setSuperClass", "(", "ClassNode", "superClass", ")", "{", "redirect", "(", ")", ".", "superClass", "=", "superClass", ";", "}", "public", "List", "<", "FieldNode", ">", "getFields", "(", ")", "{", "if", "(", "!", "redirect", "(", ")", ".", "lazyInitDone", ")", "redirect", "(", ")", ".", "lazyClassInit", "(", ")", ";", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", "(", ")", ".", "getFields", "(", ")", ";", "if", "(", "fields", "==", "null", ")", "fields", "=", "new", "LinkedList", "<", "FieldNode", ">", "(", ")", ";", "return", "fields", ";", "}", "public", "ClassNode", "[", "]", "getInterfaces", "(", ")", "{", "if", "(", "!", "redirect", "(", ")", ".", "lazyInitDone", ")", "redirect", "(", ")", ".", "lazyClassInit", "(", ")", ";", "if", "(", "hasInconsistentHierarchy", "(", ")", ")", "{", "return", "EMPTY_ARRAY", ";", "}", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", "(", ")", ".", "getInterfaces", "(", ")", ";", "return", "interfaces", ";", "}", "public", "void", "setInterfaces", "(", "ClassNode", "[", "]", "interfaces", ")", "{", "if", "(", "redirect", "!=", "null", ")", "{", "redirect", "(", ")", ".", "setInterfaces", "(", "interfaces", ")", ";", "}", "else", "{", "this", ".", "interfaces", "=", "interfaces", ";", "}", "}", "public", "MixinNode", "[", "]", "getMixins", "(", ")", "{", "return", "redirect", "(", ")", ".", "mixins", ";", "}", "public", "List", "<", "MethodNode", ">", "getMethods", "(", ")", "{", "if", "(", "!", "redirect", "(", ")", ".", "lazyInitDone", ")", "redirect", "(", ")", ".", "lazyClassInit", "(", ")", ";", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", "(", ")", ".", "getMethods", "(", ")", ";", "return", "methodsList", ";", "}", "public", "List", "<", "MethodNode", ">", "getAbstractMethods", "(", ")", "{", "List", "<", "MethodNode", ">", "result", "=", "new", "ArrayList", "<", "MethodNode", ">", "(", "3", ")", ";", "for", "(", "MethodNode", "method", ":", "getDeclaredMethodsMap", "(", ")", ".", "values", "(", ")", ")", "{", "if", "(", "method", ".", "isAbstract", "(", ")", ")", "{", "result", ".", "add", "(", "method", ")", ";", "}", "}", "if", "(", "result", ".", "isEmpty", "(", ")", ")", "{", "return", "null", ";", "}", "else", "{", "return", "result", ";", "}", "}", "public", "List", "<", "MethodNode", ">", "getAllDeclaredMethods", "(", ")", "{", "return", "new", "ArrayList", "<", "MethodNode", ">", "(", "getDeclaredMethodsMap", "(", ")", ".", "values", "(", ")", ")", ";", "}", "public", "Set", "<", "ClassNode", ">", "getAllInterfaces", "(", ")", "{", "Set", "<", "ClassNode", ">", "res", "=", "new", "HashSet", "<", "ClassNode", ">", "(", ")", ";", "getAllInterfaces", "(", "res", ")", ";", "return", "res", ";", "}", "private", "void", "getAllInterfaces", "(", "Set", "<", "ClassNode", ">", "res", ")", "{", "if", "(", "isInterface", "(", ")", ")", "res", ".", "add", "(", "this", ")", ";", "for", "(", "ClassNode", "anInterface", ":", "getInterfaces", "(", ")", ")", "{", "res", ".", "add", "(", "anInterface", ")", ";", "anInterface", ".", "getAllInterfaces", "(", "res", ")", ";", "}", "}", "public", "Map", "<", "String", ",", "MethodNode", ">", "getDeclaredMethodsMap", "(", ")", "{", "ClassNode", "parent", "=", "getSuperClass", "(", ")", ";", "Map", "<", "String", ",", "MethodNode", ">", "result", "=", "null", ";", "if", "(", "parent", "!=", "null", ")", "{", "result", "=", "parent", ".", "getDeclaredMethodsMap", "(", ")", ";", "}", "else", "{", "result", "=", "new", "HashMap", "<", "String", ",", "MethodNode", ">", "(", ")", ";", "}", "for", "(", "ClassNode", "iface", ":", "getInterfaces", "(", ")", ")", "{", "Map", "<", "String", ",", "MethodNode", ">", "ifaceMethodsMap", "=", "iface", ".", "getDeclaredMethodsMap", "(", ")", ";", "for", "(", "String", "methSig", ":", "ifaceMethodsMap", ".", "keySet", "(", ")", ")", "{", "if", "(", "!", "result", ".", "containsKey", "(", "methSig", ")", ")", "{", "MethodNode", "methNode", "=", "ifaceMethodsMap", ".", "get", "(", "methSig", ")", ";", "result", ".", "put", "(", "methSig", ",", "methNode", ")", ";", "}", "}", "}", "for", "(", "MethodNode", "method", ":", "getMethods", "(", ")", ")", "{", "String", "sig", "=", "method", ".", "getTypeDescriptor", "(", ")", ";", "result", ".", "put", "(", "sig", ",", "method", ")", ";", "}", "return", "result", ";", "}", "public", "String", "getName", "(", ")", "{", "return", "redirect", "(", ")", ".", "name", ";", "}", "public", "String", "getUnresolvedName", "(", ")", "{", "return", "name", ";", "}", "public", "String", "setName", "(", "String", "name", ")", "{", "return", "redirect", "(", ")", ".", "name", "=", "name", ";", "}", "public", "int", "getModifiers", "(", ")", "{", "return", "redirect", "(", ")", ".", "modifiers", ";", "}", "public", "void", "setModifiers", "(", "int", "modifiers", ")", "{", "redirect", "(", ")", ".", "modifiers", "=", "modifiers", ";", "}", "protected", "void", "ensurePropertiesInitialized", "(", ")", "{", "}", "public", "List", "<", "PropertyNode", ">", "getProperties", "(", ")", "{", "redirect", "(", ")", ".", "ensurePropertiesInitialized", "(", ")", ";", "final", "ClassNode", "r", "=", "redirect", "(", ")", ";", "if", "(", "r", ".", "properties", "==", "null", ")", "r", ".", "properties", "=", "new", "ArrayList", "<", "PropertyNode", ">", "(", ")", ";", "return", "r", ".", "properties", ";", "}", "public", "List", "<", "ConstructorNode", ">", "getDeclaredConstructors", "(", ")", "{", "if", "(", "!", "redirect", "(", ")", ".", "lazyInitDone", ")", "redirect", "(", ")", ".", "lazyClassInit", "(", ")", ";", "final", "ClassNode", "r", "=", "redirect", "(", ")", ";", "if", "(", "r", ".", "constructors", "==", "null", ")", "r", ".", "constructors", "=", "new", "ArrayList", "<", "ConstructorNode", ">", "(", ")", ";", "return", "r", ".", "constructors", ";", "}", "public", "ModuleNode", "getModule", "(", ")", "{", "return", "redirect", "(", ")", ".", "module", ";", "}", "public", "PackageNode", "getPackage", "(", ")", "{", "return", "getModule", "(", ")", "==", "null", "?", "null", ":", "getModule", "(", ")", ".", "getPackage", "(", ")", ";", "}", "public", "void", "setModule", "(", "ModuleNode", "module", ")", "{", "redirect", "(", ")", ".", "module", "=", "module", ";", "if", "(", "module", "!=", "null", ")", "{", "redirect", "(", ")", ".", "compileUnit", "=", "module", ".", "getUnit", "(", ")", ";", "}", "}", "public", "void", "addField", "(", "FieldNode", "node", ")", "{", "final", "ClassNode", "r", "=", "redirect", "(", ")", ";", "node", ".", "setDeclaringClass", "(", "r", ")", ";", "node", ".", "setOwner", "(", "r", ")", ";", "if", "(", "r", ".", "fields", "==", "null", ")", "r", ".", "fields", "=", "new", "LinkedList", "<", "FieldNode", ">", "(", ")", ";", "if", "(", "r", ".", "fieldIndex", "==", "null", ")", "r", ".", "fieldIndex", "=", "new", "HashMap", "<", "String", ",", "FieldNode", ">", "(", ")", ";", "r", ".", "fields", ".", "add", "(", "node", ")", ";", "r", ".", "fieldIndex", ".", "put", "(", "node", ".", "getName", "(", ")", ",", "node", ")", ";", "}", "public", "void", "addFieldFirst", "(", "FieldNode", "node", ")", "{", "final", "ClassNode", "r", "=", "redirect", "(", ")", ";", "node", ".", "setDeclaringClass", "(", "r", ")", ";", "node", ".", "setOwner", "(", "r", ")", ";", "if", "(", "r", ".", "fields", "==", "null", ")", "r", ".", "fields", "=", "new", "LinkedList", "<", "FieldNode", ">", "(", ")", ";", "if", "(", "r", ".", "fieldIndex", "==", "null", ")", "r", ".", "fieldIndex", "=", "new", "HashMap", "<", "String", ",", "FieldNode", ">", "(", ")", ";", "r", ".", "fields", ".", "addFirst", "(", "node", ")", ";", "r", ".", "fieldIndex", ".", "put", "(", "node", ".", "getName", "(", ")", ",", "node", ")", ";", "}", "public", "boolean", "isRedirectNode", "(", ")", "{", "return", "redirect", "!=", "null", ";", "}", "public", "void", "addPropertyWithoutField", "(", "PropertyNode", "node", ")", "{", "node", ".", "setDeclaringClass", "(", "redirect", "(", ")", ")", ";", "final", "ClassNode", "r", "=", "redirect", "(", ")", ";", "if", "(", "r", ".", "properties", "==", "null", ")", "r", ".", "properties", "=", "new", "ArrayList", "<", "PropertyNode", ">", "(", ")", ";", "r", ".", "properties", ".", "add", "(", "node", ")", ";", "}", "public", "void", "addProperty", "(", "PropertyNode", "node", ")", "{", "node", ".", "setDeclaringClass", "(", "redirect", "(", ")", ")", ";", "FieldNode", "field", "=", "node", ".", "getField", "(", ")", ";", "addField", "(", "field", ")", ";", "final", "ClassNode", "r", "=", "redirect", "(", ")", ";", "if", "(", "r", ".", "properties", "==", "null", ")", "r", ".", "properties", "=", "new", "ArrayList", "<", "PropertyNode", ">", "(", ")", ";", "r", ".", "properties", ".", "add", "(", "node", ")", ";", "}", "public", "PropertyNode", "addProperty", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "type", ",", "Expression", "initialValueExpression", ",", "Statement", "getterBlock", ",", "Statement", "setterBlock", ")", "{", "for", "(", "PropertyNode", "pn", ":", "getProperties", "(", ")", ")", "{", "if", "(", "pn", ".", "getName", "(", ")", ".", "equals", "(", "name", ")", ")", "{", "if", "(", "pn", ".", "getInitialExpression", "(", ")", "==", "null", "&&", "initialValueExpression", "!=", "null", ")", "pn", ".", "getField", "(", ")", ".", "setInitialValueExpression", "(", "initialValueExpression", ")", ";", "if", "(", "pn", ".", "getGetterBlock", "(", ")", "==", "null", "&&", "getterBlock", "!=", "null", ")", "pn", ".", "setGetterBlock", "(", "getterBlock", ")", ";", "if", "(", "pn", ".", "getSetterBlock", "(", ")", "==", "null", "&&", "setterBlock", "!=", "null", ")", "pn", ".", "setSetterBlock", "(", "setterBlock", ")", ";", "return", "pn", ";", "}", "}", "PropertyNode", "node", "=", "new", "PropertyNode", "(", "name", ",", "modifiers", ",", "type", ",", "redirect", "(", ")", ",", "initialValueExpression", ",", "getterBlock", ",", "setterBlock", ")", ";", "addProperty", "(", "node", ")", ";", "return", "node", ";", "}", "public", "boolean", "hasProperty", "(", "String", "name", ")", "{", "return", "getProperty", "(", "name", ")", "!=", "null", ";", "}", "public", "PropertyNode", "getProperty", "(", "String", "name", ")", "{", "try", "{", "for", "(", "PropertyNode", "pn", ":", "getProperties", "(", ")", ")", "{", "String", "pname", "=", "pn", ".", "getName", "(", ")", ";", "if", "(", "pname", ".", "equals", "(", "name", ")", ")", "return", "pn", ";", "}", "}", "catch", "(", "NullPointerException", "npe", ")", "{", "throw", "new", "RuntimeException", "(", "\"\"", "+", "this", ".", "getName", "(", ")", "+", "\"", "props", "are", "\"", "+", "getProperties", "(", ")", ",", "npe", ")", ";", "}", "return", "null", ";", "}", "public", "void", "addConstructor", "(", "ConstructorNode", "node", ")", "{", "node", ".", "setDeclaringClass", "(", "this", ")", ";", "final", "ClassNode", "r", "=", "redirect", "(", ")", ";", "if", "(", "r", ".", "constructors", "==", "null", ")", "r", ".", "constructors", "=", "new", "ArrayList", "<", "ConstructorNode", ">", "(", ")", ";", "r", ".", "constructors", ".", "add", "(", "node", ")", ";", "}", "public", "ConstructorNode", "addConstructor", "(", "int", "modifiers", ",", "Parameter", "[", "]", "parameters", ",", "ClassNode", "[", "]", "exceptions", ",", "Statement", "code", ")", "{", "ConstructorNode", "node", "=", "new", "ConstructorNode", "(", "modifiers", ",", "parameters", ",", "exceptions", ",", "code", ")", ";", "addConstructor", "(", "node", ")", ";", "return", "node", ";", "}", "public", "void", "addMethod", "(", "MethodNode", "node", ")", "{", "node", ".", "setDeclaringClass", "(", "this", ")", ";", "ClassNode", "redirect", "=", "redirect", "(", ")", ";", "redirect", ".", "methodsList", ".", "add", "(", "node", ")", ";", "redirect", ".", "methods", ".", "put", "(", "node", ".", "getName", "(", ")", ",", "node", ")", ";", "}", "public", "MethodNode", "addMethod", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "returnType", ",", "Parameter", "[", "]", "parameters", ",", "ClassNode", "[", "]", "exceptions", ",", "Statement", "code", ")", "{", "MethodNode", "other", "=", "getDeclaredMethod", "(", "name", ",", "parameters", ")", ";", "if", "(", "other", "!=", "null", ")", "{", "return", "other", ";", "}", "MethodNode", "node", "=", "new", "MethodNode", "(", "name", ",", "modifiers", ",", "returnType", ",", "parameters", ",", "exceptions", ",", "code", ")", ";", "addMethod", "(", "node", ")", ";", "return", "node", ";", "}", "public", "boolean", "hasDeclaredMethod", "(", "String", "name", ",", "Parameter", "[", "]", "parameters", ")", "{", "MethodNode", "other", "=", "getDeclaredMethod", "(", "name", ",", "parameters", ")", ";", "return", "other", "!=", "null", ";", "}", "public", "boolean", "hasMethod", "(", "String", "name", ",", "Parameter", "[", "]", "parameters", ")", "{", "MethodNode", "other", "=", "getMethod", "(", "name", ",", "parameters", ")", ";", "return", "other", "!=", "null", ";", "}", "public", "MethodNode", "addSyntheticMethod", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "returnType", ",", "Parameter", "[", "]", "parameters", ",", "ClassNode", "[", "]", "exceptions", ",", "Statement", "code", ")", "{", "MethodNode", "answer", "=", "addMethod", "(", "name", ",", "modifiers", "|", "ACC_SYNTHETIC", ",", "returnType", ",", "parameters", ",", "exceptions", ",", "code", ")", ";", "answer", ".", "setSynthetic", "(", "true", ")", ";", "return", "answer", ";", "}", "public", "FieldNode", "addField", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "type", ",", "Expression", "initialValue", ")", "{", "FieldNode", "node", "=", "new", "FieldNode", "(", "name", ",", "modifiers", ",", "type", ",", "redirect", "(", ")", ",", "initialValue", ")", ";", "addField", "(", "node", ")", ";", "return", "node", ";", "}", "public", "FieldNode", "addFieldFirst", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "type", ",", "Expression", "initialValue", ")", "{", "FieldNode", "node", "=", "new", "FieldNode", "(", "name", ",", "modifiers", ",", "type", ",", "redirect", "(", ")", ",", "initialValue", ")", ";", "addFieldFirst", "(", "node", ")", ";", "return", "node", ";", "}", "public", "void", "addInterface", "(", "ClassNode", "type", ")", "{", "boolean", "skip", "=", "false", ";", "ClassNode", "[", "]", "interfaces", "=", "redirect", "(", ")", ".", "interfaces", ";", "for", "(", "ClassNode", "existing", ":", "interfaces", ")", "{", "if", "(", "type", ".", "equals", "(", "existing", ")", ")", "{", "skip", "=", "true", ";", "}", "}", "if", "(", "!", "skip", ")", "{", "ClassNode", "[", "]", "newInterfaces", "=", "new", "ClassNode", "[", "interfaces", ".", "length", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "interfaces", ",", "0", ",", "newInterfaces", ",", "0", ",", "interfaces", ".", "length", ")", ";", "newInterfaces", "[", "interfaces", ".", "length", "]", "=", "type", ";", "redirect", "(", ")", ".", "interfaces", "=", "newInterfaces", ";", "}", "}", "public", "boolean", "equals", "(", "Object", "o", ")", "{", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", "(", ")", ".", "equals", "(", "o", ")", ";", "ClassNode", "cn", "=", "(", "ClassNode", ")", "o", ";", "return", "(", "cn", ".", "getName", "(", ")", ".", "equals", "(", "getName", "(", ")", ")", ")", ";", "}", "public", "int", "hashCode", "(", ")", "{", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", "(", ")", ".", "hashCode", "(", ")", ";", "return", "getName", "(", ")", ".", "hashCode", "(", ")", ";", "}", "public", "void", "addMixin", "(", "MixinNode", "mixin", ")", "{", "MixinNode", "[", "]", "mixins", "=", "redirect", "(", ")", ".", "mixins", ";", "boolean", "skip", "=", "false", ";", "for", "(", "MixinNode", "existing", ":", "mixins", ")", "{", "if", "(", "mixin", ".", "equals", "(", "existing", ")", ")", "{", "skip", "=", "true", ";", "}", "}", "if", "(", "!", "skip", ")", "{", "MixinNode", "[", "]", "newMixins", "=", "new", "MixinNode", "[", "mixins", ".", "length", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "mixins", ",", "0", ",", "newMixins", ",", "0", ",", "mixins", ".", "length", ")", ";", "newMixins", "[", "mixins", ".", "length", "]", "=", "mixin", ";", "redirect", "(", ")", ".", "mixins", "=", "newMixins", ";", "}", "}", "public", "FieldNode", "getDeclaredField", "(", "String", "name", ")", "{", "if", "(", "!", "redirect", "(", ")", ".", "lazyInitDone", ")", "redirect", "(", ")", ".", "lazyClassInit", "(", ")", ";", "ClassNode", "r", "=", "redirect", "(", ")", ";", "if", "(", "r", ".", "fieldIndex", "==", "null", ")", "r", ".", "fieldIndex", "=", "new", "HashMap", "<", "String", ",", "FieldNode", ">", "(", ")", ";", "return", "r", ".", "fieldIndex", ".", "get", "(", "name", ")", ";", "}", "public", "FieldNode", "getField", "(", "String", "name", ")", "{", "ClassNode", "node", "=", "this", ";", "while", "(", "node", "!=", "null", ")", "{", "FieldNode", "fn", "=", "node", ".", "getDeclaredField", "(", "name", ")", ";", "if", "(", "fn", "!=", "null", ")", "return", "fn", ";", "node", "=", "node", ".", "getSuperClass", "(", ")", ";", "}", "return", "null", ";", "}", "public", "FieldNode", "getOuterField", "(", "String", "name", ")", "{", "return", "null", ";", "}", "public", "ClassNode", "getOuterClass", "(", ")", "{", "return", "null", ";", "}", "public", "void", "addObjectInitializerStatements", "(", "Statement", "statements", ")", "{", "getObjectInitializerStatements", "(", ")", ".", "add", "(", "statements", ")", ";", "}", "public", "List", "<", "Statement", ">", "getObjectInitializerStatements", "(", ")", "{", "if", "(", "objectInitializers", "==", "null", ")", "objectInitializers", "=", "new", "ArrayList", "<", "Statement", ">", "(", ")", ";", "return", "objectInitializers", ";", "}", "private", "MethodNode", "getOrAddStaticConstructorNode", "(", ")", "{", "MethodNode", "method", "=", "null", ";", "List", "declaredMethods", "=", "getDeclaredMethods", "(", "\"<clinit>\"", ")", ";", "if", "(", "declaredMethods", ".", "isEmpty", "(", ")", ")", "{", "method", "=", "addMethod", "(", "\"<clinit>\"", ",", "ACC_STATIC", ",", "ClassHelper", ".", "VOID_TYPE", ",", "Parameter", ".", "EMPTY_ARRAY", ",", "ClassNode", ".", "EMPTY_ARRAY", ",", "new", "BlockStatement", "(", ")", ")", ";", "method", ".", "setSynthetic", "(", "true", ")", ";", "}", "else", "{", "method", "=", "(", "MethodNode", ")", "declaredMethods", ".", "get", "(", "0", ")", ";", "}", "return", "method", ";", "}", "public", "void", "addStaticInitializerStatements", "(", "List", "<", "Statement", ">", "staticStatements", ",", "boolean", "fieldInit", ")", "{", "MethodNode", "method", "=", "getOrAddStaticConstructorNode", "(", ")", ";", "BlockStatement", "block", "=", "null", ";", "Statement", "statement", "=", "method", ".", "getCode", "(", ")", ";", "if", "(", "statement", "==", "null", ")", "{", "block", "=", "new", "BlockStatement", "(", ")", ";", "}", "else", "if", "(", "statement", "instanceof", "BlockStatement", ")", "{", "block", "=", "(", "BlockStatement", ")", "statement", ";", "}", "else", "{", "block", "=", "new", "BlockStatement", "(", ")", ";", "block", ".", "addStatement", "(", "statement", ")", ";", "}", "if", "(", "!", "fieldInit", ")", "{", "block", ".", "addStatements", "(", "staticStatements", ")", ";", "}", "else", "{", "List", "<", "Statement", ">", "blockStatements", "=", "block", ".", "getStatements", "(", ")", ";", "staticStatements", ".", "addAll", "(", "blockStatements", ")", ";", "blockStatements", ".", "clear", "(", ")", ";", "blockStatements", ".", "addAll", "(", "staticStatements", ")", ";", "}", "}", "public", "void", "positionStmtsAfterEnumInitStmts", "(", "List", "<", "Statement", ">", "staticFieldStatements", ")", "{", "MethodNode", "method", "=", "getOrAddStaticConstructorNode", "(", ")", ";", "Statement", "statement", "=", "method", ".", "getCode", "(", ")", ";", "if", "(", "statement", "instanceof", "BlockStatement", ")", "{", "BlockStatement", "block", "=", "(", "BlockStatement", ")", "statement", ";", "List", "<", "Statement", ">", "blockStatements", "=", "block", ".", "getStatements", "(", ")", ";", "ListIterator", "<", "Statement", ">", "litr", "=", "blockStatements", ".", "listIterator", "(", ")", ";", "while", "(", "litr", ".", "hasNext", "(", ")", ")", "{", "Statement", "stmt", "=", "litr", ".", "next", "(", ")", ";", "if", "(", "stmt", "instanceof", "ExpressionStatement", "&&", "(", "(", "ExpressionStatement", ")", "stmt", ")", ".", "getExpression", "(", ")", "instanceof", "BinaryExpression", ")", "{", "BinaryExpression", "bExp", "=", "(", "BinaryExpression", ")", "(", "(", "ExpressionStatement", ")", "stmt", ")", ".", "getExpression", "(", ")", ";", "if", "(", "bExp", ".", "getLeftExpression", "(", ")", "instanceof", "FieldExpression", ")", "{", "FieldExpression", "fExp", "=", "(", "FieldExpression", ")", "bExp", ".", "getLeftExpression", "(", ")", ";", "if", "(", "fExp", ".", "getFieldName", "(", ")", ".", "equals", "(", "\"$VALUES\"", ")", ")", "{", "for", "(", "Statement", "tmpStmt", ":", "staticFieldStatements", ")", "{", "litr", ".", "add", "(", "tmpStmt", ")", ";", "}", "}", "}", "}", "}", "}", "}", "public", "List", "<", "MethodNode", ">", "getDeclaredMethods", "(", "String", "name", ")", "{", "if", "(", "!", "redirect", "(", ")", ".", "lazyInitDone", ")", "redirect", "(", ")", ".", "lazyClassInit", "(", ")", ";", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", "(", ")", ".", "getDeclaredMethods", "(", "name", ")", ";", "return", "methods", ".", "getNotNull", "(", "name", ")", ";", "}", "public", "List", "<", "MethodNode", ">", "getMethods", "(", "String", "name", ")", "{", "List", "<", "MethodNode", ">", "answer", "=", "new", "ArrayList", "<", "MethodNode", ">", "(", ")", ";", "ClassNode", "node", "=", "this", ";", "while", "(", "node", "!=", "null", ")", "{", "answer", ".", "addAll", "(", "node", ".", "getDeclaredMethods", "(", "name", ")", ")", ";", "node", "=", "node", ".", "getSuperClass", "(", ")", ";", "}", "return", "answer", ";", "}", "public", "MethodNode", "getDeclaredMethod", "(", "String", "name", ",", "Parameter", "[", "]", "parameters", ")", "{", "for", "(", "MethodNode", "method", ":", "getDeclaredMethods", "(", "name", ")", ")", "{", "if", "(", "parametersEqual", "(", "method", ".", "getParameters", "(", ")", ",", "parameters", ")", ")", "{", "return", "method", ";", "}", "}", "return", "null", ";", "}", "public", "MethodNode", "getMethod", "(", "String", "name", ",", "Parameter", "[", "]", "parameters", ")", "{", "for", "(", "MethodNode", "method", ":", "getMethods", "(", "name", ")", ")", "{", "if", "(", "parametersEqual", "(", "method", ".", "getParameters", "(", ")", ",", "parameters", ")", ")", "{", "return", "method", ";", "}", "}", "return", "null", ";", "}", "public", "boolean", "isDerivedFrom", "(", "ClassNode", "type", ")", "{", "if", "(", "this", ".", "equals", "(", "ClassHelper", ".", "VOID_TYPE", ")", ")", "{", "return", "type", ".", "equals", "(", "ClassHelper", ".", "VOID_TYPE", ")", ";", "}", "if", "(", "type", ".", "equals", "(", "ClassHelper", ".", "OBJECT_TYPE", ")", ")", "return", "true", ";", "ClassNode", "node", "=", "this", ";", "while", "(", "node", "!=", "null", ")", "{", "if", "(", "type", ".", "equals", "(", "node", ")", ")", "{", "return", "true", ";", "}", "node", "=", "node", ".", "getSuperClass", "(", ")", ";", "}", "return", "false", ";", "}", "public", "boolean", "isDerivedFromGroovyObject", "(", ")", "{", "return", "implementsInterface", "(", "ClassHelper", ".", "make", "(", "GroovyObject", ".", "class", ")", ")", ";", "}", "public", "boolean", "implementsInterface", "(", "ClassNode", "classNode", ")", "{", "ClassNode", "node", "=", "redirect", "(", ")", ";", "do", "{", "if", "(", "node", ".", "declaresInterface", "(", "classNode", ")", ")", "{", "return", "true", ";", "}", "node", "=", "node", ".", "getSuperClass", "(", ")", ";", "}", "while", "(", "node", "!=", "null", ")", ";", "return", "false", ";", "}", "public", "boolean", "declaresInterface", "(", "ClassNode", "classNode", ")", "{", "ClassNode", "[", "]", "interfaces", "=", "redirect", "(", ")", ".", "getInterfaces", "(", ")", ";", "for", "(", "ClassNode", "cn", ":", "interfaces", ")", "{", "if", "(", "cn", ".", "equals", "(", "classNode", ")", ")", "return", "true", ";", "}", "for", "(", "ClassNode", "cn", ":", "interfaces", ")", "{", "if", "(", "cn", ".", "declaresInterface", "(", "classNode", ")", ")", "return", "true", ";", "}", "return", "false", ";", "}", "public", "ClassNode", "getSuperClass", "(", ")", "{", "if", "(", "!", "lazyInitDone", "&&", "!", "isResolved", "(", ")", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "getName", "(", ")", "+", "\"\"", ")", ";", "}", "if", "(", "hasInconsistentHierarchy", "(", ")", ")", "{", "return", "ClassHelper", ".", "OBJECT_TYPE", ";", "}", "ClassNode", "sn", "=", "redirect", "(", ")", ".", "getUnresolvedSuperClass", "(", ")", ";", "if", "(", "sn", "!=", "null", ")", "sn", "=", "sn", ".", "redirect", "(", ")", ";", "return", "sn", ";", "}", "public", "ClassNode", "getUnresolvedSuperClass", "(", ")", "{", "return", "getUnresolvedSuperClass", "(", "true", ")", ";", "}", "public", "ClassNode", "getUnresolvedSuperClass", "(", "boolean", "useRedirect", ")", "{", "if", "(", "hasInconsistentHierarchy", "(", ")", ")", "{", "return", "ClassHelper", ".", "OBJECT_TYPE", ";", "}", "if", "(", "!", "useRedirect", ")", "return", "superClass", ";", "if", "(", "!", "redirect", "(", ")", ".", "lazyInitDone", ")", "redirect", "(", ")", ".", "lazyClassInit", "(", ")", ";", "return", "redirect", "(", ")", ".", "superClass", ";", "}", "public", "void", "setUnresolvedSuperClass", "(", "ClassNode", "sn", ")", "{", "superClass", "=", "sn", ";", "}", "public", "ClassNode", "[", "]", "getUnresolvedInterfaces", "(", ")", "{", "return", "getUnresolvedInterfaces", "(", "true", ")", ";", "}", "public", "ClassNode", "[", "]", "getUnresolvedInterfaces", "(", "boolean", "useRedirect", ")", "{", "if", "(", "hasInconsistentHierarchy", "(", ")", ")", "{", "return", "EMPTY_ARRAY", ";", "}", "if", "(", "!", "useRedirect", ")", "return", "interfaces", ";", "if", "(", "!", "redirect", "(", ")", ".", "lazyInitDone", ")", "redirect", "(", ")", ".", "lazyClassInit", "(", ")", ";", "return", "redirect", "(", ")", ".", "interfaces", ";", "}", "public", "CompileUnit", "getCompileUnit", "(", ")", "{", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", "(", ")", ".", "getCompileUnit", "(", ")", ";", "if", "(", "compileUnit", "==", "null", "&&", "module", "!=", "null", ")", "{", "compileUnit", "=", "module", ".", "getUnit", "(", ")", ";", "}", "return", "compileUnit", ";", "}", "protected", "void", "setCompileUnit", "(", "CompileUnit", "cu", ")", "{", "if", "(", "redirect", "!=", "null", ")", "redirect", "(", ")", ".", "setCompileUnit", "(", "cu", ")", ";", "if", "(", "compileUnit", "!=", "null", ")", "compileUnit", "=", "cu", ";", "}", "protected", "boolean", "parametersEqual", "(", "Parameter", "[", "]", "a", ",", "Parameter", "[", "]", "b", ")", "{", "if", "(", "a", ".", "length", "==", "b", ".", "length", ")", "{", "boolean", "answer", "=", "true", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "a", ".", "length", ";", "i", "++", ")", "{", "if", "(", "!", "a", "[", "i", "]", ".", "getType", "(", ")", ".", "equals", "(", "b", "[", "i", "]", ".", "getType", "(", ")", ")", ")", "{", "answer", "=", "false", ";", "break", ";", "}", "}", "return", "answer", ";", "}", "return", "false", ";", "}", "public", "String", "getPackageName", "(", ")", "{", "int", "idx", "=", "getName", "(", ")", ".", "lastIndexOf", "(", "'.'", ")", ";", "if", "(", "idx", ">", "0", ")", "{", "return", "getName", "(", ")", ".", "substring", "(", "0", ",", "idx", ")", ";", "}", "return", "null", ";", "}", "public", "String", "getNameWithoutPackage", "(", ")", "{", "int", "idx", "=", "getName", "(", ")", ".", "lastIndexOf", "(", "'.'", ")", ";", "if", "(", "idx", ">", "0", ")", "{", "return", "getName", "(", ")", ".", "substring", "(", "idx", "+", "1", ")", ";", "}", "return", "getName", "(", ")", ";", "}", "public", "void", "visitContents", "(", "GroovyClassVisitor", "visitor", ")", "{", "for", "(", "PropertyNode", "pn", ":", "getProperties", "(", ")", ")", "{", "visitor", ".", "visitProperty", "(", "pn", ")", ";", "}", "for", "(", "FieldNode", "fn", ":", "getFields", "(", ")", ")", "{", "visitor", ".", "visitField", "(", "fn", ")", ";", "}", "for", "(", "ConstructorNode", "cn", ":", "getDeclaredConstructors", "(", ")", ")", "{", "visitor", ".", "visitConstructor", "(", "cn", ")", ";", "}", "for", "(", "MethodNode", "mn", ":", "getMethods", "(", ")", ")", "{", "visitor", ".", "visitMethod", "(", "mn", ")", ";", "}", "}", "public", "MethodNode", "getGetterMethod", "(", "String", "getterName", ")", "{", "for", "(", "MethodNode", "method", ":", "getDeclaredMethods", "(", "getterName", ")", ")", "{", "if", "(", "getterName", ".", "equals", "(", "method", ".", "getName", "(", ")", ")", "&&", "ClassHelper", ".", "VOID_TYPE", "!=", "method", ".", "getReturnType", "(", ")", "&&", "method", ".", "getParameters", "(", ")", ".", "length", "==", "0", ")", "{", "return", "method", ";", "}", "}", "ClassNode", "parent", "=", "getSuperClass", "(", ")", ";", "if", "(", "parent", "!=", "null", ")", "return", "parent", ".", "getGetterMethod", "(", "getterName", ")", ";", "return", "null", ";", "}", "public", "MethodNode", "getSetterMethod", "(", "String", "setterName", ")", "{", "for", "(", "MethodNode", "method", ":", "getDeclaredMethods", "(", "setterName", ")", ")", "{", "if", "(", "setterName", ".", "equals", "(", "method", ".", "getName", "(", ")", ")", "&&", "ClassHelper", ".", "VOID_TYPE", "==", "method", ".", "getReturnType", "(", ")", "&&", "method", ".", "getParameters", "(", ")", ".", "length", "==", "1", ")", "{", "return", "method", ";", "}", "}", "ClassNode", "parent", "=", "getSuperClass", "(", ")", ";", "if", "(", "parent", "!=", "null", ")", "return", "parent", ".", "getSetterMethod", "(", "setterName", ")", ";", "return", "null", ";", "}", "public", "boolean", "isStaticClass", "(", ")", "{", "return", "redirect", "(", ")", ".", "staticClass", ";", "}", "public", "void", "setStaticClass", "(", "boolean", "staticClass", ")", "{", "redirect", "(", ")", ".", "staticClass", "=", "staticClass", ";", "}", "public", "boolean", "isScriptBody", "(", ")", "{", "return", "redirect", "(", ")", ".", "scriptBody", ";", "}", "public", "void", "setScriptBody", "(", "boolean", "scriptBody", ")", "{", "redirect", "(", ")", ".", "scriptBody", "=", "scriptBody", ";", "}", "public", "boolean", "isScript", "(", ")", "{", "return", "redirect", "(", ")", ".", "script", "||", "isDerivedFrom", "(", "ClassHelper", ".", "SCRIPT_TYPE", ")", ";", "}", "public", "void", "setScript", "(", "boolean", "script", ")", "{", "redirect", "(", ")", ".", "script", "=", "script", ";", "}", "public", "String", "toString", "(", ")", "{", "String", "ret", "=", "getName", "(", ")", ";", "if", "(", "genericsTypes", "!=", "null", ")", "{", "ret", "+=", "\"", "<\"", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "genericsTypes", ".", "length", ";", "i", "++", ")", "{", "if", "(", "i", "!=", "0", ")", "ret", "+=", "\",", "\"", ";", "GenericsType", "genericsType", "=", "genericsTypes", "[", "i", "]", ";", "ret", "+=", "genericTypeAsString", "(", "genericsType", ")", ";", "}", "ret", "+=", "\">\"", ";", "}", "if", "(", "redirect", "!=", "null", ")", "{", "ret", "+=", "\"", "->", "\"", "+", "redirect", "(", ")", ".", "toString", "(", ")", ";", "}", "return", "ret", ";", "}", "private", "String", "genericTypeAsString", "(", "GenericsType", "genericsType", ")", "{", "String", "ret", "=", "genericsType", ".", "getName", "(", ")", ";", "if", "(", "genericsType", ".", "getUpperBounds", "(", ")", "!=", "null", ")", "{", "ret", "+=", "\"", "extends", "\"", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "genericsType", ".", "getUpperBounds", "(", ")", ".", "length", ";", "i", "++", ")", "{", "ClassNode", "classNode", "=", "genericsType", ".", "getUpperBounds", "(", ")", "[", "i", "]", ";", "if", "(", "classNode", ".", "equals", "(", "this", ")", ")", "{", "ret", "+=", "classNode", ".", "getName", "(", ")", ";", "}", "else", "{", "ret", "+=", "classNode", ".", "toString", "(", ")", ";", "}", "if", "(", "i", "+", "1", "<", "genericsType", ".", "getUpperBounds", "(", ")", ".", "length", ")", "ret", "+=", "\"", "&", "\"", ";", "}", "}", "else", "if", "(", "genericsType", ".", "getLowerBound", "(", ")", "!=", "null", ")", "{", "ClassNode", "classNode", "=", "genericsType", ".", "getLowerBound", "(", ")", ";", "if", "(", "classNode", ".", "equals", "(", "this", ")", ")", "{", "ret", "+=", "\"", "super", "\"", "+", "classNode", ".", "getName", "(", ")", ";", "}", "else", "{", "ret", "+=", "\"", "super", "\"", "+", "classNode", ";", "}", "}", "return", "ret", ";", "}", "public", "boolean", "hasPossibleMethod", "(", "String", "name", ",", "Expression", "arguments", ")", "{", "int", "count", "=", "0", ";", "if", "(", "arguments", "instanceof", "TupleExpression", ")", "{", "TupleExpression", "tuple", "=", "(", "TupleExpression", ")", "arguments", ";", "count", "=", "tuple", ".", "getExpressions", "(", ")", ".", "size", "(", ")", ";", "}", "ClassNode", "node", "=", "this", ";", "do", "{", "for", "(", "MethodNode", "method", ":", "getMethods", "(", "name", ")", ")", "{", "if", "(", "method", ".", "getParameters", "(", ")", ".", "length", "==", "count", "&&", "!", "method", ".", "isStatic", "(", ")", ")", "{", "return", "true", ";", "}", "}", "node", "=", "node", ".", "getSuperClass", "(", ")", ";", "}", "while", "(", "node", "!=", "null", ")", ";", "return", "false", ";", "}", "public", "MethodNode", "tryFindPossibleMethod", "(", "String", "name", ",", "Expression", "arguments", ")", "{", "int", "count", "=", "0", ";", "if", "(", "arguments", "instanceof", "TupleExpression", ")", "{", "TupleExpression", "tuple", "=", "(", "TupleExpression", ")", "arguments", ";", "count", "=", "tuple", ".", "getExpressions", "(", ")", ".", "size", "(", ")", ";", "}", "else", "return", "null", ";", "MethodNode", "res", "=", "null", ";", "ClassNode", "node", "=", "this", ";", "TupleExpression", "args", "=", "(", "TupleExpression", ")", "arguments", ";", "do", "{", "for", "(", "MethodNode", "method", ":", "node", ".", "getMethods", "(", "name", ")", ")", "{", "if", "(", "method", ".", "getParameters", "(", ")", ".", "length", "==", "count", ")", "{", "boolean", "match", "=", "true", ";", "for", "(", "int", "i", "=", "0", ";", "i", "!=", "count", ";", "++", "i", ")", "if", "(", "!", "args", ".", "getType", "(", ")", ".", "isDerivedFrom", "(", "method", ".", "getParameters", "(", ")", "[", "i", "]", ".", "getType", "(", ")", ")", ")", "{", "match", "=", "false", ";", "break", ";", "}", "if", "(", "match", ")", "{", "if", "(", "res", "==", "null", ")", "res", "=", "method", ";", "else", "{", "if", "(", "res", ".", "getParameters", "(", ")", ".", "length", "!=", "count", ")", "return", "null", ";", "if", "(", "node", ".", "equals", "(", "this", ")", ")", "return", "null", ";", "match", "=", "true", ";", "for", "(", "int", "i", "=", "0", ";", "i", "!=", "count", ";", "++", "i", ")", "if", "(", "!", "res", ".", "getParameters", "(", ")", "[", "i", "]", ".", "getType", "(", ")", ".", "equals", "(", "method", ".", "getParameters", "(", ")", "[", "i", "]", ".", "getType", "(", ")", ")", ")", "{", "match", "=", "false", ";", "break", ";", "}", "if", "(", "!", "match", ")", "return", "null", ";", "}", "}", "}", "}", "node", "=", "node", ".", "getSuperClass", "(", ")", ";", "}", "while", "(", "node", "!=", "null", ")", ";", "return", "res", ";", "}", "public", "boolean", "hasPossibleStaticMethod", "(", "String", "name", ",", "Expression", "arguments", ")", "{", "int", "count", "=", "0", ";", "if", "(", "arguments", "instanceof", "TupleExpression", ")", "{", "TupleExpression", "tuple", "=", "(", "TupleExpression", ")", "arguments", ";", "count", "=", "tuple", ".", "getExpressions", "(", ")", ".", "size", "(", ")", ";", "}", "else", "if", "(", "arguments", "instanceof", "MapExpression", ")", "{", "count", "=", "1", ";", "}", "for", "(", "MethodNode", "method", ":", "getMethods", "(", "name", ")", ")", "{", "if", "(", "method", ".", "isStatic", "(", ")", ")", "{", "Parameter", "[", "]", "parameters", "=", "method", ".", "getParameters", "(", ")", ";", "if", "(", "parameters", ".", "length", "==", "count", ")", "return", "true", ";", "if", "(", "parameters", ".", "length", ">", "0", "&&", "parameters", "[", "parameters", ".", "length", "-", "1", "]", ".", "getType", "(", ")", ".", "isArray", "(", ")", ")", "{", "if", "(", "count", ">=", "parameters", ".", "length", "-", "1", ")", "return", "true", ";", "}", "int", "nonDefaultParameters", "=", "0", ";", "for", "(", "Parameter", "parameter", ":", "parameters", ")", "{", "if", "(", "!", "parameter", ".", "hasInitialExpression", "(", ")", ")", "{", "nonDefaultParameters", "++", ";", "}", "}", "if", "(", "count", "<", "parameters", ".", "length", "&&", "nonDefaultParameters", "<=", "count", ")", "{", "return", "true", ";", "}", "}", "}", "return", "false", ";", "}", "public", "boolean", "isInterface", "(", ")", "{", "return", "(", "getModifiers", "(", ")", "&", "Opcodes", ".", "ACC_INTERFACE", ")", ">", "0", ";", "}", "public", "boolean", "isResolved", "(", ")", "{", "return", "redirect", "(", ")", ".", "isReallyResolved", "(", ")", "||", "redirect", "(", ")", ".", "clazz", "!=", "null", "||", "(", "componentType", "!=", "null", "&&", "componentType", ".", "isResolved", "(", ")", ")", ";", "}", "public", "boolean", "isReallyResolved", "(", ")", "{", "return", "false", ";", "}", "public", "boolean", "isArray", "(", ")", "{", "return", "componentType", "!=", "null", ";", "}", "public", "ClassNode", "getComponentType", "(", ")", "{", "return", "componentType", ";", "}", "public", "boolean", "hasClass", "(", ")", "{", "return", "redirect", "(", ")", ".", "clazz", "!=", "null", ";", "}", "public", "Class", "getTypeClass", "(", ")", "{", "Class", "c", "=", "redirect", "(", ")", ".", "clazz", ";", "if", "(", "c", "!=", "null", ")", "return", "c", ";", "ClassNode", "component", "=", "redirect", "(", ")", ".", "componentType", ";", "if", "(", "component", "!=", "null", "&&", "component", ".", "isResolved", "(", ")", ")", "{", "ClassNode", "cn", "=", "component", ".", "makeArray", "(", ")", ";", "setRedirect", "(", "cn", ")", ";", "return", "redirect", "(", ")", ".", "clazz", ";", "}", "if", "(", "redirect", "(", ")", ".", "getClass", "(", ")", ".", "getName", "(", ")", ".", "endsWith", "(", "\"JDTClassNode\"", ")", ")", "{", "return", "redirect", "(", ")", ".", "getTypeClass", "(", ")", ";", "}", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "getName", "(", ")", "+", "\"\"", ")", ";", "}", "public", "boolean", "hasPackageName", "(", ")", "{", "return", "redirect", "(", ")", ".", "name", ".", "indexOf", "(", "'.'", ")", ">", "0", ";", "}", "public", "void", "setAnnotated", "(", "boolean", "flag", ")", "{", "this", ".", "annotated", "=", "flag", ";", "}", "public", "boolean", "isAnnotated", "(", ")", "{", "return", "this", ".", "annotated", ";", "}", "public", "GenericsType", "[", "]", "getGenericsTypes", "(", ")", "{", "return", "genericsTypes", ";", "}", "public", "void", "setGenericsTypes", "(", "GenericsType", "[", "]", "genericsTypes", ")", "{", "usesGenerics", "=", "usesGenerics", "||", "genericsTypes", "!=", "null", ";", "this", ".", "genericsTypes", "=", "genericsTypes", ";", "}", "public", "void", "setGenericsPlaceHolder", "(", "boolean", "b", ")", "{", "usesGenerics", "=", "usesGenerics", "||", "b", ";", "placeholder", "=", "b", ";", "}", "public", "boolean", "isGenericsPlaceHolder", "(", ")", "{", "return", "placeholder", ";", "}", "public", "boolean", "isUsingGenerics", "(", ")", "{", "return", "usesGenerics", ";", "}", "public", "void", "setUsingGenerics", "(", "boolean", "b", ")", "{", "usesGenerics", "=", "b", ";", "}", "public", "ClassNode", "getPlainNodeReference", "(", ")", "{", "if", "(", "ClassHelper", ".", "isPrimitiveType", "(", "this", ")", ")", "return", "this", ";", "ClassNode", "n", "=", "new", "ClassNode", "(", "getName", "(", ")", ",", "getModifiers", "(", ")", ",", "getSuperClass", "(", ")", ",", "getInterfaces", "(", ")", ",", "null", ")", ";", "n", ".", "isPrimaryNode", "=", "false", ";", "n", ".", "setRedirect", "(", "this", ".", "redirect", ")", ";", "n", ".", "componentType", "=", "redirect", "(", ")", ".", "getComponentType", "(", ")", ";", "return", "n", ";", "}", "public", "boolean", "isAnnotationDefinition", "(", ")", "{", "return", "redirect", "(", ")", ".", "isPrimaryNode", "&&", "isInterface", "(", ")", "&&", "(", "getModifiers", "(", ")", "&", "Opcodes", ".", "ACC_ANNOTATION", ")", "!=", "0", ";", "}", "public", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", ")", "{", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", ".", "getAnnotations", "(", ")", ";", "lazyClassInit", "(", ")", ";", "return", "super", ".", "getAnnotations", "(", ")", ";", "}", "public", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", "ClassNode", "type", ")", "{", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", ".", "getAnnotations", "(", "type", ")", ";", "lazyClassInit", "(", ")", ";", "return", "super", ".", "getAnnotations", "(", "type", ")", ";", "}", "public", "void", "addTransform", "(", "Class", "<", "?", "extends", "ASTTransformation", ">", "transform", ",", "ASTNode", "node", ")", "{", "GroovyASTTransformation", "annotation", "=", "transform", ".", "getAnnotation", "(", "GroovyASTTransformation", ".", "class", ")", ";", "Set", "<", "ASTNode", ">", "nodes", "=", "getTransformInstances", "(", ")", ".", "get", "(", "annotation", ".", "phase", "(", ")", ")", ".", "get", "(", "transform", ")", ";", "if", "(", "nodes", "==", "null", ")", "{", "nodes", "=", "new", "LinkedHashSet", "<", "ASTNode", ">", "(", ")", ";", "getTransformInstances", "(", ")", ".", "get", "(", "annotation", ".", "phase", "(", ")", ")", ".", "put", "(", "transform", ",", "nodes", ")", ";", "}", "nodes", ".", "add", "(", "node", ")", ";", "}", "public", "Map", "<", "Class", "<", "?", "extends", "ASTTransformation", ">", ",", "Set", "<", "ASTNode", ">", ">", "getTransforms", "(", "CompilePhase", "phase", ")", "{", "return", "getTransformInstances", "(", ")", ".", "get", "(", "phase", ")", ";", "}", "public", "void", "renameField", "(", "String", "oldName", ",", "String", "newName", ")", "{", "ClassNode", "r", "=", "redirect", "(", ")", ";", "if", "(", "r", ".", "fieldIndex", "==", "null", ")", "r", ".", "fieldIndex", "=", "new", "HashMap", "<", "String", ",", "FieldNode", ">", "(", ")", ";", "final", "Map", "<", "String", ",", "FieldNode", ">", "index", "=", "r", ".", "fieldIndex", ";", "index", ".", "put", "(", "newName", ",", "index", ".", "remove", "(", "oldName", ")", ")", ";", "}", "public", "void", "removeField", "(", "String", "oldName", ")", "{", "ClassNode", "r", "=", "redirect", "(", ")", ";", "if", "(", "r", ".", "fieldIndex", "==", "null", ")", "r", ".", "fieldIndex", "=", "new", "HashMap", "<", "String", ",", "FieldNode", ">", "(", ")", ";", "final", "Map", "<", "String", ",", "FieldNode", ">", "index", "=", "r", ".", "fieldIndex", ";", "r", ".", "fields", ".", "remove", "(", "index", ".", "get", "(", "oldName", ")", ")", ";", "index", ".", "remove", "(", "oldName", ")", ";", "}", "public", "boolean", "isEnum", "(", ")", "{", "return", "(", "getModifiers", "(", ")", "&", "Opcodes", ".", "ACC_ENUM", ")", "!=", "0", ";", "}", "public", "Iterator", "<", "InnerClassNode", ">", "getInnerClasses", "(", ")", "{", "return", "(", "innerClasses", "==", "null", "?", "Collections", ".", "<", "InnerClassNode", ">", "emptyList", "(", ")", ":", "innerClasses", ")", ".", "iterator", "(", ")", ";", "}", "public", "void", "forgetInnerClass", "(", "InnerClassNode", "icn", ")", "{", "if", "(", "innerClasses", "!=", "null", ")", "{", "innerClasses", ".", "remove", "(", "icn", ")", ";", "}", "}", "private", "Map", "<", "CompilePhase", ",", "Map", "<", "Class", "<", "?", "extends", "ASTTransformation", ">", ",", "Set", "<", "ASTNode", ">", ">", ">", "getTransformInstances", "(", ")", "{", "if", "(", "transformInstances", "==", "null", ")", "{", "transformInstances", "=", "new", "EnumMap", "<", "CompilePhase", ",", "Map", "<", "Class", "<", "?", "extends", "ASTTransformation", ">", ",", "Set", "<", "ASTNode", ">", ">", ">", "(", "CompilePhase", ".", "class", ")", ";", "for", "(", "CompilePhase", "phase", ":", "CompilePhase", ".", "values", "(", ")", ")", "{", "transformInstances", ".", "put", "(", "phase", ",", "new", "HashMap", "<", "Class", "<", "?", "extends", "ASTTransformation", ">", ",", "Set", "<", "ASTNode", ">", ">", "(", ")", ")", ";", "}", "}", "return", "transformInstances", ";", "}", "public", "String", "getClassInternalName", "(", ")", "{", "if", "(", "redirect", "!=", "null", ")", "return", "redirect", "(", ")", ".", "getClassInternalName", "(", ")", ";", "return", "null", ";", "}", "public", "boolean", "isPrimitive", "(", ")", "{", "if", "(", "clazz", "!=", "null", ")", "{", "return", "clazz", ".", "isPrimitive", "(", ")", ";", "}", "return", "false", ";", "}", "public", "boolean", "mightHaveInners", "(", ")", "{", "ClassNode", "redirect", "=", "redirect", "(", ")", ";", "if", "(", "redirect", ".", "hasClass", "(", ")", ")", "{", "return", "true", ";", "}", "boolean", "b", "=", "redirect", ".", "innerClasses", "!=", "null", "&&", "redirect", ".", "innerClasses", ".", "size", "(", ")", ">", "0", ";", "return", "b", ";", "}", "}", "</s>" ]
6,728
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "Map", ";", "public", "class", "VariableScope", "{", "private", "Map", "<", "String", ",", "Variable", ">", "declaredVariables", "=", "Collections", ".", "emptyMap", "(", ")", ";", "private", "Map", "<", "String", ",", "Variable", ">", "referencedLocalVariables", "=", "Collections", ".", "emptyMap", "(", ")", ";", "private", "Map", "<", "String", ",", "Variable", ">", "referencedClassVariables", "=", "Collections", ".", "emptyMap", "(", ")", ";", "private", "boolean", "inStaticContext", "=", "false", ";", "private", "boolean", "resolvesDynamic", "=", "false", ";", "private", "ClassNode", "clazzScope", ";", "private", "VariableScope", "parent", ";", "public", "VariableScope", "(", ")", "{", "}", "public", "VariableScope", "(", "VariableScope", "parent", ")", "{", "this", ".", "parent", "=", "parent", ";", "}", "public", "Variable", "getDeclaredVariable", "(", "String", "name", ")", "{", "return", "declaredVariables", ".", "get", "(", "name", ")", ";", "}", "public", "Iterator", "<", "Variable", ">", "getDeclaredVariablesIterator", "(", ")", "{", "return", "declaredVariables", ".", "values", "(", ")", ".", "iterator", "(", ")", ";", "}", "public", "boolean", "isReferencedLocalVariable", "(", "String", "name", ")", "{", "return", "referencedLocalVariables", ".", "containsKey", "(", "name", ")", ";", "}", "public", "boolean", "isReferencedClassVariable", "(", "String", "name", ")", "{", "return", "referencedClassVariables", ".", "containsKey", "(", "name", ")", ";", "}", "public", "VariableScope", "getParent", "(", ")", "{", "return", "parent", ";", "}", "public", "boolean", "isInStaticContext", "(", ")", "{", "return", "inStaticContext", ";", "}", "public", "void", "setInStaticContext", "(", "boolean", "inStaticContext", ")", "{", "this", ".", "inStaticContext", "=", "inStaticContext", ";", "}", "@", "Deprecated", "public", "boolean", "isResolvingDynamic", "(", ")", "{", "return", "resolvesDynamic", ";", "}", "@", "Deprecated", "public", "void", "setDynamicResolving", "(", "boolean", "resolvesDynamic", ")", "{", "this", ".", "resolvesDynamic", "=", "resolvesDynamic", ";", "}", "public", "void", "setClassScope", "(", "ClassNode", "node", ")", "{", "this", ".", "clazzScope", "=", "node", ";", "}", "public", "ClassNode", "getClassScope", "(", ")", "{", "return", "clazzScope", ";", "}", "public", "boolean", "isClassScope", "(", ")", "{", "return", "clazzScope", "!=", "null", ";", "}", "public", "boolean", "isRoot", "(", ")", "{", "return", "parent", "==", "null", ";", "}", "public", "VariableScope", "copy", "(", ")", "{", "VariableScope", "copy", "=", "new", "VariableScope", "(", ")", ";", "copy", ".", "clazzScope", "=", "clazzScope", ";", "if", "(", "declaredVariables", ".", "size", "(", ")", ">", "0", ")", "{", "copy", ".", "declaredVariables", "=", "new", "HashMap", "<", "String", ",", "Variable", ">", "(", ")", ";", "copy", ".", "declaredVariables", ".", "putAll", "(", "declaredVariables", ")", ";", "}", "copy", ".", "inStaticContext", "=", "inStaticContext", ";", "copy", ".", "parent", "=", "parent", ";", "if", "(", "referencedClassVariables", ".", "size", "(", ")", ">", "0", ")", "{", "copy", ".", "referencedClassVariables", "=", "new", "HashMap", "<", "String", ",", "Variable", ">", "(", ")", ";", "copy", ".", "referencedClassVariables", ".", "putAll", "(", "referencedClassVariables", ")", ";", "}", "if", "(", "referencedLocalVariables", ".", "size", "(", ")", ">", "0", ")", "{", "copy", ".", "referencedLocalVariables", "=", "new", "HashMap", "<", "String", ",", "Variable", ">", "(", ")", ";", "copy", ".", "referencedLocalVariables", ".", "putAll", "(", "referencedLocalVariables", ")", ";", "}", "copy", ".", "resolvesDynamic", "=", "resolvesDynamic", ";", "return", "copy", ";", "}", "public", "void", "putDeclaredVariable", "(", "Variable", "var", ")", "{", "if", "(", "declaredVariables", "==", "Collections", ".", "EMPTY_MAP", ")", "declaredVariables", "=", "new", "HashMap", "<", "String", ",", "Variable", ">", "(", ")", ";", "declaredVariables", ".", "put", "(", "var", ".", "getName", "(", ")", ",", "var", ")", ";", "}", "public", "Iterator", "<", "Variable", ">", "getReferencedLocalVariablesIterator", "(", ")", "{", "return", "referencedLocalVariables", ".", "values", "(", ")", ".", "iterator", "(", ")", ";", "}", "public", "int", "getReferencedLocalVariablesCount", "(", ")", "{", "return", "referencedLocalVariables", ".", "size", "(", ")", ";", "}", "public", "Variable", "getReferencedLocalVariable", "(", "String", "name", ")", "{", "return", "referencedLocalVariables", ".", "get", "(", "name", ")", ";", "}", "public", "void", "putReferencedLocalVariable", "(", "Variable", "var", ")", "{", "if", "(", "referencedLocalVariables", "==", "Collections", ".", "EMPTY_MAP", ")", "referencedLocalVariables", "=", "new", "HashMap", "<", "String", ",", "Variable", ">", "(", ")", ";", "referencedLocalVariables", ".", "put", "(", "var", ".", "getName", "(", ")", ",", "var", ")", ";", "}", "public", "void", "putReferencedClassVariable", "(", "Variable", "var", ")", "{", "if", "(", "referencedClassVariables", "==", "Collections", ".", "EMPTY_MAP", ")", "referencedClassVariables", "=", "new", "HashMap", "<", "String", ",", "Variable", ">", "(", ")", ";", "referencedClassVariables", ".", "put", "(", "var", ".", "getName", "(", ")", ",", "var", ")", ";", "}", "public", "Variable", "getReferencedClassVariable", "(", "String", "name", ")", "{", "return", "referencedClassVariables", ".", "get", "(", "name", ")", ";", "}", "public", "Object", "removeReferencedClassVariable", "(", "String", "name", ")", "{", "if", "(", "referencedClassVariables", "==", "Collections", ".", "EMPTY_MAP", ")", "return", "null", ";", "else", "return", "referencedClassVariables", ".", "remove", "(", "name", ")", ";", "}", "public", "Map", "<", "String", ",", "Variable", ">", "getReferencedClassVariables", "(", ")", "{", "if", "(", "referencedClassVariables", "==", "Collections", ".", "EMPTY_MAP", ")", "{", "return", "referencedClassVariables", ";", "}", "else", "{", "return", "Collections", ".", "unmodifiableMap", "(", "referencedClassVariables", ")", ";", "}", "}", "public", "Iterator", "<", "Variable", ">", "getReferencedClassVariablesIterator", "(", ")", "{", "return", "getReferencedClassVariables", "(", ")", ".", "values", "(", ")", ".", "iterator", "(", ")", ";", "}", "}", "</s>" ]
6,729
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "GroovyBugError", ";", "class", "ImmutableClassNode", "extends", "ClassNode", "{", "class", "ImmutableGenericsType", "extends", "GenericsType", "{", "ImmutableGenericsType", "(", "GenericsType", "delegate", ")", "{", "super", ".", "setType", "(", "delegate", ".", "getType", "(", ")", ")", ";", "super", ".", "setPlaceholder", "(", "delegate", ".", "isPlaceholder", "(", ")", ")", ";", "super", ".", "setResolved", "(", "delegate", ".", "isResolved", "(", ")", ")", ";", "super", ".", "setName", "(", "delegate", ".", "getName", "(", ")", ")", ";", "super", ".", "setWildcard", "(", "delegate", ".", "isWildcard", "(", ")", ")", ";", "super", ".", "setUpperBounds", "(", "delegate", ".", "getUpperBounds", "(", ")", ")", ";", "super", ".", "setLowerBound", "(", "delegate", ".", "getLowerBound", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "setType", "(", "ClassNode", "type", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "ImmutableClassNode", ".", "this", ".", "getName", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "setPlaceholder", "(", "boolean", "placeholder", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "ImmutableClassNode", ".", "this", ".", "getName", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "setResolved", "(", "boolean", "res", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "ImmutableClassNode", ".", "this", ".", "getName", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "setName", "(", "String", "name", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "ImmutableClassNode", ".", "this", ".", "getName", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "setWildcard", "(", "boolean", "wildcard", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "ImmutableClassNode", ".", "this", ".", "getName", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "setUpperBounds", "(", "ClassNode", "[", "]", "bounds", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "ImmutableClassNode", ".", "this", ".", "getName", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "setLowerBound", "(", "ClassNode", "bound", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "ImmutableClassNode", ".", "this", ".", "getName", "(", ")", ")", ";", "}", "}", "private", "boolean", "genericsInitialized", "=", "false", ";", "public", "ImmutableClassNode", "(", "Class", "c", ")", "{", "super", "(", "c", ")", ";", "}", "@", "Override", "public", "void", "setGenericsTypes", "(", "GenericsType", "[", "]", "genericsTypes", ")", "{", "if", "(", "genericsInitialized", ")", "{", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "this", ".", "getName", "(", ")", ")", ";", "}", "if", "(", "genericsTypes", "!=", "null", ")", "{", "GenericsType", "[", "]", "immutable", "=", "new", "GenericsType", "[", "genericsTypes", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "genericsTypes", ".", "length", ";", "i", "++", ")", "{", "immutable", "[", "i", "]", "=", "new", "ImmutableGenericsType", "(", "genericsTypes", "[", "i", "]", ")", ";", "}", "genericsTypes", "=", "immutable", ";", "}", "super", ".", "setGenericsTypes", "(", "genericsTypes", ")", ";", "genericsInitialized", "=", "true", ";", "}", "}", "</s>" ]
6,730
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "java", ".", "util", ".", "*", ";", "public", "class", "AnnotatedNode", "extends", "ASTNode", "{", "private", "List", "<", "AnnotationNode", ">", "annotations", "=", "Collections", ".", "emptyList", "(", ")", ";", "private", "boolean", "synthetic", ";", "ClassNode", "declaringClass", ";", "private", "boolean", "hasNoRealSourcePositionFlag", ";", "private", "int", "nameEnd", ";", "private", "int", "nameStart", ";", "public", "AnnotatedNode", "(", ")", "{", "}", "public", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", ")", "{", "return", "annotations", ";", "}", "public", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", "ClassNode", "type", ")", "{", "List", "<", "AnnotationNode", ">", "ret", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", "annotations", ".", "size", "(", ")", ")", ";", "for", "(", "AnnotationNode", "node", ":", "annotations", ")", "{", "if", "(", "type", ".", "equals", "(", "node", ".", "getClassNode", "(", ")", ")", ")", "ret", ".", "add", "(", "node", ")", ";", "}", "return", "ret", ";", "}", "public", "void", "addAnnotation", "(", "AnnotationNode", "value", ")", "{", "checkInit", "(", ")", ";", "annotations", ".", "add", "(", "value", ")", ";", "}", "private", "void", "checkInit", "(", ")", "{", "if", "(", "annotations", "==", "Collections", ".", "EMPTY_LIST", ")", "annotations", "=", "new", "ArrayList", "<", "AnnotationNode", ">", "(", "3", ")", ";", "}", "public", "void", "addAnnotations", "(", "List", "<", "AnnotationNode", ">", "annotations", ")", "{", "for", "(", "AnnotationNode", "node", ":", "annotations", ")", "{", "addAnnotation", "(", "node", ")", ";", "}", "}", "public", "boolean", "isSynthetic", "(", ")", "{", "return", "synthetic", ";", "}", "public", "void", "setSynthetic", "(", "boolean", "synthetic", ")", "{", "this", ".", "synthetic", "=", "synthetic", ";", "}", "public", "ClassNode", "getDeclaringClass", "(", ")", "{", "return", "declaringClass", ";", "}", "public", "void", "setDeclaringClass", "(", "ClassNode", "declaringClass", ")", "{", "this", ".", "declaringClass", "=", "declaringClass", ";", "}", "public", "boolean", "hasNoRealSourcePosition", "(", ")", "{", "return", "hasNoRealSourcePositionFlag", ";", "}", "public", "void", "setHasNoRealSourcePosition", "(", "boolean", "value", ")", "{", "this", ".", "hasNoRealSourcePositionFlag", "=", "value", ";", "}", "public", "int", "getNameStart", "(", ")", "{", "return", "nameStart", ";", "}", "public", "void", "setNameStart", "(", "int", "nameStart", ")", "{", "this", ".", "nameStart", "=", "nameStart", ";", "}", "public", "int", "getNameEnd", "(", ")", "{", "return", "nameEnd", ";", "}", "public", "void", "setNameEnd", "(", "int", "nameEnd", ")", "{", "this", ".", "nameEnd", "=", "nameEnd", ";", "}", "@", "Override", "public", "void", "setSourcePosition", "(", "ASTNode", "node", ")", "{", "super", ".", "setSourcePosition", "(", "node", ")", ";", "if", "(", "node", "instanceof", "AnnotatedNode", ")", "{", "AnnotatedNode", "aNode", "=", "(", "AnnotatedNode", ")", "node", ";", "setNameStart", "(", "aNode", ".", "getNameStart", "(", ")", ")", ";", "setNameEnd", "(", "aNode", ".", "getNameEnd", "(", ")", ")", ";", "}", "}", "}", "</s>" ]
6,731
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "groovy", ".", "lang", ".", "*", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "GeneratedClosure", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "vmplugin", ".", "VMPluginFactory", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "import", "java", ".", "math", ".", "BigDecimal", ";", "import", "java", ".", "math", ".", "BigInteger", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "WeakHashMap", ";", "import", "java", ".", "util", ".", "regex", ".", "Pattern", ";", "import", "java", ".", "lang", ".", "ref", ".", "SoftReference", ";", "public", "class", "ClassHelper", "{", "public", "static", "final", "Class", "[", "]", "classes", "=", "new", "Class", "[", "]", "{", "Object", ".", "class", ",", "Boolean", ".", "TYPE", ",", "Character", ".", "TYPE", ",", "Byte", ".", "TYPE", ",", "Short", ".", "TYPE", ",", "Integer", ".", "TYPE", ",", "Long", ".", "TYPE", ",", "Double", ".", "TYPE", ",", "Float", ".", "TYPE", ",", "Void", ".", "TYPE", ",", "Closure", ".", "class", ",", "GString", ".", "class", ",", "List", ".", "class", ",", "Map", ".", "class", ",", "Range", ".", "class", ",", "Pattern", ".", "class", ",", "Script", ".", "class", ",", "String", ".", "class", ",", "Boolean", ".", "class", ",", "Character", ".", "class", ",", "Byte", ".", "class", ",", "Short", ".", "class", ",", "Integer", ".", "class", ",", "Long", ".", "class", ",", "Double", ".", "class", ",", "Float", ".", "class", ",", "BigDecimal", ".", "class", ",", "BigInteger", ".", "class", ",", "Void", ".", "class", ",", "Reference", ".", "class", ",", "Class", ".", "class", ",", "MetaClass", ".", "class", ",", "}", ";", "private", "static", "final", "String", "[", "]", "primitiveClassNames", "=", "new", "String", "[", "]", "{", "\"\"", ",", "\"boolean\"", ",", "\"char\"", ",", "\"byte\"", ",", "\"short\"", ",", "\"int\"", ",", "\"long\"", ",", "\"double\"", ",", "\"float\"", ",", "\"void\"", "}", ";", "public", "static", "final", "ClassNode", "DYNAMIC_TYPE", "=", "makeCached", "(", "Object", ".", "class", ")", ",", "OBJECT_TYPE", "=", "DYNAMIC_TYPE", ",", "VOID_TYPE", "=", "makeCached", "(", "Void", ".", "TYPE", ")", ",", "CLOSURE_TYPE", "=", "makeCached", "(", "Closure", ".", "class", ")", ",", "GSTRING_TYPE", "=", "makeCached", "(", "GString", ".", "class", ")", ",", "LIST_TYPE", "=", "makeWithoutCaching", "(", "List", ".", "class", ")", ",", "MAP_TYPE", "=", "makeWithoutCaching", "(", "Map", ".", "class", ")", ",", "RANGE_TYPE", "=", "makeCached", "(", "Range", ".", "class", ")", ",", "PATTERN_TYPE", "=", "makeCached", "(", "Pattern", ".", "class", ")", ",", "STRING_TYPE", "=", "makeCached", "(", "String", ".", "class", ")", ",", "SCRIPT_TYPE", "=", "makeCached", "(", "Script", ".", "class", ")", ",", "REFERENCE_TYPE", "=", "makeWithoutCaching", "(", "Reference", ".", "class", ")", ",", "boolean_TYPE", "=", "makeCached", "(", "boolean", ".", "class", ")", ",", "char_TYPE", "=", "makeCached", "(", "char", ".", "class", ")", ",", "byte_TYPE", "=", "makeCached", "(", "byte", ".", "class", ")", ",", "int_TYPE", "=", "makeCached", "(", "int", ".", "class", ")", ",", "long_TYPE", "=", "makeCached", "(", "long", ".", "class", ")", ",", "short_TYPE", "=", "makeCached", "(", "short", ".", "class", ")", ",", "double_TYPE", "=", "makeCached", "(", "double", ".", "class", ")", ",", "float_TYPE", "=", "makeCached", "(", "float", ".", "class", ")", ",", "Byte_TYPE", "=", "makeCached", "(", "Byte", ".", "class", ")", ",", "Short_TYPE", "=", "makeCached", "(", "Short", ".", "class", ")", ",", "Integer_TYPE", "=", "makeCached", "(", "Integer", ".", "class", ")", ",", "Long_TYPE", "=", "makeCached", "(", "Long", ".", "class", ")", ",", "Character_TYPE", "=", "makeCached", "(", "Character", ".", "class", ")", ",", "Float_TYPE", "=", "makeCached", "(", "Float", ".", "class", ")", ",", "Double_TYPE", "=", "makeCached", "(", "Double", ".", "class", ")", ",", "Boolean_TYPE", "=", "makeCached", "(", "Boolean", ".", "class", ")", ",", "BigInteger_TYPE", "=", "makeCached", "(", "java", ".", "math", ".", "BigInteger", ".", "class", ")", ",", "BigDecimal_TYPE", "=", "makeCached", "(", "java", ".", "math", ".", "BigDecimal", ".", "class", ")", ",", "void_WRAPPER_TYPE", "=", "makeCached", "(", "Void", ".", "class", ")", ",", "CLASS_Type", "=", "makeWithoutCaching", "(", "Class", ".", "class", ")", ",", "METACLASS_TYPE", "=", "makeCached", "(", "MetaClass", ".", "class", ")", ",", "GENERATED_CLOSURE_Type", "=", "makeCached", "(", "GeneratedClosure", ".", "class", ")", ",", "Enum_Type", "=", "new", "ClassNode", "(", "\"\"", ",", "0", ",", "OBJECT_TYPE", ")", ",", "Annotation_TYPE", "=", "new", "ClassNode", "(", "\"\"", ",", "0", ",", "OBJECT_TYPE", ")", ",", "ELEMENT_TYPE_TYPE", "=", "new", "ClassNode", "(", "\"\"", ",", "0", ",", "Enum_Type", ")", ";", "static", "{", "Enum_Type", ".", "isPrimaryNode", "=", "false", ";", "Annotation_TYPE", ".", "isPrimaryNode", "=", "false", ";", "}", "private", "static", "ClassNode", "[", "]", "types", "=", "new", "ClassNode", "[", "]", "{", "OBJECT_TYPE", ",", "boolean_TYPE", ",", "char_TYPE", ",", "byte_TYPE", ",", "short_TYPE", ",", "int_TYPE", ",", "long_TYPE", ",", "double_TYPE", ",", "float_TYPE", ",", "VOID_TYPE", ",", "CLOSURE_TYPE", ",", "GSTRING_TYPE", ",", "LIST_TYPE", ",", "MAP_TYPE", ",", "RANGE_TYPE", ",", "PATTERN_TYPE", ",", "SCRIPT_TYPE", ",", "STRING_TYPE", ",", "Boolean_TYPE", ",", "Character_TYPE", ",", "Byte_TYPE", ",", "Short_TYPE", ",", "Integer_TYPE", ",", "Long_TYPE", ",", "Double_TYPE", ",", "Float_TYPE", ",", "BigDecimal_TYPE", ",", "BigInteger_TYPE", ",", "void_WRAPPER_TYPE", ",", "REFERENCE_TYPE", ",", "CLASS_Type", ",", "METACLASS_TYPE", ",", "GENERATED_CLOSURE_Type", ",", "Enum_Type", ",", "Annotation_TYPE", "}", ";", "private", "static", "ClassNode", "[", "]", "numbers", "=", "new", "ClassNode", "[", "]", "{", "char_TYPE", ",", "byte_TYPE", ",", "short_TYPE", ",", "int_TYPE", ",", "long_TYPE", ",", "double_TYPE", ",", "float_TYPE", ",", "Short_TYPE", ",", "Byte_TYPE", ",", "Character_TYPE", ",", "Integer_TYPE", ",", "Float_TYPE", ",", "Long_TYPE", ",", "Double_TYPE", ",", "BigInteger_TYPE", ",", "BigDecimal_TYPE", "}", ";", "protected", "static", "final", "ClassNode", "[", "]", "EMPTY_TYPE_ARRAY", "=", "{", "}", ";", "public", "static", "final", "String", "OBJECT", "=", "\"\"", ";", "public", "static", "ClassNode", "makeCached", "(", "Class", "c", ")", "{", "final", "SoftReference", "<", "ClassNode", ">", "classNodeSoftReference", "=", "ClassHelperCache", ".", "classCache", ".", "get", "(", "c", ")", ";", "ClassNode", "classNode", ";", "if", "(", "classNodeSoftReference", "==", "null", "||", "(", "classNode", "=", "classNodeSoftReference", ".", "get", "(", ")", ")", "==", "null", ")", "{", "classNode", "=", "new", "ImmutableClassNode", "(", "c", ")", ";", "ClassHelperCache", ".", "classCache", ".", "put", "(", "c", ",", "new", "SoftReference", "<", "ClassNode", ">", "(", "classNode", ")", ")", ";", "VMPluginFactory", ".", "getPlugin", "(", ")", ".", "setAdditionalClassInformation", "(", "classNode", ")", ";", "}", "return", "classNode", ";", "}", "public", "static", "ClassNode", "[", "]", "make", "(", "Class", "[", "]", "classes", ")", "{", "ClassNode", "[", "]", "cns", "=", "new", "ClassNode", "[", "classes", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "cns", ".", "length", ";", "i", "++", ")", "{", "cns", "[", "i", "]", "=", "make", "(", "classes", "[", "i", "]", ")", ";", "}", "return", "cns", ";", "}", "public", "static", "ClassNode", "make", "(", "Class", "c", ")", "{", "return", "make", "(", "c", ",", "true", ")", ";", "}", "public", "static", "ClassNode", "make", "(", "Class", "c", ",", "boolean", "includeGenerics", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "classes", ".", "length", ";", "i", "++", ")", "{", "if", "(", "c", "==", "classes", "[", "i", "]", ")", "return", "types", "[", "i", "]", ";", "}", "if", "(", "c", ".", "isArray", "(", ")", ")", "{", "ClassNode", "cn", "=", "make", "(", "c", ".", "getComponentType", "(", ")", ",", "includeGenerics", ")", ";", "return", "cn", ".", "makeArray", "(", ")", ";", "}", "return", "makeWithoutCaching", "(", "c", ",", "includeGenerics", ")", ";", "}", "public", "static", "ClassNode", "makeWithoutCaching", "(", "Class", "c", ")", "{", "return", "makeWithoutCaching", "(", "c", ",", "true", ")", ";", "}", "public", "static", "ClassNode", "makeWithoutCaching", "(", "Class", "c", ",", "boolean", "includeGenerics", ")", "{", "if", "(", "c", ".", "isArray", "(", ")", ")", "{", "ClassNode", "cn", "=", "makeWithoutCaching", "(", "c", ".", "getComponentType", "(", ")", ",", "includeGenerics", ")", ";", "return", "cn", ".", "makeArray", "(", ")", ";", "}", "final", "ClassNode", "cached", "=", "makeCached", "(", "c", ")", ";", "if", "(", "includeGenerics", ")", "{", "return", "cached", ";", "}", "else", "{", "ClassNode", "t", "=", "makeWithoutCaching", "(", "c", ".", "getName", "(", ")", ")", ";", "t", ".", "setRedirect", "(", "cached", ")", ";", "return", "t", ";", "}", "}", "public", "static", "ClassNode", "makeWithoutCaching", "(", "String", "name", ")", "{", "ClassNode", "cn", "=", "new", "ClassNode", "(", "name", ",", "Opcodes", ".", "ACC_PUBLIC", ",", "OBJECT_TYPE", ")", ";", "cn", ".", "isPrimaryNode", "=", "false", ";", "return", "cn", ";", "}", "public", "static", "ClassNode", "make", "(", "String", "name", ")", "{", "if", "(", "name", "==", "null", "||", "name", ".", "length", "(", ")", "==", "0", ")", "return", "DYNAMIC_TYPE", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "primitiveClassNames", ".", "length", ";", "i", "++", ")", "{", "if", "(", "primitiveClassNames", "[", "i", "]", ".", "equals", "(", "name", ")", ")", "return", "types", "[", "i", "]", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "classes", ".", "length", ";", "i", "++", ")", "{", "String", "cname", "=", "classes", "[", "i", "]", ".", "getName", "(", ")", ";", "if", "(", "name", ".", "equals", "(", "cname", ")", ")", "return", "types", "[", "i", "]", ";", "}", "return", "makeWithoutCaching", "(", "name", ")", ";", "}", "public", "static", "ClassNode", "getWrapper", "(", "ClassNode", "cn", ")", "{", "cn", "=", "cn", ".", "redirect", "(", ")", ";", "if", "(", "!", "isPrimitiveType", "(", "cn", ")", ")", "return", "cn", ";", "if", "(", "cn", "==", "boolean_TYPE", ")", "{", "return", "Boolean_TYPE", ";", "}", "else", "if", "(", "cn", "==", "byte_TYPE", ")", "{", "return", "Byte_TYPE", ";", "}", "else", "if", "(", "cn", "==", "char_TYPE", ")", "{", "return", "Character_TYPE", ";", "}", "else", "if", "(", "cn", "==", "short_TYPE", ")", "{", "return", "Short_TYPE", ";", "}", "else", "if", "(", "cn", "==", "int_TYPE", ")", "{", "return", "Integer_TYPE", ";", "}", "else", "if", "(", "cn", "==", "long_TYPE", ")", "{", "return", "Long_TYPE", ";", "}", "else", "if", "(", "cn", "==", "float_TYPE", ")", "{", "return", "Float_TYPE", ";", "}", "else", "if", "(", "cn", "==", "double_TYPE", ")", "{", "return", "Double_TYPE", ";", "}", "else", "if", "(", "cn", "==", "VOID_TYPE", ")", "{", "return", "void_WRAPPER_TYPE", ";", "}", "else", "{", "return", "cn", ";", "}", "}", "public", "static", "ClassNode", "getUnwrapper", "(", "ClassNode", "cn", ")", "{", "cn", "=", "cn", ".", "redirect", "(", ")", ";", "if", "(", "isPrimitiveType", "(", "cn", ")", ")", "return", "cn", ";", "if", "(", "cn", "==", "Boolean_TYPE", ")", "{", "return", "boolean_TYPE", ";", "}", "else", "if", "(", "cn", "==", "Byte_TYPE", ")", "{", "return", "byte_TYPE", ";", "}", "else", "if", "(", "cn", "==", "Character_TYPE", ")", "{", "return", "char_TYPE", ";", "}", "else", "if", "(", "cn", "==", "Short_TYPE", ")", "{", "return", "short_TYPE", ";", "}", "else", "if", "(", "cn", "==", "Integer_TYPE", ")", "{", "return", "int_TYPE", ";", "}", "else", "if", "(", "cn", "==", "Long_TYPE", ")", "{", "return", "long_TYPE", ";", "}", "else", "if", "(", "cn", "==", "Float_TYPE", ")", "{", "return", "float_TYPE", ";", "}", "else", "if", "(", "cn", "==", "Double_TYPE", ")", "{", "return", "double_TYPE", ";", "}", "else", "{", "return", "cn", ";", "}", "}", "public", "static", "boolean", "isPrimitiveType", "(", "ClassNode", "cn", ")", "{", "return", "cn", "==", "boolean_TYPE", "||", "cn", "==", "char_TYPE", "||", "cn", "==", "byte_TYPE", "||", "cn", "==", "short_TYPE", "||", "cn", "==", "int_TYPE", "||", "cn", "==", "long_TYPE", "||", "cn", "==", "float_TYPE", "||", "cn", "==", "double_TYPE", "||", "cn", "==", "VOID_TYPE", ";", "}", "public", "static", "boolean", "isNumberType", "(", "ClassNode", "cn", ")", "{", "return", "cn", "==", "Byte_TYPE", "||", "cn", "==", "Short_TYPE", "||", "cn", "==", "Integer_TYPE", "||", "cn", "==", "Long_TYPE", "||", "cn", "==", "Float_TYPE", "||", "cn", "==", "Double_TYPE", "||", "cn", "==", "byte_TYPE", "||", "cn", "==", "short_TYPE", "||", "cn", "==", "int_TYPE", "||", "cn", "==", "long_TYPE", "||", "cn", "==", "float_TYPE", "||", "cn", "==", "double_TYPE", ";", "}", "public", "static", "ClassNode", "makeReference", "(", ")", "{", "return", "make", "(", "Reference", ".", "class", ")", ";", "}", "public", "static", "boolean", "isCachedType", "(", "ClassNode", "type", ")", "{", "for", "(", "ClassNode", "cachedType", ":", "types", ")", "{", "if", "(", "cachedType", "==", "type", ")", "return", "true", ";", "}", "return", "false", ";", "}", "static", "class", "ClassHelperCache", "{", "static", "Map", "<", "Class", ",", "SoftReference", "<", "ClassNode", ">", ">", "classCache", "=", "new", "WeakHashMap", "<", "Class", ",", "SoftReference", "<", "ClassNode", ">", ">", "(", ")", ";", "}", "}", "</s>" ]
6,732
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "GroovyBugError", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "util", ".", "ListHashMap", ";", "public", "class", "ASTNode", "{", "private", "int", "lineNumber", "=", "-", "1", ";", "private", "int", "columnNumber", "=", "-", "1", ";", "private", "int", "lastLineNumber", "=", "-", "1", ";", "private", "int", "lastColumnNumber", "=", "-", "1", ";", "private", "ListHashMap", "metaDataMap", "=", "new", "ListHashMap", "(", ")", ";", "private", "int", "start", "=", "0", ";", "private", "int", "end", "=", "0", ";", "public", "void", "visit", "(", "GroovyCodeVisitor", "visitor", ")", "{", "throw", "new", "RuntimeException", "(", "\"\"", "+", "getClass", "(", ")", ".", "getName", "(", ")", ")", ";", "}", "public", "String", "getText", "(", ")", "{", "return", "\"\"", "+", "getClass", "(", ")", ".", "getName", "(", ")", "+", "\">\"", ";", "}", "public", "int", "getLineNumber", "(", ")", "{", "return", "lineNumber", ";", "}", "public", "void", "setLineNumber", "(", "int", "lineNumber", ")", "{", "this", ".", "lineNumber", "=", "lineNumber", ";", "}", "public", "int", "getColumnNumber", "(", ")", "{", "return", "columnNumber", ";", "}", "public", "void", "setColumnNumber", "(", "int", "columnNumber", ")", "{", "this", ".", "columnNumber", "=", "columnNumber", ";", "}", "public", "int", "getLastLineNumber", "(", ")", "{", "return", "lastLineNumber", ";", "}", "public", "void", "setLastLineNumber", "(", "int", "lastLineNumber", ")", "{", "this", ".", "lastLineNumber", "=", "lastLineNumber", ";", "}", "public", "int", "getLastColumnNumber", "(", ")", "{", "return", "lastColumnNumber", ";", "}", "public", "void", "setLastColumnNumber", "(", "int", "lastColumnNumber", ")", "{", "this", ".", "lastColumnNumber", "=", "lastColumnNumber", ";", "}", "public", "int", "getStart", "(", ")", "{", "return", "start", ";", "}", "public", "void", "setStart", "(", "int", "start", ")", "{", "this", ".", "start", "=", "start", ";", "}", "public", "int", "getEnd", "(", ")", "{", "return", "end", ";", "}", "public", "void", "setEnd", "(", "int", "end", ")", "{", "this", ".", "end", "=", "end", ";", "}", "public", "int", "getLength", "(", ")", "{", "return", "end", ">=", "0", "&&", "start", ">=", "0", "?", "end", "-", "start", ":", "-", "1", ";", "}", "public", "void", "setSourcePosition", "(", "ASTNode", "node", ")", "{", "this", ".", "columnNumber", "=", "node", ".", "getColumnNumber", "(", ")", ";", "this", ".", "lastLineNumber", "=", "node", ".", "getLastLineNumber", "(", ")", ";", "this", ".", "lastColumnNumber", "=", "node", ".", "getLastColumnNumber", "(", ")", ";", "this", ".", "lineNumber", "=", "node", ".", "getLineNumber", "(", ")", ";", "this", ".", "start", "=", "node", ".", "getStart", "(", ")", ";", "this", ".", "end", "=", "node", ".", "getEnd", "(", ")", ";", "}", "public", "Object", "getNodeMetaData", "(", "Object", "key", ")", "{", "return", "metaDataMap", ".", "get", "(", "key", ")", ";", "}", "public", "void", "copyNodeMetaData", "(", "ASTNode", "other", ")", "{", "metaDataMap", ".", "putAll", "(", "other", ".", "metaDataMap", ")", ";", "}", "public", "void", "setNodeMetaData", "(", "Object", "key", ",", "Object", "value", ")", "{", "if", "(", "key", "==", "null", ")", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "this", "+", "\".\"", ")", ";", "Object", "old", "=", "metaDataMap", ".", "put", "(", "key", ",", "value", ")", ";", "if", "(", "old", "!=", "null", ")", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "this", "+", "\".\"", ")", ";", "}", "public", "void", "removeNodeMetaData", "(", "Object", "key", ")", "{", "if", "(", "key", "==", "null", ")", "throw", "new", "GroovyBugError", "(", "\"\"", ")", ";", "metaDataMap", ".", "remove", "(", "key", ")", ";", "if", "(", "metaDataMap", ".", "size", "(", ")", "==", "0", ")", "metaDataMap", "=", "null", ";", "}", "}", "</s>" ]
6,733
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "List", ";", "public", "abstract", "class", "Comment", "{", "protected", "static", "final", "int", "BLOCK", "=", "0", ";", "protected", "static", "final", "int", "LINE", "=", "1", ";", "protected", "static", "final", "int", "JAVADOC", "=", "2", ";", "protected", "static", "final", "boolean", "debug", "=", "false", ";", "protected", "String", "comment", ";", "private", "int", "kind", ";", "public", "boolean", "usedUp", "=", "false", ";", "public", "int", "sline", ",", "scol", ",", "eline", ",", "ecol", ";", "public", "Comment", "(", "int", "kind", ",", "int", "sline", ",", "int", "scol", ",", "int", "eline", ",", "int", "ecol", ",", "String", "string", ")", "{", "this", ".", "kind", "=", "kind", ";", "this", ".", "sline", "=", "sline", ";", "this", ".", "scol", "=", "scol", ";", "this", ".", "eline", "=", "eline", ";", "this", ".", "ecol", "=", "ecol", ";", "this", ".", "comment", "=", "string", ";", "}", "public", "int", "getLastLine", "(", ")", "{", "return", "eline", ";", "}", "public", "static", "Comment", "makeSingleLineComment", "(", "int", "sline", ",", "int", "scol", ",", "int", "eline", ",", "int", "ecol", ",", "String", "string", ")", "{", "return", "new", "SingleLineComment", "(", "sline", ",", "scol", ",", "eline", ",", "ecol", ",", "string", ")", ";", "}", "public", "static", "Comment", "makeMultiLineComment", "(", "int", "sline", ",", "int", "scol", ",", "int", "eline", ",", "int", "ecol", ",", "String", "string", ")", "{", "return", "new", "MultiLineComment", "(", "sline", ",", "scol", ",", "eline", ",", "ecol", ",", "string", ")", ";", "}", "public", "abstract", "List", "<", "TaskEntry", ">", "getPositionsOf", "(", "String", "taskTag", ",", "String", "taskPriority", ",", "int", "[", "]", "lineseps", ",", "boolean", "caseSensitive", ")", ";", "public", "int", "[", "]", "getPositions", "(", "int", "[", "]", "lineseps", ")", "{", "int", "offsetToStartLine", "=", "(", "sline", "==", "1", "?", "0", ":", "lineseps", "[", "sline", "-", "2", "]", "+", "1", ")", ";", "int", "start", "=", "offsetToStartLine", "+", "(", "scol", "-", "1", ")", ";", "int", "offsetToEndLine", "=", "(", "eline", "==", "1", "?", "0", ":", "lineseps", "[", "eline", "-", "2", "]", "+", "1", ")", ";", "int", "end", "=", "offsetToEndLine", "+", "(", "ecol", "-", "1", ")", ";", "if", "(", "kind", "==", "LINE", ")", "{", "return", "new", "int", "[", "]", "{", "-", "start", ",", "-", "end", "}", ";", "}", "else", "if", "(", "kind", "==", "BLOCK", ")", "{", "return", "new", "int", "[", "]", "{", "start", ",", "-", "end", "}", ";", "}", "else", "{", "return", "new", "int", "[", "]", "{", "start", ",", "end", "}", ";", "}", "}", "public", "String", "toString", "(", ")", "{", "return", "comment", ";", "}", "protected", "boolean", "isValidStartLocationForTask", "(", "String", "text", ",", "int", "index", ",", "String", "taskTag", ")", "{", "int", "tagLen", "=", "taskTag", ".", "length", "(", ")", ";", "if", "(", "comment", ".", "charAt", "(", "index", "-", "1", ")", "==", "'@'", ")", "{", "return", "false", ";", "}", "if", "(", "Character", ".", "isJavaIdentifierStart", "(", "comment", ".", "charAt", "(", "index", ")", ")", ")", "{", "if", "(", "Character", ".", "isJavaIdentifierPart", "(", "comment", ".", "charAt", "(", "index", "-", "1", ")", ")", ")", "{", "return", "false", ";", "}", "}", "if", "(", "(", "index", "+", "tagLen", ")", "<", "comment", ".", "length", "(", ")", "&&", "Character", ".", "isJavaIdentifierStart", "(", "comment", ".", "charAt", "(", "index", "+", "tagLen", "-", "1", ")", ")", ")", "{", "if", "(", "Character", ".", "isJavaIdentifierPart", "(", "comment", ".", "charAt", "(", "index", "+", "tagLen", ")", ")", ")", "{", "return", "false", ";", "}", "}", "return", "true", ";", "}", "protected", "int", "findTaskTag", "(", "String", "text", ",", "String", "tag", ",", "boolean", "caseSensitive", ",", "int", "fromIndex", ")", "{", "if", "(", "caseSensitive", ")", "{", "return", "text", ".", "indexOf", "(", "tag", ",", "fromIndex", ")", ";", "}", "else", "{", "int", "taglen", "=", "tag", ".", "length", "(", ")", ";", "String", "lcTag", "=", "tag", ".", "toLowerCase", "(", ")", ";", "char", "firstChar", "=", "lcTag", ".", "charAt", "(", "0", ")", ";", "for", "(", "int", "p", "=", "fromIndex", ",", "max", "=", "text", ".", "length", "(", ")", "-", "tag", ".", "length", "(", ")", "+", "1", ";", "p", "<", "max", ";", "p", "++", ")", "{", "if", "(", "Character", ".", "toLowerCase", "(", "text", ".", "charAt", "(", "p", ")", ")", "==", "firstChar", ")", "{", "boolean", "matched", "=", "true", ";", "for", "(", "int", "t", "=", "1", ";", "t", "<", "taglen", ";", "t", "++", ")", "{", "if", "(", "Character", ".", "toLowerCase", "(", "text", ".", "charAt", "(", "p", "+", "t", ")", ")", "!=", "lcTag", ".", "charAt", "(", "t", ")", ")", "{", "matched", "=", "false", ";", "break", ";", "}", "}", "if", "(", "matched", ")", "{", "return", "p", ";", "}", "}", "}", "return", "-", "1", ";", "}", "}", "public", "boolean", "isJavadoc", "(", ")", "{", "return", "kind", "==", "JAVADOC", ";", "}", "}", "class", "SingleLineComment", "extends", "Comment", "{", "public", "SingleLineComment", "(", "int", "sline", ",", "int", "scol", ",", "int", "eline", ",", "int", "ecol", ",", "String", "string", ")", "{", "super", "(", "LINE", ",", "sline", ",", "scol", ",", "eline", ",", "ecol", ",", "string", ")", ";", "if", "(", "debug", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "string", "+", "\"]", "at", "L\"", "+", "sline", "+", "\"C\"", "+", "scol", "+", "\">L\"", "+", "eline", "+", "\"C\"", "+", "ecol", ")", ";", "}", "}", "public", "List", "<", "TaskEntry", ">", "getPositionsOf", "(", "String", "taskTag", ",", "String", "taskPriority", ",", "int", "[", "]", "lineseps", ",", "boolean", "caseSensitive", ")", "{", "int", "i", "=", "findTaskTag", "(", "comment", ",", "taskTag", ",", "caseSensitive", ",", "0", ")", ";", "if", "(", "debug", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "comment", "+", "\"]", "for", "'\"", "+", "taskTag", "+", "\"'", "\"", "+", "i", ")", ";", "}", "if", "(", "i", "==", "-", "1", ")", "{", "return", "Collections", ".", "emptyList", "(", ")", ";", "}", "List", "<", "TaskEntry", ">", "tasks", "=", "new", "ArrayList", "<", "TaskEntry", ">", "(", ")", ";", "while", "(", "i", "!=", "-", "1", ")", "{", "if", "(", "isValidStartLocationForTask", "(", "comment", ",", "i", ",", "taskTag", ")", ")", "{", "int", "offsetToLineStart", "=", "(", "sline", "==", "1", "?", "0", ":", "lineseps", "[", "sline", "-", "2", "]", "+", "1", ")", ";", "int", "taskTagStart", "=", "offsetToLineStart", "+", "(", "scol", "-", "1", ")", "+", "i", ";", "int", "taskEnd", "=", "offsetToLineStart", "+", "ecol", "-", "2", ";", "TaskEntry", "taskEntry", "=", "new", "TaskEntry", "(", "taskTagStart", ",", "taskEnd", ",", "taskTag", ",", "taskPriority", ",", "comment", ",", "offsetToLineStart", "+", "scol", "-", "1", ")", ";", "if", "(", "debug", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "taskEntry", ".", "toString", "(", ")", ")", ";", "}", "tasks", ".", "add", "(", "taskEntry", ")", ";", "}", "i", "=", "findTaskTag", "(", "comment", ",", "taskTag", ",", "caseSensitive", ",", "i", "+", "taskTag", ".", "length", "(", ")", ")", ";", "}", "return", "tasks", ";", "}", "}", "class", "MultiLineComment", "extends", "Comment", "{", "public", "MultiLineComment", "(", "int", "sline", ",", "int", "scol", ",", "int", "eline", ",", "int", "ecol", ",", "String", "string", ")", "{", "super", "(", "string", ".", "charAt", "(", "2", ")", "==", "'*'", "?", "JAVADOC", ":", "BLOCK", ",", "sline", ",", "scol", ",", "eline", ",", "ecol", ",", "string", ")", ";", "if", "(", "debug", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "string", "+", "\"]", "at", "L\"", "+", "sline", "+", "\"C\"", "+", "scol", "+", "\">L\"", "+", "eline", "+", "\"C\"", "+", "ecol", ")", ";", "}", "}", "@", "Override", "public", "List", "<", "TaskEntry", ">", "getPositionsOf", "(", "String", "taskTag", ",", "String", "taskPriority", ",", "int", "[", "]", "lineseps", ",", "boolean", "caseSensitive", ")", "{", "int", "i", "=", "findTaskTag", "(", "comment", ",", "taskTag", ",", "caseSensitive", ",", "0", ")", ";", "if", "(", "debug", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "comment", "+", "\"]", "for", "'\"", "+", "taskTag", "+", "\"'", "\"", "+", "i", ")", ";", "}", "if", "(", "i", "==", "-", "1", ")", "{", "return", "Collections", ".", "emptyList", "(", ")", ";", "}", "List", "<", "TaskEntry", ">", "taskPositions", "=", "new", "ArrayList", "<", "TaskEntry", ">", "(", ")", ";", "while", "(", "i", "!=", "-", "1", ")", "{", "if", "(", "isValidStartLocationForTask", "(", "comment", ",", "i", ",", "taskTag", ")", ")", "{", "int", "offsetToCommentStart", "=", "(", "sline", "==", "1", "?", "0", ":", "lineseps", "[", "sline", "-", "2", "]", "+", "1", ")", "+", "scol", "-", "1", ";", "int", "taskTagStart", "=", "offsetToCommentStart", "+", "i", ";", "int", "taskEnd", "=", "taskTagStart", ";", "while", "(", "true", ")", "{", "int", "pos", "=", "taskEnd", "-", "offsetToCommentStart", ";", "char", "ch", "=", "comment", ".", "charAt", "(", "pos", ")", ";", "if", "(", "ch", "==", "'\\n'", "||", "ch", "==", "'\\r'", ")", "{", "break", ";", "}", "if", "(", "(", "pos", "+", "2", ")", ">", "comment", ".", "length", "(", ")", ")", "{", "taskEnd", "--", ";", "break", ";", "}", "taskEnd", "++", ";", "}", "TaskEntry", "taskEntry", "=", "new", "TaskEntry", "(", "taskTagStart", ",", "taskEnd", "-", "1", ",", "taskTag", ",", "taskPriority", ",", "comment", ",", "offsetToCommentStart", ")", ";", "if", "(", "debug", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "taskEntry", ".", "toString", "(", ")", ")", ";", "}", "taskPositions", ".", "add", "(", "taskEntry", ")", ";", "}", "i", "=", "findTaskTag", "(", "comment", ",", "taskTag", ",", "caseSensitive", ",", "i", "+", "taskTag", ".", "length", "(", ")", ")", ";", "}", "return", "taskPositions", ";", "}", "}", "</s>" ]
6,734
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "ast", ";", "import", "groovy", ".", "lang", ".", "GroovyClassLoader", ";", "import", "java", ".", "security", ".", "CodeSource", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilerConfiguration", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "messages", ".", "SyntaxErrorMessage", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "SyntaxException", ";", "public", "class", "CompileUnit", "{", "private", "final", "List", "<", "ModuleNode", ">", "modules", "=", "new", "ArrayList", "<", "ModuleNode", ">", "(", ")", ";", "private", "List", "<", "ModuleNode", ">", "sortedModules", ";", "private", "Map", "<", "String", ",", "ClassNode", ">", "classes", "=", "new", "HashMap", "<", "String", ",", "ClassNode", ">", "(", ")", ";", "private", "CompilerConfiguration", "config", ";", "private", "GroovyClassLoader", "classLoader", ";", "private", "CodeSource", "codeSource", ";", "private", "Map", "<", "String", ",", "ClassNode", ">", "classesToCompile", "=", "new", "HashMap", "<", "String", ",", "ClassNode", ">", "(", ")", ";", "private", "Map", "<", "String", ",", "SourceUnit", ">", "classNameToSource", "=", "new", "HashMap", "<", "String", ",", "SourceUnit", ">", "(", ")", ";", "public", "CompileUnit", "(", "GroovyClassLoader", "classLoader", ",", "CompilerConfiguration", "config", ")", "{", "this", "(", "classLoader", ",", "null", ",", "config", ")", ";", "}", "public", "CompileUnit", "(", "GroovyClassLoader", "classLoader", ",", "CodeSource", "codeSource", ",", "CompilerConfiguration", "config", ")", "{", "this", ".", "classLoader", "=", "classLoader", ";", "this", ".", "config", "=", "config", ";", "this", ".", "codeSource", "=", "codeSource", ";", "}", "public", "List", "<", "ModuleNode", ">", "getModules", "(", ")", "{", "return", "modules", ";", "}", "public", "void", "addModule", "(", "ModuleNode", "node", ")", "{", "if", "(", "node", "==", "null", ")", "return", ";", "modules", ".", "add", "(", "node", ")", ";", "this", ".", "sortedModules", "=", "null", ";", "node", ".", "setUnit", "(", "this", ")", ";", "addClasses", "(", "node", ".", "getClasses", "(", ")", ")", ";", "}", "public", "ClassNode", "getClass", "(", "String", "name", ")", "{", "ClassNode", "cn", "=", "classes", ".", "get", "(", "name", ")", ";", "if", "(", "cn", "!=", "null", ")", "return", "cn", ";", "return", "classesToCompile", ".", "get", "(", "name", ")", ";", "}", "public", "List", "getClasses", "(", ")", "{", "List", "<", "ClassNode", ">", "answer", "=", "new", "ArrayList", "<", "ClassNode", ">", "(", ")", ";", "for", "(", "ModuleNode", "module", ":", "modules", ")", "{", "answer", ".", "addAll", "(", "module", ".", "getClasses", "(", ")", ")", ";", "}", "return", "answer", ";", "}", "public", "CompilerConfiguration", "getConfig", "(", ")", "{", "return", "config", ";", "}", "public", "GroovyClassLoader", "getClassLoader", "(", ")", "{", "return", "classLoader", ";", "}", "public", "CodeSource", "getCodeSource", "(", ")", "{", "return", "codeSource", ";", "}", "void", "addClasses", "(", "List", "<", "ClassNode", ">", "classList", ")", "{", "for", "(", "ClassNode", "node", ":", "classList", ")", "{", "addClass", "(", "node", ")", ";", "}", "}", "public", "void", "addClass", "(", "ClassNode", "node", ")", "{", "node", "=", "node", ".", "redirect", "(", ")", ";", "String", "name", "=", "node", ".", "getName", "(", ")", ";", "ClassNode", "stored", "=", "classes", ".", "get", "(", "name", ")", ";", "if", "(", "stored", "!=", "null", "&&", "stored", "!=", "node", ")", "{", "SourceUnit", "nodeSource", "=", "node", ".", "getModule", "(", ")", ".", "getContext", "(", ")", ";", "SourceUnit", "storedSource", "=", "stored", ".", "getModule", "(", ")", ".", "getContext", "(", ")", ";", "String", "txt", "=", "\"\"", "+", "node", ".", "getName", "(", ")", "+", "\"", ":", "\"", ";", "if", "(", "nodeSource", "==", "storedSource", ")", "{", "txt", "+=", "\"The", "source", "\"", "+", "nodeSource", ".", "getName", "(", ")", "+", "\"\"", "+", "node", ".", "getName", "(", ")", "+", "\".n\"", ";", "if", "(", "node", ".", "isScriptBody", "(", ")", "||", "stored", ".", "isScriptBody", "(", ")", ")", "{", "txt", "+=", "\"\"", "+", "\"\"", ";", "}", "}", "else", "{", "txt", "+=", "\"The", "sources", "\"", "+", "nodeSource", ".", "getName", "(", ")", "+", "\"", "and", "\"", "+", "storedSource", ".", "getName", "(", ")", "+", "\"\"", "+", "node", ".", "getName", "(", ")", "+", "\".n\"", ";", "}", "nodeSource", ".", "getErrorCollector", "(", ")", ".", "addErrorAndContinue", "(", "new", "SyntaxErrorMessage", "(", "new", "SyntaxException", "(", "txt", ",", "node", ".", "getLineNumber", "(", ")", ",", "node", ".", "getColumnNumber", "(", ")", ")", ",", "nodeSource", ")", ")", ";", "}", "classes", ".", "put", "(", "name", ",", "node", ")", ";", "if", "(", "classesToCompile", ".", "containsKey", "(", "name", ")", ")", "{", "ClassNode", "cn", "=", "classesToCompile", ".", "get", "(", "name", ")", ";", "cn", ".", "setRedirect", "(", "node", ")", ";", "classesToCompile", ".", "remove", "(", "name", ")", ";", "}", "}", "public", "void", "addClassNodeToCompile", "(", "ClassNode", "node", ",", "SourceUnit", "location", ")", "{", "classesToCompile", ".", "put", "(", "node", ".", "getName", "(", ")", ",", "node", ")", ";", "classNameToSource", ".", "put", "(", "node", ".", "getName", "(", ")", ",", "location", ")", ";", "}", "public", "SourceUnit", "getScriptSourceLocation", "(", "String", "className", ")", "{", "return", "classNameToSource", ".", "get", "(", "className", ")", ";", "}", "public", "boolean", "hasClassNodeToCompile", "(", ")", "{", "return", "!", "classesToCompile", ".", "isEmpty", "(", ")", ";", "}", "public", "Iterator", "<", "String", ">", "iterateClassNodeToCompile", "(", ")", "{", "return", "classesToCompile", ".", "keySet", "(", ")", ".", "iterator", "(", ")", ";", "}", "public", "List", "<", "ModuleNode", ">", "getSortedModules", "(", ")", "{", "return", "this", ".", "sortedModules", ";", "}", "public", "void", "setSortedModules", "(", "List", "<", "ModuleNode", ">", "sortedModules", ")", "{", "this", ".", "sortedModules", "=", "sortedModules", ";", "}", "}", "</s>" ]
6,735
[ "<s>", "package", "org", ".", "codehaus", ".", "greclipse", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "antlr", ".", "parser", ".", "GroovyTokenTypes", ";", "public", "class", "GroovyTokenTypeBridge", "{", "public", "static", "int", "IDENT", "=", "GroovyTokenTypes", ".", "IDENT", ";", "public", "static", "int", "LBRACK", "=", "GroovyTokenTypes", ".", "LBRACK", ";", "public", "static", "int", "LCURLY", "=", "GroovyTokenTypes", ".", "LCURLY", ";", "public", "static", "int", "LPAREN", "=", "GroovyTokenTypes", ".", "LPAREN", ";", "public", "static", "int", "NLS", "=", "GroovyTokenTypes", ".", "NLS", ";", "public", "static", "int", "RPAREN", "=", "GroovyTokenTypes", ".", "RPAREN", ";", "public", "static", "int", "STRING_CTOR_START", "=", "GroovyTokenTypes", ".", "STRING_CTOR_START", ";", "public", "static", "int", "WS", "=", "GroovyTokenTypes", ".", "WS", ";", "public", "static", "int", "COMMA", "=", "GroovyTokenTypes", ".", "COMMA", ";", "public", "static", "int", "SEMI", "=", "GroovyTokenTypes", ".", "SEMI", ";", "public", "static", "int", "RCURLY", "=", "GroovyTokenTypes", ".", "RCURLY", ";", "public", "static", "int", "SL_COMMENT", "=", "GroovyTokenTypes", ".", "SL_COMMENT", ";", "public", "static", "int", "CLOSABLE_BLOCK_OP", "=", "GroovyTokenTypes", ".", "CLOSABLE_BLOCK_OP", ";", "public", "static", "int", "EOF", "=", "GroovyTokenTypes", ".", "EOF", ";", "public", "static", "int", "LITERAL_if", "=", "GroovyTokenTypes", ".", "LITERAL_if", ";", "public", "static", "int", "LITERAL_else", "=", "GroovyTokenTypes", ".", "LITERAL_else", ";", "public", "static", "int", "LITERAL_for", "=", "GroovyTokenTypes", ".", "LITERAL_for", ";", "public", "static", "int", "LITERAL_switch", "=", "GroovyTokenTypes", ".", "LITERAL_switch", ";", "public", "static", "int", "LITERAL_while", "=", "GroovyTokenTypes", ".", "LITERAL_while", ";", "public", "static", "int", "RBRACK", "=", "GroovyTokenTypes", ".", "RBRACK", ";", "public", "static", "int", "ML_COMMENT", "=", "GroovyTokenTypes", ".", "ML_COMMENT", ";", "public", "static", "int", "STRING_CTOR_END", "=", "GroovyTokenTypes", ".", "STRING_CTOR_END", ";", "public", "static", "int", "LITERAL_as", "=", "GroovyTokenTypes", ".", "LITERAL_as", ";", "}", "</s>" ]
6,736
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "eclipse", ";", "import", "java", ".", "util", ".", "Date", ";", "@", "SuppressWarnings", "(", "\"nls\"", ")", "public", "class", "DefaultGroovyLogger", "implements", "IGroovyLogger", "{", "public", "void", "log", "(", "TraceCategory", "category", ",", "String", "message", ")", "{", "System", ".", "out", ".", "println", "(", "category", ".", "label", "+", "\"", ":", "\"", "+", "new", "Date", "(", ")", "+", "\"", ":", "\"", "+", "message", ")", ";", "}", "public", "boolean", "isCategoryEnabled", "(", "TraceCategory", "category", ")", "{", "return", "true", ";", "}", "}", "</s>" ]
6,737
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "eclipse", ";", "import", "junit", ".", "framework", ".", "TestCase", ";", "public", "class", "LoggerTest", "extends", "TestCase", "{", "public", "void", "testLoggers", "(", ")", "throws", "Exception", "{", "DefaultGroovyLogger", "l1", "=", "new", "DefaultGroovyLogger", "(", ")", ";", "DefaultGroovyLogger", "l2", "=", "new", "DefaultGroovyLogger", "(", ")", ";", "DefaultGroovyLogger", "l3", "=", "new", "DefaultGroovyLogger", "(", ")", ";", "DefaultGroovyLogger", "l4", "=", "new", "DefaultGroovyLogger", "(", ")", ";", "DefaultGroovyLogger", "l5", "=", "new", "DefaultGroovyLogger", "(", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l1", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l1", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l2", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l2", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l3", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l3", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l4", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l4", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l5", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l5", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l1", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l1", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l2", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l2", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l3", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l3", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l4", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l4", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l5", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l5", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l1", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l1", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l2", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l2", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l3", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l3", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l4", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l4", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l5", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l5", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l5", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l5", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l4", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l4", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l3", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l3", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l2", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l2", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l1", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l1", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l1", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l1", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l2", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l2", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l3", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l3", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l4", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l4", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l5", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "addLogger", "(", "l5", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l3", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l3", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l2", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l2", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l4", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l4", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l5", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l5", ")", ")", ";", "assertTrue", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l1", ")", ")", ";", "assertFalse", "(", "GroovyLogManager", ".", "manager", ".", "removeLogger", "(", "l1", ")", ")", ";", "}", "}", "</s>" ]
6,738
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "eclipse", ";", "import", "java", ".", "io", ".", "PrintWriter", ";", "import", "java", ".", "io", ".", "StringWriter", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Map", ";", "public", "class", "GroovyLogManager", "{", "public", "static", "final", "GroovyLogManager", "manager", "=", "new", "GroovyLogManager", "(", ")", ";", "private", "GroovyLogManager", "(", ")", "{", "defaultLogger", "=", "new", "DefaultGroovyLogger", "(", ")", ";", "timers", "=", "new", "HashMap", "<", "String", ",", "Long", ">", "(", ")", ";", "}", "private", "IGroovyLogger", "[", "]", "loggers", "=", "null", ";", "private", "IGroovyLogger", "defaultLogger", ";", "private", "Map", "<", "String", ",", "Long", ">", "timers", ";", "private", "boolean", "useDefaultLogger", ";", "public", "boolean", "addLogger", "(", "IGroovyLogger", "logger", ")", "{", "int", "newIndex", ";", "if", "(", "loggers", "==", "null", ")", "{", "loggers", "=", "new", "IGroovyLogger", "[", "1", "]", ";", "newIndex", "=", "0", ";", "}", "else", "{", "for", "(", "IGroovyLogger", "l", ":", "loggers", ")", "{", "if", "(", "l", "==", "logger", ")", "{", "return", "false", ";", "}", "}", "newIndex", "=", "loggers", ".", "length", ";", "IGroovyLogger", "[", "]", "newLoggers", "=", "new", "IGroovyLogger", "[", "newIndex", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "loggers", ",", "0", ",", "newLoggers", ",", "0", ",", "newIndex", ")", ";", "loggers", "=", "newLoggers", ";", "}", "loggers", "[", "newIndex", "]", "=", "logger", ";", "return", "true", ";", "}", "public", "boolean", "removeLogger", "(", "IGroovyLogger", "logger", ")", "{", "if", "(", "logger", "!=", "null", ")", "{", "int", "foundIndex", "=", "-", "1", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "loggers", ".", "length", ";", "i", "++", ")", "{", "if", "(", "loggers", "[", "i", "]", "==", "logger", ")", "{", "foundIndex", "=", "i", ";", "}", "}", "if", "(", "foundIndex", ">=", "0", ")", "{", "if", "(", "loggers", ".", "length", ">", "1", ")", "{", "IGroovyLogger", "[", "]", "newLoggers", "=", "new", "IGroovyLogger", "[", "loggers", ".", "length", "-", "1", "]", ";", "if", "(", "foundIndex", ">", "0", ")", "{", "System", ".", "arraycopy", "(", "loggers", ",", "0", ",", "newLoggers", ",", "0", ",", "foundIndex", ")", ";", "}", "System", ".", "arraycopy", "(", "loggers", ",", "foundIndex", "+", "1", ",", "newLoggers", ",", "foundIndex", ",", "loggers", ".", "length", "-", "foundIndex", "-", "1", ")", ";", "loggers", "=", "newLoggers", ";", "}", "else", "{", "loggers", "=", "null", ";", "}", "return", "true", ";", "}", "}", "return", "false", ";", "}", "public", "void", "logStart", "(", "String", "event", ")", "{", "timers", ".", "put", "(", "event", ",", "System", ".", "currentTimeMillis", "(", ")", ")", ";", "}", "public", "void", "logEnd", "(", "String", "event", ",", "TraceCategory", "category", ")", "{", "logEnd", "(", "event", ",", "category", ",", "null", ")", ";", "}", "public", "void", "logEnd", "(", "String", "event", ",", "TraceCategory", "category", ",", "String", "message", ")", "{", "Long", "then", "=", "timers", ".", "get", "(", "event", ")", ";", "if", "(", "then", "!=", "null", ")", "{", "if", "(", "hasLoggers", "(", ")", ")", "{", "long", "now", "=", "System", ".", "currentTimeMillis", "(", ")", ";", "long", "elapsed", "=", "now", "-", "then", ".", "longValue", "(", ")", ";", "if", "(", "(", "message", "!=", "null", ")", "&&", "(", "message", ".", "length", "(", ")", ">", "0", ")", ")", "{", "log", "(", "category", ",", "\"\"", "+", "elapsed", "+", "\"ms:", "\"", "+", "event", "+", "\"", "(\"", "+", "message", "+", "\")\"", ")", ";", "}", "else", "{", "log", "(", "category", ",", "\"\"", "+", "elapsed", "+", "\"ms:", "\"", "+", "event", ")", ";", "}", "}", "timers", ".", "remove", "(", "event", ")", ";", "}", "}", "public", "void", "log", "(", "String", "message", ")", "{", "log", "(", "TraceCategory", ".", "DEFAULT", ",", "message", ")", ";", "}", "public", "void", "log", "(", "TraceCategory", "category", ",", "String", "message", ")", "{", "if", "(", "!", "hasLoggers", "(", ")", ")", "{", "return", ";", "}", "if", "(", "loggers", "!=", "null", ")", "{", "for", "(", "IGroovyLogger", "logger", ":", "loggers", ")", "{", "if", "(", "logger", ".", "isCategoryEnabled", "(", "category", ")", ")", "{", "logger", ".", "log", "(", "category", ",", "message", ")", ";", "}", "}", "}", "if", "(", "useDefaultLogger", ")", "{", "defaultLogger", ".", "log", "(", "category", ",", "message", ")", ";", "}", "}", "public", "boolean", "hasLoggers", "(", ")", "{", "return", "loggers", "!=", "null", "||", "useDefaultLogger", ";", "}", "public", "void", "setUseDefaultLogger", "(", "boolean", "useDefaultLogger", ")", "{", "this", ".", "useDefaultLogger", "=", "useDefaultLogger", ";", "}", "public", "void", "logException", "(", "TraceCategory", "cat", ",", "Throwable", "t", ")", "{", "if", "(", "hasLoggers", "(", ")", ")", "{", "StringWriter", "writer", "=", "new", "StringWriter", "(", ")", ";", "t", ".", "printStackTrace", "(", "new", "PrintWriter", "(", "writer", ")", ")", ";", "log", "(", "cat", ",", "\"\"", "+", "writer", ".", "getBuffer", "(", ")", ")", ";", "}", "}", "}", "</s>" ]
6,739
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "eclipse", ";", "public", "interface", "IGroovyLogger", "{", "void", "log", "(", "TraceCategory", "category", ",", "String", "message", ")", ";", "boolean", "isCategoryEnabled", "(", "TraceCategory", "category", ")", ";", "}", "</s>" ]
6,740
[ "<s>", "package", "org", ".", "codehaus", ".", "groovy", ".", "eclipse", ";", "import", "java", ".", "util", ".", "Arrays", ";", "@", "SuppressWarnings", "(", "\"nls\"", ")", "public", "enum", "TraceCategory", "{", "DEFAULT", "(", "\"_\"", ")", ",", "CLASSPATH", "(", "\"Classpath\"", ")", ",", "REFACTORING", "(", "\"Refactoring\"", ")", ",", "COMPILER", "(", "\"Compiler\"", ")", ",", "DSL", "(", "\"DSL\"", ")", ",", "CODESELECT", "(", "\"Code", "select\"", ")", ",", "CONTENT_ASSIST", "(", "\"\"", ")", ",", "AST_TRANSFORM", "(", "\"\"", ")", ";", "TraceCategory", "(", "String", "label", ")", "{", "this", ".", "label", "=", "label", ";", "}", "public", "final", "String", "label", ";", "private", "String", "paddedLabel", ";", "public", "String", "getPaddedLabel", "(", ")", "{", "if", "(", "paddedLabel", "==", "null", ")", "{", "synchronized", "(", "TraceCategory", ".", "class", ")", "{", "if", "(", "longestLabel", "==", "-", "1", ")", "{", "calculateLongest", "(", ")", ";", "}", "}", "int", "extraSpace", "=", "longestLabel", "-", "label", ".", "length", "(", ")", ";", "paddedLabel", "=", "spaces", "(", "extraSpace", ")", "+", "label", ";", "}", "return", "paddedLabel", ";", "}", "private", "String", "spaces", "(", "int", "extraSpace", ")", "{", "char", "[", "]", "a", "=", "new", "char", "[", "extraSpace", "]", ";", "Arrays", ".", "fill", "(", "a", ",", "'", "'", ")", ";", "return", "new", "String", "(", "a", ")", ";", "}", "private", "static", "void", "calculateLongest", "(", ")", "{", "int", "maybeLongest", "=", "longestLabel", ";", "for", "(", "TraceCategory", "category", ":", "values", "(", ")", ")", "{", "maybeLongest", "=", "Math", ".", "max", "(", "category", ".", "label", ".", "length", "(", ")", ",", "maybeLongest", ")", ";", "}", "longestLabel", "=", "maybeLongest", ";", "}", "private", "static", "String", "[", "]", "stringValues", ";", "public", "static", "String", "[", "]", "stringValues", "(", ")", "{", "if", "(", "stringValues", "==", "null", ")", "{", "TraceCategory", "[", "]", "values", "=", "values", "(", ")", ";", "stringValues", "=", "new", "String", "[", "values", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "values", ".", "length", ";", "i", "++", ")", "{", "stringValues", "[", "i", "]", "=", "values", "[", "i", "]", ".", "label", ";", "}", "}", "return", "stringValues", ";", "}", "private", "static", "int", "longestLabel", "=", "-", "1", ";", "}", "</s>" ]
6,741
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ";", "import", "java", ".", "util", ".", "Comparator", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "Set", ";", "import", "java", ".", "util", ".", "TreeMap", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "LanguageSupportFactory", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ".", "GroovyNature", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "ICommand", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IContainer", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFolder", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IWorkspaceRoot", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "ResourceAttributes", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Path", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IClasspathEntry", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaCore", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "BuildContext", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CategorizedProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CompilationParticipant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ScriptFolderSelector", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ScriptFolderSelector", ".", "FileKind", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "DefaultProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemSeverities", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "ScriptFolderCompilationParticipant", "extends", "CompilationParticipant", "{", "static", "class", "PathLengthComparator", "implements", "Comparator", "<", "IContainer", ">", "{", "public", "int", "compare", "(", "IContainer", "c1", ",", "IContainer", "c2", ")", "{", "if", "(", "c1", "==", "null", ")", "{", "if", "(", "c2", "==", "null", ")", "{", "return", "0", ";", "}", "return", "-", "1", ";", "}", "if", "(", "c2", "==", "null", ")", "{", "return", "1", ";", "}", "int", "len1", "=", "c1", ".", "getFullPath", "(", ")", ".", "segmentCount", "(", ")", ";", "int", "len2", "=", "c2", ".", "getFullPath", "(", ")", ".", "segmentCount", "(", ")", ";", "if", "(", "len1", ">", "len2", ")", "{", "return", "-", "1", ";", "}", "else", "if", "(", "len1", "==", "len2", ")", "{", "return", "c1", ".", "toString", "(", ")", ".", "compareTo", "(", "c2", ".", "toString", "(", ")", ")", ";", "}", "else", "{", "return", "1", ";", "}", "}", "}", "private", "static", "final", "PathLengthComparator", "comparator", "=", "new", "PathLengthComparator", "(", ")", ";", "private", "BuildContext", "[", "]", "compiledFiles", ";", "private", "IJavaProject", "project", ";", "@", "Override", "public", "boolean", "isActive", "(", "IJavaProject", "project", ")", "{", "boolean", "hasGroovyNature", "=", "GroovyNature", ".", "hasGroovyNature", "(", "project", ".", "getProject", "(", ")", ")", ";", "if", "(", "!", "hasGroovyNature", ")", "{", "return", "false", ";", "}", "this", ".", "project", "=", "project", ";", "return", "true", ";", "}", "@", "Override", "public", "void", "buildStarting", "(", "BuildContext", "[", "]", "files", ",", "boolean", "isBatch", ")", "{", "sanityCheckBuilder", "(", "files", ")", ";", "compiledFiles", "=", "files", ";", "}", "private", "void", "sanityCheckBuilder", "(", "BuildContext", "[", "]", "files", ")", "{", "if", "(", "!", "LanguageSupportFactory", ".", "isGroovyLanguageSupportInstalled", "(", ")", ")", "{", "for", "(", "BuildContext", "buildContext", ":", "files", ")", "{", "buildContext", ".", "recordNewProblems", "(", "createProblem", "(", "buildContext", ")", ")", ";", "}", "}", "try", "{", "ICommand", "[", "]", "buildSpec", "=", "project", ".", "getProject", "(", ")", ".", "getDescription", "(", ")", ".", "getBuildSpec", "(", ")", ";", "boolean", "found", "=", "false", ";", "for", "(", "ICommand", "command", ":", "buildSpec", ")", "{", "if", "(", "command", ".", "getBuilderName", "(", ")", ".", "equals", "(", "JavaCore", ".", "BUILDER_ID", ")", ")", "{", "found", "=", "true", ";", "break", ";", "}", "}", "if", "(", "!", "found", ")", "{", "for", "(", "BuildContext", "buildContext", ":", "files", ")", "{", "buildContext", ".", "recordNewProblems", "(", "createProblem", "(", "buildContext", ")", ")", ";", "}", "}", "}", "catch", "(", "CoreException", "e", ")", "{", "Util", ".", "log", "(", "e", ")", ";", "}", "}", "private", "CategorizedProblem", "[", "]", "createProblem", "(", "BuildContext", "buildContext", ")", "{", "DefaultProblem", "problem", "=", "new", "DefaultProblem", "(", "buildContext", ".", "getFile", "(", ")", ".", "getFullPath", "(", ")", ".", "toOSString", "(", ")", ".", "toCharArray", "(", ")", ",", "\"\"", ",", "0", ",", "new", "String", "[", "0", "]", ",", "ProblemSeverities", ".", "Error", ",", "0", ",", "0", ",", "1", ",", "0", ")", ";", "return", "new", "CategorizedProblem", "[", "]", "{", "problem", "}", ";", "}", "@", "Override", "public", "void", "buildFinished", "(", "IJavaProject", "project", ")", "{", "try", "{", "IProject", "iproject", "=", "project", ".", "getProject", "(", ")", ";", "if", "(", "compiledFiles", "==", "null", "||", "!", "ScriptFolderSelector", ".", "isEnabled", "(", "iproject", ")", ")", "{", "return", ";", "}", "ScriptFolderSelector", "selector", "=", "new", "ScriptFolderSelector", "(", "iproject", ")", ";", "Map", "<", "IContainer", ",", "IContainer", ">", "sourceToOut", "=", "generateSourceToOut", "(", "project", ")", ";", "for", "(", "BuildContext", "compiledFile", ":", "compiledFiles", ")", "{", "IFile", "file", "=", "compiledFile", ".", "getFile", "(", ")", ";", "if", "(", "selector", ".", "getFileKind", "(", "file", ")", "==", "FileKind", ".", "SCRIPT", ")", "{", "IPath", "filePath", "=", "file", ".", "getFullPath", "(", ")", ";", "IContainer", "containingSourceFolder", "=", "findContainingSourceFolder", "(", "sourceToOut", ",", "filePath", ")", ";", "if", "(", "containingSourceFolder", "!=", "null", ")", "{", "IPath", "packagePath", "=", "findPackagePath", "(", "filePath", ",", "containingSourceFolder", ")", ";", "IContainer", "out", "=", "sourceToOut", ".", "get", "(", "containingSourceFolder", ")", ";", "copyFile", "(", "file", ",", "packagePath", ",", "out", ")", ";", "}", "}", "}", "}", "catch", "(", "CoreException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", ")", ";", "}", "finally", "{", "compiledFiles", "=", "null", ";", "}", "}", "private", "IPath", "findPackagePath", "(", "IPath", "filePath", ",", "IContainer", "containingSourceFolder", ")", "{", "IPath", "containerPath", "=", "containingSourceFolder", ".", "getFullPath", "(", ")", ";", "filePath", "=", "filePath", ".", "removeFirstSegments", "(", "containerPath", ".", "segmentCount", "(", ")", ")", ";", "filePath", "=", "filePath", ".", "removeLastSegments", "(", "1", ")", ";", "return", "filePath", ";", "}", "private", "IContainer", "findContainingSourceFolder", "(", "Map", "<", "IContainer", ",", "IContainer", ">", "sourceToOut", ",", "IPath", "filePath", ")", "{", "Set", "<", "IContainer", ">", "sourceFolders", "=", "sourceToOut", ".", "keySet", "(", ")", ";", "for", "(", "IContainer", "container", ":", "sourceFolders", ")", "{", "if", "(", "container", ".", "getFullPath", "(", ")", ".", "isPrefixOf", "(", "filePath", ")", ")", "{", "return", "container", ";", "}", "}", "return", "null", ";", "}", "private", "void", "copyFile", "(", "IFile", "file", ",", "IPath", "packagePath", ",", "IContainer", "outputFolder", ")", "throws", "CoreException", "{", "IContainer", "createdFolder", "=", "createFolder", "(", "packagePath", ",", "outputFolder", ",", "true", ")", ";", "IFile", "toFile", "=", "createdFolder", ".", "getFile", "(", "new", "Path", "(", "file", ".", "getName", "(", ")", ")", ")", ";", "if", "(", "toFile", ".", "exists", "(", ")", ")", "{", "toFile", ".", "delete", "(", "true", ",", "null", ")", ";", "}", "file", ".", "copy", "(", "toFile", ".", "getFullPath", "(", ")", ",", "true", ",", "null", ")", ";", "ResourceAttributes", "newAttrs", "=", "new", "ResourceAttributes", "(", ")", ";", "newAttrs", ".", "setReadOnly", "(", "false", ")", ";", "newAttrs", ".", "setHidden", "(", "false", ")", ";", "toFile", ".", "setResourceAttributes", "(", "newAttrs", ")", ";", "toFile", ".", "setDerived", "(", "true", ",", "null", ")", ";", "toFile", ".", "refreshLocal", "(", "IResource", ".", "DEPTH_ZERO", ",", "null", ")", ";", "}", "private", "IContainer", "createFolder", "(", "IPath", "packagePath", ",", "IContainer", "outputFolder", ",", "boolean", "derived", ")", "throws", "CoreException", "{", "if", "(", "!", "outputFolder", ".", "exists", "(", ")", "&&", "outputFolder", "instanceof", "IFolder", ")", "{", "(", "(", "IFolder", ")", "outputFolder", ")", ".", "create", "(", "true", ",", "true", ",", "null", ")", ";", "}", "if", "(", "packagePath", ".", "isEmpty", "(", ")", ")", "return", "outputFolder", ";", "IFolder", "folder", "=", "outputFolder", ".", "getFolder", "(", "packagePath", ")", ";", "folder", ".", "refreshLocal", "(", "IResource", ".", "DEPTH_ZERO", ",", "null", ")", ";", "if", "(", "!", "folder", ".", "exists", "(", ")", ")", "{", "createFolder", "(", "packagePath", ".", "removeLastSegments", "(", "1", ")", ",", "outputFolder", ",", "derived", ")", ";", "folder", ".", "create", "(", "true", ",", "true", ",", "null", ")", ";", "folder", ".", "setDerived", "(", "derived", ",", "null", ")", ";", "folder", ".", "refreshLocal", "(", "IResource", ".", "DEPTH_ZERO", ",", "null", ")", ";", "}", "return", "folder", ";", "}", "private", "Map", "<", "IContainer", ",", "IContainer", ">", "generateSourceToOut", "(", "IJavaProject", "project", ")", "throws", "JavaModelException", "{", "IProject", "p", "=", "project", ".", "getProject", "(", ")", ";", "IWorkspaceRoot", "root", "=", "(", "IWorkspaceRoot", ")", "p", ".", "getParent", "(", ")", ";", "IClasspathEntry", "[", "]", "cp", "=", "project", ".", "getRawClasspath", "(", ")", ";", "IPath", "defaultOutPath", "=", "project", ".", "getOutputLocation", "(", ")", ";", "IContainer", "defaultOutContainer", ";", "if", "(", "defaultOutPath", ".", "segmentCount", "(", ")", ">", "1", ")", "{", "defaultOutContainer", "=", "root", ".", "getFolder", "(", "defaultOutPath", ")", ";", "}", "else", "{", "defaultOutContainer", "=", "p", ";", "}", "Map", "<", "IContainer", ",", "IContainer", ">", "sourceToOut", "=", "new", "TreeMap", "<", "IContainer", ",", "IContainer", ">", "(", "comparator", ")", ";", "for", "(", "IClasspathEntry", "cpe", ":", "cp", ")", "{", "if", "(", "cpe", ".", "getEntryKind", "(", ")", "==", "IClasspathEntry", ".", "CPE_SOURCE", ")", "{", "IContainer", "sourceContainer", ";", "IPath", "sourcePath", "=", "cpe", ".", "getPath", "(", ")", ";", "if", "(", "sourcePath", ".", "segmentCount", "(", ")", ">", "1", ")", "{", "sourceContainer", "=", "root", ".", "getFolder", "(", "sourcePath", ")", ";", "}", "else", "{", "sourceContainer", "=", "p", ";", "}", "IPath", "outPath", "=", "cpe", ".", "getOutputLocation", "(", ")", ";", "IContainer", "outContainer", ";", "if", "(", "outPath", "==", "null", ")", "{", "outContainer", "=", "defaultOutContainer", ";", "}", "else", "if", "(", "outPath", ".", "segmentCount", "(", ")", ">", "1", ")", "{", "outContainer", "=", "root", ".", "getFolder", "(", "outPath", ")", ";", "}", "else", "{", "outContainer", "=", "p", ";", "}", "if", "(", "!", "sourceContainer", ".", "equals", "(", "outContainer", ")", ")", "{", "sourceToOut", ".", "put", "(", "sourceContainer", ",", "outContainer", ")", ";", "}", "}", "}", "return", "sourceToOut", ";", "}", "}", "</s>" ]
6,742
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "AnnotationBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Binding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "FieldBinding", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "JDTFieldNode", "extends", "FieldNode", "implements", "JDTNode", "{", "private", "FieldBinding", "fieldBinding", ";", "private", "JDTResolver", "resolver", ";", "private", "int", "bits", "=", "0", ";", "public", "JDTFieldNode", "(", "FieldBinding", "fieldBinding", ",", "JDTResolver", "resolver", ",", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "type", ",", "JDTClassNode", "declaringType", ",", "Expression", "initializerExpression", ")", "{", "super", "(", "name", ",", "modifiers", ",", "type", ",", "declaringType", ",", "initializerExpression", ")", ";", "this", ".", "resolver", "=", "resolver", ";", "this", ".", "fieldBinding", "=", "fieldBinding", ";", "}", "@", "Override", "public", "void", "addAnnotation", "(", "AnnotationNode", "value", ")", "{", "throw", "new", "IllegalStateException", "(", "\"\"", ")", ";", "}", "@", "Override", "public", "void", "addAnnotations", "(", "List", "annotations", ")", "{", "throw", "new", "IllegalStateException", "(", "\"\"", ")", ";", "}", "@", "Override", "public", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", ")", "{", "ensureAnnotationsInitialized", "(", ")", ";", "return", "super", ".", "getAnnotations", "(", ")", ";", "}", "@", "Override", "public", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", "ClassNode", "type", ")", "{", "ensureAnnotationsInitialized", "(", ")", ";", "return", "super", ".", "getAnnotations", "(", "type", ")", ";", "}", "private", "void", "ensureAnnotationsInitialized", "(", ")", "{", "if", "(", "(", "bits", "&", "ANNOTATIONS_INITIALIZED", ")", "==", "0", ")", "{", "AnnotationBinding", "[", "]", "annotationBindings", "=", "fieldBinding", ".", "getAnnotations", "(", ")", ";", "for", "(", "AnnotationBinding", "annotationBinding", ":", "annotationBindings", ")", "{", "super", ".", "addAnnotation", "(", "new", "JDTAnnotationNode", "(", "annotationBinding", ",", "this", ".", "resolver", ")", ")", ";", "}", "bits", "|=", "ANNOTATIONS_INITIALIZED", ";", "}", "}", "public", "FieldBinding", "getFieldBinding", "(", ")", "{", "return", "fieldBinding", ";", "}", "public", "JDTResolver", "getResolver", "(", ")", "{", "return", "resolver", ";", "}", "public", "Binding", "getJdtBinding", "(", ")", "{", "return", "fieldBinding", ";", "}", "public", "boolean", "isDeprecated", "(", ")", "{", "return", "fieldBinding", ".", "isDeprecated", "(", ")", ";", "}", "}", "</s>" ]
6,743
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Parameter", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "Statement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "AnnotationBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Binding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MethodBinding", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "JDTMethodNode", "extends", "MethodNode", "implements", "JDTNode", "{", "private", "MethodBinding", "methodBinding", ";", "private", "JDTResolver", "resolver", ";", "private", "int", "bits", "=", "0", ";", "public", "JDTMethodNode", "(", "MethodBinding", "methodBinding", ",", "JDTResolver", "resolver", ",", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "returnType", ",", "Parameter", "[", "]", "gParameters", ",", "ClassNode", "[", "]", "thrownExceptions", ",", "Statement", "object", ")", "{", "super", "(", "name", ",", "modifiers", ",", "returnType", ",", "gParameters", ",", "thrownExceptions", ",", "object", ")", ";", "this", ".", "resolver", "=", "resolver", ";", "this", ".", "methodBinding", "=", "methodBinding", ";", "}", "@", "Override", "public", "void", "addAnnotation", "(", "AnnotationNode", "value", ")", "{", "throwImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addAnnotations", "(", "List", "annotations", ")", "{", "throwImmutableException", "(", ")", ";", "}", "@", "Override", "public", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", ")", "{", "ensureAnnotationsInitialized", "(", ")", ";", "return", "super", ".", "getAnnotations", "(", ")", ";", "}", "@", "Override", "public", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", "ClassNode", "type", ")", "{", "ensureAnnotationsInitialized", "(", ")", ";", "return", "super", ".", "getAnnotations", "(", "type", ")", ";", "}", "private", "void", "ensureAnnotationsInitialized", "(", ")", "{", "if", "(", "(", "bits", "&", "ANNOTATIONS_INITIALIZED", ")", "==", "0", ")", "{", "AnnotationBinding", "[", "]", "annotationBindings", "=", "methodBinding", ".", "getAnnotations", "(", ")", ";", "for", "(", "AnnotationBinding", "annotationBinding", ":", "annotationBindings", ")", "{", "super", ".", "addAnnotation", "(", "new", "JDTAnnotationNode", "(", "annotationBinding", ",", "this", ".", "resolver", ")", ")", ";", "}", "bits", "|=", "ANNOTATIONS_INITIALIZED", ";", "}", "}", "private", "void", "throwImmutableException", "(", ")", "{", "throw", "new", "IllegalStateException", "(", "\"\"", ")", ";", "}", "public", "JDTResolver", "getResolver", "(", ")", "{", "return", "resolver", ";", "}", "public", "MethodBinding", "getMethodBinding", "(", ")", "{", "return", "methodBinding", ";", "}", "public", "Binding", "getJdtBinding", "(", ")", "{", "return", "methodBinding", ";", "}", "public", "boolean", "isDeprecated", "(", ")", "{", "return", "methodBinding", ".", "isDeprecated", "(", ")", ";", "}", "}", "</s>" ]
6,744
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationFailedException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilerConfiguration", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ErrorCollector", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "messages", ".", "Message", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "messages", ".", "SimpleMessage", ";", "public", "class", "GroovyErrorCollectorForJDT", "extends", "ErrorCollector", "{", "public", "GroovyErrorCollectorForJDT", "(", "CompilerConfiguration", "configuration", ")", "{", "super", "(", "configuration", ")", ";", "}", "@", "Override", "public", "void", "addErrorAndContinue", "(", "Message", "message", ")", "{", "System", ".", "err", ".", "println", "(", "message", ")", ";", "if", "(", "message", "instanceof", "SimpleMessage", ")", "{", "System", ".", "err", ".", "println", "(", "\"\"", "+", "(", "(", "SimpleMessage", ")", "message", ")", ".", "getMessage", "(", ")", ")", ";", "}", "super", ".", "addErrorAndContinue", "(", "message", ")", ";", "}", "@", "Override", "protected", "void", "failIfErrors", "(", ")", "throws", "CompilationFailedException", "{", "if", "(", "transformActive", ")", "{", "super", ".", "failIfErrors", "(", ")", ";", "}", "}", "}", "</s>" ]
6,745
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "io", ".", "PrintWriter", ";", "import", "java", ".", "io", ".", "StringWriter", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Arrays", ";", "import", "java", ".", "util", ".", "Comparator", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "LinkedList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "GroovyBugError", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Comment", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ConstructorNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GenericsType", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ImportNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ImportNodeCompatibilityWrapper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "InnerClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ModuleNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "PackageNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Parameter", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "TaskEntry", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstantExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ListExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "PropertyExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "VariableExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ErrorCollector", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "MultipleCompilationErrorsException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "Phases", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "messages", ".", "ExceptionMessage", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "messages", ".", "LocatedMessage", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "messages", ".", "Message", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "messages", ".", "SimpleMessage", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "messages", ".", "SyntaxErrorMessage", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "CSTNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "PreciseSyntaxException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "RuntimeParserException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "SyntaxException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "Token", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "tools", ".", "GroovyClass", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CategorizedProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "SingleMemberAnnotation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "MarkerAnnotation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ASTVisitor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Annotation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AnnotationMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Argument", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ArrayInitializer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ArrayQualifiedTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ArrayTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ClassLiteralAccess", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ConstructorDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "FieldDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Javadoc", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "MethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ParameterizedQualifiedTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ParameterizedSingleTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "QualifiedTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "SingleTypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "StringLiteral", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeParameter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Wildcard", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "IrritantSet", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "BlockScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "CompilationUnitScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "LocalTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "LookupEnvironment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "SourceTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeIds", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "AbortCompilation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "DefaultProblemFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemSeverities", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "import", "org", ".", "objectweb", ".", "asm", ".", "Opcodes", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "GroovyCompilationUnitDeclaration", "extends", "CompilationUnitDeclaration", "{", "private", "CompilationUnit", "groovyCompilationUnit", ";", "private", "SourceUnit", "groovySourceUnit", ";", "private", "CompilerOptions", "compilerOptions", ";", "private", "boolean", "checkGenerics", ";", "public", "static", "boolean", "defaultCheckGenerics", "=", "false", ";", "public", "static", "boolean", "earlyTransforms", "=", "true", ";", "private", "boolean", "isScript", "=", "false", ";", "private", "static", "final", "boolean", "DEBUG_TASK_TAGS", "=", "false", ";", "public", "GroovyCompilationUnitDeclaration", "(", "ProblemReporter", "problemReporter", ",", "CompilationResult", "compilationResult", ",", "int", "sourceLength", ",", "CompilationUnit", "groovyCompilationUnit", ",", "SourceUnit", "groovySourceUnit", ",", "CompilerOptions", "compilerOptions", ")", "{", "super", "(", "problemReporter", ",", "compilationResult", ",", "sourceLength", ")", ";", "this", ".", "groovyCompilationUnit", "=", "groovyCompilationUnit", ";", "this", ".", "groovySourceUnit", "=", "groovySourceUnit", ";", "this", ".", "compilerOptions", "=", "compilerOptions", ";", "this", ".", "checkGenerics", "=", "defaultCheckGenerics", ";", "}", "private", "void", "setComments", "(", ")", "{", "List", "<", "Comment", ">", "groovyComments", "=", "this", ".", "groovySourceUnit", ".", "getComments", "(", ")", ";", "if", "(", "groovyComments", "==", "null", "||", "groovyComments", ".", "size", "(", ")", "==", "0", ")", "{", "return", ";", "}", "this", ".", "comments", "=", "new", "int", "[", "groovyComments", ".", "size", "(", ")", "]", "[", "2", "]", ";", "for", "(", "int", "c", "=", "0", ",", "max", "=", "groovyComments", ".", "size", "(", ")", ";", "c", "<", "max", ";", "c", "++", ")", "{", "Comment", "groovyComment", "=", "groovyComments", ".", "get", "(", "c", ")", ";", "this", ".", "comments", "[", "c", "]", "=", "groovyComment", ".", "getPositions", "(", "compilationResult", ".", "lineSeparatorPositions", ")", ";", "}", "}", "public", "boolean", "processToPhase", "(", "int", "phase", ")", "{", "boolean", "alreadyHasProblems", "=", "compilationResult", ".", "hasProblems", "(", ")", ";", "try", "{", "ClassLoader", "cl", "=", "Thread", ".", "currentThread", "(", ")", ".", "getContextClassLoader", "(", ")", ";", "try", "{", "Thread", ".", "currentThread", "(", ")", ".", "setContextClassLoader", "(", "groovyCompilationUnit", ".", "getTransformLoader", "(", ")", ")", ";", "groovyCompilationUnit", ".", "compile", "(", "phase", ")", ";", "}", "finally", "{", "Thread", ".", "currentThread", "(", ")", ".", "setContextClassLoader", "(", "cl", ")", ";", "}", "if", "(", "groovySourceUnit", ".", "getErrorCollector", "(", ")", ".", "hasErrors", "(", ")", ")", "{", "recordProblems", "(", "groovySourceUnit", ".", "getErrorCollector", "(", ")", ".", "getErrors", "(", ")", ")", ";", "return", "false", ";", "}", "else", "{", "return", "true", ";", "}", "}", "catch", "(", "MultipleCompilationErrorsException", "problems", ")", "{", "AbortCompilation", "abort", "=", "getAbortCompilation", "(", "problems", ")", ";", "if", "(", "abort", "!=", "null", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", ")", ";", "throw", "abort", ";", "}", "else", "{", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "problems", ".", "printStackTrace", "(", ")", ";", "recordProblems", "(", "problems", ".", "getErrorCollector", "(", ")", ".", "getErrors", "(", ")", ")", ";", "}", "}", "catch", "(", "GroovyBugError", "gbr", ")", "{", "if", "(", "alreadyHasProblems", ")", "{", "System", ".", "err", ".", "println", "(", "\"\"", "+", "gbr", ".", "getMessage", "(", ")", "+", "\"'\"", ")", ";", "}", "else", "{", "boolean", "reportit", "=", "true", ";", "if", "(", "gbr", ".", "getCause", "(", ")", "instanceof", "AbortCompilation", ")", "{", "AbortCompilation", "abort", "=", "(", "AbortCompilation", ")", "gbr", ".", "getCause", "(", ")", ";", "if", "(", "abort", ".", "isSilent", ")", "{", "reportit", "=", "false", ";", "}", "}", "if", "(", "reportit", ")", "{", "System", ".", "err", ".", "println", "(", "\"\"", "+", "gbr", ".", "getBugText", "(", ")", ")", ";", "gbr", ".", "printStackTrace", "(", ")", ";", "Util", ".", "log", "(", "gbr", ",", "\"\"", ")", ";", "groovySourceUnit", ".", "getErrorCollector", "(", ")", ".", "addError", "(", "new", "SyntaxErrorMessage", "(", "new", "SyntaxException", "(", "\"\"", "+", "gbr", ".", "getBugText", "(", ")", ",", "gbr", ",", "1", ",", "0", ")", ",", "groovySourceUnit", ")", ")", ";", "recordProblems", "(", "groovySourceUnit", ".", "getErrorCollector", "(", ")", ".", "getErrors", "(", ")", ")", ";", "}", "}", "}", "return", "false", ";", "}", "private", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "AbortCompilation", "getAbortCompilation", "(", "MultipleCompilationErrorsException", "problems", ")", "{", "ErrorCollector", "collector", "=", "problems", ".", "getErrorCollector", "(", ")", ";", "if", "(", "collector", ".", "getErrorCount", "(", ")", "==", "1", "&&", "problems", ".", "getErrorCollector", "(", ")", ".", "getError", "(", "0", ")", "instanceof", "ExceptionMessage", ")", "{", "Exception", "abort", "=", "(", "(", "ExceptionMessage", ")", "problems", ".", "getErrorCollector", "(", ")", ".", "getError", "(", "0", ")", ")", ".", "getCause", "(", ")", ";", "return", "abort", "instanceof", "AbortCompilation", "?", "(", "AbortCompilation", ")", "abort", ":", "null", ";", "}", "return", "null", ";", "}", "public", "CompilationUnit", "getCompilationUnit", "(", ")", "{", "return", "groovyCompilationUnit", ";", "}", "public", "void", "populateCompilationUnitDeclaration", "(", ")", "{", "ModuleNode", "moduleNode", "=", "groovySourceUnit", ".", "getAST", "(", ")", ";", "createPackageDeclaration", "(", "moduleNode", ")", ";", "createImports", "(", "moduleNode", ")", ";", "createTypeDeclarations", "(", "moduleNode", ")", ";", "}", "protected", "void", "createImports", "(", "ModuleNode", "moduleNode", ")", "{", "List", "<", "ImportNode", ">", "importNodes", "=", "moduleNode", ".", "getImports", "(", ")", ";", "List", "<", "ImportNode", ">", "importPackages", "=", "ImportNodeCompatibilityWrapper", ".", "getStarImports", "(", "moduleNode", ")", ";", "Map", "<", "String", ",", "ImportNode", ">", "importStatics", "=", "ImportNodeCompatibilityWrapper", ".", "getStaticImports", "(", "moduleNode", ")", ";", "Map", "<", "String", ",", "ImportNode", ">", "importStaticStars", "=", "ImportNodeCompatibilityWrapper", ".", "getStaticStarImports", "(", "moduleNode", ")", ";", "if", "(", "importNodes", ".", "size", "(", ")", ">", "0", "||", "importPackages", ".", "size", "(", ")", ">", "0", "||", "importStatics", ".", "size", "(", ")", ">", "0", "||", "importStaticStars", ".", "size", "(", ")", ">", "0", ")", "{", "List", "<", "ImportReference", ">", "importReferences", "=", "new", "ArrayList", "<", "ImportReference", ">", "(", ")", ";", "for", "(", "ImportNode", "importNode", ":", "importNodes", ")", "{", "char", "[", "]", "[", "]", "splits", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "importNode", ".", "getClassName", "(", ")", ".", "toCharArray", "(", ")", ")", ";", "ImportReference", "ref", "=", "null", ";", "ClassNode", "type", "=", "importNode", ".", "getType", "(", ")", ";", "int", "typeStartOffset", "=", "startOffset", "(", "type", ")", ";", "int", "typeEndOffset", "=", "endOffset", "(", "type", ")", ";", "if", "(", "typeStartOffset", "==", "0", ")", "{", "continue", ";", "}", "if", "(", "importNode", ".", "getAlias", "(", ")", "!=", "null", "&&", "importNode", ".", "getAlias", "(", ")", ".", "length", "(", ")", ">", "0", ")", "{", "ref", "=", "new", "AliasImportReference", "(", "importNode", ".", "getAlias", "(", ")", ".", "toCharArray", "(", ")", ",", "splits", ",", "positionsFor", "(", "splits", ",", "typeStartOffset", ",", "typeEndOffset", ")", ",", "false", ",", "ClassFileConstants", ".", "AccDefault", ")", ";", "}", "else", "{", "ref", "=", "new", "ImportReference", "(", "splits", ",", "positionsFor", "(", "splits", ",", "typeStartOffset", ",", "typeEndOffset", ")", ",", "false", ",", "ClassFileConstants", ".", "AccDefault", ")", ";", "}", "ref", ".", "sourceEnd", "=", "Math", ".", "max", "(", "typeEndOffset", "-", "1", ",", "ref", ".", "sourceStart", ")", ";", "int", "start", "=", "importNode", ".", "getStart", "(", ")", ";", "ref", ".", "declarationSourceStart", "=", "start", ";", "int", "end", "=", "importNode", ".", "getEnd", "(", ")", ";", "ref", ".", "declarationSourceEnd", "=", "end", ";", "ref", ".", "declarationEnd", "=", "ref", ".", "sourceEnd", ";", "importReferences", ".", "add", "(", "ref", ")", ";", "}", "for", "(", "ImportNode", "importPackage", ":", "importPackages", ")", "{", "String", "importText", "=", "importPackage", ".", "getText", "(", ")", ";", "int", "packageStartOffset", "=", "importPackage", ".", "getStart", "(", ")", "+", "\"import", "\"", ".", "length", "(", ")", ";", "int", "packageEndOffset", "=", "packageStartOffset", "+", "importText", ".", "length", "(", ")", "-", "\"import", "\"", ".", "length", "(", ")", "-", "\".*\"", ".", "length", "(", ")", ";", "char", "[", "]", "[", "]", "splits", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "importPackage", ".", "getPackageName", "(", ")", ".", "substring", "(", "0", ",", "importPackage", ".", "getPackageName", "(", ")", ".", "length", "(", ")", "-", "1", ")", ".", "toCharArray", "(", ")", ")", ";", "ImportReference", "ref", "=", "new", "ImportReference", "(", "splits", ",", "positionsFor", "(", "splits", ",", "packageStartOffset", ",", "packageEndOffset", ")", ",", "true", ",", "ClassFileConstants", ".", "AccDefault", ")", ";", "ref", ".", "sourceEnd", "=", "packageEndOffset", ";", "ref", ".", "declarationSourceStart", "=", "importPackage", ".", "getStart", "(", ")", ";", "ref", ".", "declarationSourceEnd", "=", "importPackage", ".", "getEnd", "(", ")", ";", "ref", ".", "declarationEnd", "=", "ref", ".", "sourceEnd", ";", "importReferences", ".", "add", "(", "ref", ")", ";", "}", "for", "(", "Map", ".", "Entry", "<", "String", ",", "ImportNode", ">", "importStatic", ":", "importStatics", ".", "entrySet", "(", ")", ")", "{", "ImportNode", "importNode", "=", "importStatic", ".", "getValue", "(", ")", ";", "String", "importName", "=", "importNode", ".", "getClassName", "(", ")", "+", "\".\"", "+", "importStatic", ".", "getKey", "(", ")", ";", "char", "[", "]", "[", "]", "splits", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "importName", ".", "toCharArray", "(", ")", ")", ";", "ImportReference", "ref", "=", "null", ";", "ClassNode", "type", "=", "importNode", ".", "getType", "(", ")", ";", "int", "typeStartOffset", "=", "startOffset", "(", "type", ")", ";", "int", "typeEndOffset", "=", "endOffset", "(", "type", ")", ";", "if", "(", "importNode", ".", "getAlias", "(", ")", "!=", "null", "&&", "importNode", ".", "getAlias", "(", ")", ".", "length", "(", ")", ">", "0", ")", "{", "ref", "=", "new", "AliasImportReference", "(", "importNode", ".", "getAlias", "(", ")", ".", "toCharArray", "(", ")", ",", "splits", ",", "positionsFor", "(", "splits", ",", "typeStartOffset", ",", "typeEndOffset", ")", ",", "false", ",", "ClassFileConstants", ".", "AccDefault", "|", "ClassFileConstants", ".", "AccStatic", ")", ";", "}", "else", "{", "ref", "=", "new", "ImportReference", "(", "splits", ",", "positionsFor", "(", "splits", ",", "typeStartOffset", ",", "typeEndOffset", ")", ",", "false", ",", "ClassFileConstants", ".", "AccDefault", "|", "ClassFileConstants", ".", "AccStatic", ")", ";", "}", "ref", ".", "sourceEnd", "=", "Math", ".", "max", "(", "typeEndOffset", "-", "1", ",", "ref", ".", "sourceStart", ")", ";", "ref", ".", "declarationSourceStart", "=", "importNode", ".", "getStart", "(", ")", ";", "ref", ".", "declarationSourceEnd", "=", "importNode", ".", "getEnd", "(", ")", ";", "ref", ".", "declarationEnd", "=", "ref", ".", "sourceEnd", ";", "importReferences", ".", "add", "(", "ref", ")", ";", "}", "for", "(", "Map", ".", "Entry", "<", "String", ",", "ImportNode", ">", "importStaticStar", ":", "importStaticStars", ".", "entrySet", "(", ")", ")", "{", "String", "classname", "=", "importStaticStar", ".", "getKey", "(", ")", ";", "ImportNode", "importNode", "=", "importStaticStar", ".", "getValue", "(", ")", ";", "ClassNode", "importedType", "=", "importNode", ".", "getType", "(", ")", ";", "int", "typeStartOffset", "=", "importedType", "!=", "null", "?", "startOffset", "(", "importedType", ")", ":", "0", ";", "int", "typeEndOffset", "=", "importedType", "!=", "null", "?", "endOffset", "(", "importedType", ")", ":", "0", ";", "char", "[", "]", "[", "]", "splits", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "classname", ".", "toCharArray", "(", ")", ")", ";", "ImportReference", "ref", "=", "new", "ImportReference", "(", "splits", ",", "positionsFor", "(", "splits", ",", "typeStartOffset", ",", "typeEndOffset", ")", ",", "true", ",", "ClassFileConstants", ".", "AccDefault", "|", "ClassFileConstants", ".", "AccStatic", ")", ";", "ref", ".", "sourceEnd", "=", "Math", ".", "max", "(", "typeEndOffset", "-", "1", ",", "ref", ".", "sourceStart", ")", ";", "ref", ".", "declarationSourceStart", "=", "importNode", ".", "getStart", "(", ")", ";", "ref", ".", "declarationSourceEnd", "=", "importNode", ".", "getEnd", "(", ")", ";", "ref", ".", "declarationEnd", "=", "ref", ".", "sourceEnd", ";", "importReferences", ".", "add", "(", "ref", ")", ";", "}", "if", "(", "importReferences", ".", "size", "(", ")", "!=", "0", ")", "{", "imports", "=", "importReferences", ".", "toArray", "(", "new", "ImportReference", "[", "importReferences", ".", "size", "(", ")", "]", ")", ";", "Arrays", ".", "sort", "(", "imports", ",", "new", "Comparator", "<", "ImportReference", ">", "(", ")", "{", "public", "int", "compare", "(", "ImportReference", "left", ",", "ImportReference", "right", ")", "{", "return", "left", ".", "sourceStart", "-", "right", ".", "sourceStart", ";", "}", "}", ")", ";", "for", "(", "ImportReference", "ref", ":", "imports", ")", "{", "if", "(", "ref", ".", "declarationSourceStart", ">", "0", "&&", "(", "ref", ".", "declarationEnd", "-", "ref", ".", "declarationSourceStart", "+", "1", ")", "<", "0", ")", "{", "throw", "new", "IllegalStateException", "(", "\"\"", "+", "moduleNode", ".", "getClasses", "(", ")", ".", "get", "(", "0", ")", "+", "\"\"", "+", "ref", ".", "toString", "(", ")", "+", "\"\"", "+", "ref", ".", "declarationSourceStart", "+", "\"", "declEnd=\"", "+", "+", "ref", ".", "declarationEnd", ")", ";", "}", "}", "}", "}", "}", "private", "void", "createPackageDeclaration", "(", "ModuleNode", "moduleNode", ")", "{", "if", "(", "moduleNode", ".", "hasPackageName", "(", ")", ")", "{", "PackageNode", "packageNode", "=", "moduleNode", ".", "getPackage", "(", ")", ";", "String", "packageName", "=", "moduleNode", ".", "getPackageName", "(", ")", ";", "if", "(", "packageName", ".", "endsWith", "(", "\".\"", ")", ")", "{", "packageName", "=", "packageName", ".", "substring", "(", "0", ",", "packageName", ".", "length", "(", ")", "-", "1", ")", ";", "}", "long", "start", "=", "startOffset", "(", "packageNode", ")", ";", "long", "end", "=", "endOffset", "(", "packageNode", ")", ";", "char", "[", "]", "[", "]", "packageReference", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "packageName", ".", "toCharArray", "(", ")", ")", ";", "currentPackage", "=", "new", "ImportReference", "(", "packageReference", ",", "positionsFor", "(", "packageReference", ",", "start", ",", "end", ")", ",", "true", ",", "ClassFileConstants", ".", "AccDefault", ")", ";", "currentPackage", ".", "declarationSourceStart", "=", "currentPackage", ".", "sourceStart", ";", "currentPackage", ".", "declarationSourceEnd", "=", "currentPackage", ".", "sourceEnd", ";", "currentPackage", ".", "declarationEnd", "=", "currentPackage", ".", "sourceEnd", ";", "currentPackage", ".", "declarationSourceStart", "=", "currentPackage", ".", "sourceStart", "-", "\"package", "\"", ".", "length", "(", ")", ";", "currentPackage", ".", "declarationEnd", "=", "currentPackage", ".", "declarationSourceEnd", "=", "currentPackage", ".", "sourceEnd", ";", "}", "}", "private", "Annotation", "[", "]", "transformAnnotations", "(", "List", "<", "AnnotationNode", ">", "groovyAnnotations", ")", "{", "if", "(", "groovyAnnotations", "!=", "null", "&&", "groovyAnnotations", ".", "size", "(", ")", ">", "0", ")", "{", "List", "<", "Annotation", ">", "annotations", "=", "new", "ArrayList", "<", "Annotation", ">", "(", ")", ";", "for", "(", "AnnotationNode", "annotationNode", ":", "groovyAnnotations", ")", "{", "ClassNode", "annoType", "=", "annotationNode", ".", "getClassNode", "(", ")", ";", "Map", "<", "String", ",", "Expression", ">", "memberValuePairs", "=", "annotationNode", ".", "getMembers", "(", ")", ";", "if", "(", "memberValuePairs", "==", "null", "||", "memberValuePairs", ".", "size", "(", ")", "==", "0", ")", "{", "TypeReference", "annotationReference", "=", "createTypeReferenceForClassNode", "(", "annoType", ")", ";", "annotationReference", ".", "sourceStart", "=", "annotationNode", ".", "getStart", "(", ")", ";", "annotationReference", ".", "sourceEnd", "=", "annotationNode", ".", "getEnd", "(", ")", ";", "MarkerAnnotation", "annotation", "=", "new", "MarkerAnnotation", "(", "annotationReference", ",", "annotationNode", ".", "getStart", "(", ")", ")", ";", "annotation", ".", "declarationSourceEnd", "=", "annotation", ".", "sourceEnd", ";", "annotations", ".", "add", "(", "annotation", ")", ";", "}", "else", "{", "if", "(", "memberValuePairs", ".", "size", "(", ")", "==", "1", "&&", "memberValuePairs", ".", "containsKey", "(", "\"value\"", ")", ")", "{", "Expression", "value", "=", "memberValuePairs", ".", "get", "(", "\"value\"", ")", ";", "if", "(", "value", "instanceof", "PropertyExpression", ")", "{", "String", "pExpression", "=", "(", "(", "PropertyExpression", ")", "value", ")", ".", "getPropertyAsString", "(", ")", ";", "if", "(", "pExpression", ".", "equals", "(", "\"class\"", ")", ")", "{", "TypeReference", "annotationReference", "=", "createTypeReferenceForClassNode", "(", "annoType", ")", ";", "annotationReference", ".", "sourceStart", "=", "annotationNode", ".", "getStart", "(", ")", ";", "annotationReference", ".", "sourceEnd", "=", "annotationNode", ".", "getEnd", "(", ")", ";", "SingleMemberAnnotation", "annotation", "=", "new", "SingleMemberAnnotation", "(", "annotationReference", ",", "annotationNode", ".", "getStart", "(", ")", ")", ";", "annotation", ".", "memberValue", "=", "new", "ClassLiteralAccess", "(", "value", ".", "getEnd", "(", ")", ",", "classLiteralToTypeReference", "(", "(", "PropertyExpression", ")", "value", ")", ")", ";", "annotation", ".", "declarationSourceEnd", "=", "annotation", ".", "sourceStart", "+", "annoType", ".", "getNameWithoutPackage", "(", ")", ".", "length", "(", ")", ";", "annotations", ".", "add", "(", "annotation", ")", ";", "}", "}", "else", "if", "(", "value", "instanceof", "VariableExpression", "&&", "annoType", ".", "getName", "(", ")", ".", "endsWith", "(", "\"RunWith\"", ")", ")", "{", "TypeReference", "annotationReference", "=", "createTypeReferenceForClassNode", "(", "annoType", ")", ";", "annotationReference", ".", "sourceStart", "=", "annotationNode", ".", "getStart", "(", ")", ";", "annotationReference", ".", "sourceEnd", "=", "annotationNode", ".", "getEnd", "(", ")", ";", "SingleMemberAnnotation", "annotation", "=", "new", "SingleMemberAnnotation", "(", "annotationReference", ",", "annotationNode", ".", "getStart", "(", ")", ")", ";", "String", "v", "=", "(", "(", "VariableExpression", ")", "value", ")", ".", "getName", "(", ")", ";", "TypeReference", "ref", "=", "null", ";", "int", "start", "=", "annotationReference", ".", "sourceStart", ";", "int", "end", "=", "annotationReference", ".", "sourceEnd", ";", "if", "(", "v", ".", "indexOf", "(", "\".\"", ")", "==", "-", "1", ")", "{", "ref", "=", "new", "SingleTypeReference", "(", "v", ".", "toCharArray", "(", ")", ",", "toPos", "(", "start", ",", "end", "-", "1", ")", ")", ";", "}", "else", "{", "char", "[", "]", "[", "]", "splits", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "v", ".", "toCharArray", "(", ")", ")", ";", "ref", "=", "new", "QualifiedTypeReference", "(", "splits", ",", "positionsFor", "(", "splits", ",", "start", ",", "end", "-", "2", ")", ")", ";", "}", "annotation", ".", "memberValue", "=", "new", "ClassLiteralAccess", "(", "value", ".", "getEnd", "(", ")", ",", "ref", ")", ";", "annotation", ".", "declarationSourceEnd", "=", "annotation", ".", "sourceStart", "+", "annoType", ".", "getNameWithoutPackage", "(", ")", ".", "length", "(", ")", ";", "annotations", ".", "add", "(", "annotation", ")", ";", "}", "else", "if", "(", "annoType", ".", "getName", "(", ")", ".", "equals", "(", "\"\"", ")", "&&", "(", "value", "instanceof", "ConstantExpression", "||", "value", "instanceof", "ListExpression", ")", ")", "{", "if", "(", "value", "instanceof", "ListExpression", ")", "{", "ListExpression", "listExpression", "=", "(", "ListExpression", ")", "value", ";", "List", "<", "Expression", ">", "listOfExpressions", "=", "listExpression", ".", "getExpressions", "(", ")", ";", "TypeReference", "annotationReference", "=", "createTypeReferenceForClassNode", "(", "annoType", ")", ";", "annotationReference", ".", "sourceStart", "=", "annotationNode", ".", "getStart", "(", ")", ";", "annotationReference", ".", "sourceEnd", "=", "annotationNode", ".", "getEnd", "(", ")", "-", "1", ";", "SingleMemberAnnotation", "annotation", "=", "new", "SingleMemberAnnotation", "(", "annotationReference", ",", "annotationNode", ".", "getStart", "(", ")", ")", ";", "ArrayInitializer", "arrayInitializer", "=", "new", "ArrayInitializer", "(", ")", ";", "arrayInitializer", ".", "expressions", "=", "new", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Expression", "[", "listOfExpressions", ".", "size", "(", ")", "]", ";", "for", "(", "int", "c", "=", "0", ";", "c", "<", "listOfExpressions", ".", "size", "(", ")", ";", "c", "++", ")", "{", "ConstantExpression", "cExpression", "=", "(", "ConstantExpression", ")", "listOfExpressions", ".", "get", "(", "c", ")", ";", "String", "v", "=", "(", "String", ")", "cExpression", ".", "getValue", "(", ")", ";", "TypeReference", "ref", "=", "null", ";", "int", "start", "=", "cExpression", ".", "getStart", "(", ")", ";", "int", "end", "=", "cExpression", ".", "getEnd", "(", ")", "-", "1", ";", "if", "(", "v", ".", "indexOf", "(", "\".\"", ")", "==", "-", "1", ")", "{", "ref", "=", "new", "SingleTypeReference", "(", "v", ".", "toCharArray", "(", ")", ",", "toPos", "(", "start", ",", "end", "-", "1", ")", ")", ";", "annotation", ".", "declarationSourceEnd", "=", "annotation", ".", "sourceStart", "+", "annoType", ".", "getNameWithoutPackage", "(", ")", ".", "length", "(", ")", "-", "1", ";", "}", "else", "{", "char", "[", "]", "[", "]", "splits", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "v", ".", "toCharArray", "(", ")", ")", ";", "ref", "=", "new", "QualifiedTypeReference", "(", "splits", ",", "positionsFor", "(", "splits", ",", "start", ",", "end", "-", "2", ")", ")", ";", "annotation", ".", "declarationSourceEnd", "=", "annotation", ".", "sourceStart", "+", "annoType", ".", "getName", "(", ")", ".", "length", "(", ")", "-", "1", ";", "}", "arrayInitializer", ".", "expressions", "[", "c", "]", "=", "new", "StringLiteral", "(", "v", ".", "toCharArray", "(", ")", ",", "start", ",", "end", ",", "-", "1", ")", ";", "}", "annotation", ".", "memberValue", "=", "arrayInitializer", ";", "annotations", ".", "add", "(", "annotation", ")", ";", "}", "else", "{", "ConstantExpression", "constantExpression", "=", "(", "ConstantExpression", ")", "value", ";", "if", "(", "value", ".", "getType", "(", ")", ".", "getName", "(", ")", ".", "equals", "(", "\"\"", ")", ")", "{", "TypeReference", "annotationReference", "=", "createTypeReferenceForClassNode", "(", "annoType", ")", ";", "annotationReference", ".", "sourceStart", "=", "annotationNode", ".", "getStart", "(", ")", ";", "annotationReference", ".", "sourceEnd", "=", "annotationNode", ".", "getEnd", "(", ")", "-", "1", ";", "SingleMemberAnnotation", "annotation", "=", "new", "SingleMemberAnnotation", "(", "annotationReference", ",", "annotationNode", ".", "getStart", "(", ")", ")", ";", "String", "v", "=", "(", "String", ")", "constantExpression", ".", "getValue", "(", ")", ";", "TypeReference", "ref", "=", "null", ";", "int", "start", "=", "constantExpression", ".", "getStart", "(", ")", ";", "int", "end", "=", "constantExpression", ".", "getEnd", "(", ")", "-", "1", ";", "if", "(", "v", ".", "indexOf", "(", "\".\"", ")", "==", "-", "1", ")", "{", "ref", "=", "new", "SingleTypeReference", "(", "v", ".", "toCharArray", "(", ")", ",", "toPos", "(", "start", ",", "end", "-", "1", ")", ")", ";", "annotation", ".", "declarationSourceEnd", "=", "annotation", ".", "sourceStart", "+", "annoType", ".", "getNameWithoutPackage", "(", ")", ".", "length", "(", ")", "-", "1", ";", "}", "else", "{", "char", "[", "]", "[", "]", "splits", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "v", ".", "toCharArray", "(", ")", ")", ";", "ref", "=", "new", "QualifiedTypeReference", "(", "splits", ",", "positionsFor", "(", "splits", ",", "start", ",", "end", "-", "2", ")", ")", ";", "annotation", ".", "declarationSourceEnd", "=", "annotation", ".", "sourceStart", "+", "annoType", ".", "getName", "(", ")", ".", "length", "(", ")", "-", "1", ";", "}", "annotation", ".", "memberValue", "=", "new", "StringLiteral", "(", "v", ".", "toCharArray", "(", ")", ",", "start", ",", "end", ",", "-", "1", ")", ";", "annotations", ".", "add", "(", "annotation", ")", ";", "}", "}", "}", "}", "else", "if", "(", "annoType", ".", "getNameWithoutPackage", "(", ")", ".", "equals", "(", "\"Test\"", ")", ")", "{", "TypeReference", "annotationReference", "=", "createTypeReferenceForClassNode", "(", "annoType", ")", ";", "annotationReference", ".", "sourceStart", "=", "annotationNode", ".", "getStart", "(", ")", ";", "annotationReference", ".", "sourceEnd", "=", "annotationNode", ".", "getEnd", "(", ")", ";", "MarkerAnnotation", "annotation", "=", "new", "MarkerAnnotation", "(", "annotationReference", ",", "annotationNode", ".", "getStart", "(", ")", ")", ";", "annotation", ".", "declarationSourceEnd", "=", "annotation", ".", "sourceEnd", ";", "annotations", ".", "add", "(", "annotation", ")", ";", "}", "}", "}", "if", "(", "annotations", ".", "size", "(", ")", ">", "0", ")", "{", "return", "annotations", ".", "toArray", "(", "new", "Annotation", "[", "annotations", ".", "size", "(", ")", "]", ")", ";", "}", "}", "return", "null", ";", "}", "private", "TypeReference", "classLiteralToTypeReference", "(", "PropertyExpression", "value", ")", "{", "assert", "value", ".", "getPropertyAsString", "(", ")", ".", "equals", "(", "\"class\"", ")", ";", "Expression", "candidate", "=", "value", ".", "getObjectExpression", "(", ")", ";", "List", "<", "char", "[", "]", ">", "nameParts", "=", "new", "LinkedList", "<", "char", "[", "]", ">", "(", ")", ";", "while", "(", "candidate", "instanceof", "PropertyExpression", ")", "{", "nameParts", ".", "add", "(", "0", ",", "(", "(", "PropertyExpression", ")", "candidate", ")", ".", "getPropertyAsString", "(", ")", ".", "toCharArray", "(", ")", ")", ";", "candidate", "=", "(", "(", "PropertyExpression", ")", "candidate", ")", ".", "getObjectExpression", "(", ")", ";", "}", "if", "(", "candidate", "instanceof", "VariableExpression", ")", "{", "nameParts", ".", "add", "(", "0", ",", "(", "(", "VariableExpression", ")", "candidate", ")", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ")", ";", "}", "char", "[", "]", "[", "]", "namePartsArr", "=", "nameParts", ".", "toArray", "(", "new", "char", "[", "nameParts", ".", "size", "(", ")", "]", "[", "]", ")", ";", "long", "[", "]", "poss", "=", "positionsFor", "(", "namePartsArr", ",", "value", ".", "getObjectExpression", "(", ")", ".", "getStart", "(", ")", ",", "value", ".", "getObjectExpression", "(", ")", ".", "getEnd", "(", ")", ")", ";", "TypeReference", "ref", ";", "if", "(", "namePartsArr", ".", "length", ">", "1", ")", "{", "ref", "=", "new", "QualifiedTypeReference", "(", "namePartsArr", ",", "poss", ")", ";", "}", "else", "if", "(", "namePartsArr", ".", "length", "==", "1", ")", "{", "ref", "=", "new", "SingleTypeReference", "(", "namePartsArr", "[", "0", "]", ",", "poss", "[", "0", "]", ")", ";", "}", "else", "{", "ref", "=", "TypeReference", ".", "baseTypeReference", "(", "nameToPrimitiveTypeId", ".", "get", "(", "\"void\"", ")", ",", "0", ")", ";", "}", "return", "ref", ";", "}", "private", "Javadoc", "findJavadoc", "(", "int", "line", ")", "{", "for", "(", "Comment", "comment", ":", "groovySourceUnit", ".", "getComments", "(", ")", ")", "{", "if", "(", "comment", ".", "isJavadoc", "(", ")", ")", "{", "if", "(", "comment", ".", "getLastLine", "(", ")", "+", "1", "==", "line", "||", "(", "comment", ".", "getLastLine", "(", ")", "+", "2", "==", "line", "&&", "!", "comment", ".", "usedUp", ")", ")", "{", "int", "[", "]", "pos", "=", "comment", ".", "getPositions", "(", "compilationResult", ".", "lineSeparatorPositions", ")", ";", "comment", ".", "usedUp", "=", "true", ";", "return", "new", "Javadoc", "(", "pos", "[", "0", "]", ",", "pos", "[", "1", "]", ")", ";", "}", "}", "}", "return", "null", ";", "}", "private", "void", "createTypeDeclarations", "(", "ModuleNode", "moduleNode", ")", "{", "List", "<", "ClassNode", ">", "moduleClassNodes", "=", "moduleNode", ".", "getClasses", "(", ")", ";", "List", "<", "TypeDeclaration", ">", "typeDeclarations", "=", "new", "ArrayList", "<", "TypeDeclaration", ">", "(", ")", ";", "Map", "<", "ClassNode", ",", "TypeDeclaration", ">", "fromClassNodeToDecl", "=", "new", "HashMap", "<", "ClassNode", ",", "TypeDeclaration", ">", "(", ")", ";", "char", "[", "]", "mainName", "=", "toMainName", "(", "compilationResult", ".", "getFileName", "(", ")", ")", ";", "boolean", "isInner", "=", "false", ";", "List", "<", "ClassNode", ">", "classNodes", "=", "null", ";", "classNodes", "=", "moduleClassNodes", ";", "Map", "<", "ClassNode", ",", "List", "<", "TypeDeclaration", ">", ">", "innersToRecord", "=", "new", "HashMap", "<", "ClassNode", ",", "List", "<", "TypeDeclaration", ">", ">", "(", ")", ";", "for", "(", "ClassNode", "classNode", ":", "classNodes", ")", "{", "if", "(", "!", "classNode", ".", "isPrimaryClassNode", "(", ")", ")", "{", "continue", ";", "}", "GroovyTypeDeclaration", "typeDeclaration", "=", "new", "GroovyTypeDeclaration", "(", "compilationResult", ",", "classNode", ")", ";", "typeDeclaration", ".", "annotations", "=", "transformAnnotations", "(", "classNode", ".", "getAnnotations", "(", ")", ")", ";", "if", "(", "classNode", "instanceof", "InnerClassNode", ")", "{", "InnerClassNode", "innerClassNode", "=", "(", "InnerClassNode", ")", "classNode", ";", "ClassNode", "outerClass", "=", "innerClassNode", ".", "getOuterClass", "(", ")", ";", "String", "outername", "=", "outerClass", ".", "getNameWithoutPackage", "(", ")", ";", "String", "newInner", "=", "innerClassNode", ".", "getNameWithoutPackage", "(", ")", ".", "substring", "(", "outername", ".", "length", "(", ")", "+", "1", ")", ";", "typeDeclaration", ".", "name", "=", "newInner", ".", "toCharArray", "(", ")", ";", "isInner", "=", "true", ";", "}", "else", "{", "typeDeclaration", ".", "name", "=", "classNode", ".", "getNameWithoutPackage", "(", ")", ".", "toCharArray", "(", ")", ";", "isInner", "=", "false", ";", "}", "boolean", "isInterface", "=", "classNode", ".", "isInterface", "(", ")", ";", "int", "mods", "=", "classNode", ".", "getModifiers", "(", ")", ";", "if", "(", "(", "mods", "&", "Opcodes", ".", "ACC_ENUM", ")", "!=", "0", ")", "{", "mods", "=", "mods", "&", "~", "Opcodes", ".", "ACC_FINAL", ";", "}", "mods", "=", "mods", "&", "~", "(", "Opcodes", ".", "ACC_PRIVATE", "|", "Opcodes", ".", "ACC_PROTECTED", ")", ";", "if", "(", "!", "isInner", ")", "{", "if", "(", "(", "mods", "&", "Opcodes", ".", "ACC_STATIC", ")", "!=", "0", ")", "{", "mods", "=", "mods", "&", "~", "(", "Opcodes", ".", "ACC_STATIC", ")", ";", "}", "}", "typeDeclaration", ".", "modifiers", "=", "mods", "&", "~", "(", "isInterface", "?", "Opcodes", ".", "ACC_ABSTRACT", ":", "0", ")", ";", "if", "(", "!", "(", "classNode", "instanceof", "InnerClassNode", ")", ")", "{", "if", "(", "!", "CharOperation", ".", "equals", "(", "typeDeclaration", ".", "name", ",", "mainName", ")", ")", "{", "typeDeclaration", ".", "bits", "|=", "ASTNode", ".", "IsSecondaryType", ";", "}", "}", "fixupSourceLocationsForTypeDeclaration", "(", "typeDeclaration", ",", "classNode", ")", ";", "if", "(", "classNode", ".", "getGenericsTypes", "(", ")", "!=", "null", ")", "{", "GenericsType", "[", "]", "genericInfo", "=", "classNode", ".", "getGenericsTypes", "(", ")", ";", "typeDeclaration", ".", "typeParameters", "=", "new", "TypeParameter", "[", "genericInfo", ".", "length", "]", ";", "for", "(", "int", "tp", "=", "0", ";", "tp", "<", "genericInfo", ".", "length", ";", "tp", "++", ")", "{", "TypeParameter", "typeParameter", "=", "new", "TypeParameter", "(", ")", ";", "typeParameter", ".", "name", "=", "genericInfo", "[", "tp", "]", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ";", "ClassNode", "[", "]", "upperBounds", "=", "genericInfo", "[", "tp", "]", ".", "getUpperBounds", "(", ")", ";", "if", "(", "upperBounds", "!=", "null", ")", "{", "typeParameter", ".", "type", "=", "createTypeReferenceForClassNode", "(", "upperBounds", "[", "0", "]", ")", ";", "typeParameter", ".", "bounds", "=", "(", "upperBounds", ".", "length", ">", "1", "?", "new", "TypeReference", "[", "upperBounds", ".", "length", "-", "1", "]", ":", "null", ")", ";", "for", "(", "int", "b", "=", "1", ",", "max", "=", "upperBounds", ".", "length", ";", "b", "<", "max", ";", "b", "++", ")", "{", "typeParameter", ".", "bounds", "[", "b", "-", "1", "]", "=", "createTypeReferenceForClassNode", "(", "upperBounds", "[", "b", "]", ")", ";", "typeParameter", ".", "bounds", "[", "b", "-", "1", "]", ".", "bits", "|=", "ASTNode", ".", "IsSuperType", ";", "}", "}", "typeDeclaration", ".", "typeParameters", "[", "tp", "]", "=", "typeParameter", ";", "}", "}", "boolean", "isEnum", "=", "(", "classNode", ".", "getModifiers", "(", ")", "&", "Opcodes", ".", "ACC_ENUM", ")", "!=", "0", ";", "configureSuperClass", "(", "typeDeclaration", ",", "classNode", ".", "getSuperClass", "(", ")", ",", "isEnum", ")", ";", "configureSuperInterfaces", "(", "typeDeclaration", ",", "classNode", ")", ";", "typeDeclaration", ".", "methods", "=", "createMethodAndConstructorDeclarations", "(", "classNode", ",", "isEnum", ",", "compilationResult", ")", ";", "typeDeclaration", ".", "fields", "=", "createFieldDeclarations", "(", "classNode", ")", ";", "typeDeclaration", ".", "properties", "=", "classNode", ".", "getProperties", "(", ")", ";", "if", "(", "classNode", "instanceof", "InnerClassNode", ")", "{", "InnerClassNode", "innerClassNode", "=", "(", "InnerClassNode", ")", "classNode", ";", "ClassNode", "outerClass", "=", "innerClassNode", ".", "getOuterClass", "(", ")", ";", "String", "outername", "=", "outerClass", ".", "getNameWithoutPackage", "(", ")", ";", "String", "newInner", "=", "innerClassNode", ".", "getNameWithoutPackage", "(", ")", ".", "substring", "(", "outername", ".", "length", "(", ")", "+", "1", ")", ";", "typeDeclaration", ".", "name", "=", "newInner", ".", "toCharArray", "(", ")", ";", "List", "<", "TypeDeclaration", ">", "inners", "=", "innersToRecord", ".", "get", "(", "outerClass", ")", ";", "if", "(", "inners", "==", "null", ")", "{", "inners", "=", "new", "ArrayList", "<", "TypeDeclaration", ">", "(", ")", ";", "innersToRecord", ".", "put", "(", "outerClass", ",", "inners", ")", ";", "}", "inners", ".", "add", "(", "typeDeclaration", ")", ";", "}", "else", "{", "typeDeclarations", ".", "add", "(", "typeDeclaration", ")", ";", "}", "fromClassNodeToDecl", ".", "put", "(", "classNode", ",", "typeDeclaration", ")", ";", "}", "for", "(", "Map", ".", "Entry", "<", "ClassNode", ",", "List", "<", "TypeDeclaration", ">", ">", "innersToRecordEntry", ":", "innersToRecord", ".", "entrySet", "(", ")", ")", "{", "TypeDeclaration", "outerTypeDeclaration", "=", "fromClassNodeToDecl", ".", "get", "(", "innersToRecordEntry", ".", "getKey", "(", ")", ")", ";", "if", "(", "outerTypeDeclaration", "==", "null", ")", "{", "throw", "new", "GroovyEclipseBug", "(", "\"\"", "+", "innersToRecordEntry", ".", "getKey", "(", ")", ".", "getName", "(", ")", ")", ";", "}", "List", "<", "TypeDeclaration", ">", "newInnersList", "=", "innersToRecordEntry", ".", "getValue", "(", ")", ";", "outerTypeDeclaration", ".", "memberTypes", "=", "newInnersList", ".", "toArray", "(", "new", "TypeDeclaration", "[", "newInnersList", ".", "size", "(", ")", "]", ")", ";", "}", "types", "=", "typeDeclarations", ".", "toArray", "(", "new", "TypeDeclaration", "[", "typeDeclarations", ".", "size", "(", ")", "]", ")", ";", "}", "public", "char", "[", "]", "toMainName", "(", "char", "[", "]", "fileName", ")", "{", "if", "(", "fileName", "==", "null", ")", "{", "return", "new", "char", "[", "0", "]", ";", "}", "int", "start", "=", "CharOperation", ".", "lastIndexOf", "(", "'/'", ",", "fileName", ")", "+", "1", ";", "if", "(", "start", "==", "0", "||", "start", "<", "CharOperation", ".", "lastIndexOf", "(", "'\\\\'", ",", "fileName", ")", ")", "start", "=", "CharOperation", ".", "lastIndexOf", "(", "'\\\\'", ",", "fileName", ")", "+", "1", ";", "int", "end", "=", "CharOperation", ".", "lastIndexOf", "(", "'.'", ",", "fileName", ")", ";", "if", "(", "end", "==", "-", "1", ")", "end", "=", "fileName", ".", "length", ";", "return", "CharOperation", ".", "subarray", "(", "fileName", ",", "start", ",", "end", ")", ";", "}", "private", "AbstractMethodDeclaration", "[", "]", "createMethodAndConstructorDeclarations", "(", "ClassNode", "classNode", ",", "boolean", "isEnum", ",", "CompilationResult", "compilationResult", ")", "{", "List", "<", "AbstractMethodDeclaration", ">", "accumulatedDeclarations", "=", "new", "ArrayList", "<", "AbstractMethodDeclaration", ">", "(", ")", ";", "createConstructorDeclarations", "(", "classNode", ",", "isEnum", ",", "accumulatedDeclarations", ")", ";", "createMethodDeclarations", "(", "classNode", ",", "isEnum", ",", "accumulatedDeclarations", ")", ";", "return", "accumulatedDeclarations", ".", "toArray", "(", "new", "AbstractMethodDeclaration", "[", "accumulatedDeclarations", ".", "size", "(", ")", "]", ")", ";", "}", "static", "class", "FieldDeclarationWithInitializer", "extends", "FieldDeclaration", "{", "private", "Expression", "initializer", ";", "public", "FieldDeclarationWithInitializer", "(", "char", "[", "]", "name", ",", "int", "sourceStart", ",", "int", "sourceEnd", ")", "{", "super", "(", "name", ",", "sourceStart", ",", "sourceEnd", ")", ";", "}", "public", "void", "setGroovyInitializer", "(", "Expression", "initializer", ")", "{", "this", ".", "initializer", "=", "initializer", ";", "}", "public", "Expression", "getGroovyInitializer", "(", ")", "{", "return", "this", ".", "initializer", ";", "}", "}", "private", "FieldDeclaration", "[", "]", "createFieldDeclarations", "(", "ClassNode", "classNode", ")", "{", "List", "<", "FieldDeclaration", ">", "fieldDeclarations", "=", "new", "ArrayList", "<", "FieldDeclaration", ">", "(", ")", ";", "List", "<", "FieldNode", ">", "fieldNodes", "=", "classNode", ".", "getFields", "(", ")", ";", "if", "(", "fieldNodes", "!=", "null", ")", "{", "for", "(", "FieldNode", "fieldNode", ":", "fieldNodes", ")", "{", "boolean", "isEnumField", "=", "(", "fieldNode", ".", "getModifiers", "(", ")", "&", "Opcodes", ".", "ACC_ENUM", ")", "!=", "0", ";", "boolean", "isSynthetic", "=", "(", "fieldNode", ".", "getModifiers", "(", ")", "&", "Opcodes", ".", "ACC_SYNTHETIC", ")", "!=", "0", ";", "if", "(", "!", "isSynthetic", ")", "{", "FieldDeclarationWithInitializer", "fieldDeclaration", "=", "new", "FieldDeclarationWithInitializer", "(", "fieldNode", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ",", "0", ",", "0", ")", ";", "fieldDeclaration", ".", "annotations", "=", "transformAnnotations", "(", "fieldNode", ".", "getAnnotations", "(", ")", ")", ";", "if", "(", "!", "isEnumField", ")", "{", "fieldDeclaration", ".", "modifiers", "=", "fieldNode", ".", "getModifiers", "(", ")", "&", "~", "0x4000", ";", "fieldDeclaration", ".", "type", "=", "createTypeReferenceForClassNode", "(", "fieldNode", ".", "getType", "(", ")", ")", ";", "}", "fieldDeclaration", ".", "javadoc", "=", "new", "Javadoc", "(", "108", ",", "132", ")", ";", "fixupSourceLocationsForFieldDeclaration", "(", "fieldDeclaration", ",", "fieldNode", ",", "isEnumField", ")", ";", "fieldDeclaration", ".", "setGroovyInitializer", "(", "fieldNode", ".", "getInitialExpression", "(", ")", ")", ";", "fieldDeclarations", ".", "add", "(", "fieldDeclaration", ")", ";", "}", "}", "}", "return", "fieldDeclarations", ".", "toArray", "(", "new", "FieldDeclaration", "[", "fieldDeclarations", ".", "size", "(", ")", "]", ")", ";", "}", "private", "void", "createConstructorDeclarations", "(", "ClassNode", "classNode", ",", "boolean", "isEnum", ",", "List", "<", "AbstractMethodDeclaration", ">", "accumulatedMethodDeclarations", ")", "{", "List", "<", "ConstructorNode", ">", "constructorNodes", "=", "classNode", ".", "getDeclaredConstructors", "(", ")", ";", "char", "[", "]", "ctorName", "=", "null", ";", "if", "(", "classNode", "instanceof", "InnerClassNode", ")", "{", "InnerClassNode", "innerClassNode", "=", "(", "InnerClassNode", ")", "classNode", ";", "ClassNode", "outerClass", "=", "innerClassNode", ".", "getOuterClass", "(", ")", ";", "String", "outername", "=", "outerClass", ".", "getNameWithoutPackage", "(", ")", ";", "String", "newInner", "=", "innerClassNode", ".", "getNameWithoutPackage", "(", ")", ".", "substring", "(", "outername", ".", "length", "(", ")", "+", "1", ")", ";", "ctorName", "=", "newInner", ".", "toCharArray", "(", ")", ";", "}", "else", "{", "ctorName", "=", "classNode", ".", "getNameWithoutPackage", "(", ")", ".", "toCharArray", "(", ")", ";", "}", "boolean", "needsDefaultCtor", "=", "constructorNodes", ".", "size", "(", ")", "==", "0", "&&", "!", "classNode", ".", "isInterface", "(", ")", ";", "if", "(", "needsDefaultCtor", ")", "{", "ConstructorDeclaration", "constructor", "=", "new", "ConstructorDeclaration", "(", "compilationResult", ")", ";", "constructor", ".", "bits", "|=", "ASTNode", ".", "IsDefaultConstructor", ";", "if", "(", "isEnum", ")", "{", "constructor", ".", "modifiers", "=", "ClassFileConstants", ".", "AccPrivate", ";", "}", "else", "{", "constructor", ".", "modifiers", "=", "ClassFileConstants", ".", "AccPublic", ";", "}", "constructor", ".", "selector", "=", "ctorName", ";", "accumulatedMethodDeclarations", ".", "add", "(", "constructor", ")", ";", "}", "for", "(", "ConstructorNode", "constructorNode", ":", "constructorNodes", ")", "{", "ConstructorDeclaration", "constructorDeclaration", "=", "new", "ConstructorDeclaration", "(", "compilationResult", ")", ";", "fixupSourceLocationsForConstructorDeclaration", "(", "constructorDeclaration", ",", "constructorNode", ")", ";", "constructorDeclaration", ".", "annotations", "=", "transformAnnotations", "(", "constructorNode", ".", "getAnnotations", "(", ")", ")", ";", "constructorDeclaration", ".", "modifiers", "=", "isEnum", "?", "ClassFileConstants", ".", "AccPrivate", ":", "ClassFileConstants", ".", "AccPublic", ";", "constructorDeclaration", ".", "selector", "=", "ctorName", ";", "constructorDeclaration", ".", "arguments", "=", "createArguments", "(", "constructorNode", ".", "getParameters", "(", ")", ",", "false", ")", ";", "constructorDeclaration", ".", "thrownExceptions", "=", "createTypeReferencesForClassNodes", "(", "constructorNode", ".", "getExceptions", "(", ")", ")", ";", "if", "(", "constructorNode", ".", "hasDefaultValue", "(", ")", ")", "{", "createConstructorVariants", "(", "constructorNode", ",", "constructorDeclaration", ",", "accumulatedMethodDeclarations", ",", "compilationResult", ",", "isEnum", ")", ";", "}", "else", "{", "accumulatedMethodDeclarations", ".", "add", "(", "constructorDeclaration", ")", ";", "}", "}", "if", "(", "earlyTransforms", ")", "{", "executeEarlyTransforms_ConstructorRelated", "(", "ctorName", ",", "classNode", ",", "accumulatedMethodDeclarations", ")", ";", "}", "}", "private", "void", "executeEarlyTransforms_ConstructorRelated", "(", "char", "[", "]", "ctorName", ",", "ClassNode", "classNode", ",", "List", "<", "AbstractMethodDeclaration", ">", "accumulatedMethodDeclarations", ")", "{", "List", "<", "AnnotationNode", ">", "annos", "=", "classNode", ".", "getAnnotations", "(", ")", ";", "boolean", "hasImmutableAnnotation", "=", "false", ";", "if", "(", "annos", "!=", "null", ")", "{", "for", "(", "AnnotationNode", "anno", ":", "annos", ")", "{", "if", "(", "anno", ".", "getClassNode", "(", ")", "!=", "null", "&&", "anno", ".", "getClassNode", "(", ")", ".", "getName", "(", ")", ".", "equals", "(", "\"Immutable\"", ")", ")", "{", "hasImmutableAnnotation", "=", "true", ";", "}", "}", "}", "if", "(", "hasImmutableAnnotation", ")", "{", "List", "<", "FieldNode", ">", "fields", "=", "classNode", ".", "getFields", "(", ")", ";", "Argument", "[", "]", "arguments", "=", "new", "Argument", "[", "fields", ".", "size", "(", ")", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "fields", ".", "size", "(", ")", ";", "i", "++", ")", "{", "FieldNode", "field", "=", "fields", ".", "get", "(", "i", ")", ";", "TypeReference", "parameterTypeReference", "=", "createTypeReferenceForClassNode", "(", "field", ".", "getType", "(", ")", ")", ";", "arguments", "[", "i", "]", "=", "new", "Argument", "(", "fields", ".", "get", "(", "i", ")", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ",", "toPos", "(", "field", ".", "getStart", "(", ")", ",", "field", ".", "getEnd", "(", ")", "-", "1", ")", ",", "parameterTypeReference", ",", "ClassFileConstants", ".", "AccPublic", ")", ";", "arguments", "[", "i", "]", ".", "declarationSourceStart", "=", "fields", ".", "get", "(", "i", ")", ".", "getStart", "(", ")", ";", "}", "ConstructorDeclaration", "constructor", "=", "new", "ConstructorDeclaration", "(", "compilationResult", ")", ";", "constructor", ".", "selector", "=", "ctorName", ";", "constructor", ".", "modifiers", "=", "ClassFileConstants", ".", "AccPublic", ";", "constructor", ".", "arguments", "=", "arguments", ";", "accumulatedMethodDeclarations", ".", "add", "(", "constructor", ")", ";", "}", "}", "private", "Argument", "[", "]", "createArguments", "(", "Parameter", "[", "]", "ps", ",", "boolean", "isMain", ")", "{", "if", "(", "ps", "==", "null", "||", "ps", ".", "length", "==", "0", ")", "{", "return", "null", ";", "}", "Argument", "[", "]", "arguments", "=", "new", "Argument", "[", "ps", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "ps", ".", "length", ";", "i", "++", ")", "{", "Parameter", "parameter", "=", "ps", "[", "i", "]", ";", "TypeReference", "parameterTypeReference", "=", "createTypeReferenceForClassNode", "(", "parameter", ".", "getType", "(", ")", ")", ";", "arguments", "[", "i", "]", "=", "new", "Argument", "(", "parameter", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ",", "toPos", "(", "parameter", ".", "getStart", "(", ")", ",", "parameter", ".", "getEnd", "(", ")", "-", "1", ")", ",", "parameterTypeReference", ",", "ClassFileConstants", ".", "AccPublic", ")", ";", "arguments", "[", "i", "]", ".", "declarationSourceStart", "=", "parameter", ".", "getStart", "(", ")", ";", "}", "if", "(", "isVargs", "(", "ps", ")", ")", "{", "arguments", "[", "ps", ".", "length", "-", "1", "]", ".", "type", ".", "bits", "|=", "ASTNode", ".", "IsVarArgs", ";", "}", "return", "arguments", ";", "}", "private", "void", "createMethodDeclarations", "(", "ClassNode", "classNode", ",", "boolean", "isEnum", ",", "List", "<", "AbstractMethodDeclaration", ">", "accumulatedDeclarations", ")", "{", "List", "<", "MethodNode", ">", "methods", "=", "classNode", ".", "getMethods", "(", ")", ";", "for", "(", "MethodNode", "methodNode", ":", "methods", ")", "{", "if", "(", "isEnum", "&&", "methodNode", ".", "isSynthetic", "(", ")", ")", "{", "String", "name", "=", "methodNode", ".", "getName", "(", ")", ";", "Parameter", "[", "]", "params", "=", "methodNode", ".", "getParameters", "(", ")", ";", "if", "(", "name", ".", "equals", "(", "\"values\"", ")", "&&", "params", ".", "length", "==", "0", ")", "{", "continue", ";", "}", "if", "(", "name", ".", "equals", "(", "\"valueOf\"", ")", "&&", "params", ".", "length", "==", "1", "&&", "params", "[", "0", "]", ".", "getType", "(", ")", ".", "equals", "(", "ClassHelper", ".", "STRING_TYPE", ")", ")", "{", "continue", ";", "}", "}", "MethodDeclaration", "methodDeclaration", "=", "createMethodDeclaration", "(", "classNode", ",", "methodNode", ",", "isEnum", ",", "compilationResult", ")", ";", "if", "(", "methodNode", ".", "hasDefaultValue", "(", ")", ")", "{", "createMethodVariants", "(", "methodNode", ",", "methodDeclaration", ",", "accumulatedDeclarations", ",", "compilationResult", ")", ";", "}", "else", "{", "accumulatedDeclarations", ".", "add", "(", "methodDeclaration", ")", ";", "}", "}", "}", "private", "void", "createMethodVariants", "(", "MethodNode", "method", ",", "MethodDeclaration", "methodDecl", ",", "List", "<", "AbstractMethodDeclaration", ">", "accumulatedDeclarations", ",", "CompilationResult", "compilationResult", ")", "{", "List", "<", "Argument", "[", "]", ">", "variants", "=", "getVariantsAllowingForDefaulting", "(", "method", ".", "getParameters", "(", ")", ",", "methodDecl", ".", "arguments", ")", ";", "for", "(", "Argument", "[", "]", "variant", ":", "variants", ")", "{", "MethodDeclaration", "variantMethodDeclaration", "=", "genMethodDeclarationVariant", "(", "method", ",", "variant", ",", "methodDecl", ".", "returnType", ",", "compilationResult", ")", ";", "addUnlessDuplicate", "(", "accumulatedDeclarations", ",", "variantMethodDeclaration", ")", ";", "}", "}", "private", "List", "<", "Argument", "[", "]", ">", "getVariantsAllowingForDefaulting", "(", "Parameter", "[", "]", "groovyParams", ",", "Argument", "[", "]", "jdtArguments", ")", "{", "List", "<", "Argument", "[", "]", ">", "variants", "=", "new", "ArrayList", "<", "Argument", "[", "]", ">", "(", ")", ";", "int", "psCount", "=", "groovyParams", ".", "length", ";", "Parameter", "[", "]", "wipableParameters", "=", "new", "Parameter", "[", "psCount", "]", ";", "System", ".", "arraycopy", "(", "groovyParams", ",", "0", ",", "wipableParameters", ",", "0", ",", "psCount", ")", ";", "List", "<", "Argument", ">", "oneVariation", "=", "new", "ArrayList", "<", "Argument", ">", "(", ")", ";", "int", "nextToLetDefault", "=", "-", "1", ";", "do", "{", "oneVariation", ".", "clear", "(", ")", ";", "nextToLetDefault", "=", "-", "1", ";", "for", "(", "int", "p", "=", "0", ";", "p", "<", "psCount", ";", "p", "++", ")", "{", "if", "(", "wipableParameters", "[", "p", "]", "!=", "null", ")", "{", "oneVariation", ".", "add", "(", "jdtArguments", "[", "p", "]", ")", ";", "if", "(", "wipableParameters", "[", "p", "]", ".", "hasInitialExpression", "(", ")", ")", "{", "nextToLetDefault", "=", "p", ";", "}", "}", "}", "if", "(", "nextToLetDefault", "!=", "-", "1", ")", "{", "wipableParameters", "[", "nextToLetDefault", "]", "=", "null", ";", "}", "Argument", "[", "]", "argumentsVariant", "=", "(", "oneVariation", ".", "size", "(", ")", "==", "0", "?", "null", ":", "oneVariation", ".", "toArray", "(", "new", "Argument", "[", "oneVariation", ".", "size", "(", ")", "]", ")", ")", ";", "variants", ".", "add", "(", "argumentsVariant", ")", ";", "}", "while", "(", "nextToLetDefault", "!=", "-", "1", ")", ";", "return", "variants", ";", "}", "private", "void", "addUnlessDuplicate", "(", "List", "<", "AbstractMethodDeclaration", ">", "accumulatedDeclarations", ",", "AbstractMethodDeclaration", "newDeclaration", ")", "{", "boolean", "isDuplicate", "=", "false", ";", "for", "(", "AbstractMethodDeclaration", "aMethodDecl", ":", "accumulatedDeclarations", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "aMethodDecl", ".", "selector", ",", "newDeclaration", ".", "selector", ")", ")", "{", "Argument", "[", "]", "mdArgs", "=", "aMethodDecl", ".", "arguments", ";", "Argument", "[", "]", "vmdArgs", "=", "newDeclaration", ".", "arguments", ";", "int", "mdArgsLen", "=", "mdArgs", "==", "null", "?", "0", ":", "mdArgs", ".", "length", ";", "int", "vmdArgsLen", "=", "vmdArgs", "==", "null", "?", "0", ":", "vmdArgs", ".", "length", ";", "if", "(", "mdArgsLen", "==", "vmdArgsLen", ")", "{", "boolean", "argsTheSame", "=", "true", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "mdArgsLen", ";", "i", "++", ")", "{", "if", "(", "!", "CharOperation", ".", "equals", "(", "mdArgs", "[", "i", "]", ".", "type", ".", "getTypeName", "(", ")", ",", "vmdArgs", "[", "i", "]", ".", "type", ".", "getTypeName", "(", ")", ")", ")", "{", "argsTheSame", "=", "false", ";", "break", ";", "}", "}", "if", "(", "argsTheSame", ")", "{", "isDuplicate", "=", "true", ";", "break", ";", "}", "}", "}", "}", "if", "(", "!", "isDuplicate", ")", "{", "accumulatedDeclarations", ".", "add", "(", "newDeclaration", ")", ";", "}", "}", "private", "void", "createConstructorVariants", "(", "ConstructorNode", "constructorNode", ",", "ConstructorDeclaration", "constructorDecl", ",", "List", "<", "AbstractMethodDeclaration", ">", "accumulatedDeclarations", ",", "CompilationResult", "compilationResult", ",", "boolean", "isEnum", ")", "{", "List", "<", "Argument", "[", "]", ">", "variants", "=", "getVariantsAllowingForDefaulting", "(", "constructorNode", ".", "getParameters", "(", ")", ",", "constructorDecl", ".", "arguments", ")", ";", "for", "(", "Argument", "[", "]", "variant", ":", "variants", ")", "{", "ConstructorDeclaration", "constructorDeclaration", "=", "new", "ConstructorDeclaration", "(", "compilationResult", ")", ";", "constructorDeclaration", ".", "annotations", "=", "transformAnnotations", "(", "constructorNode", ".", "getAnnotations", "(", ")", ")", ";", "constructorDeclaration", ".", "modifiers", "=", "isEnum", "?", "ClassFileConstants", ".", "AccPrivate", ":", "ClassFileConstants", ".", "AccPublic", ";", "constructorDeclaration", ".", "selector", "=", "constructorDecl", ".", "selector", ";", "constructorDeclaration", ".", "arguments", "=", "variant", ";", "fixupSourceLocationsForConstructorDeclaration", "(", "constructorDeclaration", ",", "constructorNode", ")", ";", "addUnlessDuplicate", "(", "accumulatedDeclarations", ",", "constructorDeclaration", ")", ";", "}", "}", "private", "MethodDeclaration", "createMethodDeclaration", "(", "ClassNode", "classNode", ",", "MethodNode", "methodNode", ",", "boolean", "isEnum", ",", "CompilationResult", "compilationResult", ")", "{", "if", "(", "classNode", ".", "isAnnotationDefinition", "(", ")", ")", "{", "AnnotationMethodDeclaration", "methodDeclaration", "=", "new", "AnnotationMethodDeclaration", "(", "compilationResult", ")", ";", "int", "modifiers", "=", "methodNode", ".", "getModifiers", "(", ")", ";", "modifiers", "&=", "~", "(", "ClassFileConstants", ".", "AccSynthetic", "|", "ClassFileConstants", ".", "AccTransient", ")", ";", "methodDeclaration", ".", "annotations", "=", "transformAnnotations", "(", "methodNode", ".", "getAnnotations", "(", ")", ")", ";", "methodDeclaration", ".", "modifiers", "=", "modifiers", ";", "if", "(", "methodNode", ".", "hasAnnotationDefault", "(", ")", ")", "{", "methodDeclaration", ".", "modifiers", "|=", "ClassFileConstants", ".", "AccAnnotationDefault", ";", "}", "methodDeclaration", ".", "selector", "=", "methodNode", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ";", "fixupSourceLocationsForMethodDeclaration", "(", "methodDeclaration", ",", "methodNode", ")", ";", "ClassNode", "returnType", "=", "methodNode", ".", "getReturnType", "(", ")", ";", "methodDeclaration", ".", "returnType", "=", "createTypeReferenceForClassNode", "(", "returnType", ")", ";", "return", "methodDeclaration", ";", "}", "else", "{", "MethodDeclaration", "methodDeclaration", "=", "new", "MethodDeclaration", "(", "compilationResult", ")", ";", "GenericsType", "[", "]", "generics", "=", "methodNode", ".", "getGenericsTypes", "(", ")", ";", "if", "(", "generics", "!=", "null", "&&", "generics", ".", "length", "!=", "0", ")", "{", "methodDeclaration", ".", "typeParameters", "=", "new", "TypeParameter", "[", "generics", ".", "length", "]", ";", "for", "(", "int", "tp", "=", "0", ";", "tp", "<", "generics", ".", "length", ";", "tp", "++", ")", "{", "TypeParameter", "typeParameter", "=", "new", "TypeParameter", "(", ")", ";", "typeParameter", ".", "name", "=", "generics", "[", "tp", "]", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ";", "ClassNode", "[", "]", "upperBounds", "=", "generics", "[", "tp", "]", ".", "getUpperBounds", "(", ")", ";", "if", "(", "upperBounds", "!=", "null", ")", "{", "typeParameter", ".", "type", "=", "createTypeReferenceForClassNode", "(", "upperBounds", "[", "0", "]", ")", ";", "typeParameter", ".", "bounds", "=", "(", "upperBounds", ".", "length", ">", "1", "?", "new", "TypeReference", "[", "upperBounds", ".", "length", "-", "1", "]", ":", "null", ")", ";", "for", "(", "int", "b", "=", "1", ",", "max", "=", "upperBounds", ".", "length", ";", "b", "<", "max", ";", "b", "++", ")", "{", "typeParameter", ".", "bounds", "[", "b", "-", "1", "]", "=", "createTypeReferenceForClassNode", "(", "upperBounds", "[", "b", "]", ")", ";", "typeParameter", ".", "bounds", "[", "b", "-", "1", "]", ".", "bits", "|=", "ASTNode", ".", "IsSuperType", ";", "}", "}", "methodDeclaration", ".", "typeParameters", "[", "tp", "]", "=", "typeParameter", ";", "}", "}", "boolean", "isMain", "=", "false", ";", "int", "modifiers", "=", "methodNode", ".", "getModifiers", "(", ")", ";", "modifiers", "&=", "~", "(", "ClassFileConstants", ".", "AccSynthetic", "|", "ClassFileConstants", ".", "AccTransient", ")", ";", "methodDeclaration", ".", "annotations", "=", "transformAnnotations", "(", "methodNode", ".", "getAnnotations", "(", ")", ")", ";", "methodDeclaration", ".", "modifiers", "=", "modifiers", ";", "methodDeclaration", ".", "selector", "=", "methodNode", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ";", "Parameter", "[", "]", "params", "=", "methodNode", ".", "getParameters", "(", ")", ";", "ClassNode", "returnType", "=", "methodNode", ".", "getReturnType", "(", ")", ";", "if", "(", "(", "modifiers", "&", "ClassFileConstants", ".", "AccStatic", ")", "!=", "0", "&&", "params", "!=", "null", "&&", "params", ".", "length", "==", "1", "&&", "methodNode", ".", "getName", "(", ")", ".", "equals", "(", "\"main\"", ")", ")", "{", "Parameter", "p", "=", "params", "[", "0", "]", ";", "if", "(", "p", ".", "getType", "(", ")", "==", "null", "||", "p", ".", "getType", "(", ")", ".", "getName", "(", ")", ".", "equals", "(", "ClassHelper", ".", "OBJECT", ")", ")", "{", "String", "name", "=", "p", ".", "getName", "(", ")", ";", "params", "=", "new", "Parameter", "[", "1", "]", ";", "params", "[", "0", "]", "=", "new", "Parameter", "(", "ClassHelper", ".", "STRING_TYPE", ".", "makeArray", "(", ")", ",", "name", ")", ";", "if", "(", "returnType", ".", "getName", "(", ")", ".", "equals", "(", "ClassHelper", ".", "OBJECT", ")", ")", "{", "returnType", "=", "ClassHelper", ".", "VOID_TYPE", ";", "}", "}", "}", "methodDeclaration", ".", "arguments", "=", "createArguments", "(", "params", ",", "isMain", ")", ";", "methodDeclaration", ".", "returnType", "=", "createTypeReferenceForClassNode", "(", "returnType", ")", ";", "methodDeclaration", ".", "thrownExceptions", "=", "createTypeReferencesForClassNodes", "(", "methodNode", ".", "getExceptions", "(", ")", ")", ";", "fixupSourceLocationsForMethodDeclaration", "(", "methodDeclaration", ",", "methodNode", ")", ";", "return", "methodDeclaration", ";", "}", "}", "private", "MethodDeclaration", "genMethodDeclarationVariant", "(", "MethodNode", "methodNode", ",", "Argument", "[", "]", "alternativeArguments", ",", "TypeReference", "returnType", ",", "CompilationResult", "compilationResult", ")", "{", "MethodDeclaration", "methodDeclaration", "=", "new", "MethodDeclaration", "(", "compilationResult", ")", ";", "int", "modifiers", "=", "methodNode", ".", "getModifiers", "(", ")", ";", "modifiers", "&=", "~", "(", "ClassFileConstants", ".", "AccSynthetic", "|", "ClassFileConstants", ".", "AccTransient", ")", ";", "methodDeclaration", ".", "annotations", "=", "transformAnnotations", "(", "methodNode", ".", "getAnnotations", "(", ")", ")", ";", "methodDeclaration", ".", "modifiers", "=", "modifiers", ";", "methodDeclaration", ".", "selector", "=", "methodNode", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ";", "methodDeclaration", ".", "arguments", "=", "alternativeArguments", ";", "methodDeclaration", ".", "returnType", "=", "returnType", ";", "fixupSourceLocationsForMethodDeclaration", "(", "methodDeclaration", ",", "methodNode", ")", ";", "return", "methodDeclaration", ";", "}", "private", "void", "configureSuperInterfaces", "(", "TypeDeclaration", "typeDeclaration", ",", "ClassNode", "classNode", ")", "{", "ClassNode", "[", "]", "interfaces", "=", "classNode", ".", "getInterfaces", "(", ")", ";", "if", "(", "interfaces", "!=", "null", "&&", "interfaces", ".", "length", ">", "0", ")", "{", "typeDeclaration", ".", "superInterfaces", "=", "new", "TypeReference", "[", "interfaces", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "interfaces", ".", "length", ";", "i", "++", ")", "{", "typeDeclaration", ".", "superInterfaces", "[", "i", "]", "=", "createTypeReferenceForClassNode", "(", "interfaces", "[", "i", "]", ")", ";", "}", "}", "else", "{", "typeDeclaration", ".", "superInterfaces", "=", "new", "TypeReference", "[", "0", "]", ";", "}", "}", "private", "void", "configureSuperClass", "(", "TypeDeclaration", "typeDeclaration", ",", "ClassNode", "superclass", ",", "boolean", "isEnum", ")", "{", "if", "(", "isEnum", "&&", "superclass", ".", "getName", "(", ")", ".", "equals", "(", "\"\"", ")", ")", "{", "typeDeclaration", ".", "superclass", "=", "null", ";", "}", "else", "{", "if", "(", "!", "(", "superclass", ".", "getStart", "(", ")", "==", "0", "&&", "superclass", ".", "equals", "(", "ClassHelper", ".", "OBJECT_TYPE", ")", ")", ")", "{", "typeDeclaration", ".", "superclass", "=", "createTypeReferenceForClassNode", "(", "superclass", ")", ";", "}", "}", "}", "private", "final", "static", "Map", "<", "Character", ",", "Integer", ">", "charToTypeId", "=", "new", "HashMap", "<", "Character", ",", "Integer", ">", "(", ")", ";", "private", "final", "static", "Map", "<", "String", ",", "Integer", ">", "nameToPrimitiveTypeId", "=", "new", "HashMap", "<", "String", ",", "Integer", ">", "(", ")", ";", "static", "{", "charToTypeId", ".", "put", "(", "'D'", ",", "TypeIds", ".", "T_double", ")", ";", "charToTypeId", ".", "put", "(", "'I'", ",", "TypeIds", ".", "T_int", ")", ";", "charToTypeId", ".", "put", "(", "'F'", ",", "TypeIds", ".", "T_float", ")", ";", "charToTypeId", ".", "put", "(", "'J'", ",", "TypeIds", ".", "T_long", ")", ";", "charToTypeId", ".", "put", "(", "'Z'", ",", "TypeIds", ".", "T_boolean", ")", ";", "charToTypeId", ".", "put", "(", "'B'", ",", "TypeIds", ".", "T_byte", ")", ";", "charToTypeId", ".", "put", "(", "'C'", ",", "TypeIds", ".", "T_char", ")", ";", "charToTypeId", ".", "put", "(", "'S'", ",", "TypeIds", ".", "T_short", ")", ";", "nameToPrimitiveTypeId", ".", "put", "(", "\"double\"", ",", "TypeIds", ".", "T_double", ")", ";", "nameToPrimitiveTypeId", ".", "put", "(", "\"int\"", ",", "TypeIds", ".", "T_int", ")", ";", "nameToPrimitiveTypeId", ".", "put", "(", "\"float\"", ",", "TypeIds", ".", "T_float", ")", ";", "nameToPrimitiveTypeId", ".", "put", "(", "\"long\"", ",", "TypeIds", ".", "T_long", ")", ";", "nameToPrimitiveTypeId", ".", "put", "(", "\"boolean\"", ",", "TypeIds", ".", "T_boolean", ")", ";", "nameToPrimitiveTypeId", ".", "put", "(", "\"byte\"", ",", "TypeIds", ".", "T_byte", ")", ";", "nameToPrimitiveTypeId", ".", "put", "(", "\"char\"", ",", "TypeIds", ".", "T_char", ")", ";", "nameToPrimitiveTypeId", ".", "put", "(", "\"short\"", ",", "TypeIds", ".", "T_short", ")", ";", "nameToPrimitiveTypeId", ".", "put", "(", "\"void\"", ",", "TypeIds", ".", "T_void", ")", ";", "try", "{", "String", "value", "=", "System", ".", "getProperty", "(", "\"\"", ")", ";", "if", "(", "value", "!=", "null", ")", "{", "if", "(", "value", ".", "equalsIgnoreCase", "(", "\"true\"", ")", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", ")", ";", "earlyTransforms", "=", "true", ";", "}", "else", "if", "(", "value", ".", "equalsIgnoreCase", "(", "\"false\"", ")", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", ")", ";", "earlyTransforms", "=", "false", ";", "}", "}", "}", "catch", "(", "Throwable", "t", ")", "{", "}", "}", "private", "long", "[", "]", "positionsFor", "(", "char", "[", "]", "[", "]", "reference", ",", "long", "start", ",", "long", "end", ")", "{", "long", "[", "]", "result", "=", "new", "long", "[", "reference", ".", "length", "]", ";", "if", "(", "start", "<", "end", ")", "{", "long", "pos", "=", "start", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "result", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "long", "s", "=", "pos", ";", "pos", "=", "pos", "+", "reference", "[", "i", "]", ".", "length", "-", "1", ";", "result", "[", "i", "]", "=", "(", "(", "s", "<<", "32", ")", "|", "pos", ")", ";", "pos", "+=", "2", ";", "}", "}", "else", "{", "long", "pos", "=", "(", "start", "<<", "32", ")", "|", "start", ";", "for", "(", "int", "i", "=", "0", ",", "max", "=", "result", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "result", "[", "i", "]", "=", "pos", ";", "}", "}", "return", "result", ";", "}", "private", "TypeReference", "createTypeReferenceForArrayNameTrailingBrackets", "(", "ClassNode", "node", ",", "int", "start", ",", "int", "end", ")", "{", "String", "name", "=", "node", ".", "getName", "(", ")", ";", "int", "dim", "=", "0", ";", "int", "pos", "=", "name", ".", "length", "(", ")", "-", "2", ";", "ClassNode", "componentType", "=", "node", ";", "while", "(", "pos", ">", "0", "&&", "name", ".", "charAt", "(", "pos", ")", "==", "'['", ")", "{", "dim", "++", ";", "pos", "-=", "2", ";", "componentType", "=", "componentType", ".", "getComponentType", "(", ")", ";", "}", "if", "(", "componentType", ".", "isPrimitive", "(", ")", ")", "{", "Integer", "ii", "=", "charToTypeId", ".", "get", "(", "name", ".", "charAt", "(", "dim", ")", ")", ";", "if", "(", "ii", "==", "null", ")", "{", "throw", "new", "IllegalStateException", "(", "\"node", "\"", "+", "node", "+", "\"\"", ")", ";", "}", "else", "{", "TypeReference", "baseTypeReference", "=", "TypeReference", ".", "baseTypeReference", "(", "ii", ",", "dim", ")", ";", "baseTypeReference", ".", "sourceStart", "=", "start", ";", "baseTypeReference", ".", "sourceEnd", "=", "start", "+", "componentType", ".", "getName", "(", ")", ".", "length", "(", ")", ";", "return", "baseTypeReference", ";", "}", "}", "if", "(", "dim", "==", "0", ")", "{", "throw", "new", "IllegalStateException", "(", "\"\"", "+", "node", ".", "getName", "(", ")", ")", ";", "}", "String", "arrayComponentTypename", "=", "name", ".", "substring", "(", "0", ",", "pos", "+", "2", ")", ";", "if", "(", "arrayComponentTypename", ".", "indexOf", "(", "\".\"", ")", "==", "-", "1", ")", "{", "return", "createJDTArrayTypeReference", "(", "arrayComponentTypename", ",", "dim", ",", "start", ",", "end", ")", ";", "}", "else", "{", "return", "createJDTArrayQualifiedTypeReference", "(", "arrayComponentTypename", ",", "dim", ",", "start", ",", "end", ")", ";", "}", "}", "private", "TypeReference", "createTypeReferenceForArrayNameLeadingBrackets", "(", "ClassNode", "node", ",", "int", "start", ",", "int", "end", ")", "{", "String", "name", "=", "node", ".", "getName", "(", ")", ";", "int", "dim", "=", "0", ";", "ClassNode", "componentType", "=", "node", ";", "while", "(", "name", ".", "charAt", "(", "dim", ")", "==", "'['", ")", "{", "dim", "++", ";", "componentType", "=", "componentType", ".", "getComponentType", "(", ")", ";", "}", "if", "(", "componentType", ".", "isPrimitive", "(", ")", ")", "{", "Integer", "ii", "=", "charToTypeId", ".", "get", "(", "name", ".", "charAt", "(", "dim", ")", ")", ";", "if", "(", "ii", "==", "null", ")", "{", "throw", "new", "IllegalStateException", "(", "\"node", "\"", "+", "node", "+", "\"\"", ")", ";", "}", "else", "{", "TypeReference", "baseTypeReference", "=", "TypeReference", ".", "baseTypeReference", "(", "ii", ",", "dim", ")", ";", "baseTypeReference", ".", "sourceStart", "=", "start", ";", "baseTypeReference", ".", "sourceEnd", "=", "start", "+", "componentType", ".", "getName", "(", ")", ".", "length", "(", ")", ";", "return", "baseTypeReference", ";", "}", "}", "else", "{", "String", "arrayComponentTypename", "=", "name", ".", "substring", "(", "dim", ")", ";", "if", "(", "arrayComponentTypename", ".", "charAt", "(", "arrayComponentTypename", ".", "length", "(", ")", "-", "1", ")", "==", "';'", ")", "{", "arrayComponentTypename", "=", "name", ".", "substring", "(", "dim", "+", "1", ",", "name", ".", "length", "(", ")", "-", "1", ")", ";", "}", "if", "(", "arrayComponentTypename", ".", "indexOf", "(", "\".\"", ")", "==", "-", "1", ")", "{", "return", "createJDTArrayTypeReference", "(", "arrayComponentTypename", ",", "dim", ",", "start", ",", "end", ")", ";", "}", "else", "{", "return", "createJDTArrayQualifiedTypeReference", "(", "arrayComponentTypename", ",", "dim", ",", "start", ",", "end", ")", ";", "}", "}", "}", "private", "static", "long", "NON_EXISTENT_POSITION", "=", "toPos", "(", "-", "1", ",", "-", "2", ")", ";", "private", "static", "long", "toPos", "(", "long", "start", ",", "long", "end", ")", "{", "if", "(", "start", "==", "0", "&&", "end", "<=", "0", ")", "{", "return", "NON_EXISTENT_POSITION", ";", "}", "return", "(", "(", "start", "<<", "32", ")", "|", "end", ")", ";", "}", "private", "TypeReference", "createTypeReferenceForClassNode", "(", "GenericsType", "genericsType", ")", "{", "if", "(", "genericsType", ".", "isWildcard", "(", ")", ")", "{", "ClassNode", "[", "]", "bounds", "=", "genericsType", ".", "getUpperBounds", "(", ")", ";", "if", "(", "bounds", "!=", "null", ")", "{", "TypeReference", "boundReference", "=", "createTypeReferenceForClassNode", "(", "bounds", "[", "0", "]", ")", ";", "Wildcard", "wildcard", "=", "new", "Wildcard", "(", "Wildcard", ".", "EXTENDS", ")", ";", "wildcard", ".", "sourceStart", "=", "genericsType", ".", "getStart", "(", ")", ";", "wildcard", ".", "sourceEnd", "=", "boundReference", ".", "sourceEnd", "(", ")", ";", "wildcard", ".", "bound", "=", "boundReference", ";", "return", "wildcard", ";", "}", "else", "if", "(", "genericsType", ".", "getLowerBound", "(", ")", "!=", "null", ")", "{", "TypeReference", "boundReference", "=", "createTypeReferenceForClassNode", "(", "genericsType", ".", "getLowerBound", "(", ")", ")", ";", "Wildcard", "wildcard", "=", "new", "Wildcard", "(", "Wildcard", ".", "SUPER", ")", ";", "wildcard", ".", "sourceStart", "=", "genericsType", ".", "getStart", "(", ")", ";", "wildcard", ".", "sourceEnd", "=", "boundReference", ".", "sourceEnd", "(", ")", ";", "wildcard", ".", "bound", "=", "boundReference", ";", "return", "wildcard", ";", "}", "else", "{", "Wildcard", "w", "=", "new", "Wildcard", "(", "Wildcard", ".", "UNBOUND", ")", ";", "w", ".", "sourceStart", "=", "genericsType", ".", "getStart", "(", ")", ";", "w", ".", "sourceEnd", "=", "genericsType", ".", "getStart", "(", ")", ";", "return", "w", ";", "}", "}", "else", "if", "(", "!", "genericsType", ".", "getType", "(", ")", ".", "isGenericsPlaceHolder", "(", ")", ")", "{", "TypeReference", "typeReference", "=", "createTypeReferenceForClassNode", "(", "genericsType", ".", "getType", "(", ")", ")", ";", "return", "typeReference", ";", "}", "else", "{", "return", "null", ";", "}", "}", "private", "TypeReference", "[", "]", "createTypeReferencesForClassNodes", "(", "ClassNode", "[", "]", "classNodes", ")", "{", "if", "(", "classNodes", "==", "null", "||", "classNodes", ".", "length", "==", "0", ")", "{", "return", "null", ";", "}", "TypeReference", "[", "]", "refs", "=", "new", "TypeReference", "[", "classNodes", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "classNodes", ".", "length", ";", "i", "++", ")", "{", "refs", "[", "i", "]", "=", "createTypeReferenceForClassNode", "(", "classNodes", "[", "i", "]", ")", ";", "}", "return", "refs", ";", "}", "private", "TypeReference", "createTypeReferenceForClassNode", "(", "ClassNode", "classNode", ")", "{", "int", "start", "=", "startOffset", "(", "classNode", ")", ";", "int", "end", "=", "endOffset", "(", "classNode", ")", ";", "List", "<", "TypeReference", ">", "typeArguments", "=", "null", ";", "if", "(", "classNode", ".", "isUsingGenerics", "(", ")", ")", "{", "GenericsType", "[", "]", "genericsInfo", "=", "classNode", ".", "getGenericsTypes", "(", ")", ";", "if", "(", "genericsInfo", "!=", "null", ")", "{", "for", "(", "int", "g", "=", "0", ";", "g", "<", "genericsInfo", ".", "length", ";", "g", "++", ")", "{", "TypeReference", "tr", "=", "createTypeReferenceForClassNode", "(", "genericsInfo", "[", "g", "]", ")", ";", "if", "(", "tr", "!=", "null", ")", "{", "if", "(", "typeArguments", "==", "null", ")", "{", "typeArguments", "=", "new", "ArrayList", "<", "TypeReference", ">", "(", ")", ";", "}", "typeArguments", ".", "add", "(", "tr", ")", ";", "}", "}", "}", "}", "String", "name", "=", "classNode", ".", "getName", "(", ")", ";", "if", "(", "name", ".", "length", "(", ")", "==", "1", "&&", "name", ".", "charAt", "(", "0", ")", "==", "'?'", ")", "{", "return", "new", "Wildcard", "(", "Wildcard", ".", "UNBOUND", ")", ";", "}", "int", "arrayLoc", "=", "name", ".", "indexOf", "(", "\"[\"", ")", ";", "if", "(", "arrayLoc", "==", "0", ")", "{", "return", "createTypeReferenceForArrayNameLeadingBrackets", "(", "classNode", ",", "start", ",", "end", ")", ";", "}", "else", "if", "(", "arrayLoc", ">", "0", ")", "{", "return", "createTypeReferenceForArrayNameTrailingBrackets", "(", "classNode", ",", "start", ",", "end", ")", ";", "}", "if", "(", "nameToPrimitiveTypeId", ".", "containsKey", "(", "name", ")", ")", "{", "return", "TypeReference", ".", "baseTypeReference", "(", "nameToPrimitiveTypeId", ".", "get", "(", "name", ")", ",", "0", ")", ";", "}", "if", "(", "name", ".", "indexOf", "(", "\".\"", ")", "==", "-", "1", ")", "{", "if", "(", "typeArguments", "==", "null", ")", "{", "TypeReference", "tr", "=", "verify", "(", "new", "SingleTypeReference", "(", "name", ".", "toCharArray", "(", ")", ",", "toPos", "(", "start", ",", "end", "-", "1", ")", ")", ")", ";", "if", "(", "!", "checkGenerics", ")", "{", "tr", ".", "bits", "|=", "TypeReference", ".", "IgnoreRawTypeCheck", ";", "}", "return", "tr", ";", "}", "else", "{", "long", "l", "=", "toPos", "(", "start", ",", "end", "-", "1", ")", ";", "return", "new", "ParameterizedSingleTypeReference", "(", "name", ".", "toCharArray", "(", ")", ",", "typeArguments", ".", "toArray", "(", "new", "TypeReference", "[", "typeArguments", ".", "size", "(", ")", "]", ")", ",", "0", ",", "l", ")", ";", "}", "}", "else", "{", "char", "[", "]", "[", "]", "compoundName", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "name", ".", "toCharArray", "(", ")", ")", ";", "if", "(", "typeArguments", "==", "null", ")", "{", "TypeReference", "tr", "=", "new", "QualifiedTypeReference", "(", "compoundName", ",", "positionsFor", "(", "compoundName", ",", "start", ",", "end", ")", ")", ";", "if", "(", "!", "checkGenerics", ")", "{", "tr", ".", "bits", "|=", "TypeReference", ".", "IgnoreRawTypeCheck", ";", "}", "return", "tr", ";", "}", "else", "{", "TypeReference", "[", "]", "[", "]", "typeReferences", "=", "new", "TypeReference", "[", "compoundName", ".", "length", "]", "[", "]", ";", "typeReferences", "[", "compoundName", ".", "length", "-", "1", "]", "=", "typeArguments", ".", "toArray", "(", "new", "TypeReference", "[", "typeArguments", ".", "size", "(", ")", "]", ")", ";", "return", "new", "ParameterizedQualifiedTypeReference", "(", "compoundName", ",", "typeReferences", ",", "0", ",", "positionsFor", "(", "compoundName", ",", "start", ",", "end", ")", ")", ";", "}", "}", "}", "private", "final", "static", "boolean", "DEBUG", "=", "false", ";", "private", "long", "[", "]", "getPositionsFor", "(", "char", "[", "]", "[", "]", "compoundName", ")", "{", "long", "[", "]", "ls", "=", "new", "long", "[", "compoundName", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "compoundName", ".", "length", ";", "i", "++", ")", "{", "ls", "[", "i", "]", "=", "0", ";", "}", "return", "ls", ";", "}", "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "@", "Override", "public", "void", "generateCode", "(", ")", "{", "boolean", "successful", "=", "processToPhase", "(", "Phases", ".", "ALL", ")", ";", "if", "(", "successful", ")", "{", "List", "<", "GroovyClass", ">", "classes", "=", "groovyCompilationUnit", ".", "getClasses", "(", ")", ";", "if", "(", "DEBUG", ")", "{", "log", "(", "\"\"", "+", "groovySourceUnit", ".", "getName", "(", ")", ")", ";", "}", "for", "(", "GroovyClass", "clazz", ":", "classes", ")", "{", "ClassNode", "classnode", "=", "clazz", ".", "getClassNode", "(", ")", ";", "if", "(", "DEBUG", ")", "{", "log", "(", "\"\"", "+", "clazz", ".", "getName", "(", ")", ")", ";", "log", "(", "\"\"", "+", "classnode", ")", ";", "}", "if", "(", "clazz", ".", "getSourceUnit", "(", ")", "==", "groovySourceUnit", ")", "{", "if", "(", "DEBUG", ")", "{", "log", "(", "\"\"", ")", ";", "}", "String", "classname", "=", "clazz", ".", "getName", "(", ")", ";", "SourceTypeBinding", "binding", "=", "null", ";", "if", "(", "types", "!=", "null", "&&", "types", ".", "length", "!=", "0", ")", "{", "binding", "=", "findBinding", "(", "types", ",", "clazz", ".", "getClassNode", "(", ")", ")", ";", "}", "if", "(", "DEBUG", ")", "{", "log", "(", "\"\"", "+", "(", "binding", "!=", "null", ")", ")", ";", "}", "if", "(", "binding", "==", "null", ")", "{", "ClassNode", "current", "=", "classnode", ";", "while", "(", "current", "instanceof", "InnerClassNode", "&&", "binding", "==", "null", ")", "{", "current", "=", "(", "(", "InnerClassNode", ")", "current", ")", ".", "getOuterClass", "(", ")", ";", "binding", "=", "findBinding", "(", "types", ",", "current", ")", ";", "if", "(", "DEBUG", ")", "{", "log", "(", "\"\"", "+", "(", "binding", "!=", "null", ")", ")", ";", "}", "}", "}", "if", "(", "binding", "==", "null", ")", "{", "RuntimeException", "rEx", "=", "new", "RuntimeException", "(", "\"\"", "+", "classname", "+", "\"\"", ")", ";", "rEx", ".", "printStackTrace", "(", ")", ";", "Util", ".", "log", "(", "rEx", ",", "\"\"", "+", "classname", "+", "\"\"", ")", ";", "}", "else", "{", "boolean", "isScript", "=", "false", ";", "if", "(", "binding", ".", "scope", "!=", "null", "&&", "(", "binding", ".", "scope", ".", "parent", "instanceof", "GroovyCompilationUnitScope", ")", ")", "{", "GroovyCompilationUnitScope", "gcuScope", "=", "(", "GroovyCompilationUnitScope", ")", "binding", ".", "scope", ".", "parent", ";", "if", "(", "gcuScope", ".", "isScript", "(", ")", ")", "{", "isScript", "=", "true", ";", "}", "}", "if", "(", "!", "isScript", ")", "{", "byte", "[", "]", "classbytes", "=", "clazz", ".", "getBytes", "(", ")", ";", "String", "path", "=", "clazz", ".", "getName", "(", ")", ".", "replace", "(", "'.'", ",", "'/'", ")", ";", "compilationResult", ".", "record", "(", "classname", ".", "toCharArray", "(", ")", ",", "new", "GroovyClassFile", "(", "classname", ",", "classbytes", ",", "binding", ",", "path", ")", ")", ";", "}", "}", "}", "}", "}", "}", "private", "void", "log", "(", "String", "message", ")", "{", "System", ".", "out", ".", "println", "(", "message", ")", ";", "}", "private", "SourceTypeBinding", "findBinding", "(", "TypeDeclaration", "[", "]", "typedeclarations", ",", "ClassNode", "cnode", ")", "{", "for", "(", "TypeDeclaration", "typedeclaration", ":", "typedeclarations", ")", "{", "GroovyTypeDeclaration", "groovyTypeDeclaration", "=", "(", "GroovyTypeDeclaration", ")", "typedeclaration", ";", "if", "(", "groovyTypeDeclaration", ".", "getClassNode", "(", ")", ".", "equals", "(", "cnode", ")", ")", "{", "return", "groovyTypeDeclaration", ".", "binding", ";", "}", "if", "(", "typedeclaration", ".", "memberTypes", "!=", "null", ")", "{", "SourceTypeBinding", "binding", "=", "findBinding", "(", "typedeclaration", ".", "memberTypes", ",", "cnode", ")", ";", "if", "(", "binding", "!=", "null", ")", "{", "return", "binding", ";", "}", "}", "}", "return", "null", ";", "}", "private", "int", "startOffset", "(", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ASTNode", "astnode", ")", "{", "return", "(", "Math", ".", "max", "(", "astnode", ".", "getStart", "(", ")", ",", "0", ")", ")", ";", "}", "private", "int", "endOffset", "(", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ASTNode", "astnode", ")", "{", "return", "(", "Math", ".", "max", "(", "astnode", ".", "getEnd", "(", ")", ",", "0", ")", ")", ";", "}", "private", "void", "recordProblems", "(", "List", "<", "?", ">", "errors", ")", "{", "List", "errorsRecorded", "=", "new", "ArrayList", "(", ")", ";", "for", "(", "Iterator", "<", "?", ">", "iterator", "=", "errors", ".", "iterator", "(", ")", ";", "iterator", ".", "hasNext", "(", ")", ";", ")", "{", "SyntaxException", "syntaxException", "=", "null", ";", "Message", "message", "=", "(", "Message", ")", "iterator", ".", "next", "(", ")", ";", "StringWriter", "sw", "=", "new", "StringWriter", "(", ")", ";", "message", ".", "write", "(", "new", "PrintWriter", "(", "sw", ")", ")", ";", "String", "msg", "=", "sw", ".", "toString", "(", ")", ";", "CategorizedProblem", "p", "=", "null", ";", "int", "line", "=", "0", ";", "int", "sev", "=", "0", ";", "int", "scol", "=", "0", ";", "int", "ecol", "=", "0", ";", "if", "(", "message", "instanceof", "LocatedMessage", ")", "{", "CSTNode", "context", "=", "(", "(", "LocatedMessage", ")", "message", ")", ".", "getContext", "(", ")", ";", "if", "(", "context", "instanceof", "Token", ")", "{", "line", "=", "context", ".", "getStartLine", "(", ")", ";", "scol", "=", "context", ".", "getStartColumn", "(", ")", ";", "String", "text", "=", "(", "(", "Token", ")", "context", ")", ".", "getText", "(", ")", ";", "ecol", "=", "scol", "+", "(", "text", "==", "null", "?", "1", ":", "(", "text", ".", "length", "(", ")", "-", "1", ")", ")", ";", "}", "}", "if", "(", "message", "instanceof", "SimpleMessage", ")", "{", "SimpleMessage", "simpleMessage", "=", "(", "SimpleMessage", ")", "message", ";", "sev", "|=", "ProblemSeverities", ".", "Error", ";", "String", "simpleText", "=", "simpleMessage", ".", "getMessage", "(", ")", ";", "if", "(", "simpleText", ".", "length", "(", ")", ">", "1", "&&", "simpleText", ".", "charAt", "(", "0", ")", "==", "'\\n'", ")", "{", "simpleText", "=", "simpleText", ".", "substring", "(", "1", ")", ";", "}", "msg", "=", "\"Groovy:\"", "+", "simpleText", ";", "if", "(", "msg", ".", "indexOf", "(", "\"n\"", ")", "!=", "-", "1", ")", "{", "msg", "=", "msg", ".", "substring", "(", "0", ",", "msg", ".", "indexOf", "(", "\"n\"", ")", ")", ";", "}", "}", "if", "(", "message", "instanceof", "SyntaxErrorMessage", ")", "{", "SyntaxErrorMessage", "errorMessage", "=", "(", "SyntaxErrorMessage", ")", "message", ";", "syntaxException", "=", "errorMessage", ".", "getCause", "(", ")", ";", "sev", "|=", "ProblemSeverities", ".", "Error", ";", "String", "actualMessage", "=", "syntaxException", ".", "getMessage", "(", ")", ";", "if", "(", "actualMessage", ".", "length", "(", ")", ">", "1", "&&", "actualMessage", ".", "charAt", "(", "0", ")", "==", "'\\n'", ")", "{", "actualMessage", "=", "actualMessage", ".", "substring", "(", "1", ")", ";", "}", "msg", "=", "\"Groovy:\"", "+", "actualMessage", ";", "if", "(", "msg", ".", "indexOf", "(", "\"n\"", ")", "!=", "-", "1", ")", "{", "msg", "=", "msg", ".", "substring", "(", "0", ",", "msg", ".", "indexOf", "(", "\"n\"", ")", ")", ";", "}", "line", "=", "syntaxException", ".", "getLine", "(", ")", ";", "scol", "=", "errorMessage", ".", "getCause", "(", ")", ".", "getStartColumn", "(", ")", ";", "ecol", "=", "errorMessage", ".", "getCause", "(", ")", ".", "getEndColumn", "(", ")", "-", "1", ";", "}", "int", "soffset", "=", "-", "1", ";", "int", "eoffset", "=", "-", "1", ";", "if", "(", "message", "instanceof", "ExceptionMessage", ")", "{", "ExceptionMessage", "em", "=", "(", "ExceptionMessage", ")", "message", ";", "sev", "|=", "ProblemSeverities", ".", "Error", ";", "if", "(", "em", ".", "getCause", "(", ")", "instanceof", "RuntimeParserException", ")", "{", "RuntimeParserException", "rpe", "=", "(", "RuntimeParserException", ")", "em", ".", "getCause", "(", ")", ";", "sev", "|=", "ProblemSeverities", ".", "Error", ";", "msg", "=", "\"Groovy:\"", "+", "rpe", ".", "getMessage", "(", ")", ";", "if", "(", "msg", ".", "indexOf", "(", "\"n\"", ")", "!=", "-", "1", ")", "{", "msg", "=", "msg", ".", "substring", "(", "0", ",", "msg", ".", "indexOf", "(", "\"n\"", ")", ")", ";", "}", "ModuleNode", "errorModuleNode", "=", "rpe", ".", "getModule", "(", ")", ";", "ModuleNode", "thisModuleNode", "=", "this", ".", "getModuleNode", "(", ")", ";", "if", "(", "!", "errorModuleNode", ".", "equals", "(", "thisModuleNode", ")", ")", "{", "continue", ";", "}", "soffset", "=", "rpe", ".", "getNode", "(", ")", ".", "getStart", "(", ")", ";", "eoffset", "=", "rpe", ".", "getNode", "(", ")", ".", "getEnd", "(", ")", "-", "1", ";", "line", "=", "0", ";", "while", "(", "compilationResult", ".", "lineSeparatorPositions", "[", "line", "]", "<", "soffset", "&&", "line", "<", "compilationResult", ".", "lineSeparatorPositions", ".", "length", ")", "{", "line", "++", ";", "}", "line", "++", ";", "}", "}", "if", "(", "syntaxException", "instanceof", "PreciseSyntaxException", ")", "{", "soffset", "=", "(", "(", "PreciseSyntaxException", ")", "syntaxException", ")", ".", "getStartOffset", "(", ")", ";", "eoffset", "=", "(", "(", "PreciseSyntaxException", ")", "syntaxException", ")", ".", "getEndOffset", "(", ")", ";", "line", "=", "0", ";", "while", "(", "line", "<", "compilationResult", ".", "lineSeparatorPositions", ".", "length", "&&", "compilationResult", ".", "lineSeparatorPositions", "[", "line", "]", "<", "soffset", ")", "{", "line", "++", ";", "}", ";", "line", "++", ";", "}", "else", "{", "if", "(", "soffset", "==", "-", "1", ")", "{", "soffset", "=", "getOffset", "(", "compilationResult", ".", "lineSeparatorPositions", ",", "line", ",", "scol", ")", ";", "}", "if", "(", "eoffset", "==", "-", "1", ")", "{", "eoffset", "=", "getOffset", "(", "compilationResult", ".", "lineSeparatorPositions", ",", "line", ",", "ecol", ")", ";", "}", "}", "if", "(", "soffset", ">", "eoffset", ")", "{", "eoffset", "=", "soffset", ";", "}", "if", "(", "soffset", ">", "sourceEnd", ")", "{", "soffset", "=", "sourceEnd", ";", "eoffset", "=", "sourceEnd", ";", "}", "char", "[", "]", "filename", "=", "getFileName", "(", ")", ";", "p", "=", "new", "DefaultProblemFactory", "(", ")", ".", "createProblem", "(", "filename", ",", "0", ",", "new", "String", "[", "]", "{", "msg", "}", ",", "0", ",", "new", "String", "[", "]", "{", "msg", "}", ",", "sev", ",", "soffset", ",", "eoffset", ",", "line", ",", "scol", ")", ";", "this", ".", "problemReporter", ".", "record", "(", "p", ",", "compilationResult", ",", "this", ",", "false", ")", ";", "errorsRecorded", ".", "add", "(", "message", ")", ";", "System", ".", "err", ".", "println", "(", "new", "String", "(", "compilationResult", ".", "getFileName", "(", ")", ")", "+", "\":", "\"", "+", "line", "+", "\"", "\"", "+", "msg", ")", ";", "}", "errors", ".", "removeAll", "(", "errorsRecorded", ")", ";", "}", "private", "int", "getOffset", "(", "int", "[", "]", "lineSeparatorPositions", ",", "int", "line", ",", "int", "col", ")", "{", "if", "(", "lineSeparatorPositions", ".", "length", ">", "(", "line", "-", "2", ")", "&&", "line", ">", "1", ")", "{", "return", "lineSeparatorPositions", "[", "line", "-", "2", "]", "+", "col", ";", "}", "else", "{", "return", "col", ";", "}", "}", "@", "Override", "public", "CompilationUnitScope", "buildCompilationUnitScope", "(", "LookupEnvironment", "lookupEnvironment", ")", "{", "GroovyCompilationUnitScope", "gcus", "=", "new", "GroovyCompilationUnitScope", "(", "this", ",", "lookupEnvironment", ")", ";", "gcus", ".", "setIsScript", "(", "isScript", ")", ";", "return", "gcus", ";", "}", "public", "ModuleNode", "getModuleNode", "(", ")", "{", "return", "groovySourceUnit", "==", "null", "?", "null", ":", "groovySourceUnit", ".", "getAST", "(", ")", ";", "}", "public", "SourceUnit", "getSourceUnit", "(", ")", "{", "return", "groovySourceUnit", ";", "}", "@", "Override", "public", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "CompilationUnit", "getSpecialDomCompilationUnit", "(", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "AST", "ast", ")", "{", "return", "new", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "core", ".", "dom", ".", "GroovyCompilationUnit", "(", "ast", ")", ";", "}", "private", "void", "fixupSourceLocationsForTypeDeclaration", "(", "GroovyTypeDeclaration", "typeDeclaration", ",", "ClassNode", "classNode", ")", "{", "typeDeclaration", ".", "sourceStart", "=", "Math", ".", "max", "(", "classNode", ".", "getNameStart", "(", ")", ",", "classNode", ".", "getStart", "(", ")", ")", ";", "typeDeclaration", ".", "sourceEnd", "=", "Math", ".", "max", "(", "classNode", ".", "getNameEnd", "(", ")", ",", "classNode", ".", "getStart", "(", ")", ")", ";", "int", "line", "=", "classNode", ".", "getLineNumber", "(", ")", ";", "Javadoc", "doc", "=", "findJavadoc", "(", "line", ")", ";", "if", "(", "doc", "!=", "null", ")", "{", "if", "(", "imports", "!=", "null", "&&", "imports", ".", "length", ">", "0", ")", "{", "if", "(", "doc", ".", "sourceStart", "<", "imports", "[", "imports", ".", "length", "-", "1", "]", ".", "sourceStart", ")", "{", "doc", "=", "null", ";", "}", "}", "else", "if", "(", "currentPackage", "!=", "null", ")", "{", "if", "(", "doc", ".", "sourceStart", "<", "currentPackage", ".", "sourceStart", ")", "{", "doc", "=", "null", ";", "}", "}", "}", "typeDeclaration", ".", "javadoc", "=", "doc", ";", "typeDeclaration", ".", "declarationSourceStart", "=", "doc", "==", "null", "?", "classNode", ".", "getStart", "(", ")", ":", "doc", ".", "sourceStart", ";", "typeDeclaration", ".", "declarationSourceEnd", "=", "classNode", ".", "getEnd", "(", ")", "-", "1", ";", "typeDeclaration", ".", "bodyStart", "=", "Math", ".", "max", "(", "classNode", ".", "getNameEnd", "(", ")", ",", "classNode", ".", "getStart", "(", ")", ")", ";", "typeDeclaration", ".", "bodyEnd", "=", "classNode", ".", "getEnd", "(", ")", "-", "1", ";", "typeDeclaration", ".", "modifiersSourceStart", "=", "classNode", ".", "getStart", "(", ")", ";", "}", "private", "void", "fixupSourceLocationsForConstructorDeclaration", "(", "ConstructorDeclaration", "ctorDeclaration", ",", "ConstructorNode", "ctorNode", ")", "{", "ctorDeclaration", ".", "sourceStart", "=", "ctorNode", ".", "getNameStart", "(", ")", ";", "ctorDeclaration", ".", "sourceEnd", "=", "ctorNode", ".", "getNameEnd", "(", ")", ";", "int", "line", "=", "ctorNode", ".", "getLineNumber", "(", ")", ";", "Javadoc", "doc", "=", "findJavadoc", "(", "line", ")", ";", "ctorDeclaration", ".", "javadoc", "=", "doc", ";", "ctorDeclaration", ".", "declarationSourceStart", "=", "doc", "==", "null", "?", "ctorNode", ".", "getStart", "(", ")", ":", "doc", ".", "sourceStart", ";", "ctorDeclaration", ".", "declarationSourceEnd", "=", "ctorNode", ".", "getEnd", "(", ")", "-", "1", ";", "ctorDeclaration", ".", "modifiersSourceStart", "=", "ctorNode", ".", "getStart", "(", ")", ";", "ctorDeclaration", ".", "bodyStart", "=", "ctorNode", ".", "getCode", "(", ")", "!=", "null", "?", "ctorNode", ".", "getCode", "(", ")", ".", "getStart", "(", ")", ":", "ctorNode", ".", "getNameEnd", "(", ")", ";", "ctorDeclaration", ".", "bodyEnd", "=", "ctorNode", ".", "getEnd", "(", ")", "-", "1", ";", "}", "private", "void", "fixupSourceLocationsForMethodDeclaration", "(", "MethodDeclaration", "methodDeclaration", ",", "MethodNode", "methodNode", ")", "{", "methodDeclaration", ".", "sourceStart", "=", "Math", ".", "max", "(", "methodNode", ".", "getNameStart", "(", ")", ",", "methodNode", ".", "getStart", "(", ")", ")", ";", "methodDeclaration", ".", "sourceEnd", "=", "Math", ".", "max", "(", "methodNode", ".", "getNameEnd", "(", ")", ",", "methodNode", ".", "getStart", "(", ")", ")", ";", "int", "line", "=", "methodNode", ".", "getLineNumber", "(", ")", ";", "Javadoc", "doc", "=", "findJavadoc", "(", "line", ")", ";", "methodDeclaration", ".", "javadoc", "=", "doc", ";", "methodDeclaration", ".", "declarationSourceStart", "=", "doc", "==", "null", "?", "methodNode", ".", "getStart", "(", ")", ":", "doc", ".", "sourceStart", ";", "methodDeclaration", ".", "declarationSourceEnd", "=", "methodNode", ".", "getEnd", "(", ")", "-", "1", ";", "methodDeclaration", ".", "modifiersSourceStart", "=", "methodNode", ".", "getStart", "(", ")", ";", "methodDeclaration", ".", "bodyStart", "=", "methodNode", ".", "getCode", "(", ")", "!=", "null", "?", "methodNode", ".", "getCode", "(", ")", ".", "getStart", "(", ")", ":", "Math", ".", "max", "(", "methodNode", ".", "getNameEnd", "(", ")", ",", "methodNode", ".", "getStart", "(", ")", ")", ";", "methodDeclaration", ".", "bodyEnd", "=", "methodNode", ".", "getEnd", "(", ")", "-", "1", ";", "}", "private", "void", "fixupSourceLocationsForFieldDeclaration", "(", "FieldDeclaration", "fieldDeclaration", ",", "FieldNode", "fieldNode", ",", "boolean", "isEnumField", ")", "{", "fieldDeclaration", ".", "sourceStart", "=", "fieldNode", ".", "getNameStart", "(", ")", ";", "fieldDeclaration", ".", "sourceEnd", "=", "fieldNode", ".", "getNameEnd", "(", ")", ";", "int", "line", "=", "fieldNode", ".", "getLineNumber", "(", ")", ";", "Javadoc", "doc", "=", "findJavadoc", "(", "line", ")", ";", "fieldDeclaration", ".", "javadoc", "=", "doc", ";", "if", "(", "isEnumField", ")", "{", "fieldDeclaration", ".", "declarationSourceStart", "=", "doc", "==", "null", "?", "fieldNode", ".", "getNameStart", "(", ")", ":", "doc", ".", "sourceStart", ";", "fieldDeclaration", ".", "declarationSourceEnd", "=", "fieldNode", ".", "getNameEnd", "(", ")", "-", "1", ";", "}", "else", "{", "fieldDeclaration", ".", "declarationSourceStart", "=", "doc", "==", "null", "?", "fieldNode", ".", "getStart", "(", ")", ":", "doc", ".", "sourceStart", ";", "fieldDeclaration", ".", "declarationSourceEnd", "=", "fieldNode", ".", "getEnd", "(", ")", "-", "1", ";", "}", "fieldDeclaration", ".", "modifiersSourceStart", "=", "fieldNode", ".", "getStart", "(", ")", ";", "fieldDeclaration", ".", "declarationEnd", "=", "fieldNode", ".", "getEnd", "(", ")", ";", "fieldDeclaration", ".", "endPart1Position", "=", "fieldNode", ".", "getNameStart", "(", ")", ";", "fieldDeclaration", ".", "endPart2Position", "=", "fieldNode", ".", "getEnd", "(", ")", "-", "1", ";", "}", "private", "boolean", "isVargs", "(", "Parameter", "[", "]", "parameters", ")", "{", "if", "(", "parameters", ".", "length", "==", "0", ")", "{", "return", "false", ";", "}", "ClassNode", "clazz", "=", "parameters", "[", "parameters", ".", "length", "-", "1", "]", ".", "getType", "(", ")", ";", "return", "(", "clazz", ".", "isArray", "(", ")", ")", ";", "}", "public", "String", "print", "(", ")", "{", "return", "toString", "(", ")", ";", "}", "public", "GroovyCompilationUnitScope", "getScope", "(", ")", "{", "return", "(", "GroovyCompilationUnitScope", ")", "scope", ";", "}", "@", "Override", "public", "void", "resolve", "(", ")", "{", "processToPhase", "(", "Phases", ".", "SEMANTIC_ANALYSIS", ")", ";", "checkForTags", "(", ")", ";", "setComments", "(", ")", ";", "}", "private", "void", "checkForTags", "(", ")", "{", "if", "(", "this", ".", "compilerOptions", "==", "null", ")", "{", "return", ";", "}", "List", "<", "Comment", ">", "comments", "=", "groovySourceUnit", ".", "getComments", "(", ")", ";", "if", "(", "comments", "==", "null", ")", "{", "return", ";", "}", "char", "[", "]", "[", "]", "taskTags", "=", "this", ".", "compilerOptions", ".", "taskTags", ";", "char", "[", "]", "[", "]", "taskPriorities", "=", "this", ".", "compilerOptions", ".", "taskPriorities", ";", "boolean", "caseSensitiveTags", "=", "this", ".", "compilerOptions", ".", "isTaskCaseSensitive", ";", "try", "{", "if", "(", "taskTags", "!=", "null", ")", "{", "for", "(", "Comment", "comment", ":", "comments", ")", "{", "List", "<", "TaskEntry", ">", "allTasksInComment", "=", "new", "ArrayList", "<", "TaskEntry", ">", "(", ")", ";", "for", "(", "int", "t", "=", "0", ";", "t", "<", "taskTags", ".", "length", ";", "t", "++", ")", "{", "String", "taskTag", "=", "new", "String", "(", "taskTags", "[", "t", "]", ")", ";", "String", "taskPriority", "=", "null", ";", "if", "(", "taskPriorities", "!=", "null", ")", "{", "taskPriority", "=", "new", "String", "(", "taskPriorities", "[", "t", "]", ")", ";", "}", "allTasksInComment", ".", "addAll", "(", "comment", ".", "getPositionsOf", "(", "taskTag", ",", "taskPriority", ",", "compilationResult", ".", "lineSeparatorPositions", ",", "caseSensitiveTags", ")", ")", ";", "}", "if", "(", "!", "allTasksInComment", ".", "isEmpty", "(", ")", ")", "{", "for", "(", "int", "t1", "=", "0", ";", "t1", "<", "allTasksInComment", ".", "size", "(", ")", ";", "t1", "++", ")", "{", "for", "(", "int", "t2", "=", "0", ";", "t2", "<", "allTasksInComment", ".", "size", "(", ")", ";", "t2", "++", ")", "{", "if", "(", "t1", "==", "t2", ")", "continue", ";", "TaskEntry", "taskOne", "=", "allTasksInComment", ".", "get", "(", "t1", ")", ";", "TaskEntry", "taskTwo", "=", "allTasksInComment", ".", "get", "(", "t2", ")", ";", "if", "(", "DEBUG_TASK_TAGS", ")", "{", "System", ".", "out", ".", "println", "(", "\"Comparing", "\"", "+", "taskOne", ".", "toString", "(", ")", "+", "\"", "and", "\"", "+", "taskTwo", ".", "toString", "(", ")", ")", ";", "}", "if", "(", "(", "taskOne", ".", "start", "+", "taskOne", ".", "taskTag", ".", "length", "(", ")", "+", "1", ")", "==", "taskTwo", ".", "start", ")", "{", "taskOne", ".", "isAdjacentTo", "=", "taskTwo", ";", "}", "else", "{", "if", "(", "(", "taskOne", ".", "getEnd", "(", ")", ">", "taskTwo", ".", "start", ")", "&&", "(", "taskOne", ".", "start", "<", "taskTwo", ".", "start", ")", ")", "{", "taskOne", ".", "setEnd", "(", "taskTwo", ".", "start", "-", "1", ")", ";", "if", "(", "DEBUG_TASK_TAGS", ")", "{", "System", ".", "out", ".", "println", "(", "\"trim", "\"", "+", "taskOne", ".", "toString", "(", ")", "+", "\"", "and", "\"", "+", "taskTwo", ".", "toString", "(", ")", ")", ";", "}", "}", "else", "if", "(", "taskTwo", ".", "getEnd", "(", ")", ">", "taskOne", ".", "start", "&&", "taskTwo", ".", "start", "<", "taskOne", ".", "start", ")", "{", "taskTwo", ".", "setEnd", "(", "taskOne", ".", "start", "-", "1", ")", ";", "if", "(", "DEBUG_TASK_TAGS", ")", "{", "System", ".", "out", ".", "println", "(", "\"trim", "\"", "+", "taskOne", ".", "toString", "(", ")", "+", "\"", "and", "\"", "+", "taskTwo", ".", "toString", "(", ")", ")", ";", "}", "}", "}", "}", "}", "for", "(", "TaskEntry", "taskEntry", ":", "allTasksInComment", ")", "{", "this", ".", "problemReporter", ".", "referenceContext", "=", "this", ";", "if", "(", "DEBUG_TASK_TAGS", ")", "{", "System", ".", "out", ".", "println", "(", "\"Adding", "task", "\"", "+", "taskEntry", ".", "toString", "(", ")", ")", ";", "}", "problemReporter", ".", "task", "(", "taskEntry", ".", "taskTag", ",", "taskEntry", ".", "getText", "(", ")", ",", "taskEntry", ".", "taskPriority", ",", "taskEntry", ".", "start", ",", "taskEntry", ".", "getEnd", "(", ")", ")", ";", "}", "}", "}", "}", "}", "catch", "(", "AbortCompilation", "ac", ")", "{", "}", "catch", "(", "Throwable", "t", ")", "{", "Util", ".", "log", "(", "t", ",", "\"\"", "+", "groovySourceUnit", ".", "getName", "(", ")", ")", ";", "new", "RuntimeException", "(", "\"\"", "+", "groovySourceUnit", ".", "getName", "(", ")", ",", "t", ")", ".", "printStackTrace", "(", ")", ";", "}", "}", "@", "Override", "public", "void", "analyseCode", "(", ")", "{", "processToPhase", "(", "Phases", ".", "CANONICALIZATION", ")", ";", "}", "@", "Override", "public", "void", "abort", "(", "int", "abortLevel", ",", "CategorizedProblem", "problem", ")", "{", "super", ".", "abort", "(", "abortLevel", ",", "problem", ")", ";", "}", "@", "Override", "public", "void", "checkUnusedImports", "(", ")", "{", "super", ".", "checkUnusedImports", "(", ")", ";", "}", "@", "Override", "public", "void", "cleanUp", "(", ")", "{", "super", ".", "cleanUp", "(", ")", ";", "}", "@", "Override", "public", "CompilationResult", "compilationResult", "(", ")", "{", "return", "super", ".", "compilationResult", "(", ")", ";", "}", "@", "Override", "public", "TypeDeclaration", "declarationOfType", "(", "char", "[", "]", "[", "]", "typeName", ")", "{", "return", "super", ".", "declarationOfType", "(", "typeName", ")", ";", "}", "@", "Override", "public", "void", "finalizeProblems", "(", ")", "{", "super", ".", "finalizeProblems", "(", ")", ";", "}", "@", "Override", "public", "char", "[", "]", "getFileName", "(", ")", "{", "return", "super", ".", "getFileName", "(", ")", ";", "}", "@", "Override", "public", "char", "[", "]", "getMainTypeName", "(", ")", "{", "return", "super", ".", "getMainTypeName", "(", ")", ";", "}", "@", "Override", "public", "boolean", "hasErrors", "(", ")", "{", "return", "super", ".", "hasErrors", "(", ")", ";", "}", "@", "Override", "public", "boolean", "isEmpty", "(", ")", "{", "return", "super", ".", "isEmpty", "(", ")", ";", "}", "@", "Override", "public", "boolean", "isPackageInfo", "(", ")", "{", "return", "super", ".", "isPackageInfo", "(", ")", ";", "}", "@", "Override", "public", "StringBuffer", "print", "(", "int", "indent", ",", "StringBuffer", "output", ")", "{", "return", "super", ".", "print", "(", "indent", ",", "output", ")", ";", "}", "@", "Override", "public", "void", "propagateInnerEmulationForAllLocalTypes", "(", ")", "{", "super", ".", "propagateInnerEmulationForAllLocalTypes", "(", ")", ";", "}", "@", "Override", "public", "void", "record", "(", "LocalTypeBinding", "localType", ")", "{", "super", ".", "record", "(", "localType", ")", ";", "}", "@", "Override", "public", "void", "recordStringLiteral", "(", "StringLiteral", "literal", ",", "boolean", "fromRecovery", ")", "{", "super", ".", "recordStringLiteral", "(", "literal", ",", "fromRecovery", ")", ";", "}", "@", "Override", "public", "void", "recordSuppressWarnings", "(", "IrritantSet", "irritants", ",", "Annotation", "annotation", ",", "int", "scopeStart", ",", "int", "scopeEnd", ")", "{", "super", ".", "recordSuppressWarnings", "(", "irritants", ",", "annotation", ",", "scopeStart", ",", "scopeEnd", ")", ";", "}", "@", "Override", "public", "void", "tagAsHavingErrors", "(", ")", "{", "super", ".", "tagAsHavingErrors", "(", ")", ";", "}", "@", "Override", "public", "void", "traverse", "(", "ASTVisitor", "visitor", ",", "CompilationUnitScope", "unitScope", ")", "{", "super", ".", "traverse", "(", "visitor", ",", "unitScope", ")", ";", "}", "@", "Override", "public", "ASTNode", "concreteStatement", "(", ")", "{", "return", "super", ".", "concreteStatement", "(", ")", ";", "}", "@", "Override", "public", "boolean", "isImplicitThis", "(", ")", "{", "return", "super", ".", "isImplicitThis", "(", ")", ";", "}", "@", "Override", "public", "boolean", "isSuper", "(", ")", "{", "return", "super", ".", "isSuper", "(", ")", ";", "}", "@", "Override", "public", "boolean", "isThis", "(", ")", "{", "return", "super", ".", "isThis", "(", ")", ";", "}", "@", "Override", "public", "int", "sourceEnd", "(", ")", "{", "return", "super", ".", "sourceEnd", "(", ")", ";", "}", "@", "Override", "public", "int", "sourceStart", "(", ")", "{", "return", "super", ".", "sourceStart", "(", ")", ";", "}", "@", "Override", "public", "String", "toString", "(", ")", "{", "return", "super", ".", "toString", "(", ")", ";", "}", "@", "Override", "public", "void", "traverse", "(", "ASTVisitor", "visitor", ",", "BlockScope", "scope", ")", "{", "super", ".", "traverse", "(", "visitor", ",", "scope", ")", ";", "}", "private", "ArrayTypeReference", "createJDTArrayTypeReference", "(", "String", "arrayComponentTypename", ",", "int", "dimensions", ",", "int", "start", ",", "int", "end", ")", "{", "ArrayTypeReference", "atr", "=", "new", "ArrayTypeReference", "(", "arrayComponentTypename", ".", "toCharArray", "(", ")", ",", "dimensions", ",", "toPos", "(", "start", ",", "end", "-", "1", ")", ")", ";", "atr", ".", "originalSourceEnd", "=", "atr", ".", "sourceStart", "+", "arrayComponentTypename", ".", "length", "(", ")", "-", "1", ";", "return", "atr", ";", "}", "private", "ArrayQualifiedTypeReference", "createJDTArrayQualifiedTypeReference", "(", "String", "arrayComponentTypename", ",", "int", "dimensions", ",", "int", "start", ",", "int", "end", ")", "{", "char", "[", "]", "[", "]", "compoundName", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "arrayComponentTypename", ".", "toCharArray", "(", ")", ")", ";", "ArrayQualifiedTypeReference", "aqtr", "=", "new", "ArrayQualifiedTypeReference", "(", "compoundName", ",", "dimensions", ",", "positionsFor", "(", "compoundName", ",", "start", ",", "end", "-", "dimensions", "*", "2", ")", ")", ";", "aqtr", ".", "sourceEnd", "=", "end", "-", "1", ";", "return", "aqtr", ";", "}", "private", "TypeReference", "verify", "(", "TypeReference", "toVerify", ")", "{", "if", "(", "GroovyCheckingControl", ".", "checkTypeReferences", ")", "{", "if", "(", "toVerify", ".", "getClass", "(", ")", ".", "equals", "(", "SingleTypeReference", ".", "class", ")", ")", "{", "SingleTypeReference", "str", "=", "(", "SingleTypeReference", ")", "toVerify", ";", "if", "(", "str", ".", "sourceStart", "==", "-", "1", ")", "{", "if", "(", "str", ".", "sourceEnd", "!=", "-", "2", ")", "{", "throw", "new", "IllegalStateException", "(", "\"\"", "+", "new", "String", "(", "str", ".", "token", ")", "+", "\"\"", ")", ";", "}", "}", "else", "{", "if", "(", "str", ".", "sourceEnd", "<", "str", ".", "sourceStart", ")", "{", "throw", "new", "IllegalStateException", "(", "\"\"", "+", "new", "String", "(", "str", ".", "token", ")", "+", "\"\"", "+", "str", ".", "sourceStart", "+", "\"", "or", "later\"", ")", ";", "}", "}", "}", "else", "{", "throw", "new", "IllegalStateException", "(", "\"\"", "+", "toVerify", ".", "getClass", "(", ")", ")", ";", "}", "}", "return", "toVerify", ";", "}", "public", "void", "tagAsScript", "(", ")", "{", "this", ".", "isScript", "=", "true", ";", "}", "}", "</s>" ]
6,746
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "PropertyNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "Parser", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "GroovyTypeDeclaration", "extends", "TypeDeclaration", "{", "public", "List", "<", "PropertyNode", ">", "properties", ";", "private", "ClassNode", "classNode", ";", "public", "GroovyTypeDeclaration", "(", "CompilationResult", "compilationResult", ",", "ClassNode", "classNode", ")", "{", "super", "(", "compilationResult", ")", ";", "this", ".", "classNode", "=", "classNode", ";", "}", "public", "ClassNode", "getClassNode", "(", ")", "{", "return", "classNode", ";", "}", "@", "Override", "public", "void", "parseMethods", "(", "Parser", "parser", ",", "CompilationUnitDeclaration", "unit", ")", "{", "}", "@", "Override", "public", "boolean", "isScannerUsableOnThisDeclaration", "(", ")", "{", "return", "false", ";", "}", "}", "</s>" ]
6,747
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "public", "interface", "IGroovyDebugRequestor", "{", "void", "acceptCompilationUnitDeclaration", "(", "GroovyCompilationUnitDeclaration", "gcuDeclaration", ")", ";", "}", "</s>" ]
6,748
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CategorizedProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ClassFile", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AnnotationMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "MethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "SourceTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "SyntheticMethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "class", "GroovyClassFile", "extends", "ClassFile", "{", "private", "byte", "[", "]", "bytes", ";", "private", "char", "[", "]", "[", "]", "name", ";", "private", "char", "[", "]", "filename", ";", "public", "GroovyClassFile", "(", "String", "name", ",", "byte", "[", "]", "bs", ",", "SourceTypeBinding", "sourceTypeBinding", ",", "String", "filename", ")", "{", "this", ".", "name", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "name", ".", "toCharArray", "(", ")", ")", ";", "this", ".", "bytes", "=", "bs", ";", "this", ".", "referenceBinding", "=", "sourceTypeBinding", ";", "this", ".", "header", "=", "new", "byte", "[", "0", "]", ";", "this", ".", "headerOffset", "=", "0", ";", "this", ".", "contents", "=", "bs", ";", "this", ".", "contentsOffset", "=", "bs", ".", "length", ";", "this", ".", "filename", "=", "filename", ".", "toCharArray", "(", ")", ";", "}", "@", "Override", "public", "void", "addAbstractMethod", "(", "AbstractMethodDeclaration", "method", ",", "MethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addAttributes", "(", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addDefaultAbstractMethods", "(", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addFieldInfos", "(", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addProblemClinit", "(", "CategorizedProblem", "[", "]", "problems", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addProblemConstructor", "(", "AbstractMethodDeclaration", "method", ",", "MethodBinding", "methodBinding", ",", "CategorizedProblem", "[", "]", "problems", ",", "int", "savedOffset", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addProblemConstructor", "(", "AbstractMethodDeclaration", "method", ",", "MethodBinding", "methodBinding", ",", "CategorizedProblem", "[", "]", "problems", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addProblemMethod", "(", "AbstractMethodDeclaration", "method", ",", "MethodBinding", "methodBinding", ",", "CategorizedProblem", "[", "]", "problems", ",", "int", "savedOffset", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addProblemMethod", "(", "AbstractMethodDeclaration", "method", ",", "MethodBinding", "methodBinding", ",", "CategorizedProblem", "[", "]", "problems", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addSpecialMethods", "(", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addSyntheticConstructorAccessMethod", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addSyntheticEnumValueOfMethod", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addSyntheticEnumValuesMethod", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addSyntheticFieldReadAccessMethod", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addSyntheticFieldWriteAccessMethod", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addSyntheticMethodAccessMethod", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "addSyntheticSwitchTable", "(", "SyntheticMethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "completeCodeAttribute", "(", "int", "codeAttributeOffset", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "completeCodeAttributeForClinit", "(", "int", "codeAttributeOffset", ",", "int", "problemLine", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "completeCodeAttributeForClinit", "(", "int", "codeAttributeOffset", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "completeCodeAttributeForMissingAbstractProblemMethod", "(", "MethodBinding", "binding", ",", "int", "codeAttributeOffset", ",", "int", "[", "]", "startLineIndexes", ",", "int", "problemLine", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "completeCodeAttributeForProblemMethod", "(", "AbstractMethodDeclaration", "method", ",", "MethodBinding", "binding", ",", "int", "codeAttributeOffset", ",", "int", "[", "]", "startLineIndexes", ",", "int", "problemLine", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "completeCodeAttributeForSyntheticMethod", "(", "boolean", "hasExceptionHandlers", ",", "SyntheticMethodBinding", "binding", ",", "int", "codeAttributeOffset", ",", "int", "[", "]", "startLineIndexes", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "completeCodeAttributeForSyntheticMethod", "(", "SyntheticMethodBinding", "binding", ",", "int", "codeAttributeOffset", ",", "int", "[", "]", "startLineIndexes", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "public", "void", "completeMethodInfo", "(", "int", "methodAttributeOffset", ",", "int", "attributeNumber", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "public", "void", "completeMethodInfo", "(", "MethodBinding", "methodBinding", ",", "int", "methodAttributeOffset", ",", "int", "attributeNumber", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "char", "[", "]", "fileName", "(", ")", "{", "return", "filename", ";", "}", "@", "Override", "public", "void", "generateCodeAttributeHeader", "(", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "public", "int", "generateMethodInfoAttribute", "(", "MethodBinding", "methodBinding", ",", "AnnotationMethodDeclaration", "declaration", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "public", "int", "generateMethodInfoAttribute", "(", "MethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "public", "int", "generateMethodInfoAttributes", "(", "MethodBinding", "methodBinding", ",", "AnnotationMethodDeclaration", "declaration", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "public", "int", "generateMethodInfoAttributes", "(", "MethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "generateMethodInfoHeader", "(", "MethodBinding", "methodBinding", ",", "int", "accessFlags", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "generateMethodInfoHeader", "(", "MethodBinding", "methodBinding", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "generateMethodInfoHeaderForClinit", "(", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "generateMissingAbstractMethods", "(", "MethodDeclaration", "[", "]", "methodDeclarations", ",", "CompilationResult", "compilationResult", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "byte", "[", "]", "getBytes", "(", ")", "{", "return", "bytes", ";", "}", "@", "Override", "public", "char", "[", "]", "[", "]", "getCompoundName", "(", ")", "{", "return", "name", ";", "}", "@", "Override", "protected", "void", "initByteArrays", "(", ")", "{", "throw", "new", "UnsupportedOperationException", "(", ")", ";", "}", "@", "Override", "public", "void", "initialize", "(", "SourceTypeBinding", "type", ",", "ClassFile", "parentClassFile", ",", "boolean", "createProblemType", ")", "{", "throw", "new", "UnsupportedOperationException", "(", ")", ";", "}", "@", "Override", "public", "ClassFile", "outerMostEnclosingClassFile", "(", ")", "{", "throw", "new", "UnsupportedOperationException", "(", ")", ";", "}", "@", "Override", "public", "void", "recordInnerClasses", "(", "TypeBinding", "binding", ")", "{", "throw", "new", "UnsupportedOperationException", "(", ")", ";", "}", "@", "Override", "public", "void", "reset", "(", "SourceTypeBinding", "typeBinding", ")", "{", "throw", "new", "UnsupportedOperationException", "(", ")", ";", "}", "@", "Override", "public", "void", "setForMethodInfos", "(", ")", "{", "throw", "new", "UnsupportedOperationException", "(", ")", ";", "}", "@", "Override", "public", "void", "traverse", "(", "MethodBinding", "methodBinding", ",", "int", "maxLocals", ",", "byte", "[", "]", "bytecodes", ",", "int", "codeOffset", ",", "int", "codeLength", ",", "@", "SuppressWarnings", "(", "\"rawtypes\"", ")", "ArrayList", "frames", ",", "boolean", "isClinit", ")", "{", "throw", "new", "UnsupportedOperationException", "(", ")", ";", "}", "@", "Override", "public", "char", "[", "]", "utf8At", "(", "byte", "[", "]", "reference", ",", "int", "absoluteOffset", ",", "int", "bytesAvailable", ")", "{", "throw", "new", "UnsupportedOperationException", "(", ")", ";", "}", "}", "</s>" ]
6,749
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Binding", ";", "public", "interface", "JDTNode", "{", "int", "ANNOTATIONS_INITIALIZED", "=", "0x0001", ";", "int", "PROPERTIES_INITIALIZED", "=", "0x0002", ";", "JDTResolver", "getResolver", "(", ")", ";", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", ")", ";", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", "ClassNode", "type", ")", ";", "Binding", "getJdtBinding", "(", ")", ";", "boolean", "isDeprecated", "(", ")", ";", "}", "</s>" ]
6,750
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "lang", ".", "reflect", ".", "Modifier", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "PropertyNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "MetaClassHelper", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "IProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Argument", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ClassScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "CompilationUnitScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ExtraCompilerModifiers", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "FieldBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "LazilyResolvedMethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MissingTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ReferenceBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Scope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "SourceTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeConstants", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "GroovyClassScope", "extends", "ClassScope", "{", "public", "static", "EventListener", "debugListener", "=", "null", ";", "public", "GroovyClassScope", "(", "Scope", "parent", ",", "TypeDeclaration", "typeDecl", ")", "{", "super", "(", "parent", ",", "typeDecl", ")", ";", "}", "@", "Override", "protected", "boolean", "connectSuperInterfaces", "(", ")", "{", "boolean", "noProblems", "=", "super", ".", "connectSuperInterfaces", "(", ")", ";", "return", "noProblems", ";", "}", "char", "[", "]", "GROOVY", "=", "\"groovy\"", ".", "toCharArray", "(", ")", ";", "char", "[", "]", "[", "]", "GROOVY_LANG_METACLASS", "=", "{", "GROOVY", ",", "TypeConstants", ".", "LANG", ",", "\"MetaClass\"", ".", "toCharArray", "(", ")", "}", ";", "char", "[", "]", "[", "]", "GROOVY_LANG_GROOVYOBJECT", "=", "{", "GROOVY", ",", "TypeConstants", ".", "LANG", ",", "\"GroovyObject\"", ".", "toCharArray", "(", ")", "}", ";", "public", "final", "ReferenceBinding", "getGroovyLangMetaClassBinding", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "GROOVY_LANG_METACLASS", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "GROOVY_LANG_METACLASS", ",", "this", ")", ";", "}", "@", "Override", "protected", "MethodBinding", "[", "]", "augmentMethodBindings", "(", "MethodBinding", "[", "]", "methodBindings", ")", "{", "SourceTypeBinding", "binding", "=", "this", ".", "referenceContext", ".", "binding", ";", "if", "(", "binding", "!=", "null", "&&", "(", "binding", ".", "isAnnotationType", "(", ")", "||", "binding", ".", "isInterface", "(", ")", ")", ")", "{", "return", "methodBindings", ";", "}", "boolean", "implementsGroovyLangObject", "=", "false", ";", "ReferenceBinding", "[", "]", "superInterfaces", "=", "binding", ".", "superInterfaces", ";", "if", "(", "superInterfaces", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "max", "=", "superInterfaces", ".", "length", ";", "i", "<", "max", ";", "i", "++", ")", "{", "char", "[", "]", "[", "]", "interfaceName", "=", "superInterfaces", "[", "i", "]", ".", "compoundName", ";", "if", "(", "CharOperation", ".", "equals", "(", "interfaceName", ",", "GROOVY_LANG_GROOVYOBJECT", ")", ")", "{", "implementsGroovyLangObject", "=", "true", ";", "break", ";", "}", "}", "}", "List", "<", "MethodBinding", ">", "groovyMethods", "=", "new", "ArrayList", "<", "MethodBinding", ">", "(", ")", ";", "if", "(", "implementsGroovyLangObject", ")", "{", "if", "(", "debugListener", "!=", "null", ")", "{", "debugListener", ".", "record", "(", "\"\"", "+", "new", "String", "(", "this", ".", "referenceContext", ".", "name", ")", "+", "\"\"", ")", ";", "}", "TypeBinding", "bindingJLO", "=", "getJavaLangObject", "(", ")", ";", "TypeBinding", "bindingJLS", "=", "getJavaLangString", "(", ")", ";", "TypeBinding", "bindingGLM", "=", "getGroovyLangMetaClassBinding", "(", ")", ";", "createMethod", "(", "\"invokeMethod\"", ",", "false", ",", "\"\"", ",", "new", "TypeBinding", "[", "]", "{", "bindingJLS", ",", "bindingJLO", "}", ",", "bindingJLO", ",", "groovyMethods", ",", "methodBindings", ",", "null", ")", ";", "createMethod", "(", "\"getProperty\"", ",", "false", ",", "\"\"", ",", "new", "TypeBinding", "[", "]", "{", "bindingJLS", "}", ",", "bindingJLO", ",", "groovyMethods", ",", "methodBindings", ",", "null", ")", ";", "createMethod", "(", "\"setProperty\"", ",", "false", ",", "\"\"", ",", "new", "TypeBinding", "[", "]", "{", "bindingJLS", ",", "bindingJLO", "}", ",", "TypeBinding", ".", "VOID", ",", "groovyMethods", ",", "methodBindings", ",", "null", ")", ";", "createMethod", "(", "\"getMetaClass\"", ",", "false", ",", "\"\"", ",", "null", ",", "bindingGLM", ",", "groovyMethods", ",", "methodBindings", ",", "null", ")", ";", "createMethod", "(", "\"setMetaClass\"", ",", "false", ",", "\"\"", ",", "new", "TypeBinding", "[", "]", "{", "bindingGLM", "}", ",", "TypeBinding", ".", "VOID", ",", "groovyMethods", ",", "methodBindings", ",", "null", ")", ";", "}", "if", "(", "this", ".", "referenceContext", "instanceof", "GroovyTypeDeclaration", ")", "{", "GroovyTypeDeclaration", "typeDeclaration", "=", "(", "GroovyTypeDeclaration", ")", "this", ".", "referenceContext", ";", "boolean", "useOldWay", "=", "false", ";", "if", "(", "useOldWay", ")", "{", "List", "<", "PropertyNode", ">", "properties", "=", "typeDeclaration", ".", "properties", ";", "for", "(", "PropertyNode", "property", ":", "properties", ")", "{", "String", "name", "=", "property", ".", "getName", "(", ")", ";", "FieldBinding", "fBinding", "=", "typeDeclaration", ".", "binding", ".", "getField", "(", "name", ".", "toCharArray", "(", ")", ",", "false", ")", ";", "if", "(", "fBinding", "!=", "null", "&&", "!", "(", "fBinding", ".", "type", "instanceof", "MissingTypeBinding", ")", ")", "{", "String", "getterName", "=", "\"get\"", "+", "MetaClassHelper", ".", "capitalize", "(", "name", ")", ";", "createMethod", "(", "getterName", ",", "property", ".", "isStatic", "(", ")", ",", "\"\"", ",", "null", ",", "fBinding", ".", "type", ",", "groovyMethods", ",", "methodBindings", ",", "typeDeclaration", ")", ";", "if", "(", "!", "fBinding", ".", "isFinal", "(", ")", ")", "{", "String", "setterName", "=", "\"set\"", "+", "MetaClassHelper", ".", "capitalize", "(", "name", ")", ";", "createMethod", "(", "setterName", ",", "property", ".", "isStatic", "(", ")", ",", "\"\"", ",", "new", "TypeBinding", "[", "]", "{", "fBinding", ".", "type", "}", ",", "TypeBinding", ".", "VOID", ",", "groovyMethods", ",", "methodBindings", ",", "typeDeclaration", ")", ";", "}", "if", "(", "fBinding", ".", "type", "==", "TypeBinding", ".", "BOOLEAN", ")", "{", "createMethod", "(", "\"is\"", "+", "MetaClassHelper", ".", "capitalize", "(", "name", ")", ",", "property", ".", "isStatic", "(", ")", ",", "\"\"", ",", "null", ",", "fBinding", ".", "type", ",", "groovyMethods", ",", "methodBindings", ",", "typeDeclaration", ")", ";", "}", "}", "}", "}", "else", "{", "List", "<", "PropertyNode", ">", "properties", "=", "typeDeclaration", ".", "properties", ";", "for", "(", "PropertyNode", "property", ":", "properties", ")", "{", "String", "name", "=", "property", ".", "getName", "(", ")", ";", "String", "capitalizedName", "=", "MetaClassHelper", ".", "capitalize", "(", "name", ")", ";", "createGetterMethod", "(", "name", ",", "\"get\"", "+", "capitalizedName", ",", "property", ".", "isStatic", "(", ")", ",", "groovyMethods", ",", "methodBindings", ",", "typeDeclaration", ")", ";", "if", "(", "!", "Modifier", ".", "isFinal", "(", "property", ".", "getModifiers", "(", ")", ")", ")", "{", "createSetterMethod", "(", "name", ",", "\"set\"", "+", "capitalizedName", ",", "property", ".", "isStatic", "(", ")", ",", "groovyMethods", ",", "methodBindings", ",", "typeDeclaration", ",", "property", ".", "getType", "(", ")", ".", "getName", "(", ")", ")", ";", "}", "String", "propertyType", "=", "property", ".", "getType", "(", ")", ".", "getName", "(", ")", ";", "if", "(", "propertyType", ".", "equals", "(", "\"boolean\"", ")", ")", "{", "createGetterMethod", "(", "name", ",", "\"is\"", "+", "capitalizedName", ",", "property", ".", "isStatic", "(", ")", ",", "groovyMethods", ",", "methodBindings", ",", "typeDeclaration", ")", ";", "}", "}", "}", "}", "MethodBinding", "[", "]", "newMethodBindings", "=", "groovyMethods", ".", "toArray", "(", "new", "MethodBinding", "[", "methodBindings", ".", "length", "+", "groovyMethods", ".", "size", "(", ")", "]", ")", ";", "System", ".", "arraycopy", "(", "methodBindings", ",", "0", ",", "newMethodBindings", ",", "groovyMethods", ".", "size", "(", ")", ",", "methodBindings", ".", "length", ")", ";", "return", "newMethodBindings", ";", "}", "private", "void", "createMethod", "(", "String", "name", ",", "boolean", "isStatic", ",", "String", "signature", ",", "TypeBinding", "[", "]", "parameterTypes", ",", "TypeBinding", "returnType", ",", "List", "<", "MethodBinding", ">", "groovyMethods", ",", "MethodBinding", "[", "]", "existingMethods", ",", "GroovyTypeDeclaration", "typeDeclaration", ")", "{", "boolean", "found", "=", "false", ";", "for", "(", "MethodBinding", "existingMethod", ":", "existingMethods", ")", "{", "if", "(", "new", "String", "(", "existingMethod", ".", "selector", ")", ".", "equals", "(", "name", ")", ")", "{", "(", "(", "SourceTypeBinding", ")", "existingMethod", ".", "declaringClass", ")", ".", "resolveTypesFor", "(", "existingMethod", ")", ";", "boolean", "equalParameters", "=", "true", ";", "if", "(", "parameterTypes", "==", "null", ")", "{", "if", "(", "existingMethod", ".", "parameters", ".", "length", "!=", "0", ")", "{", "equalParameters", "=", "false", ";", "}", "}", "else", "if", "(", "existingMethod", ".", "parameters", ".", "length", "==", "parameterTypes", ".", "length", ")", "{", "TypeBinding", "[", "]", "existingParams", "=", "existingMethod", ".", "parameters", ";", "for", "(", "int", "p", "=", "0", ",", "max", "=", "parameterTypes", ".", "length", ";", "p", "<", "max", ";", "p", "++", ")", "{", "if", "(", "!", "CharOperation", ".", "equals", "(", "parameterTypes", "[", "p", "]", ".", "signature", "(", ")", ",", "existingParams", "[", "p", "]", ".", "signature", "(", ")", ")", ")", "{", "equalParameters", "=", "false", ";", "break", ";", "}", "}", "}", "if", "(", "equalParameters", ")", "{", "found", "=", "true", ";", "break", ";", "}", "}", "}", "if", "(", "!", "found", ")", "{", "int", "modifiers", "=", "ClassFileConstants", ".", "AccPublic", ";", "if", "(", "isStatic", ")", "{", "modifiers", "|=", "ClassFileConstants", ".", "AccStatic", ";", "}", "if", "(", "this", ".", "referenceContext", ".", "binding", ".", "isInterface", "(", ")", ")", "{", "modifiers", "|=", "ClassFileConstants", ".", "AccAbstract", ";", "}", "char", "[", "]", "methodName", "=", "name", ".", "toCharArray", "(", ")", ";", "MethodBinding", "mb", "=", "new", "MethodBinding", "(", "modifiers", ",", "methodName", ",", "returnType", ",", "parameterTypes", ",", "null", ",", "this", ".", "referenceContext", ".", "binding", ")", ";", "groovyMethods", ".", "add", "(", "mb", ")", ";", "}", "}", "private", "void", "createGetterMethod", "(", "String", "propertyName", ",", "String", "name", ",", "boolean", "isStatic", ",", "List", "<", "MethodBinding", ">", "groovyMethods", ",", "MethodBinding", "[", "]", "existingMethods", ",", "GroovyTypeDeclaration", "typeDeclaration", ")", "{", "boolean", "found", "=", "false", ";", "char", "[", "]", "nameAsCharArray", "=", "name", ".", "toCharArray", "(", ")", ";", "for", "(", "MethodBinding", "existingMethod", ":", "existingMethods", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "nameAsCharArray", ",", "existingMethod", ".", "selector", ")", ")", "{", "if", "(", "(", "existingMethod", ".", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccUnresolved", ")", "!=", "0", ")", "{", "AbstractMethodDeclaration", "methodDecl", "=", "existingMethod", ".", "sourceMethod", "(", ")", ";", "if", "(", "methodDecl", "==", "null", ")", "{", "}", "else", "{", "Argument", "[", "]", "arguments", "=", "methodDecl", ".", "arguments", ";", "if", "(", "arguments", "==", "null", "||", "arguments", ".", "length", "==", "0", ")", "{", "found", "=", "true", ";", "}", "}", "}", "else", "{", "TypeBinding", "[", "]", "existingParams", "=", "existingMethod", ".", "parameters", ";", "if", "(", "existingParams", "==", "null", "||", "existingParams", ".", "length", "==", "0", ")", "{", "found", "=", "true", ";", "}", "}", "}", "}", "if", "(", "!", "found", ")", "{", "int", "modifiers", "=", "ClassFileConstants", ".", "AccPublic", ";", "if", "(", "isStatic", ")", "{", "modifiers", "|=", "ClassFileConstants", ".", "AccStatic", ";", "}", "if", "(", "this", ".", "referenceContext", ".", "binding", ".", "isInterface", "(", ")", ")", "{", "modifiers", "|=", "ClassFileConstants", ".", "AccAbstract", ";", "}", "MethodBinding", "mb", "=", "new", "LazilyResolvedMethodBinding", "(", "true", ",", "propertyName", ",", "modifiers", ",", "nameAsCharArray", ",", "null", ",", "this", ".", "referenceContext", ".", "binding", ")", ";", "groovyMethods", ".", "add", "(", "mb", ")", ";", "}", "}", "private", "void", "createSetterMethod", "(", "String", "propertyName", ",", "String", "name", ",", "boolean", "isStatic", ",", "List", "<", "MethodBinding", ">", "groovyMethods", ",", "MethodBinding", "[", "]", "existingMethods", ",", "GroovyTypeDeclaration", "typeDeclaration", ",", "String", "propertyType", ")", "{", "boolean", "found", "=", "false", ";", "char", "[", "]", "nameAsCharArray", "=", "name", ".", "toCharArray", "(", ")", ";", "for", "(", "MethodBinding", "existingMethod", ":", "existingMethods", ")", "{", "if", "(", "CharOperation", ".", "equals", "(", "nameAsCharArray", ",", "existingMethod", ".", "selector", ")", ")", "{", "if", "(", "(", "existingMethod", ".", "modifiers", "&", "ExtraCompilerModifiers", ".", "AccUnresolved", ")", "!=", "0", ")", "{", "AbstractMethodDeclaration", "methodDecl", "=", "existingMethod", ".", "sourceMethod", "(", ")", ";", "if", "(", "methodDecl", "==", "null", ")", "{", "}", "else", "{", "Argument", "[", "]", "arguments", "=", "methodDecl", ".", "arguments", ";", "if", "(", "arguments", "!=", "null", "&&", "arguments", ".", "length", "==", "1", ")", "{", "found", "=", "true", ";", "}", "}", "}", "else", "{", "TypeBinding", "[", "]", "existingParams", "=", "existingMethod", ".", "parameters", ";", "if", "(", "existingParams", "!=", "null", "&&", "existingParams", ".", "length", "==", "1", ")", "{", "found", "=", "true", ";", "}", "}", "}", "}", "if", "(", "!", "found", ")", "{", "int", "modifiers", "=", "ClassFileConstants", ".", "AccPublic", ";", "if", "(", "isStatic", ")", "{", "modifiers", "|=", "ClassFileConstants", ".", "AccStatic", ";", "}", "if", "(", "this", ".", "referenceContext", ".", "binding", ".", "isInterface", "(", ")", ")", "{", "modifiers", "|=", "ClassFileConstants", ".", "AccAbstract", ";", "}", "char", "[", "]", "methodName", "=", "name", ".", "toCharArray", "(", ")", ";", "MethodBinding", "mb", "=", "new", "LazilyResolvedMethodBinding", "(", "false", ",", "propertyName", ",", "modifiers", ",", "methodName", ",", "null", ",", "this", ".", "referenceContext", ".", "binding", ")", ";", "groovyMethods", ".", "add", "(", "mb", ")", ";", "}", "}", "@", "Override", "public", "boolean", "shouldReport", "(", "int", "problem", ")", "{", "if", "(", "problem", "==", "IProblem", ".", "SuperclassMustBeAClass", ")", "{", "return", "false", ";", "}", "if", "(", "problem", "==", "IProblem", ".", "IncompatibleReturnType", ")", "{", "return", "false", ";", "}", "if", "(", "problem", "==", "IProblem", ".", "AbstractMethodMustBeImplemented", ")", "{", "return", "false", ";", "}", "if", "(", "problem", "==", "IProblem", ".", "MethodNameClash", ")", "{", "return", "false", ";", "}", "if", "(", "problem", "==", "IProblem", ".", "VarargsConflict", ")", "{", "return", "false", ";", "}", "return", "true", ";", "}", "@", "Override", "public", "MethodBinding", "[", "]", "getAnyExtraMethods", "(", "char", "[", "]", "selector", ")", "{", "if", "(", "true", ")", "{", "return", "null", ";", "}", "List", "<", "MethodNode", ">", "mns", "=", "(", "(", "GroovyTypeDeclaration", ")", "referenceContext", ")", ".", "getClassNode", "(", ")", ".", "getMethods", "(", "new", "String", "(", "selector", ")", ")", ";", "MethodBinding", "[", "]", "newMethods", "=", "new", "MethodBinding", "[", "mns", ".", "size", "(", ")", "]", ";", "int", "idx", "=", "0", ";", "for", "(", "MethodNode", "methodNode", ":", "mns", ")", "{", "TypeBinding", "[", "]", "parameterTypes", "=", "null", ";", "TypeBinding", "returnType", "=", "compilationUnitScope", "(", ")", ".", "environment", ".", "getResolvedType", "(", "CharOperation", ".", "splitAndTrimOn", "(", "'.'", ",", "methodNode", ".", "getReturnType", "(", ")", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ")", ",", "this", ")", ";", "newMethods", "[", "idx", "++", "]", "=", "new", "MethodBinding", "(", "methodNode", ".", "getModifiers", "(", ")", ",", "selector", ",", "returnType", ",", "parameterTypes", ",", "null", ",", "this", ".", "referenceContext", ".", "binding", ")", ";", "}", "return", "newMethods", ";", "}", "@", "Override", "protected", "ClassScope", "buildClassScope", "(", "Scope", "parent", ",", "TypeDeclaration", "typeDecl", ")", "{", "return", "new", "GroovyClassScope", "(", "parent", ",", "typeDecl", ")", ";", "}", "}", "</s>" ]
6,751
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "AliasImportReference", "extends", "ImportReference", "{", "private", "char", "[", "]", "alias", ";", "public", "AliasImportReference", "(", "char", "[", "]", "alias", ",", "char", "[", "]", "[", "]", "tokens", ",", "long", "[", "]", "sourcePositions", ",", "boolean", "onDemand", ",", "int", "modifiers", ")", "{", "super", "(", "tokens", ",", "sourcePositions", ",", "onDemand", ",", "modifiers", ")", ";", "this", ".", "alias", "=", "alias", ";", "}", "@", "Override", "public", "char", "[", "]", "getSimpleName", "(", ")", "{", "return", "alias", ";", "}", "}", "</s>" ]
6,752
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "lang", ".", "reflect", ".", "Modifier", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Set", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "GroovyBugError", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ConstructorNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GenericsType", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Parameter", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "PropertyNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstantExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "Statement", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyCompilationUnitDeclaration", ".", "FieldDeclarationWithInitializer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "FieldDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Wildcard", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "classfmt", ".", "ClassFileConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "BooleanConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "ByteConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CharConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "Constant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "DoubleConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "FloatConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "IntConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "LongConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "ShortConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "StringConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "AnnotationBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ArrayBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "BinaryTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ClassScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "CompilationUnitScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "FieldBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "LookupEnvironment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MemberTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MethodVerifier", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ParameterizedTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ReferenceBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "SourceTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "SyntheticMethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeVariableBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "WildcardBinding", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "JDTClassNode", "extends", "ClassNode", "implements", "JDTNode", "{", "private", "static", "final", "Parameter", "[", "]", "NO_PARAMETERS", "=", "new", "Parameter", "[", "0", "]", ";", "private", "final", "static", "String", "[", "]", "argNames", "=", "new", "String", "[", "]", "{", "\"arg0\"", ",", "\"arg1\"", ",", "\"arg2\"", ",", "\"arg3\"", ",", "\"arg4\"", ",", "\"arg5\"", ",", "\"arg6\"", ",", "\"arg7\"", "}", ";", "ReferenceBinding", "jdtBinding", ";", "private", "boolean", "beingInitialized", "=", "false", ";", "JDTResolver", "resolver", ";", "private", "int", "bits", "=", "0", ";", "private", "static", "final", "int", "ANNOTATIONS_INITIALIZED", "=", "0x0001", ";", "private", "static", "final", "int", "PROPERTIES_INITIALIZED", "=", "0x0002", ";", "private", "TypeDeclaration", "groovyDecl", "=", "null", ";", "static", "final", "ClassNode", "unboundWildcard", ";", "static", "final", "GenericsType", "genericsTypeUnboundWildcard", ";", "static", "{", "ClassNode", "base", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "\"?\"", ")", ";", "base", ".", "setRedirect", "(", "ClassHelper", ".", "OBJECT_TYPE", ")", ";", "GenericsType", "t", "=", "new", "GenericsType", "(", "base", ",", "null", ",", "null", ")", ";", "t", ".", "setName", "(", "\"?\"", ")", ";", "t", ".", "setWildcard", "(", "true", ")", ";", "unboundWildcard", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "\"?\"", ")", ";", "unboundWildcard", ".", "setRedirect", "(", "ClassHelper", ".", "OBJECT_TYPE", ")", ";", "genericsTypeUnboundWildcard", "=", "t", ";", "}", "@", "Override", "public", "boolean", "mightHaveInners", "(", ")", "{", "return", "jdtBinding", ".", "memberTypes", "(", ")", ".", "length", "!=", "0", ";", "}", "public", "JDTClassNode", "(", "ReferenceBinding", "jdtReferenceBinding", ",", "JDTResolver", "resolver", ")", "{", "super", "(", "getName", "(", "jdtReferenceBinding", ")", ",", "getMods", "(", "jdtReferenceBinding", ")", ",", "null", ")", ";", "this", ".", "jdtBinding", "=", "jdtReferenceBinding", ";", "this", ".", "resolver", "=", "resolver", ";", "this", ".", "lazyInitDone", "=", "false", ";", "this", ".", "isPrimaryNode", "=", "false", ";", "}", "private", "static", "String", "getName", "(", "TypeBinding", "tb", ")", "{", "if", "(", "tb", "instanceof", "ArrayBinding", ")", "{", "return", "new", "String", "(", "(", "(", "ArrayBinding", ")", "tb", ")", ".", "signature", "(", ")", ")", ";", "}", "else", "if", "(", "tb", "instanceof", "MemberTypeBinding", ")", "{", "MemberTypeBinding", "mtb", "=", "(", "MemberTypeBinding", ")", "tb", ";", "return", "CharOperation", ".", "toString", "(", "mtb", ".", "compoundName", ")", ";", "}", "else", "if", "(", "tb", "instanceof", "ReferenceBinding", ")", "{", "return", "CharOperation", ".", "toString", "(", "(", "(", "ReferenceBinding", ")", "tb", ")", ".", "compoundName", ")", ";", "}", "else", "{", "return", "new", "String", "(", "tb", ".", "sourceName", "(", ")", ")", ";", "}", "}", "private", "static", "int", "getMods", "(", "TypeBinding", "tb", ")", "{", "if", "(", "tb", "instanceof", "ReferenceBinding", ")", "{", "return", "(", "(", "ReferenceBinding", ")", "tb", ")", ".", "modifiers", ";", "}", "else", "{", "return", "ClassFileConstants", ".", "AccPublic", ";", "}", "}", "@", "Override", "public", "void", "lazyClassInit", "(", ")", "{", "synchronized", "(", "lazyInitLock", ")", "{", "if", "(", "lazyInitDone", ")", "{", "return", ";", "}", "initialize", "(", ")", ";", "lazyInitDone", "=", "true", ";", "}", "}", "public", "void", "setupGenerics", "(", ")", "{", "if", "(", "jdtBinding", "instanceof", "ParameterizedTypeBinding", ")", "{", "ParameterizedTypeBinding", "ptb", "=", "(", "ParameterizedTypeBinding", ")", "jdtBinding", ";", "TypeBinding", "[", "]", "parameterizationArguments", "=", "ptb", ".", "arguments", ";", "if", "(", "parameterizationArguments", "!=", "null", "&&", "parameterizationArguments", ".", "length", ">", "0", ")", "{", "GenericsType", "[", "]", "generics", "=", "new", "GenericsType", "[", "parameterizationArguments", ".", "length", "]", ";", "for", "(", "int", "g", "=", "0", ";", "g", "<", "parameterizationArguments", ".", "length", ";", "g", "++", ")", "{", "TypeBinding", "typeBinding", "=", "parameterizationArguments", "[", "g", "]", ";", "if", "(", "typeBinding", "instanceof", "TypeVariableBinding", ")", "{", "generics", "[", "g", "]", "=", "createGenericsTypeInfoForTypeVariableBinding", "(", "(", "TypeVariableBinding", ")", "parameterizationArguments", "[", "g", "]", ")", ";", "}", "else", "{", "if", "(", "typeBinding", "instanceof", "WildcardBinding", "&&", "(", "(", "WildcardBinding", ")", "typeBinding", ")", ".", "boundKind", "==", "Wildcard", ".", "UNBOUND", ")", "{", "generics", "[", "g", "]", "=", "genericsTypeUnboundWildcard", ";", "}", "else", "{", "generics", "[", "g", "]", "=", "new", "GenericsType", "(", "resolver", ".", "convertToClassNode", "(", "typeBinding", ")", ")", ";", "}", "}", "}", "this", ".", "setGenericsTypes", "(", "generics", ")", ";", "}", "this", ".", "setRedirect", "(", "resolver", ".", "convertToClassNode", "(", "ptb", ".", "original", "(", ")", ")", ")", ";", "}", "else", "{", "TypeVariableBinding", "[", "]", "typeVariables", "=", "jdtBinding", ".", "typeVariables", "(", ")", ";", "GenericsType", "[", "]", "generics", "=", "createGenericsTypeInfoForTypeVariableBindings", "(", "typeVariables", ")", ";", "if", "(", "generics", "!=", "null", ")", "{", "this", ".", "setGenericsTypes", "(", "generics", ")", ";", "}", "}", "}", "@", "Override", "public", "boolean", "isResolved", "(", ")", "{", "return", "true", ";", "}", "void", "initialize", "(", ")", "{", "try", "{", "if", "(", "beingInitialized", ")", "{", "return", ";", "}", "beingInitialized", "=", "true", ";", "if", "(", "jdtBinding", "instanceof", "ParameterizedTypeBinding", ")", "{", "ClassNode", "rd", "=", "redirect", "(", ")", ";", "rd", ".", "lazyClassInit", "(", ")", ";", "return", ";", "}", "resolver", ".", "pushTypeGenerics", "(", "getGenericsTypes", "(", ")", ")", ";", "if", "(", "!", "jdtBinding", ".", "isInterface", "(", ")", ")", "{", "ReferenceBinding", "superClass", "=", "jdtBinding", ".", "superclass", "(", ")", ";", "if", "(", "superClass", "!=", "null", ")", "{", "setUnresolvedSuperClass", "(", "resolver", ".", "convertToClassNode", "(", "superClass", ")", ")", ";", "}", "}", "ReferenceBinding", "[", "]", "superInterfaceBindings", "=", "jdtBinding", ".", "superInterfaces", "(", ")", ";", "superInterfaceBindings", "=", "superInterfaceBindings", "==", "null", "?", "ReferenceBinding", ".", "NO_SUPERINTERFACES", ":", "superInterfaceBindings", ";", "ClassNode", "[", "]", "interfaces", "=", "new", "ClassNode", "[", "superInterfaceBindings", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "superInterfaceBindings", ".", "length", ";", "i", "++", ")", "{", "interfaces", "[", "i", "]", "=", "resolver", ".", "convertToClassNode", "(", "superInterfaceBindings", "[", "i", "]", ")", ";", "}", "setInterfaces", "(", "interfaces", ")", ";", "initializeMembers", "(", ")", ";", "resolver", ".", "popTypeGenerics", "(", ")", ";", "}", "finally", "{", "beingInitialized", "=", "false", ";", "}", "}", "private", "void", "initializeMembers", "(", ")", "{", "if", "(", "jdtBinding", "instanceof", "SourceTypeBinding", ")", "{", "SourceTypeBinding", "sourceType", "=", "(", "SourceTypeBinding", ")", "jdtBinding", ";", "if", "(", "sourceType", ".", "scope", "!=", "null", ")", "{", "TypeDeclaration", "typeDecl", "=", "sourceType", ".", "scope", ".", "referenceContext", ";", "if", "(", "typeDecl", "instanceof", "GroovyTypeDeclaration", ")", "{", "groovyDecl", "=", "typeDecl", ";", "}", "}", "}", "MethodBinding", "[", "]", "bindings", "=", "null", ";", "if", "(", "jdtBinding", "instanceof", "ParameterizedTypeBinding", ")", "{", "ReferenceBinding", "genericType", "=", "(", "(", "ParameterizedTypeBinding", ")", "jdtBinding", ")", ".", "genericType", "(", ")", ";", "bindings", "=", "genericType", ".", "methods", "(", ")", ";", "}", "else", "{", "bindings", "=", "jdtBinding", ".", "methods", "(", ")", ";", "}", "if", "(", "bindings", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "bindings", ".", "length", ";", "i", "++", ")", "{", "if", "(", "bindings", "[", "i", "]", ".", "isConstructor", "(", ")", ")", "{", "ConstructorNode", "cNode", "=", "constructorBindingToConstructorNode", "(", "bindings", "[", "i", "]", ")", ";", "addConstructor", "(", "cNode", ")", ";", "}", "else", "{", "MethodNode", "mNode", "=", "methodBindingToMethodNode", "(", "bindings", "[", "i", "]", ")", ";", "addMethod", "(", "mNode", ")", ";", "}", "}", "}", "if", "(", "jdtBinding", "instanceof", "BinaryTypeBinding", ")", "{", "MethodBinding", "[", "]", "infraBindings", "=", "(", "(", "BinaryTypeBinding", ")", "jdtBinding", ")", ".", "infraMethods", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "infraBindings", ".", "length", ";", "i", "++", ")", "{", "if", "(", "infraBindings", "[", "i", "]", ".", "isConstructor", "(", ")", ")", "{", "ConstructorNode", "cNode", "=", "constructorBindingToConstructorNode", "(", "infraBindings", "[", "i", "]", ")", ";", "addConstructor", "(", "cNode", ")", ";", "}", "else", "{", "MethodNode", "mNode", "=", "methodBindingToMethodNode", "(", "infraBindings", "[", "i", "]", ")", ";", "addMethod", "(", "mNode", ")", ";", "}", "}", "}", "if", "(", "jdtBinding", "instanceof", "SourceTypeBinding", ")", "{", "SourceTypeBinding", "jdtSourceTypeBinding", "=", "(", "SourceTypeBinding", ")", "jdtBinding", ";", "ClassScope", "classScope", "=", "jdtSourceTypeBinding", ".", "scope", ";", "if", "(", "classScope", "!=", "null", ")", "{", "CompilationUnitScope", "cuScope", "=", "classScope", ".", "compilationUnitScope", "(", ")", ";", "LookupEnvironment", "environment", "=", "classScope", ".", "environment", "(", ")", ";", "MethodVerifier", "verifier", "=", "environment", ".", "methodVerifier", "(", ")", ";", "cuScope", ".", "verifyMethods", "(", "verifier", ")", ";", "}", "SyntheticMethodBinding", "[", "]", "syntheticMethodBindings", "=", "(", "(", "SourceTypeBinding", ")", "jdtBinding", ")", ".", "syntheticMethods", "(", ")", ";", "if", "(", "syntheticMethodBindings", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "syntheticMethodBindings", ".", "length", ";", "i", "++", ")", "{", "if", "(", "syntheticMethodBindings", "[", "i", "]", ".", "isConstructor", "(", ")", ")", "{", "ConstructorNode", "cNode", "=", "constructorBindingToConstructorNode", "(", "bindings", "[", "i", "]", ")", ";", "addConstructor", "(", "cNode", ")", ";", "}", "else", "{", "MethodNode", "mNode", "=", "methodBindingToMethodNode", "(", "syntheticMethodBindings", "[", "i", "]", ")", ";", "addMethod", "(", "mNode", ")", ";", "}", "}", "}", "}", "FieldBinding", "[", "]", "fieldBindings", "=", "null", ";", "if", "(", "jdtBinding", "instanceof", "ParameterizedTypeBinding", ")", "{", "fieldBindings", "=", "(", "(", "ParameterizedTypeBinding", ")", "jdtBinding", ")", ".", "genericType", "(", ")", ".", "fields", "(", ")", ";", "}", "else", "{", "fieldBindings", "=", "jdtBinding", ".", "fields", "(", ")", ";", "}", "if", "(", "fieldBindings", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "fieldBindings", ".", "length", ";", "i", "++", ")", "{", "FieldNode", "fNode", "=", "fieldBindingToFieldNode", "(", "fieldBindings", "[", "i", "]", ",", "groovyDecl", ")", ";", "addField", "(", "fNode", ")", ";", "}", "}", "}", "private", "MethodNode", "methodBindingToMethodNode", "(", "MethodBinding", "methodBinding", ")", "{", "String", "name", "=", "new", "String", "(", "methodBinding", ".", "selector", ")", ";", "TypeVariableBinding", "[", "]", "typeVariables", "=", "methodBinding", ".", "typeVariables", "(", ")", ";", "GenericsType", "[", "]", "generics", "=", "createGenericsTypeInfoForTypeVariableBindings", "(", "typeVariables", ")", ";", "MethodNode", "mNode", "=", "null", ";", "try", "{", "resolver", ".", "pushMemberGenerics", "(", "generics", ")", ";", "int", "modifiers", "=", "methodBinding", ".", "modifiers", ";", "if", "(", "jdtBinding", ".", "isInterface", "(", ")", ")", "{", "modifiers", "|=", "Modifier", ".", "ABSTRACT", ";", "}", "ClassNode", "returnType", "=", "resolver", ".", "convertToClassNode", "(", "methodBinding", ".", "returnType", ")", ";", "Parameter", "[", "]", "gParameters", "=", "convertJdtParametersToGroovyParameters", "(", "methodBinding", ".", "parameters", ")", ";", "ClassNode", "[", "]", "thrownExceptions", "=", "new", "ClassNode", "[", "0", "]", ";", "if", "(", "methodBinding", ".", "thrownExceptions", "!=", "null", ")", "{", "thrownExceptions", "=", "new", "ClassNode", "[", "methodBinding", ".", "thrownExceptions", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "methodBinding", ".", "thrownExceptions", ".", "length", ";", "i", "++", ")", "{", "thrownExceptions", "[", "i", "]", "=", "resolver", ".", "convertToClassNode", "(", "methodBinding", ".", "thrownExceptions", "[", "i", "]", ")", ";", "}", "}", "mNode", "=", "new", "JDTMethodNode", "(", "methodBinding", ",", "resolver", ",", "name", ",", "modifiers", ",", "returnType", ",", "gParameters", ",", "thrownExceptions", ",", "null", ")", ";", "}", "finally", "{", "resolver", ".", "popMemberGenerics", "(", ")", ";", "}", "mNode", ".", "setGenericsTypes", "(", "generics", ")", ";", "return", "mNode", ";", "}", "private", "Parameter", "[", "]", "convertJdtParametersToGroovyParameters", "(", "TypeBinding", "[", "]", "jdtParameters", ")", "{", "Parameter", "[", "]", "gParameters", "=", "NO_PARAMETERS", ";", "if", "(", "jdtParameters", "!=", "null", "&&", "jdtParameters", ".", "length", ">", "0", ")", "{", "gParameters", "=", "new", "Parameter", "[", "jdtParameters", ".", "length", "]", ";", "if", "(", "jdtParameters", ".", "length", "<", "8", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "jdtParameters", ".", "length", ";", "i", "++", ")", "{", "ClassNode", "paramType", "=", "resolver", ".", "convertToClassNode", "(", "jdtParameters", "[", "i", "]", ")", ";", "gParameters", "[", "i", "]", "=", "new", "Parameter", "(", "paramType", ",", "argNames", "[", "i", "]", ")", ";", "}", "}", "else", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "jdtParameters", ".", "length", ";", "i", "++", ")", "{", "ClassNode", "c2", "=", "resolver", ".", "convertToClassNode", "(", "jdtParameters", "[", "i", "]", ")", ";", "if", "(", "i", "<", "8", ")", "{", "gParameters", "[", "i", "]", "=", "new", "Parameter", "(", "c2", ",", "argNames", "[", "i", "]", ")", ";", "}", "else", "{", "gParameters", "[", "i", "]", "=", "new", "Parameter", "(", "c2", ",", "\"arg\"", "+", "i", ")", ";", "}", "}", "}", "}", "return", "gParameters", ";", "}", "private", "ConstructorNode", "constructorBindingToConstructorNode", "(", "MethodBinding", "methodBinding", ")", "{", "TypeVariableBinding", "[", "]", "typeVariables", "=", "methodBinding", ".", "typeVariables", "(", ")", ";", "GenericsType", "[", "]", "generics", "=", "createGenericsTypeInfoForTypeVariableBindings", "(", "typeVariables", ")", ";", "ConstructorNode", "ctorNode", "=", "null", ";", "try", "{", "resolver", ".", "pushMemberGenerics", "(", "generics", ")", ";", "int", "modifiers", "=", "methodBinding", ".", "modifiers", ";", "Parameter", "[", "]", "parameters", "=", "convertJdtParametersToGroovyParameters", "(", "methodBinding", ".", "parameters", ")", ";", "ClassNode", "[", "]", "thrownExceptions", "=", "new", "ClassNode", "[", "0", "]", ";", "if", "(", "methodBinding", ".", "thrownExceptions", "!=", "null", ")", "{", "thrownExceptions", "=", "new", "ClassNode", "[", "methodBinding", ".", "thrownExceptions", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "methodBinding", ".", "thrownExceptions", ".", "length", ";", "i", "++", ")", "{", "thrownExceptions", "[", "i", "]", "=", "resolver", ".", "convertToClassNode", "(", "methodBinding", ".", "thrownExceptions", "[", "i", "]", ")", ";", "}", "}", "ctorNode", "=", "new", "ConstructorNode", "(", "modifiers", ",", "parameters", ",", "thrownExceptions", ",", "null", ")", ";", "}", "finally", "{", "resolver", ".", "popMemberGenerics", "(", ")", ";", "}", "ctorNode", ".", "setGenericsTypes", "(", "generics", ")", ";", "return", "ctorNode", ";", "}", "private", "FieldNode", "fieldBindingToFieldNode", "(", "FieldBinding", "fieldBinding", ",", "TypeDeclaration", "groovyTypeDecl", ")", "{", "String", "name", "=", "new", "String", "(", "fieldBinding", ".", "name", ")", ";", "int", "modifiers", "=", "fieldBinding", ".", "modifiers", ";", "ClassNode", "fieldType", "=", "resolver", ".", "convertToClassNode", "(", "fieldBinding", ".", "type", ")", ";", "Constant", "c", "=", "fieldBinding", ".", "constant", "(", ")", ";", "Expression", "initializerExpression", "=", "null", ";", "if", "(", "c", "==", "Constant", ".", "NotAConstant", ")", "{", "if", "(", "groovyTypeDecl", "!=", "null", ")", "{", "FieldDeclaration", "fieldDecl", "=", "groovyTypeDecl", ".", "declarationOf", "(", "fieldBinding", ")", ";", "if", "(", "fieldDecl", "instanceof", "FieldDeclarationWithInitializer", ")", "{", "initializerExpression", "=", "(", "(", "FieldDeclarationWithInitializer", ")", "fieldDecl", ")", ".", "getGroovyInitializer", "(", ")", ";", "}", "}", "}", "else", "{", "if", "(", "c", "instanceof", "StringConstant", ")", "{", "initializerExpression", "=", "new", "ConstantExpression", "(", "(", "(", "StringConstant", ")", "c", ")", ".", "stringValue", "(", ")", ")", ";", "}", "else", "if", "(", "c", "instanceof", "BooleanConstant", ")", "{", "initializerExpression", "=", "new", "ConstantExpression", "(", "(", "(", "BooleanConstant", ")", "c", ")", ".", "booleanValue", "(", ")", ")", ";", "}", "else", "if", "(", "c", "instanceof", "IntConstant", ")", "{", "initializerExpression", "=", "new", "ConstantExpression", "(", "(", "(", "IntConstant", ")", "c", ")", ".", "intValue", "(", ")", ")", ";", "}", "else", "if", "(", "c", "instanceof", "LongConstant", ")", "{", "initializerExpression", "=", "new", "ConstantExpression", "(", "(", "(", "LongConstant", ")", "c", ")", ".", "longValue", "(", ")", ")", ";", "}", "else", "if", "(", "c", "instanceof", "DoubleConstant", ")", "{", "initializerExpression", "=", "new", "ConstantExpression", "(", "(", "(", "DoubleConstant", ")", "c", ")", ".", "doubleValue", "(", ")", ")", ";", "}", "else", "if", "(", "c", "instanceof", "FloatConstant", ")", "{", "initializerExpression", "=", "new", "ConstantExpression", "(", "(", "(", "FloatConstant", ")", "c", ")", ".", "floatValue", "(", ")", ")", ";", "}", "else", "if", "(", "c", "instanceof", "ByteConstant", ")", "{", "initializerExpression", "=", "new", "ConstantExpression", "(", "(", "(", "ByteConstant", ")", "c", ")", ".", "byteValue", "(", ")", ")", ";", "}", "else", "if", "(", "c", "instanceof", "CharConstant", ")", "{", "initializerExpression", "=", "new", "ConstantExpression", "(", "(", "(", "CharConstant", ")", "c", ")", ".", "charValue", "(", ")", ")", ";", "}", "else", "if", "(", "c", "instanceof", "ShortConstant", ")", "{", "initializerExpression", "=", "new", "ConstantExpression", "(", "(", "(", "ShortConstant", ")", "c", ")", ".", "shortValue", "(", ")", ")", ";", "}", "}", "FieldNode", "fNode", "=", "new", "JDTFieldNode", "(", "fieldBinding", ",", "resolver", ",", "name", ",", "modifiers", ",", "fieldType", ",", "this", ",", "initializerExpression", ")", ";", "return", "fNode", ";", "}", "@", "Override", "public", "boolean", "isReallyResolved", "(", ")", "{", "return", "true", ";", "}", "@", "Override", "public", "String", "getClassInternalName", "(", ")", "{", "return", "getName", "(", ")", ".", "replace", "(", "'.'", ",", "'/'", ")", ";", "}", "@", "Override", "public", "boolean", "isPrimitive", "(", ")", "{", "return", "false", ";", "}", "private", "GenericsType", "[", "]", "createGenericsTypeInfoForTypeVariableBindings", "(", "TypeVariableBinding", "...", "typeVariables", ")", "{", "if", "(", "typeVariables", "==", "null", "||", "typeVariables", ".", "length", "==", "0", ")", "{", "return", "null", ";", "}", "GenericsType", "[", "]", "genericTypeInfo", "=", "new", "GenericsType", "[", "typeVariables", ".", "length", "]", ";", "for", "(", "int", "g", "=", "0", ";", "g", "<", "typeVariables", ".", "length", ";", "g", "++", ")", "{", "genericTypeInfo", "[", "g", "]", "=", "createGenericsTypeInfoForTypeVariableBinding", "(", "typeVariables", "[", "g", "]", ")", ";", "}", "return", "genericTypeInfo", ";", "}", "private", "GenericsType", "createGenericsTypeInfoForTypeVariableBinding", "(", "TypeVariableBinding", "typeVariableBinding", ")", "{", "GenericsType", "gt", "=", "new", "LazyGenericsType", "(", "typeVariableBinding", ",", "resolver", ")", ";", "return", "gt", ";", "}", "@", "Override", "public", "List", "<", "AnnotationNode", ">", "getAnnotations", "(", ")", "{", "if", "(", "(", "bits", "&", "ANNOTATIONS_INITIALIZED", ")", "==", "0", ")", "{", "ensureAnnotationsInitialized", "(", ")", ";", "}", "return", "super", ".", "getAnnotations", "(", ")", ";", "}", "private", "synchronized", "void", "ensureAnnotationsInitialized", "(", ")", "{", "if", "(", "(", "bits", "&", "ANNOTATIONS_INITIALIZED", ")", "==", "0", ")", "{", "if", "(", "(", "jdtBinding", "instanceof", "SourceTypeBinding", ")", ")", "{", "(", "(", "SourceTypeBinding", ")", "jdtBinding", ")", ".", "getAnnotationTagBits", "(", ")", ";", "}", "AnnotationBinding", "[", "]", "annotationBindings", "=", "jdtBinding", ".", "getAnnotations", "(", ")", ";", "for", "(", "AnnotationBinding", "annotationBinding", ":", "annotationBindings", ")", "{", "addAnnotation", "(", "new", "JDTAnnotationNode", "(", "annotationBinding", ",", "this", ".", "resolver", ")", ")", ";", "}", "bits", "|=", "ANNOTATIONS_INITIALIZED", ";", "}", "}", "protected", "void", "ensurePropertiesInitialized", "(", ")", "{", "if", "(", "(", "bits", "&", "PROPERTIES_INITIALIZED", ")", "==", "0", ")", "{", "initializeProperties", "(", ")", ";", "}", "}", "protected", "synchronized", "void", "initializeProperties", "(", ")", "{", "if", "(", "(", "bits", "&", "PROPERTIES_INITIALIZED", ")", "==", "0", ")", "{", "lazyClassInit", "(", ")", ";", "if", "(", "groovyDecl", "!=", "null", ")", "{", "Set", "<", "String", ">", "existing", "=", "new", "HashSet", "<", "String", ">", "(", ")", ";", "for", "(", "MethodNode", "methodNode", ":", "getMethods", "(", ")", ")", "{", "if", "(", "isGetter", "(", "methodNode", ")", ")", "{", "String", "propertyName", "=", "convertToPropertyName", "(", "methodNode", ".", "getName", "(", ")", ")", ";", "if", "(", "!", "existing", ".", "contains", "(", "propertyName", ")", ")", "{", "existing", ".", "add", "(", "propertyName", ")", ";", "super", ".", "addPropertyWithoutField", "(", "createPropertyNodeForMethodNode", "(", "methodNode", ",", "propertyName", ")", ")", ";", "}", "}", "}", "}", "bits", "|=", "PROPERTIES_INITIALIZED", ";", "}", "}", "private", "PropertyNode", "createPropertyNodeForMethodNode", "(", "MethodNode", "methodNode", ",", "String", "propertyName", ")", "{", "ClassNode", "propertyType", "=", "methodNode", ".", "getReturnType", "(", ")", ";", "int", "mods", "=", "methodNode", ".", "getModifiers", "(", ")", ";", "FieldNode", "field", "=", "this", ".", "getField", "(", "propertyName", ")", ";", "if", "(", "field", "==", "null", ")", "{", "field", "=", "new", "FieldNode", "(", "propertyName", ",", "mods", ",", "propertyType", ",", "this", ",", "null", ")", ";", "field", ".", "setDeclaringClass", "(", "this", ")", ";", "}", "else", "{", "this", ".", "removeField", "(", "propertyName", ")", ";", "}", "PropertyNode", "property", "=", "new", "PropertyNode", "(", "field", ",", "mods", ",", "null", ",", "null", ")", ";", "property", ".", "setDeclaringClass", "(", "this", ")", ";", "return", "property", ";", "}", "private", "String", "convertToPropertyName", "(", "String", "methodName", ")", "{", "StringBuffer", "propertyName", "=", "new", "StringBuffer", "(", ")", ";", "int", "prefixLen", ";", "if", "(", "methodName", ".", "startsWith", "(", "\"is\"", ")", ")", "{", "prefixLen", "=", "2", ";", "}", "else", "{", "prefixLen", "=", "3", ";", "}", "propertyName", ".", "append", "(", "Character", ".", "toLowerCase", "(", "methodName", ".", "charAt", "(", "prefixLen", ")", ")", ")", ";", "if", "(", "methodName", ".", "length", "(", ")", ">", "prefixLen", "+", "1", ")", "{", "propertyName", ".", "append", "(", "methodName", ".", "substring", "(", "prefixLen", "+", "1", ")", ")", ";", "}", "String", "name", "=", "propertyName", ".", "toString", "(", ")", ";", "return", "name", ";", "}", "private", "boolean", "isSetter", "(", "MethodNode", "methodNode", ")", "{", "return", "methodNode", ".", "getReturnType", "(", ")", "==", "ClassHelper", ".", "VOID_TYPE", "&&", "methodNode", ".", "getParameters", "(", ")", ".", "length", "==", "1", "&&", "methodNode", ".", "getName", "(", ")", ".", "startsWith", "(", "\"set\"", ")", "&&", "methodNode", ".", "getName", "(", ")", ".", "length", "(", ")", ">", "3", ";", "}", "private", "boolean", "isGetter", "(", "MethodNode", "methodNode", ")", "{", "return", "methodNode", ".", "getReturnType", "(", ")", "!=", "ClassHelper", ".", "VOID_TYPE", "&&", "methodNode", ".", "getParameters", "(", ")", ".", "length", "==", "0", "&&", "(", "(", "methodNode", ".", "getName", "(", ")", ".", "startsWith", "(", "\"get\"", ")", "&&", "methodNode", ".", "getName", "(", ")", ".", "length", "(", ")", ">", "3", ")", "||", "(", "methodNode", ".", "getName", "(", ")", ".", "startsWith", "(", "\"is\"", ")", "&&", "methodNode", ".", "getName", "(", ")", ".", "length", "(", ")", ">", "2", ")", ")", ";", "}", "@", "Override", "public", "List", "<", "PropertyNode", ">", "getProperties", "(", ")", "{", "ensurePropertiesInitialized", "(", ")", ";", "return", "super", ".", "getProperties", "(", ")", ";", "}", "@", "Override", "public", "PropertyNode", "getProperty", "(", "String", "name", ")", "{", "ensurePropertiesInitialized", "(", ")", ";", "return", "super", ".", "getProperty", "(", "name", ")", ";", "}", "@", "Override", "public", "boolean", "hasProperty", "(", "String", "name", ")", "{", "ensurePropertiesInitialized", "(", ")", ";", "return", "super", ".", "hasProperty", "(", "name", ")", ";", "}", "@", "Override", "public", "void", "addProperty", "(", "PropertyNode", "node", ")", "{", "new", "RuntimeException", "(", "\"\"", "+", "node", ".", "getName", "(", ")", ")", ".", "printStackTrace", "(", ")", ";", "}", "@", "Override", "public", "PropertyNode", "addProperty", "(", "String", "name", ",", "int", "modifiers", ",", "ClassNode", "type", ",", "Expression", "initialValueExpression", ",", "Statement", "getterBlock", ",", "Statement", "setterBlock", ")", "{", "new", "RuntimeException", "(", "\"\"", "+", "name", ")", ".", "printStackTrace", "(", ")", ";", "return", "null", ";", "}", "public", "ReferenceBinding", "getJdtBinding", "(", ")", "{", "return", "jdtBinding", ";", "}", "public", "JDTResolver", "getResolver", "(", ")", "{", "return", "resolver", ";", "}", "public", "boolean", "isDeprecated", "(", ")", "{", "return", "jdtBinding", ".", "isDeprecated", "(", ")", ";", "}", "private", "boolean", "unfindable", "=", "false", ";", "public", "Class", "getTypeClass", "(", ")", "{", "if", "(", "clazz", "!=", "null", "||", "unfindable", ")", "{", "return", "clazz", ";", "}", "ClassLoader", "transformLoader", "=", "resolver", ".", "compilationUnit", ".", "getTransformLoader", "(", ")", ";", "if", "(", "transformLoader", "!=", "null", ")", "{", "try", "{", "clazz", "=", "Class", ".", "forName", "(", "this", ".", "getName", "(", ")", ",", "false", ",", "transformLoader", ")", ";", "return", "clazz", ";", "}", "catch", "(", "ClassNotFoundException", "e", ")", "{", "unfindable", "=", "true", ";", "}", "}", "throw", "new", "GroovyBugError", "(", "\"\"", "+", "getName", "(", ")", "+", "\"\"", "+", "transformLoader", ")", ";", "}", "}", "</s>" ]
6,753
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "lang", ".", "reflect", ".", "InvocationTargetException", ";", "import", "java", ".", "lang", ".", "reflect", ".", "Method", ";", "import", "groovy", ".", "lang", ".", "GroovyClassLoader", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "classgen", ".", "GeneratorContext", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationFailedException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", ".", "PrimaryClassNodeOperation", ";", "public", "class", "GrailsInjector", "extends", "PrimaryClassNodeOperation", "{", "private", "GroovyClassLoader", "groovyClassLoader", ";", "private", "boolean", "broken", "=", "false", ";", "private", "Class", "<", "?", ">", "injectorClazz", ";", "private", "Object", "injectorInstance", ";", "private", "Method", "injectorMethod", ";", "public", "GrailsInjector", "(", "GroovyClassLoader", "groovyClassLoader", ")", "{", "this", ".", "groovyClassLoader", "=", "groovyClassLoader", ";", "}", "@", "Override", "public", "void", "call", "(", "SourceUnit", "sourceUnit", ",", "GeneratorContext", "context", ",", "ClassNode", "classNode", ")", "throws", "CompilationFailedException", "{", "if", "(", "broken", ")", "{", "return", ";", "}", "if", "(", "injectorClazz", "==", "null", ")", "{", "try", "{", "injectorClazz", "=", "groovyClassLoader", ".", "loadClass", "(", "\"\"", ")", ";", "injectorInstance", "=", "injectorClazz", ".", "newInstance", "(", ")", ";", "}", "catch", "(", "Throwable", "t", ")", "{", "broken", "=", "true", ";", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "t", ".", "printStackTrace", "(", ")", ";", "return", ";", "}", "try", "{", "injectorMethod", "=", "injectorClazz", ".", "getDeclaredMethod", "(", "\"\"", ",", "new", "Class", "[", "]", "{", "SourceUnit", ".", "class", ",", "GeneratorContext", ".", "class", ",", "ClassNode", ".", "class", "}", ")", ";", "}", "catch", "(", "SecurityException", "se", ")", "{", "broken", "=", "true", ";", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "se", ".", "printStackTrace", "(", ")", ";", "return", ";", "}", "catch", "(", "NoSuchMethodException", "nsme", ")", "{", "broken", "=", "true", ";", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "nsme", ".", "printStackTrace", "(", ")", ";", "return", ";", "}", "if", "(", "injectorMethod", "==", "null", ")", "{", "broken", "=", "true", ";", "return", ";", "}", "}", "try", "{", "if", "(", "sourceUnit", ".", "getName", "(", ")", ".", "indexOf", "(", "\"\"", ")", "!=", "-", "1", ")", "{", "injectorMethod", ".", "invoke", "(", "injectorInstance", ",", "sourceUnit", ",", "context", ",", "classNode", ")", ";", "}", "}", "catch", "(", "IllegalArgumentException", "iae", ")", "{", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "iae", ".", "printStackTrace", "(", ")", ";", "}", "catch", "(", "IllegalAccessException", "iae", ")", "{", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "iae", ".", "printStackTrace", "(", ")", ";", "}", "catch", "(", "InvocationTargetException", "e", ")", "{", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "e", ".", "printStackTrace", "(", ")", ";", "}", "}", "}", "</s>" ]
6,754
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "groovy", ".", "lang", ".", "GroovyClassLoader", ";", "import", "java", ".", "io", ".", "File", ";", "import", "java", ".", "lang", ".", "reflect", ".", "Field", ";", "import", "java", ".", "net", ".", "MalformedURLException", ";", "import", "java", ".", "net", ".", "URL", ";", "import", "java", ".", "net", ".", "URLClassLoader", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "jar", ".", "JarFile", ";", "import", "org", ".", "apache", ".", "xbean", ".", "classloader", ".", "NonLockingJarFileClassLoader", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", ".", "PrimaryClassNodeOperation", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", ".", "ProgressListener", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilerConfiguration", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ErrorCollector", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "Phases", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "eclipse", ".", "GroovyLogManager", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "eclipse", ".", "TraceCategory", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "control", ".", "EclipseSourceUnit", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "ResourcesPlugin", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Path", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "util", ".", "CompilerUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "GroovyUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ScriptFolderSelector", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "batch", ".", "FileSystem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "batch", ".", "FileSystem", ".", "Classpath", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "INameEnvironment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "LookupEnvironment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "builder", ".", "BatchImageBuilder", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "builder", ".", "BuildNotifier", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "builder", ".", "SourceFile", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "GroovyParser", "{", "public", "ProblemReporter", "problemReporter", ";", "CompilationUnit", "groovyCompilationUnit", ";", "private", "JDTResolver", "resolver", ";", "private", "String", "projectName", ";", "private", "String", "gclClasspath", ";", "public", "static", "IGroovyDebugRequestor", "debugRequestor", ";", "private", "CompilerOptions", "compilerOptions", ";", "public", "Object", "requestor", ";", "private", "boolean", "allowTransforms", ";", "private", "boolean", "isReconcile", ";", "private", "ScriptFolderSelector", "scriptFolderSelector", ";", "private", "static", "Map", "<", "String", ",", "PathLoaderPair", ">", "projectToLoaderCache", "=", "Collections", ".", "synchronizedMap", "(", "new", "HashMap", "<", "String", ",", "PathLoaderPair", ">", "(", ")", ")", ";", "static", "class", "PathLoaderPair", "{", "String", "classpath", ";", "GroovyClassLoader", "groovyClassLoader", ";", "PathLoaderPair", "(", "String", "classpath", ")", "{", "this", ".", "classpath", "=", "classpath", ";", "this", ".", "groovyClassLoader", "=", "new", "GroovyClassLoader", "(", "createConfigureLoader", "(", "classpath", ")", ")", ";", "}", "}", "public", "static", "void", "close", "(", "GroovyClassLoader", "groovyClassLoader", ")", "{", "try", "{", "Class", "<", "?", ">", "clazz", "=", "java", ".", "net", ".", "URLClassLoader", ".", "class", ";", "Field", "field_urlClasspath", "=", "clazz", ".", "getDeclaredField", "(", "\"ucp\"", ")", ";", "field_urlClasspath", ".", "setAccessible", "(", "true", ")", ";", "Object", "urlClasspath", "=", "field_urlClasspath", ".", "get", "(", "groovyClassLoader", ")", ";", "Field", "field_loaders", "=", "urlClasspath", ".", "getClass", "(", ")", ".", "getDeclaredField", "(", "\"loaders\"", ")", ";", "field_loaders", ".", "setAccessible", "(", "true", ")", ";", "Object", "[", "]", "jarLoaders", "=", "(", "(", "java", ".", "util", ".", "Collection", "<", "?", ">", ")", "field_loaders", ".", "get", "(", "urlClasspath", ")", ")", ".", "toArray", "(", ")", ";", "for", "(", "Object", "jarLoader", ":", "jarLoaders", ")", "{", "try", "{", "Field", "field_jarFile", "=", "jarLoader", ".", "getClass", "(", ")", ".", "getDeclaredField", "(", "\"jar\"", ")", ";", "field_jarFile", ".", "setAccessible", "(", "true", ")", ";", "JarFile", "jarFile", "=", "(", "JarFile", ")", "field_jarFile", ".", "get", "(", "jarLoader", ")", ";", "String", "jarFileName", "=", "jarFile", ".", "getName", "(", ")", ";", "if", "(", "jarFileName", ".", "indexOf", "(", "\"cache\"", ")", "!=", "-", "1", "||", "jarFileName", ".", "indexOf", "(", "\"plugins\"", ")", "!=", "-", "1", ")", "{", "jarFile", ".", "close", "(", ")", ";", "}", "}", "catch", "(", "Throwable", "t", ")", "{", "}", "}", "}", "catch", "(", "Throwable", "t", ")", "{", "}", "}", "public", "static", "void", "tidyCache", "(", "String", "projectName", ")", "{", "projectToLoaderCache", ".", "remove", "(", "projectName", ")", ";", "}", "public", "static", "void", "closeClassLoader", "(", "String", "projectName", ")", "{", "PathLoaderPair", "pathLoaderPair", "=", "projectToLoaderCache", ".", "get", "(", "projectName", ")", ";", "if", "(", "pathLoaderPair", "!=", "null", ")", "{", "close", "(", "pathLoaderPair", ".", "groovyClassLoader", ")", ";", "}", "}", "public", "GroovyParser", "(", "CompilerOptions", "options", ",", "ProblemReporter", "problemReporter", ",", "boolean", "allowTransforms", ",", "boolean", "isReconcile", ")", "{", "this", "(", "null", ",", "options", ",", "problemReporter", ",", "allowTransforms", ",", "isReconcile", ")", ";", "}", "private", "GroovyClassLoader", "gclForBatch", "=", "null", ";", "private", "GroovyClassLoader", "getLoaderFor", "(", "String", "path", ")", "{", "GroovyClassLoader", "gcl", "=", "null", ";", "if", "(", "projectName", "==", "null", "&&", "path", "==", "null", ")", "{", "if", "(", "gclForBatch", "==", "null", ")", "{", "try", "{", "if", "(", "requestor", "instanceof", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "Compiler", ")", "{", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "Compiler", "compiler", "=", "(", "(", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "Compiler", ")", "requestor", ")", ";", "LookupEnvironment", "lookupEnvironment", "=", "compiler", ".", "lookupEnvironment", ";", "if", "(", "lookupEnvironment", "!=", "null", ")", "{", "INameEnvironment", "nameEnvironment", "=", "lookupEnvironment", ".", "nameEnvironment", ";", "if", "(", "nameEnvironment", "instanceof", "FileSystem", ")", "{", "FileSystem", "fileSystem", "=", "(", "FileSystem", ")", "nameEnvironment", ";", "if", "(", "fileSystem", "!=", "null", ")", "{", "Field", "f", "=", "FileSystem", ".", "class", ".", "getDeclaredField", "(", "\"classpaths\"", ")", ";", "if", "(", "f", "!=", "null", ")", "{", "f", ".", "setAccessible", "(", "true", ")", ";", "gclForBatch", "=", "new", "GroovyClassLoader", "(", ")", ";", "Classpath", "[", "]", "classpaths", "=", "(", "Classpath", "[", "]", ")", "f", ".", "get", "(", "fileSystem", ")", ";", "if", "(", "classpaths", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "classpaths", ".", "length", ";", "i", "++", ")", "{", "gclForBatch", ".", "addClasspath", "(", "classpaths", "[", "i", "]", ".", "getPath", "(", ")", ")", ";", "}", "}", "}", "else", "{", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "}", "}", "}", "}", "}", "}", "catch", "(", "Exception", "e", ")", "{", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "e", ".", "printStackTrace", "(", "System", ".", "err", ")", ";", "}", "}", "return", "gclForBatch", ";", "}", "if", "(", "path", "!=", "null", ")", "{", "if", "(", "projectName", "==", "null", ")", "{", "}", "else", "{", "PathLoaderPair", "pathAndLoader", "=", "projectToLoaderCache", ".", "get", "(", "projectName", ")", ";", "if", "(", "pathAndLoader", "==", "null", ")", "{", "if", "(", "GroovyLogManager", ".", "manager", ".", "hasLoggers", "(", ")", ")", "{", "GroovyLogManager", ".", "manager", ".", "log", "(", "TraceCategory", ".", "AST_TRANSFORM", ",", "\"\"", "+", "path", ")", ";", "}", "pathAndLoader", "=", "new", "PathLoaderPair", "(", "path", ")", ";", "projectToLoaderCache", ".", "put", "(", "projectName", ",", "pathAndLoader", ")", ";", "}", "else", "{", "if", "(", "!", "path", ".", "equals", "(", "pathAndLoader", ".", "classpath", ")", ")", "{", "pathAndLoader", "=", "new", "PathLoaderPair", "(", "path", ")", ";", "projectToLoaderCache", ".", "put", "(", "projectName", ",", "pathAndLoader", ")", ";", "}", "}", "gcl", "=", "pathAndLoader", ".", "groovyClassLoader", ";", "}", "}", "return", "gcl", ";", "}", "public", "GroovyParser", "(", "Object", "requestor", ",", "CompilerOptions", "options", ",", "ProblemReporter", "problemReporter", ",", "boolean", "allowTransforms", ",", "boolean", "isReconcile", ")", "{", "String", "path", "=", "(", "options", "==", "null", "?", "null", ":", "options", ".", "groovyClassLoaderPath", ")", ";", "this", ".", "requestor", "=", "requestor", ";", "this", ".", "allowTransforms", "=", "allowTransforms", ";", "this", ".", "isReconcile", "=", "isReconcile", ";", "this", ".", "gclClasspath", "=", "path", ";", "this", ".", "compilerOptions", "=", "options", ";", "this", ".", "projectName", "=", "options", ".", "groovyProjectName", ";", "GroovyClassLoader", "gcl", "=", "getLoaderFor", "(", "path", ")", ";", "GrapeAwareGroovyClassLoader", "grabbyLoader", "=", "new", "GrapeAwareGroovyClassLoader", "(", ")", ";", "this", ".", "groovyCompilationUnit", "=", "makeCompilationUnit", "(", "grabbyLoader", ",", "gcl", ",", "isReconcile", ",", "allowTransforms", ")", ";", "this", ".", "groovyCompilationUnit", ".", "tweak", "(", "isReconcile", ")", ";", "if", "(", "grabbyLoader", "!=", "null", ")", "{", "grabbyLoader", ".", "setCompilationUnit", "(", "groovyCompilationUnit", ")", ";", "}", "this", ".", "groovyCompilationUnit", ".", "removeOutputPhaseOperation", "(", ")", ";", "if", "(", "(", "options", ".", "groovyFlags", "&", "CompilerUtils", ".", "IsGrails", ")", "!=", "0", ")", "{", "this", ".", "groovyCompilationUnit", ".", "addPhaseOperation", "(", "new", "GrailsInjector", "(", "gcl", ")", ",", "Phases", ".", "CANONICALIZATION", ")", ";", "new", "Grails20TestSupport", "(", "options", ",", "gcl", ")", ".", "addGrailsTestCompilerCustomizers", "(", "groovyCompilationUnit", ")", ";", "if", "(", "allowTransforms", "&&", "gcl", "!=", "null", ")", "{", "this", ".", "groovyCompilationUnit", ".", "addPhaseOperation", "(", "new", "GrailsGlobalPluginAwareEntityInjector", "(", "gcl", ")", ",", "Phases", ".", "CANONICALIZATION", ")", ";", "}", "}", "this", ".", "problemReporter", "=", "problemReporter", ";", "this", ".", "resolver", "=", "new", "JDTResolver", "(", "groovyCompilationUnit", ")", ";", "groovyCompilationUnit", ".", "setResolveVisitor", "(", "resolver", ")", ";", "}", "static", "class", "GrapeAwareGroovyClassLoader", "extends", "GroovyClassLoader", "{", "private", "CompilationUnit", "groovyCompilationUnit", ";", "public", "boolean", "grabbed", "=", "false", ";", "@", "Override", "public", "void", "addURL", "(", "URL", "url", ")", "{", "this", ".", "grabbed", "=", "true", ";", "super", ".", "addURL", "(", "url", ")", ";", "}", "public", "void", "setCompilationUnit", "(", "CompilationUnit", "groovyCompilationUnit", ")", "{", "this", ".", "groovyCompilationUnit", "=", "groovyCompilationUnit", ";", "}", "}", "private", "static", "boolean", "NONLOCKING", "=", "false", ";", "static", "{", "try", "{", "boolean", "value", "=", "System", ".", "getProperty", "(", "\"\"", ",", "\"false\"", ")", ".", "equalsIgnoreCase", "(", "\"true\"", ")", ";", "NONLOCKING", "=", "value", ";", "if", "(", "value", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", ")", ";", "}", "}", "catch", "(", "Throwable", "t", ")", "{", "}", "}", "private", "static", "URLClassLoader", "createLoader", "(", "URL", "[", "]", "urls", ",", "ClassLoader", "parent", ")", "{", "if", "(", "NONLOCKING", ")", "{", "return", "new", "NonLockingJarFileClassLoader", "(", "\"\"", ",", "urls", ",", "parent", ")", ";", "}", "else", "{", "return", "new", "URLClassLoader", "(", "urls", ",", "parent", ")", ";", "}", "}", "private", "static", "URLClassLoader", "createConfigureLoader", "(", "String", "path", ")", "{", "ClassLoader", "pcl", "=", "GroovyParser", ".", "class", ".", "getClassLoader", "(", ")", ";", "if", "(", "path", "==", "null", ")", "{", "return", "createLoader", "(", "null", ",", "pcl", ")", ";", "}", "List", "<", "URL", ">", "urls", "=", "new", "ArrayList", "<", "URL", ">", "(", ")", ";", "if", "(", "path", ".", "indexOf", "(", "File", ".", "pathSeparator", ")", "!=", "-", "1", ")", "{", "int", "pos", "=", "0", ";", "while", "(", "pos", "!=", "-", "1", ")", "{", "int", "nextSep", "=", "path", ".", "indexOf", "(", "File", ".", "pathSeparator", ",", "pos", ")", ";", "if", "(", "nextSep", "==", "-", "1", ")", "{", "addNewURL", "(", "path", ".", "substring", "(", "pos", ")", ",", "urls", ")", ";", "pos", "=", "-", "1", ";", "}", "else", "{", "addNewURL", "(", "path", ".", "substring", "(", "pos", ",", "nextSep", ")", ",", "urls", ")", ";", "pos", "=", "nextSep", "+", "1", ";", "}", "}", "}", "else", "{", "addNewURL", "(", "path", ",", "urls", ")", ";", "}", "return", "createLoader", "(", "urls", ".", "toArray", "(", "new", "URL", "[", "urls", ".", "size", "(", ")", "]", ")", ",", "pcl", ")", ";", "}", "private", "static", "void", "addNewURL", "(", "String", "path", ",", "List", "<", "URL", ">", "existingURLs", ")", "{", "try", "{", "File", "f", "=", "new", "File", "(", "path", ")", ";", "URL", "newURL", "=", "f", ".", "toURI", "(", ")", ".", "toURL", "(", ")", ";", "for", "(", "URL", "url", ":", "existingURLs", ")", "{", "if", "(", "url", ".", "equals", "(", "newURL", ")", ")", "{", "return", ";", "}", "}", "existingURLs", ".", "add", "(", "newURL", ")", ";", "}", "catch", "(", "MalformedURLException", "e", ")", "{", "}", "}", "public", "CompilationUnitDeclaration", "dietParse", "(", "ICompilationUnit", "sourceUnit", ",", "CompilationResult", "compilationResult", ")", "{", "char", "[", "]", "sourceCode", "=", "sourceUnit", ".", "getContents", "(", ")", ";", "if", "(", "sourceCode", "==", "null", ")", "{", "sourceCode", "=", "CharOperation", ".", "NO_CHAR", ";", "}", "CompilerConfiguration", "groovyCompilerConfig", "=", "new", "CompilerConfiguration", "(", ")", ";", "ErrorCollector", "errorCollector", "=", "new", "GroovyErrorCollectorForJDT", "(", "groovyCompilerConfig", ")", ";", "String", "filepath", "=", "null", ";", "if", "(", "sourceUnit", "instanceof", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "batch", ".", "CompilationUnit", ")", "{", "filepath", "=", "new", "String", "(", "(", "(", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "batch", ".", "CompilationUnit", ")", "sourceUnit", ")", ".", "fileName", ")", ";", "}", "else", "{", "filepath", "=", "new", "String", "(", "sourceUnit", ".", "getFileName", "(", ")", ")", ";", "}", "Path", "path", "=", "new", "Path", "(", "filepath", ")", ";", "IFile", "eclipseFile", "=", "null", ";", "if", "(", "ResourcesPlugin", ".", "getPlugin", "(", ")", "!=", "null", "&&", "path", ".", "segmentCount", "(", ")", ">=", "2", ")", "{", "eclipseFile", "=", "ResourcesPlugin", ".", "getWorkspace", "(", ")", ".", "getRoot", "(", ")", ".", "getFile", "(", "new", "Path", "(", "filepath", ")", ")", ";", "final", "IPath", "location", "=", "eclipseFile", ".", "getLocation", "(", ")", ";", "if", "(", "location", "!=", "null", ")", "{", "filepath", "=", "location", ".", "toFile", "(", ")", ".", "getAbsolutePath", "(", ")", ";", "}", "}", "SourceUnit", "groovySourceUnit", "=", "new", "EclipseSourceUnit", "(", "eclipseFile", ",", "filepath", ",", "new", "String", "(", "sourceCode", ")", ",", "groovyCompilerConfig", ",", "groovyCompilationUnit", ".", "getClassLoader", "(", ")", ",", "errorCollector", ")", ";", "groovySourceUnit", ".", "isReconcile", "=", "isReconcile", ";", "GroovyCompilationUnitDeclaration", "gcuDeclaration", "=", "new", "GroovyCompilationUnitDeclaration", "(", "problemReporter", ",", "compilationResult", ",", "sourceCode", ".", "length", ",", "groovyCompilationUnit", ",", "groovySourceUnit", ",", "compilerOptions", ")", ";", "compilationResult", ".", "lineSeparatorPositions", "=", "GroovyUtils", ".", "getSourceLineSeparatorsIn", "(", "sourceCode", ")", ";", "groovyCompilationUnit", ".", "addSource", "(", "groovySourceUnit", ")", ";", "if", "(", "requestor", "instanceof", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "Compiler", ")", "{", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "Compiler", "compiler", "=", "(", "(", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "Compiler", ")", "requestor", ")", ";", "if", "(", "compiler", ".", "requestor", "instanceof", "BatchImageBuilder", ")", "{", "BuildNotifier", "notifier", "=", "(", "(", "BatchImageBuilder", ")", "compiler", ".", "requestor", ")", ".", "notifier", ";", "if", "(", "notifier", "!=", "null", ")", "{", "groovyCompilationUnit", ".", "setProgressListener", "(", "new", "ProgressListenerImpl", "(", "notifier", ")", ")", ";", "}", "}", "}", "gcuDeclaration", ".", "processToPhase", "(", "Phases", ".", "CONVERSION", ")", ";", "if", "(", "gcuDeclaration", ".", "getModuleNode", "(", ")", "!=", "null", ")", "{", "gcuDeclaration", ".", "populateCompilationUnitDeclaration", "(", ")", ";", "for", "(", "TypeDeclaration", "decl", ":", "gcuDeclaration", ".", "types", ")", "{", "GroovyTypeDeclaration", "gtDeclaration", "=", "(", "GroovyTypeDeclaration", ")", "decl", ";", "resolver", ".", "record", "(", "gtDeclaration", ")", ";", "}", "}", "if", "(", "allowTransforms", "&&", "(", "sourceUnit", "instanceof", "SourceFile", ")", ")", "{", "if", "(", "this", ".", "scriptFolderSelector", "==", "null", ")", "{", "this", ".", "scriptFolderSelector", "=", "new", "ScriptFolderSelector", "(", "(", "(", "SourceFile", ")", "sourceUnit", ")", ".", "resource", ".", "getProject", "(", ")", ")", ";", "}", "SourceFile", "file", "=", "(", "SourceFile", ")", "sourceUnit", ";", "if", "(", "scriptFolderSelector", ".", "isScript", "(", "file", ".", "resource", ")", ")", "{", "gcuDeclaration", ".", "tagAsScript", "(", ")", ";", "}", "}", "if", "(", "debugRequestor", "!=", "null", ")", "{", "debugRequestor", ".", "acceptCompilationUnitDeclaration", "(", "gcuDeclaration", ")", ";", "}", "return", "gcuDeclaration", ";", "}", "static", "class", "ProgressListenerImpl", "implements", "ProgressListener", "{", "private", "BuildNotifier", "notifier", ";", "public", "ProgressListenerImpl", "(", "BuildNotifier", "notifier", ")", "{", "this", ".", "notifier", "=", "notifier", ";", "}", "public", "void", "parseComplete", "(", "int", "phase", ",", "String", "sourceUnitName", ")", "{", "try", "{", "int", "lastSlash", "=", "sourceUnitName", ".", "lastIndexOf", "(", "\"/\"", ")", ";", "if", "(", "lastSlash", "==", "-", "1", ")", "{", "lastSlash", "=", "sourceUnitName", ".", "lastIndexOf", "(", "\"\\\\\"", ")", ";", "}", "if", "(", "lastSlash", "!=", "-", "1", ")", "{", "StringBuffer", "msg", "=", "new", "StringBuffer", "(", ")", ";", "msg", ".", "append", "(", "\"\"", ")", ";", "msg", ".", "append", "(", "sourceUnitName", ",", "0", ",", "lastSlash", ")", ";", "notifier", ".", "subTask", "(", "msg", ".", "toString", "(", ")", ")", ";", "}", "}", "catch", "(", "Exception", "e", ")", "{", "}", "notifier", ".", "checkCancel", "(", ")", ";", "}", "public", "void", "generateComplete", "(", "int", "phase", ",", "ClassNode", "classNode", ")", "{", "try", "{", "String", "pkgName", "=", "classNode", ".", "getPackageName", "(", ")", ";", "if", "(", "pkgName", "!=", "null", "&&", "pkgName", ".", "length", "(", ")", ">", "0", ")", "{", "StringBuffer", "msg", "=", "new", "StringBuffer", "(", ")", ";", "msg", ".", "append", "(", "\"\"", ")", ";", "msg", ".", "append", "(", "pkgName", ")", ";", "notifier", ".", "subTask", "(", "msg", ".", "toString", "(", ")", ")", ";", "}", "}", "catch", "(", "Exception", "e", ")", "{", "}", "notifier", ".", "checkCancel", "(", ")", ";", "}", "}", "public", "void", "reset", "(", ")", "{", "GroovyClassLoader", "gcl", "=", "getLoaderFor", "(", "gclClasspath", ")", ";", "GrapeAwareGroovyClassLoader", "grabbyLoader", "=", "new", "GrapeAwareGroovyClassLoader", "(", ")", ";", "boolean", "allowTransforms", "=", "this", ".", "groovyCompilationUnit", ".", "allowTransforms", ";", "boolean", "isReconcile", "=", "this", ".", "groovyCompilationUnit", ".", "isReconcile", ";", "this", ".", "groovyCompilationUnit", "=", "makeCompilationUnit", "(", "grabbyLoader", ",", "gcl", ",", "isReconcile", ",", "allowTransforms", ")", ";", "this", ".", "scriptFolderSelector", "=", "null", ";", "grabbyLoader", ".", "setCompilationUnit", "(", "this", ".", "groovyCompilationUnit", ")", ";", "this", ".", "resolver", "=", "new", "JDTResolver", "(", "groovyCompilationUnit", ")", ";", "this", ".", "groovyCompilationUnit", ".", "setResolveVisitor", "(", "resolver", ")", ";", "}", "private", "CompilationUnit", "makeCompilationUnit", "(", "GroovyClassLoader", "loader", ",", "GroovyClassLoader", "transformLoader", ",", "boolean", "isReconcile", ",", "boolean", "allowTransforms", ")", "{", "CompilationUnit", "it", "=", "new", "CompilationUnit", "(", "null", ",", "null", ",", "loader", ",", "transformLoader", ",", "allowTransforms", ",", "compilerOptions", ".", "groovyTransformsToRunOnReconcile", ")", ";", "if", "(", "allowTransforms", "&&", "transformLoader", "!=", "null", "&&", "compilerOptions", "!=", "null", "&&", "(", "(", "compilerOptions", ".", "groovyFlags", "&", "0x01", ")", "!=", "0", ")", ")", "{", "try", "{", "Class", "<", "?", ">", "klass", "=", "Class", ".", "forName", "(", "\"\"", ",", "true", ",", "transformLoader", ")", ";", "if", "(", "klass", "!=", "null", ")", "{", "ClassLoader", "savedLoader", "=", "Thread", ".", "currentThread", "(", ")", ".", "getContextClassLoader", "(", ")", ";", "try", "{", "Thread", ".", "currentThread", "(", ")", ".", "setContextClassLoader", "(", "transformLoader", ")", ";", "PrimaryClassNodeOperation", "op", "=", "(", "PrimaryClassNodeOperation", ")", "klass", ".", "newInstance", "(", ")", ";", "it", ".", "addPhaseOperation", "(", "op", ",", "Phases", ".", "CANONICALIZATION", ")", ";", "}", "finally", "{", "Thread", ".", "currentThread", "(", ")", ".", "setContextClassLoader", "(", "savedLoader", ")", ";", "}", "}", "}", "catch", "(", "Exception", "e", ")", "{", "}", "}", "it", ".", "tweak", "(", "isReconcile", ")", ";", "return", "it", ";", "}", "public", "CompilerOptions", "getCompilerOptions", "(", ")", "{", "return", "compilerOptions", ";", "}", "public", "boolean", "getAllowTranforms", "(", ")", "{", "return", "allowTransforms", ";", "}", "public", "boolean", "getIsReconcile", "(", ")", "{", "return", "isReconcile", ";", "}", "public", "CompilationUnit", "getGroovyCompilationUnit", "(", ")", "{", "return", "groovyCompilationUnit", ";", "}", "public", "String", "getProjectName", "(", ")", "{", "return", "projectName", ";", "}", "}", "</s>" ]
6,755
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "public", "class", "AbortResolutionException", "extends", "IllegalStateException", "{", "private", "static", "final", "long", "serialVersionUID", "=", "1L", ";", "public", "AbortResolutionException", "(", "String", "message", ")", "{", "super", "(", "message", ")", ";", "}", "}", "</s>" ]
6,756
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "groovy", ".", "lang", ".", "GroovyClassLoader", ";", "import", "groovy", ".", "lang", ".", "GroovySystem", ";", "import", "java", ".", "io", ".", "File", ";", "import", "java", ".", "lang", ".", "reflect", ".", "Constructor", ";", "import", "java", ".", "lang", ".", "reflect", ".", "InvocationTargetException", ";", "import", "java", ".", "lang", ".", "reflect", ".", "Method", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "classgen", ".", "GeneratorContext", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationFailedException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "customizers", ".", "ASTTransformationCustomizer", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "customizers", ".", "ImportCustomizer", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "control", ".", "EclipseSourceUnit", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "ResourcesPlugin", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Assert", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Path", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "public", "class", "Grails20TestSupport", "{", "public", "static", "boolean", "DEBUG", "=", "false", ";", "private", "static", "void", "debug", "(", "String", "msg", ")", "{", "if", "(", "DEBUG", ")", "{", "System", ".", "out", ".", "println", "(", "\"\"", "+", "msg", ")", ";", "}", "}", "private", "static", "final", "String", "GRAILS_UTIL_BUILD_SETTINGS", "=", "\"\"", ";", "private", "static", "final", "String", "GRAILS_UTIL_BUILD_SETTINGS_HOLDER", "=", "\"\"", ";", "CompilerOptions", "options", ";", "GroovyClassLoader", "gcl", ";", "public", "Grails20TestSupport", "(", "CompilerOptions", "options", ",", "GroovyClassLoader", "gcl", ")", "{", "this", ".", "options", "=", "options", ";", "this", ".", "gcl", "=", "gcl", ";", "}", "public", "void", "addGrailsTestCompilerCustomizers", "(", "CompilationUnit", "groovyCompilationUnit", ")", "{", "if", "(", "GroovySystem", ".", "getVersion", "(", ")", ".", "startsWith", "(", "\"1.8\"", ")", ")", "{", "ImportCustomizer", "importCustomizer", "=", "new", "ImportCustomizer", "(", ")", "{", "@", "Override", "public", "void", "call", "(", "SourceUnit", "source", ",", "GeneratorContext", "context", ",", "ClassNode", "classNode", ")", "throws", "CompilationFailedException", "{", "if", "(", "isInGrailsUnitTestSourceFolder", "(", "source", ")", ")", "{", "super", ".", "call", "(", "source", ",", "context", ",", "classNode", ")", ";", "}", "}", "}", ";", "importCustomizer", ".", "addStarImports", "(", "\"\"", ")", ";", "importCustomizer", ".", "addStarImports", "(", "\"org.junit\"", ")", ";", "importCustomizer", ".", "addStaticStars", "(", "\"\"", ")", ";", "groovyCompilationUnit", ".", "addPhaseOperation", "(", "importCustomizer", ",", "importCustomizer", ".", "getPhase", "(", ")", ".", "getPhaseNumber", "(", ")", ")", ";", "@", "SuppressWarnings", "(", "\"rawtypes\"", ")", "Class", "testForClass", "=", "null", ";", "try", "{", "testForClass", "=", "Class", ".", "forName", "(", "\"\"", ",", "false", ",", "gcl", ")", ";", "if", "(", "testForClass", "!=", "null", ")", "{", "ASTTransformationCustomizer", "astTransformationCustomizer", "=", "new", "ASTTransformationCustomizer", "(", "testForClass", ")", "{", "@", "Override", "public", "void", "call", "(", "SourceUnit", "source", ",", "GeneratorContext", "context", ",", "ClassNode", "classNode", ")", "throws", "CompilationFailedException", "{", "if", "(", "isInGrailsUnitTestSourceFolder", "(", "source", ")", ")", "{", "super", ".", "call", "(", "source", ",", "context", ",", "classNode", ")", ";", "}", "}", "}", ";", "groovyCompilationUnit", ".", "addPhaseOperation", "(", "astTransformationCustomizer", ",", "astTransformationCustomizer", ".", "getPhase", "(", ")", ".", "getPhaseNumber", "(", ")", ")", ";", "ensureGrailsBuildSettings", "(", ")", ";", "}", "}", "catch", "(", "LinkageError", "e", ")", "{", "}", "catch", "(", "ClassNotFoundException", "e", ")", "{", "}", "catch", "(", "Exception", "e", ")", "{", "e", ".", "printStackTrace", "(", "System", ".", "err", ")", ";", "}", "}", "}", "@", "SuppressWarnings", "(", "\"rawtypes\"", ")", "void", "ensureGrailsBuildSettings", "(", ")", "{", "debug", "(", "\"\"", ")", ";", "try", "{", "String", "projectName", "=", "options", ".", "groovyProjectName", ";", "debug", "(", "\"\"", "+", "projectName", ")", ";", "if", "(", "projectName", "!=", "null", ")", "{", "Class", "buildSettingsHolder", "=", "gcl", ".", "loadClass", "(", "GRAILS_UTIL_BUILD_SETTINGS_HOLDER", ")", ";", "debug", "(", "\"\"", "+", "buildSettingsHolder", ")", ";", "Object", "buildSettings", "=", "getBuildSettings", "(", "buildSettingsHolder", ")", ";", "debug", "(", "\"\"", "+", "buildSettings", ")", ";", "if", "(", "buildSettings", "==", "null", ")", "{", "debug", "(", "\"\"", ")", ";", "buildSettings", "=", "createBuildSettings", "(", ")", ";", "debug", "(", "\"\"", "+", "buildSettingsHolder", ")", ";", "setBuildSettings", "(", "buildSettingsHolder", ",", "buildSettings", ")", ";", "Object", "checkit", "=", "getBuildSettings", "(", "buildSettingsHolder", ")", ";", "debug", "(", "\"\"", "+", "checkit", ")", ";", "}", "}", "}", "catch", "(", "Exception", "e", ")", "{", "debug", "(", "\"\"", ")", ";", "e", ".", "printStackTrace", "(", ")", ";", "}", "debug", "(", "\"\"", ")", ";", "}", "@", "SuppressWarnings", "(", "\"rawtypes\"", ")", "private", "Object", "createBuildSettings", "(", ")", "throws", "ClassNotFoundException", ",", "SecurityException", ",", "NoSuchMethodException", ",", "IllegalArgumentException", ",", "InstantiationException", ",", "IllegalAccessException", ",", "InvocationTargetException", "{", "Class", "buildSettingsClass", "=", "gcl", ".", "loadClass", "(", "GRAILS_UTIL_BUILD_SETTINGS", ")", ";", "debug", "(", "\"\"", "+", "buildSettingsClass", ")", ";", "Constructor", "constructor", "=", "buildSettingsClass", ".", "getConstructor", "(", "File", ".", "class", ",", "File", ".", "class", ")", ";", "debug", "(", "\"\"", "+", "constructor", ")", ";", "Object", "grailsHome", "=", "getGrailsHome", "(", ")", ";", "debug", "(", "\"\"", "+", "grailsHome", ")", ";", "File", "projectHome", "=", "getProjectHome", "(", ")", ";", "debug", "(", "\"\"", "+", "projectHome", ")", ";", "return", "constructor", ".", "newInstance", "(", "grailsHome", ",", "projectHome", ")", ";", "}", "private", "Object", "getGrailsHome", "(", ")", "{", "return", "null", ";", "}", "private", "File", "getProjectHome", "(", ")", "{", "String", "projectName", "=", "options", ".", "groovyProjectName", ";", "if", "(", "projectName", "!=", "null", ")", "{", "IProject", "project", "=", "ResourcesPlugin", ".", "getWorkspace", "(", ")", ".", "getRoot", "(", ")", ".", "getProject", "(", "projectName", ")", ";", "IPath", "location", "=", "project", ".", "getLocation", "(", ")", ";", "if", "(", "location", "!=", "null", ")", "{", "return", "location", ".", "toFile", "(", ")", ";", "}", "}", "return", "null", ";", "}", "@", "SuppressWarnings", "(", "\"rawtypes\"", ")", "private", "static", "Object", "getBuildSettings", "(", "Class", "buildSettingsHolder", ")", "throws", "SecurityException", ",", "NoSuchMethodException", ",", "IllegalArgumentException", ",", "IllegalAccessException", ",", "InvocationTargetException", "{", "Method", "m", "=", "buildSettingsHolder", ".", "getMethod", "(", "\"getSettings\"", ")", ";", "return", "m", ".", "invoke", "(", "null", ")", ";", "}", "@", "SuppressWarnings", "(", "\"rawtypes\"", ")", "private", "static", "synchronized", "void", "setBuildSettings", "(", "Class", "buildSettingsHolder", ",", "Object", "buildSettings", ")", "throws", "SecurityException", ",", "NoSuchMethodException", ",", "ClassNotFoundException", ",", "IllegalArgumentException", ",", "IllegalAccessException", ",", "InvocationTargetException", "{", "Method", "m", "=", "buildSettingsHolder", ".", "getMethod", "(", "\"setSettings\"", ",", "buildSettingsHolder", ".", "getClassLoader", "(", ")", ".", "loadClass", "(", "GRAILS_UTIL_BUILD_SETTINGS", ")", ")", ";", "m", ".", "invoke", "(", "null", ",", "buildSettings", ")", ";", "Assert", ".", "isTrue", "(", "getBuildSettings", "(", "buildSettingsHolder", ")", "==", "buildSettings", ")", ";", "}", "static", "boolean", "isInGrailsUnitTestSourceFolder", "(", "SourceUnit", "source", ")", "{", "if", "(", "source", "instanceof", "EclipseSourceUnit", ")", "{", "EclipseSourceUnit", "eclipseSource", "=", "(", "EclipseSourceUnit", ")", "source", ";", "IFile", "file", "=", "eclipseSource", ".", "getEclipseFile", "(", ")", ";", "if", "(", "file", "!=", "null", ")", "{", "IPath", "path", "=", "file", ".", "getProjectRelativePath", "(", ")", ";", "return", "new", "Path", "(", "\"test/unit\"", ")", ".", "isPrefixOf", "(", "path", ")", ";", "}", "}", "return", "false", ";", "}", "}", "</s>" ]
6,757
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "public", "class", "GroovyEclipseBug", "extends", "IllegalStateException", "{", "private", "static", "final", "long", "serialVersionUID", "=", "1L", ";", "public", "GroovyEclipseBug", "(", "String", "message", ")", "{", "super", "(", "message", ")", ";", "}", "public", "GroovyEclipseBug", "(", ")", "{", "}", "}", "</s>" ]
6,758
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "public", "class", "GroovyCheckingControl", "{", "public", "final", "static", "boolean", "globalControl", "=", "true", ";", "public", "final", "static", "boolean", "checkTypeReferences", "=", "globalControl", "&&", "true", ";", "}", "</s>" ]
6,759
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Set", ";", "public", "class", "EventListener", "{", "private", "List", "<", "String", ">", "events", "=", "new", "ArrayList", "<", "String", ">", "(", ")", ";", "private", "Set", "<", "String", ">", "interestingEvents", "=", "new", "HashSet", "<", "String", ">", "(", ")", ";", "public", "EventListener", "(", ")", "{", "}", "public", "EventListener", "(", "String", "key", ")", "{", "interestingEvents", ".", "add", "(", "key", ")", ";", "}", "public", "EventListener", "(", "String", "...", "keys", ")", "{", "if", "(", "keys", "!=", "null", ")", "{", "for", "(", "String", "k", ":", "keys", ")", "{", "interestingEvents", ".", "add", "(", "k", ")", ";", "}", "}", "}", "public", "void", "record", "(", "String", "event", ")", "{", "String", "key", "=", "event", ".", "substring", "(", "0", ",", "event", ".", "indexOf", "(", "':'", ")", ")", ".", "toLowerCase", "(", ")", ";", "if", "(", "interestingEvents", ".", "size", "(", ")", ">", "0", "&&", "!", "interestingEvents", ".", "contains", "(", "key", ")", ")", "{", "return", ";", "}", "events", ".", "add", "(", "event", ")", ";", "}", "public", "void", "clear", "(", ")", "{", "events", ".", "clear", "(", ")", ";", "}", "public", "String", "toString", "(", ")", "{", "StringBuilder", "sb", "=", "new", "StringBuilder", "(", ")", ";", "for", "(", "String", "event", ":", "events", ")", "{", "sb", ".", "append", "(", "event", ")", ".", "append", "(", "\"n\"", ")", ";", "}", "return", "sb", ".", "toString", "(", ")", ";", "}", "public", "int", "eventCount", "(", ")", "{", "return", "events", ".", "size", "(", ")", ";", "}", "public", "List", "<", "String", ">", "getEvents", "(", ")", "{", "return", "Collections", ".", "unmodifiableList", "(", "events", ")", ";", "}", "}", "</s>" ]
6,760
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "groovy", ".", "lang", ".", "GroovyClassLoader", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ModuleNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstantExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "classgen", ".", "GeneratorContext", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationFailedException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", ".", "PrimaryClassNodeOperation", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "control", ".", "EclipseSourceUnit", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IPath", ";", "public", "class", "GrailsGlobalPluginAwareEntityInjector", "extends", "PrimaryClassNodeOperation", "{", "private", "static", "final", "boolean", "DEBUG", "=", "false", ";", "private", "static", "void", "debug", "(", "String", "msg", ")", "{", "System", ".", "out", ".", "println", "(", "msg", ")", ";", "}", "private", "static", "class", "PluginInfo", "{", "final", "String", "name", ";", "final", "String", "version", ";", "public", "PluginInfo", "(", "String", "name", ",", "String", "version", ")", "{", "this", ".", "name", "=", "name", ";", "this", ".", "version", "=", "version", ";", "}", "@", "Override", "public", "String", "toString", "(", ")", "{", "return", "\"Plugin(name=\"", "+", "name", "+", "\",", "version=\"", "+", "version", "+", "\")\"", ";", "}", "}", "private", "GroovyClassLoader", "groovyClassLoader", ";", "private", "boolean", "broken", "=", "false", ";", "public", "GrailsGlobalPluginAwareEntityInjector", "(", "GroovyClassLoader", "groovyClassLoader", ")", "{", "this", ".", "groovyClassLoader", "=", "groovyClassLoader", ";", "}", "@", "Override", "public", "void", "call", "(", "SourceUnit", "_sourceUnit", ",", "GeneratorContext", "context", ",", "ClassNode", "classNode", ")", "throws", "CompilationFailedException", "{", "if", "(", "broken", ")", "{", "return", ";", "}", "if", "(", "_sourceUnit", "instanceof", "EclipseSourceUnit", ")", "{", "EclipseSourceUnit", "sourceUnit", "=", "(", "EclipseSourceUnit", ")", "_sourceUnit", ";", "try", "{", "if", "(", "classNode", ".", "isAnnotationDefinition", "(", ")", ")", "{", "return", ";", "}", "if", "(", "!", "isFirstClassInModule", "(", "classNode", ")", ")", "{", "return", ";", "}", "IFile", "file", "=", "sourceUnit", ".", "getEclipseFile", "(", ")", ";", "PluginInfo", "info", "=", "getInfo", "(", "file", ")", ";", "if", "(", "info", "!=", "null", ")", "{", "if", "(", "DEBUG", ")", "{", "debug", "(", "\"\"", "+", "classNode", ")", ";", "}", "Class", "<", "?", ">", "GrailsPlugin_class", "=", "Class", ".", "forName", "(", "\"\"", ",", "false", ",", "groovyClassLoader", ")", ";", "final", "ClassNode", "annotation", "=", "new", "ClassNode", "(", "GrailsPlugin_class", ")", ";", "final", "List", "<", "?", ">", "list", "=", "classNode", ".", "getAnnotations", "(", "annotation", ")", ";", "if", "(", "!", "list", ".", "isEmpty", "(", ")", ")", "{", "return", ";", "}", "final", "AnnotationNode", "annotationNode", "=", "new", "AnnotationNode", "(", "annotation", ")", ";", "annotationNode", ".", "addMember", "(", "\"name\"", ",", "new", "ConstantExpression", "(", "info", ".", "name", ")", ")", ";", "annotationNode", ".", "addMember", "(", "\"version\"", ",", "new", "ConstantExpression", "(", "info", ".", "version", ")", ")", ";", "annotationNode", ".", "setRuntimeRetention", "(", "true", ")", ";", "annotationNode", ".", "setClassRetention", "(", "true", ")", ";", "classNode", ".", "addAnnotation", "(", "annotationNode", ")", ";", "}", "else", "{", "if", "(", "DEBUG", ")", "{", "debug", "(", "\"\"", "+", "classNode", ")", ";", "}", "}", "}", "catch", "(", "Exception", "e", ")", "{", "e", ".", "printStackTrace", "(", "System", ".", "err", ")", ";", "broken", "=", "true", ";", "}", "}", "}", "private", "boolean", "isFirstClassInModule", "(", "ClassNode", "classNode", ")", "{", "ModuleNode", "module", "=", "classNode", ".", "getModule", "(", ")", ";", "if", "(", "module", "!=", "null", ")", "{", "List", "<", "ClassNode", ">", "classes", "=", "module", ".", "getClasses", "(", ")", ";", "if", "(", "classes", "!=", "null", "&&", "classes", ".", "size", "(", ")", ">", "0", ")", "{", "return", "classes", ".", "get", "(", "0", ")", "==", "classNode", ";", "}", "}", "return", "false", ";", "}", "public", "static", "PluginInfo", "getInfo", "(", "IFile", "file", ")", "{", "if", "(", "file", "==", "null", ")", "{", "return", "null", ";", "}", "IPath", "path", "=", "file", ".", "getFullPath", "(", ")", ";", "if", "(", "path", "!=", "null", ")", "{", "if", "(", "path", ".", "segmentCount", "(", ")", ">", "3", ")", "{", "String", "link", "=", "path", ".", "segment", "(", "1", ")", ";", "if", "(", "link", ".", "equals", "(", "\"\"", ")", ")", "{", "String", "pluginNameAndVersion", "=", "path", ".", "segment", "(", "2", ")", ";", "int", "split", "=", "findVersionDash", "(", "pluginNameAndVersion", ")", ";", "if", "(", "split", ">=", "0", ")", "{", "if", "(", "\"test\"", ".", "equals", "(", "path", ".", "segment", "(", "3", ")", ")", ")", "{", "return", "null", ";", "}", "else", "{", "return", "new", "PluginInfo", "(", "pluginNameAndVersion", ".", "substring", "(", "0", ",", "split", ")", ",", "pluginNameAndVersion", ".", "substring", "(", "split", "+", "1", ")", ")", ";", "}", "}", "}", "}", "}", "return", "null", ";", "}", "private", "static", "int", "findVersionDash", "(", "String", "pluginNameAndVersion", ")", "{", "int", "split", "=", "pluginNameAndVersion", ".", "lastIndexOf", "(", "'-'", ")", ";", "if", "(", "pluginNameAndVersion", ".", "endsWith", "(", "\"-SNAPSHOT\"", ")", ")", "{", "split", "=", "pluginNameAndVersion", ".", "lastIndexOf", "(", "'-'", ",", "split", "-", "1", ")", ";", "}", "return", "split", ";", "}", "}", "</s>" ]
6,761
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ClassExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstantExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ListExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "PropertyExpression", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "IntConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "StringConstant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "AnnotationBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ArrayBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ElementValuePair", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "FieldBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TagBits", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "JDTAnnotationNode", "extends", "AnnotationNode", "{", "private", "static", "final", "char", "[", "]", "jlString", "=", "\"\"", ".", "toCharArray", "(", ")", ";", "private", "static", "final", "char", "[", "]", "baseInt", "=", "\"I\"", ".", "toCharArray", "(", ")", ";", "private", "boolean", "membersInitialized", "=", "false", ";", "private", "AnnotationBinding", "annotationBinding", ";", "private", "JDTResolver", "resolver", ";", "public", "JDTAnnotationNode", "(", "AnnotationBinding", "annotationBinding", ",", "JDTResolver", "resolver", ")", "{", "super", "(", "new", "JDTClassNode", "(", "annotationBinding", ".", "getAnnotationType", "(", ")", ",", "resolver", ")", ")", ";", "this", ".", "annotationBinding", "=", "annotationBinding", ";", "this", ".", "resolver", "=", "resolver", ";", "}", "@", "Override", "public", "void", "addMember", "(", "String", "name", ",", "Expression", "value", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "ClassNode", "getClassNode", "(", ")", "{", "return", "super", ".", "getClassNode", "(", ")", ";", "}", "@", "Override", "public", "Expression", "getMember", "(", "String", "name", ")", "{", "ensureMembersInitialized", "(", ")", ";", "return", "super", ".", "getMember", "(", "name", ")", ";", "}", "@", "Override", "public", "Map", "<", "String", ",", "Expression", ">", "getMembers", "(", ")", "{", "ensureMembersInitialized", "(", ")", ";", "return", "super", ".", "getMembers", "(", ")", ";", "}", "@", "Override", "public", "boolean", "hasClassRetention", "(", ")", "{", "return", "(", "annotationBinding", ".", "getAnnotationType", "(", ")", ".", "tagBits", "&", "TagBits", ".", "AnnotationClassRetention", ")", "==", "TagBits", ".", "AnnotationClassRetention", ";", "}", "@", "Override", "public", "boolean", "hasRuntimeRetention", "(", ")", "{", "return", "(", "annotationBinding", ".", "getAnnotationType", "(", ")", ".", "tagBits", "&", "TagBits", ".", "AnnotationRuntimeRetention", ")", "==", "TagBits", ".", "AnnotationRuntimeRetention", ";", "}", "@", "Override", "public", "boolean", "hasSourceRetention", "(", ")", "{", "return", "(", "annotationBinding", ".", "getAnnotationType", "(", ")", ".", "tagBits", "&", "TagBits", ".", "AnnotationSourceRetention", ")", "==", "TagBits", ".", "AnnotationSourceRetention", ";", "}", "@", "Override", "public", "boolean", "isBuiltIn", "(", ")", "{", "return", "super", ".", "isBuiltIn", "(", ")", ";", "}", "@", "Override", "public", "boolean", "isTargetAllowed", "(", "int", "target", ")", "{", "return", "super", ".", "isTargetAllowed", "(", "target", ")", ";", "}", "@", "Override", "public", "void", "setMember", "(", "String", "name", ",", "Expression", "value", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "private", "void", "ensureMembersInitialized", "(", ")", "{", "if", "(", "membersInitialized", ")", "{", "return", ";", "}", "membersInitialized", "=", "true", ";", "ElementValuePair", "[", "]", "evpairs", "=", "annotationBinding", ".", "getElementValuePairs", "(", ")", ";", "for", "(", "ElementValuePair", "evpair", ":", "evpairs", ")", "{", "char", "[", "]", "name", "=", "evpair", ".", "getName", "(", ")", ";", "MethodBinding", "mb", "=", "evpair", ".", "binding", ";", "Expression", "valueExpression", "=", "null", ";", "if", "(", "mb", "==", "null", "&&", "(", "evpair", ".", "value", "instanceof", "StringConstant", ")", ")", "{", "String", "v", "=", "(", "(", "StringConstant", ")", "evpair", ".", "value", ")", ".", "stringValue", "(", ")", ";", "valueExpression", "=", "new", "ConstantExpression", "(", "v", ")", ";", "}", "else", "{", "valueExpression", "=", "createExpressionFor", "(", "mb", ".", "returnType", ",", "evpair", ".", "value", ")", ";", "}", "super", ".", "addMember", "(", "new", "String", "(", "name", ")", ",", "valueExpression", ")", ";", "}", "}", "private", "Expression", "createExpressionFor", "(", "TypeBinding", "b", ",", "Object", "value", ")", "{", "if", "(", "b", ".", "isArrayType", "(", ")", ")", "{", "ListExpression", "listExpression", "=", "new", "ListExpression", "(", ")", ";", "if", "(", "value", ".", "getClass", "(", ")", ".", "isArray", "(", ")", ")", "{", "Object", "[", "]", "values", "=", "(", "Object", "[", "]", ")", "value", ";", "for", "(", "Object", "v", ":", "values", ")", "{", "listExpression", ".", "addExpression", "(", "createExpressionFor", "(", "(", "(", "ArrayBinding", ")", "b", ")", ".", "leafComponentType", ",", "v", ")", ")", ";", "}", "}", "else", "{", "listExpression", ".", "addExpression", "(", "createExpressionFor", "(", "(", "(", "ArrayBinding", ")", "b", ")", ".", "leafComponentType", ",", "value", ")", ")", ";", "}", "return", "listExpression", ";", "}", "else", "if", "(", "b", ".", "isEnum", "(", ")", ")", "{", "ClassExpression", "classExpression", "=", "new", "ClassExpression", "(", "resolver", ".", "convertToClassNode", "(", "b", ")", ")", ";", "Expression", "valueExpression", "=", "new", "PropertyExpression", "(", "classExpression", ",", "new", "String", "(", "(", "(", "FieldBinding", ")", "value", ")", ".", "name", ")", ")", ";", "return", "valueExpression", ";", "}", "else", "if", "(", "CharOperation", ".", "equals", "(", "b", ".", "signature", "(", ")", ",", "jlString", ")", ")", "{", "String", "v", "=", "(", "(", "StringConstant", ")", "value", ")", ".", "stringValue", "(", ")", ";", "return", "new", "ConstantExpression", "(", "v", ")", ";", "}", "else", "if", "(", "b", ".", "isBaseType", "(", ")", ")", "{", "char", "[", "]", "sig", "=", "b", ".", "signature", "(", ")", ";", "if", "(", "CharOperation", ".", "equals", "(", "sig", ",", "baseInt", ")", ")", "{", "return", "new", "ConstantExpression", "(", "(", "(", "IntConstant", ")", "value", ")", ".", "intValue", "(", ")", ")", ";", "}", "else", "{", "throw", "new", "GroovyEclipseBug", "(", "\"\"", "+", "new", "String", "(", "sig", ")", ")", ";", "}", "}", "else", "if", "(", "b", ".", "isClass", "(", ")", ")", "{", "ClassExpression", "classExpression", "=", "new", "ClassExpression", "(", "resolver", ".", "convertToClassNode", "(", "(", "TypeBinding", ")", "value", ")", ")", ";", "return", "classExpression", ";", "}", "throw", "new", "GroovyEclipseBug", "(", "\"\"", "+", "b", "+", "\"", "value=\"", "+", "value", "+", "\")\"", ")", ";", "}", "public", "JDTResolver", "getResolver", "(", ")", "{", "return", "resolver", ";", "}", "}", "</s>" ]
6,762
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "groovy", ".", "lang", ".", "GroovyClassLoader", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "Set", ";", "import", "java", ".", "util", ".", "Stack", ";", "import", "java", ".", "util", ".", "StringTokenizer", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GenericsType", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "InnerClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationFailedException", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ResolveVisitor", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyParser", ".", "GrapeAwareGroovyClassLoader", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "Wildcard", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ArrayBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "BaseTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "BinaryTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Binding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "MethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ParameterizedMethodBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ReferenceBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "SourceTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeIds", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeVariableBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "WildcardBinding", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "JDTResolver", "extends", "ResolveVisitor", "{", "private", "static", "final", "int", "BOOLEAN_LENGTH", "=", "\"boolean\"", ".", "length", "(", ")", ";", "private", "static", "final", "boolean", "debug", "=", "false", ";", "private", "static", "Map", "<", "String", ",", "ClassNode", ">", "commonTypes", "=", "new", "HashMap", "<", "String", ",", "ClassNode", ">", "(", ")", ";", "public", "static", "boolean", "recordInstances", "=", "false", ";", "public", "static", "List", "<", "JDTResolver", ">", "instances", "=", "null", ";", "static", "{", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "OBJECT_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "STRING_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "CLASS_Type", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "Boolean_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "Byte_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "Character_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "Double_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "Float_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "Integer_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "Long_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"\"", ",", "ClassHelper", ".", "Short_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"boolean\"", ",", "ClassHelper", ".", "boolean_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"byte\"", ",", "ClassHelper", ".", "byte_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"char\"", ",", "ClassHelper", ".", "char_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"double\"", ",", "ClassHelper", ".", "double_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"float\"", ",", "ClassHelper", ".", "float_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"int\"", ",", "ClassHelper", ".", "int_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"long\"", ",", "ClassHelper", ".", "long_TYPE", ")", ";", "commonTypes", ".", "put", "(", "\"short\"", ",", "ClassHelper", ".", "short_TYPE", ")", ";", "}", "private", "Stack", "<", "GenericsType", "[", "]", ">", "memberGenericsCurrentlyActive", "=", "new", "Stack", "<", "GenericsType", "[", "]", ">", "(", ")", ";", "private", "Stack", "<", "GenericsType", "[", "]", ">", "typeGenericsCurrentlyActive", "=", "new", "Stack", "<", "GenericsType", "[", "]", ">", "(", ")", ";", "void", "pushMemberGenerics", "(", "GenericsType", "[", "]", "generics", ")", "{", "memberGenericsCurrentlyActive", ".", "push", "(", "generics", ")", ";", "}", "void", "popMemberGenerics", "(", ")", "{", "memberGenericsCurrentlyActive", ".", "pop", "(", ")", ";", "}", "public", "void", "pushTypeGenerics", "(", "GenericsType", "[", "]", "genericsTypes", ")", "{", "typeGenericsCurrentlyActive", ".", "push", "(", "genericsTypes", ")", ";", "}", "public", "void", "popTypeGenerics", "(", ")", "{", "typeGenericsCurrentlyActive", ".", "pop", "(", ")", ";", "}", "private", "Map", "<", "TypeBinding", ",", "JDTClassNode", ">", "inProgress", "=", "new", "HashMap", "<", "TypeBinding", ",", "JDTClassNode", ">", "(", ")", ";", "private", "Stack", "<", "JDTClassNode", ">", "inProgressStack", "=", "new", "Stack", "<", "JDTClassNode", ">", "(", ")", ";", "private", "GroovyCompilationUnitScope", "activeScope", "=", "null", ";", "private", "Map", "<", "ClassNode", ",", "GroovyTypeDeclaration", ">", "scopes", "=", "new", "HashMap", "<", "ClassNode", ",", "GroovyTypeDeclaration", ">", "(", ")", ";", "private", "List", "<", "ClassNode", ">", "haveBeenResolved", "=", "new", "ArrayList", "<", "ClassNode", ">", "(", ")", ";", "private", "Map", "<", "Binding", ",", "JDTClassNode", ">", "nodeCache", "=", "Collections", ".", "synchronizedMap", "(", "new", "HashMap", "<", "Binding", ",", "JDTClassNode", ">", "(", ")", ")", ";", "public", "JDTResolver", "(", "CompilationUnit", "groovyCompilationUnit", ")", "{", "super", "(", "groovyCompilationUnit", ")", ";", "if", "(", "recordInstances", ")", "{", "if", "(", "instances", "==", "null", ")", "{", "instances", "=", "new", "ArrayList", "<", "JDTResolver", ">", "(", ")", ";", "}", "instances", ".", "add", "(", "this", ")", ";", "}", "}", "public", "JDTClassNode", "getCachedNode", "(", "String", "name", ")", "{", "for", "(", "Map", ".", "Entry", "<", "Binding", ",", "JDTClassNode", ">", "nodeFromCache", ":", "nodeCache", ".", "entrySet", "(", ")", ")", "{", "String", "nodename", "=", "new", "String", "(", "nodeFromCache", ".", "getKey", "(", ")", ".", "readableName", "(", ")", ")", ";", "if", "(", "nodename", ".", "equals", "(", "name", ")", ")", "{", "return", "nodeFromCache", ".", "getValue", "(", ")", ";", "}", "}", "return", "null", ";", "}", "@", "Override", "protected", "boolean", "resolveFromModule", "(", "ClassNode", "type", ",", "boolean", "testModuleImports", ")", "{", "boolean", "foundit", "=", "super", ".", "resolveFromModule", "(", "type", ",", "testModuleImports", ")", ";", "recordDependency", "(", "type", ".", "getName", "(", ")", ")", ";", "if", "(", "debug", ")", "{", "log", "(", "\"\"", ",", "type", ",", "foundit", ")", ";", "}", "return", "foundit", ";", "}", "@", "Override", "protected", "boolean", "resolveFromCompileUnit", "(", "ClassNode", "type", ")", "{", "boolean", "foundit", "=", "super", ".", "resolveFromCompileUnit", "(", "type", ")", ";", "recordDependency", "(", "type", ".", "getName", "(", ")", ")", ";", "if", "(", "debug", ")", "{", "log", "(", "\"\"", ",", "type", ",", "foundit", ")", ";", "}", "if", "(", "foundit", ")", "{", "return", "true", ";", "}", "String", "typename", "=", "type", ".", "getName", "(", ")", ";", "ClassNode", "node", "=", "getScope", "(", ")", ".", "lookupClassNodeForSource", "(", "typename", ",", "this", ")", ";", "if", "(", "debug", ")", "{", "log", "(", "\"\"", ",", "type", ",", "node", "!=", "null", ")", ";", "}", "if", "(", "node", "!=", "null", ")", "{", "type", ".", "setRedirect", "(", "node", ")", ";", "return", "true", ";", "}", "else", "{", "return", "false", ";", "}", "}", "@", "Override", "protected", "boolean", "resolveFromDefaultImports", "(", "ClassNode", "type", ",", "boolean", "testDefaultImports", ")", "{", "boolean", "foundit", "=", "super", ".", "resolveFromDefaultImports", "(", "type", ",", "testDefaultImports", ")", ";", "if", "(", "activeScope", "!=", "null", ")", "{", "boolean", "b", "=", "testDefaultImports", "&", "!", "type", ".", "hasPackageName", "(", ")", ";", "b", "&=", "!", "(", "type", "instanceof", "LowerCaseClass", ")", ";", "if", "(", "b", ")", "{", "String", "extraImports", "=", "activeScope", ".", "compilerOptions", "(", ")", ".", "groovyExtraImports", ";", "if", "(", "extraImports", "!=", "null", ")", "{", "try", "{", "String", "filename", "=", "new", "String", "(", "activeScope", ".", "referenceContext", ".", "getFileName", "(", ")", ")", ";", "StringTokenizer", "st", "=", "new", "StringTokenizer", "(", "extraImports", ",", "\";\"", ")", ";", "while", "(", "st", ".", "hasMoreTokens", "(", ")", ")", "{", "String", "onesuffix", "=", "st", ".", "nextToken", "(", ")", ";", "int", "equals", "=", "onesuffix", ".", "indexOf", "(", "'='", ")", ";", "boolean", "shouldApply", "=", "false", ";", "String", "imports", "=", "null", ";", "if", "(", "equals", "==", "-", "1", ")", "{", "shouldApply", "=", "true", ";", "imports", "=", "onesuffix", ";", "}", "else", "{", "String", "suffix", "=", "onesuffix", ".", "substring", "(", "0", ",", "equals", ")", ";", "shouldApply", "=", "filename", ".", "endsWith", "(", "suffix", ")", ";", "imports", "=", "onesuffix", ".", "substring", "(", "equals", "+", "1", ")", ";", "}", "StringTokenizer", "st2", "=", "new", "StringTokenizer", "(", "imports", ",", "\",\"", ")", ";", "while", "(", "st2", ".", "hasMoreTokens", "(", ")", ")", "{", "String", "nextElement", "=", "st2", ".", "nextToken", "(", ")", ";", "if", "(", "nextElement", ".", "endsWith", "(", "\".*\"", ")", ")", "{", "String", "withoutStar", "=", "nextElement", ".", "substring", "(", "0", ",", "nextElement", ".", "length", "(", ")", "-", "1", ")", ";", "ConstructedClassWithPackage", "tmp", "=", "new", "ConstructedClassWithPackage", "(", "withoutStar", ",", "type", ".", "getName", "(", ")", ")", ";", "if", "(", "resolve", "(", "tmp", ",", "false", ",", "false", ",", "false", ")", ")", "{", "type", ".", "setRedirect", "(", "tmp", ".", "redirect", "(", ")", ")", ";", "return", "true", ";", "}", "}", "else", "{", "String", "importedTypeName", "=", "nextElement", ";", "if", "(", "importedTypeName", ".", "endsWith", "(", "type", ".", "getName", "(", ")", ")", ")", "{", "int", "lastdot", "=", "importedTypeName", ".", "lastIndexOf", "(", "'.'", ")", ";", "String", "importTypeNameChopped", "=", "importedTypeName", ".", "substring", "(", "0", ",", "lastdot", "+", "1", ")", ";", "ConstructedClassWithPackage", "tmp", "=", "new", "ConstructedClassWithPackage", "(", "importTypeNameChopped", ",", "type", ".", "getName", "(", ")", ")", ";", "if", "(", "resolve", "(", "tmp", ",", "false", ",", "false", ",", "false", ")", ")", "{", "type", ".", "setRedirect", "(", "tmp", ".", "redirect", "(", ")", ")", ";", "return", "true", ";", "}", "}", "}", "}", "}", "}", "catch", "(", "Exception", "e", ")", "{", "new", "RuntimeException", "(", "\"\"", "+", "extraImports", ",", "e", ")", ".", "printStackTrace", "(", ")", ";", "}", "}", "}", "}", "recordDependency", "(", "type", ".", "getName", "(", ")", ")", ";", "if", "(", "debug", ")", "{", "log", "(", "\"\"", ",", "type", ",", "foundit", ")", ";", "}", "return", "foundit", ";", "}", "@", "Override", "protected", "boolean", "resolveFromStaticInnerClasses", "(", "ClassNode", "type", ",", "boolean", "testStaticInnerClasses", ")", "{", "boolean", "foundit", "=", "super", ".", "resolveFromStaticInnerClasses", "(", "type", ",", "testStaticInnerClasses", ")", ";", "recordDependency", "(", "type", ".", "getName", "(", ")", ")", ";", "if", "(", "debug", ")", "{", "log", "(", "\"\"", ",", "type", ",", "foundit", ")", ";", "}", "return", "foundit", ";", "}", "@", "Override", "protected", "boolean", "resolveFromClassCache", "(", "ClassNode", "type", ")", "{", "return", "false", ";", "}", "protected", "boolean", "resolveToOuter", "(", "ClassNode", "type", ")", "{", "return", "resolveToClass", "(", "type", ")", ";", "}", "protected", "boolean", "resolveToClass", "(", "ClassNode", "type", ")", "{", "String", "typename", "=", "type", ".", "getName", "(", ")", ";", "ClassNode", "node", "=", "getScope", "(", ")", ".", "lookupClassNodeForBinary", "(", "typename", ",", "this", ")", ";", "if", "(", "debug", ")", "{", "log", "(", "\"\"", ",", "type", ",", "node", "!=", "null", ")", ";", "}", "if", "(", "node", "!=", "null", ")", "{", "type", ".", "setRedirect", "(", "node", ")", ";", "return", "true", ";", "}", "GroovyClassLoader", "loader", "=", "compilationUnit", ".", "getClassLoader", "(", ")", ";", "if", "(", "loader", "instanceof", "GrapeAwareGroovyClassLoader", ")", "{", "GrapeAwareGroovyClassLoader", "gagc", "=", "(", "GrapeAwareGroovyClassLoader", ")", "loader", ";", "if", "(", "gagc", ".", "grabbed", ")", "{", "Class", "<", "?", ">", "cls", ";", "try", "{", "cls", "=", "loader", ".", "loadClass", "(", "type", ".", "getName", "(", ")", ",", "false", ",", "true", ")", ";", "}", "catch", "(", "ClassNotFoundException", "cnfe", ")", "{", "return", "false", ";", "}", "catch", "(", "CompilationFailedException", "cfe", ")", "{", "return", "false", ";", "}", "if", "(", "cls", "==", "null", ")", "{", "return", "false", ";", "}", "node", "=", "ClassHelper", ".", "make", "(", "cls", ")", ";", "type", ".", "setRedirect", "(", "node", ")", ";", "return", "true", ";", "}", "}", "return", "false", ";", "}", "@", "Override", "protected", "boolean", "resolveToScript", "(", "ClassNode", "type", ")", "{", "return", "false", ";", "}", "private", "Set", "<", "String", ">", "unresolvables", "=", "new", "HashSet", "<", "String", ">", "(", ")", ";", "@", "Override", "protected", "boolean", "resolve", "(", "ClassNode", "type", ",", "boolean", "testModuleImports", ",", "boolean", "testDefaultImports", ",", "boolean", "testStaticInnerClasses", ")", "{", "String", "name", "=", "type", ".", "getName", "(", ")", ";", "if", "(", "name", ".", "charAt", "(", "0", ")", "==", "'j'", "||", "name", ".", "length", "(", ")", "<=", "BOOLEAN_LENGTH", ")", "{", "ClassNode", "commonRedirect", "=", "commonTypes", ".", "get", "(", "type", ".", "getName", "(", ")", ")", ";", "if", "(", "commonRedirect", "!=", "null", ")", "{", "type", ".", "setRedirect", "(", "commonRedirect", ")", ";", "return", "true", ";", "}", "}", "if", "(", "unresolvables", ".", "contains", "(", "name", ")", ")", "{", "return", "false", ";", "}", "else", "{", "boolean", "b", "=", "super", ".", "resolve", "(", "type", ",", "testModuleImports", ",", "testDefaultImports", ",", "testStaticInnerClasses", ")", ";", "if", "(", "!", "b", ")", "{", "unresolvables", ".", "add", "(", "name", ")", ";", "}", "return", "b", ";", "}", "}", "public", "ClassNode", "resolve", "(", "String", "qualifiedName", ")", "{", "ClassNode", "type", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "qualifiedName", ")", ";", "if", "(", "super", ".", "resolve", "(", "type", ")", ")", "{", "return", "type", ".", "redirect", "(", ")", ";", "}", "else", "{", "return", "ClassHelper", ".", "DYNAMIC_TYPE", ";", "}", "}", "@", "Override", "protected", "boolean", "resolveToInnerEnum", "(", "ClassNode", "type", ")", "{", "if", "(", "existsAsInnerClass", "(", "type", ")", ")", "{", "return", "super", ".", "resolveToInnerEnum", "(", "type", ")", ";", "}", "return", "false", ";", "}", "@", "Override", "protected", "boolean", "resolveToInner", "(", "ClassNode", "type", ")", "{", "if", "(", "existsAsInnerClass", "(", "type", ")", ")", "{", "return", "super", ".", "resolveToInner", "(", "type", ")", ";", "}", "return", "false", ";", "}", "private", "boolean", "existsAsInnerClass", "(", "ClassNode", "type", ")", "{", "Iterator", "<", "InnerClassNode", ">", "innerClasses", "=", "currentClass", ".", "getInnerClasses", "(", ")", ";", "if", "(", "innerClasses", "!=", "null", ")", "{", "while", "(", "innerClasses", ".", "hasNext", "(", ")", ")", "{", "InnerClassNode", "innerClass", "=", "innerClasses", ".", "next", "(", ")", ";", "if", "(", "innerClass", ".", "getName", "(", ")", ".", "equals", "(", "type", ".", "getName", "(", ")", ")", ")", "{", "return", "true", ";", "}", "}", "}", "return", "false", ";", "}", "private", "void", "recordDependency", "(", "String", "typename", ")", "{", "GroovyCompilationUnitScope", "gcuScope", "=", "getScope", "(", ")", ";", "if", "(", "typename", ".", "indexOf", "(", "\".\"", ")", "!=", "-", "1", ")", "{", "gcuScope", ".", "recordQualifiedReference", "(", "CharOperation", ".", "splitOn", "(", "'.'", ",", "typename", ".", "toCharArray", "(", ")", ")", ")", ";", "}", "else", "{", "gcuScope", ".", "recordSimpleReference", "(", "typename", ".", "toCharArray", "(", ")", ")", ";", "}", "}", "ClassNode", "convertToClassNode", "(", "TypeBinding", "jdtBinding", ")", "{", "if", "(", "inProgress", ".", "containsKey", "(", "jdtBinding", ")", ")", "{", "return", "inProgress", ".", "get", "(", "jdtBinding", ")", ";", "}", "JDTClassNode", "existingNode", "=", "nodeCache", ".", "get", "(", "jdtBinding", ")", ";", "if", "(", "existingNode", "!=", "null", ")", "{", "if", "(", "debug", ")", "{", "log", "(", "\"\"", "+", "new", "String", "(", "jdtBinding", ".", "readableName", "(", ")", ")", ")", ";", "}", "return", "existingNode", ";", "}", "if", "(", "debug", ")", "{", "log", "(", "\"\"", "+", "new", "String", "(", "jdtBinding", ".", "readableName", "(", ")", ")", ")", ";", "}", "ClassNode", "jdtNode", "=", "createJDTClassNode", "(", "jdtBinding", ")", ";", "return", "jdtNode", ";", "}", "private", "ClassNode", "createJDTClassNode", "(", "TypeBinding", "jdtBinding", ")", "{", "ClassNode", "classNode", "=", "createClassNode", "(", "jdtBinding", ")", ";", "if", "(", "classNode", "instanceof", "JDTClassNode", ")", "{", "JDTClassNode", "jdtNode", "=", "(", "JDTClassNode", ")", "classNode", ";", "inProgress", ".", "put", "(", "jdtBinding", ",", "jdtNode", ")", ";", "inProgressStack", ".", "push", "(", "jdtNode", ")", ";", "jdtNode", ".", "setupGenerics", "(", ")", ";", "inProgressStack", ".", "pop", "(", ")", ";", "inProgress", ".", "remove", "(", "jdtBinding", ")", ";", "nodeCache", ".", "put", "(", "jdtBinding", ",", "jdtNode", ")", ";", "}", "return", "classNode", ";", "}", "private", "ClassNode", "createClassNode", "(", "TypeBinding", "jdtTypeBinding", ")", "{", "if", "(", "jdtTypeBinding", "instanceof", "WildcardBinding", ")", "{", "return", "createClassNodeForWildcardBinding", "(", "(", "WildcardBinding", ")", "jdtTypeBinding", ")", ";", "}", "else", "if", "(", "jdtTypeBinding", "instanceof", "BaseTypeBinding", ")", "{", "return", "createClassNodeForPrimitiveBinding", "(", "(", "BaseTypeBinding", ")", "jdtTypeBinding", ")", ";", "}", "else", "if", "(", "jdtTypeBinding", "instanceof", "ArrayBinding", ")", "{", "return", "createClassNodeForArrayBinding", "(", "(", "ArrayBinding", ")", "jdtTypeBinding", ")", ";", "}", "else", "if", "(", "jdtTypeBinding", "instanceof", "TypeVariableBinding", ")", "{", "String", "typeVariableName", "=", "new", "String", "(", "jdtTypeBinding", ".", "sourceName", "(", ")", ")", ";", "TypeVariableBinding", "typeVariableBinding", "=", "(", "TypeVariableBinding", ")", "jdtTypeBinding", ";", "if", "(", "typeVariableBinding", ".", "declaringElement", "instanceof", "SourceTypeBinding", ")", "{", "GenericsType", "[", "]", "genericTypes", "=", "typeGenericsCurrentlyActive", ".", "peek", "(", ")", ";", "GenericsType", "matchingGenericType", "=", "findMatchingGenericType", "(", "genericTypes", ",", "typeVariableName", ")", ";", "if", "(", "matchingGenericType", "!=", "null", ")", "{", "ClassNode", "newNode", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "typeVariableName", ")", ";", "newNode", ".", "setRedirect", "(", "matchingGenericType", ".", "getType", "(", ")", ")", ";", "newNode", ".", "setGenericsTypes", "(", "new", "GenericsType", "[", "]", "{", "matchingGenericType", "}", ")", ";", "newNode", ".", "setGenericsPlaceHolder", "(", "true", ")", ";", "return", "newNode", ";", "}", "if", "(", "typeVariableBinding", ".", "firstBound", "==", "null", ")", "{", "return", "ClassHelper", ".", "OBJECT_TYPE", ";", "}", "else", "{", "return", "convertToClassNode", "(", "typeVariableBinding", ".", "firstBound", ")", ";", "}", "}", "else", "if", "(", "typeVariableBinding", ".", "declaringElement", "instanceof", "BinaryTypeBinding", ")", "{", "GenericsType", "[", "]", "genericTypes", "=", "convertToClassNode", "(", "(", "(", "BinaryTypeBinding", ")", "typeVariableBinding", ".", "declaringElement", ")", ")", ".", "getGenericsTypes", "(", ")", ";", "GenericsType", "matchingGenericType", "=", "findMatchingGenericType", "(", "genericTypes", ",", "typeVariableName", ")", ";", "if", "(", "matchingGenericType", "!=", "null", ")", "{", "ClassNode", "newNode", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "typeVariableName", ")", ";", "ClassNode", "[", "]", "upper", "=", "matchingGenericType", ".", "getUpperBounds", "(", ")", ";", "if", "(", "upper", "!=", "null", "&&", "upper", ".", "length", ">", "0", ")", "{", "newNode", ".", "setRedirect", "(", "upper", "[", "0", "]", ")", ";", "}", "else", "{", "newNode", ".", "setRedirect", "(", "matchingGenericType", ".", "getType", "(", ")", ")", ";", "}", "newNode", ".", "setGenericsTypes", "(", "new", "GenericsType", "[", "]", "{", "matchingGenericType", "}", ")", ";", "newNode", ".", "setGenericsPlaceHolder", "(", "true", ")", ";", "return", "newNode", ";", "}", "throw", "new", "GroovyEclipseBug", "(", "\"\"", "+", "typeVariableBinding", ".", "declaringElement", ")", ";", "}", "else", "if", "(", "typeVariableBinding", ".", "declaringElement", "instanceof", "ParameterizedMethodBinding", "||", "typeVariableBinding", ".", "declaringElement", "instanceof", "MethodBinding", ")", "{", "GenericsType", "[", "]", "genericTypes", "=", "memberGenericsCurrentlyActive", ".", "peek", "(", ")", ";", "GenericsType", "matchingGenericType", "=", "findMatchingGenericType", "(", "genericTypes", ",", "typeVariableName", ")", ";", "if", "(", "matchingGenericType", "!=", "null", ")", "{", "ClassNode", "newNode", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "typeVariableName", ")", ";", "newNode", ".", "setRedirect", "(", "matchingGenericType", ".", "getType", "(", ")", ")", ";", "newNode", ".", "setGenericsTypes", "(", "new", "GenericsType", "[", "]", "{", "matchingGenericType", "}", ")", ";", "newNode", ".", "setGenericsPlaceHolder", "(", "true", ")", ";", "return", "newNode", ";", "}", "throw", "new", "GroovyEclipseBug", "(", "\"\"", "+", "typeVariableBinding", ".", "declaringElement", ")", ";", "}", "throw", "new", "GroovyEclipseBug", "(", "\"\"", "+", "typeVariableBinding", ".", "declaringElement", ")", ";", "}", "else", "if", "(", "jdtTypeBinding", "instanceof", "ReferenceBinding", ")", "{", "if", "(", "jdtTypeBinding", ".", "id", "==", "TypeIds", ".", "T_JavaLangObject", ")", "{", "return", "ClassHelper", ".", "OBJECT_TYPE", ";", "}", "return", "new", "JDTClassNode", "(", "(", "ReferenceBinding", ")", "jdtTypeBinding", ",", "this", ")", ";", "}", "else", "{", "throw", "new", "GroovyEclipseBug", "(", "\"\"", "+", "jdtTypeBinding", ".", "getClass", "(", ")", ")", ";", "}", "}", "private", "GenericsType", "findMatchingGenericType", "(", "GenericsType", "[", "]", "genericTypes", ",", "String", "typeVariableName", ")", "{", "if", "(", "genericTypes", "!=", "null", ")", "{", "for", "(", "GenericsType", "genericType", ":", "genericTypes", ")", "{", "if", "(", "genericType", ".", "getName", "(", ")", ".", "equals", "(", "typeVariableName", ")", ")", "{", "return", "genericType", ";", "}", "}", "}", "return", "null", ";", "}", "ClassNode", "createClassNodeForArrayBinding", "(", "ArrayBinding", "arrayBinding", ")", "{", "int", "dims", "=", "arrayBinding", ".", "dimensions", ";", "ClassNode", "classNode", "=", "convertToClassNode", "(", "arrayBinding", ".", "leafComponentType", ")", ";", "while", "(", "dims", ">", "0", ")", "{", "classNode", "=", "new", "ClassNode", "(", "classNode", ")", ";", "dims", "--", ";", "}", "return", "classNode", ";", "}", "ClassNode", "createClassNodeForPrimitiveBinding", "(", "BaseTypeBinding", "jdtBinding", ")", "{", "switch", "(", "jdtBinding", ".", "id", ")", "{", "case", "TypeIds", ".", "T_boolean", ":", "return", "ClassHelper", ".", "boolean_TYPE", ";", "case", "TypeIds", ".", "T_char", ":", "return", "ClassHelper", ".", "char_TYPE", ";", "case", "TypeIds", ".", "T_byte", ":", "return", "ClassHelper", ".", "byte_TYPE", ";", "case", "TypeIds", ".", "T_short", ":", "return", "ClassHelper", ".", "short_TYPE", ";", "case", "TypeIds", ".", "T_int", ":", "return", "ClassHelper", ".", "int_TYPE", ";", "case", "TypeIds", ".", "T_long", ":", "return", "ClassHelper", ".", "long_TYPE", ";", "case", "TypeIds", ".", "T_double", ":", "return", "ClassHelper", ".", "double_TYPE", ";", "case", "TypeIds", ".", "T_float", ":", "return", "ClassHelper", ".", "float_TYPE", ";", "case", "TypeIds", ".", "T_void", ":", "return", "ClassHelper", ".", "VOID_TYPE", ";", "default", ":", "throw", "new", "GroovyEclipseBug", "(", "\"\"", "+", "jdtBinding", ")", ";", "}", "}", "private", "ClassNode", "[", "]", "convertToClassNodes", "(", "TypeBinding", "[", "]", "typeBindings", ")", "{", "if", "(", "typeBindings", ".", "length", "==", "0", ")", "{", "return", "null", ";", "}", "ClassNode", "[", "]", "nodes", "=", "new", "ClassNode", "[", "typeBindings", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "typeBindings", ".", "length", ";", "i", "++", ")", "{", "nodes", "[", "i", "]", "=", "convertToClassNode", "(", "typeBindings", "[", "i", "]", ")", ";", "}", "return", "nodes", ";", "}", "private", "ClassNode", "createClassNodeForWildcardBinding", "(", "WildcardBinding", "wildcardBinding", ")", "{", "ClassNode", "base", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "\"?\"", ")", ";", "ClassNode", "lowerBound", "=", "null", ";", "ClassNode", "[", "]", "allUppers", "=", "null", ";", "if", "(", "wildcardBinding", ".", "boundKind", "==", "Wildcard", ".", "EXTENDS", ")", "{", "ClassNode", "firstUpper", "=", "convertToClassNode", "(", "wildcardBinding", ".", "bound", ")", ";", "ClassNode", "[", "]", "otherUppers", "=", "(", "wildcardBinding", ".", "otherBounds", "==", "null", "?", "null", ":", "convertToClassNodes", "(", "wildcardBinding", ".", "otherBounds", ")", ")", ";", "if", "(", "otherUppers", "==", "null", ")", "{", "allUppers", "=", "new", "ClassNode", "[", "]", "{", "firstUpper", "}", ";", "}", "else", "{", "allUppers", "=", "new", "ClassNode", "[", "otherUppers", ".", "length", "+", "1", "]", ";", "System", ".", "arraycopy", "(", "otherUppers", ",", "0", ",", "allUppers", ",", "1", ",", "otherUppers", ".", "length", ")", ";", "allUppers", "[", "0", "]", "=", "firstUpper", ";", "}", "}", "else", "if", "(", "wildcardBinding", ".", "boundKind", "==", "Wildcard", ".", "SUPER", ")", "{", "lowerBound", "=", "convertToClassNode", "(", "wildcardBinding", ".", "bound", ")", ";", "}", "else", "{", "assert", "(", "wildcardBinding", ".", "boundKind", "==", "Wildcard", ".", "UNBOUND", ")", ";", "return", "JDTClassNode", ".", "unboundWildcard", ";", "}", "GenericsType", "t", "=", "new", "GenericsType", "(", "base", ",", "allUppers", ",", "lowerBound", ")", ";", "t", ".", "setWildcard", "(", "true", ")", ";", "ClassNode", "ref", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "Object", ".", "class", ",", "false", ")", ";", "ref", ".", "setGenericsTypes", "(", "new", "GenericsType", "[", "]", "{", "t", "}", ")", ";", "return", "ref", ";", "}", "@", "Override", "protected", "boolean", "commencingResolution", "(", ")", "{", "GroovyTypeDeclaration", "gtDeclaration", "=", "scopes", ".", "get", "(", "this", ".", "currentClass", ")", ";", "if", "(", "gtDeclaration", "==", "null", ")", "{", "if", "(", "haveBeenResolved", ".", "contains", "(", "currentClass", ")", ")", "{", "return", "false", ";", "}", "GroovyEclipseBug", "geb", "=", "new", "GroovyEclipseBug", "(", "\"\"", "+", "currentClass", ")", ";", "geb", ".", "printStackTrace", "(", ")", ";", "throw", "geb", ";", "}", "activeScope", "=", "null", ";", "if", "(", "gtDeclaration", ".", "scope", "==", "null", ")", "{", "if", "(", "gtDeclaration", ".", "hasErrors", "(", ")", ")", "{", "return", "false", ";", "}", "GroovyEclipseBug", "geb", "=", "new", "GroovyEclipseBug", "(", "\"\"", "+", "currentClass", ".", "getName", "(", ")", ")", ";", "geb", ".", "printStackTrace", "(", ")", ";", "throw", "geb", ";", "}", "activeScope", "=", "(", "GroovyCompilationUnitScope", ")", "gtDeclaration", ".", "scope", ".", "compilationUnitScope", "(", ")", ";", "if", "(", "debug", ")", "{", "System", ".", "err", ".", "println", "(", "\"\"", "+", "this", ".", "currentClass", ".", "getName", "(", ")", ")", ";", "}", "return", "true", ";", "}", "@", "Override", "protected", "void", "finishedResolution", "(", ")", "{", "scopes", ".", "remove", "(", "this", ".", "currentClass", ")", ";", "haveBeenResolved", ".", "add", "(", "currentClass", ")", ";", "unresolvables", ".", "clear", "(", ")", ";", "}", "private", "GroovyCompilationUnitScope", "getScope", "(", ")", "{", "return", "activeScope", ";", "}", "private", "void", "log", "(", "String", "string", ")", "{", "System", ".", "err", ".", "println", "(", "\"Resolver:", "\"", "+", "string", ")", ";", "}", "public", "void", "record", "(", "GroovyTypeDeclaration", "gtDeclaration", ")", "{", "scopes", ".", "put", "(", "gtDeclaration", ".", "getClassNode", "(", ")", ",", "gtDeclaration", ")", ";", "if", "(", "gtDeclaration", ".", "memberTypes", "!=", "null", ")", "{", "TypeDeclaration", "[", "]", "members", "=", "gtDeclaration", ".", "memberTypes", ";", "for", "(", "int", "m", "=", "0", ";", "m", "<", "members", ".", "length", ";", "m", "++", ")", "{", "record", "(", "(", "GroovyTypeDeclaration", ")", "members", "[", "m", "]", ")", ";", "}", "}", "}", "private", "void", "log", "(", "String", "string", ",", "ClassNode", "type", ",", "boolean", "foundit", ")", "{", "System", ".", "err", ".", "println", "(", "\"Resolver:", "\"", "+", "string", "+", "\"", "\"", "+", "type", ".", "getName", "(", ")", "+", "\"", "?\"", "+", "foundit", ")", ";", "}", "public", "void", "startResolving", "(", "ClassNode", "node", ",", "SourceUnit", "source", ")", "{", "try", "{", "super", ".", "startResolving", "(", "node", ",", "source", ")", ";", "unresolvables", ".", "clear", "(", ")", ";", "}", "catch", "(", "AbortResolutionException", "are", ")", "{", "}", "}", "}", "</s>" ]
6,763
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GenericsType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeVariableBinding", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "LazyGenericsType", "extends", "GenericsType", "{", "private", "boolean", "initialized", "=", "false", ";", "private", "TypeVariableBinding", "tvBinding", ";", "private", "JDTResolver", "resolver", ";", "public", "LazyGenericsType", "(", "TypeVariableBinding", "typeVariableBinding", ",", "JDTResolver", "jdtResolver", ")", "{", "this", ".", "tvBinding", "=", "typeVariableBinding", ";", "this", ".", "resolver", "=", "jdtResolver", ";", "this", ".", "name", "=", "new", "String", "(", "typeVariableBinding", ".", "sourceName", ")", ";", "this", ".", "placeholder", "=", "true", ";", "}", "@", "Override", "public", "ClassNode", "getLowerBound", "(", ")", "{", "ensureInitialized", "(", ")", ";", "return", "lowerBound", ";", "}", "@", "Override", "public", "ClassNode", "getType", "(", ")", "{", "ensureInitialized", "(", ")", ";", "return", "type", ";", "}", "@", "Override", "public", "ClassNode", "[", "]", "getUpperBounds", "(", ")", "{", "ensureInitialized", "(", ")", ";", "return", "upperBounds", ";", "}", "@", "Override", "public", "boolean", "isResolved", "(", ")", "{", "return", "true", ";", "}", "@", "Override", "public", "boolean", "isWildcard", "(", ")", "{", "return", "false", ";", "}", "@", "Override", "public", "void", "setLowerBound", "(", "ClassNode", "bound", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "setName", "(", "String", "name", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "setPlaceholder", "(", "boolean", "placeholder", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "setResolved", "(", "boolean", "res", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "setType", "(", "ClassNode", "type", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "setUpperBounds", "(", "ClassNode", "[", "]", "bounds", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "void", "setWildcard", "(", "boolean", "wildcard", ")", "{", "throw", "new", "ImmutableException", "(", ")", ";", "}", "@", "Override", "public", "String", "toString", "(", ")", "{", "if", "(", "!", "initialized", ")", "{", "return", "\"\"", "+", "tvBinding", ";", "}", "else", "{", "return", "super", ".", "toString", "(", ")", ";", "}", "}", "private", "void", "ensureInitialized", "(", ")", "{", "if", "(", "!", "initialized", ")", "{", "ClassNode", "cn", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "name", ")", ";", "cn", ".", "setGenericsPlaceHolder", "(", "true", ")", ";", "ClassNode", "cn2", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "name", ")", ";", "cn2", ".", "setGenericsPlaceHolder", "(", "true", ")", ";", "GenericsType", "[", "]", "gts", "=", "new", "GenericsType", "[", "]", "{", "new", "GenericsType", "(", "cn2", ")", "}", ";", "cn", ".", "setGenericsTypes", "(", "gts", ")", ";", "cn", ".", "setRedirect", "(", "ClassHelper", ".", "OBJECT_TYPE", ")", ";", "type", "=", "cn", ";", "if", "(", "tvBinding", ".", "firstBound", "==", "null", ")", "{", "type", "=", "ClassHelper", ".", "OBJECT_TYPE", ";", "}", "else", "{", "ClassNode", "firstBoundType", "=", "resolver", ".", "convertToClassNode", "(", "tvBinding", ".", "firstBound", ")", ";", "TypeBinding", "[", "]", "otherUpperBounds", "=", "tvBinding", ".", "otherUpperBounds", "(", ")", ";", "if", "(", "otherUpperBounds", ".", "length", "==", "0", ")", "{", "upperBounds", "=", "new", "ClassNode", "[", "]", "{", "firstBoundType", "}", ";", "}", "else", "{", "ClassNode", "[", "]", "nodes", "=", "new", "ClassNode", "[", "1", "+", "otherUpperBounds", ".", "length", "]", ";", "int", "idx", "=", "0", ";", "nodes", "[", "idx", "++", "]", "=", "firstBoundType", ";", "for", "(", "TypeBinding", "typeBinding", ":", "otherUpperBounds", ")", "{", "nodes", "[", "idx", "++", "]", "=", "resolver", ".", "convertToClassNode", "(", "typeBinding", ")", ";", "}", "upperBounds", "=", "nodes", ";", "}", "}", "lowerBound", "=", "null", ";", "initialized", "=", "true", ";", "}", "}", "}", "</s>" ]
6,764
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "StringTokenizer", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "BinaryTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Binding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ClassScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "CompilationUnitScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ImportBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "LookupEnvironment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "PackageBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ProblemReasons", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ProblemReferenceBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "ReferenceBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "Scope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "SourceTypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "lookup", ".", "TypeBinding", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "AbortCompilation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "builder", ".", "AbortIncrementalBuildException", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "GroovyCompilationUnitScope", "extends", "CompilationUnitScope", "{", "private", "Map", "<", "String", ",", "ClassNode", ">", "typenameToClassNodeCache", "=", "new", "HashMap", "<", "String", ",", "ClassNode", ">", "(", ")", ";", "private", "static", "final", "char", "[", "]", "[", "]", "javaLang", ";", "private", "static", "final", "char", "[", "]", "[", "]", "javaIo", ";", "private", "static", "final", "char", "[", "]", "[", "]", "javaNet", ";", "private", "static", "final", "char", "[", "]", "[", "]", "javaUtil", ";", "private", "static", "final", "char", "[", "]", "[", "]", "groovyLang", ";", "private", "static", "final", "char", "[", "]", "[", "]", "groovyUtil", ";", "private", "static", "final", "char", "[", "]", "[", "]", "javaMathBigDecimal", ";", "private", "static", "final", "char", "[", "]", "[", "]", "javaMathBigInteger", ";", "static", "{", "javaLang", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "\"java.lang\"", ".", "toCharArray", "(", ")", ")", ";", "javaIo", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "\"java.io\"", ".", "toCharArray", "(", ")", ")", ";", "javaNet", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "\"java.net\"", ".", "toCharArray", "(", ")", ")", ";", "javaUtil", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "\"java.util\"", ".", "toCharArray", "(", ")", ")", ";", "groovyLang", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "\"groovy.lang\"", ".", "toCharArray", "(", ")", ")", ";", "groovyUtil", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "\"groovy.util\"", ".", "toCharArray", "(", ")", ")", ";", "javaMathBigDecimal", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "\"\"", ".", "toCharArray", "(", ")", ")", ";", "javaMathBigInteger", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "\"\"", ".", "toCharArray", "(", ")", ")", ";", "}", "private", "final", "static", "char", "[", "]", "GROOVY", "=", "\"groovy\"", ".", "toCharArray", "(", ")", ";", "private", "final", "static", "char", "[", "]", "LANG", "=", "\"lang\"", ".", "toCharArray", "(", ")", ";", "private", "final", "static", "char", "[", "]", "[", "]", "GROOVY_LANG_GROOVYOBJECT", "=", "{", "GROOVY", ",", "LANG", ",", "\"GroovyObject\"", ".", "toCharArray", "(", ")", "}", ";", "private", "boolean", "isScript", "=", "false", ";", "public", "GroovyCompilationUnitScope", "(", "GroovyCompilationUnitDeclaration", "compilationUnitDeclaration", ",", "LookupEnvironment", "lookupEnvironment", ")", "{", "super", "(", "compilationUnitDeclaration", ",", "lookupEnvironment", ")", ";", "}", "@", "Override", "protected", "ImportBinding", "[", "]", "getDefaultImports", "(", ")", "{", "ImportBinding", "[", "]", "defaultImports", "=", "super", ".", "getDefaultImports", "(", ")", ";", "List", "<", "ImportBinding", ">", "importBindings", "=", "new", "ArrayList", "<", "ImportBinding", ">", "(", ")", ";", "importBindings", ".", "add", "(", "defaultImports", "[", "0", "]", ")", ";", "Binding", "importBinding", "=", "environment", ".", "createPackage", "(", "javaIo", ")", ";", "importBindings", ".", "add", "(", "new", "ImportBinding", "(", "javaIo", ",", "true", ",", "importBinding", ",", "null", ")", ")", ";", "importBinding", "=", "environment", ".", "createPackage", "(", "javaNet", ")", ";", "importBindings", ".", "add", "(", "new", "ImportBinding", "(", "javaNet", ",", "true", ",", "importBinding", ",", "null", ")", ")", ";", "importBinding", "=", "environment", ".", "createPackage", "(", "javaUtil", ")", ";", "importBindings", ".", "add", "(", "new", "ImportBinding", "(", "javaUtil", ",", "true", ",", "importBinding", ",", "null", ")", ")", ";", "importBinding", "=", "environment", ".", "createPackage", "(", "groovyLang", ")", ";", "importBindings", ".", "add", "(", "new", "ImportBinding", "(", "groovyLang", ",", "true", ",", "importBinding", ",", "null", ")", ")", ";", "importBinding", "=", "environment", ".", "createPackage", "(", "groovyUtil", ")", ";", "importBindings", ".", "add", "(", "new", "ImportBinding", "(", "groovyUtil", ",", "true", ",", "importBinding", ",", "null", ")", ")", ";", "Binding", "jmBigDecimal", "=", "environment", ".", "getType", "(", "javaMathBigDecimal", ")", ";", "importBindings", ".", "add", "(", "new", "ImportBinding", "(", "javaMathBigDecimal", ",", "false", ",", "jmBigDecimal", ",", "null", ")", ")", ";", "Binding", "jmBigInteger", "=", "environment", ".", "getType", "(", "javaMathBigInteger", ")", ";", "importBindings", ".", "add", "(", "new", "ImportBinding", "(", "javaMathBigInteger", ",", "false", ",", "jmBigInteger", ",", "null", ")", ")", ";", "CompilerOptions", "co", "=", "compilerOptions", "(", ")", ";", "String", "extraImports", "=", "co", ".", "groovyExtraImports", ";", "if", "(", "extraImports", "!=", "null", ")", "{", "try", "{", "String", "filename", "=", "new", "String", "(", "this", ".", "referenceContext", ".", "getFileName", "(", ")", ")", ";", "StringTokenizer", "st", "=", "new", "StringTokenizer", "(", "extraImports", ",", "\";\"", ")", ";", "while", "(", "st", ".", "hasMoreTokens", "(", ")", ")", "{", "String", "onesuffix", "=", "st", ".", "nextToken", "(", ")", ";", "int", "equals", "=", "onesuffix", ".", "indexOf", "(", "'='", ")", ";", "boolean", "shouldApply", "=", "false", ";", "String", "imports", "=", "null", ";", "if", "(", "equals", "==", "-", "1", ")", "{", "shouldApply", "=", "true", ";", "imports", "=", "onesuffix", ";", "}", "else", "{", "String", "suffix", "=", "onesuffix", ".", "substring", "(", "0", ",", "equals", ")", ";", "shouldApply", "=", "filename", ".", "endsWith", "(", "suffix", ")", ";", "imports", "=", "onesuffix", ".", "substring", "(", "equals", "+", "1", ")", ";", "}", "StringTokenizer", "st2", "=", "new", "StringTokenizer", "(", "imports", ",", "\",\"", ")", ";", "while", "(", "st2", ".", "hasMoreTokens", "(", ")", ")", "{", "String", "nextElement", "=", "st2", ".", "nextToken", "(", ")", ";", "if", "(", "nextElement", ".", "endsWith", "(", "\".*\"", ")", ")", "{", "char", "[", "]", "withoutDotStar", "=", "nextElement", ".", "substring", "(", "0", ",", "nextElement", ".", "length", "(", ")", "-", "2", ")", ".", "toCharArray", "(", ")", ";", "char", "[", "]", "[", "]", "cs", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "withoutDotStar", ")", ";", "importBinding", "=", "environment", ".", "createPackage", "(", "cs", ")", ";", "importBindings", ".", "add", "(", "new", "ImportBinding", "(", "cs", ",", "true", ",", "importBinding", ",", "null", ")", ")", ";", "}", "else", "{", "char", "[", "]", "type", "=", "nextElement", ".", "toCharArray", "(", ")", ";", "char", "[", "]", "[", "]", "cs", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "type", ")", ";", "Binding", "typeBinding", "=", "environment", ".", "getType", "(", "cs", ")", ";", "importBindings", ".", "add", "(", "new", "ImportBinding", "(", "cs", ",", "false", ",", "typeBinding", ",", "null", ")", ")", ";", "}", "}", "}", "}", "catch", "(", "Exception", "e", ")", "{", "new", "RuntimeException", "(", "\"\"", "+", "extraImports", ",", "e", ")", ".", "printStackTrace", "(", ")", ";", "}", "}", "return", "importBindings", ".", "toArray", "(", "new", "ImportBinding", "[", "importBindings", ".", "size", "(", ")", "]", ")", ";", "}", "@", "Override", "protected", "ClassScope", "buildClassScope", "(", "Scope", "parent", ",", "TypeDeclaration", "typeDecl", ")", "{", "return", "new", "GroovyClassScope", "(", "parent", ",", "typeDecl", ")", ";", "}", "@", "Override", "public", "void", "augmentTypeHierarchy", "(", ")", "{", "for", "(", "int", "i", "=", "0", ",", "length", "=", "topLevelTypes", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "augmentTypeHierarchy", "(", "topLevelTypes", "[", "i", "]", ")", ";", "}", "}", "private", "void", "augmentTypeHierarchy", "(", "SourceTypeBinding", "typeBinding", ")", "{", "if", "(", "typeBinding", ".", "isAnnotationType", "(", ")", "||", "typeBinding", ".", "isInterface", "(", ")", ")", "{", "return", ";", "}", "ReferenceBinding", "groovyLangObjectBinding", "=", "getGroovyLangObjectBinding", "(", ")", ";", "if", "(", "!", "typeBinding", ".", "implementsInterface", "(", "groovyLangObjectBinding", ",", "true", ")", ")", "{", "ReferenceBinding", "[", "]", "superInterfaceBindings", "=", "typeBinding", ".", "superInterfaces", ";", "if", "(", "superInterfaceBindings", "!=", "null", ")", "{", "int", "count", "=", "superInterfaceBindings", ".", "length", ";", "System", ".", "arraycopy", "(", "superInterfaceBindings", ",", "0", ",", "superInterfaceBindings", "=", "new", "ReferenceBinding", "[", "count", "+", "1", "]", ",", "0", ",", "count", ")", ";", "superInterfaceBindings", "[", "count", "]", "=", "groovyLangObjectBinding", ";", "typeBinding", ".", "superInterfaces", "=", "superInterfaceBindings", ";", "}", "}", "}", "private", "final", "ReferenceBinding", "getGroovyLangObjectBinding", "(", ")", "{", "CompilationUnitScope", "unitScope", "=", "compilationUnitScope", "(", ")", ";", "unitScope", ".", "recordQualifiedReference", "(", "GROOVY_LANG_GROOVYOBJECT", ")", ";", "return", "unitScope", ".", "environment", ".", "getResolvedType", "(", "GROOVY_LANG_GROOVYOBJECT", ",", "this", ")", ";", "}", "public", "ClassNode", "lookupClassNodeForSource", "(", "String", "typename", ",", "JDTResolver", "jdtResolver", ")", "{", "ClassNode", "node", "=", "typenameToClassNodeCache", ".", "get", "(", "typename", ")", ";", "if", "(", "node", "!=", "null", ")", "{", "return", "node", ";", "}", "char", "[", "]", "[", "]", "compoundName", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "typename", ".", "toCharArray", "(", ")", ")", ";", "TypeBinding", "jdtBinding", "=", "null", ";", "try", "{", "jdtBinding", "=", "getType", "(", "compoundName", ",", "compoundName", ".", "length", ")", ";", "}", "catch", "(", "AbortCompilation", "t", ")", "{", "if", "(", "t", ".", "silentException", "instanceof", "AbortIncrementalBuildException", ")", "{", "jdtBinding", "=", "null", ";", "}", "else", "{", "throw", "t", ";", "}", "}", "if", "(", "jdtBinding", "!=", "null", ")", "{", "if", "(", "jdtBinding", "instanceof", "SourceTypeBinding", ")", "{", "ClassNode", "classNode", "=", "jdtResolver", ".", "convertToClassNode", "(", "jdtBinding", ")", ";", "if", "(", "classNode", "!=", "null", ")", "{", "typenameToClassNodeCache", ".", "put", "(", "typename", ",", "classNode", ")", ";", "}", "return", "classNode", ";", "}", "else", "if", "(", "jdtBinding", "instanceof", "BinaryTypeBinding", ")", "{", "ClassNode", "newNode", "=", "jdtResolver", ".", "convertToClassNode", "(", "jdtBinding", ")", ";", "if", "(", "newNode", "!=", "null", ")", "{", "typenameToClassNodeCache", ".", "put", "(", "typename", ",", "newNode", ")", ";", "}", "return", "newNode", ";", "}", "}", "if", "(", "jdtBinding", "!=", "null", "&&", "(", "jdtBinding", "instanceof", "ProblemReferenceBinding", ")", ")", "{", "ProblemReferenceBinding", "prBinding", "=", "(", "ProblemReferenceBinding", ")", "jdtBinding", ";", "if", "(", "prBinding", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "InternalNameProvided", ")", "{", "jdtBinding", "=", "prBinding", ".", "closestMatch", "(", ")", ";", "if", "(", "jdtBinding", "!=", "null", "&&", "(", "jdtBinding", "instanceof", "SourceTypeBinding", ")", ")", "{", "return", "jdtResolver", ".", "convertToClassNode", "(", "jdtBinding", ")", ";", "}", "if", "(", "jdtBinding", "!=", "null", "&&", "(", "jdtBinding", "instanceof", "BinaryTypeBinding", ")", ")", "{", "return", "jdtResolver", ".", "convertToClassNode", "(", "jdtBinding", ")", ";", "}", "}", "}", "return", "null", ";", "}", "public", "ClassNode", "lookupClassNodeForBinary", "(", "String", "typename", ",", "JDTResolver", "jdtResolver", ")", "{", "char", "[", "]", "[", "]", "compoundName", "=", "CharOperation", ".", "splitOn", "(", "'.'", ",", "typename", ".", "toCharArray", "(", ")", ")", ";", "TypeBinding", "jdtBinding", "=", "getType", "(", "compoundName", ",", "compoundName", ".", "length", ")", ";", "if", "(", "jdtBinding", "!=", "null", "&&", "(", "jdtBinding", "instanceof", "BinaryTypeBinding", ")", ")", "{", "ClassNode", "classNode", "=", "jdtResolver", ".", "convertToClassNode", "(", "jdtBinding", ")", ";", "return", "classNode", ";", "}", "if", "(", "jdtBinding", "!=", "null", "&&", "(", "jdtBinding", "instanceof", "ProblemReferenceBinding", ")", ")", "{", "ProblemReferenceBinding", "prBinding", "=", "(", "ProblemReferenceBinding", ")", "jdtBinding", ";", "if", "(", "prBinding", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "InternalNameProvided", ")", "{", "jdtBinding", "=", "prBinding", ".", "closestMatch", "(", ")", ";", "if", "(", "jdtBinding", "!=", "null", "&&", "(", "jdtBinding", "instanceof", "BinaryTypeBinding", ")", ")", "{", "return", "jdtResolver", ".", "convertToClassNode", "(", "jdtBinding", ")", ";", "}", "}", "}", "return", "null", ";", "}", "@", "Override", "protected", "void", "checkPublicTypeNameMatchesFilename", "(", "TypeDeclaration", "typeDecl", ")", "{", "}", "@", "Override", "protected", "void", "recordImportProblem", "(", "ImportReference", "importReference", ",", "Binding", "importBinding", ")", "{", "}", "@", "Override", "protected", "boolean", "reportPackageIsNotExpectedPackage", "(", "CompilationUnitDeclaration", "compUnitDecl", ")", "{", "if", "(", "compUnitDecl", "!=", "null", "&&", "compUnitDecl", ".", "compilationResult", "!=", "null", "&&", "compUnitDecl", ".", "compilationResult", ".", "compilationUnit", "!=", "null", ")", "{", "char", "[", "]", "[", "]", "packageName", "=", "compUnitDecl", ".", "compilationResult", ".", "compilationUnit", ".", "getPackageName", "(", ")", ";", "String", "shouldBe", "=", "packageName", "==", "null", "?", "\"\"", ":", "CharOperation", ".", "toString", "(", "packageName", ")", ";", "String", "actuallyIs", "=", "compUnitDecl", ".", "currentPackage", "==", "null", "?", "\"\"", ":", "CharOperation", ".", "toString", "(", "compUnitDecl", ".", "currentPackage", ".", "tokens", ")", ";", "if", "(", "actuallyIs", ".", "length", "(", ")", ">", "0", "&&", "!", "shouldBe", ".", "equals", "(", "actuallyIs", ")", ")", "{", "problemReporter", "(", ")", ".", "packageIsNotExpectedPackage", "(", "compUnitDecl", ")", ";", "return", "true", ";", "}", "}", "return", "false", ";", "}", "@", "Override", "protected", "void", "checkParameterizedTypes", "(", ")", "{", "}", "@", "Override", "public", "boolean", "reportInvalidType", "(", "TypeReference", "typeReference", ",", "TypeBinding", "resolvedType", ")", "{", "if", "(", "resolvedType", "instanceof", "ProblemReferenceBinding", ")", "{", "ProblemReferenceBinding", "problemRefBinding", "=", "(", "ProblemReferenceBinding", ")", "resolvedType", ";", "if", "(", "problemRefBinding", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "Ambiguous", ")", "{", "return", "true", ";", "}", "}", "return", "false", ";", "}", "@", "Override", "protected", "void", "reportImportProblem", "(", "ImportReference", "importReference", ",", "Binding", "importBinding", ")", "{", "if", "(", "importBinding", "instanceof", "ProblemReferenceBinding", ")", "{", "ProblemReferenceBinding", "problemRefBinding", "=", "(", "ProblemReferenceBinding", ")", "importBinding", ";", "if", "(", "problemRefBinding", ".", "problemId", "(", ")", "==", "ProblemReasons", ".", "NotFound", ")", "{", "return", ";", "}", "}", "problemReporter", "(", ")", ".", "importProblem", "(", "importReference", ",", "importBinding", ")", ";", "}", "@", "Override", "public", "boolean", "canSeeEverything", "(", ")", "{", "return", "true", ";", "}", "@", "Override", "public", "boolean", "checkTargetCompatibility", "(", ")", "{", "return", "false", ";", "}", "@", "Override", "protected", "boolean", "canBeSeenBy", "(", "ReferenceBinding", "type", ",", "PackageBinding", "fPackage", ")", "{", "return", "true", ";", "}", "@", "Override", "public", "boolean", "scannerAvailable", "(", ")", "{", "return", "false", ";", "}", "public", "void", "setIsScript", "(", "boolean", "isScript", ")", "{", "this", ".", "isScript", "=", "isScript", ";", "}", "public", "boolean", "isScript", "(", ")", "{", "return", "isScript", ";", "}", "public", "ReferenceBinding", "selectBinding", "(", "ReferenceBinding", "newlyFound", ",", "ReferenceBinding", "originallyFound", ",", "boolean", "isDeclaredImport", ")", "{", "if", "(", "isDeclaredImport", ")", "{", "if", "(", "originallyFound", ".", "fPackage", "!=", "null", ")", "{", "char", "[", "]", "[", "]", "packageName", "=", "originallyFound", ".", "fPackage", ".", "compoundName", ";", "if", "(", "CharOperation", ".", "equals", "(", "javaLang", ",", "packageName", ")", "||", "CharOperation", ".", "equals", "(", "javaIo", ",", "packageName", ")", "||", "CharOperation", ".", "equals", "(", "javaNet", ",", "packageName", ")", "||", "CharOperation", ".", "equals", "(", "javaUtil", ",", "packageName", ")", "||", "CharOperation", ".", "equals", "(", "groovyLang", ",", "packageName", ")", "||", "CharOperation", ".", "equals", "(", "groovyUtil", ",", "packageName", ")", ")", "{", "return", "newlyFound", ";", "}", "else", "{", "return", "originallyFound", ";", "}", "}", "}", "return", "null", ";", "}", "}", "</s>" ]
6,765
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ";", "public", "class", "ImmutableException", "extends", "IllegalStateException", "{", "private", "static", "final", "long", "serialVersionUID", "=", "1L", ";", "}", "</s>" ]
6,766
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "core", ".", "dom", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "AST", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "ASTVisitor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "CompilationUnit", ";", "public", "class", "GroovyCompilationUnit", "extends", "CompilationUnit", "{", "public", "GroovyCompilationUnit", "(", "AST", "ast", ")", "{", "super", "(", "ast", ")", ";", "}", "@", "Override", "protected", "void", "accept0", "(", "ASTVisitor", "visitor", ")", "{", "String", "visitorName", "=", "visitor", ".", "getClass", "(", ")", ".", "getName", "(", ")", ";", "if", "(", "visitorName", ".", "equals", "(", "\"\"", ")", ")", "{", "return", ";", "}", "super", ".", "accept0", "(", "visitor", ")", ";", "}", "}", "</s>" ]
6,767
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "SourceElementParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnitElementInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnitStructureRequestor", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "class", "GroovyCompilationUnitStructureRequestor", "extends", "CompilationUnitStructureRequestor", "{", "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "protected", "GroovyCompilationUnitStructureRequestor", "(", "ICompilationUnit", "unit", ",", "CompilationUnitElementInfo", "unitInfo", ",", "Map", "newElements", ")", "{", "super", "(", "unit", ",", "unitInfo", ",", "newElements", ")", ";", "}", "void", "setParser", "(", "SourceElementParser", "parser", ")", "{", "this", ".", "parser", "=", "parser", ";", "}", "}", "</s>" ]
6,768
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ModuleNode", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyCompilationUnitDeclaration", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "JDTResolver", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Platform", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ReflectionUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaModelManager", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaModelManager", ".", "PerWorkingCopyInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "ModuleNodeMapper", "{", "public", "class", "ModuleNodeInfo", "{", "public", "ModuleNodeInfo", "(", "ModuleNode", "module", ",", "JDTResolver", "resolver", ")", "{", "this", ".", "module", "=", "module", ";", "this", ".", "resolver", "=", "resolver", ";", "}", "public", "final", "ModuleNode", "module", ";", "public", "final", "JDTResolver", "resolver", ";", "}", "private", "static", "final", "ModuleNodeMapper", "INSTANCE", "=", "new", "ModuleNodeMapper", "(", ")", ";", "static", "ModuleNodeMapper", "getInstance", "(", ")", "{", "return", "INSTANCE", ";", "}", "private", "final", "Map", "<", "PerWorkingCopyInfo", ",", "ModuleNodeInfo", ">", "infoToModuleMap", "=", "new", "HashMap", "<", "PerWorkingCopyInfo", ",", "ModuleNodeInfo", ">", "(", ")", ";", "synchronized", "void", "store", "(", "PerWorkingCopyInfo", "info", ",", "ModuleNode", "module", ",", "JDTResolver", "resolver", ")", "{", "sweepAndPurgeModuleNodes", "(", ")", ";", "infoToModuleMap", ".", "put", "(", "info", ",", "new", "ModuleNodeInfo", "(", "module", ",", "shouldStoreResovler", "(", ")", "?", "resolver", ":", "null", ")", ")", ";", "}", "private", "final", "static", "boolean", "DSL_BUNDLE_INSTALLED", ";", "static", "{", "boolean", "result", "=", "false", ";", "try", "{", "result", "=", "Platform", ".", "getBundle", "(", "\"\"", ")", "!=", "null", ";", "}", "catch", "(", "Exception", "e", ")", "{", "Util", ".", "log", "(", "e", ")", ";", "}", "DSL_BUNDLE_INSTALLED", "=", "result", ";", "}", "private", "boolean", "shouldStoreResovler", "(", ")", "{", "return", "DSL_BUNDLE_INSTALLED", ";", "}", "synchronized", "ModuleNode", "getModule", "(", "PerWorkingCopyInfo", "info", ")", "{", "ModuleNodeInfo", "moduleNodeInfo", "=", "get", "(", "info", ")", ";", "return", "moduleNodeInfo", "!=", "null", "?", "moduleNodeInfo", ".", "module", ":", "null", ";", "}", "synchronized", "ModuleNodeInfo", "get", "(", "PerWorkingCopyInfo", "info", ")", "{", "sweepAndPurgeModuleNodes", "(", ")", ";", "return", "infoToModuleMap", ".", "get", "(", "info", ")", ";", "}", "synchronized", "JDTResolver", "getResolver", "(", "PerWorkingCopyInfo", "info", ")", "{", "ModuleNodeInfo", "moduleNodeInfo", "=", "get", "(", "info", ")", ";", "return", "moduleNodeInfo", "!=", "null", "?", "moduleNodeInfo", ".", "resolver", ":", "null", ";", "}", "synchronized", "ModuleNode", "remove", "(", "PerWorkingCopyInfo", "info", ")", "{", "sweepAndPurgeModuleNodes", "(", ")", ";", "ModuleNodeInfo", "removed", "=", "infoToModuleMap", ".", "remove", "(", "info", ")", ";", "return", "removed", "!=", "null", "?", "removed", ".", "module", ":", "null", ";", "}", "synchronized", "protected", "void", "maybeCacheModuleNode", "(", "JavaModelManager", ".", "PerWorkingCopyInfo", "perWorkingCopyInfo", ",", "GroovyCompilationUnitDeclaration", "compilationUnitDeclaration", ")", "{", "if", "(", "perWorkingCopyInfo", "!=", "null", "&&", "compilationUnitDeclaration", "!=", "null", ")", "{", "ModuleNode", "module", "=", "compilationUnitDeclaration", ".", "getModuleNode", "(", ")", ";", "if", "(", "module", "!=", "null", ")", "{", "JDTResolver", "resolver", ";", "if", "(", "shouldStoreResovler", "(", ")", ")", "{", "resolver", "=", "(", "JDTResolver", ")", "compilationUnitDeclaration", ".", "getCompilationUnit", "(", ")", ".", "getResolveVisitor", "(", ")", ";", "}", "else", "{", "resolver", "=", "null", ";", "}", "ModuleNodeMapper", ".", "getInstance", "(", ")", ".", "store", "(", "perWorkingCopyInfo", ",", "module", ",", "resolver", ")", ";", "}", "}", "}", "public", "static", "boolean", "isEmpty", "(", ")", "{", "return", "INSTANCE", ".", "infoToModuleMap", ".", "isEmpty", "(", ")", ";", "}", "synchronized", "void", "sweepAndPurgeModuleNodes", "(", ")", "{", "if", "(", "System", ".", "getProperty", "(", "\"\"", ")", "==", "null", ")", "{", "return", ";", "}", "List", "<", "PerWorkingCopyInfo", ">", "toPurge", "=", "new", "ArrayList", "<", "PerWorkingCopyInfo", ">", "(", ")", ";", "for", "(", "PerWorkingCopyInfo", "info", ":", "infoToModuleMap", ".", "keySet", "(", ")", ")", "{", "int", "useCount", "=", "(", "(", "Integer", ")", "ReflectionUtils", ".", "getPrivateField", "(", "PerWorkingCopyInfo", ".", "class", ",", "\"useCount\"", ",", "info", ")", ")", ".", "intValue", "(", ")", ";", "if", "(", "useCount", "<=", "0", ")", "{", "String", "message", "=", "\"\"", "+", "info", ".", "getWorkingCopy", "(", ")", ".", "getElementName", "(", ")", ";", "System", ".", "out", ".", "println", "(", "message", ")", ";", "Util", ".", "log", "(", "new", "RuntimeException", "(", "message", ")", ",", "message", ")", ";", "toPurge", ".", "add", "(", "info", ")", ";", "}", "else", "if", "(", "useCount", ">", "1", ")", "{", "System", ".", "out", ".", "println", "(", "info", ".", "getWorkingCopy", "(", ")", ".", "getElementName", "(", ")", "+", "\"\"", "+", "useCount", ")", ";", "}", "}", "if", "(", "toPurge", ".", "size", "(", ")", ">", "0", ")", "{", "for", "(", "PerWorkingCopyInfo", "info", ":", "toPurge", ")", "{", "infoToModuleMap", ".", "remove", "(", "info", ")", ";", "}", "}", "}", "}", "</s>" ]
6,769
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "WorkingCopyOwner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "ClassFile", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "PackageFragment", ";", "public", "class", "GroovyClassFile", "extends", "ClassFile", "{", "protected", "GroovyClassFile", "(", "PackageFragment", "parent", ",", "String", "nameWithoutExtension", ")", "{", "super", "(", "parent", ",", "nameWithoutExtension", ")", ";", "}", "@", "Override", "protected", "IJavaElement", "[", "]", "codeSelect", "(", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", "cu", ",", "int", "offset", ",", "int", "length", ",", "WorkingCopyOwner", "o", ")", "throws", "JavaModelException", "{", "if", "(", "CodeSelectHelperFactory", ".", "selectHelper", "!=", "null", ")", "{", "}", "return", "new", "IJavaElement", "[", "0", "]", ";", "}", "}", "</s>" ]
6,770
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ModuleNode", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyCompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "WorkingCopyOwner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "AST", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnitProblemFinder", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaElementDelta", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaModelManager", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "ReconcileWorkingCopyOperation", ";", "public", "class", "GroovyReconcileWorkingCopyOperation", "extends", "ReconcileWorkingCopyOperation", "{", "WorkingCopyOwner", "workingCopyOwner", ";", "public", "GroovyReconcileWorkingCopyOperation", "(", "IJavaElement", "workingCopy", ",", "int", "astLevel", ",", "int", "reconcileFlags", ",", "WorkingCopyOwner", "workingCopyOwner", ")", "{", "super", "(", "workingCopy", ",", "astLevel", ",", "reconcileFlags", ",", "workingCopyOwner", ")", ";", "this", ".", "workingCopyOwner", "=", "workingCopyOwner", ";", "}", "public", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "CompilationUnit", "makeConsistent", "(", "CompilationUnit", "workingCopy", ")", "throws", "JavaModelException", "{", "if", "(", "!", "workingCopy", ".", "isConsistent", "(", ")", ")", "{", "if", "(", "this", ".", "problems", "==", "null", ")", "this", ".", "problems", "=", "new", "HashMap", "(", ")", ";", "this", ".", "resolveBindings", "=", "this", ".", "requestorIsActive", ";", "this", ".", "ast", "=", "workingCopy", ".", "makeConsistent", "(", "this", ".", "astLevel", ",", "this", ".", "resolveBindings", ",", "this", ".", "reconcileFlags", ",", "this", ".", "problems", ",", "this", ".", "progressMonitor", ")", ";", "this", ".", "deltaBuilder", ".", "buildDeltas", "(", ")", ";", "if", "(", "this", ".", "ast", "!=", "null", "&&", "this", ".", "deltaBuilder", ".", "delta", "!=", "null", ")", "this", ".", "deltaBuilder", ".", "delta", ".", "changedAST", "(", "this", ".", "ast", ")", ";", "return", "this", ".", "ast", ";", "}", "if", "(", "this", ".", "ast", "!=", "null", ")", "return", "this", ".", "ast", ";", "CompilationUnitDeclaration", "unit", "=", "null", ";", "try", "{", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "abortOnMissingSource", ".", "set", "(", "Boolean", ".", "TRUE", ")", ";", "CompilationUnit", "source", "=", "workingCopy", ".", "cloneCachingContents", "(", ")", ";", "if", "(", "JavaProject", ".", "hasJavaNature", "(", "workingCopy", ".", "getJavaProject", "(", ")", ".", "getProject", "(", ")", ")", "&&", "(", "this", ".", "reconcileFlags", "&", "ICompilationUnit", ".", "FORCE_PROBLEM_DETECTION", ")", "!=", "0", ")", "{", "this", ".", "resolveBindings", "=", "this", ".", "requestorIsActive", ";", "if", "(", "this", ".", "problems", "==", "null", ")", "this", ".", "problems", "=", "new", "HashMap", "(", ")", ";", "unit", "=", "CompilationUnitProblemFinder", ".", "process", "(", "source", ",", "this", ".", "workingCopyOwner", ",", "this", ".", "problems", ",", "this", ".", "astLevel", "!=", "ICompilationUnit", ".", "NO_AST", ",", "this", ".", "reconcileFlags", ",", "this", ".", "progressMonitor", ")", ";", "if", "(", "unit", "instanceof", "GroovyCompilationUnitDeclaration", ")", "{", "ModuleNodeMapper", ".", "getInstance", "(", ")", ".", "maybeCacheModuleNode", "(", "workingCopy", ".", "getPerWorkingCopyInfo", "(", ")", ",", "(", "GroovyCompilationUnitDeclaration", ")", "unit", ")", ";", "}", "if", "(", "this", ".", "progressMonitor", "!=", "null", ")", "this", ".", "progressMonitor", ".", "worked", "(", "1", ")", ";", "}", "if", "(", "this", ".", "astLevel", "!=", "ICompilationUnit", ".", "NO_AST", "&&", "unit", "!=", "null", ")", "{", "Map", "options", "=", "workingCopy", ".", "getJavaProject", "(", ")", ".", "getOptions", "(", "true", ")", ";", "this", ".", "ast", "=", "AST", ".", "convertCompilationUnit", "(", "this", ".", "astLevel", ",", "unit", ",", "options", ",", "this", ".", "resolveBindings", ",", "source", ",", "this", ".", "reconcileFlags", ",", "this", ".", "progressMonitor", ")", ";", "if", "(", "this", ".", "ast", "!=", "null", ")", "{", "if", "(", "this", ".", "deltaBuilder", ".", "delta", "==", "null", ")", "{", "this", ".", "deltaBuilder", ".", "delta", "=", "new", "JavaElementDelta", "(", "workingCopy", ")", ";", "}", "this", ".", "deltaBuilder", ".", "delta", ".", "changedAST", "(", "this", ".", "ast", ")", ";", "}", "if", "(", "this", ".", "progressMonitor", "!=", "null", ")", "this", ".", "progressMonitor", ".", "worked", "(", "1", ")", ";", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "if", "(", "JavaProject", ".", "hasJavaNature", "(", "workingCopy", ".", "getJavaProject", "(", ")", ".", "getProject", "(", ")", ")", ")", "throw", "e", ";", "}", "finally", "{", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ".", "abortOnMissingSource", ".", "set", "(", "null", ")", ";", "if", "(", "unit", "!=", "null", ")", "{", "unit", ".", "cleanUp", "(", ")", ";", "}", "}", "return", "this", ".", "ast", ";", "}", "}", "</s>" ]
6,771
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IConfigurationElement", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IExtension", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IExtensionPoint", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Platform", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "public", "interface", "ICodeSelectHelper", "{", "public", "IJavaElement", "[", "]", "select", "(", "GroovyCompilationUnit", "unit", ",", "int", "start", ",", "int", "length", ")", ";", "}", "class", "CodeSelectHelperFactory", "{", "private", "final", "static", "String", "CODE_SELECT_HELPER_EXTENSION", "=", "\"\"", ";", "static", "ICodeSelectHelper", "selectHelper", ";", "static", "{", "IExtensionPoint", "extPoint", "=", "Platform", ".", "getExtensionRegistry", "(", ")", ".", "getExtensionPoint", "(", "CODE_SELECT_HELPER_EXTENSION", ")", ";", "IExtension", "[", "]", "exts", "=", "extPoint", ".", "getExtensions", "(", ")", ";", "if", "(", "exts", ".", "length", "<", "1", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"\"", ")", ";", "}", "else", "if", "(", "exts", ".", "length", ">", "1", ")", "{", "StringBuilder", "sb", "=", "new", "StringBuilder", "(", ")", ";", "sb", ".", "append", "(", "\"\"", ")", ";", "for", "(", "IExtension", "ext", ":", "exts", ")", "{", "sb", ".", "append", "(", "\"", "\"", "+", "ext", ".", "getNamespaceIdentifier", "(", ")", "+", "\".\"", "+", "ext", ".", "getSimpleIdentifier", "(", ")", ")", ";", "}", "throw", "new", "IllegalArgumentException", "(", "sb", ".", "toString", "(", ")", ")", ";", "}", "IConfigurationElement", "[", "]", "elts", "=", "exts", "[", "0", "]", ".", "getConfigurationElements", "(", ")", ";", "if", "(", "elts", ".", "length", "<", "1", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"\"", ")", ";", "}", "else", "if", "(", "elts", ".", "length", ">", "1", ")", "{", "StringBuilder", "sb", "=", "new", "StringBuilder", "(", ")", ";", "sb", ".", "append", "(", "\"\"", ")", ";", "for", "(", "IConfigurationElement", "elt", ":", "elts", ")", "{", "sb", ".", "append", "(", "\"", "\"", "+", "elt", ".", "getNamespaceIdentifier", "(", ")", ")", ";", "}", "throw", "new", "IllegalArgumentException", "(", "sb", ".", "toString", "(", ")", ")", ";", "}", "try", "{", "selectHelper", "=", "(", "ICodeSelectHelper", ")", "elts", "[", "0", "]", ".", "createExecutableExtension", "(", "\"class\"", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "throw", "new", "IllegalArgumentException", "(", "e", ")", ";", "}", "}", "public", "static", "void", "setSelectHelper", "(", "ICodeSelectHelper", "newSelectHelper", ")", "{", "selectHelper", "=", "newSelectHelper", ";", "}", "}", "</s>" ]
6,772
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProjectNature", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IncrementalProjectBuilder", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "ResourcesPlugin", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "WorkspaceJob", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IStatus", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Status", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "jobs", ".", "Job", ";", "public", "class", "GroovyNature", "implements", "IProjectNature", "{", "private", "IProject", "project", ";", "public", "static", "final", "String", "GROOVY_NATURE", "=", "\"\"", ";", "public", "static", "void", "configure", "(", "final", "IProject", "project", ")", "throws", "CoreException", "{", "cleanAndRebuildProject", "(", "project", ")", ";", "}", "public", "static", "void", "deconfigure", "(", "final", "IProject", "project", ")", "throws", "CoreException", "{", "cleanAndRebuildProject", "(", "project", ")", ";", "}", "private", "static", "void", "cleanAndRebuildProject", "(", "final", "IProject", "project", ")", "{", "if", "(", "project", "==", "null", "||", "!", "project", ".", "isAccessible", "(", ")", ")", "return", ";", "final", "Job", "[", "]", "existingJob", "=", "Job", ".", "getJobManager", "(", ")", ".", "find", "(", "project", ")", ";", "if", "(", "existingJob", "!=", "null", "&&", "existingJob", ".", "length", ">", "0", ")", "return", ";", "final", "WorkspaceJob", "job", "=", "new", "WorkspaceJob", "(", "\"\"", "+", "project", ".", "getName", "(", ")", ")", "{", "@", "Override", "public", "IStatus", "runInWorkspace", "(", "final", "IProgressMonitor", "monitor", ")", "throws", "CoreException", "{", "project", ".", "build", "(", "IncrementalProjectBuilder", ".", "CLEAN_BUILD", ",", "monitor", ")", ";", "if", "(", "!", "ResourcesPlugin", ".", "getWorkspace", "(", ")", ".", "isAutoBuilding", "(", ")", ")", "project", ".", "build", "(", "IncrementalProjectBuilder", ".", "FULL_BUILD", ",", "monitor", ")", ";", "return", "Status", ".", "OK_STATUS", ";", "}", "@", "Override", "public", "boolean", "belongsTo", "(", "final", "Object", "family", ")", "{", "if", "(", "family", "instanceof", "IProject", ")", "return", "project", ".", "getName", "(", ")", ".", "equals", "(", "(", "(", "IProject", ")", "family", ")", ".", "getName", "(", ")", ")", ";", "return", "super", ".", "belongsTo", "(", "family", ")", ";", "}", "}", ";", "job", ".", "setRule", "(", "ResourcesPlugin", ".", "getWorkspace", "(", ")", ".", "getRoot", "(", ")", ")", ";", "job", ".", "schedule", "(", ")", ";", "}", "public", "void", "configure", "(", ")", "throws", "CoreException", "{", "configure", "(", "getProject", "(", ")", ")", ";", "}", "public", "void", "deconfigure", "(", ")", "throws", "CoreException", "{", "deconfigure", "(", "getProject", "(", ")", ")", ";", "}", "public", "IProject", "getProject", "(", ")", "{", "return", "project", ";", "}", "public", "void", "setProject", "(", "IProject", "project", ")", "{", "this", ".", "project", "=", "project", ";", "}", "public", "static", "boolean", "hasGroovyNature", "(", "IProject", "project", ")", "{", "try", "{", "return", "project", ".", "hasNature", "(", "GROOVY_NATURE", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "}", "return", "false", ";", "}", "public", "static", "List", "<", "IProject", ">", "getAllAccessibleGroovyProjects", "(", ")", "{", "IProject", "[", "]", "projects", "=", "ResourcesPlugin", ".", "getWorkspace", "(", ")", ".", "getRoot", "(", ")", ".", "getProjects", "(", ")", ";", "List", "<", "IProject", ">", "groovyProjects", "=", "new", "ArrayList", "<", "IProject", ">", "(", ")", ";", "if", "(", "projects", "!=", "null", ")", "{", "for", "(", "IProject", "project", ":", "projects", ")", "{", "if", "(", "project", ".", "isAccessible", "(", ")", "&&", "hasGroovyNature", "(", "project", ")", ")", "{", "groovyProjects", ".", "add", "(", "project", ")", ";", "}", "}", "}", "return", "groovyProjects", ";", "}", "}", "</s>" ]
6,773
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ASTVisitor", ";", "public", "class", "ASTNodeLocationsChecker", "extends", "ASTVisitor", "{", "}", "</s>" ]
6,774
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "CompletionRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ITypeRoot", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "WorkingCopyOwner", ";", "public", "interface", "ICodeCompletionDelegate", "{", "void", "codeComplete", "(", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", "cu", ",", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", "unitToSkip", ",", "int", "position", ",", "CompletionRequestor", "requestor", ",", "WorkingCopyOwner", "owner", ",", "ITypeRoot", "typeRoot", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", ";", "boolean", "shouldCodeComplete", "(", "CompletionRequestor", "requestor", ",", "ITypeRoot", "typeRoot", ")", ";", "}", "</s>" ]
6,775
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ModuleNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "eclipse", ".", "GroovyLogManager", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "eclipse", ".", "TraceCategory", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ".", "MultiplexingSourceElementRequestorParser", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyCompilationUnitDeclaration", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ".", "ModuleNodeMapper", ".", "ModuleNodeInfo", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IResource", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Assert", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "NullProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "OperationCanceledException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "PerformanceStats", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "CompletionRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IBuffer", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaModelStatusConstants", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ITypeRoot", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaCore", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "WorkingCopyOwner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CategorizedProblem", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "AST", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "util", ".", "CompilerUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ReflectionUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "IErrorHandlingPolicy", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "IProblemFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "SourceElementParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "DefaultProblemFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "ASTHolderCUInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnitElementInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnitProblemFinder", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "DefaultWorkingCopyOwner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaModelManager", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaModelManager", ".", "PerWorkingCopyInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "OpenableElementInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "PackageFragment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "ReconcileWorkingCopyOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "GroovyCompilationUnit", "extends", "CompilationUnit", "{", "private", "class", "GroovyErrorHandlingPolicy", "implements", "IErrorHandlingPolicy", "{", "final", "boolean", "stopOnFirst", ";", "public", "GroovyErrorHandlingPolicy", "(", "boolean", "stopOnFirst", ")", "{", "this", ".", "stopOnFirst", "=", "stopOnFirst", ";", "}", "public", "boolean", "proceedOnErrors", "(", ")", "{", "return", "!", "stopOnFirst", ";", "}", "public", "boolean", "stopOnFirstError", "(", ")", "{", "return", "stopOnFirst", ";", "}", "}", "public", "GroovyCompilationUnit", "(", "PackageFragment", "parent", ",", "String", "name", ",", "WorkingCopyOwner", "owner", ")", "{", "super", "(", "parent", ",", "name", ",", "owner", ")", ";", "}", "public", "ModuleNode", "getModuleNode", "(", ")", "{", "ModuleNodeInfo", "moduleInfo", "=", "getModuleInfo", "(", "true", ")", ";", "return", "moduleInfo", "!=", "null", "?", "moduleInfo", ".", "module", ":", "null", ";", "}", "public", "ModuleNodeInfo", "getModuleInfo", "(", "boolean", "force", ")", "{", "try", "{", "if", "(", "!", "isConsistent", "(", ")", ")", "{", "makeConsistent", "(", "null", ")", ";", "}", "synchronized", "(", "ModuleNodeMapper", ".", "getInstance", "(", ")", ")", "{", "boolean", "becameWorkingCopy", "=", "false", ";", "try", "{", "if", "(", "becameWorkingCopy", "=", "(", "force", "&&", "!", "isWorkingCopy", "(", ")", ")", ")", "{", "becomeWorkingCopy", "(", "null", ")", ";", "}", "PerWorkingCopyInfo", "info", "=", "getPerWorkingCopyInfo", "(", ")", ";", "if", "(", "info", "!=", "null", ")", "{", "return", "ModuleNodeMapper", ".", "getInstance", "(", ")", ".", "get", "(", "info", ")", ";", "}", "}", "finally", "{", "if", "(", "becameWorkingCopy", ")", "{", "discardWorkingCopy", "(", ")", ";", "}", "}", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "this", ".", "getElementName", "(", ")", ")", ";", "}", "return", "null", ";", "}", "public", "ModuleNodeInfo", "getNewModuleInfo", "(", ")", "{", "try", "{", "openWhenClosed", "(", "createElementInfo", "(", ")", ",", "false", ",", "new", "NullProgressMonitor", "(", ")", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "this", ".", "getElementName", "(", ")", ")", ";", "}", "return", "getModuleInfo", "(", "true", ")", ";", "}", "@", "Override", "public", "void", "discardWorkingCopy", "(", ")", "throws", "JavaModelException", "{", "synchronized", "(", "ModuleNodeMapper", ".", "getInstance", "(", ")", ")", "{", "PerWorkingCopyInfo", "info", "=", "getPerWorkingCopyInfo", "(", ")", ";", "if", "(", "workingCopyInfoWillBeDiscarded", "(", "info", ")", ")", "{", "ModuleNodeMapper", ".", "getInstance", "(", ")", ".", "remove", "(", "info", ")", ";", "}", "super", ".", "discardWorkingCopy", "(", ")", ";", "}", "}", "private", "boolean", "workingCopyInfoWillBeDiscarded", "(", "PerWorkingCopyInfo", "info", ")", "{", "return", "info", "!=", "null", "&&", "(", "(", "Integer", ")", "ReflectionUtils", ".", "getPrivateField", "(", "PerWorkingCopyInfo", ".", "class", ",", "\"useCount\"", ",", "info", ")", ")", ".", "intValue", "(", ")", "<=", "1", ";", "}", "static", "MyThreadLocal", "depth", "=", "new", "MyThreadLocal", "(", ")", ";", "static", "class", "MyThreadLocal", "extends", "ThreadLocal", "<", "Integer", ">", "{", "@", "Override", "protected", "Integer", "initialValue", "(", ")", "{", "return", "0", ";", "}", "}", "@", "SuppressWarnings", "(", "{", "\"unchecked\"", ",", "\"rawtypes\"", ",", "\"nls\"", ",", "\"restriction\"", "}", ")", "@", "Override", "protected", "boolean", "buildStructure", "(", "OpenableElementInfo", "info", ",", "IProgressMonitor", "pm", ",", "Map", "newElements", ",", "IResource", "underlyingResource", ")", "throws", "JavaModelException", "{", "try", "{", "depth", ".", "set", "(", "depth", ".", "get", "(", ")", "+", "1", ")", ";", "if", "(", "GroovyLogManager", ".", "manager", ".", "hasLoggers", "(", ")", ")", "{", "GroovyLogManager", ".", "manager", ".", "log", "(", "TraceCategory", ".", "COMPILER", ",", "\"\"", "+", "this", ".", "name", ")", ";", "GroovyLogManager", ".", "manager", ".", "logStart", "(", "\"\"", "+", "name", "+", "\"", ":", "\"", "+", "Thread", ".", "currentThread", "(", ")", ".", "getName", "(", ")", ")", ";", "}", "CompilationUnitElementInfo", "unitInfo", "=", "(", "CompilationUnitElementInfo", ")", "info", ";", "IBuffer", "buffer", "=", "getBufferManager", "(", ")", ".", "getBuffer", "(", "this", ")", ";", "if", "(", "buffer", "==", "null", ")", "{", "openBuffer", "(", "pm", ",", "unitInfo", ")", ";", "}", "GroovyCompilationUnitStructureRequestor", "requestor", "=", "new", "GroovyCompilationUnitStructureRequestor", "(", "this", ",", "unitInfo", ",", "newElements", ")", ";", "JavaModelManager", ".", "PerWorkingCopyInfo", "perWorkingCopyInfo", "=", "getPerWorkingCopyInfo", "(", ")", ";", "JavaProject", "project", "=", "(", "JavaProject", ")", "getJavaProject", "(", ")", ";", "boolean", "createAST", ";", "int", "reconcileFlags", ";", "boolean", "resolveBindings", ";", "HashMap", "problems", ";", "if", "(", "info", "instanceof", "ASTHolderCUInfo", ")", "{", "ASTHolderCUInfo", "astHolder", "=", "(", "ASTHolderCUInfo", ")", "info", ";", "createAST", "=", "(", "(", "Integer", ")", "ReflectionUtils", ".", "getPrivateField", "(", "ASTHolderCUInfo", ".", "class", ",", "\"astLevel\"", ",", "astHolder", ")", ")", ".", "intValue", "(", ")", "!=", "NO_AST", ";", "resolveBindings", "=", "(", "(", "Boolean", ")", "ReflectionUtils", ".", "getPrivateField", "(", "ASTHolderCUInfo", ".", "class", ",", "\"\"", ",", "astHolder", ")", ")", ".", "booleanValue", "(", ")", ";", "reconcileFlags", "=", "(", "(", "Integer", ")", "ReflectionUtils", ".", "getPrivateField", "(", "ASTHolderCUInfo", ".", "class", ",", "\"\"", ",", "astHolder", ")", ")", ".", "intValue", "(", ")", ";", "problems", "=", "(", "HashMap", ")", "ReflectionUtils", ".", "getPrivateField", "(", "ASTHolderCUInfo", ".", "class", ",", "\"problems\"", ",", "astHolder", ")", ";", "}", "else", "{", "createAST", "=", "false", ";", "resolveBindings", "=", "false", ";", "reconcileFlags", "=", "0", ";", "problems", "=", "null", ";", "}", "boolean", "computeProblems", "=", "perWorkingCopyInfo", "!=", "null", "&&", "perWorkingCopyInfo", ".", "isActive", "(", ")", "&&", "project", "!=", "null", "&&", "JavaProject", ".", "hasJavaNature", "(", "project", ".", "getProject", "(", ")", ")", ";", "IProblemFactory", "problemFactory", "=", "new", "DefaultProblemFactory", "(", ")", ";", "Map", "<", "String", ",", "String", ">", "options", "=", "(", "project", "==", "null", "?", "JavaCore", ".", "getOptions", "(", ")", ":", "project", ".", "getOptions", "(", "true", ")", ")", ";", "if", "(", "!", "computeProblems", ")", "{", "options", ".", "put", "(", "JavaCore", ".", "COMPILER_TASK_TAGS", ",", "\"\"", ")", ";", "}", "options", ".", "put", "(", "CompilerOptions", ".", "OPTIONG_BuildGroovyFiles", ",", "CompilerOptions", ".", "ENABLED", ")", ";", "CompilerOptions", "compilerOptions", "=", "new", "CompilerOptions", "(", "options", ")", ";", "if", "(", "project", "!=", "null", ")", "{", "CompilerUtils", ".", "setGroovyClasspath", "(", "compilerOptions", ",", "project", ")", ";", "}", "ProblemReporter", "reporter", "=", "new", "ProblemReporter", "(", "new", "GroovyErrorHandlingPolicy", "(", "!", "computeProblems", ")", ",", "compilerOptions", ",", "new", "DefaultProblemFactory", "(", ")", ")", ";", "SourceElementParser", "parser", "=", "new", "MultiplexingSourceElementRequestorParser", "(", "reporter", ",", "requestor", ",", "problemFactory", ",", "compilerOptions", ",", "true", ",", "!", "createAST", ")", ";", "parser", ".", "reportOnlyOneSyntaxError", "=", "!", "computeProblems", ";", "parser", ".", "setMethodsFullRecovery", "(", "true", ")", ";", "parser", ".", "setStatementsRecovery", "(", "(", "reconcileFlags", "&", "ICompilationUnit", ".", "ENABLE_STATEMENTS_RECOVERY", ")", "!=", "0", ")", ";", "if", "(", "!", "computeProblems", "&&", "!", "resolveBindings", "&&", "!", "createAST", ")", "parser", ".", "javadocParser", ".", "checkDocComment", "=", "false", ";", "requestor", ".", "setParser", "(", "parser", ")", ";", "if", "(", "underlyingResource", "==", "null", ")", "{", "underlyingResource", "=", "getResource", "(", ")", ";", "}", "if", "(", "underlyingResource", "!=", "null", ")", "{", "ReflectionUtils", ".", "setPrivateField", "(", "CompilationUnitElementInfo", ".", "class", ",", "\"timestamp\"", ",", "unitInfo", ",", "underlyingResource", ".", "getModificationStamp", "(", ")", ")", ";", "}", "GroovyCompilationUnitDeclaration", "compilationUnitDeclaration", "=", "null", ";", "CompilationUnit", "source", "=", "cloneCachingContents", "(", ")", ";", "try", "{", "if", "(", "computeProblems", "||", "depth", ".", "get", "(", ")", "<", "2", ")", "{", "if", "(", "problems", "==", "null", ")", "{", "problems", "=", "new", "HashMap", "(", ")", ";", "compilationUnitDeclaration", "=", "(", "GroovyCompilationUnitDeclaration", ")", "CompilationUnitProblemFinder", ".", "process", "(", "source", ",", "parser", ",", "this", ".", "owner", ",", "problems", ",", "createAST", ",", "reconcileFlags", ",", "pm", ")", ";", "if", "(", "computeProblems", ")", "{", "try", "{", "perWorkingCopyInfo", ".", "beginReporting", "(", ")", ";", "for", "(", "Iterator", "iteraror", "=", "problems", ".", "values", "(", ")", ".", "iterator", "(", ")", ";", "iteraror", ".", "hasNext", "(", ")", ";", ")", "{", "CategorizedProblem", "[", "]", "categorizedProblems", "=", "(", "CategorizedProblem", "[", "]", ")", "iteraror", ".", "next", "(", ")", ";", "if", "(", "categorizedProblems", "==", "null", ")", "continue", ";", "for", "(", "int", "i", "=", "0", ",", "length", "=", "categorizedProblems", ".", "length", ";", "i", "<", "length", ";", "i", "++", ")", "{", "perWorkingCopyInfo", ".", "acceptProblem", "(", "categorizedProblems", "[", "i", "]", ")", ";", "}", "}", "}", "finally", "{", "perWorkingCopyInfo", ".", "endReporting", "(", ")", ";", "}", "}", "}", "else", "{", "compilationUnitDeclaration", "=", "(", "GroovyCompilationUnitDeclaration", ")", "CompilationUnitProblemFinder", ".", "process", "(", "source", ",", "parser", ",", "this", ".", "owner", ",", "problems", ",", "createAST", ",", "reconcileFlags", ",", "pm", ")", ";", "}", "}", "else", "{", "compilationUnitDeclaration", "=", "(", "GroovyCompilationUnitDeclaration", ")", "parser", ".", "parseCompilationUnit", "(", "source", ",", "true", ",", "pm", ")", ";", "}", "maybeCacheModuleNode", "(", "perWorkingCopyInfo", ",", "compilationUnitDeclaration", ")", ";", "if", "(", "createAST", ")", "{", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "CompilationUnit", "ast", ";", "try", "{", "ast", "=", "AST", ".", "convertCompilationUnit", "(", "AST", ".", "JLS3", ",", "compilationUnitDeclaration", ",", "options", ",", "computeProblems", ",", "source", ",", "reconcileFlags", ",", "pm", ")", ";", "ReflectionUtils", ".", "setPrivateField", "(", "ASTHolderCUInfo", ".", "class", ",", "\"ast\"", ",", "info", ",", "ast", ")", ";", "}", "catch", "(", "OperationCanceledException", "e", ")", "{", "throw", "e", ";", "}", "catch", "(", "IllegalArgumentException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "this", ".", "getParent", "(", ")", ".", "getElementName", "(", ")", "+", "\".\"", "+", "getElementName", "(", ")", ")", ";", "}", "catch", "(", "Exception", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "this", ".", "getElementName", "(", ")", ")", ";", "}", "}", "}", "catch", "(", "OperationCanceledException", "e", ")", "{", "throw", "e", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "if", "(", "e", ".", "getStatus", "(", ")", ".", "getCode", "(", ")", "!=", "IJavaModelStatusConstants", ".", "ELEMENT_DOES_NOT_EXIST", "||", "this", ".", "getJavaProject", "(", ")", ".", "exists", "(", ")", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "this", ".", "getElementName", "(", ")", ")", ";", "}", "}", "catch", "(", "Exception", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "this", ".", "getElementName", "(", ")", ")", ";", "}", "finally", "{", "if", "(", "compilationUnitDeclaration", "!=", "null", ")", "{", "compilationUnitDeclaration", ".", "cleanUp", "(", ")", ";", "}", "}", "return", "unitInfo", ".", "isStructureKnown", "(", ")", ";", "}", "finally", "{", "depth", ".", "set", "(", "depth", ".", "get", "(", ")", "-", "1", ")", ";", "if", "(", "GroovyLogManager", ".", "manager", ".", "hasLoggers", "(", ")", ")", "{", "GroovyLogManager", ".", "manager", ".", "logEnd", "(", "\"\"", "+", "name", "+", "\"", ":", "\"", "+", "Thread", ".", "currentThread", "(", ")", ".", "getName", "(", ")", ",", "TraceCategory", ".", "COMPILER", ")", ";", "}", "}", "}", "protected", "void", "maybeCacheModuleNode", "(", "JavaModelManager", ".", "PerWorkingCopyInfo", "perWorkingCopyInfo", ",", "GroovyCompilationUnitDeclaration", "compilationUnitDeclaration", ")", "{", "ModuleNodeMapper", ".", "getInstance", "(", ")", ".", "maybeCacheModuleNode", "(", "perWorkingCopyInfo", ",", "compilationUnitDeclaration", ")", ";", "}", "@", "Override", "public", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "dom", ".", "CompilationUnit", "reconcile", "(", "int", "astLevel", ",", "int", "reconcileFlags", ",", "WorkingCopyOwner", "workingCopyOwner", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "if", "(", "!", "isWorkingCopy", "(", ")", ")", "return", "null", ";", "if", "(", "workingCopyOwner", "==", "null", ")", "workingCopyOwner", "=", "DefaultWorkingCopyOwner", ".", "PRIMARY", ";", "PerformanceStats", "stats", "=", "null", ";", "if", "(", "ReconcileWorkingCopyOperation", ".", "PERF", ")", "{", "stats", "=", "PerformanceStats", ".", "getStats", "(", "JavaModelManager", ".", "RECONCILE_PERF", ",", "this", ")", ";", "stats", ".", "startRun", "(", "new", "String", "(", "this", ".", "getFileName", "(", ")", ")", ")", ";", "}", "ReconcileWorkingCopyOperation", "op", "=", "new", "GroovyReconcileWorkingCopyOperation", "(", "this", ",", "astLevel", ",", "reconcileFlags", ",", "workingCopyOwner", ")", ";", "JavaModelManager", "manager", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ";", "try", "{", "manager", ".", "cacheZipFiles", "(", "this", ")", ";", "op", ".", "runOperation", "(", "monitor", ")", ";", "}", "finally", "{", "manager", ".", "flushZipFiles", "(", "this", ")", ";", "}", "if", "(", "ReconcileWorkingCopyOperation", ".", "PERF", ")", "{", "stats", ".", "endRun", "(", ")", ";", "}", "return", "op", ".", "ast", ";", "}", "@", "SuppressWarnings", "(", "{", "\"unchecked\"", ",", "\"rawtypes\"", "}", ")", "@", "Override", "public", "Object", "getAdapter", "(", "Class", "adapter", ")", "{", "if", "(", "adapter", "==", "GroovyCompilationUnit", ".", "class", ")", "{", "return", "this", ";", "}", "if", "(", "adapter", "==", "ModuleNode", ".", "class", ")", "{", "return", "getModuleNode", "(", ")", ";", "}", "return", "super", ".", "getAdapter", "(", "adapter", ")", ";", "}", "class", "CompilationUnitClone", "extends", "GroovyCompilationUnit", "{", "private", "char", "[", "]", "cachedContents", ";", "public", "CompilationUnitClone", "(", "char", "[", "]", "cachedContents", ")", "{", "this", "(", ")", ";", "this", ".", "cachedContents", "=", "cachedContents", ";", "}", "public", "CompilationUnitClone", "(", ")", "{", "super", "(", "(", "PackageFragment", ")", "GroovyCompilationUnit", ".", "this", ".", "parent", ",", "GroovyCompilationUnit", ".", "this", ".", "name", ",", "GroovyCompilationUnit", ".", "this", ".", "owner", ")", ";", "}", "@", "Override", "public", "char", "[", "]", "getContents", "(", ")", "{", "if", "(", "this", ".", "cachedContents", "==", "null", ")", "this", ".", "cachedContents", "=", "GroovyCompilationUnit", ".", "this", ".", "getContents", "(", ")", ";", "return", "this", ".", "cachedContents", ";", "}", "@", "Override", "public", "CompilationUnit", "originalFromClone", "(", ")", "{", "return", "GroovyCompilationUnit", ".", "this", ";", "}", "@", "Override", "public", "char", "[", "]", "getFileName", "(", ")", "{", "return", "GroovyCompilationUnit", ".", "this", ".", "getFileName", "(", ")", ";", "}", "}", "public", "GroovyCompilationUnit", "cloneCachingContents", "(", "char", "[", "]", "newContents", ")", "{", "return", "new", "CompilationUnitClone", "(", "newContents", ")", ";", "}", "@", "Override", "public", "GroovyCompilationUnit", "cloneCachingContents", "(", ")", "{", "return", "new", "CompilationUnitClone", "(", ")", ";", "}", "@", "Override", "public", "IJavaElement", "[", "]", "codeSelect", "(", "int", "offset", ",", "int", "length", ")", "throws", "JavaModelException", "{", "return", "codeSelect", "(", "offset", ",", "length", ",", "DefaultWorkingCopyOwner", ".", "PRIMARY", ")", ";", "}", "@", "Override", "public", "IJavaElement", "[", "]", "codeSelect", "(", "int", "offset", ",", "int", "length", ",", "WorkingCopyOwner", "workingCopyOwner", ")", "throws", "JavaModelException", "{", "return", "codeSelect", "(", "this", ",", "offset", ",", "length", ",", "workingCopyOwner", ")", ";", "}", "@", "Override", "protected", "IJavaElement", "[", "]", "codeSelect", "(", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", "cu", ",", "int", "offset", ",", "int", "length", ",", "WorkingCopyOwner", "o", ")", "throws", "JavaModelException", "{", "if", "(", "CodeSelectHelperFactory", ".", "selectHelper", "!=", "null", ")", "{", "return", "CodeSelectHelperFactory", ".", "selectHelper", ".", "select", "(", "this", ",", "offset", ",", "length", ")", ";", "}", "return", "new", "IJavaElement", "[", "0", "]", ";", "}", "@", "SuppressWarnings", "(", "\"nls\"", ")", "@", "Override", "public", "IType", "findPrimaryType", "(", ")", "{", "IType", "type", "=", "super", ".", "findPrimaryType", "(", ")", ";", "if", "(", "type", "!=", "null", ")", "{", "return", "type", ";", "}", "try", "{", "IType", "[", "]", "types", "=", "getTypes", "(", ")", ";", "if", "(", "types", "!=", "null", "&&", "types", ".", "length", ">", "0", ")", "{", "return", "types", "[", "0", "]", ";", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "if", "(", "e", ".", "getStatus", "(", ")", ".", "getCode", "(", ")", "!=", "IJavaModelStatusConstants", ".", "ELEMENT_NOT_ON_CLASSPATH", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "this", ".", "getElementName", "(", ")", ")", ";", "}", "}", "return", "null", ";", "}", "public", "boolean", "isOnBuildPath", "(", ")", "{", "IJavaProject", "project", "=", "this", ".", "getJavaProject", "(", ")", ";", "if", "(", "!", "project", ".", "isOnClasspath", "(", "this", ")", ")", "{", "return", "false", ";", "}", "IProject", "resourceProject", "=", "project", ".", "getProject", "(", ")", ";", "if", "(", "resourceProject", "==", "null", "||", "!", "resourceProject", ".", "isAccessible", "(", ")", "||", "!", "GroovyNature", ".", "hasGroovyNature", "(", "resourceProject", ")", ")", "{", "return", "false", ";", "}", "return", "true", ";", "}", "@", "Override", "public", "IResource", "getUnderlyingResource", "(", ")", "throws", "JavaModelException", "{", "if", "(", "isOnBuildPath", "(", ")", ")", "{", "return", "super", ".", "getUnderlyingResource", "(", ")", ";", "}", "else", "{", "IResource", "rsrc", "=", "getResource", "(", ")", ";", "try", "{", "Assert", ".", "isTrue", "(", "rsrc", ".", "getFullPath", "(", ")", ".", "toString", "(", ")", ".", "endsWith", "(", "name", ")", ")", ";", "}", "catch", "(", "Throwable", "e", ")", "{", "Util", ".", "log", "(", "e", ")", ";", "return", "super", ".", "getUnderlyingResource", "(", ")", ";", "}", "return", "rsrc", ";", "}", "}", "@", "Override", "public", "void", "rename", "(", "String", "newName", ",", "boolean", "force", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "super", ".", "rename", "(", "newName", ",", "force", ",", "monitor", ")", ";", "if", "(", "this", ".", "isWorkingCopy", "(", ")", ")", "{", "this", ".", "discardWorkingCopy", "(", ")", ";", "}", "}", "protected", "void", "codeComplete", "(", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", "cu", ",", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", "unitToSkip", ",", "int", "position", ",", "CompletionRequestor", "requestor", ",", "WorkingCopyOwner", "owner", ",", "ITypeRoot", "typeRoot", ",", "IProgressMonitor", "monitor", ")", "throws", "JavaModelException", "{", "ICodeCompletionDelegate", "delegate", "=", "(", "ICodeCompletionDelegate", ")", "getAdapter", "(", "ICodeCompletionDelegate", ".", "class", ")", ";", "if", "(", "delegate", "!=", "null", "&&", "delegate", ".", "shouldCodeComplete", "(", "requestor", ",", "typeRoot", ")", ")", "{", "delegate", ".", "codeComplete", "(", "cu", ",", "unitToSkip", ",", "position", ",", "requestor", ",", "owner", ",", "typeRoot", ",", "monitor", ")", ";", "}", "else", "{", "super", ".", "codeComplete", "(", "cu", ",", "unitToSkip", ",", "position", ",", "requestor", ",", "owner", ",", "typeRoot", ",", "monitor", ")", ";", "}", "}", "}", "</s>" ]
6,776
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyCompilationUnitDeclaration", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyParser", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ContentTypeUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ReflectionUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "IProblemFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ISourceElementRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "SourceElementNotifier", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "SourceElementParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "FieldDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "HashtableOfObjectToInt", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "indexing", ".", "IndexingParser", ";", "public", "class", "MultiplexingIndexingParser", "extends", "IndexingParser", "{", "SourceElementNotifier", "notifier", ";", "boolean", "groovyReportReferenceInfo", ";", "ISourceElementRequestor", "requestor", ";", "public", "MultiplexingIndexingParser", "(", "ISourceElementRequestor", "requestor", ",", "IProblemFactory", "problemFactory", ",", "CompilerOptions", "options", ",", "boolean", "reportLocalDeclarations", ",", "boolean", "optimizeStringLiterals", ",", "boolean", "useSourceJavadocParser", ")", "{", "super", "(", "requestor", ",", "problemFactory", ",", "options", ",", "reportLocalDeclarations", ",", "optimizeStringLiterals", ",", "useSourceJavadocParser", ")", ";", "this", ".", "notifier", "=", "(", "SourceElementNotifier", ")", "ReflectionUtils", ".", "getPrivateField", "(", "SourceElementParser", ".", "class", ",", "\"notifier\"", ",", "this", ")", ";", "this", ".", "groovyReportReferenceInfo", "=", "reportLocalDeclarations", ";", "this", ".", "requestor", "=", "requestor", ";", "}", "@", "Override", "public", "void", "setRequestor", "(", "ISourceElementRequestor", "requestor", ")", "{", "super", ".", "setRequestor", "(", "requestor", ")", ";", "this", ".", "requestor", "=", "requestor", ";", "}", "@", "Override", "public", "CompilationUnitDeclaration", "parseCompilationUnit", "(", "ICompilationUnit", "unit", ",", "boolean", "fullParse", ",", "IProgressMonitor", "pm", ")", "{", "if", "(", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "unit", ".", "getFileName", "(", ")", ")", ")", "{", "CompilationResult", "compilationResult", "=", "new", "CompilationResult", "(", "unit", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ";", "GroovyCompilationUnitDeclaration", "cud", "=", "(", "GroovyCompilationUnitDeclaration", ")", "new", "GroovyParser", "(", "this", ".", "options", ",", "problemReporter", ",", "false", ",", "true", ")", ".", "dietParse", "(", "unit", ",", "compilationResult", ")", ";", "HashtableOfObjectToInt", "sourceEnds", "=", "createSourceEnds", "(", "cud", ")", ";", "GroovyIndexingVisitor", "visitor", "=", "new", "GroovyIndexingVisitor", "(", "requestor", ")", ";", "visitor", ".", "doVisit", "(", "cud", ".", "getModuleNode", "(", ")", ",", "cud", ".", "currentPackage", ")", ";", "notifier", ".", "notifySourceElementRequestor", "(", "cud", ",", "0", ",", "unit", ".", "getContents", "(", ")", ".", "length", ",", "groovyReportReferenceInfo", ",", "sourceEnds", ",", "Collections", ".", "EMPTY_MAP", ")", ";", "return", "cud", ";", "}", "else", "{", "return", "super", ".", "parseCompilationUnit", "(", "unit", ",", "fullParse", ",", "pm", ")", ";", "}", "}", "private", "HashtableOfObjectToInt", "createSourceEnds", "(", "CompilationUnitDeclaration", "cDecl", ")", "{", "HashtableOfObjectToInt", "table", "=", "new", "HashtableOfObjectToInt", "(", ")", ";", "if", "(", "cDecl", ".", "types", "!=", "null", ")", "{", "for", "(", "TypeDeclaration", "tDecl", ":", "cDecl", ".", "types", ")", "{", "createSourceEndsForType", "(", "tDecl", ",", "table", ")", ";", "}", "}", "return", "table", ";", "}", "private", "void", "createSourceEndsForType", "(", "TypeDeclaration", "tDecl", ",", "HashtableOfObjectToInt", "table", ")", "{", "table", ".", "put", "(", "tDecl", ",", "tDecl", ".", "sourceEnd", ")", ";", "if", "(", "tDecl", ".", "fields", "!=", "null", ")", "{", "for", "(", "FieldDeclaration", "fDecl", ":", "tDecl", ".", "fields", ")", "{", "table", ".", "put", "(", "fDecl", ",", "fDecl", ".", "sourceEnd", ")", ";", "}", "}", "if", "(", "tDecl", ".", "methods", "!=", "null", ")", "{", "for", "(", "AbstractMethodDeclaration", "mDecl", ":", "tDecl", ".", "methods", ")", "{", "table", ".", "put", "(", "mDecl", ",", "mDecl", ".", "sourceEnd", ")", ";", "}", "}", "if", "(", "tDecl", ".", "memberTypes", "!=", "null", ")", "{", "for", "(", "TypeDeclaration", "innerTDecl", ":", "tDecl", ".", "memberTypes", ")", "{", "createSourceEndsForType", "(", "innerTDecl", ",", "table", ")", ";", "}", "}", "}", "}", "</s>" ]
6,777
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyParser", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ContentTypeUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "IProblemFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "SourceElementNotifier", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "SourceElementParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "AbstractMethodDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "FieldDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "util", ".", "HashtableOfObjectToInt", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ISourceElementRequestor", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "MultiplexingSourceElementRequestorParser", "extends", "SourceElementParser", "{", "ISourceElementRequestor", "groovyRequestor", ";", "SourceElementNotifier", "notifier", ";", "boolean", "groovyReportReferenceInfo", ";", "private", "GroovyParser", "parser", ";", "public", "MultiplexingSourceElementRequestorParser", "(", "ProblemReporter", "problemReporter", ",", "ISourceElementRequestor", "requestor", ",", "IProblemFactory", "problemFactory", ",", "CompilerOptions", "options", ",", "boolean", "reportLocalDeclarations", ",", "boolean", "optimizeStringLiterals", ")", "{", "super", "(", "requestor", ",", "problemFactory", ",", "options", ",", "reportLocalDeclarations", ",", "optimizeStringLiterals", ")", ";", "this", ".", "groovyRequestor", "=", "requestor", ";", "this", ".", "notifier", "=", "new", "SourceElementNotifier", "(", "requestor", ",", "reportLocalDeclarations", ")", ";", "this", ".", "parser", "=", "new", "GroovyParser", "(", "requestor", ",", "this", ".", "options", ",", "problemReporter", ",", "false", ",", "true", ")", ";", "}", "@", "Override", "public", "CompilationUnitDeclaration", "parseCompilationUnit", "(", "ICompilationUnit", "unit", ",", "boolean", "fullParse", ",", "IProgressMonitor", "pm", ")", "{", "if", "(", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "unit", ".", "getFileName", "(", ")", ")", ")", "{", "CompilationResult", "compilationResult", "=", "new", "CompilationResult", "(", "unit", ",", "0", ",", "0", ",", "this", ".", "options", ".", "maxProblemsPerUnit", ")", ";", "CompilationUnitDeclaration", "cud", "=", "new", "GroovyParser", "(", "this", ".", "parser", ".", "requestor", ",", "this", ".", "options", ",", "problemReporter", ",", "false", ",", "true", ")", ".", "dietParse", "(", "unit", ",", "compilationResult", ")", ";", "HashtableOfObjectToInt", "sourceEnds", "=", "createSourceEnds", "(", "cud", ")", ";", "notifier", ".", "notifySourceElementRequestor", "(", "cud", ",", "0", ",", "unit", ".", "getContents", "(", ")", ".", "length", ",", "groovyReportReferenceInfo", ",", "sourceEnds", ",", "Collections", ".", "EMPTY_MAP", ")", ";", "return", "cud", ";", "}", "else", "{", "return", "super", ".", "parseCompilationUnit", "(", "unit", ",", "fullParse", ",", "pm", ")", ";", "}", "}", "@", "Override", "public", "CompilationUnitDeclaration", "dietParse", "(", "ICompilationUnit", "sourceUnit", ",", "CompilationResult", "compilationResult", ")", "{", "if", "(", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "sourceUnit", ".", "getFileName", "(", ")", ")", ")", "{", "return", "parser", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "else", "{", "return", "super", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "}", "private", "HashtableOfObjectToInt", "createSourceEnds", "(", "CompilationUnitDeclaration", "cDecl", ")", "{", "HashtableOfObjectToInt", "table", "=", "new", "HashtableOfObjectToInt", "(", ")", ";", "if", "(", "cDecl", ".", "types", "!=", "null", ")", "{", "for", "(", "TypeDeclaration", "tDecl", ":", "cDecl", ".", "types", ")", "{", "createSourceEndsForType", "(", "tDecl", ",", "table", ")", ";", "}", "}", "return", "table", ";", "}", "@", "Override", "public", "void", "reset", "(", ")", "{", "parser", ".", "reset", "(", ")", ";", "}", "private", "void", "createSourceEndsForType", "(", "TypeDeclaration", "tDecl", ",", "HashtableOfObjectToInt", "table", ")", "{", "table", ".", "put", "(", "tDecl", ",", "tDecl", ".", "sourceEnd", ")", ";", "if", "(", "tDecl", ".", "fields", "!=", "null", ")", "{", "for", "(", "FieldDeclaration", "fDecl", ":", "tDecl", ".", "fields", ")", "{", "table", ".", "put", "(", "fDecl", ",", "fDecl", ".", "sourceEnd", ")", ";", "}", "}", "if", "(", "tDecl", ".", "methods", "!=", "null", ")", "{", "for", "(", "AbstractMethodDeclaration", "mDecl", ":", "tDecl", ".", "methods", ")", "{", "table", ".", "put", "(", "mDecl", ",", "mDecl", ".", "sourceEnd", ")", ";", "}", "}", "if", "(", "tDecl", ".", "memberTypes", "!=", "null", ")", "{", "for", "(", "TypeDeclaration", "innerTDecl", ":", "tDecl", ".", "memberTypes", ")", "{", "createSourceEndsForType", "(", "innerTDecl", ",", "table", ")", ";", "}", "}", "}", "}", "</s>" ]
6,778
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "java", ".", "util", ".", "SortedSet", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotatedNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassCodeVisitorSupport", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GenericsType", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ImportNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ImportNodeCompatibilityWrapper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ModuleNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Parameter", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "CastExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ClassExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ClosureExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstantExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstructorCallExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "DeclarationExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "FieldExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MethodCallExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "VariableExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "Statement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IStatus", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Status", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "Activator", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ISourceElementRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "ImportReference", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "GroovyIndexingVisitor", "extends", "ClassCodeVisitorSupport", "{", "private", "ISourceElementRequestor", "requestor", ";", "private", "ModuleNode", "module", ";", "public", "GroovyIndexingVisitor", "(", "ISourceElementRequestor", "requestor", ")", "{", "this", ".", "requestor", "=", "requestor", ";", "}", "@", "Override", "protected", "SourceUnit", "getSourceUnit", "(", ")", "{", "return", "null", ";", "}", "void", "doVisit", "(", "ModuleNode", "node", ",", "ImportReference", "pkg", ")", "{", "if", "(", "node", "==", "null", ")", "{", "return", ";", "}", "module", "=", "node", ";", "try", "{", "this", ".", "visitImports", "(", "node", ")", ";", "for", "(", "ClassNode", "clazz", ":", "(", "Iterable", "<", "ClassNode", ">", ")", "node", ".", "getClasses", "(", ")", ")", "{", "this", ".", "visitClass", "(", "clazz", ")", ";", "}", "}", "catch", "(", "RuntimeException", "e", ")", "{", "Util", ".", "log", "(", "e", ")", ";", "}", "}", "public", "void", "visitImports", "(", "ModuleNode", "node", ")", "{", "if", "(", "node", "!=", "null", ")", "{", "SortedSet", "<", "ImportNode", ">", "allImports", "=", "new", "ImportNodeCompatibilityWrapper", "(", "node", ")", ".", "getAllImportNodes", "(", ")", ";", "for", "(", "ImportNode", "importNode", ":", "allImports", ")", "{", "visitAnnotations", "(", "importNode", ")", ";", "if", "(", "importNode", ".", "getType", "(", ")", "!=", "null", ")", "{", "handleType", "(", "importNode", ".", "getType", "(", ")", ",", "false", ",", "true", ")", ";", "}", "String", "importFieldName", "=", "ImportNodeCompatibilityWrapper", ".", "getFieldName", "(", "importNode", ")", ";", "if", "(", "importFieldName", "!=", "null", ")", "{", "requestor", ".", "acceptUnknownReference", "(", "importFieldName", ".", "toCharArray", "(", ")", ",", "0", ")", ";", "}", "}", "}", "}", "@", "Override", "public", "void", "visitMethodCallExpression", "(", "MethodCallExpression", "call", ")", "{", "super", ".", "visitMethodCallExpression", "(", "call", ")", ";", "String", "methodStr", "=", "call", ".", "getMethodAsString", "(", ")", ";", "if", "(", "methodStr", "==", "null", ")", "return", ";", "char", "[", "]", "methodName", "=", "methodStr", ".", "toCharArray", "(", ")", ";", "int", "start", "=", "call", ".", "getStart", "(", ")", ";", "requestor", ".", "acceptFieldReference", "(", "methodName", ",", "start", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "7", ";", "i", "++", ")", "{", "requestor", ".", "acceptMethodReference", "(", "methodName", ",", "i", ",", "start", ")", ";", "}", "}", "@", "Override", "public", "void", "visitFieldExpression", "(", "FieldExpression", "expression", ")", "{", "super", ".", "visitFieldExpression", "(", "expression", ")", ";", "requestor", ".", "acceptFieldReference", "(", "expression", ".", "getFieldName", "(", ")", ".", "toCharArray", "(", ")", ",", "expression", ".", "getStart", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "visitConstantExpression", "(", "ConstantExpression", "expression", ")", "{", "if", "(", "!", "(", "expression", ".", "isTrueExpression", "(", ")", "||", "expression", ".", "isFalseExpression", "(", ")", "||", "expression", ".", "isNullExpression", "(", ")", "||", "expression", ".", "isEmptyStringExpression", "(", ")", ")", ")", "{", "char", "[", "]", "constName", "=", "expression", ".", "getValue", "(", ")", ".", "toString", "(", ")", ".", "toCharArray", "(", ")", ";", "int", "start", "=", "expression", ".", "getStart", "(", ")", ";", "requestor", ".", "acceptFieldReference", "(", "constName", ",", "start", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "7", ";", "i", "++", ")", "{", "requestor", ".", "acceptMethodReference", "(", "constName", ",", "i", ",", "start", ")", ";", "}", "}", "super", ".", "visitConstantExpression", "(", "expression", ")", ";", "}", "@", "Override", "public", "void", "visitCastExpression", "(", "CastExpression", "expression", ")", "{", "handleType", "(", "expression", ".", "getType", "(", ")", ",", "false", ",", "true", ")", ";", "}", "@", "Override", "public", "void", "visitClassExpression", "(", "ClassExpression", "expression", ")", "{", "handleType", "(", "expression", ".", "getType", "(", ")", ",", "false", ",", "true", ")", ";", "}", "@", "Override", "public", "void", "visitConstructorCallExpression", "(", "ConstructorCallExpression", "call", ")", "{", "super", ".", "visitConstructorCallExpression", "(", "call", ")", ";", "requestor", ".", "acceptConstructorReference", "(", "call", ".", "getType", "(", ")", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ",", "0", ",", "call", ".", "getStart", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "visitDeclarationExpression", "(", "DeclarationExpression", "expression", ")", "{", "handleType", "(", "expression", ".", "getLeftExpression", "(", ")", ".", "getType", "(", ")", ",", "false", ",", "true", ")", ";", "expression", ".", "getRightExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "@", "Override", "public", "void", "visitVariableExpression", "(", "VariableExpression", "expression", ")", "{", "requestor", ".", "acceptUnknownReference", "(", "expression", ".", "getName", "(", ")", ".", "toCharArray", "(", ")", ",", "expression", ".", "getStart", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "visitField", "(", "FieldNode", "node", ")", "{", "super", ".", "visitField", "(", "node", ")", ";", "}", "@", "Override", "public", "void", "visitMethod", "(", "MethodNode", "node", ")", "{", "if", "(", "!", "node", ".", "isSynthetic", "(", ")", ")", "{", "handleType", "(", "node", ".", "getReturnType", "(", ")", ",", "false", ",", "true", ")", ";", "for", "(", "Parameter", "param", ":", "node", ".", "getParameters", "(", ")", ")", "{", "handleType", "(", "param", ".", "getType", "(", ")", ",", "false", ",", "true", ")", ";", "}", "}", "super", ".", "visitMethod", "(", "node", ")", ";", "}", "@", "Override", "public", "void", "visitClass", "(", "ClassNode", "node", ")", "{", "if", "(", "!", "node", ".", "isSynthetic", "(", ")", ")", "{", "handleType", "(", "node", ",", "false", ",", "false", ")", ";", "handleType", "(", "node", ".", "getSuperClass", "(", ")", ",", "false", ",", "true", ")", ";", "for", "(", "ClassNode", "impls", ":", "node", ".", "getInterfaces", "(", ")", ")", "{", "handleType", "(", "impls", ",", "false", ",", "true", ")", ";", "}", "}", "visitAnnotations", "(", "node", ")", ";", "node", ".", "visitContents", "(", "this", ")", ";", "for", "(", "Statement", "element", ":", "(", "Iterable", "<", "Statement", ">", ")", "node", ".", "getObjectInitializerStatements", "(", ")", ")", "{", "element", ".", "visit", "(", "this", ")", ";", "}", "}", "@", "Override", "public", "void", "visitClosureExpression", "(", "ClosureExpression", "node", ")", "{", "if", "(", "node", ".", "getParameters", "(", ")", "!=", "null", ")", "{", "for", "(", "Parameter", "param", ":", "node", ".", "getParameters", "(", ")", ")", "{", "handleType", "(", "param", ".", "getType", "(", ")", ",", "false", ",", "true", ")", ";", "}", "}", "super", ".", "visitClosureExpression", "(", "node", ")", ";", "}", "@", "Override", "public", "void", "visitAnnotations", "(", "AnnotatedNode", "node", ")", "{", "for", "(", "AnnotationNode", "an", ":", "(", "Iterable", "<", "AnnotationNode", ">", ")", "node", ".", "getAnnotations", "(", ")", ")", "{", "handleType", "(", "an", ".", "getClassNode", "(", ")", ",", "true", ",", "true", ")", ";", "}", "super", ".", "visitAnnotations", "(", "node", ")", ";", "}", "private", "void", "handleType", "(", "ClassNode", "node", ",", "boolean", "isAnnotation", ",", "boolean", "useQualifiedName", ")", "{", "if", "(", "node", "==", "null", ")", "{", "Util", ".", "log", "(", "new", "Status", "(", "IStatus", ".", "WARNING", ",", "Activator", ".", "PLUGIN_ID", ",", "\"\"", "+", "module", ".", "getDescription", "(", ")", ",", "new", "RuntimeException", "(", ")", ")", ")", ";", "return", ";", "}", "if", "(", "isAnnotation", ")", "{", "requestor", ".", "acceptAnnotationTypeReference", "(", "splitName", "(", "node", ",", "useQualifiedName", ")", ",", "node", ".", "getStart", "(", ")", ",", "node", ".", "getEnd", "(", ")", ")", ";", "}", "else", "{", "ClassNode", "componentType", "=", "node", ".", "getComponentType", "(", ")", ";", "requestor", ".", "acceptTypeReference", "(", "splitName", "(", "componentType", "!=", "null", "?", "componentType", ":", "node", ",", "useQualifiedName", ")", ",", "node", ".", "getStart", "(", ")", ",", "node", ".", "getEnd", "(", ")", ")", ";", "}", "if", "(", "node", ".", "isUsingGenerics", "(", ")", "&&", "node", ".", "getGenericsTypes", "(", ")", "!=", "null", ")", "{", "for", "(", "GenericsType", "gen", ":", "node", ".", "getGenericsTypes", "(", ")", ")", "{", "ClassNode", "lowerBound", "=", "gen", ".", "getLowerBound", "(", ")", ";", "if", "(", "lowerBound", "!=", "null", ")", "{", "handleType", "(", "lowerBound", ",", "lowerBound", ".", "isAnnotationDefinition", "(", ")", ",", "true", ")", ";", "}", "if", "(", "gen", ".", "getUpperBounds", "(", ")", "!=", "null", ")", "{", "for", "(", "ClassNode", "upper", ":", "gen", ".", "getUpperBounds", "(", ")", ")", "{", "if", "(", "!", "upper", ".", "getName", "(", ")", ".", "equals", "(", "node", ".", "getName", "(", ")", ")", ")", "{", "handleType", "(", "upper", ",", "upper", ".", "isAnnotationDefinition", "(", ")", ",", "true", ")", ";", "}", "}", "}", "ClassNode", "genType", "=", "gen", ".", "getType", "(", ")", ";", "if", "(", "genType", "!=", "null", "&&", "gen", ".", "getName", "(", ")", ".", "charAt", "(", "0", ")", "!=", "'?'", ")", "{", "handleType", "(", "genType", ",", "genType", ".", "isAnnotationDefinition", "(", ")", ",", "true", ")", ";", "}", "}", "}", "}", "private", "char", "[", "]", "[", "]", "splitName", "(", "ClassNode", "node", ",", "boolean", "useQualifiedName", ")", "{", "String", "name", "=", "useQualifiedName", "?", "node", ".", "getName", "(", ")", ":", "node", ".", "getNameWithoutPackage", "(", ")", ";", "String", "[", "]", "nameArr", "=", "name", ".", "split", "(", "\"\\\\.\"", ")", ";", "char", "[", "]", "[", "]", "nameCharArr", "=", "new", "char", "[", "nameArr", ".", "length", "]", "[", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nameArr", ".", "length", ";", "i", "++", ")", "{", "nameCharArr", "[", "i", "]", "=", "nameArr", "[", "i", "]", ".", "toCharArray", "(", ")", ";", "}", "return", "nameCharArr", ";", "}", "}", "</s>" ]
6,779
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Arrays", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "LinkedList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilerConfiguration", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ErrorCollector", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "Phases", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "EventHandler", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "LanguageSupport", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyCompilationUnitDeclaration", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyErrorCollectorForJDT", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyTypeDeclaration", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "JDTResolver", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ".", "GroovyCompilationUnit", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ".", "GroovyNature", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ISourceRange", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "WorkingCopyOwner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "IJavaSearchScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchPattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ContentTypeUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "GroovyUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ReflectionUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ".", "ITypeRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ".", "TypeInferencingVisitorFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ".", "TypeInferencingVisitorWithRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ".", "TypeRequestorFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "DefaultErrorHandlingPolicies", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "IProblemFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ISourceElementRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "SourceElementParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "TypeDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "Parser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "DefaultProblemFactory", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "BinaryMember", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "BinaryType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "ClassFile", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaModelManager", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "PackageFragment", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "indexing", ".", "IndexingParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "ImportMatchLocatorParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "MatchLocator", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "MatchLocatorParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "PossibleMatch", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "GroovyLanguageSupport", "implements", "LanguageSupport", "{", "public", "Parser", "getParser", "(", "Object", "requestor", ",", "CompilerOptions", "compilerOptions", ",", "ProblemReporter", "problemReporter", ",", "boolean", "parseLiteralExpressionsAsConstants", ",", "int", "variant", ")", "{", "if", "(", "variant", "==", "1", ")", "{", "return", "new", "MultiplexingParser", "(", "requestor", ",", "compilerOptions", ",", "problemReporter", ",", "parseLiteralExpressionsAsConstants", ")", ";", "}", "else", "if", "(", "variant", "==", "2", ")", "{", "return", "new", "MultiplexingCommentRecorderParser", "(", "requestor", ",", "compilerOptions", ",", "problemReporter", ",", "parseLiteralExpressionsAsConstants", ")", ";", "}", "else", "{", "return", "new", "MultiplexingCommentRecorderParser", "(", "requestor", ",", "compilerOptions", ",", "problemReporter", ",", "parseLiteralExpressionsAsConstants", ",", "false", ")", ";", "}", "}", "public", "IndexingParser", "getIndexingParser", "(", "ISourceElementRequestor", "requestor", ",", "IProblemFactory", "problemFactory", ",", "CompilerOptions", "options", ",", "boolean", "reportLocalDeclarations", ",", "boolean", "optimizeStringLiterals", ",", "boolean", "useSourceJavadocParser", ")", "{", "return", "new", "MultiplexingIndexingParser", "(", "requestor", ",", "problemFactory", ",", "options", ",", "reportLocalDeclarations", ",", "optimizeStringLiterals", ",", "useSourceJavadocParser", ")", ";", "}", "public", "MatchLocatorParser", "getMatchLocatorParserParser", "(", "ProblemReporter", "problemReporter", ",", "MatchLocator", "locator", ")", "{", "return", "new", "MultiplexingMatchLocatorParser", "(", "problemReporter", ",", "locator", ")", ";", "}", "public", "ImportMatchLocatorParser", "getImportMatchLocatorParserParser", "(", "ProblemReporter", "problemReporter", ",", "MatchLocator", "locator", ")", "{", "return", "new", "MultiplexingImportMatchLocatorParser", "(", "problemReporter", ",", "locator", ")", ";", "}", "public", "SourceElementParser", "getSourceElementParser", "(", "ISourceElementRequestor", "requestor", ",", "IProblemFactory", "problemFactory", ",", "CompilerOptions", "options", ",", "boolean", "reportLocalDeclarations", ",", "boolean", "optimizeStringLiterals", ",", "boolean", "useSourceJavadocParser", ")", "{", "ProblemReporter", "problemReporter", "=", "new", "ProblemReporter", "(", "DefaultErrorHandlingPolicies", ".", "proceedWithAllProblems", "(", ")", ",", "options", ",", "new", "DefaultProblemFactory", "(", ")", ")", ";", "return", "new", "MultiplexingSourceElementRequestorParser", "(", "problemReporter", ",", "requestor", ",", "problemFactory", ",", "options", ",", "reportLocalDeclarations", ",", "optimizeStringLiterals", ")", ";", "}", "public", "CompilationUnit", "newCompilationUnit", "(", "PackageFragment", "parent", ",", "String", "name", ",", "WorkingCopyOwner", "owner", ")", "{", "if", "(", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "name", ")", ")", "{", "return", "new", "GroovyCompilationUnit", "(", "parent", ",", "name", ",", "owner", ")", ";", "}", "else", "{", "return", "new", "CompilationUnit", "(", "parent", ",", "name", ",", "owner", ")", ";", "}", "}", "public", "CompilationUnitDeclaration", "newCompilationUnitDeclaration", "(", "ICompilationUnit", "unit", ",", "ProblemReporter", "problemReporter", ",", "CompilationResult", "compilationResult", ",", "int", "sourceLength", ")", "{", "if", "(", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "compilationResult", ".", "getFileName", "(", ")", ")", ")", "{", "CompilerConfiguration", "groovyCompilerConfig", "=", "new", "CompilerConfiguration", "(", ")", ";", "ErrorCollector", "errorCollector", "=", "new", "GroovyErrorCollectorForJDT", "(", "groovyCompilerConfig", ")", ";", "SourceUnit", "groovySourceUnit", "=", "new", "SourceUnit", "(", "new", "String", "(", "compilationResult", ".", "getFileName", "(", ")", ")", ",", "new", "String", "(", "unit", ".", "getContents", "(", ")", ")", ",", "groovyCompilerConfig", ",", "null", ",", "errorCollector", ")", ";", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", "groovyCU", "=", "new", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilationUnit", "(", "groovyCompilerConfig", ")", ";", "JDTResolver", "resolver", "=", "new", "JDTResolver", "(", "groovyCU", ")", ";", "groovyCU", ".", "setResolveVisitor", "(", "resolver", ")", ";", "compilationResult", ".", "lineSeparatorPositions", "=", "GroovyUtils", ".", "getSourceLineSeparatorsIn", "(", "unit", ".", "getContents", "(", ")", ")", ";", "groovyCU", ".", "addSource", "(", "groovySourceUnit", ")", ";", "GroovyCompilationUnitDeclaration", "gcuDeclaration", "=", "new", "GroovyCompilationUnitDeclaration", "(", "problemReporter", ",", "compilationResult", ",", "sourceLength", ",", "groovyCU", ",", "groovySourceUnit", ",", "null", ")", ";", "gcuDeclaration", ".", "processToPhase", "(", "Phases", ".", "CONVERSION", ")", ";", "gcuDeclaration", ".", "populateCompilationUnitDeclaration", "(", ")", ";", "for", "(", "TypeDeclaration", "decl", ":", "gcuDeclaration", ".", "types", ")", "{", "GroovyTypeDeclaration", "gtDeclaration", "=", "(", "GroovyTypeDeclaration", ")", "decl", ";", "resolver", ".", "record", "(", "gtDeclaration", ")", ";", "}", "return", "gcuDeclaration", ";", "}", "else", "{", "return", "new", "CompilationUnitDeclaration", "(", "problemReporter", ",", "compilationResult", ",", "sourceLength", ")", ";", "}", "}", "public", "boolean", "isInterestingProject", "(", "IProject", "project", ")", "{", "return", "GroovyNature", ".", "hasGroovyNature", "(", "project", ")", ";", "}", "public", "boolean", "isSourceFile", "(", "String", "fileName", ",", "boolean", "isInterestingProject", ")", "{", "if", "(", "isInterestingProject", ")", "{", "return", "Util", ".", "isJavaLikeFileName", "(", "fileName", ")", ";", "}", "else", "{", "return", "ContentTypeUtils", ".", "isJavaLikeButNotGroovyLikeExtension", "(", "fileName", ")", ";", "}", "}", "public", "boolean", "isInterestingSourceFile", "(", "String", "fileName", ")", "{", "return", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "fileName", ")", ";", "}", "public", "boolean", "maybePerformDelegatedSearch", "(", "PossibleMatch", "possibleMatch", ",", "SearchPattern", "pattern", ",", "SearchRequestor", "requestor", ")", "{", "if", "(", "possibleMatch", ".", "openable", "!=", "null", "&&", "possibleMatch", ".", "openable", ".", "exists", "(", ")", ")", "{", "ITypeRequestor", "typeRequestor", "=", "new", "TypeRequestorFactory", "(", ")", ".", "createRequestor", "(", "possibleMatch", ",", "pattern", ",", "requestor", ")", ";", "if", "(", "typeRequestor", "!=", "null", ")", "{", "TypeInferencingVisitorWithRequestor", "visitor", "=", "new", "TypeInferencingVisitorFactory", "(", ")", ".", "createVisitor", "(", "possibleMatch", ")", ";", "visitor", ".", "visitCompilationUnit", "(", "typeRequestor", ")", ";", "return", "true", ";", "}", "}", "return", "false", ";", "}", "public", "EventHandler", "getEventHandler", "(", ")", "{", "return", "new", "GroovyEventHandler", "(", ")", ";", "}", "public", "void", "filterNonSourceMembers", "(", "BinaryType", "binaryType", ")", "{", "try", "{", "IJavaElement", "[", "]", "childrenArr", "=", "binaryType", ".", "getChildren", "(", ")", ";", "List", "<", "IJavaElement", ">", "children", "=", "new", "ArrayList", "<", "IJavaElement", ">", "(", "Arrays", ".", "asList", "(", "childrenArr", ")", ")", ";", "List", "<", "JavaElement", ">", "removedChildren", "=", "new", "LinkedList", "<", "JavaElement", ">", "(", ")", ";", "for", "(", "Iterator", "<", "IJavaElement", ">", "childIter", "=", "children", ".", "iterator", "(", ")", ";", "childIter", ".", "hasNext", "(", ")", ";", ")", "{", "IJavaElement", "child", "=", "childIter", ".", "next", "(", ")", ";", "if", "(", "child", "instanceof", "BinaryMember", ")", "{", "BinaryMember", "binaryChild", "=", "(", "BinaryMember", ")", "child", ";", "ISourceRange", "range", "=", "binaryChild", ".", "getSourceRange", "(", ")", ";", "if", "(", "range", "==", "null", "||", "range", ".", "getOffset", "(", ")", "==", "-", "1", ")", "{", "removedChildren", ".", "add", "(", "binaryChild", ")", ";", "childIter", ".", "remove", "(", ")", ";", "}", "}", "}", "JavaElement", "[", "]", "newChildrenArr", "=", "children", ".", "toArray", "(", "new", "JavaElement", "[", "children", ".", "size", "(", ")", "]", ")", ";", "Object", "classFileInfo", "=", "(", "(", "ClassFile", ")", "binaryType", ".", "getParent", "(", ")", ")", ".", "getElementInfo", "(", ")", ";", "ReflectionUtils", ".", "setPrivateField", "(", "classFileInfo", ".", "getClass", "(", ")", ",", "\"\"", ",", "classFileInfo", ",", "newChildrenArr", ")", ";", "JavaModelManager", "manager", "=", "JavaModelManager", ".", "getJavaModelManager", "(", ")", ";", "for", "(", "JavaElement", "removedChild", ":", "removedChildren", ")", "{", "if", "(", "removedChild", "instanceof", "BinaryType", ")", "{", "manager", ".", "removeInfoAndChildren", "(", "(", "JavaElement", ")", "removedChild", ".", "getParent", "(", ")", ")", ";", "}", "else", "{", "manager", ".", "removeInfoAndChildren", "(", "removedChild", ")", ";", "}", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "e", ".", "printStackTrace", "(", ")", ";", "}", "}", "public", "static", "ISearchScopeExpander", "searchScopeExpander", ";", "public", "IJavaSearchScope", "expandSearchScope", "(", "IJavaSearchScope", "scope", ",", "SearchPattern", "pattern", ",", "SearchRequestor", "requestor", ")", "{", "if", "(", "searchScopeExpander", "!=", "null", ")", "{", "return", "searchScopeExpander", ".", "expandSearchScope", "(", "scope", ",", "pattern", ",", "requestor", ")", ";", "}", "return", "scope", ";", "}", "}", "</s>" ]
6,780
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ".", "GroovyCompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "IJavaSearchScope", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchPattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchRequestor", ";", "public", "interface", "ISearchScopeExpander", "{", "IJavaSearchScope", "expandSearchScope", "(", "IJavaSearchScope", "scope", ",", "SearchPattern", "pattern", ",", "SearchRequestor", "requestor", ")", ";", "}", "</s>" ]
6,781
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ContentTypeUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "ImportMatchLocatorParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "MatchLocator", ";", "public", "class", "MultiplexingImportMatchLocatorParser", "extends", "ImportMatchLocatorParser", "{", "GroovyParser", "groovyParser", ";", "protected", "MultiplexingImportMatchLocatorParser", "(", "ProblemReporter", "problemReporter", ",", "MatchLocator", "locator", ")", "{", "super", "(", "problemReporter", ",", "locator", ")", ";", "groovyParser", "=", "new", "GroovyParser", "(", "locator", ".", "options", ",", "problemReporter", ",", "false", ",", "true", ")", ";", "}", "@", "Override", "public", "CompilationUnitDeclaration", "dietParse", "(", "ICompilationUnit", "sourceUnit", ",", "CompilationResult", "compilationResult", ")", "{", "if", "(", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "sourceUnit", ".", "getFileName", "(", ")", ")", ")", "{", "return", "new", "GroovyParser", "(", "this", ".", "groovyParser", ".", "getCompilerOptions", "(", ")", ",", "this", ".", "groovyParser", ".", "problemReporter", ",", "false", ",", "true", ")", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "else", "{", "return", "super", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "}", "}", "</s>" ]
6,782
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ContentTypeUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "parser", ".", "Parser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "MultiplexingParser", "extends", "Parser", "{", "GroovyParser", "groovyParser", ";", "public", "MultiplexingParser", "(", "Object", "requestor", ",", "CompilerOptions", "compilerOptions", ",", "ProblemReporter", "problemReporter", ",", "boolean", "optimizeStringLiterals", ")", "{", "super", "(", "problemReporter", ",", "optimizeStringLiterals", ")", ";", "groovyParser", "=", "new", "GroovyParser", "(", "requestor", ",", "compilerOptions", ",", "problemReporter", ",", "true", ",", "false", ")", ";", "}", "@", "Override", "public", "CompilationUnitDeclaration", "dietParse", "(", "ICompilationUnit", "sourceUnit", ",", "CompilationResult", "compilationResult", ")", "{", "if", "(", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "sourceUnit", ".", "getFileName", "(", ")", ")", ")", "{", "return", "groovyParser", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "else", "{", "return", "super", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "}", "@", "Override", "public", "void", "reset", "(", ")", "{", "groovyParser", ".", "reset", "(", ")", ";", "}", "}", "</s>" ]
6,783
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "EventHandler", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "JavaProject", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "GroovyEventHandler", "implements", "EventHandler", "{", "public", "void", "handle", "(", "JavaProject", "javaProject", ",", "String", "event", ")", "{", "if", "(", "event", ".", "equals", "(", "\"\"", ")", ")", "{", "if", "(", "javaProject", "!=", "null", ")", "{", "GroovyParser", ".", "tidyCache", "(", "javaProject", ".", "getProject", "(", ")", ".", "getName", "(", ")", ")", ";", "}", "}", "else", "if", "(", "event", ".", "equals", "(", "\"close\"", ")", ")", "{", "if", "(", "javaProject", "!=", "null", ")", "{", "String", "projectName", "=", "javaProject", ".", "getProject", "(", ")", ".", "getName", "(", ")", ";", "GroovyParser", ".", "closeClassLoader", "(", "projectName", ")", ";", "GroovyParser", ".", "tidyCache", "(", "projectName", ")", ";", "}", "}", "}", "}", "</s>" ]
6,784
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ContentTypeUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "impl", ".", "CompilerOptions", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "CommentRecorderParser", ";", "@", "SuppressWarnings", "(", "\"restriction\"", ")", "public", "class", "MultiplexingCommentRecorderParser", "extends", "CommentRecorderParser", "{", "GroovyParser", "groovyParser", ";", "private", "boolean", "allowTransforms", "=", "true", ";", "public", "MultiplexingCommentRecorderParser", "(", "Object", "requestor", ",", "CompilerOptions", "compilerOptions", ",", "ProblemReporter", "problemReporter", ",", "boolean", "optimizeStringLiterals", ",", "boolean", "allowTransforms", ")", "{", "super", "(", "problemReporter", ",", "optimizeStringLiterals", ")", ";", "groovyParser", "=", "new", "GroovyParser", "(", "requestor", ",", "compilerOptions", ",", "problemReporter", ",", "allowTransforms", ",", "true", ")", ";", "this", ".", "allowTransforms", "=", "allowTransforms", ";", "}", "public", "MultiplexingCommentRecorderParser", "(", "Object", "requestor", ",", "CompilerOptions", "compilerOptions", ",", "ProblemReporter", "problemReporter", ",", "boolean", "optimizeStringLiterals", ")", "{", "this", "(", "requestor", ",", "compilerOptions", ",", "problemReporter", ",", "optimizeStringLiterals", ",", "true", ")", ";", "}", "@", "Override", "public", "CompilationUnitDeclaration", "dietParse", "(", "ICompilationUnit", "sourceUnit", ",", "CompilationResult", "compilationResult", ")", "{", "if", "(", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "sourceUnit", ".", "getFileName", "(", ")", ")", ")", "{", "if", "(", "this", ".", "scanner", "!=", "null", ")", "{", "this", ".", "scanner", ".", "setSource", "(", "sourceUnit", ".", "getContents", "(", ")", ")", ";", "}", "return", "new", "GroovyParser", "(", "this", ".", "groovyParser", ".", "requestor", ",", "this", ".", "groovyParser", ".", "getCompilerOptions", "(", ")", ",", "this", ".", "groovyParser", ".", "problemReporter", ",", "allowTransforms", ",", "true", ")", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "else", "{", "return", "super", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "}", "@", "Override", "public", "void", "reset", "(", ")", "{", "groovyParser", ".", "reset", "(", ")", ";", "}", "}", "</s>" ]
6,785
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "integration", ".", "internal", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "GroovyParser", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ContentTypeUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "CompilationResult", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "ast", ".", "CompilationUnitDeclaration", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "env", ".", "ICompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "compiler", ".", "problem", ".", "ProblemReporter", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "MatchLocator", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "MatchLocatorParser", ";", "public", "class", "MultiplexingMatchLocatorParser", "extends", "MatchLocatorParser", "{", "GroovyParser", "groovyParser", ";", "protected", "MultiplexingMatchLocatorParser", "(", "ProblemReporter", "problemReporter", ",", "MatchLocator", "locator", ")", "{", "super", "(", "problemReporter", ",", "locator", ")", ";", "groovyParser", "=", "new", "GroovyParser", "(", "locator", ".", "options", ",", "problemReporter", ",", "false", ",", "true", ")", ";", "}", "@", "Override", "public", "CompilationUnitDeclaration", "dietParse", "(", "ICompilationUnit", "sourceUnit", ",", "CompilationResult", "compilationResult", ")", "{", "if", "(", "ContentTypeUtils", ".", "isGroovyLikeFileName", "(", "sourceUnit", ".", "getFileName", "(", ")", ")", ")", "{", "return", "new", "GroovyParser", "(", "this", ".", "groovyParser", ".", "getCompilerOptions", "(", ")", ",", "this", ".", "groovyParser", ".", "problemReporter", ",", "false", ",", "true", ")", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "else", "{", "return", "super", ".", "dietParse", "(", "sourceUnit", ",", "compilationResult", ")", ";", "}", "}", "}", "</s>" ]
6,786
[ "<s>", "package", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "control", ";", "import", "groovy", ".", "lang", ".", "GroovyClassLoader", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "CompilerConfiguration", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "ErrorCollector", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IFile", ";", "public", "class", "EclipseSourceUnit", "extends", "SourceUnit", "{", "final", "private", "IFile", "file", ";", "public", "EclipseSourceUnit", "(", "IFile", "resource", ",", "String", "filepath", ",", "String", "string", ",", "CompilerConfiguration", "groovyCompilerConfig", ",", "GroovyClassLoader", "classLoader", ",", "ErrorCollector", "errorCollector", ")", "{", "super", "(", "filepath", ",", "string", ",", "groovyCompilerConfig", ",", "classLoader", ",", "errorCollector", ")", ";", "this", ".", "file", "=", "resource", ";", "}", "public", "IFile", "getEclipseFile", "(", ")", "{", "return", "file", ";", "}", "}", "</s>" ]
6,787
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "public", "interface", "ITypeRequestor", "{", "public", "static", "enum", "VisitStatus", "{", "CONTINUE", "(", "0", ")", ",", "CANCEL_BRANCH", "(", "1", ")", ",", "CANCEL_MEMBER", "(", "2", ")", ",", "STOP_VISIT", "(", "3", ")", ";", "int", "val", ";", "private", "VisitStatus", "(", "int", "val", ")", "{", "this", ".", "val", "=", "val", ";", "}", "public", "static", "VisitStatus", "merge", "(", "VisitStatus", "status1", ",", "VisitStatus", "status2", ")", "{", "if", "(", "status1", ".", "val", ">", "status2", ".", "val", ")", "{", "return", "status1", ";", "}", "return", "status2", ";", "}", "}", "VisitStatus", "acceptASTNode", "(", "ASTNode", "node", ",", "TypeLookupResult", "result", ",", "IJavaElement", "enclosingElement", ")", ";", "}", "</s>" ]
6,788
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "LinkedHashSet", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "Stack", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GenericsType", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "IStatus", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Status", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "GenericsMapper", "{", "private", "Stack", "<", "Map", "<", "String", ",", "ClassNode", ">", ">", "allGenerics", "=", "new", "Stack", "<", "Map", "<", "String", ",", "ClassNode", ">", ">", "(", ")", ";", "public", "static", "GenericsMapper", "gatherGenerics", "(", "ClassNode", "resolvedType", ",", "ClassNode", "declaringType", ")", "{", "ClassNode", "ucandidate", "=", "resolvedType", ".", "redirect", "(", ")", ";", "ClassNode", "rcandidate", "=", "resolvedType", ";", "GenericsType", "[", "]", "ugts", ";", "GenericsType", "[", "]", "rgts", ";", "GenericsMapper", "mapper", "=", "new", "GenericsMapper", "(", ")", ";", "LinkedHashSet", "<", "ClassNode", ">", "uHierarchy", "=", "new", "LinkedHashSet", "<", "ClassNode", ">", "(", ")", ";", "VariableScope", ".", "createTypeHierarchy", "(", "ucandidate", ",", "uHierarchy", ",", "false", ")", ";", "Iterator", "<", "ClassNode", ">", "uIter", "=", "uHierarchy", ".", "iterator", "(", ")", ";", "LinkedHashSet", "<", "ClassNode", ">", "rHierarchy", "=", "new", "LinkedHashSet", "<", "ClassNode", ">", "(", ")", ";", "VariableScope", ".", "createTypeHierarchy", "(", "rcandidate", ",", "rHierarchy", ",", "true", ")", ";", "Iterator", "<", "ClassNode", ">", "rIter", "=", "rHierarchy", ".", "iterator", "(", ")", ";", "while", "(", "uIter", ".", "hasNext", "(", ")", "&&", "rIter", ".", "hasNext", "(", ")", ")", "{", "ucandidate", "=", "uIter", ".", "next", "(", ")", ";", "rcandidate", "=", "rIter", ".", "next", "(", ")", ";", "ugts", "=", "ucandidate", ".", "getGenericsTypes", "(", ")", ";", "ugts", "=", "ugts", "==", "null", "?", "VariableScope", ".", "NO_GENERICS", ":", "ugts", ";", "rgts", "=", "rcandidate", ".", "getGenericsTypes", "(", ")", ";", "rgts", "=", "rgts", "==", "null", "?", "VariableScope", ".", "NO_GENERICS", ":", "rgts", ";", "HashMap", "<", "String", ",", "ClassNode", ">", "resolved", "=", "new", "HashMap", "<", "String", ",", "ClassNode", ">", "(", "2", ",", "1.0f", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "rgts", ".", "length", "&&", "i", "<", "ugts", ".", "length", ";", "i", "++", ")", "{", "resolved", ".", "put", "(", "ugts", "[", "i", "]", ".", "getName", "(", ")", ",", "mapper", ".", "resolveParameter", "(", "rgts", "[", "i", "]", ",", "0", ")", ")", ";", "}", "mapper", ".", "allGenerics", ".", "push", "(", "resolved", ")", ";", "if", "(", "rcandidate", ".", "getName", "(", ")", ".", "equals", "(", "declaringType", ".", "getName", "(", ")", ")", ")", "{", "break", ";", "}", "}", "return", "mapper", ";", "}", "boolean", "hasGenerics", "(", ")", "{", "return", "!", "allGenerics", ".", "isEmpty", "(", ")", "&&", "allGenerics", ".", "peek", "(", ")", ".", "size", "(", ")", ">", "0", ";", "}", "public", "ClassNode", "resolveParameter", "(", "GenericsType", "topGT", ",", "int", "depth", ")", "{", "if", "(", "depth", ">", "10", ")", "{", "Util", ".", "log", "(", "new", "Status", "(", "IStatus", ".", "WARNING", ",", "\"\"", ",", "\"\"", "+", "topGT", ")", ")", ";", "return", "topGT", ".", "getType", "(", ")", ";", "}", "if", "(", "allGenerics", ".", "isEmpty", "(", ")", ")", "{", "return", "topGT", ".", "getType", "(", ")", ";", "}", "ClassNode", "origType", "=", "findParameter", "(", "topGT", ".", "getName", "(", ")", ",", "topGT", ".", "getType", "(", ")", ")", ";", "if", "(", "origType", ".", "getGenericsTypes", "(", ")", "!=", "null", ")", "{", "origType", "=", "VariableScope", ".", "clone", "(", "origType", ")", ";", "GenericsType", "[", "]", "genericsTypes", "=", "origType", ".", "getGenericsTypes", "(", ")", ";", "for", "(", "GenericsType", "genericsType", ":", "genericsTypes", ")", "{", "if", "(", "genericsType", ".", "getName", "(", ")", ".", "equals", "(", "topGT", ".", "getName", "(", ")", ")", ")", "{", "continue", ";", "}", "genericsType", ".", "setType", "(", "findParameter", "(", "genericsType", ".", "getName", "(", ")", ",", "resolveParameter", "(", "genericsType", ",", "depth", "+", "1", ")", ")", ")", ";", "genericsType", ".", "setLowerBound", "(", "null", ")", ";", "genericsType", ".", "setUpperBounds", "(", "null", ")", ";", "genericsType", ".", "setName", "(", "genericsType", ".", "getType", "(", ")", ".", "getName", "(", ")", ")", ";", "}", "}", "return", "origType", ";", "}", "ClassNode", "findParameter", "(", "String", "parameterName", ",", "ClassNode", "defaultType", ")", "{", "if", "(", "allGenerics", ".", "isEmpty", "(", ")", ")", "{", "return", "defaultType", ";", "}", "ClassNode", "type", "=", "allGenerics", ".", "peek", "(", ")", ".", "get", "(", "parameterName", ")", ";", "if", "(", "type", "==", "null", ")", "{", "return", "defaultType", ";", "}", "return", "type", ";", "}", "}", "</s>" ]
6,789
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ".", "GroovyCompilationUnit", ";", "import", "org", ".", "eclipse", ".", "core", ".", "resources", ".", "IProject", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IOpenable", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "PossibleMatch", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "TypeInferencingVisitorFactory", "{", "public", "TypeInferencingVisitorWithRequestor", "createVisitor", "(", "PossibleMatch", "possibleMatch", ")", "{", "try", "{", "IOpenable", "openable", "=", "possibleMatch", ".", "openable", ";", "if", "(", "openable", "instanceof", "GroovyCompilationUnit", ")", "{", "TypeInferencingVisitorWithRequestor", "visitor", "=", "new", "TypeInferencingVisitorWithRequestor", "(", "(", "GroovyCompilationUnit", ")", "openable", ",", "createLookups", "(", "(", "(", "GroovyCompilationUnit", ")", "openable", ")", ".", "getJavaProject", "(", ")", ".", "getProject", "(", ")", ")", ")", ";", "return", "visitor", ";", "}", "else", "{", "Util", ".", "log", "(", "new", "RuntimeException", "(", ")", ",", "\"\"", "+", "new", "String", "(", "possibleMatch", ".", "getFileName", "(", ")", ")", ")", ";", "}", "}", "catch", "(", "Exception", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "possibleMatch", ".", "document", ".", "getPath", "(", ")", ")", ";", "}", "return", "null", ";", "}", "public", "TypeInferencingVisitorWithRequestor", "createVisitor", "(", "GroovyCompilationUnit", "unit", ")", "{", "return", "new", "TypeInferencingVisitorWithRequestor", "(", "unit", ",", "createLookups", "(", "unit", ".", "getJavaProject", "(", ")", ".", "getProject", "(", ")", ")", ")", ";", "}", "private", "ITypeLookup", "[", "]", "createLookups", "(", "IProject", "project", ")", "{", "ITypeLookup", "[", "]", "lookups", ";", "try", "{", "List", "<", "ITypeLookup", ">", "lookupsList", "=", "TypeLookupRegistry", ".", "getRegistry", "(", ")", ".", "getLookupsFor", "(", "project", ")", ";", "lookupsList", ".", "add", "(", "new", "CategoryTypeLookup", "(", ")", ")", ";", "lookupsList", ".", "add", "(", "new", "SimpleTypeLookup", "(", ")", ")", ";", "lookups", "=", "lookupsList", ".", "toArray", "(", "new", "ITypeLookup", "[", "0", "]", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "project", ".", "getName", "(", ")", "+", "\"\"", ")", ";", "lookups", "=", "new", "ITypeLookup", "[", "]", "{", "new", "CategoryTypeLookup", "(", ")", ",", "new", "SimpleTypeLookup", "(", ")", "}", ";", "}", "return", "lookups", ";", "}", "}", "</s>" ]
6,790
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotatedNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ImportNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Parameter", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Variable", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "BinaryExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "DeclarationExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ListExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "TupleExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "VariableExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "Types", ";", "public", "class", "AssignmentStorer", "{", "public", "void", "storeAssignment", "(", "BinaryExpression", "assign", ",", "VariableScope", "scope", ",", "ClassNode", "rhsType", ")", "{", "if", "(", "assign", "instanceof", "DeclarationExpression", ")", "{", "DeclarationExpression", "declExpr", "=", "(", "DeclarationExpression", ")", "assign", ";", "if", "(", "declExpr", ".", "isMultipleAssignmentDeclaration", "(", ")", ")", "{", "TupleExpression", "tuple", "=", "(", "TupleExpression", ")", "declExpr", ".", "getLeftExpression", "(", ")", ";", "handleMultiAssignment", "(", "scope", ",", "rhsType", ",", "declExpr", ",", "tuple", ")", ";", "}", "else", "{", "VariableExpression", "variableExpression", "=", "declExpr", ".", "getVariableExpression", "(", ")", ";", "ClassNode", "varType", ";", "if", "(", "variableExpression", ".", "getOriginType", "(", ")", "!=", "null", ")", "{", "varType", "=", "variableExpression", ".", "getOriginType", "(", ")", ";", "}", "else", "{", "varType", "=", "variableExpression", ".", "getType", "(", ")", ";", "}", "ClassNode", "typeToStore", ";", "if", "(", "!", "VariableScope", ".", "isVoidOrObject", "(", "varType", ")", "&&", "!", "varType", ".", "equals", "(", "VariableScope", ".", "OBJECT_CLASS_NODE", ")", ")", "{", "typeToStore", "=", "varType", ";", "}", "else", "if", "(", "rhsType", "!=", "null", ")", "{", "typeToStore", "=", "rhsType", ";", "}", "else", "{", "typeToStore", "=", "VariableScope", ".", "OBJECT_CLASS_NODE", ";", "}", "scope", ".", "addVariable", "(", "variableExpression", ".", "getName", "(", ")", ",", "typeToStore", ",", "null", ")", ";", "}", "}", "else", "{", "if", "(", "isInterestingOperation", "(", "assign", ")", "&&", "!", "VariableScope", ".", "isVoidOrObject", "(", "rhsType", ")", ")", "{", "if", "(", "assign", ".", "getLeftExpression", "(", ")", "instanceof", "VariableExpression", ")", "{", "VariableExpression", "var", "=", "(", "VariableExpression", ")", "assign", ".", "getLeftExpression", "(", ")", ";", "ClassNode", "declaringType", "=", "findDeclaringType", "(", "var", ")", ";", "if", "(", "scope", ".", "inScriptRunMethod", "(", ")", ")", "{", "scope", ".", "updateOrAddVariable", "(", "var", ".", "getName", "(", ")", ",", "rhsType", ",", "declaringType", ")", ";", "}", "else", "{", "scope", ".", "updateVariable", "(", "var", ".", "getName", "(", ")", ",", "rhsType", ",", "declaringType", ")", ";", "}", "}", "else", "if", "(", "assign", ".", "getLeftExpression", "(", ")", "instanceof", "TupleExpression", ")", "{", "TupleExpression", "tuple", "=", "(", "TupleExpression", ")", "assign", ".", "getLeftExpression", "(", ")", ";", "handleMultiAssignment", "(", "scope", ",", "rhsType", ",", "assign", ",", "tuple", ")", ";", "}", "else", "{", "}", "}", "}", "}", "public", "void", "storeField", "(", "FieldNode", "node", ",", "VariableScope", "scope", ")", "{", "Expression", "init", "=", "node", ".", "getInitialExpression", "(", ")", ";", "if", "(", "!", "isObjectType", "(", "init", ")", ")", "{", "scope", ".", "addVariable", "(", "node", ".", "getName", "(", ")", ",", "init", ".", "getType", "(", ")", ",", "node", ".", "getDeclaringClass", "(", ")", ")", ";", "}", "}", "public", "void", "storeImport", "(", "ImportNode", "node", ",", "VariableScope", "scope", ")", "{", "ClassNode", "type", "=", "node", ".", "getType", "(", ")", ";", "if", "(", "node", ".", "isStar", "(", ")", "&&", "type", "!=", "null", ")", "{", "List", "<", "FieldNode", ">", "fields", "=", "type", ".", "getFields", "(", ")", ";", "for", "(", "FieldNode", "field", ":", "fields", ")", "{", "if", "(", "field", ".", "isStatic", "(", ")", ")", "{", "scope", ".", "addVariable", "(", "field", ".", "getName", "(", ")", ",", "field", ".", "getType", "(", ")", ",", "type", ")", ";", "}", "}", "List", "<", "MethodNode", ">", "methods", "=", "node", ".", "getType", "(", ")", ".", "getMethods", "(", ")", ";", "for", "(", "MethodNode", "method", ":", "methods", ")", "{", "if", "(", "method", ".", "isStatic", "(", ")", ")", "{", "scope", ".", "addVariable", "(", "method", ".", "getName", "(", ")", ",", "method", ".", "getReturnType", "(", ")", ",", "type", ")", ";", "}", "}", "}", "else", "{", "String", "fieldName", "=", "node", ".", "getFieldName", "(", ")", ";", "if", "(", "node", ".", "isStatic", "(", ")", "&&", "type", "!=", "null", "&&", "fieldName", "!=", "null", ")", "{", "String", "alias", ";", "if", "(", "node", ".", "getAlias", "(", ")", "!=", "null", ")", "{", "alias", "=", "node", ".", "getAlias", "(", ")", ";", "}", "else", "{", "alias", "=", "fieldName", ";", "}", "FieldNode", "field", "=", "type", ".", "getField", "(", "fieldName", ")", ";", "if", "(", "field", "!=", "null", ")", "{", "scope", ".", "addVariable", "(", "alias", ",", "field", ".", "getType", "(", ")", ",", "type", ")", ";", "}", "List", "<", "MethodNode", ">", "methods", "=", "type", ".", "getDeclaredMethods", "(", "fieldName", ")", ";", "if", "(", "methods", "!=", "null", ")", "{", "for", "(", "MethodNode", "method", ":", "methods", ")", "{", "scope", ".", "addVariable", "(", "alias", ",", "method", ".", "getReturnType", "(", ")", ",", "type", ")", ";", "}", "}", "}", "}", "}", "public", "void", "storeParameterType", "(", "Parameter", "node", ",", "VariableScope", "scope", ")", "{", "scope", ".", "addVariable", "(", "node", ")", ";", "}", "private", "void", "handleMultiAssignment", "(", "VariableScope", "scope", ",", "ClassNode", "objectExpressionType", ",", "BinaryExpression", "binaryExpr", ",", "TupleExpression", "tuple", ")", "{", "ClassNode", "maybeType", "=", "findComponentType", "(", "objectExpressionType", ")", ";", "ListExpression", "rhs", "=", "binaryExpr", ".", "getRightExpression", "(", ")", "instanceof", "ListExpression", "?", "(", "ListExpression", ")", "binaryExpr", ".", "getRightExpression", "(", ")", ":", "null", ";", "List", "<", "Expression", ">", "lhsExprs", "=", "(", "List", "<", "Expression", ">", ")", "(", "tuple", "==", "null", "?", "Collections", ".", "emptyList", "(", ")", ":", "tuple", ".", "getExpressions", "(", ")", ")", ";", "List", "<", "Expression", ">", "rhsExprs", "=", "(", "List", "<", "Expression", ">", ")", "(", "rhs", "==", "null", "?", "Collections", ".", "emptyList", "(", ")", ":", "rhs", ".", "getExpressions", "(", ")", ")", ";", "for", "(", "int", "i", "=", "0", ",", "lhsSize", "=", "lhsExprs", ".", "size", "(", ")", ",", "rhsSize", "=", "rhsExprs", ".", "size", "(", ")", ";", "i", "<", "lhsSize", ";", "i", "++", ")", "{", "Expression", "lhsExpr", "=", "lhsExprs", ".", "get", "(", "i", ")", ";", "ClassNode", "rhsType", "=", "i", "<", "rhsSize", "?", "rhsExprs", ".", "get", "(", "i", ")", ".", "getType", "(", ")", ":", "maybeType", ";", "if", "(", "lhsExpr", "instanceof", "VariableExpression", ")", "{", "scope", ".", "addVariable", "(", "(", "(", "Variable", ")", "lhsExpr", ")", ".", "getName", "(", ")", ",", "rhsType", ",", "null", ")", ";", "}", "}", "}", "private", "ClassNode", "findComponentType", "(", "ClassNode", "objectExpressionType", ")", "{", "if", "(", "objectExpressionType", "==", "null", ")", "{", "return", "VariableScope", ".", "OBJECT_CLASS_NODE", ";", "}", "else", "{", "return", "VariableScope", ".", "extractElementType", "(", "objectExpressionType", ")", ";", "}", "}", "private", "boolean", "isInterestingOperation", "(", "BinaryExpression", "assign", ")", "{", "switch", "(", "assign", ".", "getOperation", "(", ")", ".", "getType", "(", ")", ")", "{", "case", "Types", ".", "EQUALS", ":", "return", "true", ";", "default", ":", "return", "false", ";", "}", "}", "private", "ClassNode", "findDeclaringType", "(", "VariableExpression", "var", ")", "{", "return", "var", ".", "getAccessedVariable", "(", ")", "instanceof", "AnnotatedNode", "?", "(", "(", "AnnotatedNode", ")", "var", ".", "getAccessedVariable", "(", ")", ")", ".", "getDeclaringClass", "(", ")", ":", "null", ";", "}", "private", "boolean", "isObjectType", "(", "Expression", "init", ")", "{", "return", "init", "==", "null", "||", "ClassHelper", ".", "OBJECT_TYPE", ".", "equals", "(", "init", ".", "getType", "(", ")", ")", ";", "}", "}", "</s>" ]
6,791
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassCodeVisitorSupport", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "BinaryExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstantExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "FieldExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "VariableExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "public", "class", "EqualityVisitor", "extends", "ClassCodeVisitorSupport", "{", "private", "final", "ASTNode", "nodeToLookFor", ";", "private", "boolean", "nodeFound", "=", "false", ";", "public", "EqualityVisitor", "(", "ASTNode", "nodeToLookFor", ")", "{", "this", ".", "nodeToLookFor", "=", "nodeToLookFor", ";", "}", "public", "boolean", "doVisit", "(", "ASTNode", "toVisit", ")", "{", "toVisit", ".", "visit", "(", "this", ")", ";", "return", "nodeFound", ";", "}", "@", "Override", "protected", "SourceUnit", "getSourceUnit", "(", ")", "{", "return", "null", ";", "}", "@", "Override", "public", "void", "visitFieldExpression", "(", "FieldExpression", "expression", ")", "{", "if", "(", "nodeToLookFor", "==", "expression", ")", "{", "nodeFound", "=", "true", ";", "}", "else", "{", "super", ".", "visitFieldExpression", "(", "expression", ")", ";", "}", "}", "@", "Override", "public", "void", "visitVariableExpression", "(", "VariableExpression", "expression", ")", "{", "if", "(", "nodeToLookFor", "==", "expression", ")", "{", "nodeFound", "=", "true", ";", "}", "else", "{", "super", ".", "visitVariableExpression", "(", "expression", ")", ";", "}", "}", "@", "Override", "public", "void", "visitConstantExpression", "(", "ConstantExpression", "expression", ")", "{", "if", "(", "nodeToLookFor", "==", "expression", ")", "{", "nodeFound", "=", "true", ";", "}", "else", "{", "super", ".", "visitConstantExpression", "(", "expression", ")", ";", "}", "}", "public", "static", "boolean", "checkForAssignment", "(", "ASTNode", "node", ",", "BinaryExpression", "binaryExpr", ")", "{", "return", "binaryExpr", "!=", "null", "&&", "new", "EqualityVisitor", "(", "node", ")", ".", "doVisit", "(", "binaryExpr", ".", "getLeftExpression", "(", ")", ")", ";", "}", "}", "</s>" ]
6,792
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ImportNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Parameter", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "PropertyExpression", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ".", "GroovyCompilationUnit", ";", "public", "interface", "ITypeLookup", "{", "TypeLookupResult", "lookupType", "(", "Expression", "node", ",", "VariableScope", "scope", ",", "ClassNode", "objectExpressionType", ")", ";", "TypeLookupResult", "lookupType", "(", "FieldNode", "node", ",", "VariableScope", "scope", ")", ";", "TypeLookupResult", "lookupType", "(", "MethodNode", "node", ",", "VariableScope", "scope", ")", ";", "TypeLookupResult", "lookupType", "(", "AnnotationNode", "node", ",", "VariableScope", "scope", ")", ";", "TypeLookupResult", "lookupType", "(", "ImportNode", "node", ",", "VariableScope", "scope", ")", ";", "TypeLookupResult", "lookupType", "(", "ClassNode", "node", ",", "VariableScope", "scope", ")", ";", "TypeLookupResult", "lookupType", "(", "Parameter", "node", ",", "VariableScope", "scope", ")", ";", "void", "initialize", "(", "GroovyCompilationUnit", "unit", ",", "VariableScope", "topLevelScope", ")", ";", "}", "</s>" ]
6,793
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "public", "enum", "AccessorSupport", "{", "GETTER", "(", "\"get\"", ")", ",", "SETTER", "(", "\"set\"", ")", ",", "ISSER", "(", "\"is\"", ")", ",", "NONE", "(", "\"\"", ")", ";", "private", "final", "String", "prefix", ";", "private", "AccessorSupport", "(", "String", "prefix", ")", "{", "this", ".", "prefix", "=", "prefix", ";", "}", "public", "boolean", "isAccessor", "(", ")", "{", "return", "this", "!=", "NONE", ";", "}", "public", "boolean", "isAccessorKind", "(", "MethodNode", "node", ",", "boolean", "isCategory", ")", "{", "int", "args", "=", "isCategory", "?", "1", ":", "0", ";", "ClassNode", "returnType", "=", "node", ".", "getReturnType", "(", ")", ";", "switch", "(", "this", ")", "{", "case", "GETTER", ":", "return", "(", "node", ".", "getParameters", "(", ")", "==", "null", "||", "node", ".", "getParameters", "(", ")", ".", "length", "==", "args", ")", "&&", "!", "returnType", ".", "equals", "(", "VariableScope", ".", "VOID_CLASS_NODE", ")", ";", "case", "ISSER", ":", "return", "!", "isCategory", "&&", "(", "node", ".", "getParameters", "(", ")", "==", "null", "||", "node", ".", "getParameters", "(", ")", ".", "length", "==", "args", ")", "&&", "(", "returnType", ".", "equals", "(", "VariableScope", ".", "OBJECT_CLASS_NODE", ")", "||", "returnType", ".", "equals", "(", "VariableScope", ".", "BOOLEAN_CLASS_NODE", ")", "||", "returnType", ".", "equals", "(", "ClassHelper", ".", "boolean_TYPE", ")", ")", ";", "case", "SETTER", ":", "return", "node", ".", "getParameters", "(", ")", "!=", "null", "&&", "node", ".", "getParameters", "(", ")", ".", "length", "==", "args", "+", "1", "&&", "(", "returnType", ".", "equals", "(", "VariableScope", ".", "VOID_CLASS_NODE", ")", "||", "returnType", ".", "equals", "(", "VariableScope", ".", "OBJECT_CLASS_NODE", ")", ")", ";", "case", "NONE", ":", "default", ":", "return", "false", ";", "}", "}", "public", "String", "createAccessorName", "(", "String", "name", ")", "{", "if", "(", "!", "name", ".", "startsWith", "(", "GETTER", ".", "prefix", ")", "&&", "!", "name", ".", "startsWith", "(", "SETTER", ".", "prefix", ")", "&&", "name", ".", "length", "(", ")", ">", "0", ")", "{", "return", "this", ".", "prefix", "+", "Character", ".", "toUpperCase", "(", "name", ".", "charAt", "(", "0", ")", ")", "+", "(", "name", ".", "length", "(", ")", ">", "1", "?", "name", ".", "substring", "(", "1", ")", ":", "\"\"", ")", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "static", "AccessorSupport", "findAccessorKind", "(", "MethodNode", "node", ",", "boolean", "isCategory", ")", "{", "AccessorSupport", "accessor", "=", "create", "(", "node", ".", "getName", "(", ")", ",", "isCategory", ")", ";", "return", "accessor", ".", "isAccessorKind", "(", "node", ",", "isCategory", ")", "?", "accessor", ":", "NONE", ";", "}", "public", "static", "MethodNode", "findAccessorMethodForPropertyName", "(", "String", "name", ",", "ClassNode", "declaringType", ",", "boolean", "isCategory", ")", "{", "if", "(", "name", ".", "length", "(", ")", "<=", "0", ")", "{", "return", "null", ";", "}", "String", "suffix", "=", "Character", ".", "toUpperCase", "(", "name", ".", "charAt", "(", "0", ")", ")", "+", "(", "name", ".", "length", "(", ")", ">", "1", "?", "name", ".", "substring", "(", "1", ")", ":", "\"\"", ")", ";", "String", "getterName", "=", "\"get\"", "+", "suffix", ";", "List", "<", "MethodNode", ">", "methods", "=", "declaringType", ".", "getMethods", "(", "getterName", ")", ";", "if", "(", "!", "methods", ".", "isEmpty", "(", ")", ")", "{", "MethodNode", "maybeMethod", "=", "methods", ".", "get", "(", "0", ")", ";", "if", "(", "findAccessorKind", "(", "maybeMethod", ",", "isCategory", ")", "==", "GETTER", ")", "{", "return", "maybeMethod", ";", "}", "}", "String", "setterName", "=", "\"set\"", "+", "suffix", ";", "methods", "=", "declaringType", ".", "getMethods", "(", "setterName", ")", ";", "if", "(", "!", "methods", ".", "isEmpty", "(", ")", ")", "{", "MethodNode", "maybeMethod", "=", "methods", ".", "get", "(", "0", ")", ";", "if", "(", "findAccessorKind", "(", "maybeMethod", ",", "isCategory", ")", "==", "SETTER", ")", "{", "return", "maybeMethod", ";", "}", "}", "String", "isserName", "=", "\"is\"", "+", "suffix", ";", "methods", "=", "declaringType", ".", "getMethods", "(", "isserName", ")", ";", "if", "(", "!", "methods", ".", "isEmpty", "(", ")", ")", "{", "MethodNode", "maybeMethod", "=", "methods", ".", "get", "(", "0", ")", ";", "if", "(", "findAccessorKind", "(", "maybeMethod", ",", "isCategory", ")", "==", "ISSER", ")", "{", "return", "maybeMethod", ";", "}", "}", "return", "null", ";", "}", "public", "static", "boolean", "isGetter", "(", "MethodNode", "node", ")", "{", "return", "node", ".", "getReturnType", "(", ")", "!=", "VariableScope", ".", "VOID_CLASS_NODE", "&&", "node", ".", "getParameters", "(", ")", ".", "length", "==", "0", "&&", "(", "(", "node", ".", "getName", "(", ")", ".", "startsWith", "(", "\"get\"", ")", "&&", "node", ".", "getName", "(", ")", ".", "length", "(", ")", ">", "3", ")", "||", "(", "node", ".", "getName", "(", ")", ".", "startsWith", "(", "\"is\"", ")", "&&", "node", ".", "getName", "(", ")", ".", "length", "(", ")", ">", "2", ")", ")", ";", "}", "public", "static", "AccessorSupport", "create", "(", "String", "methodName", ",", "boolean", "isCategory", ")", "{", "AccessorSupport", "accessor", "=", "AccessorSupport", ".", "NONE", ";", "if", "(", "!", "isCategory", "&&", "methodName", ".", "length", "(", ")", ">", "2", "&&", "methodName", ".", "startsWith", "(", "\"is\"", ")", "&&", "Character", ".", "isUpperCase", "(", "methodName", ".", "charAt", "(", "2", ")", ")", ")", "{", "accessor", "=", "AccessorSupport", ".", "ISSER", ";", "}", "if", "(", "!", "accessor", ".", "isAccessor", "(", ")", ")", "{", "if", "(", "methodName", ".", "length", "(", ")", ">", "3", "&&", "(", "methodName", ".", "startsWith", "(", "\"get\"", ")", "||", "methodName", ".", "startsWith", "(", "\"set\"", ")", ")", "&&", "Character", ".", "isUpperCase", "(", "methodName", ".", "charAt", "(", "3", ")", ")", ")", "{", "accessor", "=", "methodName", ".", "charAt", "(", "0", ")", "==", "'g'", "?", "AccessorSupport", ".", "GETTER", ":", "AccessorSupport", ".", "SETTER", ";", "}", "}", "return", "accessor", ";", "}", "}", "</s>" ]
6,794
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "public", "class", "OrPatternRequestor", "implements", "ITypeRequestor", "{", "private", "final", "ITypeRequestor", "[", "]", "requestors", ";", "public", "OrPatternRequestor", "(", "List", "<", "ITypeRequestor", ">", "requestors", ")", "{", "this", ".", "requestors", "=", "requestors", ".", "toArray", "(", "new", "ITypeRequestor", "[", "requestors", ".", "size", "(", ")", "]", ")", ";", "}", "public", "VisitStatus", "acceptASTNode", "(", "ASTNode", "node", ",", "TypeLookupResult", "result", ",", "IJavaElement", "enclosingElement", ")", "{", "VisitStatus", "status", "=", "VisitStatus", ".", "CONTINUE", ";", "for", "(", "ITypeRequestor", "requestor", ":", "requestors", ")", "{", "status", "=", "VisitStatus", ".", "merge", "(", "status", ",", "requestor", ".", "acceptASTNode", "(", "node", ",", "result", ",", "enclosingElement", ")", ")", ";", "}", "return", "status", ";", "}", "}", "</s>" ]
6,795
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "Set", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ConstructorNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ImportNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ClassExpression", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "CoreException", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "NullProgressMonitor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "compiler", ".", "CharOperation", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchMatch", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchParticipant", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "TypeReferenceMatch", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ReflectionUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ".", "TypeLookupResult", ".", "TypeConfidence", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "CompilationUnit", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "DeclarationOfReferencedTypesPattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "JavaSearchPattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "TypeReferencePattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "import", "org", ".", "eclipse", ".", "jface", ".", "text", ".", "Position", ";", "public", "class", "TypeReferenceSearchRequestor", "implements", "ITypeRequestor", "{", "private", "static", "final", "String", "DOT", "=", "\".\"", ";", "private", "final", "SearchRequestor", "requestor", ";", "private", "final", "SearchParticipant", "participant", ";", "private", "final", "char", "[", "]", "qualificationPattern", ";", "private", "final", "char", "[", "]", "namePattern", ";", "private", "final", "boolean", "isCaseSensitive", ";", "private", "final", "boolean", "isCamelCase", ";", "private", "final", "boolean", "findDeclaration", ";", "private", "final", "Set", "<", "Position", ">", "acceptedPositions", "=", "new", "HashSet", "<", "Position", ">", "(", ")", ";", "private", "char", "[", "]", "cachedContents", ";", "@", "SuppressWarnings", "(", "\"nls\"", ")", "public", "TypeReferenceSearchRequestor", "(", "TypeReferencePattern", "pattern", ",", "SearchRequestor", "requestor", ",", "SearchParticipant", "participant", ")", "{", "this", ".", "requestor", "=", "requestor", ";", "this", ".", "participant", "=", "participant", ";", "this", ".", "isCaseSensitive", "=", "(", "(", "Boolean", ")", "ReflectionUtils", ".", "getPrivateField", "(", "JavaSearchPattern", ".", "class", ",", "\"\"", ",", "pattern", ")", ")", ".", "booleanValue", "(", ")", ";", "this", ".", "namePattern", "=", "extractArray", "(", "pattern", ",", "\"simpleName\"", ")", ";", "this", ".", "qualificationPattern", "=", "extractArray", "(", "pattern", ",", "\"\"", ")", ";", "this", ".", "isCamelCase", "=", "(", "(", "Boolean", ")", "ReflectionUtils", ".", "getPrivateField", "(", "JavaSearchPattern", ".", "class", ",", "\"isCamelCase\"", ",", "pattern", ")", ")", ".", "booleanValue", "(", ")", ";", "this", ".", "findDeclaration", "=", "pattern", "instanceof", "DeclarationOfReferencedTypesPattern", ";", "}", "protected", "char", "[", "]", "extractArray", "(", "TypeReferencePattern", "pattern", ",", "String", "fieldName", ")", "{", "char", "[", "]", "arr", ";", "arr", "=", "(", "char", "[", "]", ")", "ReflectionUtils", ".", "getPrivateField", "(", "TypeReferencePattern", ".", "class", ",", "fieldName", ",", "pattern", ")", ";", "if", "(", "!", "isCaseSensitive", ")", "{", "arr", "=", "CharOperation", ".", "toLowerCase", "(", "arr", ")", ";", "}", "return", "arr", ";", "}", "public", "VisitStatus", "acceptASTNode", "(", "ASTNode", "node", ",", "TypeLookupResult", "result", ",", "IJavaElement", "enclosingElement", ")", "{", "if", "(", "node", "instanceof", "ClassExpression", "||", "node", "instanceof", "ClassNode", "||", "node", "instanceof", "ImportNode", "||", "node", "instanceof", "AnnotationNode", ")", "{", "ClassNode", "type", ";", "if", "(", "node", "instanceof", "ConstructorNode", ")", "{", "type", "=", "(", "(", "ConstructorNode", ")", "node", ")", ".", "getDeclaringClass", "(", ")", ";", "}", "else", "if", "(", "node", "instanceof", "AnnotationNode", ")", "{", "type", "=", "(", "(", "AnnotationNode", ")", "node", ")", ".", "getClassNode", "(", ")", ";", "}", "else", "{", "type", "=", "result", ".", "type", ";", "}", "if", "(", "node", "instanceof", "ClassExpression", "&&", "type", "==", "VariableScope", ".", "CLASS_CLASS_NODE", ")", "{", "type", "=", "(", "(", "ClassExpression", ")", "node", ")", ".", "getType", "(", ")", ";", "}", "if", "(", "type", "!=", "null", ")", "{", "type", "=", "removeArray", "(", "type", ")", ";", "if", "(", "qualifiedNameMatches", "(", "type", ")", "&&", "hasValidSourceLocation", "(", "node", ")", ")", "{", "int", "start", "=", "-", "1", ";", "int", "end", "=", "-", "1", ";", "boolean", "startEndFound", "=", "false", ";", "if", "(", "node", "instanceof", "ImportNode", ")", "{", "if", "(", "(", "(", "ImportNode", ")", "node", ")", ".", "getType", "(", ")", "==", "null", ")", "{", "end", "=", "node", ".", "getEnd", "(", ")", ";", "start", "=", "node", ".", "getStart", "(", ")", ";", "}", "}", "else", "if", "(", "node", "instanceof", "ClassExpression", ")", "{", "end", "=", "node", ".", "getEnd", "(", ")", ";", "start", "=", "node", ".", "getStart", "(", ")", ";", "}", "else", "if", "(", "node", "instanceof", "ClassNode", ")", "{", "ClassNode", "classNode", "=", "(", "ClassNode", ")", "node", ";", "if", "(", "classNode", ".", "getNameEnd", "(", ")", ">", "0", ")", "{", "}", "else", "if", "(", "classNode", ".", "redirect", "(", ")", "==", "classNode", ")", "{", "start", "=", "end", "=", "-", "1", ";", "startEndFound", "=", "true", ";", "}", "else", "{", "classNode", "=", "maybeGetComponentType", "(", "classNode", ")", ";", "end", "=", "classNode", ".", "getEnd", "(", ")", ";", "start", "=", "classNode", ".", "getStart", "(", ")", ";", "}", "}", "else", "if", "(", "node", "instanceof", "ConstructorNode", ")", "{", "start", "=", "(", "(", "ConstructorNode", ")", "node", ")", ".", "getNameStart", "(", ")", ";", "end", "=", "(", "(", "ConstructorNode", ")", "node", ")", ".", "getNameEnd", "(", ")", "+", "1", ";", "if", "(", "start", "==", "0", "&&", "end", "==", "1", ")", "{", "start", "=", "end", "=", "-", "1", ";", "startEndFound", "=", "true", ";", "}", "}", "else", "if", "(", "node", "instanceof", "AnnotationNode", ")", "{", "type", "=", "(", "(", "AnnotationNode", ")", "node", ")", ".", "getClassNode", "(", ")", ";", "end", "=", "type", ".", "getEnd", "(", ")", ";", "start", "=", "type", ".", "getStart", "(", ")", ";", "}", "if", "(", "!", "startEndFound", ")", "{", "StartEnd", "startEnd", "=", "getMatchLocation", "(", "type", ",", "enclosingElement", ",", "start", ",", "end", ")", ";", "if", "(", "startEnd", "!=", "null", ")", "{", "start", "=", "startEnd", ".", "start", ";", "end", "=", "startEnd", ".", "end", ";", "}", "else", "{", "start", "=", "end", "=", "-", "1", ";", "}", "}", "if", "(", "start", ">=", "0", "&&", "end", ">=", "0", ")", "{", "Position", "position", "=", "new", "Position", "(", "start", ",", "end", "-", "start", ")", ";", "if", "(", "!", "acceptedPositions", ".", "contains", "(", "position", ")", ")", "{", "try", "{", "requestor", ".", "acceptSearchMatch", "(", "createMatch", "(", "result", ",", "enclosingElement", ",", "start", ",", "end", ")", ")", ";", "acceptedPositions", ".", "add", "(", "position", ")", ";", "}", "catch", "(", "CoreException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "enclosingElement", ")", ";", "}", "}", "}", "}", "}", "}", "return", "VisitStatus", ".", "CONTINUE", ";", "}", "protected", "TypeReferenceMatch", "createMatch", "(", "TypeLookupResult", "result", ",", "IJavaElement", "enclosingElement", ",", "int", "start", ",", "int", "end", ")", "{", "IJavaElement", "element", ";", "if", "(", "findDeclaration", ")", "{", "try", "{", "element", "=", "enclosingElement", ".", "getJavaProject", "(", ")", ".", "findType", "(", "result", ".", "type", ".", "getName", "(", ")", ".", "replace", "(", "'$'", ",", "'.'", ")", ",", "new", "NullProgressMonitor", "(", ")", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "Util", ".", "log", "(", "e", ")", ";", "element", "=", "enclosingElement", ";", "}", "}", "else", "{", "element", "=", "enclosingElement", ";", "}", "return", "new", "TypeReferenceMatch", "(", "element", ",", "getAccuracy", "(", "result", ".", "confidence", ")", ",", "start", ",", "end", "-", "start", ",", "false", ",", "participant", ",", "element", ".", "getResource", "(", ")", ")", ";", "}", "private", "boolean", "hasValidSourceLocation", "(", "ASTNode", "node", ")", "{", "ASTNode", "astNodeWithSourceLocation", ";", "if", "(", "node", "instanceof", "ClassNode", ")", "{", "astNodeWithSourceLocation", "=", "maybeGetComponentType", "(", "(", "ClassNode", ")", "node", ")", ";", "}", "else", "{", "astNodeWithSourceLocation", "=", "node", ";", "}", "return", "astNodeWithSourceLocation", ".", "getEnd", "(", ")", ">", "0", ";", "}", "private", "ClassNode", "maybeGetComponentType", "(", "ClassNode", "orig", ")", "{", "if", "(", "orig", ".", "getComponentType", "(", ")", "!=", "null", ")", "{", "ClassNode", "componentType", "=", "orig", ".", "getComponentType", "(", ")", ";", "if", "(", "componentType", ".", "getColumnNumber", "(", ")", "!=", "-", "1", ")", "{", "return", "componentType", ";", "}", "}", "return", "orig", ";", "}", "private", "ClassNode", "removeArray", "(", "ClassNode", "declaration", ")", "{", "return", "declaration", ".", "getComponentType", "(", ")", "!=", "null", "?", "removeArray", "(", "declaration", ".", "getComponentType", "(", ")", ")", ":", "declaration", ";", "}", "private", "String", "[", "]", "extractNameAndQualification", "(", "ClassNode", "type", ")", "{", "String", "qualification", "=", "type", ".", "getPackageName", "(", ")", ";", "if", "(", "qualification", "==", "null", ")", "{", "qualification", "=", "\"\"", ";", "}", "String", "semiQualified", "=", "type", ".", "getNameWithoutPackage", "(", ")", ";", "String", "simple", ";", "int", "lastDollar", "=", "semiQualified", ".", "lastIndexOf", "(", "'$'", ")", ";", "if", "(", "lastDollar", ">", "0", ")", "{", "simple", "=", "semiQualified", ".", "substring", "(", "lastDollar", "+", "1", ")", ";", "semiQualified", "=", "semiQualified", ".", "replace", "(", "'$'", ",", "'.'", ")", ".", "substring", "(", "0", ",", "lastDollar", ")", ";", "if", "(", "qualification", ".", "length", "(", ")", "==", "0", ")", "{", "qualification", "=", "semiQualified", ";", "}", "else", "{", "qualification", "+=", "DOT", "+", "semiQualified", ";", "}", "}", "else", "{", "simple", "=", "semiQualified", ";", "}", "return", "new", "String", "[", "]", "{", "qualification", ",", "simple", "}", ";", "}", "private", "boolean", "qualifiedNameMatches", "(", "ClassNode", "type", ")", "{", "String", "[", "]", "nameAndQualification", "=", "extractNameAndQualification", "(", "type", ")", ";", "String", "name", ",", "qualification", ";", "qualification", "=", "nameAndQualification", "[", "0", "]", ";", "name", "=", "nameAndQualification", "[", "1", "]", ";", "if", "(", "!", "isCaseSensitive", ")", "{", "name", "=", "name", ".", "toLowerCase", "(", ")", ";", "qualification", "=", "qualification", ".", "toLowerCase", "(", ")", ";", "}", "boolean", "match", "=", "true", ";", "if", "(", "namePattern", "!=", "null", ")", "{", "if", "(", "isCamelCase", ")", "{", "match", "=", "CharOperation", ".", "camelCaseMatch", "(", "namePattern", ",", "name", ".", "toCharArray", "(", ")", ")", ";", "}", "else", "{", "match", "=", "CharOperation", ".", "equals", "(", "namePattern", ",", "name", ".", "toCharArray", "(", ")", ")", ";", "}", "}", "if", "(", "match", "&&", "qualificationPattern", "!=", "null", ")", "{", "if", "(", "isCamelCase", ")", "{", "match", "=", "CharOperation", ".", "camelCaseMatch", "(", "qualificationPattern", ",", "qualification", ".", "toCharArray", "(", ")", ")", ";", "}", "else", "{", "match", "=", "CharOperation", ".", "equals", "(", "qualificationPattern", ",", "qualification", ".", "toCharArray", "(", ")", ")", ";", "}", "}", "return", "match", ";", "}", "private", "class", "StartEnd", "{", "StartEnd", "(", "int", "start", ",", "int", "end", ")", "{", "this", ".", "start", "=", "start", ";", "this", ".", "end", "=", "end", ";", "}", "final", "int", "start", ";", "final", "int", "end", ";", "}", "private", "StartEnd", "getMatchLocation", "(", "ClassNode", "node", ",", "IJavaElement", "elt", ",", "int", "maybeStart", ",", "int", "maybeEnd", ")", "{", "CompilationUnit", "unit", "=", "(", "CompilationUnit", ")", "elt", ".", "getAncestor", "(", "IJavaElement", ".", "COMPILATION_UNIT", ")", ";", "if", "(", "unit", "!=", "null", "&&", "cachedContents", "==", "null", ")", "{", "cachedContents", "=", "unit", ".", "getContents", "(", ")", ";", "}", "if", "(", "cachedContents", "!=", "null", ")", "{", "int", "nameLength", "=", "maybeEnd", "-", "maybeStart", ";", "int", "start", "=", "-", "1", ";", "int", "end", "=", "-", "1", ";", "String", "name", "=", "node", ".", "getName", "(", ")", ";", "int", "dollarIndex", "=", "name", ".", "lastIndexOf", "(", "'$'", ")", ";", "name", "=", "name", ".", "substring", "(", "dollarIndex", "+", "1", ")", ";", "if", "(", "name", ".", "length", "(", ")", "<=", "nameLength", ")", "{", "start", "=", "CharOperation", ".", "indexOf", "(", "name", ".", "toCharArray", "(", ")", ",", "cachedContents", ",", "true", ",", "maybeStart", ",", "maybeEnd", "+", "1", ")", ";", "end", "=", "start", "+", "name", ".", "length", "(", ")", ";", "}", "if", "(", "start", "==", "-", "1", ")", "{", "String", "nameWithoutPackage", "=", "node", ".", "getNameWithoutPackage", "(", ")", ";", "start", "=", "CharOperation", ".", "indexOf", "(", "nameWithoutPackage", ".", "toCharArray", "(", ")", ",", "cachedContents", ",", "true", ",", "maybeStart", ",", "maybeEnd", "+", "1", ")", ";", "end", "=", "start", "+", "nameWithoutPackage", ".", "length", "(", ")", ";", "}", "if", "(", "start", "==", "-", "1", ")", "{", "return", "null", ";", "}", "else", "{", "return", "new", "StartEnd", "(", "start", ",", "end", ")", ";", "}", "}", "return", "new", "StartEnd", "(", "node", ".", "getStart", "(", ")", ",", "node", ".", "getEnd", "(", ")", ")", ";", "}", "private", "boolean", "shouldAlwaysBeAccurate", "(", ")", "{", "return", "requestor", ".", "getClass", "(", ")", ".", "getPackage", "(", ")", ".", "getName", "(", ")", ".", "indexOf", "(", "\"refactoring\"", ")", "!=", "-", "1", ";", "}", "private", "int", "getAccuracy", "(", "TypeConfidence", "confidence", ")", "{", "if", "(", "shouldAlwaysBeAccurate", "(", ")", ")", "{", "return", "SearchMatch", ".", "A_ACCURATE", ";", "}", "switch", "(", "confidence", ")", "{", "case", "EXACT", ":", "return", "SearchMatch", ".", "A_ACCURATE", ";", "default", ":", "return", "SearchMatch", ".", "A_INACCURATE", ";", "}", "}", "}", "</s>" ]
6,796
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "BinaryExpression", ";", "public", "class", "TypeLookupResult", "{", "public", "static", "enum", "TypeConfidence", "{", "EXACT", "(", "0", ")", ",", "POTENTIAL", "(", "1", ")", ",", "INFERRED", "(", "2", ")", ",", "LOOSELY_INFERRED", "(", "3", ")", ",", "UNKNOWN", "(", "4", ")", ";", "private", "final", "int", "val", ";", "TypeConfidence", "(", "int", "val", ")", "{", "this", ".", "val", "=", "val", ";", "}", "static", "TypeConfidence", "findLessPrecise", "(", "TypeConfidence", "left", ",", "TypeConfidence", "right", ")", "{", "return", "left", ".", "val", ">", "right", ".", "val", "?", "left", ":", "right", ";", "}", "boolean", "isLessPreciseThan", "(", "TypeConfidence", "other", ")", "{", "return", "this", ".", "val", ">", "other", ".", "val", ";", "}", "}", "public", "final", "TypeConfidence", "confidence", ";", "public", "final", "ClassNode", "type", ";", "public", "final", "ClassNode", "declaringType", ";", "public", "final", "ASTNode", "declaration", ";", "public", "final", "VariableScope", "scope", ";", "public", "final", "String", "extraDoc", ";", "BinaryExpression", "enclosingAssignment", ";", "public", "TypeLookupResult", "(", "ClassNode", "type", ",", "ClassNode", "declaringType", ",", "ASTNode", "declaration", ",", "TypeConfidence", "confidence", ",", "VariableScope", "scope", ")", "{", "this", "(", "type", ",", "declaringType", ",", "declaration", ",", "confidence", ",", "scope", ",", "null", ")", ";", "}", "public", "TypeLookupResult", "(", "ClassNode", "type", ",", "ClassNode", "declaringType", ",", "ASTNode", "declaration", ",", "TypeConfidence", "confidence", ",", "VariableScope", "scope", ",", "String", "extraDoc", ")", "{", "this", ".", "confidence", "=", "confidence", ";", "this", ".", "type", "=", "ClassHelper", ".", "isPrimitiveType", "(", "type", ")", "?", "ClassHelper", ".", "getWrapper", "(", "type", ")", ":", "type", ";", "this", ".", "declaringType", "=", "declaringType", ";", "this", ".", "declaration", "=", "declaration", ";", "this", ".", "scope", "=", "scope", ";", "this", ".", "extraDoc", "=", "extraDoc", ";", "}", "public", "BinaryExpression", "getEnclosingAssignment", "(", ")", "{", "return", "enclosingAssignment", ";", "}", "}", "</s>" ]
6,797
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "List", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "ILocalVariable", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchPattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "search", ".", "SearchRequestor", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "core", ".", "util", ".", "ReflectionUtils", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "FieldPattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "LocalVariablePattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "MethodPattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "OrPattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "PossibleMatch", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "TypeDeclarationPattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "search", ".", "matching", ".", "TypeReferencePattern", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "TypeRequestorFactory", "{", "public", "ITypeRequestor", "createRequestor", "(", "PossibleMatch", "possibleMatch", ",", "SearchPattern", "pattern", ",", "SearchRequestor", "requestor", ")", "{", "if", "(", "pattern", "instanceof", "TypeReferencePattern", ")", "{", "return", "new", "TypeReferenceSearchRequestor", "(", "(", "TypeReferencePattern", ")", "pattern", ",", "requestor", ",", "possibleMatch", ".", "document", ".", "getParticipant", "(", ")", ")", ";", "}", "else", "if", "(", "pattern", "instanceof", "TypeDeclarationPattern", ")", "{", "return", "new", "TypeDeclarationSearchRequestor", "(", "(", "TypeDeclarationPattern", ")", "pattern", ",", "requestor", ",", "possibleMatch", ".", "document", ".", "getParticipant", "(", ")", ")", ";", "}", "else", "if", "(", "pattern", "instanceof", "FieldPattern", ")", "{", "return", "new", "FieldReferenceSearchRequestor", "(", "(", "FieldPattern", ")", "pattern", ",", "requestor", ",", "possibleMatch", ".", "document", ".", "getParticipant", "(", ")", ")", ";", "}", "else", "if", "(", "pattern", "instanceof", "MethodPattern", ")", "{", "return", "new", "MethodReferenceSearchRequestor", "(", "(", "MethodPattern", ")", "pattern", ",", "requestor", ",", "possibleMatch", ".", "document", ".", "getParticipant", "(", ")", ")", ";", "}", "else", "if", "(", "pattern", "instanceof", "LocalVariablePattern", ")", "{", "ILocalVariable", "localVar", "=", "(", "ILocalVariable", ")", "ReflectionUtils", ".", "getPrivateField", "(", "LocalVariablePattern", ".", "class", ",", "\"\"", ",", "pattern", ")", ";", "int", "start", ";", "try", "{", "start", "=", "localVar", ".", "getSourceRange", "(", ")", ".", "getOffset", "(", ")", ";", "}", "catch", "(", "JavaModelException", "e", ")", "{", "Util", ".", "log", "(", "e", ")", ";", "start", "=", "-", "1", ";", "}", "return", "new", "LocalVariableReferenceRequestor", "(", "localVar", ".", "getElementName", "(", ")", ",", "localVar", ".", "getParent", "(", ")", ",", "requestor", ",", "possibleMatch", ".", "document", ".", "getParticipant", "(", ")", ",", "start", ")", ";", "}", "else", "if", "(", "pattern", "instanceof", "OrPattern", ")", "{", "SearchPattern", "[", "]", "patterns", "=", "getPatterns", "(", "(", "OrPattern", ")", "pattern", ")", ";", "List", "<", "ITypeRequestor", ">", "requestors", "=", "new", "ArrayList", "<", "ITypeRequestor", ">", "(", "patterns", ".", "length", ")", ";", "for", "(", "SearchPattern", "orPattern", ":", "patterns", ")", "{", "if", "(", "orPattern", "!=", "null", ")", "{", "ITypeRequestor", "maybeRequestor", "=", "createRequestor", "(", "possibleMatch", ",", "orPattern", ",", "requestor", ")", ";", "if", "(", "maybeRequestor", "!=", "null", ")", "{", "requestors", ".", "add", "(", "maybeRequestor", ")", ";", "}", "}", "}", "return", "new", "OrPatternRequestor", "(", "requestors", ")", ";", "}", "return", "null", ";", "}", "private", "SearchPattern", "[", "]", "getPatterns", "(", "OrPattern", "pattern", ")", "{", "return", "(", "SearchPattern", "[", "]", ")", "ReflectionUtils", ".", "getPrivateField", "(", "OrPattern", ".", "class", ",", "\"patterns\"", ",", "pattern", ")", ";", "}", "}", "</s>" ]
6,798
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "java", ".", "util", ".", "Arrays", ";", "import", "java", ".", "util", ".", "Collection", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "HashSet", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "Set", ";", "import", "java", ".", "util", ".", "Stack", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotatedNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "AnnotationNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassCodeVisitorSupport", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ConstructorNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GenericsType", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ImportNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ImportNodeCompatibilityWrapper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ModuleNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "PackageNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Parameter", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "AnnotationConstantExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ArgumentListExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ArrayExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "AttributeExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "BinaryExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "BitwiseNegationExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "BooleanExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "CastExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ClassExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ClosureExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ClosureListExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstantExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ConstructorCallExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "DeclarationExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ElvisOperatorExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "EmptyExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "Expression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "FieldExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "GStringExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ListExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MapEntryExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MapExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MethodCallExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MethodPointerExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "NotExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "PostfixExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "PrefixExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "PropertyExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "RangeExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "SpreadExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "SpreadMapExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "StaticMethodCallExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "TernaryExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "TupleExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "UnaryMinusExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "UnaryPlusExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "VariableExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "BlockStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "CatchStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ExpressionStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ForStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "ReturnStatement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "stmt", ".", "Statement", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "classgen", ".", "BytecodeExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "control", ".", "SourceUnit", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "syntax", ".", "Types", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "JDTResolver", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ".", "GroovyCompilationUnit", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "model", ".", "ModuleNodeMapper", ".", "ModuleNodeInfo", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Assert", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IField", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IJavaElement", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IMethod", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "IType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "JavaModelException", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "Signature", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ".", "ITypeRequestor", ".", "VisitStatus", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ".", "TypeLookupResult", ".", "TypeConfidence", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ".", "VariableScope", ".", "CallAndType", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ".", "VariableScope", ".", "VariableInfo", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "DefaultWorkingCopyOwner", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "@", "SuppressWarnings", "(", "\"nls\"", ")", "public", "class", "TypeInferencingVisitorWithRequestor", "extends", "ClassCodeVisitorSupport", "{", "public", "class", "VisitCompleted", "extends", "RuntimeException", "{", "private", "static", "final", "long", "serialVersionUID", "=", "1L", ";", "public", "final", "VisitStatus", "status", ";", "public", "VisitCompleted", "(", "VisitStatus", "status", ")", "{", "super", "(", ")", ";", "this", ".", "status", "=", "status", ";", "}", "}", "public", "boolean", "DEBUG", "=", "false", ";", "private", "static", "final", "Set", "<", "String", ">", "dgmClosureMethods", "=", "new", "HashSet", "<", "String", ">", "(", ")", ";", "static", "{", "dgmClosureMethods", ".", "add", "(", "\"find\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"each\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"reverseEach\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"unique\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"every\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"collect\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"collectMany\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"findAll\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"groupBy\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"inject\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"count\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"countBy\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"findResult\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"findResults\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"grep\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"split\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"sum\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"any\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"flatten\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"findIndexOf\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"collectAll\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"min\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"max\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"sort\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"withDefault\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"identity\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"times\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"upto\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"downto\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"step\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"eachFile\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"eachDir\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMethods", ".", "add", "(", "\"traverse\"", ")", ";", "}", "private", "static", "final", "Set", "<", "String", ">", "dgmClosureIdentityMethods", "=", "new", "HashSet", "<", "String", ">", "(", ")", ";", "static", "{", "dgmClosureIdentityMethods", ".", "add", "(", "\"with\"", ")", ";", "dgmClosureIdentityMethods", ".", "add", "(", "\"\"", ")", ";", "}", "private", "static", "final", "Set", "<", "String", ">", "dgmClosureMaybeMap", "=", "new", "HashSet", "<", "String", ">", "(", ")", ";", "static", "{", "dgmClosureMaybeMap", ".", "add", "(", "\"any\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"every\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"each\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"collect\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"findResult\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"findResults\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"findAll\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"groupBy\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"inject\"", ")", ";", "dgmClosureMaybeMap", ".", "add", "(", "\"withDefault\"", ")", ";", "}", "private", "static", "final", "Map", "<", "String", ",", "ClassNode", ">", "dgmClosureMethodsMap", "=", "new", "HashMap", "<", "String", ",", "ClassNode", ">", "(", ")", ";", "static", "{", "dgmClosureMethodsMap", ".", "put", "(", "\"eachLine\"", ",", "VariableScope", ".", "STRING_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "STRING_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "OBJECT_OUTPUT_STREAM", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "OBJECT_INPUT_STREAM", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "DATA_OUTPUT_STREAM_CLASS", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "DATA_INPUT_STREAM_CLASS", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "OUTPUT_STREAM_CLASS", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "INPUT_STREAM_CLASS", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"withStream\"", ",", "VariableScope", ".", "OUTPUT_STREAM_CLASS", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"metaClass\"", ",", "ClassHelper", ".", "METACLASS_TYPE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "FILE_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"eachDirMatch\"", ",", "VariableScope", ".", "FILE_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"withReader\"", ",", "VariableScope", ".", "BUFFERED_READER_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"withWriter\"", ",", "VariableScope", ".", "BUFFERED_WRITER_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "BUFFERED_WRITER_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "PRINT_WRITER_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "STRING_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"\"", ",", "VariableScope", ".", "STRING_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"filterLine\"", ",", "VariableScope", ".", "STRING_CLASS_NODE", ")", ";", "dgmClosureMethodsMap", ".", "put", "(", "\"eachMatch\"", ",", "VariableScope", ".", "STRING_CLASS_NODE", ")", ";", "}", "private", "final", "GroovyCompilationUnit", "unit", ";", "private", "final", "Stack", "<", "VariableScope", ">", "scopes", ";", "private", "final", "ITypeLookup", "[", "]", "lookups", ";", "private", "ITypeRequestor", "requestor", ";", "private", "IJavaElement", "enclosingElement", ";", "private", "ASTNode", "enclosingDeclarationNode", ";", "private", "BinaryExpression", "enclosingAssignment", ";", "private", "ConstructorCallExpression", "enclosingConstructorCall", ";", "private", "Stack", "<", "ASTNode", ">", "completeExpressionStack", ";", "private", "Stack", "<", "ClassNode", ">", "primaryTypeStack", ";", "private", "Stack", "<", "ClassNode", ">", "dependentDeclaringTypeStack", ";", "private", "Stack", "<", "ClassNode", ">", "dependentTypeStack", ";", "private", "final", "JDTResolver", "resolver", ";", "private", "final", "AssignmentStorer", "assignmentStorer", "=", "new", "AssignmentStorer", "(", ")", ";", "TypeInferencingVisitorWithRequestor", "(", "GroovyCompilationUnit", "unit", ",", "ITypeLookup", "[", "]", "lookups", ")", "{", "super", "(", ")", ";", "this", ".", "unit", "=", "unit", ";", "ModuleNodeInfo", "info", "=", "createModuleNode", "(", "unit", ")", ";", "this", ".", "enclosingDeclarationNode", "=", "info", "!=", "null", "?", "info", ".", "module", ":", "null", ";", "this", ".", "resolver", "=", "info", "!=", "null", "?", "info", ".", "resolver", ":", "null", ";", "this", ".", "lookups", "=", "lookups", ";", "scopes", "=", "new", "Stack", "<", "VariableScope", ">", "(", ")", ";", "completeExpressionStack", "=", "new", "Stack", "<", "ASTNode", ">", "(", ")", ";", "primaryTypeStack", "=", "new", "Stack", "<", "ClassNode", ">", "(", ")", ";", "dependentTypeStack", "=", "new", "Stack", "<", "ClassNode", ">", "(", ")", ";", "dependentDeclaringTypeStack", "=", "new", "Stack", "<", "ClassNode", ">", "(", ")", ";", "}", "public", "void", "visitCompilationUnit", "(", "ITypeRequestor", "requestor", ")", "{", "if", "(", "enclosingDeclarationNode", "==", "null", ")", "{", "return", ";", "}", "this", ".", "requestor", "=", "requestor", ";", "enclosingElement", "=", "unit", ";", "VariableScope", "topLevelScope", "=", "new", "VariableScope", "(", "null", ",", "enclosingDeclarationNode", ",", "false", ")", ";", "scopes", ".", "push", "(", "topLevelScope", ")", ";", "for", "(", "ITypeLookup", "lookup", ":", "lookups", ")", "{", "if", "(", "lookup", "instanceof", "ITypeResolver", ")", "{", "(", "(", "ITypeResolver", ")", "lookup", ")", ".", "setResolverInformation", "(", "(", "ModuleNode", ")", "enclosingDeclarationNode", ",", "resolver", ")", ";", "}", "lookup", ".", "initialize", "(", "unit", ",", "topLevelScope", ")", ";", "}", "try", "{", "visitPackage", "(", "(", "(", "ModuleNode", ")", "enclosingDeclarationNode", ")", ".", "getPackage", "(", ")", ")", ";", "visitImports", "(", "(", "ModuleNode", ")", "enclosingDeclarationNode", ")", ";", "try", "{", "IType", "[", "]", "types", "=", "unit", ".", "getTypes", "(", ")", ";", "for", "(", "IType", "type", ":", "types", ")", "{", "visitJDT", "(", "type", ",", "requestor", ")", ";", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "unit", ".", "getElementName", "(", ")", ")", ";", "}", "scopes", ".", "pop", "(", ")", ";", "}", "catch", "(", "VisitCompleted", "vc", ")", "{", "}", "catch", "(", "Exception", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "unit", ".", "getElementName", "(", ")", ")", ";", "if", "(", "DEBUG", ")", "{", "System", ".", "err", ".", "println", "(", "\"\"", ")", ";", "e", ".", "printStackTrace", "(", ")", ";", "}", "}", "if", "(", "DEBUG", ")", "{", "postVisitSanityCheck", "(", ")", ";", "}", "}", "public", "void", "visitPackage", "(", "PackageNode", "p", ")", "{", "}", "public", "void", "visitJDT", "(", "IType", "type", ",", "ITypeRequestor", "requestor", ")", "{", "IJavaElement", "oldEnclosing", "=", "enclosingElement", ";", "ASTNode", "oldEnclosingNode", "=", "enclosingDeclarationNode", ";", "enclosingElement", "=", "type", ";", "ClassNode", "node", "=", "findClassWithName", "(", "createName", "(", "type", ")", ")", ";", "if", "(", "node", "==", "null", ")", "{", "return", ";", "}", "try", "{", "scopes", ".", "push", "(", "new", "VariableScope", "(", "scopes", ".", "peek", "(", ")", ",", "node", ",", "false", ")", ")", ";", "enclosingDeclarationNode", "=", "node", ";", "visitClassInternal", "(", "node", ")", ";", "try", "{", "boolean", "isEnum", "=", "type", ".", "isEnum", "(", ")", ";", "for", "(", "IJavaElement", "child", ":", "type", ".", "getChildren", "(", ")", ")", "{", "if", "(", "isEnum", "&&", "shouldFilterEnumMember", "(", "child", ")", ")", "{", "continue", ";", "}", "switch", "(", "child", ".", "getElementType", "(", ")", ")", "{", "case", "IJavaElement", ".", "METHOD", ":", "visitJDT", "(", "(", "IMethod", ")", "child", ",", "requestor", ")", ";", "break", ";", "case", "IJavaElement", ".", "FIELD", ":", "visitJDT", "(", "(", "IField", ")", "child", ",", "requestor", ")", ";", "break", ";", "case", "IJavaElement", ".", "TYPE", ":", "visitJDT", "(", "(", "IType", ")", "child", ",", "requestor", ")", ";", "break", ";", "default", ":", "break", ";", "}", "}", "if", "(", "!", "type", ".", "getMethod", "(", "type", ".", "getElementName", "(", ")", ",", "new", "String", "[", "0", "]", ")", ".", "exists", "(", ")", ")", "{", "ConstructorNode", "defConstructor", "=", "findDefaultConstructor", "(", "node", ")", ";", "if", "(", "defConstructor", "!=", "null", ")", "{", "visitConstructorOrMethod", "(", "defConstructor", ",", "true", ")", ";", "}", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "type", ".", "getFullyQualifiedName", "(", ")", ")", ";", "}", "}", "catch", "(", "VisitCompleted", "vc", ")", "{", "if", "(", "vc", ".", "status", "==", "VisitStatus", ".", "STOP_VISIT", ")", "{", "throw", "vc", ";", "}", "}", "finally", "{", "enclosingElement", "=", "oldEnclosing", ";", "enclosingDeclarationNode", "=", "oldEnclosingNode", ";", "scopes", ".", "pop", "(", ")", ";", "}", "}", "private", "ConstructorNode", "findDefaultConstructor", "(", "ClassNode", "node", ")", "{", "List", "<", "ConstructorNode", ">", "constructors", "=", "node", ".", "getDeclaredConstructors", "(", ")", ";", "for", "(", "ConstructorNode", "constructor", ":", "constructors", ")", "{", "if", "(", "constructor", ".", "getParameters", "(", ")", "==", "null", "||", "constructor", ".", "getParameters", "(", ")", ".", "length", "==", "0", ")", "{", "return", "constructor", ";", "}", "}", "return", "null", ";", "}", "private", "boolean", "shouldFilterEnumMember", "(", "IJavaElement", "child", ")", "{", "int", "type", "=", "child", ".", "getElementType", "(", ")", ";", "String", "name", "=", "child", ".", "getElementName", "(", ")", ";", "if", "(", "name", ".", "indexOf", "(", "'$'", ")", ">=", "0", ")", "{", "return", "true", ";", "}", "else", "if", "(", "type", "==", "IJavaElement", ".", "METHOD", ")", "{", "if", "(", "(", "name", ".", "equals", "(", "\"next\"", ")", "||", "name", ".", "equals", "(", "\"previous\"", ")", ")", "&&", "(", "(", "IMethod", ")", "child", ")", ".", "getNumberOfParameters", "(", ")", "==", "0", ")", "{", "return", "true", ";", "}", "}", "else", "if", "(", "type", "==", "IJavaElement", ".", "METHOD", ")", "{", "if", "(", "name", ".", "equals", "(", "\"MIN_VALUE\"", ")", "||", "name", ".", "equals", "(", "\"MAX_VALUE\"", ")", ")", "{", "return", "true", ";", "}", "}", "return", "false", ";", "}", "private", "String", "createName", "(", "IType", "type", ")", "{", "StringBuilder", "sb", "=", "new", "StringBuilder", "(", ")", ";", "sb", ".", "append", "(", "type", ".", "getElementName", "(", ")", ")", ";", "while", "(", "type", ".", "getParent", "(", ")", ".", "getElementType", "(", ")", "==", "IJavaElement", ".", "TYPE", ")", "{", "sb", ".", "insert", "(", "0", ",", "'$'", ")", ";", "type", "=", "(", "IType", ")", "type", ".", "getParent", "(", ")", ";", "sb", ".", "insert", "(", "0", ",", "type", ".", "getElementName", "(", ")", ")", ";", "}", "return", "sb", ".", "toString", "(", ")", ";", "}", "public", "void", "visitJDT", "(", "IField", "field", ",", "ITypeRequestor", "requestor", ")", "{", "IJavaElement", "oldEnclosing", "=", "enclosingElement", ";", "ASTNode", "oldEnclosingNode", "=", "enclosingDeclarationNode", ";", "enclosingElement", "=", "field", ";", "this", ".", "requestor", "=", "requestor", ";", "FieldNode", "fieldNode", "=", "findFieldNode", "(", "field", ")", ";", "if", "(", "fieldNode", "==", "null", ")", "{", "return", ";", "}", "enclosingDeclarationNode", "=", "fieldNode", ";", "scopes", ".", "push", "(", "new", "VariableScope", "(", "scopes", ".", "peek", "(", ")", ",", "fieldNode", ",", "fieldNode", ".", "isStatic", "(", ")", ")", ")", ";", "try", "{", "visitField", "(", "fieldNode", ")", ";", "}", "catch", "(", "VisitCompleted", "vc", ")", "{", "if", "(", "vc", ".", "status", "==", "VisitStatus", ".", "STOP_VISIT", ")", "{", "throw", "vc", ";", "}", "}", "finally", "{", "enclosingDeclarationNode", "=", "oldEnclosingNode", ";", "enclosingElement", "=", "oldEnclosing", ";", "scopes", ".", "pop", "(", ")", ";", "}", "if", "(", "isLazy", "(", "fieldNode", ")", ")", "{", "List", "<", "MethodNode", ">", "lazyMethods", "=", "(", "(", "ClassNode", ")", "enclosingDeclarationNode", ")", ".", "getDeclaredMethods", "(", "\"set$\"", "+", "field", ".", "getElementName", "(", ")", ")", ";", "if", "(", "lazyMethods", ".", "size", "(", ")", ">", "0", ")", "{", "MethodNode", "lazyMethod", "=", "lazyMethods", ".", "get", "(", "0", ")", ";", "enclosingDeclarationNode", "=", "lazyMethod", ";", "this", ".", "requestor", "=", "requestor", ";", "scopes", ".", "push", "(", "new", "VariableScope", "(", "scopes", ".", "peek", "(", ")", ",", "lazyMethod", ",", "lazyMethod", ".", "isStatic", "(", ")", ")", ")", ";", "try", "{", "visitConstructorOrMethod", "(", "lazyMethod", ",", "lazyMethod", "instanceof", "ConstructorNode", ")", ";", "}", "catch", "(", "VisitCompleted", "vc", ")", "{", "if", "(", "vc", ".", "status", "==", "VisitStatus", ".", "STOP_VISIT", ")", "{", "throw", "vc", ";", "}", "}", "finally", "{", "enclosingElement", "=", "oldEnclosing", ";", "enclosingDeclarationNode", "=", "oldEnclosingNode", ";", "scopes", ".", "pop", "(", ")", ";", "}", "}", "}", "}", "public", "void", "visitJDT", "(", "IMethod", "method", ",", "ITypeRequestor", "requestor", ")", "{", "IJavaElement", "oldEnclosing", "=", "enclosingElement", ";", "ASTNode", "oldEnclosingNode", "=", "enclosingDeclarationNode", ";", "enclosingElement", "=", "method", ";", "MethodNode", "methodNode", "=", "findMethodNode", "(", "method", ")", ";", "if", "(", "methodNode", "==", "null", ")", "{", "return", ";", "}", "enclosingDeclarationNode", "=", "methodNode", ";", "this", ".", "requestor", "=", "requestor", ";", "scopes", ".", "push", "(", "new", "VariableScope", "(", "scopes", ".", "peek", "(", ")", ",", "methodNode", ",", "methodNode", ".", "isStatic", "(", ")", ")", ")", ";", "try", "{", "visitConstructorOrMethod", "(", "methodNode", ",", "method", ".", "isConstructor", "(", ")", ")", ";", "}", "catch", "(", "VisitCompleted", "vc", ")", "{", "if", "(", "vc", ".", "status", "==", "VisitStatus", ".", "STOP_VISIT", ")", "{", "throw", "vc", ";", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "method", ".", "getElementName", "(", ")", "+", "\"", "in", "class", "\"", "+", "method", ".", "getParent", "(", ")", ".", "getElementName", "(", ")", ")", ";", "}", "finally", "{", "enclosingElement", "=", "oldEnclosing", ";", "enclosingDeclarationNode", "=", "oldEnclosingNode", ";", "scopes", ".", "pop", "(", ")", ";", "}", "}", "@", "SuppressWarnings", "(", "\"cast\"", ")", "private", "void", "visitClassInternal", "(", "ClassNode", "node", ")", "{", "if", "(", "resolver", "!=", "null", ")", "{", "resolver", ".", "currentClass", "=", "node", ";", "}", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "scope", ".", "addVariable", "(", "\"this\"", ",", "node", ",", "node", ")", ";", "visitAnnotations", "(", "node", ")", ";", "TypeLookupResult", "result", "=", "null", ";", "result", "=", "new", "TypeLookupResult", "(", "node", ",", "node", ",", "node", ",", "TypeConfidence", ".", "EXACT", ",", "scope", ")", ";", "VisitStatus", "status", "=", "notifyRequestor", "(", "node", ",", "requestor", ",", "result", ")", ";", "switch", "(", "status", ")", "{", "case", "CONTINUE", ":", "break", ";", "case", "CANCEL_BRANCH", ":", "return", ";", "case", "CANCEL_MEMBER", ":", "case", "STOP_VISIT", ":", "throw", "new", "VisitCompleted", "(", "status", ")", ";", "}", "if", "(", "!", "node", ".", "isEnum", "(", ")", ")", "{", "visitGenerics", "(", "node", ")", ";", "visitClassReference", "(", "node", ".", "getUnresolvedSuperClass", "(", ")", ")", ";", "}", "for", "(", "ClassNode", "intr", ":", "node", ".", "getInterfaces", "(", ")", ")", "{", "visitClassReference", "(", "intr", ")", ";", "}", "VariableScope", "currentScope", "=", "scope", ";", "MethodNode", "clinit", "=", "node", ".", "getMethod", "(", "\"<clinit>\"", ",", "new", "Parameter", "[", "0", "]", ")", ";", "if", "(", "clinit", "!=", "null", "&&", "clinit", ".", "getCode", "(", ")", "instanceof", "BlockStatement", ")", "{", "for", "(", "Statement", "element", ":", "(", "Iterable", "<", "Statement", ">", ")", "(", "(", "BlockStatement", ")", "clinit", ".", "getCode", "(", ")", ")", ".", "getStatements", "(", ")", ")", "{", "if", "(", "element", "instanceof", "ExpressionStatement", "&&", "(", "(", "ExpressionStatement", ")", "element", ")", ".", "getExpression", "(", ")", "instanceof", "BinaryExpression", ")", "{", "BinaryExpression", "bexpr", "=", "(", "BinaryExpression", ")", "(", "(", "ExpressionStatement", ")", "element", ")", ".", "getExpression", "(", ")", ";", "if", "(", "bexpr", ".", "getLeftExpression", "(", ")", "instanceof", "FieldExpression", ")", "{", "FieldNode", "f", "=", "(", "(", "FieldExpression", ")", "bexpr", ".", "getLeftExpression", "(", ")", ")", ".", "getField", "(", ")", ";", "if", "(", "f", "!=", "null", "&&", "f", ".", "isStatic", "(", ")", "&&", "bexpr", ".", "getRightExpression", "(", ")", "!=", "null", ")", "{", "VariableScope", "fieldScope", "=", "new", "VariableScope", "(", "currentScope", ",", "f", ",", "true", ")", ";", "scopes", ".", "push", "(", "fieldScope", ")", ";", "try", "{", "bexpr", ".", "getRightExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "}", "finally", "{", "scopes", ".", "pop", "(", ")", ";", "}", "}", "}", "}", "}", "}", "for", "(", "Statement", "element", ":", "(", "Iterable", "<", "Statement", ">", ")", "node", ".", "getObjectInitializerStatements", "(", ")", ")", "{", "element", ".", "visit", "(", "this", ")", ";", "}", "for", "(", "ConstructorNode", "constructor", ":", "(", "Iterable", "<", "ConstructorNode", ">", ")", "node", ".", "getDeclaredConstructors", "(", ")", ")", "{", "if", "(", "constructor", ".", "isSynthetic", "(", ")", "&&", "(", "constructor", ".", "getParameters", "(", ")", "==", "null", "||", "constructor", ".", "getParameters", "(", ")", ".", "length", "==", "0", ")", ")", "{", "visitConstructor", "(", "constructor", ")", ";", "}", "}", "}", "@", "Override", "public", "void", "visitField", "(", "FieldNode", "node", ")", "{", "TypeLookupResult", "result", "=", "null", ";", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "assignmentStorer", ".", "storeField", "(", "node", ",", "scope", ")", ";", "for", "(", "ITypeLookup", "lookup", ":", "lookups", ")", "{", "TypeLookupResult", "candidate", "=", "lookup", ".", "lookupType", "(", "node", ",", "scope", ")", ";", "if", "(", "candidate", "!=", "null", ")", "{", "if", "(", "result", "==", "null", "||", "result", ".", "confidence", ".", "isLessPreciseThan", "(", "candidate", ".", "confidence", ")", ")", "{", "result", "=", "candidate", ";", "}", "if", "(", "TypeConfidence", ".", "LOOSELY_INFERRED", ".", "isLessPreciseThan", "(", "result", ".", "confidence", ")", ")", "{", "break", ";", "}", "}", "}", "scope", ".", "setPrimaryNode", "(", "false", ")", ";", "VisitStatus", "status", "=", "notifyRequestor", "(", "node", ",", "requestor", ",", "result", ")", ";", "switch", "(", "status", ")", "{", "case", "CONTINUE", ":", "ClassNode", "fieldType", "=", "node", ".", "getType", "(", ")", ";", "if", "(", "fieldType", "!=", "node", ".", "getDeclaringClass", "(", ")", ")", "{", "visitClassReference", "(", "fieldType", ")", ";", "}", "visitAnnotations", "(", "node", ")", ";", "Expression", "init", "=", "node", ".", "getInitialExpression", "(", ")", ";", "if", "(", "init", "!=", "null", ")", "{", "init", ".", "visit", "(", "this", ")", ";", "}", "case", "CANCEL_BRANCH", ":", "return", ";", "case", "CANCEL_MEMBER", ":", "case", "STOP_VISIT", ":", "throw", "new", "VisitCompleted", "(", "status", ")", ";", "}", "}", "private", "void", "visitClassReference", "(", "ClassNode", "node", ")", "{", "if", "(", "node", ".", "isGenericsPlaceHolder", "(", ")", ")", "{", "return", ";", "}", "TypeLookupResult", "result", "=", "null", ";", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "for", "(", "ITypeLookup", "lookup", ":", "lookups", ")", "{", "TypeLookupResult", "candidate", "=", "lookup", ".", "lookupType", "(", "node", ",", "scope", ")", ";", "if", "(", "candidate", "!=", "null", ")", "{", "if", "(", "result", "==", "null", "||", "result", ".", "confidence", ".", "isLessPreciseThan", "(", "candidate", ".", "confidence", ")", ")", "{", "result", "=", "candidate", ";", "}", "if", "(", "TypeConfidence", ".", "LOOSELY_INFERRED", ".", "isLessPreciseThan", "(", "result", ".", "confidence", ")", ")", "{", "break", ";", "}", "}", "}", "scope", ".", "setPrimaryNode", "(", "false", ")", ";", "VisitStatus", "status", "=", "notifyRequestor", "(", "node", ",", "requestor", ",", "result", ")", ";", "switch", "(", "status", ")", "{", "case", "CONTINUE", ":", "if", "(", "!", "node", ".", "isEnum", "(", ")", ")", "{", "visitGenerics", "(", "node", ")", ";", "}", "case", "CANCEL_BRANCH", ":", "return", ";", "case", "CANCEL_MEMBER", ":", "case", "STOP_VISIT", ":", "throw", "new", "VisitCompleted", "(", "status", ")", ";", "}", "}", "private", "void", "visitGenerics", "(", "ClassNode", "node", ")", "{", "if", "(", "node", ".", "isUsingGenerics", "(", ")", "&&", "node", ".", "getGenericsTypes", "(", ")", "!=", "null", ")", "{", "for", "(", "GenericsType", "gen", ":", "node", ".", "getGenericsTypes", "(", ")", ")", "{", "if", "(", "gen", ".", "getLowerBound", "(", ")", "!=", "null", ")", "{", "visitClassReference", "(", "gen", ".", "getLowerBound", "(", ")", ")", ";", "}", "if", "(", "gen", ".", "getUpperBounds", "(", ")", "!=", "null", ")", "{", "for", "(", "ClassNode", "upper", ":", "gen", ".", "getUpperBounds", "(", ")", ")", "{", "if", "(", "!", "upper", ".", "getName", "(", ")", ".", "equals", "(", "node", ".", "getName", "(", ")", ")", ")", "{", "visitClassReference", "(", "upper", ")", ";", "}", "}", "}", "if", "(", "gen", ".", "getType", "(", ")", "!=", "null", "&&", "gen", ".", "getName", "(", ")", ".", "charAt", "(", "0", ")", "!=", "'?'", ")", "{", "visitClassReference", "(", "gen", ".", "getType", "(", ")", ")", ";", "}", "}", "}", "}", "@", "Override", "public", "void", "visitConstructorOrMethod", "(", "MethodNode", "node", ",", "boolean", "isConstructor", ")", "{", "TypeLookupResult", "result", "=", "null", ";", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "for", "(", "ITypeLookup", "lookup", ":", "lookups", ")", "{", "TypeLookupResult", "candidate", "=", "lookup", ".", "lookupType", "(", "node", ",", "scope", ")", ";", "if", "(", "candidate", "!=", "null", ")", "{", "if", "(", "result", "==", "null", "||", "result", ".", "confidence", ".", "isLessPreciseThan", "(", "candidate", ".", "confidence", ")", ")", "{", "result", "=", "candidate", ";", "}", "if", "(", "TypeConfidence", ".", "LOOSELY_INFERRED", ".", "isLessPreciseThan", "(", "result", ".", "confidence", ")", ")", "{", "break", ";", "}", "}", "}", "scope", ".", "setPrimaryNode", "(", "false", ")", ";", "VisitStatus", "status", "=", "notifyRequestor", "(", "node", ",", "requestor", ",", "result", ")", ";", "switch", "(", "status", ")", "{", "case", "CONTINUE", ":", "GenericsType", "[", "]", "gens", "=", "node", ".", "getGenericsTypes", "(", ")", ";", "if", "(", "gens", "!=", "null", ")", "{", "for", "(", "GenericsType", "gen", ":", "gens", ")", "{", "if", "(", "gen", ".", "getLowerBound", "(", ")", "!=", "null", ")", "{", "visitClassReference", "(", "gen", ".", "getLowerBound", "(", ")", ")", ";", "}", "if", "(", "gen", ".", "getUpperBounds", "(", ")", "!=", "null", ")", "{", "for", "(", "ClassNode", "upper", ":", "gen", ".", "getUpperBounds", "(", ")", ")", "{", "visitClassReference", "(", "upper", ")", ";", "}", "}", "if", "(", "gen", ".", "getType", "(", ")", "!=", "null", "&&", "gen", ".", "getType", "(", ")", ".", "getName", "(", ")", ".", "charAt", "(", "0", ")", "!=", "'?'", ")", "{", "visitClassReference", "(", "gen", ".", "getType", "(", ")", ")", ";", "}", "}", "}", "visitClassReference", "(", "node", ".", "getReturnType", "(", ")", ")", ";", "if", "(", "node", ".", "getExceptions", "(", ")", "!=", "null", ")", "{", "for", "(", "ClassNode", "e", ":", "node", ".", "getExceptions", "(", ")", ")", "{", "visitClassReference", "(", "e", ")", ";", "}", "}", "if", "(", "handleParameterList", "(", "node", ".", "getParameters", "(", ")", ")", ")", "{", "super", ".", "visitConstructorOrMethod", "(", "node", ",", "isConstructor", ")", ";", "}", "case", "CANCEL_BRANCH", ":", "return", ";", "case", "CANCEL_MEMBER", ":", "case", "STOP_VISIT", ":", "throw", "new", "VisitCompleted", "(", "status", ")", ";", "}", "}", "@", "SuppressWarnings", "(", "\"cast\"", ")", "@", "Override", "public", "void", "visitAnnotations", "(", "AnnotatedNode", "node", ")", "{", "for", "(", "AnnotationNode", "annotation", ":", "(", "Iterable", "<", "AnnotationNode", ">", ")", "node", ".", "getAnnotations", "(", ")", ")", "{", "visitAnnotation", "(", "annotation", ")", ";", "}", "super", ".", "visitAnnotations", "(", "node", ")", ";", "}", "@", "Override", "public", "void", "visitImports", "(", "ModuleNode", "node", ")", "{", "for", "(", "ImportNode", "imp", ":", "new", "ImportNodeCompatibilityWrapper", "(", "node", ")", ".", "getAllImportNodes", "(", ")", ")", "{", "TypeLookupResult", "result", "=", "null", ";", "IJavaElement", "oldEnclosingElement", "=", "enclosingElement", ";", "visitAnnotations", "(", "imp", ")", ";", "ClassNode", "type", "=", "imp", ".", "getType", "(", ")", ";", "if", "(", "type", "!=", "null", ")", "{", "String", "importName", "=", "imp", ".", "getClassName", "(", ")", ".", "replace", "(", "'$'", ",", "'.'", ")", "+", "(", "imp", ".", "getFieldName", "(", ")", "!=", "null", "?", "\".\"", "+", "imp", ".", "getFieldName", "(", ")", ":", "\"\"", ")", ";", "enclosingElement", "=", "unit", ".", "getImport", "(", "importName", ")", ";", "if", "(", "!", "enclosingElement", ".", "exists", "(", ")", ")", "{", "enclosingElement", "=", "oldEnclosingElement", ";", "}", "}", "try", "{", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "scope", ".", "setPrimaryNode", "(", "false", ")", ";", "assignmentStorer", ".", "storeImport", "(", "imp", ",", "scope", ")", ";", "for", "(", "ITypeLookup", "lookup", ":", "lookups", ")", "{", "TypeLookupResult", "candidate", "=", "lookup", ".", "lookupType", "(", "imp", ",", "scope", ")", ";", "if", "(", "candidate", "!=", "null", ")", "{", "if", "(", "result", "==", "null", "||", "result", ".", "confidence", ".", "isLessPreciseThan", "(", "candidate", ".", "confidence", ")", ")", "{", "result", "=", "candidate", ";", "}", "if", "(", "TypeConfidence", ".", "LOOSELY_INFERRED", ".", "isLessPreciseThan", "(", "result", ".", "confidence", ")", ")", "{", "break", ";", "}", "}", "}", "VisitStatus", "status", "=", "notifyRequestor", "(", "imp", ",", "requestor", ",", "result", ")", ";", "switch", "(", "status", ")", "{", "case", "CONTINUE", ":", "try", "{", "if", "(", "type", "!=", "null", ")", "{", "visitClassReference", "(", "type", ")", ";", "completeExpressionStack", ".", "push", "(", "imp", ")", ";", "if", "(", "imp", ".", "getFieldNameExpr", "(", ")", "!=", "null", ")", "{", "primaryTypeStack", ".", "push", "(", "type", ")", ";", "imp", ".", "getFieldNameExpr", "(", ")", ".", "visit", "(", "this", ")", ";", "dependentDeclaringTypeStack", ".", "pop", "(", ")", ";", "dependentTypeStack", ".", "pop", "(", ")", ";", "}", "completeExpressionStack", ".", "pop", "(", ")", ";", "}", "}", "catch", "(", "VisitCompleted", "e", ")", "{", "if", "(", "e", ".", "status", "==", "VisitStatus", ".", "STOP_VISIT", ")", "{", "throw", "e", ";", "}", "}", "continue", ";", "case", "CANCEL_BRANCH", ":", "case", "CANCEL_MEMBER", ":", "return", ";", "case", "STOP_VISIT", ":", "throw", "new", "VisitCompleted", "(", "status", ")", ";", "}", "}", "finally", "{", "enclosingElement", "=", "oldEnclosingElement", ";", "}", "}", "}", "@", "Override", "public", "void", "visitVariableExpression", "(", "VariableExpression", "node", ")", "{", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "visitAnnotations", "(", "node", ")", ";", "if", "(", "node", ".", "getAccessedVariable", "(", ")", "==", "node", ")", "{", "visitClassReference", "(", "node", ".", "getType", "(", ")", ")", ";", "}", "handleSimpleExpression", "(", "node", ")", ";", "scopes", ".", "peek", "(", ")", ".", "forgetCurrentNode", "(", ")", ";", "}", "@", "Override", "public", "void", "visitArgumentlistExpression", "(", "ArgumentListExpression", "node", ")", "{", "visitTupleExpression", "(", "node", ")", ";", "}", "@", "Override", "public", "void", "visitArrayExpression", "(", "ArrayExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitArrayExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitAttributeExpression", "(", "AttributeExpression", "node", ")", "{", "visitPropertyExpression", "(", "node", ")", ";", "}", "@", "Override", "public", "void", "visitBinaryExpression", "(", "BinaryExpression", "node", ")", "{", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "if", "(", "node", ".", "getEnd", "(", ")", "==", "0", ")", "{", "return", ";", "}", "visitAnnotations", "(", "node", ")", ";", "boolean", "isAssignment", "=", "node", ".", "getOperation", "(", ")", ".", "getType", "(", ")", "==", "Types", ".", "EQUALS", ";", "BinaryExpression", "oldEnclosingAssignment", "=", "enclosingAssignment", ";", "if", "(", "isAssignment", ")", "{", "enclosingAssignment", "=", "node", ";", "}", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "Expression", "toVisitPrimary", ";", "Expression", "toVisitDependent", ";", "if", "(", "isAssignment", ")", "{", "toVisitPrimary", "=", "node", ".", "getRightExpression", "(", ")", ";", "toVisitDependent", "=", "node", ".", "getLeftExpression", "(", ")", ";", "}", "else", "{", "toVisitPrimary", "=", "node", ".", "getLeftExpression", "(", ")", ";", "toVisitDependent", "=", "node", ".", "getRightExpression", "(", ")", ";", "}", "toVisitPrimary", ".", "visit", "(", "this", ")", ";", "ClassNode", "primaryExprType", ";", "primaryExprType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "if", "(", "isAssignment", ")", "{", "assignmentStorer", ".", "storeAssignment", "(", "node", ",", "scopes", ".", "peek", "(", ")", ",", "primaryExprType", ")", ";", "}", "toVisitDependent", ".", "visit", "(", "this", ")", ";", "completeExpressionStack", ".", "pop", "(", ")", ";", "ClassNode", "completeExprType", "=", "primaryExprType", ";", "ClassNode", "dependentExprType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "if", "(", "!", "isAssignment", ")", "{", "String", "associatedMethod", "=", "findBinaryOperatorName", "(", "node", ".", "getOperation", "(", ")", ".", "getText", "(", ")", ")", ";", "if", "(", "isArithmeticOperationOnNumberOrStringOrList", "(", "node", ".", "getOperation", "(", ")", ".", "getText", "(", ")", ",", "primaryExprType", ",", "dependentExprType", ")", ")", "{", "completeExprType", "=", "dependentExprType", ".", "equals", "(", "VariableScope", ".", "STRING_CLASS_NODE", ")", "?", "VariableScope", ".", "STRING_CLASS_NODE", ":", "primaryExprType", ";", "}", "else", "if", "(", "associatedMethod", "!=", "null", ")", "{", "TypeLookupResult", "result", "=", "lookupExpressionType", "(", "new", "ConstantExpression", "(", "associatedMethod", ")", ",", "primaryExprType", ",", "false", ",", "scopes", ".", "peek", "(", ")", ")", ";", "completeExprType", "=", "result", ".", "type", ";", "if", "(", "associatedMethod", ".", "equals", "(", "\"getAt\"", ")", "&&", "result", ".", "declaringType", ".", "equals", "(", "VariableScope", ".", "DGM_CLASS_NODE", ")", ")", "{", "if", "(", "primaryExprType", ".", "getName", "(", ")", ".", "equals", "(", "\"\"", ")", ")", "{", "completeExprType", "=", "VariableScope", ".", "BOOLEAN_CLASS_NODE", ";", "}", "else", "{", "GenericsType", "[", "]", "lhsGenericsTypes", "=", "primaryExprType", ".", "getGenericsTypes", "(", ")", ";", "ClassNode", "elementType", ";", "if", "(", "VariableScope", ".", "MAP_CLASS_NODE", ".", "equals", "(", "primaryExprType", ")", "&&", "lhsGenericsTypes", "!=", "null", "&&", "lhsGenericsTypes", ".", "length", "==", "2", ")", "{", "elementType", "=", "lhsGenericsTypes", "[", "1", "]", ".", "getType", "(", ")", ";", "}", "else", "{", "elementType", "=", "VariableScope", ".", "extractElementType", "(", "primaryExprType", ")", ";", "}", "if", "(", "dependentExprType", ".", "isArray", "(", ")", "||", "dependentExprType", ".", "getName", "(", ")", ".", "equals", "(", "VariableScope", ".", "LIST_CLASS_NODE", ".", "getName", "(", ")", ")", "||", "dependentExprType", ".", "implementsInterface", "(", "VariableScope", ".", "LIST_CLASS_NODE", ")", ")", "{", "completeExprType", "=", "createParameterizedList", "(", "elementType", ")", ";", "}", "else", "{", "completeExprType", "=", "elementType", ";", "}", "}", "}", "}", "else", "{", "completeExprType", "=", "findTypeOfBinaryExpression", "(", "node", ".", "getOperation", "(", ")", ".", "getText", "(", ")", ",", "primaryExprType", ",", "dependentExprType", ")", ";", "}", "}", "handleCompleteExpression", "(", "node", ",", "completeExprType", ",", "null", ")", ";", "enclosingAssignment", "=", "oldEnclosingAssignment", ";", "}", "private", "boolean", "isArithmeticOperationOnNumberOrStringOrList", "(", "String", "text", ",", "ClassNode", "lhs", ",", "ClassNode", "rhs", ")", "{", "if", "(", "text", ".", "length", "(", ")", "!=", "1", ")", "{", "return", "false", ";", "}", "switch", "(", "text", ".", "charAt", "(", "0", ")", ")", "{", "case", "'+'", ":", "case", "'-'", ":", "return", "VariableScope", ".", "STRING_CLASS_NODE", ".", "equals", "(", "lhs", ")", "||", "lhs", ".", "isDerivedFrom", "(", "VariableScope", ".", "NUMBER_CLASS_NODE", ")", "||", "VariableScope", ".", "NUMBER_CLASS_NODE", ".", "equals", "(", "lhs", ")", "||", "VariableScope", ".", "LIST_CLASS_NODE", ".", "equals", "(", "lhs", ")", "||", "lhs", ".", "implementsInterface", "(", "VariableScope", ".", "LIST_CLASS_NODE", ")", ";", "case", "'*'", ":", "case", "'/'", ":", "case", "'%'", ":", "return", "VariableScope", ".", "STRING_CLASS_NODE", ".", "equals", "(", "lhs", ")", "||", "lhs", ".", "isDerivedFrom", "(", "VariableScope", ".", "NUMBER_CLASS_NODE", ")", "||", "VariableScope", ".", "NUMBER_CLASS_NODE", ".", "equals", "(", "lhs", ")", ";", "default", ":", "return", "false", ";", "}", "}", "private", "String", "findBinaryOperatorName", "(", "String", "text", ")", "{", "char", "op", "=", "text", ".", "charAt", "(", "0", ")", ";", "switch", "(", "op", ")", "{", "case", "'+'", ":", "return", "\"plus\"", ";", "case", "'-'", ":", "return", "\"minus\"", ";", "case", "'*'", ":", "if", "(", "text", ".", "length", "(", ")", ">", "1", "&&", "text", ".", "equals", "(", "\"**\"", ")", ")", "{", "return", "\"power\"", ";", "}", "return", "\"multiply\"", ";", "case", "'/'", ":", "return", "\"div\"", ";", "case", "'%'", ":", "return", "\"mod\"", ";", "case", "'&'", ":", "return", "\"and\"", ";", "case", "'|'", ":", "return", "\"or\"", ";", "case", "'^'", ":", "return", "\"xor\"", ";", "case", "'>'", ":", "if", "(", "text", ".", "length", "(", ")", ">", "1", "&&", "text", ".", "equals", "(", "\">>\"", ")", ")", "{", "return", "\"rightShift\"", ";", "}", "break", ";", "case", "'<'", ":", "if", "(", "text", ".", "length", "(", ")", ">", "1", "&&", "text", ".", "equals", "(", "\"<<\"", ")", ")", "{", "return", "\"leftShift\"", ";", "}", "break", ";", "case", "'['", ":", "return", "\"getAt\"", ";", "}", "return", "null", ";", "}", "private", "String", "findUnaryOperatorName", "(", "String", "text", ")", "{", "char", "op", "=", "text", ".", "charAt", "(", "0", ")", ";", "switch", "(", "op", ")", "{", "case", "'+'", ":", "if", "(", "text", ".", "length", "(", ")", ">", "1", "&&", "text", ".", "equals", "(", "\"++\"", ")", ")", "{", "return", "\"next\"", ";", "}", "return", "\"positive\"", ";", "case", "'-'", ":", "if", "(", "text", ".", "length", "(", ")", ">", "1", "&&", "text", ".", "equals", "(", "\"--\"", ")", ")", "{", "return", "\"previous\"", ";", "}", "return", "\"negative\"", ";", "case", "']'", ":", "return", "\"putAt\"", ";", "case", "'~'", ":", "return", "\"\"", ";", "}", "return", "null", ";", "}", "@", "Override", "public", "void", "visitBitwiseNegationExpression", "(", "BitwiseNegationExpression", "node", ")", "{", "visitUnaryExpression", "(", "node", ",", "node", ".", "getExpression", "(", ")", ",", "\"~\"", ")", ";", "}", "@", "Override", "public", "void", "visitBooleanExpression", "(", "BooleanExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitBooleanExpression", "(", "node", ")", ";", "}", "}", "public", "void", "visitEmptyExpression", "(", "EmptyExpression", "node", ")", "{", "handleSimpleExpression", "(", "node", ")", ";", "}", "@", "Override", "public", "void", "visitBytecodeExpression", "(", "BytecodeExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitBytecodeExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitCastExpression", "(", "CastExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "visitClassReference", "(", "node", ".", "getType", "(", ")", ")", ";", "super", ".", "visitCastExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitClassExpression", "(", "ClassExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitClassExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitClosureExpression", "(", "ClosureExpression", "node", ")", "{", "VariableScope", "parent", "=", "scopes", ".", "peek", "(", ")", ";", "ClosureExpression", "enclosingClosure", "=", "parent", ".", "getEnclosingClosure", "(", ")", ";", "VariableScope", "scope", "=", "new", "VariableScope", "(", "parent", ",", "node", ",", "false", ")", ";", "scopes", ".", "push", "(", "scope", ")", ";", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "ClassNode", "[", "]", "implicitParamType", "=", "findImplicitParamType", "(", "scope", ",", "node", ")", ";", "if", "(", "node", ".", "getParameters", "(", ")", "!=", "null", "&&", "node", ".", "getParameters", "(", ")", ".", "length", ">", "0", ")", "{", "handleParameterList", "(", "node", ".", "getParameters", "(", ")", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "node", ".", "getParameters", "(", ")", ".", "length", ";", "i", "++", ")", "{", "Parameter", "parameter", "=", "node", ".", "getParameters", "(", ")", "[", "i", "]", ";", "if", "(", "implicitParamType", "[", "i", "]", "!=", "VariableScope", ".", "OBJECT_CLASS_NODE", "&&", "parameter", ".", "getType", "(", ")", ".", "equals", "(", "VariableScope", ".", "OBJECT_CLASS_NODE", ")", ")", "{", "parameter", ".", "setType", "(", "implicitParamType", "[", "i", "]", ")", ";", "scope", ".", "addVariable", "(", "parameter", ")", ";", "}", "}", "}", "else", "if", "(", "implicitParamType", "[", "0", "]", "!=", "VariableScope", ".", "OBJECT_CLASS_NODE", "&&", "!", "scope", ".", "containsInThisScope", "(", "\"it\"", ")", ")", "{", "scope", ".", "addVariable", "(", "\"it\"", ",", "implicitParamType", "[", "0", "]", ",", "VariableScope", ".", "OBJECT_CLASS_NODE", ")", ";", "}", "CallAndType", "cat", "=", "scope", ".", "getEnclosingMethodCallExpression", "(", ")", ";", "if", "(", "cat", "!=", "null", ")", "{", "scope", ".", "addVariable", "(", "\"delegate\"", ",", "cat", ".", "declaringType", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"getDelegate\"", ",", "cat", ".", "declaringType", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "}", "else", "{", "ClassNode", "thisType", "=", "scope", ".", "getThis", "(", ")", ";", "scope", ".", "addVariable", "(", "\"delegate\"", ",", "thisType", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"getDelegate\"", ",", "thisType", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "}", "if", "(", "enclosingClosure", "!=", "null", ")", "{", "scope", ".", "addVariable", "(", "\"owner\"", ",", "VariableScope", ".", "CLOSURE_CLASS", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"getOwner\"", ",", "VariableScope", ".", "CLOSURE_CLASS", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "}", "else", "{", "ClassNode", "thisType", "=", "scope", ".", "getThis", "(", ")", ";", "scope", ".", "addVariable", "(", "\"owner\"", ",", "thisType", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"getOwner\"", ",", "thisType", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"thisObject\"", ",", "VariableScope", ".", "OBJECT_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"\"", ",", "VariableScope", ".", "OBJECT_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"\"", ",", "VariableScope", ".", "INTEGER_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"\"", ",", "VariableScope", ".", "INTEGER_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"directive\"", ",", "VariableScope", ".", "INTEGER_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"getDirective\"", ",", "VariableScope", ".", "INTEGER_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"\"", ",", "VariableScope", ".", "INTEGER_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"\"", ",", "VariableScope", ".", "INTEGER_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"\"", ",", "VariableScope", ".", "CLASS_ARRAY_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "scope", ".", "addVariable", "(", "\"\"", ",", "VariableScope", ".", "CLASS_ARRAY_CLASS_NODE", ",", "VariableScope", ".", "CLOSURE_CLASS", ")", ";", "}", "super", ".", "visitClosureExpression", "(", "node", ")", ";", "}", "scopes", ".", "pop", "(", ")", ";", "}", "private", "ClassNode", "[", "]", "findImplicitParamType", "(", "VariableScope", "scope", ",", "ClosureExpression", "closure", ")", "{", "int", "numParams", "=", "closure", ".", "getParameters", "(", ")", "==", "null", "?", "0", ":", "closure", ".", "getParameters", "(", ")", ".", "length", ";", "if", "(", "numParams", "==", "0", ")", "{", "numParams", "++", ";", "}", "ClassNode", "[", "]", "allInferred", "=", "new", "ClassNode", "[", "numParams", "]", ";", "CallAndType", "call", "=", "scope", ".", "getEnclosingMethodCallExpression", "(", ")", ";", "if", "(", "call", "!=", "null", ")", "{", "String", "methodName", "=", "call", ".", "call", ".", "getMethodAsString", "(", ")", ";", "ClassNode", "inferredType", ";", "ClassNode", "delegateType", "=", "call", ".", "declaringType", ";", "if", "(", "dgmClosureMethods", ".", "contains", "(", "methodName", ")", ")", "{", "inferredType", "=", "VariableScope", ".", "extractElementType", "(", "delegateType", ")", ";", "}", "else", "if", "(", "dgmClosureIdentityMethods", ".", "contains", "(", "methodName", ")", ")", "{", "inferredType", "=", "VariableScope", ".", "clone", "(", "delegateType", ")", ";", "}", "else", "{", "inferredType", "=", "dgmClosureMethodsMap", ".", "get", "(", "methodName", ")", ";", "}", "if", "(", "inferredType", "!=", "null", ")", "{", "Arrays", ".", "fill", "(", "allInferred", ",", "inferredType", ")", ";", "if", "(", "methodName", ".", "equals", "(", "\"\"", ")", "&&", "allInferred", ".", "length", ">", "1", ")", "{", "allInferred", "[", "allInferred", ".", "length", "-", "1", "]", "=", "VariableScope", ".", "INTEGER_CLASS_NODE", ";", "}", "if", "(", "delegateType", ".", "getName", "(", ")", ".", "equals", "(", "VariableScope", ".", "MAP_CLASS_NODE", ".", "getName", "(", ")", ")", ")", "{", "if", "(", "(", "dgmClosureMaybeMap", ".", "contains", "(", "methodName", ")", "&&", "numParams", "==", "2", ")", "||", "(", "methodName", ".", "equals", "(", "\"\"", ")", "&&", "numParams", "==", "3", ")", ")", "{", "GenericsType", "[", "]", "typeParams", "=", "inferredType", ".", "getGenericsTypes", "(", ")", ";", "if", "(", "typeParams", "!=", "null", "&&", "typeParams", ".", "length", "==", "2", ")", "{", "allInferred", "[", "0", "]", "=", "typeParams", "[", "0", "]", ".", "getType", "(", ")", ";", "allInferred", "[", "1", "]", "=", "typeParams", "[", "1", "]", ".", "getType", "(", ")", ";", "}", "}", "}", "return", "allInferred", ";", "}", "}", "Arrays", ".", "fill", "(", "allInferred", ",", "VariableScope", ".", "OBJECT_CLASS_NODE", ")", ";", "return", "allInferred", ";", "}", "@", "Override", "public", "void", "visitBlockStatement", "(", "BlockStatement", "block", ")", "{", "scopes", ".", "push", "(", "new", "VariableScope", "(", "scopes", ".", "peek", "(", ")", ",", "block", ",", "false", ")", ")", ";", "boolean", "shouldContinue", "=", "handleStatement", "(", "block", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitBlockStatement", "(", "block", ")", ";", "}", "scopes", ".", "pop", "(", ")", ";", "}", "@", "Override", "public", "void", "visitReturnStatement", "(", "ReturnStatement", "ret", ")", "{", "boolean", "shouldContinue", "=", "handleStatement", "(", "ret", ")", ";", "if", "(", "shouldContinue", ")", "{", "if", "(", "ret", ".", "getExpression", "(", ")", "instanceof", "AnnotationConstantExpression", ")", "{", "visitClassReference", "(", "(", "(", "AnnotationConstantExpression", ")", "ret", ".", "getExpression", "(", ")", ")", ".", "getType", "(", ")", ")", ";", "}", "super", ".", "visitReturnStatement", "(", "ret", ")", ";", "}", "}", "@", "Override", "public", "void", "visitForLoop", "(", "ForStatement", "node", ")", "{", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "node", ".", "getCollectionExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "completeExpressionStack", ".", "pop", "(", ")", ";", "ClassNode", "collectionType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "scopes", ".", "push", "(", "new", "VariableScope", "(", "scopes", ".", "peek", "(", ")", ",", "node", ",", "false", ")", ")", ";", "Parameter", "param", "=", "node", ".", "getVariable", "(", ")", ";", "if", "(", "param", "!=", "null", ")", "{", "handleParameterList", "(", "new", "Parameter", "[", "]", "{", "param", "}", ")", ";", "if", "(", "param", ".", "getType", "(", ")", ".", "equals", "(", "VariableScope", ".", "OBJECT_CLASS_NODE", ")", ")", "{", "ClassNode", "extractedElementType", "=", "VariableScope", ".", "extractElementType", "(", "collectionType", ")", ";", "scopes", ".", "peek", "(", ")", ".", "addVariable", "(", "param", ".", "getName", "(", ")", ",", "extractedElementType", ",", "null", ")", ";", "}", "}", "node", ".", "getLoopBlock", "(", ")", ".", "visit", "(", "this", ")", ";", "scopes", ".", "pop", "(", ")", ";", "}", "@", "Override", "public", "void", "visitCatchStatement", "(", "CatchStatement", "node", ")", "{", "scopes", ".", "push", "(", "new", "VariableScope", "(", "scopes", ".", "peek", "(", ")", ",", "node", ",", "false", ")", ")", ";", "Parameter", "param", "=", "node", ".", "getVariable", "(", ")", ";", "if", "(", "param", "!=", "null", ")", "{", "handleParameterList", "(", "new", "Parameter", "[", "]", "{", "param", "}", ")", ";", "}", "super", ".", "visitCatchStatement", "(", "node", ")", ";", "scopes", ".", "pop", "(", ")", ";", "}", "@", "Override", "public", "void", "visitClosureListExpression", "(", "ClosureListExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitClosureListExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitConstantExpression", "(", "ConstantExpression", "node", ")", "{", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "handleSimpleExpression", "(", "node", ")", ";", "scopes", ".", "peek", "(", ")", ".", "forgetCurrentNode", "(", ")", ";", "}", "@", "Override", "public", "void", "visitConstructorCallExpression", "(", "ConstructorCallExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "visitClassReference", "(", "node", ".", "getType", "(", ")", ")", ";", "if", "(", "node", ".", "getArguments", "(", ")", "instanceof", "TupleExpression", "&&", "(", "(", "TupleExpression", ")", "node", ".", "getArguments", "(", ")", ")", ".", "getExpressions", "(", ")", ".", "size", "(", ")", "==", "1", ")", "{", "Expression", "arg", "=", "(", "(", "TupleExpression", ")", "node", ".", "getArguments", "(", ")", ")", ".", "getExpressions", "(", ")", ".", "get", "(", "0", ")", ";", "if", "(", "arg", "instanceof", "MapExpression", ")", "{", "enclosingConstructorCall", "=", "node", ";", "}", "}", "super", ".", "visitConstructorCallExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitDeclarationExpression", "(", "DeclarationExpression", "node", ")", "{", "visitBinaryExpression", "(", "node", ")", ";", "}", "@", "Override", "public", "void", "visitFieldExpression", "(", "FieldExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitFieldExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitGStringExpression", "(", "GStringExpression", "node", ")", "{", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitGStringExpression", "(", "node", ")", ";", "}", "scopes", ".", "peek", "(", ")", ".", "forgetCurrentNode", "(", ")", ";", "}", "@", "Override", "public", "void", "visitListExpression", "(", "ListExpression", "node", ")", "{", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "super", ".", "visitListExpression", "(", "node", ")", ";", "ClassNode", "eltType", ";", "if", "(", "node", ".", "getExpressions", "(", ")", ".", "size", "(", ")", ">", "0", ")", "{", "eltType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "else", "{", "eltType", "=", "VariableScope", ".", "OBJECT_CLASS_NODE", ";", "}", "completeExpressionStack", ".", "pop", "(", ")", ";", "ClassNode", "exprType", "=", "createParameterizedList", "(", "eltType", ")", ";", "handleCompleteExpression", "(", "node", ",", "exprType", ",", "null", ")", ";", "scopes", ".", "peek", "(", ")", ".", "forgetCurrentNode", "(", ")", ";", "}", "@", "Override", "public", "void", "visitMapEntryExpression", "(", "MapEntryExpression", "node", ")", "{", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "node", ".", "getKeyExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "ClassNode", "k", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "node", ".", "getValueExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "ClassNode", "v", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "completeExpressionStack", ".", "pop", "(", ")", ";", "ClassNode", "exprType", ";", "if", "(", "isPrimaryExpression", "(", "node", ")", ")", "{", "exprType", "=", "createParameterizedMap", "(", "k", ",", "v", ")", ";", "}", "else", "{", "exprType", "=", "VariableScope", ".", "OBJECT_CLASS_NODE", ";", "}", "handleCompleteExpression", "(", "node", ",", "exprType", ",", "null", ")", ";", "scopes", ".", "peek", "(", ")", ".", "forgetCurrentNode", "(", ")", ";", "}", "@", "Override", "public", "void", "visitMapExpression", "(", "MapExpression", "node", ")", "{", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "ClassNode", "newType", ";", "if", "(", "enclosingConstructorCall", "!=", "null", ")", "{", "newType", "=", "enclosingConstructorCall", ".", "getType", "(", ")", ";", "enclosingConstructorCall", "=", "null", ";", "}", "else", "{", "newType", "=", "null", ";", "}", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "if", "(", "newType", "==", "null", ")", "{", "for", "(", "MapEntryExpression", "entry", ":", "node", ".", "getMapEntryExpressions", "(", ")", ")", "{", "entry", ".", "visit", "(", "this", ")", ";", "}", "}", "else", "{", "for", "(", "MapEntryExpression", "entry", ":", "node", ".", "getMapEntryExpressions", "(", ")", ")", "{", "Expression", "key", "=", "entry", ".", "getKeyExpression", "(", ")", ";", "if", "(", "key", "instanceof", "ConstantExpression", ")", "{", "String", "fieldName", "=", "key", ".", "getText", "(", ")", ";", "FieldNode", "field", "=", "newType", ".", "getField", "(", "fieldName", ")", ";", "if", "(", "field", "!=", "null", ")", "{", "TypeLookupResult", "result", "=", "new", "TypeLookupResult", "(", "field", ".", "getType", "(", ")", ",", "field", ".", "getDeclaringClass", "(", ")", ",", "field", ",", "TypeConfidence", ".", "EXACT", ",", "scopes", ".", "peek", "(", ")", ")", ";", "handleRequestor", "(", "key", ",", "newType", ",", "result", ")", ";", "}", "else", "{", "handleSimpleExpression", "(", "key", ")", ";", "}", "}", "else", "{", "handleSimpleExpression", "(", "key", ")", ";", "}", "handleSimpleExpression", "(", "entry", ".", "getValueExpression", "(", ")", ")", ";", "}", "}", "completeExpressionStack", ".", "pop", "(", ")", ";", "ClassNode", "exprType", ";", "if", "(", "node", ".", "getMapEntryExpressions", "(", ")", ".", "size", "(", ")", ">", "0", "&&", "newType", "==", "null", ")", "{", "exprType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "else", "{", "exprType", "=", "createParameterizedMap", "(", "VariableScope", ".", "OBJECT_CLASS_NODE", ",", "VariableScope", ".", "OBJECT_CLASS_NODE", ")", ";", "}", "handleCompleteExpression", "(", "node", ",", "exprType", ",", "null", ")", ";", "scopes", ".", "peek", "(", ")", ".", "forgetCurrentNode", "(", ")", ";", "}", "@", "Override", "public", "void", "visitMethodCallExpression", "(", "MethodCallExpression", "node", ")", "{", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "node", ".", "getObjectExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "if", "(", "node", ".", "isSpreadSafe", "(", ")", ")", "{", "ClassNode", "objType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "primaryTypeStack", ".", "push", "(", "VariableScope", ".", "extractElementType", "(", "objType", ")", ")", ";", "}", "node", ".", "getMethod", "(", ")", ".", "visit", "(", "this", ")", ";", "ClassNode", "exprType", "=", "dependentTypeStack", ".", "pop", "(", ")", ";", "ClassNode", "exprDeclaringType", "=", "dependentDeclaringTypeStack", ".", "pop", "(", ")", ";", "CallAndType", "call", "=", "new", "CallAndType", "(", "node", ",", "exprDeclaringType", ")", ";", "completeExpressionStack", ".", "pop", "(", ")", ";", "ClassNode", "catNode", "=", "isCategoryDeclaration", "(", "node", ")", ";", "if", "(", "catNode", "!=", "null", ")", "{", "addCategoryToBeDeclared", "(", "catNode", ")", ";", "}", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "scope", ".", "addEnclosingMethodCall", "(", "call", ")", ";", "node", ".", "getArguments", "(", ")", ".", "visit", "(", "this", ")", ";", "scope", ".", "forgetEnclosingMethodCall", "(", ")", ";", "if", "(", "node", ".", "isSpreadSafe", "(", ")", ")", "{", "exprType", "=", "createParameterizedList", "(", "exprType", ")", ";", "}", "handleCompleteExpression", "(", "node", ",", "exprType", ",", "exprDeclaringType", ")", ";", "scopes", ".", "peek", "(", ")", ".", "forgetCurrentNode", "(", ")", ";", "}", "@", "Override", "public", "void", "visitMethodPointerExpression", "(", "MethodPointerExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitMethodPointerExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitNotExpression", "(", "NotExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitNotExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitPostfixExpression", "(", "PostfixExpression", "node", ")", "{", "visitUnaryExpression", "(", "node", ",", "node", ".", "getExpression", "(", ")", ",", "node", ".", "getOperation", "(", ")", ".", "getText", "(", ")", ")", ";", "}", "@", "Override", "public", "void", "visitPrefixExpression", "(", "PrefixExpression", "node", ")", "{", "visitUnaryExpression", "(", "node", ",", "node", ".", "getExpression", "(", ")", ",", "node", ".", "getOperation", "(", ")", ".", "getText", "(", ")", ")", ";", "}", "private", "void", "visitUnaryExpression", "(", "Expression", "node", ",", "Expression", "expression", ",", "String", "operation", ")", "{", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "expression", ".", "visit", "(", "this", ")", ";", "ClassNode", "primaryType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "String", "associatedMethod", "=", "findUnaryOperatorName", "(", "operation", ")", ";", "ClassNode", "completeExprType", ";", "if", "(", "associatedMethod", "==", "null", "&&", "primaryType", ".", "equals", "(", "VariableScope", ".", "NUMBER_CLASS_NODE", ")", "||", "primaryType", ".", "isDerivedFrom", "(", "VariableScope", ".", "NUMBER_CLASS_NODE", ")", ")", "{", "completeExprType", "=", "primaryType", ";", "}", "else", "{", "TypeLookupResult", "result", "=", "lookupExpressionType", "(", "new", "ConstantExpression", "(", "associatedMethod", ")", ",", "primaryType", ",", "false", ",", "scopes", ".", "peek", "(", ")", ")", ";", "completeExprType", "=", "result", ".", "type", ";", "}", "completeExpressionStack", ".", "pop", "(", ")", ";", "handleCompleteExpression", "(", "node", ",", "completeExprType", ",", "null", ")", ";", "}", "@", "Override", "public", "void", "visitPropertyExpression", "(", "PropertyExpression", "node", ")", "{", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "node", ".", "getObjectExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "ClassNode", "objType", ";", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "if", "(", "node", ".", "isSpreadSafe", "(", ")", ")", "{", "objType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "primaryTypeStack", ".", "push", "(", "objType", "=", "VariableScope", ".", "extractElementType", "(", "objType", ")", ")", ";", "}", "else", "{", "objType", "=", "primaryTypeStack", ".", "peek", "(", ")", ";", "}", "node", ".", "getProperty", "(", ")", ".", "visit", "(", "this", ")", ";", "ClassNode", "exprType", "=", "dependentTypeStack", ".", "pop", "(", ")", ";", "dependentDeclaringTypeStack", ".", "pop", "(", ")", ";", "completeExpressionStack", ".", "pop", "(", ")", ";", "if", "(", "node", ".", "isSpreadSafe", "(", ")", ")", "{", "if", "(", "objType", ".", "equals", "(", "VariableScope", ".", "MAP_CLASS_NODE", ")", "&&", "objType", ".", "getGenericsTypes", "(", ")", "!=", "null", "&&", "objType", ".", "getGenericsTypes", "(", ")", ".", "length", "==", "2", ")", "{", "exprType", "=", "objType", ".", "getGenericsTypes", "(", ")", "[", "1", "]", ".", "getType", "(", ")", ";", "}", "exprType", "=", "createParameterizedList", "(", "exprType", ")", ";", "}", "handleCompleteExpression", "(", "node", ",", "exprType", ",", "null", ")", ";", "scopes", ".", "peek", "(", ")", ".", "forgetCurrentNode", "(", ")", ";", "}", "@", "Override", "public", "void", "visitRangeExpression", "(", "RangeExpression", "node", ")", "{", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "scopes", ".", "peek", "(", ")", ".", "setCurrentNode", "(", "node", ")", ";", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "super", ".", "visitRangeExpression", "(", "node", ")", ";", "ClassNode", "eltType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "completeExpressionStack", ".", "pop", "(", ")", ";", "ClassNode", "rangeType", "=", "createParameterizedRange", "(", "eltType", ")", ";", "handleCompleteExpression", "(", "node", ",", "rangeType", ",", "null", ")", ";", "scopes", ".", "peek", "(", ")", ".", "forgetCurrentNode", "(", ")", ";", "}", "@", "Override", "public", "void", "visitShortTernaryExpression", "(", "ElvisOperatorExpression", "node", ")", "{", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "node", ".", "getTrueExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "ClassNode", "exprType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "completeExpressionStack", ".", "pop", "(", ")", ";", "node", ".", "getFalseExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "handleCompleteExpression", "(", "node", ",", "exprType", ",", "null", ")", ";", "}", "@", "Override", "public", "void", "visitSpreadExpression", "(", "SpreadExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitSpreadExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitSpreadMapExpression", "(", "SpreadMapExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitSpreadMapExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitStaticMethodCallExpression", "(", "StaticMethodCallExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", "&&", "node", ".", "getEnd", "(", ")", ">", "0", ")", "{", "visitClassReference", "(", "node", ".", "getOwnerType", "(", ")", ")", ";", "super", ".", "visitStaticMethodCallExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitTernaryExpression", "(", "TernaryExpression", "node", ")", "{", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "pop", "(", ")", ";", "}", "completeExpressionStack", ".", "push", "(", "node", ")", ";", "node", ".", "getBooleanExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "node", ".", "getTrueExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "ClassNode", "exprType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "node", ".", "getFalseExpression", "(", ")", ".", "visit", "(", "this", ")", ";", "completeExpressionStack", ".", "pop", "(", ")", ";", "handleCompleteExpression", "(", "node", ",", "exprType", ",", "null", ")", ";", "}", "@", "Override", "public", "void", "visitTupleExpression", "(", "TupleExpression", "node", ")", "{", "boolean", "shouldContinue", "=", "handleSimpleExpression", "(", "node", ")", ";", "if", "(", "shouldContinue", ")", "{", "super", ".", "visitTupleExpression", "(", "node", ")", ";", "}", "}", "@", "Override", "public", "void", "visitUnaryMinusExpression", "(", "UnaryMinusExpression", "node", ")", "{", "visitUnaryExpression", "(", "node", ",", "node", ".", "getExpression", "(", ")", ",", "\"-\"", ")", ";", "}", "@", "Override", "public", "void", "visitUnaryPlusExpression", "(", "UnaryPlusExpression", "node", ")", "{", "visitUnaryExpression", "(", "node", ",", "node", ".", "getExpression", "(", ")", ",", "\"+\"", ")", ";", "}", "private", "void", "visitAnnotation", "(", "AnnotationNode", "node", ")", "{", "TypeLookupResult", "result", "=", "null", ";", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "for", "(", "ITypeLookup", "lookup", ":", "lookups", ")", "{", "TypeLookupResult", "candidate", "=", "lookup", ".", "lookupType", "(", "node", ",", "scope", ")", ";", "if", "(", "candidate", "!=", "null", ")", "{", "if", "(", "result", "==", "null", "||", "result", ".", "confidence", ".", "isLessPreciseThan", "(", "candidate", ".", "confidence", ")", ")", "{", "result", "=", "candidate", ";", "}", "if", "(", "TypeConfidence", ".", "LOOSELY_INFERRED", ".", "isLessPreciseThan", "(", "result", ".", "confidence", ")", ")", "{", "break", ";", "}", "}", "}", "VisitStatus", "status", "=", "notifyRequestor", "(", "node", ",", "requestor", ",", "result", ")", ";", "switch", "(", "status", ")", "{", "case", "CONTINUE", ":", "visitClassReference", "(", "node", ".", "getClassNode", "(", ")", ")", ";", "if", "(", "node", ".", "getMembers", "(", ")", "!=", "null", ")", "{", "@", "SuppressWarnings", "(", "\"cast\"", ")", "Collection", "<", "Expression", ">", "exprs", "=", "(", "Collection", "<", "Expression", ">", ")", "node", ".", "getMembers", "(", ")", ".", "values", "(", ")", ";", "for", "(", "Expression", "expr", ":", "exprs", ")", "{", "if", "(", "expr", "instanceof", "AnnotationConstantExpression", ")", "{", "visitClassReference", "(", "(", "(", "AnnotationConstantExpression", ")", "expr", ")", ".", "getType", "(", ")", ")", ";", "}", "expr", ".", "visit", "(", "this", ")", ";", "}", "}", "break", ";", "case", "CANCEL_BRANCH", ":", "return", ";", "case", "CANCEL_MEMBER", ":", "case", "STOP_VISIT", ":", "throw", "new", "VisitCompleted", "(", "status", ")", ";", "}", "}", "private", "boolean", "handleStatement", "(", "Statement", "node", ")", "{", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "ClassNode", "declaring", "=", "scope", ".", "getDelegateOrThis", "(", ")", ";", "scope", ".", "setPrimaryNode", "(", "false", ")", ";", "if", "(", "node", "instanceof", "BlockStatement", ")", "{", "for", "(", "ITypeLookup", "lookup", ":", "lookups", ")", "{", "if", "(", "lookup", "instanceof", "ITypeLookupExtension", ")", "{", "(", "(", "ITypeLookupExtension", ")", "lookup", ")", ".", "lookupInBlock", "(", "(", "BlockStatement", ")", "node", ",", "scope", ")", ";", "}", "}", "}", "TypeLookupResult", "noLookup", "=", "new", "TypeLookupResult", "(", "declaring", ",", "declaring", ",", "declaring", ",", "TypeConfidence", ".", "EXACT", ",", "scope", ")", ";", "VisitStatus", "status", "=", "notifyRequestor", "(", "node", ",", "requestor", ",", "noLookup", ")", ";", "switch", "(", "status", ")", "{", "case", "CONTINUE", ":", "return", "true", ";", "case", "CANCEL_BRANCH", ":", "return", "false", ";", "case", "CANCEL_MEMBER", ":", "case", "STOP_VISIT", ":", "default", ":", "throw", "new", "VisitCompleted", "(", "status", ")", ";", "}", "}", "private", "boolean", "handleSimpleExpression", "(", "Expression", "node", ")", "{", "ClassNode", "primaryType", ";", "boolean", "isStatic", ";", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "primaryType", "=", "primaryTypeStack", ".", "pop", "(", ")", ";", "if", "(", "isImplicitThis", "(", ")", ")", "{", "primaryType", "=", "null", ";", "}", "isStatic", "=", "hasStaticObjectExpression", "(", "node", ")", ";", "scope", ".", "setMethodCallNumberOfArguments", "(", "getMethodCallArgs", "(", ")", ")", ";", "}", "else", "{", "primaryType", "=", "null", ";", "isStatic", "=", "false", ";", "}", "scope", ".", "setPrimaryNode", "(", "primaryType", "==", "null", ")", ";", "TypeLookupResult", "result", "=", "lookupExpressionType", "(", "node", ",", "primaryType", ",", "isStatic", ",", "scope", ")", ";", "return", "handleRequestor", "(", "node", ",", "primaryType", ",", "result", ")", ";", "}", "protected", "boolean", "isImplicitThis", "(", ")", "{", "return", "completeExpressionStack", ".", "peek", "(", ")", "instanceof", "MethodCallExpression", "&&", "(", "(", "MethodCallExpression", ")", "completeExpressionStack", ".", "peek", "(", ")", ")", ".", "isImplicitThis", "(", ")", ";", "}", "private", "void", "handleCompleteExpression", "(", "Expression", "node", ",", "ClassNode", "exprType", ",", "ClassNode", "exprDeclaringType", ")", "{", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "scope", ".", "setPrimaryNode", "(", "false", ")", ";", "handleRequestor", "(", "node", ",", "exprDeclaringType", ",", "new", "TypeLookupResult", "(", "exprType", ",", "exprDeclaringType", ",", "node", ",", "TypeConfidence", ".", "EXACT", ",", "scope", ")", ")", ";", "}", "private", "void", "postVisit", "(", "Expression", "node", ",", "ClassNode", "type", ",", "ClassNode", "declaringType", ")", "{", "if", "(", "isPrimaryExpression", "(", "node", ")", ")", "{", "primaryTypeStack", ".", "push", "(", "type", ")", ";", "}", "else", "if", "(", "isDependentExpression", "(", "node", ")", ")", "{", "dependentTypeStack", ".", "push", "(", "type", ")", ";", "dependentDeclaringTypeStack", ".", "push", "(", "declaringType", ")", ";", "}", "}", "private", "TypeLookupResult", "lookupExpressionType", "(", "Expression", "node", ",", "ClassNode", "objectExprType", ",", "boolean", "isStatic", ",", "VariableScope", "scope", ")", "{", "TypeLookupResult", "result", "=", "null", ";", "for", "(", "ITypeLookup", "lookup", ":", "lookups", ")", "{", "TypeLookupResult", "candidate", ";", "if", "(", "lookup", "instanceof", "ITypeLookupExtension", ")", "{", "candidate", "=", "(", "(", "ITypeLookupExtension", ")", "lookup", ")", ".", "lookupType", "(", "node", ",", "scope", ",", "objectExprType", ",", "isStatic", ")", ";", "}", "else", "{", "candidate", "=", "lookup", ".", "lookupType", "(", "node", ",", "scope", ",", "objectExprType", ")", ";", "}", "if", "(", "candidate", "!=", "null", ")", "{", "if", "(", "result", "==", "null", "||", "result", ".", "confidence", ".", "isLessPreciseThan", "(", "candidate", ".", "confidence", ")", ")", "{", "result", "=", "candidate", ";", "}", "if", "(", "TypeConfidence", ".", "LOOSELY_INFERRED", ".", "isLessPreciseThan", "(", "result", ".", "confidence", ")", ")", "{", "break", ";", "}", "}", "}", "return", "result", ";", "}", "private", "int", "getMethodCallArgs", "(", ")", "{", "ASTNode", "peek", "=", "completeExpressionStack", ".", "peek", "(", ")", ";", "if", "(", "peek", "instanceof", "MethodCallExpression", ")", "{", "MethodCallExpression", "call", "=", "(", "MethodCallExpression", ")", "peek", ";", "Expression", "arguments", "=", "call", ".", "getArguments", "(", ")", ";", "if", "(", "arguments", "instanceof", "ArgumentListExpression", ")", "{", "ArgumentListExpression", "list", "=", "(", "ArgumentListExpression", ")", "arguments", ";", "List", "<", "Expression", ">", "expressions", "=", "list", ".", "getExpressions", "(", ")", ";", "return", "expressions", "!=", "null", "?", "expressions", ".", "size", "(", ")", ":", "0", ";", "}", "else", "{", "return", "0", ";", "}", "}", "return", "-", "1", ";", "}", "private", "boolean", "handleParameterList", "(", "Parameter", "[", "]", "params", ")", "{", "if", "(", "params", "!=", "null", ")", "{", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "for", "(", "Parameter", "node", ":", "params", ")", "{", "assignmentStorer", ".", "storeParameterType", "(", "node", ",", "scope", ")", ";", "TypeLookupResult", "result", "=", "null", ";", "for", "(", "ITypeLookup", "lookup", ":", "lookups", ")", "{", "lookup", ".", "lookupType", "(", "node", ",", "scope", ")", ";", "result", "=", "lookup", ".", "lookupType", "(", "node", ".", "getType", "(", ")", ",", "scope", ")", ";", "TypeLookupResult", "candidate", "=", "lookup", ".", "lookupType", "(", "node", ".", "getType", "(", ")", ",", "scope", ")", ";", "if", "(", "candidate", "!=", "null", ")", "{", "if", "(", "result", "==", "null", "||", "result", ".", "confidence", ".", "isLessPreciseThan", "(", "candidate", ".", "confidence", ")", ")", "{", "result", "=", "candidate", ";", "}", "if", "(", "TypeConfidence", ".", "LOOSELY_INFERRED", ".", "isLessPreciseThan", "(", "result", ".", "confidence", ")", ")", "{", "break", ";", "}", "}", "}", "TypeLookupResult", "parameterResult", "=", "new", "TypeLookupResult", "(", "result", ".", "type", ",", "result", ".", "declaringType", ",", "node", ",", "TypeConfidence", ".", "EXACT", ",", "scope", ")", ";", "scope", ".", "setPrimaryNode", "(", "false", ")", ";", "VisitStatus", "status", "=", "notifyRequestor", "(", "node", ",", "requestor", ",", "parameterResult", ")", ";", "switch", "(", "status", ")", "{", "case", "CONTINUE", ":", "break", ";", "case", "CANCEL_BRANCH", ":", "return", "false", ";", "case", "CANCEL_MEMBER", ":", "case", "STOP_VISIT", ":", "throw", "new", "VisitCompleted", "(", "status", ")", ";", "}", "visitClassReference", "(", "node", ".", "getType", "(", ")", ")", ";", "visitAnnotations", "(", "node", ")", ";", "Expression", "init", "=", "node", ".", "getInitialExpression", "(", ")", ";", "if", "(", "init", "!=", "null", ")", "{", "init", ".", "visit", "(", "this", ")", ";", "}", "}", "}", "return", "true", ";", "}", "private", "boolean", "handleRequestor", "(", "Expression", "node", ",", "ClassNode", "primaryType", ",", "TypeLookupResult", "result", ")", "{", "result", ".", "enclosingAssignment", "=", "enclosingAssignment", ";", "VisitStatus", "status", "=", "requestor", ".", "acceptASTNode", "(", "node", ",", "result", ",", "enclosingElement", ")", ";", "VariableScope", "scope", "=", "scopes", ".", "peek", "(", ")", ";", "scope", ".", "setMethodCallNumberOfArguments", "(", "-", "1", ")", ";", "ClassNode", "rememberedDeclaringType", "=", "result", ".", "declaringType", ";", "if", "(", "scope", ".", "getCategoryNames", "(", ")", ".", "contains", "(", "rememberedDeclaringType", ")", ")", "{", "rememberedDeclaringType", "=", "primaryType", "!=", "null", "?", "primaryType", ":", "scope", ".", "getDelegateOrThis", "(", ")", ";", "}", "if", "(", "rememberedDeclaringType", "==", "null", ")", "{", "rememberedDeclaringType", "=", "VariableScope", ".", "OBJECT_CLASS_NODE", ";", "}", "switch", "(", "status", ")", "{", "case", "CONTINUE", ":", "postVisit", "(", "node", ",", "result", ".", "type", ",", "rememberedDeclaringType", ")", ";", "return", "true", ";", "case", "CANCEL_BRANCH", ":", "postVisit", "(", "node", ",", "result", ".", "type", ",", "rememberedDeclaringType", ")", ";", "return", "false", ";", "case", "CANCEL_MEMBER", ":", "case", "STOP_VISIT", ":", "throw", "new", "VisitCompleted", "(", "status", ")", ";", "}", "return", "false", ";", "}", "private", "VisitStatus", "notifyRequestor", "(", "ASTNode", "node", ",", "ITypeRequestor", "requestor", ",", "TypeLookupResult", "result", ")", "{", "return", "requestor", ".", "acceptASTNode", "(", "node", ",", "result", ",", "enclosingElement", ")", ";", "}", "private", "MethodNode", "findMethodNode", "(", "IMethod", "method", ")", "{", "ClassNode", "clazz", "=", "findClassWithName", "(", "createName", "(", "method", ".", "getDeclaringType", "(", ")", ")", ")", ";", "try", "{", "if", "(", "method", ".", "isConstructor", "(", ")", ")", "{", "List", "<", "ConstructorNode", ">", "constructors", "=", "clazz", ".", "getDeclaredConstructors", "(", ")", ";", "if", "(", "constructors", ".", "size", "(", ")", "==", "0", ")", "{", "return", "null", ";", "}", "outer", ":", "for", "(", "ConstructorNode", "constructorNode", ":", "constructors", ")", "{", "String", "[", "]", "jdtParamTypes", "=", "method", ".", "getParameterTypes", "(", ")", "==", "null", "?", "new", "String", "[", "0", "]", ":", "method", ".", "getParameterTypes", "(", ")", ";", "Parameter", "[", "]", "groovyParams", "=", "constructorNode", ".", "getParameters", "(", ")", "==", "null", "?", "new", "Parameter", "[", "0", "]", ":", "constructorNode", ".", "getParameters", "(", ")", ";", "if", "(", "groovyParams", "!=", "null", "&&", "groovyParams", ".", "length", ">", "0", "&&", "groovyParams", "[", "0", "]", ".", "getName", "(", ")", ".", "startsWith", "(", "\"$\"", ")", ")", "{", "Parameter", "[", "]", "newGroovyParams", "=", "new", "Parameter", "[", "groovyParams", ".", "length", "-", "1", "]", ";", "System", ".", "arraycopy", "(", "groovyParams", ",", "1", ",", "newGroovyParams", ",", "0", ",", "newGroovyParams", ".", "length", ")", ";", "groovyParams", "=", "newGroovyParams", ";", "}", "if", "(", "groovyParams", ".", "length", "!=", "jdtParamTypes", ".", "length", ")", "{", "continue", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "groovyParams", ".", "length", ";", "i", "++", ")", "{", "String", "groovyClassType", "=", "groovyParams", "[", "i", "]", ".", "getType", "(", ")", ".", "getName", "(", ")", ";", "if", "(", "!", "groovyClassType", ".", "startsWith", "(", "\"[\"", ")", ")", "{", "groovyClassType", "=", "Signature", ".", "createTypeSignature", "(", "groovyClassType", ",", "false", ")", ";", "}", "if", "(", "!", "groovyClassType", ".", "equals", "(", "jdtParamTypes", "[", "i", "]", ")", ")", "{", "continue", "outer", ";", "}", "}", "return", "constructorNode", ";", "}", "return", "constructors", ".", "get", "(", "0", ")", ";", "}", "else", "{", "List", "<", "MethodNode", ">", "methods", "=", "clazz", ".", "getMethods", "(", "method", ".", "getElementName", "(", ")", ")", ";", "if", "(", "methods", ".", "size", "(", ")", "==", "0", ")", "{", "return", "null", ";", "}", "outer", ":", "for", "(", "MethodNode", "methodNode", ":", "methods", ")", "{", "String", "[", "]", "jdtParamTypes", "=", "method", ".", "getParameterTypes", "(", ")", "==", "null", "?", "new", "String", "[", "0", "]", ":", "method", ".", "getParameterTypes", "(", ")", ";", "Parameter", "[", "]", "groovyParams", "=", "methodNode", ".", "getParameters", "(", ")", "==", "null", "?", "new", "Parameter", "[", "0", "]", ":", "methodNode", ".", "getParameters", "(", ")", ";", "if", "(", "groovyParams", ".", "length", "!=", "jdtParamTypes", ".", "length", ")", "{", "continue", ";", "}", "inner", ":", "for", "(", "int", "i", "=", "0", ";", "i", "<", "groovyParams", ".", "length", ";", "i", "++", ")", "{", "String", "simpleGroovyClassType", "=", "groovyParams", "[", "i", "]", ".", "getType", "(", ")", ".", "getNameWithoutPackage", "(", ")", ";", "if", "(", "!", "simpleGroovyClassType", ".", "startsWith", "(", "\"[\"", ")", ")", "{", "simpleGroovyClassType", "=", "Signature", ".", "createTypeSignature", "(", "simpleGroovyClassType", ",", "false", ")", ";", "}", "if", "(", "simpleGroovyClassType", ".", "equals", "(", "jdtParamTypes", "[", "i", "]", ")", ")", "{", "continue", "inner", ";", "}", "String", "groovyClassType", "=", "groovyParams", "[", "i", "]", ".", "getType", "(", ")", ".", "getName", "(", ")", ";", "if", "(", "!", "groovyClassType", ".", "startsWith", "(", "\"[\"", ")", ")", "{", "groovyClassType", "=", "Signature", ".", "createTypeSignature", "(", "groovyClassType", ",", "false", ")", ";", "}", "if", "(", "!", "groovyClassType", ".", "equals", "(", "jdtParamTypes", "[", "i", "]", ")", ")", "{", "continue", "outer", ";", "}", "}", "return", "methodNode", ";", "}", "return", "methods", ".", "get", "(", "0", ")", ";", "}", "}", "catch", "(", "JavaModelException", "e", ")", "{", "Util", ".", "log", "(", "e", ",", "\"\"", "+", "method", ".", "getElementName", "(", ")", "+", "\"", "in", "class", "\"", "+", "clazz", ".", "getName", "(", ")", ")", ";", "}", "return", "null", ";", "}", "private", "FieldNode", "findFieldNode", "(", "IField", "field", ")", "{", "ClassNode", "clazz", "=", "findClassWithName", "(", "createName", "(", "field", ".", "getDeclaringType", "(", ")", ")", ")", ";", "FieldNode", "fieldNode", "=", "clazz", ".", "getField", "(", "field", ".", "getElementName", "(", ")", ")", ";", "if", "(", "fieldNode", "==", "null", ")", "{", "fieldNode", "=", "clazz", ".", "getField", "(", "\"$\"", "+", "field", ".", "getElementName", "(", ")", ")", ";", "}", "return", "fieldNode", ";", "}", "private", "ClassNode", "createParameterizedList", "(", "ClassNode", "propType", ")", "{", "ClassNode", "list", "=", "VariableScope", ".", "clonedList", "(", ")", ";", "list", ".", "getGenericsTypes", "(", ")", "[", "0", "]", ".", "setType", "(", "propType", ")", ";", "list", ".", "getGenericsTypes", "(", ")", "[", "0", "]", ".", "setName", "(", "propType", ".", "getName", "(", ")", ")", ";", "return", "list", ";", "}", "private", "ClassNode", "createParameterizedRange", "(", "ClassNode", "propType", ")", "{", "ClassNode", "range", "=", "VariableScope", ".", "clonedRange", "(", ")", ";", "range", ".", "getGenericsTypes", "(", ")", "[", "0", "]", ".", "setType", "(", "propType", ")", ";", "range", ".", "getGenericsTypes", "(", ")", "[", "0", "]", ".", "setName", "(", "propType", ".", "getName", "(", ")", ")", ";", "return", "range", ";", "}", "private", "ClassNode", "createParameterizedMap", "(", "ClassNode", "k", ",", "ClassNode", "v", ")", "{", "ClassNode", "map", "=", "VariableScope", ".", "clonedMap", "(", ")", ";", "map", ".", "getGenericsTypes", "(", ")", "[", "0", "]", ".", "setType", "(", "k", ")", ";", "map", ".", "getGenericsTypes", "(", ")", "[", "0", "]", ".", "setName", "(", "k", ".", "getName", "(", ")", ")", ";", "map", ".", "getGenericsTypes", "(", ")", "[", "1", "]", ".", "setType", "(", "v", ")", ";", "map", ".", "getGenericsTypes", "(", ")", "[", "1", "]", ".", "setName", "(", "v", ".", "getName", "(", ")", ")", ";", "return", "map", ";", "}", "private", "boolean", "isLazy", "(", "FieldNode", "field", ")", "{", "List", "<", "AnnotationNode", ">", "annotations", "=", "field", ".", "getAnnotations", "(", ")", ";", "for", "(", "AnnotationNode", "annotation", ":", "annotations", ")", "{", "if", "(", "annotation", ".", "getClassNode", "(", ")", ".", "getName", "(", ")", ".", "equals", "(", "\"\"", ")", ")", "{", "return", "true", ";", "}", "}", "return", "false", ";", "}", "@", "Override", "protected", "SourceUnit", "getSourceUnit", "(", ")", "{", "return", "null", ";", "}", "@", "SuppressWarnings", "(", "\"cast\"", ")", "private", "ClassNode", "findClassWithName", "(", "String", "simpleName", ")", "{", "for", "(", "ClassNode", "clazz", ":", "(", "Iterable", "<", "ClassNode", ">", ")", "getModuleNode", "(", ")", ".", "getClasses", "(", ")", ")", "{", "if", "(", "clazz", ".", "getNameWithoutPackage", "(", ")", ".", "equals", "(", "simpleName", ")", ")", "{", "return", "clazz", ";", "}", "}", "return", "null", ";", "}", "private", "ModuleNodeInfo", "createModuleNode", "(", "GroovyCompilationUnit", "unit", ")", "{", "if", "(", "unit", ".", "getOwner", "(", ")", "==", "null", "||", "unit", ".", "owner", "==", "DefaultWorkingCopyOwner", ".", "PRIMARY", ")", "{", "return", "unit", ".", "getModuleInfo", "(", "true", ")", ";", "}", "else", "{", "return", "unit", ".", "getNewModuleInfo", "(", ")", ";", "}", "}", "private", "ModuleNode", "getModuleNode", "(", ")", "{", "if", "(", "enclosingDeclarationNode", "instanceof", "ModuleNode", ")", "{", "return", "(", "ModuleNode", ")", "enclosingDeclarationNode", ";", "}", "else", "if", "(", "enclosingDeclarationNode", "instanceof", "ClassNode", ")", "{", "return", "(", "(", "ClassNode", ")", "enclosingDeclarationNode", ")", ".", "getModule", "(", ")", ";", "}", "else", "if", "(", "enclosingDeclarationNode", "instanceof", "MethodNode", ")", "{", "return", "(", "(", "MethodNode", ")", "enclosingDeclarationNode", ")", ".", "getDeclaringClass", "(", ")", ".", "getModule", "(", ")", ";", "}", "else", "if", "(", "enclosingDeclarationNode", "instanceof", "FieldNode", ")", "{", "return", "(", "(", "FieldNode", ")", "enclosingDeclarationNode", ")", ".", "getDeclaringClass", "(", ")", ".", "getModule", "(", ")", ";", "}", "else", "{", "throw", "new", "IllegalArgumentException", "(", "\"\"", "+", "enclosingDeclarationNode", ")", ";", "}", "}", "private", "boolean", "isPrimaryExpression", "(", "Expression", "node", ")", "{", "if", "(", "!", "completeExpressionStack", ".", "isEmpty", "(", ")", ")", "{", "ASTNode", "complete", "=", "completeExpressionStack", ".", "peek", "(", ")", ";", "if", "(", "complete", "instanceof", "PropertyExpression", ")", "{", "PropertyExpression", "prop", "=", "(", "PropertyExpression", ")", "complete", ";", "return", "prop", ".", "getObjectExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "MethodCallExpression", ")", "{", "MethodCallExpression", "prop", "=", "(", "MethodCallExpression", ")", "complete", ";", "return", "prop", ".", "getObjectExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "BinaryExpression", ")", "{", "BinaryExpression", "prop", "=", "(", "BinaryExpression", ")", "complete", ";", "return", "prop", ".", "getRightExpression", "(", ")", "==", "node", "||", "prop", ".", "getLeftExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "AttributeExpression", ")", "{", "AttributeExpression", "prop", "=", "(", "AttributeExpression", ")", "complete", ";", "return", "prop", ".", "getObjectExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "TernaryExpression", ")", "{", "TernaryExpression", "prop", "=", "(", "TernaryExpression", ")", "complete", ";", "return", "prop", ".", "getTrueExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "ForStatement", ")", "{", "ForStatement", "prop", "=", "(", "ForStatement", ")", "complete", ";", "return", "prop", ".", "getCollectionExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "ListExpression", ")", "{", "return", "(", "(", "ListExpression", ")", "complete", ")", ".", "getExpressions", "(", ")", ".", "size", "(", ")", ">", "0", "&&", "(", "(", "ListExpression", ")", "complete", ")", ".", "getExpression", "(", "0", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "RangeExpression", ")", "{", "return", "(", "(", "RangeExpression", ")", "complete", ")", ".", "getFrom", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "MapEntryExpression", ")", "{", "return", "(", "(", "MapEntryExpression", ")", "complete", ")", ".", "getKeyExpression", "(", ")", "==", "node", "||", "(", "(", "MapEntryExpression", ")", "complete", ")", ".", "getValueExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "MapExpression", ")", "{", "return", "(", "(", "MapExpression", ")", "complete", ")", ".", "getMapEntryExpressions", "(", ")", ".", "size", "(", ")", ">", "0", "&&", "(", "(", "MapExpression", ")", "complete", ")", ".", "getMapEntryExpressions", "(", ")", ".", "get", "(", "0", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "PrefixExpression", ")", "{", "return", "(", "(", "PrefixExpression", ")", "complete", ")", ".", "getExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "PostfixExpression", ")", "{", "return", "(", "(", "PostfixExpression", ")", "complete", ")", ".", "getExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "UnaryPlusExpression", ")", "{", "return", "(", "(", "UnaryPlusExpression", ")", "complete", ")", ".", "getExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "UnaryMinusExpression", ")", "{", "return", "(", "(", "UnaryMinusExpression", ")", "complete", ")", ".", "getExpression", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "BitwiseNegationExpression", ")", "{", "return", "(", "(", "BitwiseNegationExpression", ")", "complete", ")", ".", "getExpression", "(", ")", "==", "node", ";", "}", "else", "{", "return", "false", ";", "}", "}", "else", "{", "return", "false", ";", "}", "}", "private", "boolean", "isDependentExpression", "(", "Expression", "node", ")", "{", "if", "(", "!", "completeExpressionStack", ".", "isEmpty", "(", ")", ")", "{", "ASTNode", "complete", "=", "completeExpressionStack", ".", "peek", "(", ")", ";", "if", "(", "complete", "instanceof", "PropertyExpression", ")", "{", "PropertyExpression", "prop", "=", "(", "PropertyExpression", ")", "complete", ";", "return", "prop", ".", "getProperty", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "MethodCallExpression", ")", "{", "MethodCallExpression", "prop", "=", "(", "MethodCallExpression", ")", "complete", ";", "return", "prop", ".", "getMethod", "(", ")", "==", "node", ";", "}", "else", "if", "(", "complete", "instanceof", "ImportNode", ")", "{", "ImportNode", "imp", "=", "(", "ImportNode", ")", "complete", ";", "return", "node", "==", "imp", ".", "getAliasExpr", "(", ")", "||", "node", "==", "imp", ".", "getFieldNameExpr", "(", ")", ";", "}", "else", "{", "return", "false", ";", "}", "}", "else", "{", "return", "false", ";", "}", "}", "private", "boolean", "hasStaticObjectExpression", "(", "Expression", "node", ")", "{", "if", "(", "!", "completeExpressionStack", ".", "isEmpty", "(", ")", ")", "{", "ASTNode", "maybeProperty", "=", "completeExpressionStack", ".", "peek", "(", ")", ";", "if", "(", "maybeProperty", "instanceof", "PropertyExpression", ")", "{", "PropertyExpression", "prop", "=", "(", "PropertyExpression", ")", "maybeProperty", ";", "return", "prop", ".", "getObjectExpression", "(", ")", "instanceof", "ClassExpression", "||", "(", "prop", ".", "isImplicitThis", "(", ")", "&&", "scopes", ".", "peek", "(", ")", ".", "isStatic", "(", ")", ")", ";", "}", "else", "if", "(", "maybeProperty", "instanceof", "MethodCallExpression", ")", "{", "MethodCallExpression", "prop", "=", "(", "MethodCallExpression", ")", "maybeProperty", ";", "return", "prop", ".", "getObjectExpression", "(", ")", "instanceof", "ClassExpression", "||", "(", "prop", ".", "isImplicitThis", "(", ")", "&&", "scopes", ".", "peek", "(", ")", ".", "isStatic", "(", ")", ")", ";", "}", "else", "if", "(", "maybeProperty", "instanceof", "AttributeExpression", ")", "{", "AttributeExpression", "prop", "=", "(", "AttributeExpression", ")", "maybeProperty", ";", "return", "prop", ".", "getObjectExpression", "(", ")", "instanceof", "ClassExpression", "||", "(", "prop", ".", "isImplicitThis", "(", ")", "&&", "scopes", ".", "peek", "(", ")", ".", "isStatic", "(", ")", ")", ";", "}", "else", "{", "return", "false", ";", "}", "}", "else", "{", "return", "false", ";", "}", "}", "private", "ClassNode", "findTypeOfBinaryExpression", "(", "String", "operation", ",", "ClassNode", "lhs", ",", "ClassNode", "rhs", ")", "{", "char", "op", "=", "operation", ".", "charAt", "(", "0", ")", ";", "switch", "(", "op", ")", "{", "case", "'*'", ":", "if", "(", "operation", ".", "equals", "(", "\"*.\"", ")", "||", "operation", ".", "equals", "(", "\"*.@\"", ")", ")", "{", "return", "VariableScope", ".", "clonedList", "(", ")", ";", "}", "case", "'~'", ":", "return", "VariableScope", ".", "STRING_CLASS_NODE", ";", "case", "'!'", ":", "case", "'<'", ":", "case", "'>'", ":", "if", "(", "operation", ".", "length", "(", ")", ">", "1", ")", "{", "if", "(", "operation", ".", "equals", "(", "\"<=>\"", ")", ")", "{", "return", "VariableScope", ".", "INTEGER_CLASS_NODE", ";", "}", "}", "return", "VariableScope", ".", "BOOLEAN_CLASS_NODE", ";", "case", "'i'", ":", "if", "(", "operation", ".", "equals", "(", "\"is\"", ")", "||", "operation", ".", "equals", "(", "\"in\"", ")", ")", "{", "return", "VariableScope", ".", "BOOLEAN_CLASS_NODE", ";", "}", "else", "{", "return", "rhs", ";", "}", "case", "'.'", ":", "if", "(", "operation", ".", "equals", "(", "\".&\"", ")", ")", "{", "return", "ClassHelper", ".", "CLOSURE_TYPE", ";", "}", "else", "{", "return", "rhs", ";", "}", "case", "'='", ":", "if", "(", "operation", ".", "length", "(", ")", ">", "1", ")", "{", "if", "(", "operation", ".", "charAt", "(", "1", ")", "==", "'='", ")", "{", "return", "VariableScope", ".", "BOOLEAN_CLASS_NODE", ";", "}", "else", "if", "(", "operation", ".", "charAt", "(", "1", ")", "==", "'~'", ")", "{", "return", "VariableScope", ".", "MATCHER_CLASS_NODE", ";", "}", "}", "default", ":", "return", "rhs", ";", "}", "}", "private", "void", "addCategoryToBeDeclared", "(", "ClassNode", "catNode", ")", "{", "scopes", ".", "peek", "(", ")", ".", "setCategoryBeingDeclared", "(", "catNode", ")", ";", "}", "private", "ClassNode", "isCategoryDeclaration", "(", "MethodCallExpression", "node", ")", "{", "String", "methodAsString", "=", "node", ".", "getMethodAsString", "(", ")", ";", "if", "(", "methodAsString", "!=", "null", "&&", "methodAsString", ".", "equals", "(", "\"use\"", ")", ")", "{", "Expression", "exprs", "=", "node", ".", "getArguments", "(", ")", ";", "if", "(", "exprs", "instanceof", "ArgumentListExpression", ")", "{", "ArgumentListExpression", "args", "=", "(", "ArgumentListExpression", ")", "exprs", ";", "if", "(", "args", ".", "getExpressions", "(", ")", ".", "size", "(", ")", ">=", "2", "&&", "args", ".", "getExpressions", "(", ")", ".", "get", "(", "1", ")", "instanceof", "ClosureExpression", ")", "{", "@", "SuppressWarnings", "(", "\"cast\"", ")", "Expression", "expr", "=", "(", "(", "List", "<", "Expression", ">", ")", "args", ".", "getExpressions", "(", ")", ")", ".", "get", "(", "0", ")", ";", "if", "(", "expr", "instanceof", "ClassExpression", ")", "{", "return", "expr", ".", "getType", "(", ")", ";", "}", "else", "if", "(", "expr", "instanceof", "VariableExpression", "&&", "expr", ".", "getText", "(", ")", "!=", "null", ")", "{", "VariableInfo", "info", "=", "scopes", ".", "peek", "(", ")", ".", "lookupName", "(", "expr", ".", "getText", "(", ")", ")", ";", "if", "(", "info", "!=", "null", ")", "{", "return", "info", ".", "type", ";", "}", "}", "}", "}", "}", "return", "null", ";", "}", "private", "void", "postVisitSanityCheck", "(", ")", "{", "Assert", ".", "isTrue", "(", "completeExpressionStack", ".", "isEmpty", "(", ")", ",", "\"\"", ")", ";", "Assert", ".", "isTrue", "(", "primaryTypeStack", ".", "isEmpty", "(", ")", ",", "\"\"", ")", ";", "Assert", ".", "isTrue", "(", "dependentDeclaringTypeStack", ".", "isEmpty", "(", ")", ",", "\"\"", ")", ";", "Assert", ".", "isTrue", "(", "dependentTypeStack", ".", "isEmpty", "(", ")", ",", "\"\"", ")", ";", "Assert", ".", "isTrue", "(", "scopes", ".", "isEmpty", "(", ")", ",", "\"\"", ")", ";", "}", "}", "</s>" ]
6,799
[ "<s>", "package", "org", ".", "eclipse", ".", "jdt", ".", "groovy", ".", "search", ";", "import", "groovy", ".", "lang", ".", "GroovyObjectSupport", ";", "import", "groovy", ".", "lang", ".", "Tuple", ";", "import", "java", ".", "io", ".", "BufferedReader", ";", "import", "java", ".", "io", ".", "BufferedWriter", ";", "import", "java", ".", "io", ".", "DataInputStream", ";", "import", "java", ".", "io", ".", "DataOutputStream", ";", "import", "java", ".", "io", ".", "File", ";", "import", "java", ".", "io", ".", "InputStream", ";", "import", "java", ".", "io", ".", "ObjectInputStream", ";", "import", "java", ".", "io", ".", "ObjectOutputStream", ";", "import", "java", ".", "io", ".", "OutputStream", ";", "import", "java", ".", "io", ".", "PrintWriter", ";", "import", "java", ".", "util", ".", "ArrayList", ";", "import", "java", ".", "util", ".", "Collections", ";", "import", "java", ".", "util", ".", "Enumeration", ";", "import", "java", ".", "util", ".", "HashMap", ";", "import", "java", ".", "util", ".", "Iterator", ";", "import", "java", ".", "util", ".", "LinkedHashSet", ";", "import", "java", ".", "util", ".", "List", ";", "import", "java", ".", "util", ".", "Map", ";", "import", "java", ".", "util", ".", "Map", ".", "Entry", ";", "import", "java", ".", "util", ".", "NoSuchElementException", ";", "import", "java", ".", "util", ".", "Set", ";", "import", "java", ".", "util", ".", "Stack", ";", "import", "java", ".", "util", ".", "regex", ".", "Matcher", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ASTNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassHelper", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ClassNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "FieldNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "GenericsType", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "MethodNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "ModuleNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Parameter", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "PropertyNode", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "Variable", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "ClosureExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "ast", ".", "expr", ".", "MethodCallExpression", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "DateGroovyMethods", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "DefaultGroovyMethods", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "DefaultGroovyStaticMethods", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "EncodingGroovyMethods", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "ProcessGroovyMethods", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "SwingGroovyMethods", ";", "import", "org", ".", "codehaus", ".", "groovy", ".", "runtime", ".", "XmlGroovyMethods", ";", "import", "org", ".", "codehaus", ".", "jdt", ".", "groovy", ".", "internal", ".", "compiler", ".", "ast", ".", "LazyGenericsType", ";", "import", "org", ".", "eclipse", ".", "core", ".", "runtime", ".", "Assert", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "core", ".", "Signature", ";", "import", "org", ".", "eclipse", ".", "jdt", ".", "internal", ".", "core", ".", "util", ".", "Util", ";", "public", "class", "VariableScope", "{", "public", "static", "final", "ClassNode", "OBJECT_CLASS_NODE", "=", "ClassHelper", ".", "OBJECT_TYPE", ";", "public", "static", "final", "ClassNode", "LIST_CLASS_NODE", "=", "ClassHelper", ".", "LIST_TYPE", ";", "public", "static", "final", "ClassNode", "RANGE_CLASS_NODE", "=", "ClassHelper", ".", "RANGE_TYPE", ";", "public", "static", "final", "ClassNode", "TUPLE_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "Tuple", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "PATTERN_CLASS_NODE", "=", "ClassHelper", ".", "PATTERN_TYPE", ";", "public", "static", "final", "ClassNode", "MATCHER_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "Matcher", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "MAP_CLASS_NODE", "=", "ClassHelper", ".", "MAP_TYPE", ";", "public", "static", "final", "ClassNode", "STRING_CLASS_NODE", "=", "ClassHelper", ".", "STRING_TYPE", ";", "public", "static", "final", "ClassNode", "GSTRING_CLASS_NODE", "=", "ClassHelper", ".", "GSTRING_TYPE", ";", "public", "static", "final", "ClassNode", "VOID_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "void", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "VOID_WRAPPER_CLASS_NODE", "=", "ClassHelper", ".", "void_WRAPPER_TYPE", ";", "public", "static", "final", "ClassNode", "NUMBER_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "Number", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "ITERATOR_CLASS", "=", "ClassHelper", ".", "make", "(", "Iterator", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "ENUMERATION_CLASS", "=", "ClassHelper", ".", "make", "(", "Enumeration", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "INPUT_STREAM_CLASS", "=", "ClassHelper", ".", "make", "(", "InputStream", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "OUTPUT_STREAM_CLASS", "=", "ClassHelper", ".", "make", "(", "OutputStream", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "DATA_INPUT_STREAM_CLASS", "=", "ClassHelper", ".", "make", "(", "DataInputStream", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "DATA_OUTPUT_STREAM_CLASS", "=", "ClassHelper", ".", "make", "(", "DataOutputStream", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "OBJECT_OUTPUT_STREAM", "=", "ClassHelper", ".", "make", "(", "ObjectOutputStream", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "OBJECT_INPUT_STREAM", "=", "ClassHelper", ".", "make", "(", "ObjectInputStream", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "FILE_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "File", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "BUFFERED_READER_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "BufferedReader", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "BUFFERED_WRITER_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "BufferedWriter", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "PRINT_WRITER_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "PrintWriter", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "CLOSURE_CLASS", "=", "ClassHelper", ".", "CLOSURE_TYPE", ";", "public", "static", "final", "ClassNode", "GROOVY_OBJECT_SUPPORT", "=", "ClassHelper", ".", "make", "(", "GroovyObjectSupport", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "DGM_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "DefaultGroovyMethods", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "EGM_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "EncodingGroovyMethods", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "PGM_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "ProcessGroovyMethods", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "SGM_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "SwingGroovyMethods", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "XGM_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "XmlGroovyMethods", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "DGSM_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "DefaultGroovyStaticMethods", ".", "class", ")", ";", "public", "static", "final", "ClassNode", "DATE_GM_CLASS_NODE", "=", "ClassHelper", ".", "make", "(", "DateGroovyMethods", ".", "class", ")", ";", "public", "static", "ClassNode", "RESOURCE_GROOVY_METHODS", ";", "public", "static", "ClassNode", "STRING_GROOVY_METHODS", ";", "public", "static", "ClassNode", "IO_GROOVY_METHODS", ";", "static", "{", "try", "{", "RESOURCE_GROOVY_METHODS", "=", "ClassHelper", ".", "make", "(", "Class", ".", "forName", "(", "\"\"", ")", ")", ";", "STRING_GROOVY_METHODS", "=", "ClassHelper", ".", "make", "(", "Class", ".", "forName", "(", "\"\"", ")", ")", ";", "IO_GROOVY_METHODS", "=", "ClassHelper", ".", "make", "(", "Class", ".", "forName", "(", "\"\"", ")", ")", ";", "}", "catch", "(", "ClassNotFoundException", "e", ")", "{", "RESOURCE_GROOVY_METHODS", "=", "null", ";", "STRING_GROOVY_METHODS", "=", "null", ";", "IO_GROOVY_METHODS", "=", "null", ";", "}", "}", "public", "static", "Set", "<", "ClassNode", ">", "ALL_DEFAULT_CATEGORIES", ";", "static", "{", "List", "<", "ClassNode", ">", "dgm_classes", "=", "new", "ArrayList", "<", "ClassNode", ">", "(", "10", ")", ";", "if", "(", "STRING_GROOVY_METHODS", "!=", "null", ")", "{", "dgm_classes", ".", "add", "(", "STRING_GROOVY_METHODS", ")", ";", "}", "if", "(", "RESOURCE_GROOVY_METHODS", "!=", "null", ")", "{", "dgm_classes", ".", "add", "(", "RESOURCE_GROOVY_METHODS", ")", ";", "}", "if", "(", "IO_GROOVY_METHODS", "!=", "null", ")", "{", "dgm_classes", ".", "add", "(", "IO_GROOVY_METHODS", ")", ";", "}", "dgm_classes", ".", "add", "(", "EGM_CLASS_NODE", ")", ";", "dgm_classes", ".", "add", "(", "PGM_CLASS_NODE", ")", ";", "dgm_classes", ".", "add", "(", "SGM_CLASS_NODE", ")", ";", "dgm_classes", ".", "add", "(", "XGM_CLASS_NODE", ")", ";", "dgm_classes", ".", "add", "(", "DATE_GM_CLASS_NODE", ")", ";", "dgm_classes", ".", "add", "(", "DGSM_CLASS_NODE", ")", ";", "dgm_classes", ".", "add", "(", "DGM_CLASS_NODE", ")", ";", "ALL_DEFAULT_CATEGORIES", "=", "Collections", ".", "unmodifiableSet", "(", "new", "LinkedHashSet", "<", "ClassNode", ">", "(", "dgm_classes", ")", ")", ";", "}", "public", "static", "final", "ClassNode", "CLASS_CLASS_NODE", "=", "ClassHelper", ".", "makeWithoutCaching", "(", "Class", ".", "class", ")", ";", "static", "{", "initializeProperties", "(", "CLASS_CLASS_NODE", ")", ";", "}", "public", "static", "final", "ClassNode", "CLASS_ARRAY_CLASS_NODE", "=", "CLASS_CLASS_NODE", ".", "makeArray", "(", ")", ";", "public", "static", "final", "ClassNode", "INTEGER_CLASS_NODE", "=", "ClassHelper", ".", "Integer_TYPE", ";", "public", "static", "final", "ClassNode", "LONG_CLASS_NODE", "=", "ClassHelper", ".", "Long_TYPE", ";", "public", "static", "final", "ClassNode", "SHORT_CLASS_NODE", "=", "ClassHelper", ".", "Short_TYPE", ";", "public", "static", "final", "ClassNode", "FLOAT_CLASS_NODE", "=", "ClassHelper", ".", "Float_TYPE", ";", "public", "static", "final", "ClassNode", "DOUBLE_CLASS_NODE", "=", "ClassHelper", ".", "Double_TYPE", ";", "public", "static", "final", "ClassNode", "BYTE_CLASS_NODE", "=", "ClassHelper", ".", "Byte_TYPE", ";", "public", "static", "final", "ClassNode", "BOOLEAN_CLASS_NODE", "=", "ClassHelper", ".", "Boolean_TYPE", ";", "public", "static", "final", "ClassNode", "CHARACTER_CLASS_NODE", "=", "ClassHelper", ".", "Character_TYPE", ";", "public", "static", "class", "VariableInfo", "{", "public", "final", "ClassNode", "type", ";", "public", "final", "ClassNode", "declaringType", ";", "public", "VariableInfo", "(", "ClassNode", "type", ",", "ClassNode", "declaringType", ")", "{", "super", "(", ")", ";", "this", ".", "type", "=", "type", ";", "this", ".", "declaringType", "=", "declaringType", ";", "}", "public", "String", "getTypeSignature", "(", ")", "{", "String", "typeName", "=", "type", ".", "getName", "(", ")", ";", "if", "(", "typeName", ".", "startsWith", "(", "\"[\"", ")", ")", "{", "return", "typeName", ";", "}", "else", "{", "return", "Signature", ".", "createTypeSignature", "(", "typeName", ",", "true", ")", ";", "}", "}", "}", "public", "static", "class", "CallAndType", "{", "public", "CallAndType", "(", "MethodCallExpression", "call", ",", "ClassNode", "declaringType", ")", "{", "this", ".", "call", "=", "call", ";", "this", ".", "declaringType", "=", "declaringType", ";", "}", "public", "final", "MethodCallExpression", "call", ";", "public", "final", "ClassNode", "declaringType", ";", "}", "private", "class", "SharedState", "{", "final", "Map", "<", "String", ",", "Object", ">", "wormhole", "=", "new", "HashMap", "<", "String", ",", "Object", ">", "(", ")", ";", "final", "Stack", "<", "CallAndType", ">", "enclosingCallStack", "=", "new", "Stack", "<", "VariableScope", ".", "CallAndType", ">", "(", ")", ";", "final", "Stack", "<", "ASTNode", ">", "nodeStack", "=", "new", "Stack", "<", "ASTNode", ">", "(", ")", ";", "boolean", "isRunMethod", ";", "}", "public", "static", "ClassNode", "NO_CATEGORY", "=", "null", ";", "private", "VariableScope", "parent", ";", "private", "SharedState", "shared", ";", "private", "ASTNode", "scopeNode", ";", "private", "Map", "<", "String", ",", "VariableInfo", ">", "nameVariableMap", "=", "new", "HashMap", "<", "String", ",", "VariableInfo", ">", "(", ")", ";", "private", "boolean", "isStaticScope", ";", "private", "final", "ClosureExpression", "enclosingClosure", ";", "private", "ClassNode", "categoryBeingDeclared", ";", "private", "int", "methodCallNumberOfArguments", "=", "-", "1", ";", "private", "boolean", "isPrimaryNode", ";", "public", "VariableScope", "(", "VariableScope", "parent", ",", "ASTNode", "enclosingNode", ",", "boolean", "isStatic", ")", "{", "this", ".", "parent", "=", "parent", ";", "this", ".", "scopeNode", "=", "enclosingNode", ";", "if", "(", "parent", "!=", "null", ")", "{", "this", ".", "shared", "=", "parent", ".", "shared", ";", "}", "else", "{", "this", ".", "shared", "=", "new", "SharedState", "(", ")", ";", "}", "if", "(", "enclosingNode", "instanceof", "MethodNode", ")", "{", "this", ".", "shared", ".", "isRunMethod", "=", "(", "(", "MethodNode", ")", "enclosingNode", ")", ".", "isScriptBody", "(", ")", ";", "}", "else", "if", "(", "enclosingNode", "instanceof", "FieldNode", "||", "enclosingNode", "instanceof", "ClassNode", ")", "{", "this", ".", "shared", ".", "isRunMethod", "=", "false", ";", "}", "this", ".", "isStaticScope", "=", "isStatic", "||", "(", "parent", "!=", "null", "&&", "parent", ".", "isStaticScope", ")", ";", "if", "(", "enclosingNode", "instanceof", "ClosureExpression", ")", "{", "this", ".", "enclosingClosure", "=", "(", "ClosureExpression", ")", "enclosingNode", ";", "}", "else", "{", "this", ".", "enclosingClosure", "=", "null", ";", "}", "}", "public", "Map", "<", "String", ",", "Object", ">", "getWormhole", "(", ")", "{", "return", "shared", ".", "wormhole", ";", "}", "public", "ASTNode", "getEnclosingNode", "(", ")", "{", "if", "(", "shared", ".", "nodeStack", ".", "size", "(", ")", ">", "1", ")", "{", "ASTNode", "current", "=", "shared", ".", "nodeStack", ".", "pop", "(", ")", ";", "ASTNode", "enclosing", "=", "shared", ".", "nodeStack", ".", "peek", "(", ")", ";", "shared", ".", "nodeStack", ".", "push", "(", "current", ")", ";", "return", "enclosing", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "void", "setPrimaryNode", "(", "boolean", "isPrimaryNode", ")", "{", "this", ".", "isPrimaryNode", "=", "isPrimaryNode", ";", "}", "public", "void", "setCurrentNode", "(", "ASTNode", "currentNode", ")", "{", "shared", ".", "nodeStack", ".", "push", "(", "currentNode", ")", ";", "}", "public", "void", "forgetCurrentNode", "(", ")", "{", "if", "(", "!", "shared", ".", "nodeStack", ".", "isEmpty", "(", ")", ")", "{", "shared", ".", "nodeStack", ".", "pop", "(", ")", ";", "}", "}", "public", "ASTNode", "getCurrentNode", "(", ")", "{", "if", "(", "!", "shared", ".", "nodeStack", ".", "isEmpty", "(", ")", ")", "{", "return", "shared", ".", "nodeStack", ".", "peek", "(", ")", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "Set", "<", "ClassNode", ">", "getCategoryNames", "(", ")", "{", "if", "(", "parent", "!=", "null", ")", "{", "Set", "<", "ClassNode", ">", "categories", "=", "parent", ".", "getCategoryNames", "(", ")", ";", "if", "(", "parent", ".", "isCategoryBeingDeclared", "(", ")", ")", "{", "categories", ".", "add", "(", "parent", ".", "categoryBeingDeclared", ")", ";", "}", "return", "categories", ";", "}", "else", "{", "return", "new", "LinkedHashSet", "<", "ClassNode", ">", "(", "ALL_DEFAULT_CATEGORIES", ")", ";", "}", "}", "private", "boolean", "isCategoryBeingDeclared", "(", ")", "{", "return", "categoryBeingDeclared", "!=", "null", ";", "}", "public", "void", "setCategoryBeingDeclared", "(", "ClassNode", "categoryBeingDeclared", ")", "{", "this", ".", "categoryBeingDeclared", "=", "categoryBeingDeclared", ";", "}", "public", "VariableInfo", "lookupName", "(", "String", "name", ")", "{", "if", "(", "\"super\"", ".", "equals", "(", "name", ")", ")", "{", "ClassNode", "type", "=", "getDelegateOrThis", "(", ")", ";", "if", "(", "type", "!=", "null", ")", "{", "ClassNode", "superType", "=", "type", ".", "getSuperClass", "(", ")", ";", "superType", "=", "superType", "==", "null", "?", "VariableScope", ".", "OBJECT_CLASS_NODE", ":", "superType", ";", "return", "new", "VariableInfo", "(", "superType", ",", "superType", ")", ";", "}", "}", "VariableInfo", "var", "=", "lookupNameInCurrentScope", "(", "name", ")", ";", "if", "(", "var", "==", "null", "&&", "parent", "!=", "null", ")", "{", "var", "=", "parent", ".", "lookupName", "(", "name", ")", ";", "}", "return", "var", ";", "}", "public", "ClassNode", "getThis", "(", ")", "{", "VariableInfo", "thiz", "=", "lookupName", "(", "\"this\"", ")", ";", "return", "thiz", "!=", "null", "?", "thiz", ".", "type", ":", "null", ";", "}", "public", "ClassNode", "getDelegate", "(", ")", "{", "VariableInfo", "delegate", "=", "lookupName", "(", "\"delegate\"", ")", ";", "return", "delegate", "!=", "null", "?", "delegate", ".", "type", ":", "null", ";", "}", "public", "VariableInfo", "getDelegateOrThisInfo", "(", ")", "{", "VariableInfo", "info", "=", "lookupName", "(", "\"delegate\"", ")", ";", "if", "(", "info", "!=", "null", ")", "{", "return", "info", ";", "}", "info", "=", "lookupName", "(", "\"this\"", ")", ";", "return", "info", ";", "}", "public", "ClassNode", "getDelegateOrThis", "(", ")", "{", "VariableInfo", "info", "=", "getDelegateOrThisInfo", "(", ")", ";", "return", "info", "!=", "null", "?", "info", ".", "type", ":", "null", ";", "}", "public", "VariableInfo", "lookupNameInCurrentScope", "(", "String", "name", ")", "{", "return", "nameVariableMap", ".", "get", "(", "name", ")", ";", "}", "public", "boolean", "isThisOrSuper", "(", "Variable", "var", ")", "{", "return", "var", ".", "getName", "(", ")", ".", "equals", "(", "\"this\"", ")", "||", "var", ".", "getName", "(", ")", ".", "equals", "(", "\"super\"", ")", ";", "}", "public", "void", "addVariable", "(", "String", "name", ",", "ClassNode", "type", ",", "ClassNode", "declaringType", ")", "{", "nameVariableMap", ".", "put", "(", "name", ",", "new", "VariableInfo", "(", "type", ",", "declaringType", "!=", "null", "?", "declaringType", ":", "OBJECT_CLASS_NODE", ")", ")", ";", "}", "public", "void", "addVariable", "(", "Variable", "var", ")", "{", "addVariable", "(", "var", ".", "getName", "(", ")", ",", "var", ".", "getType", "(", ")", ",", "var", ".", "getOriginType", "(", ")", ")", ";", "}", "public", "ModuleNode", "getEnclosingModuleNode", "(", ")", "{", "if", "(", "scopeNode", "instanceof", "ModuleNode", ")", "{", "return", "(", "ModuleNode", ")", "scopeNode", ";", "}", "else", "if", "(", "parent", "!=", "null", ")", "{", "return", "parent", ".", "getEnclosingModuleNode", "(", ")", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "ClassNode", "getEnclosingTypeDeclaration", "(", ")", "{", "if", "(", "scopeNode", "instanceof", "ClassNode", ")", "{", "return", "(", "ClassNode", ")", "scopeNode", ";", "}", "else", "if", "(", "parent", "!=", "null", ")", "{", "return", "parent", ".", "getEnclosingTypeDeclaration", "(", ")", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "FieldNode", "getEnclosingFieldDeclaration", "(", ")", "{", "if", "(", "scopeNode", "instanceof", "FieldNode", ")", "{", "return", "(", "FieldNode", ")", "scopeNode", ";", "}", "else", "if", "(", "parent", "!=", "null", ")", "{", "return", "parent", ".", "getEnclosingFieldDeclaration", "(", ")", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "MethodNode", "getEnclosingMethodDeclaration", "(", ")", "{", "if", "(", "scopeNode", "instanceof", "MethodNode", ")", "{", "return", "(", "MethodNode", ")", "scopeNode", ";", "}", "else", "if", "(", "parent", "!=", "null", ")", "{", "return", "parent", ".", "getEnclosingMethodDeclaration", "(", ")", ";", "}", "else", "{", "return", "null", ";", "}", "}", "public", "static", "ClassNode", "maybeConvertFromPrimitive", "(", "ClassNode", "type", ")", "{", "if", "(", "ClassHelper", ".", "isPrimitiveType", "(", "type", ")", ")", "{", "return", "ClassHelper", ".", "getWrapper", "(", "type", ")", ";", "}", "return", "type", ";", "}", "private", "static", "PropertyNode", "createPropertyNodeForMethodNode", "(", "MethodNode", "methodNode", ")", "{", "ClassNode", "propertyType", "=", "methodNode", ".", "getReturnType", "(", ")", ";", "String", "methodName", "=", "methodNode", ".", "getName", "(", ")", ";", "StringBuffer", "propertyName", "=", "new", "StringBuffer", "(", ")", ";", "propertyName", ".", "append", "(", "Character", ".", "toLowerCase", "(", "methodName", ".", "charAt", "(", "3", ")", ")", ")", ";", "if", "(", "methodName", ".", "length", "(", ")", ">", "4", ")", "{", "propertyName", ".", "append", "(", "methodName", ".", "substring", "(", "4", ")", ")", ";", "}", "int", "mods", "=", "methodNode", ".", "getModifiers", "(", ")", ";", "ClassNode", "declaringClass", "=", "methodNode", ".", "getDeclaringClass", "(", ")", ";", "PropertyNode", "property", "=", "new", "PropertyNode", "(", "propertyName", ".", "toString", "(", ")", ",", "mods", ",", "propertyType", ",", "declaringClass", ",", "null", ",", "null", ",", "null", ")", ";", "property", ".", "setDeclaringClass", "(", "declaringClass", ")", ";", "property", ".", "getField", "(", ")", ".", "setDeclaringClass", "(", "declaringClass", ")", ";", "return", "property", ";", "}", "private", "static", "void", "initializeProperties", "(", "ClassNode", "node", ")", "{", "for", "(", "MethodNode", "methodNode", ":", "node", ".", "getMethods", "(", ")", ")", "{", "if", "(", "AccessorSupport", ".", "isGetter", "(", "methodNode", ")", ")", "{", "node", ".", "addProperty", "(", "createPropertyNodeForMethodNode", "(", "methodNode", ")", ")", ";", "}", "}", "}", "public", "static", "boolean", "isVoidOrObject", "(", "ClassNode", "maybeVoid", ")", "{", "return", "maybeVoid", "!=", "null", "&&", "(", "maybeVoid", ".", "getName", "(", ")", ".", "equals", "(", "VOID_CLASS_NODE", ".", "getName", "(", ")", ")", "||", "maybeVoid", ".", "getName", "(", ")", ".", "equals", "(", "VOID_WRAPPER_CLASS_NODE", ".", "getName", "(", ")", ")", "||", "maybeVoid", ".", "getName", "(", ")", ".", "equals", "(", "OBJECT_CLASS_NODE", ".", "getName", "(", ")", ")", ")", ";", "}", "public", "void", "updateOrAddVariable", "(", "String", "name", ",", "ClassNode", "type", ",", "ClassNode", "declaringType", ")", "{", "if", "(", "!", "internalUpdateVariable", "(", "name", ",", "type", ",", "declaringType", ")", ")", "{", "addVariable", "(", "name", ",", "type", ",", "declaringType", ")", ";", "}", "}", "public", "boolean", "updateVariable", "(", "String", "name", ",", "ClassNode", "type", ",", "ClassNode", "declaringType", ")", "{", "return", "internalUpdateVariable", "(", "name", ",", "type", ",", "declaringType", ")", ";", "}", "private", "boolean", "internalUpdateVariable", "(", "String", "name", ",", "ClassNode", "type", ",", "ClassNode", "declaringType", ")", "{", "VariableInfo", "info", "=", "lookupNameInCurrentScope", "(", "name", ")", ";", "if", "(", "info", "!=", "null", ")", "{", "nameVariableMap", ".", "put", "(", "name", ",", "new", "VariableInfo", "(", "type", ",", "declaringType", "==", "null", "?", "info", ".", "declaringType", ":", "declaringType", ")", ")", ";", "return", "true", ";", "}", "else", "if", "(", "parent", "!=", "null", ")", "{", "return", "parent", ".", "internalUpdateVariable", "(", "name", ",", "type", ",", "declaringType", ")", ";", "}", "else", "{", "return", "false", ";", "}", "}", "public", "static", "ClassNode", "resolveTypeParameterization", "(", "GenericsMapper", "mapper", ",", "ClassNode", "typeToParameterize", ")", "{", "if", "(", "!", "mapper", ".", "hasGenerics", "(", ")", ")", "{", "return", "typeToParameterize", ";", "}", "GenericsType", "[", "]", "typesToParameterize", "=", "typeToParameterize", ".", "getGenericsTypes", "(", ")", ";", "if", "(", "typesToParameterize", "==", "null", ")", "{", "return", "typeToParameterize", ";", "}", "for", "(", "int", "i", "=", "0", ";", "i", "<", "typesToParameterize", ".", "length", ";", "i", "++", ")", "{", "GenericsType", "genericsToParameterize", "=", "typesToParameterize", "[", "i", "]", ";", "if", "(", "genericsToParameterize", "instanceof", "LazyGenericsType", ")", "{", "Util", ".", "log", "(", "new", "RuntimeException", "(", ")", ",", "\"\"", "+", "\"\"", "+", "\"\"", "+", "typeToParameterize", ")", ";", "continue", ";", "}", "resolveTypeParameterization", "(", "mapper", ",", "genericsToParameterize", ".", "getType", "(", ")", ")", ";", "String", "toParameterizeName", "=", "genericsToParameterize", ".", "getName", "(", ")", ";", "ClassNode", "resolved", "=", "mapper", ".", "findParameter", "(", "toParameterizeName", ",", "genericsToParameterize", ".", "getType", "(", ")", ")", ";", "if", "(", "typeParameterExistsInRedirected", "(", "typeToParameterize", ",", "toParameterizeName", ")", ")", "{", "Assert", ".", "isLegal", "(", "typeToParameterize", ".", "redirect", "(", ")", "!=", "typeToParameterize", ",", "\"\"", "+", "typeToParameterize", ")", ";", "typeToParameterize", ".", "getGenericsTypes", "(", ")", "[", "i", "]", ".", "setType", "(", "resolved", ")", ";", "genericsToParameterize", ".", "setName", "(", "genericsToParameterize", ".", "getType", "(", ")", ".", "getName", "(", ")", ")", ";", "genericsToParameterize", ".", "setUpperBounds", "(", "null", ")", ";", "genericsToParameterize", ".", "setLowerBound", "(", "null", ")", ";", "}", "else", "{", "typeToParameterize", "=", "resolved", ";", "break", ";", "}", "}", "return", "typeToParameterize", ";", "}", "static", "final", "public", "GenericsType", "[", "]", "NO_GENERICS", "=", "new", "GenericsType", "[", "0", "]", ";", "private", "static", "boolean", "typeParameterExistsInRedirected", "(", "ClassNode", "type", ",", "String", "toParameterizeName", ")", "{", "ClassNode", "redirect", "=", "type", ".", "redirect", "(", ")", ";", "GenericsType", "[", "]", "genericsTypes", "=", "redirect", ".", "getGenericsTypes", "(", ")", ";", "if", "(", "genericsTypes", "!=", "null", ")", "{", "return", "true", ";", "}", "return", "false", ";", "}", "public", "static", "ClassNode", "clone", "(", "ClassNode", "type", ")", "{", "return", "cloneInternal", "(", "type", ",", "0", ")", ";", "}", "public", "static", "ClassNode", "clonedMap", "(", ")", "{", "ClassNode", "clone", "=", "clone", "(", "MAP_CLASS_NODE", ")", ";", "cleanGenerics", "(", "clone", ".", "getGenericsTypes", "(", ")", "[", "0", "]", ")", ";", "cleanGenerics", "(", "clone", ".", "getGenericsTypes", "(", ")", "[", "1", "]", ")", ";", "return", "clone", ";", "}", "public", "static", "ClassNode", "clonedList", "(", ")", "{", "ClassNode", "clone", "=", "clone", "(", "LIST_CLASS_NODE", ")", ";", "cleanGenerics", "(", "clone", ".", "getGenericsTypes", "(", ")", "[", "0", "]", ")", ";", "return", "clone", ";", "}", "public", "static", "ClassNode", "clonedRange", "(", ")", "{", "ClassNode", "clone", "=", "clone", "(", "RANGE_CLASS_NODE", ")", ";", "cleanGenerics", "(", "clone", ".", "getGenericsTypes", "(", ")", "[", "0", "]", ")", ";", "return", "clone", ";", "}", "public", "static", "ClassNode", "clonedTuple", "(", ")", "{", "return", "clonedList", "(", ")", ";", "}", "private", "static", "void", "cleanGenerics", "(", "GenericsType", "gt", ")", "{", "gt", ".", "getType", "(", ")", ".", "setGenericsTypes", "(", "null", ")", ";", "gt", ".", "setName", "(", "\"\"", ")", ";", "gt", ".", "setPlaceholder", "(", "false", ")", ";", "gt", ".", "setWildcard", "(", "false", ")", ";", "gt", ".", "setResolved", "(", "true", ")", ";", "gt", ".", "setUpperBounds", "(", "null", ")", ";", "gt", ".", "setLowerBound", "(", "null", ")", ";", "}", "private", "static", "ClassNode", "cloneInternal", "(", "ClassNode", "type", ",", "int", "depth", ")", "{", "if", "(", "type", "==", "null", ")", "{", "return", "type", ";", "}", "ClassNode", "newType", ";", "newType", "=", "type", ".", "getPlainNodeReference", "(", ")", ";", "newType", ".", "setRedirect", "(", "type", ".", "redirect", "(", ")", ")", ";", "ClassNode", "[", "]", "origIFaces", "=", "type", ".", "getInterfaces", "(", ")", ";", "if", "(", "origIFaces", "!=", "null", ")", "{", "ClassNode", "[", "]", "newIFaces", "=", "new", "ClassNode", "[", "origIFaces", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "newIFaces", ".", "length", ";", "i", "++", ")", "{", "newIFaces", "[", "i", "]", "=", "origIFaces", "[", "i", "]", ";", "}", "newType", ".", "setInterfaces", "(", "newIFaces", ")", ";", "}", "newType", ".", "setSourcePosition", "(", "type", ")", ";", "if", "(", "depth", ">", "10", ")", "{", "return", "newType", ";", "}", "GenericsType", "[", "]", "origgts", "=", "type", ".", "getGenericsTypes", "(", ")", ";", "if", "(", "origgts", "!=", "null", ")", "{", "GenericsType", "[", "]", "newgts", "=", "new", "GenericsType", "[", "origgts", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "origgts", ".", "length", ";", "i", "++", ")", "{", "newgts", "[", "i", "]", "=", "clone", "(", "origgts", "[", "i", "]", ",", "depth", ")", ";", "}", "newType", ".", "setGenericsTypes", "(", "newgts", ")", ";", "}", "return", "newType", ";", "}", "private", "static", "GenericsType", "clone", "(", "GenericsType", "origgt", ",", "int", "depth", ")", "{", "GenericsType", "newgt", "=", "new", "GenericsType", "(", ")", ";", "newgt", ".", "setType", "(", "cloneInternal", "(", "origgt", ".", "getType", "(", ")", ",", "depth", "+", "1", ")", ")", ";", "newgt", ".", "setLowerBound", "(", "cloneInternal", "(", "origgt", ".", "getLowerBound", "(", ")", ",", "depth", "+", "1", ")", ")", ";", "ClassNode", "[", "]", "oldUpperBounds", "=", "origgt", ".", "getUpperBounds", "(", ")", ";", "if", "(", "oldUpperBounds", "!=", "null", ")", "{", "ClassNode", "[", "]", "newUpperBounds", "=", "new", "ClassNode", "[", "oldUpperBounds", ".", "length", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "newUpperBounds", ".", "length", ";", "i", "++", ")", "{", "if", "(", "oldUpperBounds", "[", "i", "]", ".", "getName", "(", ")", ".", "equals", "(", "newgt", ".", "getType", "(", ")", ".", "getName", "(", ")", ")", ")", "{", "newUpperBounds", "[", "i", "]", "=", "VariableScope", ".", "OBJECT_CLASS_NODE", ";", "}", "else", "{", "newUpperBounds", "[", "i", "]", "=", "cloneInternal", "(", "oldUpperBounds", "[", "i", "]", ",", "depth", "+", "1", ")", ";", "}", "}", "newgt", ".", "setUpperBounds", "(", "newUpperBounds", ")", ";", "}", "newgt", ".", "setName", "(", "origgt", ".", "getName", "(", ")", ")", ";", "newgt", ".", "setPlaceholder", "(", "origgt", ".", "isPlaceholder", "(", ")", ")", ";", "newgt", ".", "setWildcard", "(", "origgt", ".", "isWildcard", "(", ")", ")", ";", "newgt", ".", "setResolved", "(", "origgt", ".", "isResolved", "(", ")", ")", ";", "newgt", ".", "setSourcePosition", "(", "origgt", ")", ";", "return", "newgt", ";", "}", "public", "boolean", "isStatic", "(", ")", "{", "return", "isStaticScope", ";", "}", "public", "boolean", "isPrimaryNode", "(", ")", "{", "return", "isPrimaryNode", ";", "}", "public", "ClosureExpression", "getEnclosingClosure", "(", ")", "{", "if", "(", "enclosingClosure", "==", "null", "&&", "parent", "!=", "null", ")", "{", "return", "parent", ".", "getEnclosingClosure", "(", ")", ";", "}", "return", "enclosingClosure", ";", "}", "public", "List", "<", "CallAndType", ">", "getAllEnclosingMethodCallExpressions", "(", ")", "{", "return", "shared", ".", "enclosingCallStack", ";", "}", "public", "CallAndType", "getEnclosingMethodCallExpression", "(", ")", "{", "if", "(", "shared", ".", "enclosingCallStack", ".", "isEmpty", "(", ")", ")", "{", "return", "null", ";", "}", "else", "{", "return", "shared", ".", "enclosingCallStack", ".", "peek", "(", ")", ";", "}", "}", "public", "void", "addEnclosingMethodCall", "(", "CallAndType", "enclosingMethodCall", ")", "{", "shared", ".", "enclosingCallStack", ".", "push", "(", "enclosingMethodCall", ")", ";", "}", "public", "void", "forgetEnclosingMethodCall", "(", ")", "{", "shared", ".", "enclosingCallStack", ".", "pop", "(", ")", ";", "}", "public", "boolean", "isTopLevel", "(", ")", "{", "return", "parent", "==", "null", ";", "}", "public", "boolean", "containsInThisScope", "(", "String", "name", ")", "{", "return", "nameVariableMap", ".", "containsKey", "(", "name", ")", ";", "}", "int", "getMethodCallNumberOfArguments", "(", ")", "{", "return", "methodCallNumberOfArguments", ";", "}", "void", "setMethodCallNumberOfArguments", "(", "int", "methodCallNumberOfArguments", ")", "{", "this", ".", "methodCallNumberOfArguments", "=", "methodCallNumberOfArguments", ";", "}", "public", "boolean", "isMethodCall", "(", ")", "{", "return", "methodCallNumberOfArguments", ">=", "0", ";", "}", "public", "Iterator", "<", "Map", ".", "Entry", "<", "String", ",", "VariableInfo", ">", ">", "variablesIterator", "(", ")", "{", "return", "new", "Iterator", "<", "Map", ".", "Entry", "<", "String", ",", "VariableInfo", ">", ">", "(", ")", "{", "VariableScope", "currentScope", "=", "VariableScope", ".", "this", ";", "Iterator", "<", "Map", ".", "Entry", "<", "String", ",", "VariableInfo", ">", ">", "currentIter", "=", "currentScope", ".", "nameVariableMap", ".", "entrySet", "(", ")", ".", "iterator", "(", ")", ";", "public", "boolean", "hasNext", "(", ")", "{", "if", "(", "currentIter", "==", "null", ")", "{", "return", "false", ";", "}", "if", "(", "!", "currentIter", ".", "hasNext", "(", ")", ")", "{", "currentScope", "=", "currentScope", ".", "parent", ";", "currentIter", "=", "currentScope", "==", "null", "?", "null", ":", "currentScope", ".", "nameVariableMap", ".", "entrySet", "(", ")", ".", "iterator", "(", ")", ";", "}", "return", "currentIter", "!=", "null", "&&", "currentIter", ".", "hasNext", "(", ")", ";", "}", "public", "Entry", "<", "String", ",", "VariableInfo", ">", "next", "(", ")", "{", "if", "(", "!", "currentIter", ".", "hasNext", "(", ")", ")", "{", "throw", "new", "NoSuchElementException", "(", ")", ";", "}", "return", "currentIter", ".", "next", "(", ")", ";", "}", "public", "void", "remove", "(", ")", "{", "throw", "new", "UnsupportedOperationException", "(", ")", ";", "}", "}", ";", "}", "public", "static", "void", "findAllInterfaces", "(", "ClassNode", "type", ",", "LinkedHashSet", "<", "ClassNode", ">", "allInterfaces", ",", "boolean", "useResolved", ")", "{", "if", "(", "!", "useResolved", ")", "{", "type", "=", "type", ".", "redirect", "(", ")", ";", "}", "if", "(", "!", "type", ".", "isInterface", "(", ")", "||", "!", "allInterfaces", ".", "contains", "(", "type", ")", ")", "{", "if", "(", "type", ".", "isInterface", "(", ")", ")", "{", "allInterfaces", ".", "add", "(", "type", ")", ";", "}", "ClassNode", "[", "]", "interfaces", ";", "if", "(", "useResolved", ")", "{", "interfaces", "=", "type", ".", "getUnresolvedInterfaces", "(", ")", ";", "}", "else", "{", "interfaces", "=", "type", ".", "getInterfaces", "(", ")", ";", "}", "if", "(", "interfaces", "!=", "null", ")", "{", "for", "(", "ClassNode", "superInterface", ":", "interfaces", ")", "{", "findAllInterfaces", "(", "superInterface", ",", "allInterfaces", ",", "useResolved", ")", ";", "}", "}", "}", "}", "public", "static", "void", "createTypeHierarchy", "(", "ClassNode", "type", ",", "LinkedHashSet", "<", "ClassNode", ">", "allClasses", ",", "boolean", "useResolved", ")", "{", "if", "(", "!", "useResolved", ")", "{", "type", "=", "type", ".", "redirect", "(", ")", ";", "}", "if", "(", "!", "allClasses", ".", "contains", "(", "type", ")", ")", "{", "if", "(", "!", "type", ".", "isInterface", "(", ")", ")", "{", "allClasses", ".", "add", "(", "type", ")", ";", "ClassNode", "superClass", ";", "if", "(", "useResolved", ")", "{", "superClass", "=", "type", ".", "getUnresolvedSuperClass", "(", ")", ";", "}", "else", "{", "superClass", "=", "type", ".", "getSuperClass", "(", ")", ";", "}", "if", "(", "superClass", "!=", "null", ")", "{", "createTypeHierarchy", "(", "superClass", ",", "allClasses", ",", "useResolved", ")", ";", "}", "}", "findAllInterfaces", "(", "type", ",", "allClasses", ",", "useResolved", ")", ";", "}", "}", "public", "static", "ClassNode", "extractElementType", "(", "ClassNode", "collectionType", ")", "{", "if", "(", "collectionType", ".", "isArray", "(", ")", ")", "{", "return", "collectionType", ".", "getComponentType", "(", ")", ";", "}", "MethodNode", "iterator", "=", "collectionType", ".", "getMethod", "(", "\"iterator\"", ",", "new", "Parameter", "[", "0", "]", ")", ";", "ClassNode", "typeToResolve", "=", "null", ";", "if", "(", "iterator", "==", "null", "&&", "collectionType", ".", "isInterface", "(", ")", ")", "{", "if", "(", "collectionType", ".", "implementsInterface", "(", "VariableScope", ".", "LIST_CLASS_NODE", ")", "&&", "collectionType", ".", "getGenericsTypes", "(", ")", "!=", "null", "&&", "collectionType", ".", "getGenericsTypes", "(", ")", ".", "length", "==", "1", ")", "{", "typeToResolve", "=", "collectionType", ";", "}", "else", "if", "(", "collectionType", ".", "declaresInterface", "(", "ITERATOR_CLASS", ")", "||", "collectionType", ".", "equals", "(", "ITERATOR_CLASS", ")", "||", "collectionType", ".", "declaresInterface", "(", "ENUMERATION_CLASS", ")", "||", "collectionType", ".", "equals", "(", "ENUMERATION_CLASS", ")", ")", "{", "typeToResolve", "=", "collectionType", ";", "}", "else", "if", "(", "collectionType", ".", "declaresInterface", "(", "MAP_CLASS_NODE", ")", "||", "collectionType", ".", "equals", "(", "MAP_CLASS_NODE", ")", ")", "{", "MethodNode", "entrySetMethod", "=", "collectionType", ".", "getMethod", "(", "\"entrySet\"", ",", "new", "Parameter", "[", "0", "]", ")", ";", "if", "(", "entrySetMethod", "!=", "null", ")", "{", "typeToResolve", "=", "entrySetMethod", ".", "getReturnType", "(", ")", ";", "}", "}", "}", "else", "if", "(", "iterator", "!=", "null", ")", "{", "typeToResolve", "=", "iterator", ".", "getReturnType", "(", ")", ";", "}", "if", "(", "typeToResolve", "!=", "null", ")", "{", "typeToResolve", "=", "clone", "(", "typeToResolve", ")", ";", "ClassNode", "unresolvedCollectionType", "=", "collectionType", ".", "redirect", "(", ")", ";", "GenericsMapper", "mapper", "=", "GenericsMapper", ".", "gatherGenerics", "(", "collectionType", ",", "unresolvedCollectionType", ")", ";", "ClassNode", "resolved", "=", "resolveTypeParameterization", "(", "mapper", ",", "typeToResolve", ")", ";", "GenericsType", "[", "]", "resolvedReturnGenerics", "=", "resolved", ".", "getGenericsTypes", "(", ")", ";", "if", "(", "resolvedReturnGenerics", "!=", "null", "&&", "resolvedReturnGenerics", ".", "length", ">", "0", ")", "{", "return", "resolvedReturnGenerics", "[", "0", "]", ".", "getType", "(", ")", ";", "}", "}", "if", "(", "collectionType", ".", "declaresInterface", "(", "INPUT_STREAM_CLASS", ")", "||", "collectionType", ".", "declaresInterface", "(", "DATA_INPUT_STREAM_CLASS", ")", "||", "collectionType", ".", "equals", "(", "INPUT_STREAM_CLASS", ")", "||", "collectionType", ".", "equals", "(", "DATA_INPUT_STREAM_CLASS", ")", ")", "{", "return", "BYTE_CLASS_NODE", ";", "}", "return", "collectionType", ";", "}", "public", "boolean", "inScriptRunMethod", "(", ")", "{", "return", "shared", ".", "isRunMethod", ";", "}", "}", "</s>" ]