Compiles:
struct Foo {
var g: Double = 5.0
}
struct Bar {
var h: Double = 5.0
var foo = Foo()
}
var bar = Bar(h: 6)
Add "private" and no longer compiles, with above error in title:
struct Foo {
var g: Double = 5.0
}
struct Bar {
var h: Double = 5.0
private var foo = Foo()
}
var bar = Bar(h: 6) // compiler error on this line
Why would that be?