Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,9 @@
*/
Nodes::ElementNode getAControlFlowNode() { result.getAstNode() = this }

ControlFlow::Node getControlFlowNode() { result.getAstNode() = this }

Check warning on line 43 in csharp/ql/lib/semmle/code/csharp/controlflow/ControlFlowElement.qll

View workflow job for this annotation

GitHub Actions / qldoc

Missing QLdoc for member-predicate ControlFlowElement::ControlFlowElement::getControlFlowNode/0

/** Gets the basic block in which this element occurs. */
BasicBlock getBasicBlock() { result = this.getAControlFlowNode().getBasicBlock() }

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,7 @@ module ControlFlow {
}
}

/** A control flow node indicating normal termination of a callable. */
class NormalExitNode extends AnnotatedExitNode instanceof Impl::NormalExitNode { }

/** A node for a callable exit point. */
Expand Down
2 changes: 1 addition & 1 deletion csharp/ql/lib/semmle/code/csharp/dataflow/Nullness.qll
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@
}

/**
* Holds if the `node` is a dereference `d` of SSA definition `def`.
* Holds if `node` is a dereference `d` of SSA definition `def`.
*/
private predicate dereferenceAt(ControlFlow::Node node, Ssa::Definition def, Dereference d) {
d = def.getAReadAtNode(node)
Expand Down Expand Up @@ -277,7 +277,7 @@

private module NullnessFlow = Cf::ControlFlowReachability::Flow<NullnessConfig>;

predicate maybeNullDeref(Dereference d, Ssa::SourceVariable v, string msg, Element reason) {

Check warning on line 280 in csharp/ql/lib/semmle/code/csharp/dataflow/Nullness.qll

View workflow job for this annotation

GitHub Actions / qldoc

Missing QLdoc for classless-predicate Nullness::maybeNullDeref/4
exists(
Ssa::Definition origin, Ssa::Definition ssa, ControlFlow::Node src, ControlFlow::Node sink
|
Expand Down
1 change: 1 addition & 0 deletions shared/controlflow/codeql/controlflow/Cfg.qll
Original file line number Diff line number Diff line change
Expand Up @@ -1185,6 +1185,7 @@ module MakeWithSplitting<

final class AnnotatedExitNode = AnnotatedExitNodeImpl;

/** A control flow node indicating normal termination of a callable. */
final class NormalExitNode extends AnnotatedExitNodeImpl {
NormalExitNode() { this = TAnnotatedExitNode(_, true) }
}
Expand Down
Loading