mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
stdlib: coding style: add parentheses to one-argument closures for
consistency with the rest of the library Swift SVN r25036
This commit is contained in:
@@ -65,7 +65,7 @@ public struct _UnitTestArrayBuffer<T> : _ArrayBufferType {
|
||||
/// Call `body(p)`, where `p` is an `UnsafeBufferPointer` over the
|
||||
/// underlying contiguous storage.
|
||||
public func withUnsafeBufferPointer<R>(
|
||||
@noescape body: UnsafeBufferPointer<Element> -> R
|
||||
@noescape body: (UnsafeBufferPointer<Element>) -> R
|
||||
) -> R {
|
||||
let ret = body(UnsafeBufferPointer(start: self.baseAddress, count: count))
|
||||
_fixLifetime(self)
|
||||
@@ -75,7 +75,7 @@ public struct _UnitTestArrayBuffer<T> : _ArrayBufferType {
|
||||
/// Call `body(p)`, where `p` is an `UnsafeMutableBufferPointer`
|
||||
/// over the underlying contiguous storage.
|
||||
public mutating func withUnsafeMutableBufferPointer<R>(
|
||||
@noescape body: UnsafeMutableBufferPointer<T> -> R
|
||||
@noescape body: (UnsafeMutableBufferPointer<T>) -> R
|
||||
) -> R {
|
||||
let ret = body(
|
||||
UnsafeMutableBufferPointer(start: baseAddress, count: count))
|
||||
|
||||
Reference in New Issue
Block a user