Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 35c7fa5

Browse files
committed
joiner order fixes
1 parent 88e8969 commit 35c7fa5

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

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

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import python
22
private import semmle.python.types.Builtins
3+
private import semmle.python.internal.CachedStages
34

45
/**
56
* An alias in an import statement, the `mod as name` part of `import mod as name`. May be artificial;
@@ -203,7 +204,9 @@ class Import extends Import_ {
203204
/** An import * statement */
204205
class ImportStar extends ImportStar_ {
205206
/* syntax: from modname import * */
207+
cached
206208
ImportExpr getModuleExpr() {
209+
Stages::AST::ref() and
207210
result = this.getModule()
208211
or
209212
result = this.getModule().(ImportMember).getModule()

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

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,7 @@ module Value {
263263
* object of that name.
264264
* For example `Value::named("len")` is the `Value` representing the `len` built-in function.
265265
*/
266+
pragma[nomagic]
266267
Value named(string name) {
267268
exists(string modname, string attrname | name = modname + "." + attrname |
268269
result = Module::named(modname).attr(attrname)

0 commit comments

Comments
 (0)