Files
swift-mirror/validation-test/compiler_crashers_fixed/27291-swift-modulefile-getdeclcontext.swift
Slava Pestov f6e4355b69 Sema: Fix monthly TypeNullifier bug
This time, the issue is that TypeNullifier skips bodies of
multi-statement closures. However, ExprRewriter will type
happily pass them on to typeCheckClosureBody(). This could
trigger assertions. Fix this by skipping type checking of
multi-statement closures when diagnosing.

There seems to be a minor QoI regression in some test cases
that already looked pretty dodgy and/or had FIXMEs. However
I think its worth fixing a crash.
2015-12-11 08:58:52 -08:00

8 lines
381 B
Swift

// RUN: not %target-swift-frontend %s -parse
// Distributed under the terms of the MIT license
// Test case submitted to project by https://github.com/practicalswift (practicalswift)
// Test case found by fuzzing
class a{{}class a{struct S<k:CollectionType}}struct c{struct c<T where H:d{struct i{enum S{struct d{class B{let f=c{struct S{class B<T where T=a{enum B{var f=B{class