Files
swift-mirror/validation-test/compiler_crashers_2_fixed/sr11062.swift
Doug Gregor d74a24be37 [AST] Look through ConstructorRefCallExpr to find direct callee.
Fixes SR-11062 / rdar://problem/54141935
2019-09-13 22:37:43 -07:00

28 lines
523 B
Swift

// RUN: %target-swift-frontend -emit-ir %s
struct MyText<V> {
let label: String
let value: V
}
extension MyText where V == Void {
init(_ label: String, defaulted: Int = 17) {
self.label = label
self.value = ()
}
}
struct ImagePulse {
@Inspectable(control: { MyText("duration") })
var test: Double = 0
}
@propertyWrapper
final class Inspectable<Value> {
var wrappedValue: Value
init<V>(wrappedValue initialValue: Value, control: @escaping () -> V) {
self.wrappedValue = initialValue
}
}