1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Cosmetics.

This commit is contained in:
Sergey Prigogin 2013-02-02 16:57:25 -08:00
parent 6f24a6820b
commit 2a96dbfc19
47 changed files with 304 additions and 319 deletions

View file

@ -240,7 +240,8 @@ public class IndexUpdateTests extends IndexTestBase {
for (int i = 0; i < nchars.length; i++) {
nchars[i]= names[i].toCharArray();
}
return fIndex.findBindings(nchars, IndexFilter.ALL_DECLARED, npm())[0];
IIndexBinding[] bindings = fIndex.findBindings(nchars, IndexFilter.ALL_DECLARED, npm());
return bindings.length > 0 ? bindings[0] : null;
}
private String msg() {
@ -256,7 +257,6 @@ public class IndexUpdateTests extends IndexTestBase {
// short globalVar;
// register int globalVar;
public void testGlobalCppVariable() throws Exception {
setupFile(3, true);
checkCppVariable("globalVar", INT, new String[]{});
@ -345,7 +345,6 @@ public class IndexUpdateTests extends IndexTestBase {
// struct my_struct {int fField;};
// struct my_struct {short fField;};
public void testCField() throws Exception {
setupFile(2, false);
checkVariable("my_struct::fField", INT, new String[]{});
@ -402,7 +401,6 @@ public class IndexUpdateTests extends IndexTestBase {
checkModifier(modifiers, PRIVATE, visibility == ICPPMember.v_private);
}
// class MyClass {int method(int a, int b);};
// class MyClass {short method(int a, int b);};
@ -422,7 +420,6 @@ public class IndexUpdateTests extends IndexTestBase {
// class MyClass {int method(char a){};};
// class MyClass {virtual int method(char a) = 0;};
public void testCppMethod() throws Exception {
setupFile(10, true);
checkCppMethod("MyClass::method", new String[] {INT, INT, INT}, new String[]{PRIVATE});
@ -453,7 +450,6 @@ public class IndexUpdateTests extends IndexTestBase {
// #include "header.h"
// char MyClass::method(int a, int b);
public void testFixedCppMethod() throws Exception {
setupHeader(3, true);
checkCppMethod("MyClass::method", new String[] {INT, INT, INT}, new String[]{PROTECTED});
@ -493,7 +489,6 @@ public class IndexUpdateTests extends IndexTestBase {
// class MyClass {protected: MyClass(char a, int b);};
// class MyClass {private: MyClass(char a, int b);};
public void testCppConstructor() throws Exception {
setupFile(6, true);
checkCppConstructor("MyClass::MyClass", new String[] {"", INT, INT}, new String[]{PRIVATE});
@ -587,7 +582,8 @@ public class IndexUpdateTests extends IndexTestBase {
}
checkCppConstructor((ICPPConstructor) ctors[0], new String[]{"", constRefType}, m2);
IIndexBinding[] assignmentOps= fIndex.findBindings(new char[][]{nchars, "operator =".toCharArray()}, IndexFilter.ALL_DECLARED_OR_IMPLICIT, npm());
IIndexBinding[] assignmentOps= fIndex.findBindings(
new char[][] {nchars, "operator =".toCharArray() }, IndexFilter.ALL_DECLARED_OR_IMPLICIT, npm());
count= 0;
for (int i = 0; i < assignmentOps.length; i++) {
IIndexBinding assignmentOp= assignmentOps[i];
@ -717,7 +713,6 @@ public class IndexUpdateTests extends IndexTestBase {
}
}
// class myType {
// int a;
// };
@ -1183,7 +1178,6 @@ public class IndexUpdateTests extends IndexTestBase {
}
}
// void funcTypeDeletion(int);
// #include "header.h"

View file

@ -24,7 +24,6 @@ import org.eclipse.core.runtime.CoreException;
/**
* @author Doug Schaefer
*
*/
public abstract class PDOMNamedNode extends PDOMNode {
/**
@ -104,7 +103,6 @@ public abstract class PDOMNamedNode extends PDOMNode {
fName= nameCharArray;
}
@Override
public void delete(PDOMLinkage linkage) throws CoreException {
final Database db = getDB();

View file

@ -75,7 +75,6 @@ import org.eclipse.cdt.internal.ui.search.actions.OpenDeclarationsAction;
* @author dsteffle
*/
public class CPPSelectionTestsNoIndexer extends BaseUITestCase {
private static final String INDEX_FILE_ID = "2946365241"; //$NON-NLS-1$
static NullProgressMonitor monitor;
static IWorkspace workspace;

View file

@ -12,7 +12,6 @@
*******************************************************************************/
package org.eclipse.cdt.internal.ui.text;
import java.util.HashMap;
import java.util.Map;

View file

@ -10,7 +10,6 @@
# Anton Leherbauer (Wind River Systems)
# Sergey Prigogin (Google)
###############################################################################
AbstractAnnotationHover_action_configureAnnotationPreferences= Configure Annotation Preferences
AbstractAnnotationHover_message_singleQuickFix= 1 quick fix available:
AbstractAnnotationHover_message_multipleQuickFix= {0} quick fixes available:

View file

@ -46,5 +46,4 @@ public class AnnotationHover implements IAnnotationHover {
}
return null;
}
}

View file

@ -25,7 +25,6 @@ import org.eclipse.cdt.core.parser.OffsetLimitReachedException;
* TODO move into an internal package
*/
public class CPreprocessorAdapter {
/**
* During content assist the preprocessor may return a completion token
* which represents the identifier on which the user invoked content assist.

View file

@ -31,7 +31,6 @@ import org.eclipse.cdt.internal.core.dom.lrparser.gcc.GCCParser;
* @author Mike Kucera
*/
public class GCCLanguage extends BaseExtensibleLanguage {
public static final String ID = "org.eclipse.cdt.core.lrparser.gcc"; //$NON-NLS-1$
private static GCCLanguage DEFAULT = new GCCLanguage();

View file

@ -18,7 +18,6 @@ public class CPPRules {
static Map fRules = new HashMap();
static {
fRules.put(Integer.valueOf(3), "] ::= RightBracket");
fRules.put(Integer.valueOf(4), "] ::= EndOfCompletion");
fRules.put(Integer.valueOf(5), ") ::= RightParen");