mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Fixed compiler warnings.
This commit is contained in:
parent
aaa0f85bb3
commit
813cfa454b
1 changed files with 1 additions and 32 deletions
|
@ -140,12 +140,6 @@ public class AST2BaseTest extends BaseTestCase {
|
||||||
return parse(code, lang, useGNUExtensions, true);
|
return parse(code, lang, useGNUExtensions, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param string
|
|
||||||
* @param c
|
|
||||||
* @return
|
|
||||||
* @throws ParserException
|
|
||||||
*/
|
|
||||||
protected IASTTranslationUnit parse(String code, ParserLanguage lang, boolean useGNUExtensions,
|
protected IASTTranslationUnit parse(String code, ParserLanguage lang, boolean useGNUExtensions,
|
||||||
boolean expectNoProblems) throws ParserException {
|
boolean expectNoProblems) throws ParserException {
|
||||||
return parse(code, lang, useGNUExtensions, expectNoProblems, false);
|
return parse(code, lang, useGNUExtensions, expectNoProblems, false);
|
||||||
|
@ -220,9 +214,6 @@ public class AST2BaseTest extends BaseTestCase {
|
||||||
return scanner;
|
return scanner;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param string
|
|
||||||
*/
|
|
||||||
protected void validateSimplePostfixInitializerExpressionC(String code) throws ParserException {
|
protected void validateSimplePostfixInitializerExpressionC(String code) throws ParserException {
|
||||||
ICASTTypeIdInitializerExpression e = (ICASTTypeIdInitializerExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
ICASTTypeIdInitializerExpression e = (ICASTTypeIdInitializerExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
||||||
assertNotNull(e);
|
assertNotNull(e);
|
||||||
|
@ -230,10 +221,6 @@ public class AST2BaseTest extends BaseTestCase {
|
||||||
assertNotNull(e.getInitializer());
|
assertNotNull(e.getInitializer());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param string
|
|
||||||
* @throws ParserException
|
|
||||||
*/
|
|
||||||
protected void validateSimpleUnaryTypeIdExpression(String code, int op) throws ParserException {
|
protected void validateSimpleUnaryTypeIdExpression(String code, int op) throws ParserException {
|
||||||
IASTCastExpression e = (IASTCastExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
IASTCastExpression e = (IASTCastExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
||||||
assertNotNull(e);
|
assertNotNull(e);
|
||||||
|
@ -243,11 +230,6 @@ public class AST2BaseTest extends BaseTestCase {
|
||||||
assertEquals(x.getName().toString(), "x"); //$NON-NLS-1$
|
assertEquals(x.getName().toString(), "x"); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param code
|
|
||||||
* @param op
|
|
||||||
* @throws ParserException
|
|
||||||
*/
|
|
||||||
protected void validateSimpleTypeIdExpressionC(String code, int op) throws ParserException {
|
protected void validateSimpleTypeIdExpressionC(String code, int op) throws ParserException {
|
||||||
IASTTypeIdExpression e = (IASTTypeIdExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
IASTTypeIdExpression e = (IASTTypeIdExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
||||||
assertNotNull(e);
|
assertNotNull(e);
|
||||||
|
@ -255,11 +237,6 @@ public class AST2BaseTest extends BaseTestCase {
|
||||||
assertNotNull(e.getTypeId());
|
assertNotNull(e.getTypeId());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param string
|
|
||||||
* @param op_prefixIncr
|
|
||||||
* @throws ParserException
|
|
||||||
*/
|
|
||||||
protected void validateSimpleUnaryExpressionC(String code, int operator) throws ParserException {
|
protected void validateSimpleUnaryExpressionC(String code, int operator) throws ParserException {
|
||||||
IASTUnaryExpression e = (IASTUnaryExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
IASTUnaryExpression e = (IASTUnaryExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
||||||
assertNotNull(e);
|
assertNotNull(e);
|
||||||
|
@ -268,10 +245,6 @@ public class AST2BaseTest extends BaseTestCase {
|
||||||
assertEquals(x.getName().toString(), "x"); //$NON-NLS-1$
|
assertEquals(x.getName().toString(), "x"); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param code
|
|
||||||
* @throws ParserException
|
|
||||||
*/
|
|
||||||
protected void validateConditionalExpressionC(String code) throws ParserException {
|
protected void validateConditionalExpressionC(String code) throws ParserException {
|
||||||
IASTConditionalExpression e = (IASTConditionalExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
IASTConditionalExpression e = (IASTConditionalExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
||||||
assertNotNull(e);
|
assertNotNull(e);
|
||||||
|
@ -283,10 +256,6 @@ public class AST2BaseTest extends BaseTestCase {
|
||||||
assertEquals(x.getName().toString(), x2.getName().toString());
|
assertEquals(x.getName().toString(), x2.getName().toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param operand
|
|
||||||
* @throws ParserException
|
|
||||||
*/
|
|
||||||
protected void validateSimpleBinaryExpressionC(String code, int operand) throws ParserException {
|
protected void validateSimpleBinaryExpressionC(String code, int operand) throws ParserException {
|
||||||
IASTBinaryExpression e = (IASTBinaryExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
IASTBinaryExpression e = (IASTBinaryExpression) getExpressionFromStatementInCode(code, ParserLanguage.C);
|
||||||
assertNotNull(e);
|
assertNotNull(e);
|
||||||
|
@ -343,7 +312,7 @@ public class AST2BaseTest extends BaseTestCase {
|
||||||
protected void assertInstances(CNameCollector collector, IBinding binding, int num) throws Exception {
|
protected void assertInstances(CNameCollector collector, IBinding binding, int num) throws Exception {
|
||||||
int count = 0;
|
int count = 0;
|
||||||
|
|
||||||
if (binding == null) assertTrue(false);
|
assertNotNull(binding);
|
||||||
|
|
||||||
for (int i = 0; i < collector.size(); i++) {
|
for (int i = 0; i < collector.size(); i++) {
|
||||||
if (collector.getName(i).resolveBinding() == binding)
|
if (collector.getName(i).resolveBinding() == binding)
|
||||||
|
|
Loading…
Add table
Reference in a new issue