如何在Swift 4中记录函数可选闭包参数的参数?
假设您有一个接受可选闭包作为参数的方法。例如,
/// An example function.
/// Documentation goes here.
///
/// - Parameters:
/// - optionalClosure: An optional closure.
/// - aClosureParameter: This will not be displayed.
func exampleMethod(optionalClosure: ((_ aClosureParameter: Bool) -> Void)?) {
// Do something
}
不会被记录。如何记录可选闭包参数?