Files
swift-mirror/validation-test/compiler_crashers_fixed/00323-swift-apply-generic-protocol.swift
practicalswift c4866885c8 Rename old crash cases to match the current naming scheme.
Will allow for easy import of crash cases from swift-compiler-crashes.
2015-12-10 16:50:15 +01:00

16 lines
425 B
Swift

// RUN: %target-swift-frontend %s -emit-sil -verify
// Distributed under the terms of the MIT license
// Test case submitted to project by http://github.com/valfer (Valerio Ferrucci)
protocol C {
static func c(o: AnyObject) -> Self?
}
func d<A,B>(a : A, _ f : A -> B) -> B {
} // expected-error {{missing return in a function expected to return 'B'}}
class D<A:C> {
func e(o: AnyObject) {
d(o, A.c)
}
}