mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
This reverts commits:b96e06da44,8f2fbdc93a,93b6962478,64024118f4,a759ca9141,3434f9642b,9f33429891,47c043e8a6. This commit leaves 'var' on function parameters as a warning to be merged into Swift 2.2. For Swift 3, this will be an error, to be converted in a follow-up.
23 lines
445 B
Swift
23 lines
445 B
Swift
// RUN: %target-swift-frontend %s -emit-ir
|
|
|
|
// REQUIRES: objc_interop
|
|
|
|
// Distributed under the terms of the MIT license
|
|
// Test case submitted to project by https://github.com/practicalswift (practicalswift)
|
|
// http://www.openradar.me/18756378
|
|
|
|
import Foundation
|
|
enum A<T : AnyObject> {
|
|
case E(T)
|
|
}
|
|
class B {
|
|
}
|
|
func c(d : A<B>) {
|
|
switch (d) {
|
|
case .E(var e):
|
|
print("")
|
|
default:
|
|
print("")
|
|
}
|
|
}
|