mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-08 16:55:38 +02:00
Cosmetics.
Change-Id: Idbdc12de9dc54acbb0e5da1c86260ad740dd895f
This commit is contained in:
parent
9f7fd16f22
commit
58543c6245
4 changed files with 23 additions and 26 deletions
|
@ -6,7 +6,7 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* John Camelon (IBM Rational Software) - Initial API and implementation
|
||||
* John Camelon (IBM Rational Software) - Initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.core.dom.ast.c;
|
||||
|
||||
|
@ -20,7 +20,6 @@ import org.eclipse.cdt.core.dom.ast.IASTNamedTypeSpecifier;
|
|||
* @noimplement This interface is not intended to be implemented by clients.
|
||||
*/
|
||||
public interface ICASTTypedefNameSpecifier extends IASTNamedTypeSpecifier, ICASTDeclSpecifier {
|
||||
|
||||
/**
|
||||
* @since 5.1
|
||||
*/
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* John Camelon (IBM) - Initial API and implementation
|
||||
* John Camelon (IBM) - Initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.core.dom.ast.cpp;
|
||||
|
||||
|
@ -19,9 +19,7 @@ import org.eclipse.cdt.core.dom.ast.IASTNamedTypeSpecifier;
|
|||
* @noextend This interface is not intended to be extended by clients.
|
||||
* @noimplement This interface is not intended to be implemented by clients.
|
||||
*/
|
||||
public interface ICPPASTNamedTypeSpecifier extends IASTNamedTypeSpecifier,
|
||||
ICPPASTDeclSpecifier {
|
||||
|
||||
public interface ICPPASTNamedTypeSpecifier extends IASTNamedTypeSpecifier, ICPPASTDeclSpecifier {
|
||||
/**
|
||||
* Was typename token consumed?
|
||||
*
|
||||
|
@ -48,5 +46,4 @@ public interface ICPPASTNamedTypeSpecifier extends IASTNamedTypeSpecifier,
|
|||
*/
|
||||
@Override
|
||||
public ICPPASTNamedTypeSpecifier copy(CopyStyle style);
|
||||
|
||||
}
|
||||
|
|
|
@ -24,9 +24,8 @@ import org.eclipse.cdt.core.parser.util.ArrayUtil;
|
|||
/**
|
||||
* @author jcamelon
|
||||
*/
|
||||
public class CASTTypedefNameSpecifier extends CASTBaseDeclSpecifier implements
|
||||
ICASTTypedefNameSpecifier, IASTCompletionContext {
|
||||
|
||||
public class CASTTypedefNameSpecifier extends CASTBaseDeclSpecifier
|
||||
implements ICASTTypedefNameSpecifier, IASTCompletionContext {
|
||||
private IASTName name;
|
||||
|
||||
public CASTTypedefNameSpecifier() {
|
||||
|
@ -64,23 +63,24 @@ public class CASTTypedefNameSpecifier extends CASTBaseDeclSpecifier implements
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean accept( ASTVisitor action ){
|
||||
if( action.shouldVisitDeclSpecifiers ){
|
||||
switch( action.visit( this ) ){
|
||||
case ASTVisitor.PROCESS_ABORT : return false;
|
||||
case ASTVisitor.PROCESS_SKIP : return true;
|
||||
default : break;
|
||||
public boolean accept(ASTVisitor action) {
|
||||
if (action.shouldVisitDeclSpecifiers) {
|
||||
switch (action.visit(this)) {
|
||||
case ASTVisitor.PROCESS_ABORT: return false;
|
||||
case ASTVisitor.PROCESS_SKIP: return true;
|
||||
default: break;
|
||||
}
|
||||
}
|
||||
if (!visitAlignmentSpecifiers(action)) {
|
||||
if (!visitAlignmentSpecifiers(action))
|
||||
return false;
|
||||
}
|
||||
if( name != null ) if( !name.accept( action ) ) return false;
|
||||
if( action.shouldVisitDeclSpecifiers ){
|
||||
switch( action.leave( this ) ){
|
||||
case ASTVisitor.PROCESS_ABORT : return false;
|
||||
case ASTVisitor.PROCESS_SKIP : return true;
|
||||
default : break;
|
||||
if (name != null && !name.accept(action))
|
||||
return false;
|
||||
|
||||
if (action.shouldVisitDeclSpecifiers) {
|
||||
switch (action.leave(this)) {
|
||||
case ASTVisitor.PROCESS_ABORT: return false;
|
||||
case ASTVisitor.PROCESS_SKIP: return true;
|
||||
default: break;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
@ -88,7 +88,8 @@ public class CASTTypedefNameSpecifier extends CASTBaseDeclSpecifier implements
|
|||
|
||||
@Override
|
||||
public int getRoleForName(IASTName n) {
|
||||
if( n == name ) return r_reference;
|
||||
if (n == name)
|
||||
return r_reference;
|
||||
return r_unclear;
|
||||
}
|
||||
|
||||
|
|
|
@ -92,7 +92,7 @@ public class CPPASTNamedTypeSpecifier extends CPPASTBaseDeclSpecifier
|
|||
if (name != null && !name.accept(action))
|
||||
return false;
|
||||
|
||||
if (action.shouldVisitDeclSpecifiers ){
|
||||
if (action.shouldVisitDeclSpecifiers) {
|
||||
switch (action.leave(this)) {
|
||||
case ASTVisitor.PROCESS_ABORT:
|
||||
return false;
|
||||
|
|
Loading…
Add table
Reference in a new issue