Python move various theXXX() predicates into the appropriate module.

This commit is contained in:
Mark Shannon
2019-01-18 14:27:23 +00:00
parent 2dea0b4270
commit 35fa5d8f60
30 changed files with 211 additions and 126 deletions

View File

@@ -67,9 +67,9 @@ predicate subscript(Stmt s) {
predicate encode_decode(Expr ex, ClassObject type) {
exists(string name |
ex.(Call).getFunc().(Attribute).getName() = name |
name = "encode" and type = builtin_object("UnicodeEncodeError")
name = "encode" and type = Object::builtin("UnicodeEncodeError")
or
name = "decode" and type = builtin_object("UnicodeDecodeError")
name = "decode" and type = Object::builtin("UnicodeDecodeError")
)
}