Skip to content

Commit fef5a49

Browse files
committed
Swift: Remove now duplicate extension logic.
1 parent 34240f7 commit fef5a49

File tree

1 file changed

+0
-16
lines changed

1 file changed

+0
-16
lines changed

swift/ql/lib/codeql/swift/dataflow/ExternalFlow.qll

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -417,14 +417,6 @@ private Element interpretElement0(
417417
subtypes = true and
418418
declWithMethod.asNominalTypeDecl() = namedTypeDecl.getADerivedTypeDecl*()
419419
or
420-
// member declared in a type that's extended with a protocol that is the named type
421-
exists(ExtensionDecl e |
422-
e.getExtendedTypeDecl().getADerivedTypeDecl*() = declWithMethod.asNominalTypeDecl()
423-
|
424-
subtypes = true and
425-
e.getAProtocol() = namedTypeDecl.getADerivedTypeDecl*()
426-
)
427-
or
428420
// member declared directly in the named type (or an extension of it)
429421
subtypes = false and
430422
declWithMethod.asNominalTypeDecl() = namedTypeDecl
@@ -442,14 +434,6 @@ private Element interpretElement0(
442434
subtypes = true and
443435
declWithField.asNominalTypeDecl() = namedTypeDecl.getADerivedTypeDecl*()
444436
or
445-
// field declared in a type that's extended with a protocol that is the named type
446-
exists(ExtensionDecl e |
447-
e.getExtendedTypeDecl().getADerivedTypeDecl*() = declWithField.asNominalTypeDecl()
448-
|
449-
subtypes = true and
450-
e.getAProtocol() = namedTypeDecl.getADerivedTypeDecl*()
451-
)
452-
or
453437
// field declared directly in the named type (or an extension of it)
454438
subtypes = false and
455439
declWithField.asNominalTypeDecl() = namedTypeDecl

0 commit comments

Comments
 (0)