Skip to content

Commit 38af324

Browse files
committed
Merge pull request #396 from practicalswift/sync-with-swift-compiler-crashes-20151210b
Sync with https://github.com/practicalswift/swift-compiler-crashes
2 parents c5d3b85 + 159d58d commit 38af324

6 files changed

+49
-1
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
// RUN: not --crash %target-swift-frontend %s -emit-silgen
2+
// Distributed under the terms of the MIT license
3+
// Test case submitted to project by https://github.com/practicalswift (practicalswift)
4+
// http://www.openradar.me/19423783
5+
6+
protocol A {
7+
var a: Int {
8+
get
9+
}
10+
}
11+
class B: A {
12+
let a = 42
13+
}
14+
let b = B()
15+
let c = [b]
16+
let d = c as [A]
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// RUN: not --crash %target-swift-frontend %s -c -o /dev/null
2+
// Distributed under the terms of the MIT license
3+
// Test case submitted to project by https://github.com/codafi (Robert Widmann)
4+
5+
struct X<T> {
6+
let s : X<X>
7+
}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
// RUN: not --crash %target-swift-frontend %s -parse
2+
// Distributed under the terms of the MIT license
3+
// Test case submitted to project by https://github.com/adocyn (adocyn)
4+
5+
extension CollectionType {
6+
func f<T where T=Generator>() {
7+
}
8+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// RUN: not --crash %target-swift-frontend %s -emit-silgen
2+
// Distributed under the terms of the MIT license
3+
// Test case submitted to project by https://github.com/airspeedswift (airspeedswift)
4+
5+
["1"].map { String($0) }
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
// RUN: not --crash %target-swift-frontend %s -emit-silgen
2+
// Distributed under the terms of the MIT license
3+
// Test case submitted to project by https://github.com/airspeedswift (airspeedswift)
4+
5+
struct S<T> {
6+
var a: [T] = []
7+
}
8+
extension S {
9+
init(other: [T]) {
10+
a = other
11+
}
12+
}

validation-test/compiler_crashers/README

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@ SOFTWARE.
2424
Repository: https://github.com/practicalswift/swift-compiler-crashes.git
2525
Web URL: https://github.com/practicalswift/swift-compiler-crashes
2626

27-
Tests updated as of revision 736d5c8bee75f676ff3750e4ad3165d81059fe03
27+
Tests updated as of revision 26d1d4cb0a23cc55722a153b82f4f8ab9f8f4653

0 commit comments

Comments
 (0)