mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
These are tests that fail in the next commit without this flag. This does not add -verify-ignore-unrelated to all tests with -verify, only the ones that would fail without it. This is NFC since this flag is currently a no-op.
24 lines
879 B
Swift
24 lines
879 B
Swift
// RUN: %empty-directory(%t)
|
|
// RUN: %target-swift-frontend -emit-module -o %t/Lib.swiftmodule %S/Inputs/attr_usableFromInline_protocol_hole_helper.swift
|
|
// RUN: %target-typecheck-verify-swift -verify-ignore-unrelated -I %t -verify-ignore-unknown
|
|
|
|
import Lib
|
|
|
|
func test(_ obj: PublicProtocol) {
|
|
obj.publicExtensionMethod()
|
|
obj.ufiExtensionMethod() // expected-error {{inaccessible}}
|
|
obj.internalExtensionMethod() // expected-error {{inaccessible}}
|
|
}
|
|
|
|
func test(_ obj: PublicImpl) {
|
|
obj.publicExtensionMethod()
|
|
obj.ufiExtensionMethod() // expected-error {{inaccessible}}
|
|
obj.internalExtensionMethod() // expected-error {{inaccessible}}
|
|
}
|
|
|
|
func test(_ obj: UFIImpl) {
|
|
obj.publicExtensionMethod() // This being accessible is the "hole".
|
|
obj.ufiExtensionMethod() // expected-error {{inaccessible}}
|
|
obj.internalExtensionMethod() // expected-error {{inaccessible}}
|
|
}
|