Lines Matching refs:unique_ptr

142 std::vector<std::unique_ptr<ASTDeclaration>> Parser::file() {  in file()
143 std::vector<std::unique_ptr<ASTDeclaration>> result; in file()
149 std::unique_ptr<ASTDeclaration> decl = this->directive(); in file()
156 std::unique_ptr<ASTDeclaration> section = this->section(); in file()
163 std::unique_ptr<ASTDeclaration> decl = this->declaration(); in file()
251 std::unique_ptr<ASTDeclaration> Parser::directive() { in directive()
279 return std::unique_ptr<ASTDeclaration>(new ASTExtension(start.fOffset, in directive()
289 std::unique_ptr<ASTDeclaration> Parser::section() { in section()
334 return std::unique_ptr<ASTDeclaration>(new ASTSection(start.fOffset, in section()
342 std::unique_ptr<ASTDeclaration> Parser::enumDeclaration() { in enumDeclaration()
357 fTypes.add(this->text(name), std::unique_ptr<Symbol>(new Type(this->text(name), in enumDeclaration()
360 std::vector<std::unique_ptr<ASTExpression>> values; in enumDeclaration()
368 std::unique_ptr<ASTExpression> value = this->assignmentExpression(); in enumDeclaration()
385 std::unique_ptr<ASTExpression> value = this->assignmentExpression(); in enumDeclaration()
396 return std::unique_ptr<ASTDeclaration>(new ASTEnum(name.fOffset, this->text(name), names, in enumDeclaration()
402 std::unique_ptr<ASTDeclaration> Parser::declaration() { in declaration()
418 return std::unique_ptr<ASTDeclaration>(new ASTModifiersDeclaration(modifiers)); in declaration()
420 std::unique_ptr<ASTType> type(this->type()); in declaration()
432 std::vector<std::unique_ptr<ASTParameter>> parameters; in declaration()
439 std::unique_ptr<ASTParameter> parameter = this->parameter(); in declaration()
446 std::unique_ptr<ASTBlock> body; in declaration()
453 return std::unique_ptr<ASTDeclaration>(new ASTFunction(name.fOffset, in declaration()
465 std::unique_ptr<ASTVarDeclarations> Parser::varDeclarations() { in varDeclarations()
467 std::unique_ptr<ASTType> type(this->type()); in varDeclarations()
479 std::unique_ptr<ASTType> Parser::structDeclaration() { in structDeclaration()
492 std::unique_ptr<ASTVarDeclarations> decl = this->varDeclarations(); in structDeclaration()
517 fTypes.add(this->text(name), std::unique_ptr<Type>(new Type(name.fOffset, this->text(name), in structDeclaration()
519 return std::unique_ptr<ASTType>(new ASTType(name.fOffset, this->text(name), in structDeclaration()
524 std::unique_ptr<ASTVarDeclarations> Parser::structVarDeclaration(Modifiers modifiers) { in structVarDeclaration()
525 std::unique_ptr<ASTType> type = this->structDeclaration(); in structVarDeclaration()
531 std::unique_ptr<ASTVarDeclarations> result = this->varDeclarationEnd(modifiers, in structVarDeclaration()
550 std::unique_ptr<ASTVarDeclarations> Parser::varDeclarationEnd(Modifiers mods, in varDeclarationEnd()
551 std::unique_ptr<ASTType> type, in varDeclarationEnd()
554 std::vector<std::unique_ptr<ASTExpression>> currentVarSizes; in varDeclarationEnd()
559 std::unique_ptr<ASTExpression> size(this->expression()); in varDeclarationEnd()
569 std::unique_ptr<ASTExpression> value; in varDeclarationEnd()
588 std::unique_ptr<ASTExpression> size(this->expression()); in varDeclarationEnd()
609 return std::unique_ptr<ASTVarDeclarations>(new ASTVarDeclarations(std::move(mods), in varDeclarationEnd()
615 std::unique_ptr<ASTParameter> Parser::parameter() { in parameter()
617 std::unique_ptr<ASTType> type = this->type(); in parameter()
636 return std::unique_ptr<ASTParameter>(new ASTParameter(name.fOffset, modifiers, std::move(type), in parameter()
1020 std::unique_ptr<ASTStatement> Parser::statement() { in statement()
1047 return std::unique_ptr<ASTStatement>(new ASTBlock(start.fOffset, in statement()
1048 std::vector<std::unique_ptr<ASTStatement>>())); in statement()
1057 return std::unique_ptr<ASTStatement>(new ASTVarDeclarationStatement(std::move(decl))); in statement()
1065 return std::unique_ptr<ASTStatement>(new ASTVarDeclarationStatement( in statement()
1075 std::unique_ptr<ASTType> Parser::type() { in type()
1098 return std::unique_ptr<ASTType>(new ASTType(type.fOffset, this->text(type), in type()
1103 std::unique_ptr<ASTDeclaration> Parser::interfaceBlock(Modifiers mods) { in interfaceBlock()
1116 std::vector<std::unique_ptr<ASTVarDeclarations>> decls; in interfaceBlock()
1118 std::unique_ptr<ASTVarDeclarations> decl = this->varDeclarations(); in interfaceBlock()
1125 std::vector<std::unique_ptr<ASTExpression>> sizes; in interfaceBlock()
1131 std::unique_ptr<ASTExpression> size = this->expression(); in interfaceBlock()
1144 return std::unique_ptr<ASTDeclaration>(new ASTInterfaceBlock(name.fOffset, mods, in interfaceBlock()
1152 std::unique_ptr<ASTIfStatement> Parser::ifStatement() { in ifStatement()
1161 std::unique_ptr<ASTExpression> test(this->expression()); in ifStatement()
1168 std::unique_ptr<ASTStatement> ifTrue(this->statement()); in ifStatement()
1172 std::unique_ptr<ASTStatement> ifFalse; in ifStatement()
1179 return std::unique_ptr<ASTIfStatement>(new ASTIfStatement(start.fOffset, in ifStatement()
1187 std::unique_ptr<ASTDoStatement> Parser::doStatement() { in doStatement()
1192 std::unique_ptr<ASTStatement> statement(this->statement()); in doStatement()
1202 std::unique_ptr<ASTExpression> test(this->expression()); in doStatement()
1212 return std::unique_ptr<ASTDoStatement>(new ASTDoStatement(start.fOffset, in doStatement()
1218 std::unique_ptr<ASTWhileStatement> Parser::whileStatement() { in whileStatement()
1226 std::unique_ptr<ASTExpression> test(this->expression()); in whileStatement()
1233 std::unique_ptr<ASTStatement> statement(this->statement()); in whileStatement()
1237 return std::unique_ptr<ASTWhileStatement>(new ASTWhileStatement(start.fOffset, in whileStatement()
1243 std::unique_ptr<ASTSwitchCase> Parser::switchCase() { in switchCase()
1248 std::unique_ptr<ASTExpression> value = this->expression(); in switchCase()
1255 std::vector<std::unique_ptr<ASTStatement>> statements; in switchCase()
1258 std::unique_ptr<ASTStatement> s = this->statement(); in switchCase()
1264 return std::unique_ptr<ASTSwitchCase>(new ASTSwitchCase(start.fOffset, std::move(value), in switchCase()
1269 std::unique_ptr<ASTStatement> Parser::switchStatement() { in switchStatement()
1278 std::unique_ptr<ASTExpression> value(this->expression()); in switchStatement()
1288 std::vector<std::unique_ptr<ASTSwitchCase>> cases; in switchStatement()
1290 std::unique_ptr<ASTSwitchCase> c = this->switchCase(); in switchStatement()
1304 std::vector<std::unique_ptr<ASTStatement>> statements; in switchStatement()
1306 std::unique_ptr<ASTStatement> s = this->statement(); in switchStatement()
1318 return std::unique_ptr<ASTStatement>(new ASTSwitchStatement(start.fOffset, in switchStatement()
1326 std::unique_ptr<ASTForStatement> Parser::forStatement() { in forStatement()
1334 std::unique_ptr<ASTStatement> initializer; in forStatement()
1341 std::unique_ptr<ASTVarDeclarations> vd = this->varDeclarations(); in forStatement()
1345 initializer = std::unique_ptr<ASTStatement>(new ASTVarDeclarationStatement( in forStatement()
1351 std::unique_ptr<ASTVarDeclarations> vd = this->varDeclarations(); in forStatement()
1355 initializer = std::unique_ptr<ASTStatement>(new ASTVarDeclarationStatement( in forStatement()
1363 std::unique_ptr<ASTExpression> test; in forStatement()
1373 std::unique_ptr<ASTExpression> next; in forStatement()
1383 std::unique_ptr<ASTStatement> statement(this->statement()); in forStatement()
1387 return std::unique_ptr<ASTForStatement>(new ASTForStatement(start.fOffset, in forStatement()
1394 std::unique_ptr<ASTReturnStatement> Parser::returnStatement() { in returnStatement()
1399 std::unique_ptr<ASTExpression> expression; in returnStatement()
1409 return std::unique_ptr<ASTReturnStatement>(new ASTReturnStatement(start.fOffset, in returnStatement()
1414 std::unique_ptr<ASTBreakStatement> Parser::breakStatement() { in breakStatement()
1422 return std::unique_ptr<ASTBreakStatement>(new ASTBreakStatement(start.fOffset)); in breakStatement()
1426 std::unique_ptr<ASTContinueStatement> Parser::continueStatement() { in continueStatement()
1434 return std::unique_ptr<ASTContinueStatement>(new ASTContinueStatement(start.fOffset)); in continueStatement()
1438 std::unique_ptr<ASTDiscardStatement> Parser::discardStatement() { in discardStatement()
1446 return std::unique_ptr<ASTDiscardStatement>(new ASTDiscardStatement(start.fOffset)); in discardStatement()
1450 std::unique_ptr<ASTBlock> Parser::block() { in block()
1459 std::vector<std::unique_ptr<ASTStatement>> statements; in block()
1464 return std::unique_ptr<ASTBlock>(new ASTBlock(start.fOffset, in block()
1470 std::unique_ptr<ASTStatement> statement = this->statement(); in block()
1481 std::unique_ptr<ASTExpressionStatement> Parser::expressionStatement() { in expressionStatement()
1482 std::unique_ptr<ASTExpression> expr = this->expression(); in expressionStatement()
1486 return std::unique_ptr<ASTExpressionStatement>(result); in expressionStatement()
1493 std::unique_ptr<ASTExpression> Parser::expression() { in expression()
1502 std::unique_ptr<ASTExpression> Parser::commaExpression() { in commaExpression()
1503 std::unique_ptr<ASTExpression> result = this->assignmentExpression(); in commaExpression()
1509 std::unique_ptr<ASTExpression> right = this->commaExpression(); in commaExpression()
1522 std::unique_ptr<ASTExpression> Parser::assignmentExpression() { in assignmentExpression()
1523 std::unique_ptr<ASTExpression> result = this->ternaryExpression(); in assignmentExpression()
1544 std::unique_ptr<ASTExpression> right = this->assignmentExpression(); in assignmentExpression()
1548 result = std::unique_ptr<ASTExpression>(new ASTBinaryExpression(std::move(result), in assignmentExpression()
1560 std::unique_ptr<ASTExpression> Parser::ternaryExpression() { in ternaryExpression()
1561 std::unique_ptr<ASTExpression> result = this->logicalOrExpression(); in ternaryExpression()
1566 std::unique_ptr<ASTExpression> trueExpr = this->expression(); in ternaryExpression()
1571 std::unique_ptr<ASTExpression> falseExpr = this->assignmentExpression(); in ternaryExpression()
1572 return std::unique_ptr<ASTExpression>(new ASTTernaryExpression(std::move(result), in ternaryExpression()
1582 std::unique_ptr<ASTExpression> Parser::logicalOrExpression() { in logicalOrExpression()
1583 std::unique_ptr<ASTExpression> result = this->logicalXorExpression(); in logicalOrExpression()
1589 std::unique_ptr<ASTExpression> right = this->logicalXorExpression(); in logicalOrExpression()
1599 std::unique_ptr<ASTExpression> Parser::logicalXorExpression() { in logicalXorExpression()
1600 std::unique_ptr<ASTExpression> result = this->logicalAndExpression(); in logicalXorExpression()
1606 std::unique_ptr<ASTExpression> right = this->logicalAndExpression(); in logicalXorExpression()
1616 std::unique_ptr<ASTExpression> Parser::logicalAndExpression() { in logicalAndExpression()
1617 std::unique_ptr<ASTExpression> result = this->bitwiseOrExpression(); in logicalAndExpression()
1623 std::unique_ptr<ASTExpression> right = this->bitwiseOrExpression(); in logicalAndExpression()
1633 std::unique_ptr<ASTExpression> Parser::bitwiseOrExpression() { in bitwiseOrExpression()
1634 std::unique_ptr<ASTExpression> result = this->bitwiseXorExpression(); in bitwiseOrExpression()
1640 std::unique_ptr<ASTExpression> right = this->bitwiseXorExpression(); in bitwiseOrExpression()
1650 std::unique_ptr<ASTExpression> Parser::bitwiseXorExpression() { in bitwiseXorExpression()
1651 std::unique_ptr<ASTExpression> result = this->bitwiseAndExpression(); in bitwiseXorExpression()
1657 std::unique_ptr<ASTExpression> right = this->bitwiseAndExpression(); in bitwiseXorExpression()
1667 std::unique_ptr<ASTExpression> Parser::bitwiseAndExpression() { in bitwiseAndExpression()
1668 std::unique_ptr<ASTExpression> result = this->equalityExpression(); in bitwiseAndExpression()
1674 std::unique_ptr<ASTExpression> right = this->equalityExpression(); in bitwiseAndExpression()
1684 std::unique_ptr<ASTExpression> Parser::equalityExpression() { in equalityExpression()
1685 std::unique_ptr<ASTExpression> result = this->relationalExpression(); in equalityExpression()
1694 std::unique_ptr<ASTExpression> right = this->relationalExpression(); in equalityExpression()
1708 std::unique_ptr<ASTExpression> Parser::relationalExpression() { in relationalExpression()
1709 std::unique_ptr<ASTExpression> result = this->shiftExpression(); in relationalExpression()
1720 std::unique_ptr<ASTExpression> right = this->shiftExpression(); in relationalExpression()
1735 std::unique_ptr<ASTExpression> Parser::shiftExpression() { in shiftExpression()
1736 std::unique_ptr<ASTExpression> result = this->additiveExpression(); in shiftExpression()
1745 std::unique_ptr<ASTExpression> right = this->additiveExpression(); in shiftExpression()
1760 std::unique_ptr<ASTExpression> Parser::additiveExpression() { in additiveExpression()
1761 std::unique_ptr<ASTExpression> result = this->multiplicativeExpression(); in additiveExpression()
1770 std::unique_ptr<ASTExpression> right = this->multiplicativeExpression(); in additiveExpression()
1785 std::unique_ptr<ASTExpression> Parser::multiplicativeExpression() { in multiplicativeExpression()
1786 std::unique_ptr<ASTExpression> result = this->unaryExpression(); in multiplicativeExpression()
1796 std::unique_ptr<ASTExpression> right = this->unaryExpression(); in multiplicativeExpression()
1811 std::unique_ptr<ASTExpression> Parser::unaryExpression() { in unaryExpression()
1820 std::unique_ptr<ASTExpression> expr = this->unaryExpression(); in unaryExpression()
1824 return std::unique_ptr<ASTExpression>(new ASTPrefixExpression(std::move(t), in unaryExpression()
1833 std::unique_ptr<ASTExpression> Parser::postfixExpression() { in postfixExpression()
1834 std::unique_ptr<ASTExpression> result = this->term(); in postfixExpression()
1846 std::unique_ptr<ASTSuffix> s = this->suffix(); in postfixExpression()
1861 std::unique_ptr<ASTSuffix> Parser::suffix() { in suffix()
1866 return std::unique_ptr<ASTSuffix>(new ASTIndexSuffix(next.fOffset)); in suffix()
1868 std::unique_ptr<ASTExpression> e = this->expression(); in suffix()
1873 return std::unique_ptr<ASTSuffix>(new ASTIndexSuffix(std::move(e))); in suffix()
1880 return std::unique_ptr<ASTSuffix>(new ASTFieldSuffix(offset, std::move(text))); in suffix()
1885 std::vector<std::unique_ptr<ASTExpression>> parameters; in suffix()
1888 std::unique_ptr<ASTExpression> expr = this->assignmentExpression(); in suffix()
1899 return std::unique_ptr<ASTSuffix>(new ASTCallSuffix(next.fOffset, in suffix()
1903 return std::unique_ptr<ASTSuffix>(new ASTSuffix(next.fOffset, in suffix()
1906 return std::unique_ptr<ASTSuffix>(new ASTSuffix(next.fOffset, in suffix()
1917 std::unique_ptr<ASTExpression> Parser::term() { in term()
1918 std::unique_ptr<ASTExpression> result; in term()