mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-08 18:26:01 +02:00
74190 - [Scanner][IProblem] glib.h macro usage error
This commit is contained in:
parent
475911cb82
commit
a885c2bd7f
2 changed files with 13 additions and 1 deletions
|
@ -266,4 +266,15 @@ public class GCCCompleteParseExtensionsTest extends CompleteParseBaseTest {
|
||||||
|
|
||||||
parse( writer.toString() );
|
parse( writer.toString() );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void testBug74190_g_return_if_fail() throws Exception {
|
||||||
|
Writer writer = new StringWriter();
|
||||||
|
writer.write( "void f() { \n"); //$NON-NLS-1$
|
||||||
|
writer.write( " (void)({ if( ( ({ 0; }) ) ) \n"); //$NON-NLS-1$
|
||||||
|
writer.write( " { } \n"); //$NON-NLS-1$
|
||||||
|
writer.write( " }); \n"); //$NON-NLS-1$
|
||||||
|
writer.write( "} \n"); //$NON-NLS-1$
|
||||||
|
|
||||||
|
parse( writer.toString() );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -62,7 +62,8 @@ public abstract class GCCASTExtension implements IASTFactoryExtension {
|
||||||
kind == IASTGCCExpression.Kind.UNARY_TYPEOF_UNARYEXPRESSION ||
|
kind == IASTGCCExpression.Kind.UNARY_TYPEOF_UNARYEXPRESSION ||
|
||||||
kind == IASTGCCExpression.Kind.UNARY_TYPEOF_TYPEID ||
|
kind == IASTGCCExpression.Kind.UNARY_TYPEOF_TYPEID ||
|
||||||
kind == IASTGCCExpression.Kind.RELATIONAL_MAX ||
|
kind == IASTGCCExpression.Kind.RELATIONAL_MAX ||
|
||||||
kind == IASTGCCExpression.Kind.RELATIONAL_MIN )
|
kind == IASTGCCExpression.Kind.RELATIONAL_MIN ||
|
||||||
|
kind == IASTGCCExpression.Kind.STATEMENT_EXPRESSION )
|
||||||
return true;
|
return true;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue