Files
swift-mirror/test/ClangImporter/protocol-member-renaming.swift
Henrik G. Olsson cbc0ec3b88 Add -verify-ignore-unrelated where necessary (NFC)
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.
2025-10-04 14:19:52 -07:00

18 lines
666 B
Swift

// RUN: %target-swift-frontend -typecheck -import-objc-header %S/Inputs/protocol-member-renaming.h -verify -verify-ignore-unrelated %s
// REQUIRES: objc_interop
class Modern : NSObject, FooDelegate {
func foo(_ foo: Foo, willConsume object: Any) {}
}
class PreMigration : NSObject, FooDelegate {
func foo(_ foo: Foo, willConsumeObject object: Any) {}
// expected-error@-1 {{'foo(_:willConsumeObject:)' has been renamed to 'foo(_:willConsume:)'}} {{24-41=willConsume}}
}
class OptionalButUnavailableImpl : OptionalButUnavailable {
// Note the argument label that causes this not to match the requirement.
func doTheThing(object: Any) {} // no-warning
}