Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSergey Prigogin2016-08-20 01:44:45 +0000
committerSergey Prigogin2016-08-20 01:46:13 +0000
commit58543c62450d7570931a0484edae3108813a656e (patch)
tree9fddec9234a52555f13da4fccc9f2a70972b7af8
parent9f7fd16f228266380a34bf97b530cc4504a8d045 (diff)
downloadorg.eclipse.cdt-58543c62450d7570931a0484edae3108813a656e.tar.gz
org.eclipse.cdt-58543c62450d7570931a0484edae3108813a656e.tar.xz
org.eclipse.cdt-58543c62450d7570931a0484edae3108813a656e.zip
Cosmetics.
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/c/ICASTTypedefNameSpecifier.java3
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/cpp/ICPPASTNamedTypeSpecifier.java7
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/c/CASTTypedefNameSpecifier.java37
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPASTNamedTypeSpecifier.java2
4 files changed, 23 insertions, 26 deletions
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/c/ICASTTypedefNameSpecifier.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/c/ICASTTypedefNameSpecifier.java
index 408dcd7e249..72e32df508b 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/c/ICASTTypedefNameSpecifier.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/c/ICASTTypedefNameSpecifier.java
@@ -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
*/
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/cpp/ICPPASTNamedTypeSpecifier.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/cpp/ICPPASTNamedTypeSpecifier.java
index b66240f7341..fc48fa884c4 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/cpp/ICPPASTNamedTypeSpecifier.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/core/dom/ast/cpp/ICPPASTNamedTypeSpecifier.java
@@ -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);
-
}
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/c/CASTTypedefNameSpecifier.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/c/CASTTypedefNameSpecifier.java
index fdad5020aac..811c3bd0557 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/c/CASTTypedefNameSpecifier.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/c/CASTTypedefNameSpecifier.java
@@ -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 && !name.accept(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 (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;
}
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPASTNamedTypeSpecifier.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPASTNamedTypeSpecifier.java
index 0119feb3558..24e2a76092b 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPASTNamedTypeSpecifier.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPASTNamedTypeSpecifier.java
@@ -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;

Back to the top