Skip to content

Commit a028f5e

Browse files
committed
C#: Deprecate some SSA internals.
1 parent 624af8a commit a028f5e

1 file changed

Lines changed: 8 additions & 8 deletions

File tree

  • csharp/ql/lib/semmle/code/csharp/dataflow/internal

csharp/ql/lib/semmle/code/csharp/dataflow/internal/SsaImpl.qll

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -77,11 +77,11 @@ module Ssa_ = Impl::MakeSsa<SsaInput>;
7777

7878
class Definition = Impl::Definition;
7979

80-
class WriteDefinition = Impl::WriteDefinition;
80+
deprecated class WriteDefinition = Impl::WriteDefinition;
8181

82-
class UncertainWriteDefinition = Impl::UncertainWriteDefinition;
82+
deprecated class UncertainWriteDefinition = Impl::UncertainWriteDefinition;
8383

84-
class PhiNode = Impl::PhiNode;
84+
deprecated class PhiNode = Impl::PhiNode;
8585

8686
module Consistency = Impl::Consistency;
8787

@@ -853,7 +853,7 @@ private module Cached {
853853
}
854854

855855
cached
856-
predicate isLiveAtEndOfBlock(Definition def, BasicBlock bb) {
856+
deprecated predicate isLiveAtEndOfBlock(Definition def, BasicBlock bb) {
857857
Impl::ssaDefReachesEndOfBlock(bb, def, _)
858858
}
859859

@@ -863,7 +863,7 @@ private module Cached {
863863
}
864864

865865
cached
866-
AssignableRead getAReadAtNode(Definition def, ControlFlowNode cfn) {
866+
deprecated AssignableRead getAReadAtNode(Definition def, ControlFlowNode cfn) {
867867
exists(Ssa::SourceVariable v, BasicBlock bb, int i |
868868
Impl::ssaDefReachesRead(v, def, bb, i) and
869869
variableReadActual(bb, i, v) and
@@ -997,9 +997,9 @@ private module DataFlowIntegrationInput implements Impl::DataFlowIntegrationInpu
997997
predicate hasCfgNode(BasicBlock bb, int i) { this = bb.getNode(i) }
998998
}
999999

1000-
Expr getARead(Definition def) { exists(getAReadAtNode(def, result)) }
1000+
Expr getARead(Definition def) { def.(SsaDefinition).getARead().getControlFlowNode() = result }
10011001

1002-
predicate ssaDefHasSource(WriteDefinition def) {
1002+
predicate ssaDefHasSource(Impl::WriteDefinition def) {
10031003
// exclude flow directly from RHS to SSA definition, as we instead want to
10041004
// go from RHS to matching assignable definition, and from there to SSA definition
10051005
def instanceof SsaParameterInit
@@ -1009,7 +1009,7 @@ private module DataFlowIntegrationInput implements Impl::DataFlowIntegrationInpu
10091009
* Allows for flow into uncertain defintions that are not call definitions,
10101010
* as we, conservatively, consider such definitions to be certain.
10111011
*/
1012-
predicate allowFlowIntoUncertainDef(UncertainWriteDefinition def) {
1012+
predicate allowFlowIntoUncertainDef(Impl::UncertainWriteDefinition def) {
10131013
def instanceof SsaExplicitWrite
10141014
or
10151015
def =

0 commit comments

Comments
 (0)