@Override protected void updateRecoveryState() { /* expose parser state to recovery state */ this.currentElement.updateFromParserState(); /* may be able to retrieve completionNode as an orphan, and then attach it */ selectionIdentifierCheck(); attachOrphanCompletionNode(); // if an assist node has been found and a recovered element exists, // mark enclosing blocks as to be preserved if (this.assistNode != null && this.currentElement != null) { this.currentElement.preserveEnclosingBlocks(); } /* check and update recovered state based on current token, this action is also performed when shifting token after recovery got activated once. */ recoveryTokenCheck(); } @Override
protected void updateRecoveryState() { /* expose parser state to recovery state */ this.currentElement.updateFromParserState(); /* may be able to retrieve completionNode as an orphan, and then attach it */ selectionIdentifierCheck(); attachOrphanCompletionNode(); // if an assist node has been found and a recovered element exists, // mark enclosing blocks as to be preserved if (this.assistNode != null && this.currentElement != null) { this.currentElement.preserveEnclosingBlocks(); } /* check and update recovered state based on current token, this action is also performed when shifting token after recovery got activated once. */ recoveryTokenCheck(); } protected Argument typeElidedArgument() {
protected void updateRecoveryState() { /* expose parser state to recovery state */ this.currentElement.updateFromParserState(); /* may be able to retrieve completionNode as an orphan, and then attach it */ selectionIdentifierCheck(); attachOrphanCompletionNode(); // if an assist node has been found and a recovered element exists, // mark enclosing blocks as to be preserved if (this.assistNode != null && this.currentElement != null) { this.currentElement.preserveEnclosingBlocks(); } /* check and update recovered state based on current token, this action is also performed when shifting token after recovery got activated once. */ recoveryTokenCheck(); } protected Argument typeElidedArgument() {
protected boolean resumeAfterRecovery() { /* if reached assist node inside method body, but still inside nested type, should continue in diet mode until the end of the method body */ if (this.assistNode != null && !(this.referenceContext instanceof CompilationUnitDeclaration)){ this.currentElement.preserveEnclosingBlocks(); if (this.currentElement.enclosingType() == null) { if(!(this.currentElement instanceof RecoveredType)) { resetStacks(); return false; } RecoveredType recoveredType = (RecoveredType)this.currentElement; if(recoveredType.typeDeclaration != null && recoveredType.typeDeclaration.allocation == this.assistNode){ resetStacks(); return false; } } } return super.resumeAfterRecovery(); }
protected void updateRecoveryState() { /* expose parser state to recovery state */ this.currentElement.updateFromParserState(); /* may be able to retrieve completionNode as an orphan, and then attach it */ selectionIdentifierCheck(); attachOrphanCompletionNode(); // if an assist node has been found and a recovered element exists, // mark enclosing blocks as to be preserved if (this.assistNode != null && this.currentElement != null) { this.currentElement.preserveEnclosingBlocks(); } /* check and update recovered state based on current token, this action is also performed when shifting token after recovery got activated once. */ recoveryTokenCheck(); }
protected void updateRecoveryState() { /* expose parser state to recovery state */ this.currentElement.updateFromParserState(); /* may be able to retrieve completionNode as an orphan, and then attach it */ selectionIdentifierCheck(); attachOrphanCompletionNode(); // if an assist node has been found and a recovered element exists, // mark enclosing blocks as to be preserved if (this.assistNode != null && this.currentElement != null) { this.currentElement.preserveEnclosingBlocks(); } /* check and update recovered state based on current token, this action is also performed when shifting token after recovery got activated once. */ recoveryTokenCheck(); } protected Argument typeElidedArgument() {
protected void updateRecoveryState() { /* expose parser state to recovery state */ this.currentElement.updateFromParserState(); /* may be able to retrieve completionNode as an orphan, and then attach it */ selectionIdentifierCheck(); attachOrphanCompletionNode(); // if an assist node has been found and a recovered element exists, // mark enclosing blocks as to be preserved if (this.assistNode != null && this.currentElement != null) { this.currentElement.preserveEnclosingBlocks(); } /* check and update recovered state based on current token, this action is also performed when shifting token after recovery got activated once. */ recoveryTokenCheck(); } protected Argument typeElidedArgument() {
protected void updateRecoveryState() { /* expose parser state to recovery state */ this.currentElement.updateFromParserState(); /* may be able to retrieve completionNode as an orphan, and then attach it */ completionIdentifierCheck(); attachOrphanCompletionNode(); // if an assist node has been found and a recovered element exists, // mark enclosing blocks as to be preserved if (this.assistNode != null && this.currentElement != null) { this.currentElement.preserveEnclosingBlocks(); } /* check and update recovered state based on current token, this action is also performed when shifting token after recovery got activated once. */ recoveryTokenCheck(); recoveryExitFromVariable(); }
protected int resumeAfterRecovery() { /* if reached assist node inside method body, but still inside nested type, should continue in diet mode until the end of the method body */ if (this.assistNode != null && !(this.referenceContext instanceof CompilationUnitDeclaration)){ this.currentElement.preserveEnclosingBlocks(); if (requireExtendedRecovery()) { if (this.unstackedAct != ERROR_ACTION) { return RESUME; } return super.resumeAfterRecovery(); } if (this.currentElement.enclosingType() == null) { if (!(this.currentElement instanceof RecoveredType)) { resetStacks(); return HALT; } RecoveredType recoveredType = (RecoveredType) this.currentElement; if (recoveredType.typeDeclaration != null && recoveredType.typeDeclaration.allocation == this.assistNode) { resetStacks(); return HALT; } } } return super.resumeAfterRecovery(); }
protected int resumeAfterRecovery() { /* if reached assist node inside method body, but still inside nested type, should continue in diet mode until the end of the method body */ if (this.assistNode != null && !(this.referenceContext instanceof CompilationUnitDeclaration)){ this.currentElement.preserveEnclosingBlocks(); if (requireExtendedRecovery()) { if (this.unstackedAct != ERROR_ACTION) { return RESUME; } return super.resumeAfterRecovery(); } if (this.currentElement.enclosingType() == null) { if (!(this.currentElement instanceof RecoveredType)) { resetStacks(); return HALT; } RecoveredType recoveredType = (RecoveredType) this.currentElement; if (recoveredType.typeDeclaration != null && recoveredType.typeDeclaration.allocation == this.assistNode) { resetStacks(); return HALT; } } } return super.resumeAfterRecovery(); }
protected int resumeAfterRecovery() { /* if reached assist node inside method body, but still inside nested type, should continue in diet mode until the end of the method body */ if (this.assistNode != null && !(this.referenceContext instanceof CompilationUnitDeclaration)){ this.currentElement.preserveEnclosingBlocks(); if (requireExtendedRecovery()) { if (this.unstackedAct != ERROR_ACTION) { return RESUME; } return super.resumeAfterRecovery(); } if (this.currentElement.enclosingType() == null) { if (!(this.currentElement instanceof RecoveredType)) { resetStacks(); return HALT; } RecoveredType recoveredType = (RecoveredType) this.currentElement; if (recoveredType.typeDeclaration != null && recoveredType.typeDeclaration.allocation == this.assistNode) { resetStacks(); return HALT; } } } return super.resumeAfterRecovery(); }
@Override protected int resumeAfterRecovery() { /* if reached assist node inside method body, but still inside nested type, should continue in diet mode until the end of the method body */ if (this.assistNode != null && !(this.referenceContext instanceof CompilationUnitDeclaration)){ this.currentElement.preserveEnclosingBlocks(); if (requireExtendedRecovery()) { if (this.unstackedAct != ERROR_ACTION) { return RESUME; } return super.resumeAfterRecovery(); } if (this.currentElement.enclosingType() == null) { if (!(this.currentElement instanceof RecoveredType)) { resetStacks(); return HALT; } RecoveredType recoveredType = (RecoveredType) this.currentElement; if (recoveredType.typeDeclaration != null && recoveredType.typeDeclaration.allocation == this.assistNode) { resetStacks(); return HALT; } } } return super.resumeAfterRecovery(); }
protected int resumeAfterRecovery() { /* if reached assist node inside method body, but still inside nested type, should continue in diet mode until the end of the method body */ if (this.assistNode != null && !(this.referenceContext instanceof CompilationUnitDeclaration)){ this.currentElement.preserveEnclosingBlocks(); if (requireExtendedRecovery()) { if (this.unstackedAct != ERROR_ACTION) { return RESUME; } return super.resumeAfterRecovery(); } if (this.currentElement.enclosingType() == null) { if (!(this.currentElement instanceof RecoveredType)) { resetStacks(); return HALT; } RecoveredType recoveredType = (RecoveredType) this.currentElement; if (recoveredType.typeDeclaration != null && recoveredType.typeDeclaration.allocation == this.assistNode) { resetStacks(); return HALT; } } } return super.resumeAfterRecovery(); }
this.currentElement.preserveEnclosingBlocks();
this.currentElement.preserveEnclosingBlocks();
this.currentElement.preserveEnclosingBlocks();
this.currentElement.preserveEnclosingBlocks();
this.currentElement.preserveEnclosingBlocks();