Skip to content

Commit 1da3be4

Browse files
committed
C#: Remove remaining DefinitionExt references.
1 parent 79069ce commit 1da3be4

File tree

1 file changed

+0
-54
lines changed
  • csharp/ql/lib/semmle/code/csharp/dataflow/internal

1 file changed

+0
-54
lines changed

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

Lines changed: 0 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -994,60 +994,6 @@ private module Cached {
994994

995995
import Cached
996996

997-
private string getSplitString(DefinitionExt def) {
998-
exists(ControlFlow::BasicBlock bb, int i, ControlFlow::Node cfn |
999-
def.definesAt(_, bb, i, _) and
1000-
result = cfn.(ControlFlow::Nodes::ElementNode).getSplitsString()
1001-
|
1002-
cfn = bb.getNode(i)
1003-
or
1004-
not exists(bb.getNode(i)) and
1005-
cfn = bb.getFirstNode()
1006-
)
1007-
}
1008-
1009-
string getToStringPrefix(DefinitionExt def) {
1010-
result = "[" + getSplitString(def) + "] "
1011-
or
1012-
not exists(getSplitString(def)) and
1013-
result = ""
1014-
}
1015-
1016-
/**
1017-
* An extended static single assignment (SSA) definition.
1018-
*
1019-
* This is either a normal SSA definition (`Definition`) or a
1020-
* phi-read node (`PhiReadNode`).
1021-
*
1022-
* Only intended for internal use.
1023-
*/
1024-
class DefinitionExt extends Impl::DefinitionExt {
1025-
override string toString() { result = this.(Ssa::Definition).toString() }
1026-
1027-
/** Gets the location of this definition. */
1028-
override Location getLocation() { result = this.(Ssa::Definition).getLocation() }
1029-
1030-
/** Gets the enclosing callable of this definition. */
1031-
Callable getEnclosingCallable() { result = this.(Ssa::Definition).getEnclosingCallable() }
1032-
}
1033-
1034-
/**
1035-
* A phi-read node.
1036-
*
1037-
* Only intended for internal use.
1038-
*/
1039-
class PhiReadNode extends DefinitionExt, Impl::PhiReadNode {
1040-
override string toString() {
1041-
result = getToStringPrefix(this) + "SSA phi read(" + this.getSourceVariable() + ")"
1042-
}
1043-
1044-
override Location getLocation() { result = this.getBasicBlock().getLocation() }
1045-
1046-
override Callable getEnclosingCallable() {
1047-
result = this.getSourceVariable().getEnclosingCallable()
1048-
}
1049-
}
1050-
1051997
private module DataFlowIntegrationInput implements Impl::DataFlowIntegrationInputSig {
1052998
private import csharp as Cs
1053999
private import semmle.code.csharp.controlflow.BasicBlocks

0 commit comments

Comments
 (0)