blob: e1e08099f18caa865c10bdfd8e48373e62b49748 [file] [log] [blame]
// RUN: %target-swift-frontend %s -emit-ir
class IndexPath {
init(indexes: [Int]) {}
}
extension CountableRange where Bound == Int {
func indexPaths(inSection section: Bound) -> [IndexPath] {
return reduce([]) { $0 + [IndexPath(indexes: [section, $1])] }
}
}