Hi,
Swift 3.0.2 seems to have broken my code due to mutating self capture. But I
have to pass inout self to the closure. Any workaround?
let blockSize = min(512, count)
let blockCount = (count+blockSize-1)/blockSize
device.sync { // Launch CUDA kernel
try! fill<<<(blockSize, blockCount)>>>[
.pointer(to: &self), .value(value), .value(Int64(count))
]
}
-Richard
_______________________________________________
swift-users mailing list
swift-users@swift.org
https://lists.swift.org/mailman/listinfo/swift-users