Merge pull request #8255 from tausbn/python-nomagic-pattern-getcase

Python: Prevent magic/inlining in `getCase`
This commit is contained in:
yoff
2022-03-04 10:53:20 +01:00
committed by GitHub

View File

@@ -10,6 +10,7 @@ class Pattern extends Pattern_, AstNode {
override Scope getScope() { result = this.getCase().getScope() }
/** Gets the case statement containing this pattern */
pragma[nomagic]
Case getCase() { result.contains(this) }
override string toString() { result = "Pattern" }