Files
swift-mirror/test/Serialization/Inputs/inherited-conformance-user.swift
Robert Widmann f97e5dcb0e [SE-0115][1/2] Rename *LiteralConvertible protocols to ExpressibleBy*Literal. This
change includes both the necessary protocol updates and the deprecation
warnings
suitable for migration.  A future patch will remove the renamings and
make this
a hard error.
2016-07-12 15:25:24 -07:00

25 lines
476 B
Swift

import Base
import Lib
// Instantiate Counter<Int>, relying on Counter's adoption of SimpleProto.
public struct OneToAThousand : ProtoUser {
public typealias Impl = Counter<Int>
public var start: Impl {
return Impl(value: 1)
}
public var end: Impl {
return Impl(value: 1001)
}
public subscript(i: Impl) -> Int {
return i.value
}
public init() {}
}
public protocol SpecialProto : ExpressibleByIntegerLiteral {}
extension Int : SpecialProto {}