Files
swift-mirror/validation-test/compiler_crashers_2_fixed/0138-rdar36453271.swift
Doug Gregor 597c955948 [Associated type inference] Find tentative type witnesses across protocol hierarchy.
As a minor step toward more global associated type inference,
allow tentative type witnesses to be found across a protocol
hierarchy, eliminating some recursion through associated type
inference. Fixes a recent regression in validation-test/stdlib/CollectionTypes.swift, as well as rdar://problem/36453271.
2018-01-24 23:01:21 -08:00

14 lines
387 B
Swift

// RUN: %target-swift-frontend %s -emit-ir -o 0
extension Slice where Base == UnsafeBufferPointer<UInt16> {
var rebased: UnsafeBufferPointer<UInt16> {
return UnsafeBufferPointer(rebasing: self)
}
}
extension Slice where Base == UnsafeMutableBufferPointer<UInt16> {
var rebased: UnsafeMutableBufferPointer<UInt16> {
return UnsafeMutableBufferPointer(rebasing: self)
}
}