Home
last modified time | relevance | path

Searched refs:forStmt (Results 1 – 25 of 36) sorted by relevance

12

/external/javaparser/javaparser-core-testing/src/test/java/com/github/javaparser/ast/nodeTypes/
DNodeWithBodyTest.java14 ForStmt forStmt = TestParser.parseStatement("for(;;);").asForStmt(); in emptyStatementIsEmpty() local
16 assertTrue(forStmt.hasEmptyBody()); in emptyStatementIsEmpty()
21 ForStmt forStmt = TestParser.parseStatement("for(;;){}").asForStmt(); in emptyBlockIsEmpty() local
23 assertTrue(forStmt.hasEmptyBody()); in emptyBlockIsEmpty()
28 ForStmt forStmt = TestParser.parseStatement("for(;;)a=b;").asForStmt(); in simpleStatementIsNotEmpty() local
30 assertFalse(forStmt.hasEmptyBody()); in simpleStatementIsNotEmpty()
35 ForStmt forStmt = TestParser.parseStatement("for(;;){a=b;}").asForStmt(); in nonEmptyBlockIsNotEmpty() local
37 assertFalse(forStmt.hasEmptyBody()); in nonEmptyBlockIsNotEmpty()
/external/javaparser/javaparser-core-testing/src/test/java/com/github/javaparser/
DJavaParserTest.java273 ForStmt forStmt = parseStatement("for(int a,b=0;;){}").asForStmt(); in parsingInitializedAndUnitializedVarsInForStmt() local
274 assertEquals(1, forStmt.getInitialization().size()); in parsingInitializedAndUnitializedVarsInForStmt()
275 assertTrue(forStmt.getInitialization().get(0).isVariableDeclarationExpr()); in parsingInitializedAndUnitializedVarsInForStmt()
276 …assertEquals(2, forStmt.getInitialization().get(0).asVariableDeclarationExpr().getVariables().size… in parsingInitializedAndUnitializedVarsInForStmt()
277 …assertEquals("a", forStmt.getInitialization().get(0).asVariableDeclarationExpr().getVariables().ge… in parsingInitializedAndUnitializedVarsInForStmt()
278 …assertEquals("b", forStmt.getInitialization().get(0).asVariableDeclarationExpr().getVariables().ge… in parsingInitializedAndUnitializedVarsInForStmt()
279 …assertFalse(forStmt.getInitialization().get(0).asVariableDeclarationExpr().getVariables().get(0).g… in parsingInitializedAndUnitializedVarsInForStmt()
280 …assertTrue(forStmt.getInitialization().get(0).asVariableDeclarationExpr().getVariables().get(1).ge… in parsingInitializedAndUnitializedVarsInForStmt()
286 ForStmt forStmt = parseStatement("for(int i, j = array2.length - 1;;){}").asForStmt(); in parsingInitializedAndUnitializedVarsInForStmtComplexCase() local
287 assertEquals(1, forStmt.getInitialization().size()); in parsingInitializedAndUnitializedVarsInForStmtComplexCase()
[all …]
/external/llvm-project/clang-tools-extra/clang-tidy/bugprone/
DSpuriouslyWakeUpFunctionsCheck.cpp67 hasDescendant(forStmt(hasWaitDescendantCPP)), in registerMatchers()
80 hasDescendant(forStmt(hasWaitDescendantC)), in registerMatchers()
84 hasParent(forStmt()), in registerMatchers()
85 hasParent(compoundStmt(hasParent(forStmt()))), in registerMatchers()
DTerminatingContinueCheck.cpp29 continueStmt(hasAncestor(stmt(anyOf(forStmt(), whileStmt(), in registerMatchers()
DUnusedReturnValueCheck.cpp157 forStmt(eachOf(hasLoopInit(MatchedCallExpr), in registerMatchers()
DSuspiciousSemicolonCheck.cpp25 forStmt(hasBody(nullStmt().bind("semi"))), in registerMatchers()
DMultipleStatementMacroCheck.cpp62 whileStmt(hasBody(Inner)), forStmt(hasBody(Inner)))) in registerMatchers()
DSuspiciousStringCompareCheck.cpp119 forStmt(hasCondition(StringCompareCallExpr)), in registerMatchers()
DTooSmallLoopVariableCheck.cpp81 forStmt( in registerMatchers()
DInfiniteLoopCheck.cpp126 forStmt(LoopCondition))) in registerMatchers()
/external/llvm-project/clang-tools-extra/clang-tidy/cppcoreguidelines/
DAvoidGotoCheck.cpp32 auto Loop = stmt(anyOf(forStmt(), cxxForRangeStmt(), whileStmt(), doStmt())); in registerMatchers()
34 stmt(anyOf(forStmt(hasAncestor(Loop)), cxxForRangeStmt(hasAncestor(Loop)), in registerMatchers()
/external/llvm-project/clang-tools-extra/clang-tidy/cert/
DFloatLoopCounter.cpp21 forStmt(hasIncrement(expr(hasType(realFloatingPointType())))).bind("for"), in registerMatchers()
/external/clang/unittests/ASTMatchers/
DASTMatchersTraversalTest.cpp968 forStmt(hasCondition(cxxBoolLiteral(equals(true)))); in TEST()
985 forStmt(hasCondition(anything())))); in TEST()
987 forStmt(hasLoopInit(anything())))); in TEST()
1000 forStmt(hasCondition(expr())))); in TEST()
1002 forStmt(hasLoopInit(anything())))); in TEST()
1007 forStmt(hasBody(compoundStmt())))); in TEST()
1009 forStmt(hasBody(compoundStmt())))); in TEST()
1027 compoundStmt(hasAnySubstatement(forStmt())))); in TEST()
1033 compoundStmt(hasAnySubstatement(forStmt())))); in TEST()
1038 compoundStmt(hasAnySubstatement(forStmt())))); in TEST()
[all …]
DASTMatchersNodeTest.cpp831 EXPECT_TRUE(matches("void f() { for(;;); }", forStmt())); in TEST()
832 EXPECT_TRUE(matches("void f() { if(true) for(;;); }", forStmt())); in TEST()
835 forStmt())); in TEST()
839 EXPECT_TRUE(notMatches("void f() { ; }", forStmt())); in TEST()
840 EXPECT_TRUE(notMatches("void f() { if(true); }", forStmt())); in TEST()
/external/javaparser/javaparser-symbol-solver-testing/src/test/java/com/github/javaparser/symbolsolver/resolution/
DContextTest.java709 ForStmt forStmt = parse("for (int i=0, j=1;i<10;i++) { body(); }", in localVariablesExposedToChildWithinForStmt() local
711 …VariableDeclarationExpr initializations = forStmt.getInitialization().get(0).asVariableDeclaration… in localVariablesExposedToChildWithinForStmt()
715 assertOneVarExposedToChildInContextNamed(forStmt, in localVariablesExposedToChildWithinForStmt()
716 forStmt.getCompare().get(), in localVariablesExposedToChildWithinForStmt()
718 assertOneVarExposedToChildInContextNamed(forStmt, in localVariablesExposedToChildWithinForStmt()
719 forStmt.getUpdate().get(0), in localVariablesExposedToChildWithinForStmt()
721 assertOneVarExposedToChildInContextNamed(forStmt, in localVariablesExposedToChildWithinForStmt()
722 forStmt.getBody(), in localVariablesExposedToChildWithinForStmt()
/external/llvm-project/clang-tools-extra/clang-tidy/performance/
DInefficientStringConcatenationCheck.cpp62 whileStmt(), forStmt())))), in registerMatchers()
DUnnecessaryValueParamCheck.cpp48 unless(hasAncestor(stmt(anyOf(forStmt(), cxxForRangeStmt(), in hasLoopStmtAncestor()
DInefficientVectorOperationCheck.cpp127 forStmt( in AddMatcher()
/external/llvm-project/clang-tools-extra/clang-tidy/readability/
DRedundantControlFlowCheck.cpp43 stmt(anyOf(forStmt(), cxxForRangeStmt(), whileStmt(), doStmt()), in registerMatchers()
DMisleadingIndentationCheck.cpp115 compoundStmt(has(stmt(anyOf(ifStmt(), forStmt(), whileStmt())))) in registerMatchers()
/external/skia/src/sksl/
DSkSLInliner.cpp851 ForStatement& forStmt = (*stmt)->as<ForStatement>(); in visitStatement() local
852 if (forStmt.symbols()) { in visitStatement()
853 fSymbolTableStack.push_back(forStmt.symbols()); in visitStatement()
857 this->visitStatement(&forStmt.initializer(), in visitStatement()
859 this->visitStatement(&forStmt.statement()); in visitStatement()
/external/llvm-project/clang/docs/
DLibASTMatchersTutorial.rst220 forStmt()
227 forStmt(hasLoopInit(declStmt(hasSingleDecl(varDecl()))))
234 forStmt(hasLoopInit(declStmt(hasSingleDecl(varDecl(
250 forStmt(hasLoopInit(declStmt(hasSingleDecl(varDecl(
269 forStmt(hasLoopInit(declStmt(hasSingleDecl(varDecl(
472 forStmt(hasLoopInit(declStmt(
/external/clang/docs/
DLibASTMatchersTutorial.rst228 forStmt()
235 forStmt(hasLoopInit(declStmt(hasSingleDecl(varDecl()))))
242 forStmt(hasLoopInit(declStmt(hasSingleDecl(varDecl(
258 forStmt(hasLoopInit(declStmt(hasSingleDecl(varDecl(
277 forStmt(hasLoopInit(declStmt(hasSingleDecl(varDecl(
480 forStmt(hasLoopInit(declStmt(
/external/llvm-project/clang/unittests/ASTMatchers/
DASTMatchersTraversalTest.cpp1567 forStmt(hasCondition(cxxBoolLiteral(equals(true)))); in TEST()
1584 forStmt(hasCondition(anything())))); in TEST()
1586 forStmt(hasLoopInit(anything())))); in TEST()
1599 forStmt(hasCondition(expr())))); in TEST()
1601 forStmt(hasLoopInit(anything())))); in TEST()
1606 forStmt(hasBody(compoundStmt())))); in TEST()
1608 forStmt(hasBody(compoundStmt())))); in TEST()
1665 compoundStmt(hasAnySubstatement(forStmt())))); in TEST()
1671 compoundStmt(hasAnySubstatement(forStmt())))); in TEST()
1676 compoundStmt(hasAnySubstatement(forStmt())))); in TEST()
[all …]
/external/llvm-project/clang-tools-extra/clang-tidy/modernize/
DLoopConvertCheck.cpp113 return forStmt( in makeArrayLoopMatcher()
212 return forStmt( in makeIteratorLoopMatcher()
312 return forStmt( in makePseudoArrayLoopMatcher()

12