mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Creating accessors for a storage declaration within validateDecl() caused circular dependencies detected by the request-evaluator. Separate out accessor creation to break the dependency. Fixes SR-8656 / rdar://problem/43951634.
26 lines
436 B
Swift
26 lines
436 B
Swift
// RUN: %target-typecheck-verify-swift -debug-cycles > %t.log 2>&1
|
|
// RUN: not grep "CYCLE DETECTED" %t.log | count 0
|
|
|
|
// REQUIRES: objc_interop
|
|
|
|
// Verify that isObjC computation doesn't cause cyclic dependencies.
|
|
|
|
// expected-no-diagnostics
|
|
|
|
class A {
|
|
@objc func foo() { }
|
|
}
|
|
|
|
|
|
@objc class B {
|
|
@objc dynamic subscript(i: Int) -> B {
|
|
return self
|
|
}
|
|
}
|
|
|
|
class C: B {
|
|
override subscript(i: Int) -> B {
|
|
return super[i]
|
|
}
|
|
}
|