// RUN: %target-swift-frontend -emit-ir %s public func withOptionalsAsPointers( _ optional: repeat Optional, body: (repeat UnsafePointer?) throws -> T ) rethrows -> T { return try body(repeat (each optional).map { withUnsafePointer(to: $0) { $0 } }) }