Skip to content

Commit e0fd4b6

Browse files
committed
Add new test case for recovery
1 parent 24fc5ea commit e0fd4b6

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

Tests/SwiftParserTest/translated/RecoveryTests.swift

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2206,4 +2206,20 @@ final class RecoveryTests: XCTestCase {
22062206
)
22072207
}
22082208

2209+
func testRecovery182() {
2210+
AssertParse(
2211+
"func foo() 1️⃣bogus {}",
2212+
diagnostics: [
2213+
DiagnosticSpec(message: "unexpected code 'bogus' in function")
2214+
]
2215+
)
2216+
2217+
AssertParse(
2218+
"func foo() 1️⃣bogus -> Int {}",
2219+
diagnostics: [
2220+
DiagnosticSpec(message: "unexpected code 'bogus' in function signature")
2221+
]
2222+
)
2223+
}
2224+
22092225
}

0 commit comments

Comments
 (0)