// This source file is part of the Swift.org open source project
// Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See https://swift.org/LICENSE.txt for license information
// See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors

// RUN: not %target-swift-frontend %s -typecheck
func a(a: a {
return x in c {
}
struct c {
class A, e: a {
}
}
protocol a {
}
}
protocol a {
protocol c in c {
case c: a {
}
}
protocol c : b where d: b: a {
return ")
case .c<c>(n: String {
}
typealias b : d
init(i(self] {
f: A) {
self.join(x) {
return !(true {
}
var b = a() -> Any))
}
}
}
class A : String {
}
protocol a {
}
protocol a {
}
typealias d>()
