nescemitter.java
来自「plugin for eclipse」· Java 代码 · 共 2,918 行 · 第 1/5 页
JAVA
2,918 行
print( p );
}
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
catch (RecognitionException ex) {
if (inputState.guessing==0) {
reportError(ex);
if (_t!=null) {_t = _t.getNextSibling();}
} else {
throw ex;
}
}
_retTree = _t;
}
public final void functionStorageClassSpecifier(AST _t) throws RecognitionException {
TNode functionStorageClassSpecifier_AST_in = (_t == ASTNULL) ? null : (TNode)_t;
TNode a = null;
TNode b = null;
TNode c = null;
TNode d = null;
TNode e = null;
TNode f = null;
TNode g = null;
TNode h = null;
try { // for error handling
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LITERAL_extern:
{
a = (TNode)_t;
match(_t,LITERAL_extern);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( a );
}
break;
}
case LITERAL_static:
{
b = (TNode)_t;
match(_t,LITERAL_static);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( b );
}
break;
}
case LITERAL_inline:
{
c = (TNode)_t;
match(_t,LITERAL_inline);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( c );
}
break;
}
case LITERAL_async:
{
d = (TNode)_t;
match(_t,LITERAL_async);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( d );
}
break;
}
case LITERAL_default:
{
e = (TNode)_t;
match(_t,LITERAL_default);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( e );
}
break;
}
case LITERAL_command:
{
f = (TNode)_t;
match(_t,LITERAL_command);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( f );
}
break;
}
case LITERAL_event:
{
g = (TNode)_t;
match(_t,LITERAL_event);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( g );
}
break;
}
case LITERAL_task:
{
h = (TNode)_t;
match(_t,LITERAL_task);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( h );
}
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
catch (RecognitionException ex) {
if (inputState.guessing==0) {
reportError(ex);
if (_t!=null) {_t = _t.getNextSibling();}
} else {
throw ex;
}
}
_retTree = _t;
}
public final void structSpecifier(AST _t) throws RecognitionException {
TNode structSpecifier_AST_in = (_t == ASTNULL) ? null : (TNode)_t;
TNode a = null;
try { // for error handling
AST __t1126 = _t;
a = _t==ASTNULL ? null :(TNode)_t;
match(_t,LITERAL_struct);
_t = _t.getFirstChild();
if ( inputState.guessing==0 ) {
print( a );
}
structOrUnionBody(_t);
_t = _retTree;
_t = __t1126;
_t = _t.getNextSibling();
}
catch (RecognitionException ex) {
if (inputState.guessing==0) {
reportError(ex);
if (_t!=null) {_t = _t.getNextSibling();}
} else {
throw ex;
}
}
_retTree = _t;
}
public final void attributeDecl(AST _t) throws RecognitionException {
TNode attributeDecl_AST_in = (_t == ASTNULL) ? null : (TNode)_t;
TNode a = null;
TNode b = null;
TNode n = null;
TNode lp = null;
TNode rp = null;
try { // for error handling
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LITERAL___attribute:
{
AST __t1163 = _t;
a = _t==ASTNULL ? null :(TNode)_t;
match(_t,LITERAL___attribute);
_t = _t.getFirstChild();
if ( inputState.guessing==0 ) {
print( a );
}
{
_loop1165:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= LITERAL_typedef && _t.getType() <= NConnectionList))) {
b = (TNode)_t;
if ( _t==null ) throw new MismatchedTokenException();
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( b );
}
}
else {
break _loop1165;
}
} while (true);
}
_t = __t1163;
_t = _t.getNextSibling();
break;
}
case NAsmAttribute:
{
AST __t1166 = _t;
n = _t==ASTNULL ? null :(TNode)_t;
match(_t,NAsmAttribute);
_t = _t.getFirstChild();
if ( inputState.guessing==0 ) {
print( n );
}
lp = (TNode)_t;
match(_t,LPAREN);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( lp );
}
expr(_t);
_t = _retTree;
if ( inputState.guessing==0 ) {
print( ")" );
}
rp = (TNode)_t;
match(_t,RPAREN);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( rp );
}
_t = __t1166;
_t = _t.getNextSibling();
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
catch (RecognitionException ex) {
if (inputState.guessing==0) {
reportError(ex);
if (_t!=null) {_t = _t.getNextSibling();}
} else {
throw ex;
}
}
_retTree = _t;
}
public final void unionSpecifier(AST _t) throws RecognitionException {
TNode unionSpecifier_AST_in = (_t == ASTNULL) ? null : (TNode)_t;
TNode a = null;
try { // for error handling
AST __t1128 = _t;
a = _t==ASTNULL ? null :(TNode)_t;
match(_t,LITERAL_union);
_t = _t.getFirstChild();
if ( inputState.guessing==0 ) {
print( a );
}
structOrUnionBody(_t);
_t = _retTree;
_t = __t1128;
_t = _t.getNextSibling();
}
catch (RecognitionException ex) {
if (inputState.guessing==0) {
reportError(ex);
if (_t!=null) {_t = _t.getNextSibling();}
} else {
throw ex;
}
}
_retTree = _t;
}
public final void enumSpecifier(AST _t) throws RecognitionException {
TNode enumSpecifier_AST_in = (_t == ASTNULL) ? null : (TNode)_t;
TNode a = null;
TNode i = null;
TNode lc = null;
TNode rc = null;
try { // for error handling
AST __t1152 = _t;
a = _t==ASTNULL ? null :(TNode)_t;
match(_t,LITERAL_enum);
_t = _t.getFirstChild();
if ( inputState.guessing==0 ) {
print( a );
}
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case ID:
{
i = (TNode)_t;
match(_t,ID);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( i );
}
break;
}
case 3:
case LCURLY:
case NAsmAttribute:
case LITERAL___attribute:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LCURLY:
{
lc = (TNode)_t;
match(_t,LCURLY);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( lc ); tabs++;
}
enumList(_t);
_t = _retTree;
rc = (TNode)_t;
match(_t,RCURLY);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
tabs--; print( rc );
}
break;
}
case 3:
case NAsmAttribute:
case LITERAL___attribute:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
{
_loop1156:
do {
if (_t==null) _t=ASTNULL;
if ((_t.getType()==NAsmAttribute||_t.getType()==LITERAL___attribute)) {
attributeDecl(_t);
_t = _retTree;
}
else {
break _loop1156;
}
} while (true);
}
_t = __t1152;
_t = _t.getNextSibling();
}
catch (RecognitionException ex) {
if (inputState.guessing==0) {
reportError(ex);
if (_t!=null) {_t = _t.getNextSibling();}
} else {
throw ex;
}
}
_retTree = _t;
}
public final void typedefName(AST _t) throws RecognitionException {
TNode typedefName_AST_in = (_t == ASTNULL) ? null : (TNode)_t;
TNode i = null;
try { // for error handling
AST __t1124 = _t;
TNode tmp8_AST_in = (TNode)_t;
match(_t,NTypedefName);
_t = _t.getFirstChild();
i = (TNode)_t;
match(_t,ID);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( i );
}
_t = __t1124;
_t = _t.getNextSibling();
}
catch (RecognitionException ex) {
if (inputState.guessing==0) {
reportError(ex);
if (_t!=null) {_t = _t.getNextSibling();}
} else {
throw ex;
}
}
_retTree = _t;
}
public final void typeName(AST _t) throws RecognitionException {
TNode typeName_AST_in = (_t == ASTNULL) ? null : (TNode)_t;
try { // for error handling
specifierQualifierList(_t);
_t = _retTree;
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case NNonemptyAbstractDeclarator:
{
nonemptyAbstractDeclarator(_t);
_t = _retTree;
break;
}
case RPAREN:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
}
catch (RecognitionException ex) {
if (inputState.guessing==0) {
reportError(ex);
if (_t!=null) {_t = _t.getNextSibling();}
} else {
throw ex;
}
}
_retTree = _t;
}
public final void structOrUnionBody(AST _t) throws RecognitionException {
TNode structOrUnionBody_AST_in = (_t == ASTNULL) ? null : (TNode)_t;
TNode i1 = null;
TNode lc1 = null;
TNode rc1 = null;
TNode lc2 = null;
TNode rc2 = null;
TNode i2 = null;
try { // for error handling
{
boolean synPredMatched1132 = false;
if (((_t.getType()==ID))) {
AST __t1132 = _t;
synPredMatched1132 = true;
inputState.guessing++;
try {
{
TNode tmp9_AST_in = (TNode)_t;
match(_t,ID);
_t = _t.getNextSibling();
TNode tmp10_AST_in = (TNode)_t;
match(_t,LCURLY);
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched1132 = false;
}
_t = __t1132;
inputState.guessing--;
}
if ( synPredMatched1132 ) {
i1 = (TNode)_t;
match(_t,ID);
_t = _t.getNextSibling();
lc1 = (TNode)_t;
match(_t,LCURLY);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( i1 ); print ( "{" ); tabs++;
}
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LITERAL_volatile:
case LITERAL_struct:
case LITERAL_union:
case LITERAL_enum:
case LITERAL_const:
case LITERAL_void:
case LITERAL_char:
case LITERAL_short:
case LITERAL_int:
case LITERAL_long:
case LITERAL_float:
case LITERAL_double:
case LITERAL_signed:
case LITERAL_unsigned:
case NTypedefName:
case LITERAL_typeof:
case LITERAL___complex:
{
structDeclarationList(_t);
_t = _retTree;
break;
}
case RCURLY:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
rc1 = (TNode)_t;
match(_t,RCURLY);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
tabs--; print( rc1 );
}
}
else if ((_t.getType()==LCURLY)) {
lc2 = (TNode)_t;
match(_t,LCURLY);
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
print( "{" ); tabs++;
}
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LITERAL_volatile:
case LITERAL_struct:
case LITERAL_union:
case LITERAL_enum:
case LITERAL_const:
case LITERAL_void:
case LITERAL_char:
case LITERAL_short:
case LITERAL_int:
case LITERAL_long:
case LITERAL_float:
case LITERAL_double:
case LITERAL_signed:
case LITERAL_unsigned:
case NTypedefName:
case LITERAL_typeof:
case LITERAL___complex:
{
structDeclarationList(_t);
_t = _retTree;
break;
}
case RCURLY:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
rc2 = (TNode)_t;
match(_t,RCURLY);
_t = _t.getNextS
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?