mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-08 18:26:01 +02:00
Added JUnit test to validate 69526 - [Parser] CDT parse failures on C function-like macro definition with no parameters
This commit is contained in:
parent
f172ffa642
commit
78ccc6c372
1 changed files with 11 additions and 0 deletions
|
@ -2123,5 +2123,16 @@ public class CompleteParseASTTest extends CompleteParseBaseTest
|
|||
writer.write( "}\n" );
|
||||
parse( writer.toString() );
|
||||
}
|
||||
|
||||
public void testBug69526() throws Exception
|
||||
{
|
||||
Writer writer = new StringWriter();
|
||||
writer.write( "unsigned inkernel;\n" );
|
||||
writer.write( "#define lock_kernel() (inkernel |= 0x01)" );
|
||||
writer.write( "int main(int argc, char **argv) {" );
|
||||
writer.write( "lock_kernel();" );
|
||||
writer.write( "}" );
|
||||
parse( writer.toString() );
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue