mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-31 12:55:40 +02:00
Cosmetics.
This commit is contained in:
parent
eb549137f7
commit
a8bfc893f3
2 changed files with 6 additions and 6 deletions
|
@ -31,5 +31,5 @@ public interface ICPPNamespace extends ICPPBinding {
|
||||||
* get an array of the all the bindings declared in this namespace.
|
* get an array of the all the bindings declared in this namespace.
|
||||||
* @throws DOMException
|
* @throws DOMException
|
||||||
*/
|
*/
|
||||||
public IBinding [] getMemberBindings() throws DOMException;
|
public IBinding[] getMemberBindings() throws DOMException;
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,7 +48,7 @@ import org.eclipse.core.runtime.PlatformObject;
|
||||||
* @author aniefer
|
* @author aniefer
|
||||||
*/
|
*/
|
||||||
public class CPPVariable extends PlatformObject implements ICPPVariable, ICPPInternalBinding, IInternalVariable {
|
public class CPPVariable extends PlatformObject implements ICPPVariable, ICPPInternalBinding, IInternalVariable {
|
||||||
public static class CPPVariableProblem extends ProblemBinding implements ICPPVariable{
|
public static class CPPVariableProblem extends ProblemBinding implements ICPPVariable {
|
||||||
public CPPVariableProblem(IASTNode node, int id, char[] arg) {
|
public CPPVariableProblem(IASTNode node, int id, char[] arg) {
|
||||||
super(node, id, arg);
|
super(node, id, arg);
|
||||||
}
|
}
|
||||||
|
@ -122,11 +122,11 @@ public class CPPVariable extends PlatformObject implements ICPPVariable, ICPPInt
|
||||||
IASTSimpleDeclaration simpleDecl = (IASTSimpleDeclaration) dtor.getParent();
|
IASTSimpleDeclaration simpleDecl = (IASTSimpleDeclaration) dtor.getParent();
|
||||||
IASTDeclSpecifier declSpec = simpleDecl.getDeclSpecifier();
|
IASTDeclSpecifier declSpec = simpleDecl.getDeclSpecifier();
|
||||||
|
|
||||||
//(3.1-1) A declaration is a definition unless ...
|
// (3.1-1) A declaration is a definition unless ...
|
||||||
//it contains the extern specifier or a linkage-spec and does not contain an initializer
|
// it contains the extern specifier or a linkage-spec and does not contain an initializer
|
||||||
if (dtor.getInitializer() == null && declSpec.getStorageClass() == IASTDeclSpecifier.sc_extern)
|
if (dtor.getInitializer() == null && declSpec.getStorageClass() == IASTDeclSpecifier.sc_extern)
|
||||||
return false;
|
return false;
|
||||||
//or it declares a static data member in a class declaration
|
// or it declares a static data member in a class declaration
|
||||||
if (simpleDecl.getParent() instanceof ICPPASTCompositeTypeSpecifier &&
|
if (simpleDecl.getParent() instanceof ICPPASTCompositeTypeSpecifier &&
|
||||||
declSpec.getStorageClass() == IASTDeclSpecifier.sc_static) {
|
declSpec.getStorageClass() == IASTDeclSpecifier.sc_static) {
|
||||||
return false;
|
return false;
|
||||||
|
@ -274,7 +274,7 @@ public class CPPVariable extends PlatformObject implements ICPPVariable, ICPPInt
|
||||||
parent = parent.getParent();
|
parent = parent.getParent();
|
||||||
|
|
||||||
if (parent instanceof IASTSimpleDeclaration) {
|
if (parent instanceof IASTSimpleDeclaration) {
|
||||||
IASTDeclSpecifier declSpec = ((IASTSimpleDeclaration)parent).getDeclSpecifier();
|
IASTDeclSpecifier declSpec = ((IASTSimpleDeclaration) parent).getDeclSpecifier();
|
||||||
if (declSpec.getStorageClass() == storage) {
|
if (declSpec.getStorageClass() == storage) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue