if(lookAhead() == DeeTokens.OPEN_BRACKET) {
NodeResult<InitializerArray> arrayInitResult = parseArrayInitializer();
if(arrayInitResult.ruleBroken) {
return arrayInitResult;
}
InitializerArray arrayInit = arrayInitResult.node;
assertTrue(arrayInit.getData().hasErrors() == false);
NodeResult<Expression> fullExpInitializer = parseExpression_fromUnary(InfixOpType.ASSIGN, arrayInit);
if(fullExpInitializer.node == arrayInit) {
return arrayInitResult;
}
if(!arrayInitializerCouldParseAsArrayLiteral(arrayInit)) {
ParserError error = createError(ParserErrorTypes.INIT_USED_IN_EXP, arrayInit.getSourceRange(), null);
arrayInit.resetData();
conclude(error, arrayInit);
} else {
// Even if initializer can be parsed as array literal, we place it in exp without any node conversion
// (this might change in future)
}