Skip to content

Commit 7b15d0d

Browse files
committed
Add a Test Case for #687
This appears to have been resolved at some point in the past. rdar://99453979
1 parent 745922f commit 7b15d0d

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

Tests/SwiftParserTest/Declarations.swift

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,16 @@ final class DeclarationTests: XCTestCase {
3232
}
3333
"""
3434
)
35+
36+
AssertParse("""
37+
func #^DIAG1^#where
38+
r#^DIAG2^#
39+
""",
40+
diagnostics: [
41+
DiagnosticSpec(locationMarker: "DIAG1", message: "Expected '' in function"),
42+
DiagnosticSpec(locationMarker: "DIAG1", message: "Expected argument list in function declaration"),
43+
DiagnosticSpec(locationMarker: "DIAG2", message: "Expected '=' in same type requirement"),
44+
])
3545
}
3646

3747
func testClassParsing() {

0 commit comments

Comments
 (0)