1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-23 14:42:11 +02:00
John Camelon 2004-06-24 18:51:49 +00:00
parent 05ec4b4f52
commit 78cc9ee282
2 changed files with 13 additions and 0 deletions

View file

@ -304,4 +304,14 @@ public class SelectionParseTest extends SelectionParseBaseTest {
IASTNode node = parse( code, startIndex, startIndex + 5 );
assertNotNull( node );
}
public void testBug68527() throws Exception
{
Writer writer = new StringWriter();
writer.write("struct X;\n"); //$NON-NLS-1$
writer.write("struct X anA;"); //$NON-NLS-1$
String code = writer.toString();
int startIndex = code.indexOf( "X anA"); //$NON-NLS-1$
parse( code, startIndex, startIndex + 1 );
}
}

View file

@ -1939,8 +1939,11 @@ public abstract class Parser extends ExpressionParser implements IParser
sdw.setTypeSpecifier(elaboratedTypeSpec);
if (isForewardDecl)
{
((IASTElaboratedTypeSpecifier) elaboratedTypeSpec).acceptElement(
requestor, astFactory.getReferenceManager());
handleOffsetableNamedElement((IASTOffsetableNamedElement) elaboratedTypeSpec);
}
}
/**
* Parses the initDeclarator construct of the ANSI C++ spec.