Skip to content

Commit 2efa38a

Browse files
committed
Python: fix typos in comments
1 parent 2ed42c3 commit 2efa38a

File tree

13 files changed

+20
-20
lines changed

13 files changed

+20
-20
lines changed

python/ql/lib/semmle/python/Import.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ class Import extends Import_ {
184184
* For example, for the import statement `import bar` which
185185
* is a relative import in package "foo", this would return
186186
* "foo.bar".
187-
* The import statment `from foo import bar` would return
187+
* The import statement `from foo import bar` would return
188188
* `foo` and `foo.bar`
189189
*/
190190
string getAnImportedModuleName() {

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ module ArgumentPassing {
172172
/**
173173
* Gets the node representing the argument to `call` that is passed to the parameter at
174174
* (zero-based) index `paramN` in `callable`. If this is a positional argument, it must appear
175-
* at an index, `argN`, in `call` wich satisfies `paramN = mapping.getParamN(argN)`.
175+
* at an index, `argN`, in `call` which satisfies `paramN = mapping.getParamN(argN)`.
176176
*
177177
* `mapping` will be the identity for function calls, but not for method- or constructor calls,
178178
* where the first parameter is `self` and the first positional argument is passed to the second positional parameter.

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -305,7 +305,7 @@ cached
305305
private module Cached {
306306
/**
307307
* If needed, call this predicate from `DataFlowImplSpecific.qll` in order to
308-
* force a stage-dependency on the `DataFlowImplCommon.qll` stage and therby
308+
* force a stage-dependency on the `DataFlowImplCommon.qll` stage and thereby
309309
* collapsing the two stages.
310310
*/
311311
cached

python/ql/lib/semmle/python/dataflow/old/StateTracking.qll

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,29 +45,29 @@ abstract class TrackableState extends string {
4545
/**
4646
* Holds if state starts at `f`.
4747
* Either this predicate or `startsAt(ControlFlowNode f, Context ctx)`
48-
* should be overriden by sub-classes.
48+
* should be overridden by sub-classes.
4949
*/
5050
predicate startsAt(ControlFlowNode f) { none() }
5151

5252
/**
5353
* Holds if state starts at `f` given context `ctx`.
5454
* Either this predicate or `startsAt(ControlFlowNode f)`
55-
* should be overriden by sub-classes.
55+
* should be overridden by sub-classes.
5656
*/
5757
pragma[noinline]
5858
predicate startsAt(ControlFlowNode f, Context ctx) { ctx.appliesTo(f) and this.startsAt(f) }
5959

6060
/**
6161
* Holds if state ends at `f`.
6262
* Either this predicate or `endsAt(ControlFlowNode f, Context ctx)`
63-
* may be overriden by sub-classes.
63+
* may be overridden by sub-classes.
6464
*/
6565
predicate endsAt(ControlFlowNode f) { none() }
6666

6767
/**
6868
* Holds if state ends at `f` given context `ctx`.
6969
* Either this predicate or `endsAt(ControlFlowNode f)`
70-
* may be overriden by sub-classes.
70+
* may be overridden by sub-classes.
7171
*/
7272
pragma[noinline]
7373
predicate endsAt(ControlFlowNode f, Context ctx) { ctx.appliesTo(f) and this.endsAt(f) }

python/ql/lib/semmle/python/frameworks/Aiomysql.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ private module Aiomysql {
2525
/**
2626
* Gets a `Connection` that is created when
2727
* - the result of `aiomysql.connect()` is awaited.
28-
* - the result of calling `aquire` on a `ConnectionPool` is awaited.
28+
* - the result of calling `acquire` on a `ConnectionPool` is awaited.
2929
* See https://aiomysql.readthedocs.io/en/stable/connection.html#connection
3030
*/
3131
API::Node connection() {
@@ -82,7 +82,7 @@ private module Aiomysql {
8282
}
8383

8484
/**
85-
* Gets an `SAConnection` that is created when the result of calling `aquire` on an `Engine` is awaited.
85+
* Gets an `SAConnection` that is created when the result of calling `acquire` on an `Engine` is awaited.
8686
* See https://aiomysql.readthedocs.io/en/stable/sa.html#connection
8787
*/
8888
API::Node saConnection() { result = engine().getMember("acquire").getReturn().getAwaited() }

python/ql/lib/semmle/python/frameworks/Aiopg.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ private module Aiopg {
2525
/**
2626
* Gets a `Connection` that is created when
2727
* - the result of `aiopg.connect()` is awaited.
28-
* - the result of calling `aquire` on a `ConnectionPool` is awaited.
28+
* - the result of calling `acquire` on a `ConnectionPool` is awaited.
2929
* See https://aiopg.readthedocs.io/en/stable/core.html#connection
3030
*/
3131
API::Node connection() {
@@ -78,7 +78,7 @@ private module Aiopg {
7878
}
7979

8080
/**
81-
* Gets an `SAConnection` that is created when the result of calling `aquire` on an `Engine` is awaited.
81+
* Gets an `SAConnection` that is created when the result of calling `acquire` on an `Engine` is awaited.
8282
* See https://aiopg.readthedocs.io/en/stable/sa.html#connection
8383
*/
8484
API::Node saConnection() { result = engine().getMember("acquire").getReturn().getAwaited() }

python/ql/lib/semmle/python/frameworks/Asyncpg.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ private module Asyncpg {
2020
/**
2121
* Gets a `Connection` that is created when
2222
* - the result of `asyncpg.connect()` is awaited.
23-
* - the result of calling `aquire` on a `ConnectionPool` is awaited.
23+
* - the result of calling `acquire` on a `ConnectionPool` is awaited.
2424
*/
2525
API::Node connection() {
2626
result = API::moduleImport("asyncpg").getMember("connect").getReturn().getAwaited()
@@ -69,7 +69,7 @@ private module Asyncpg {
6969
* Provides models of the `PreparedStatement` class in `asyncpg`.
7070
* `PreparedStatement`s are created when the result of calling `prepare(query)` on a connection is awaited.
7171
* The result of calling `prepare(query)` is a `PreparedStatementFactory` and the argument, `query` needs to
72-
* be tracked to the place where a `PreparedStatement` is created and then futher to any executing methods.
72+
* be tracked to the place where a `PreparedStatement` is created and then further to any executing methods.
7373
* Hence the two type trackers.
7474
*/
7575
module PreparedStatement {

python/ql/lib/semmle/python/objects/TObject.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ predicate class_method(
243243
* Holds if the literal corresponding to the control flow node `n` has class `cls`.
244244
*
245245
* Helper predicate for `literal_instantiation`. Prevents a bad join with
246-
* `PointsToContext::appliesTo` from occuring.
246+
* `PointsToContext::appliesTo` from occurring.
247247
*/
248248
pragma[nomagic]
249249
private predicate literal_node_class(ControlFlowNode n, ClassObjectInternal cls) {

python/ql/lib/semmle/python/security/BadTagFilterQuery.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,14 @@ private module RegexpMatching {
2828
* but if `ignorePrefix` is true, it will only match "foo".
2929
*/
3030
predicate test(string str, boolean ignorePrefix) {
31-
none() // maybe overriden in subclasses
31+
none() // maybe overridden in subclasses
3232
}
3333

3434
/**
3535
* Same as `test(..)`, but where the `fillsCaptureGroup` afterwards tells which capture groups were filled by the given string.
3636
*/
3737
predicate testWithGroups(string str, boolean ignorePrefix) {
38-
none() // maybe overriden in subclasses
38+
none() // maybe overridden in subclasses
3939
}
4040

4141
/**

python/ql/lib/semmle/python/security/performance/ExponentialBackTracking.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
* either a single character, a set of characters represented by a
5252
* character class, or the set of all characters.
5353
* * The product automaton is constructed lazily, starting with pair states
54-
* `(q, q)` where `q` is a fork, and proceding along an over-approximate
54+
* `(q, q)` where `q` is a fork, and proceeding along an over-approximate
5555
* step relation.
5656
* * The over-approximate step relation allows transitions along pairs of
5757
* abstract input symbols where the symbols have overlap in the characters they accept.

0 commit comments

Comments
 (0)