Skip to content

Commit 70d47f3

Browse files
yoffRasmusWL
andauthored
Apply suggestions from code review
Co-authored-by: Rasmus Wriedt Larsen <rasmuswriedtlarsen@gmail.com>
1 parent 441fc1b commit 70d47f3

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

python/ql/lib/semmle/python/ApiGraphs.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,7 @@ module API {
245245

246246
/**
247247
* Gets a node representing a subscript of this node.
248+
* For example `obj[x]` is a subscript of `obj`.
248249
*/
249250
Node getASubscript() { result = this.getASuccessor(Label::subscript()) }
250251

@@ -575,7 +576,6 @@ module API {
575576
* API graph node for the prefix `foo`), in accordance with the usual semantics of Python.
576577
*/
577578

578-
// private import semmle.python.internal.Awaited
579579
cached
580580
newtype TApiNode =
581581
/** The root of the API graph. */
@@ -1067,7 +1067,7 @@ module API {
10671067
override string toString() { result = "getAwaited()" }
10681068
}
10691069

1070-
/** A label that gets the subscript of a sequence. */
1070+
/** A label that gets the subscript of a sequence/mapping. */
10711071
class LabelSubscript extends ApiLabel, MkLabelSubscript {
10721072
override string toString() { result = "getSubscript()" }
10731073
}

python/ql/lib/semmle/python/dataflow/new/internal/LocalSources.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ private module Cached {
249249
}
250250

251251
/**
252-
* Holds if `node` flows to a sequence of which `subscript` is a subscript.
252+
* Holds if `node` flows to a sequence/mapping of which `subscript` is a subscript.
253253
*/
254254
cached
255255
predicate subscript(LocalSourceNode node, CfgNode subscript) {

0 commit comments

Comments
 (0)