for example: var a = 1
let block = { [inout a] in a += 1 } block() block() print(a) // 3 _______________________________________________ swift-evolution mailing list swift-evolution@swift.org https://lists.swift.org/mailman/listinfo/swift-evolution
Cao Jiannan via swift-evolution Wed, 05 Oct 2016 21:08:53 -0700
for example: var a = 1
let block = { [inout a] in a += 1 } block() block() print(a) // 3 _______________________________________________ swift-evolution mailing list swift-evolution@swift.org https://lists.swift.org/mailman/listinfo/swift-evolution