mirror of
https://github.com/github/codeql.git
synced 2025-12-24 04:36:35 +01:00
C#: Rename and restructure control flow graph entities
Follow a naming structure similar to the data flow library: - `ControlFlowNode` -> `ControlFlow::Node`. - `CallableEntryNode` -> `ControlFlow::Nodes::EntryNode`. - `CallableExitNode` -> `ControlFlow::Nodes::ExitNode`. - `ControlFlowEdgeType` -> `ControlFlow::SuccessorType`. - `ControlFlowEdgeSuccessor` -> `ControlFlow::SuccessorTypes::NormalSuccessor`. - `ControlFlowEdgeConditional -> ControlFlow::SuccessorTypes::ConditionalSuccessor`. - `ControlFlowEdgeBoolean` -> `ControlFlow::SuccessorTypes::BooleanSuccessor`. - `ControlFlowEdgeNullness` -> `ControlFlow::SuccessorTypes::NullnessSuccessor`. - `ControlFlowEdgeMatching` -> `ControlFlow::SuccessorTypes::MatchingSuccessor`. - `ControlFlowEdgeEmptiness` -> `ControlFlow::SuccessorTypes::EmptinessSuccessor`. - `ControlFlowEdgeReturn` -> `ControlFlow::SuccessorTypes::ReturnSuccessor`. - `ControlFlowEdgeBreak` -> `ControlFlow::SuccessorTypes::BreakSuccessor`. - `ControlFlowEdgeContinue` -> `ControlFlow::SuccessorTypes::ContinueSuccessor`. - `ControlFlowEdgeGotoLabel` -> `ControlFlow::SuccessorTypes::GotoLabelSuccessor`. - `ControlFlowEdgeGotoCase` -> `ControlFlow::SuccessorTypes::GotoCaseSuccessor`. - `ControlFlowEdgeGotoDefault` -> `ControlFlow::SuccessorTypes::GotoDefaultSuccessor`. - `ControlFlowEdgeException` -> `ControlFlow::SuccessorTypes::ExceptionSuccessor`
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
import csharp
|
||||
import semmle.code.csharp.frameworks.system.Text
|
||||
|
||||
from ObjectCreation creation, LoopStmt loop, ControlFlowGraph::ControlFlowNode loopEntryNode
|
||||
from ObjectCreation creation, LoopStmt loop, ControlFlow::Node loopEntryNode
|
||||
where creation.getType() instanceof SystemTextStringBuilderClass
|
||||
and loopEntryNode = loop.getBody().getAControlFlowEntryNode()
|
||||
and loop.getBody().getAChild*() = creation
|
||||
|
||||
Reference in New Issue
Block a user