mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Fix a bug with cross-file uses of the synthesized _foo/$foo for properties with attached wrappers by implicitly triggering the appropriate synthesis during name lookup. Fixes rdar://problem/51725203.
10 lines
357 B
Swift
10 lines
357 B
Swift
// RUN: %target-swift-frontend -typecheck -verify -primary-file %s %S/Inputs/rdar51725203.swift
|
|
|
|
func test(sm: StructModel, cm: ClassModel) {
|
|
_ = sm.$foo
|
|
_ = cm.$foo
|
|
|
|
_ = sm._bar // expected-error{{'_bar' is inaccessible due to 'private' protection level}}
|
|
_ = cm._bar // expected-error{{'_bar' is inaccessible due to 'private' protection level}}
|
|
}
|