26 Followers
46 Following
7 Posts
Tools engineer at a large fruit company.
@eniko @thephd We’ve recently been rewriting the Swift parser, and have some opinions on how to do this well: good parser primitives (“expect this”, “match this”, “don’t go beyond that”, etc.), no diagnostics from parsing itself (represent all issues as missing/unexpected nodes in the tree), and handle diagnostics in a post-pass. The result is really nice and is easy to extend to@new grammar terms. See https://github.com/apple/swift-syntax/blob/main/Sources/SwiftParser/SwiftParser.docc/ParserRecovery.md
swift-syntax/ParserRecovery.md at main · apple/swift-syntax

A set of Swift libraries for parsing, inspecting, generating, and transforming Swift source code. - swift-syntax/ParserRecovery.md at main · apple/swift-syntax

GitHub
For a presumably fleeting moment, it appears #swift on here will get you programming posts not pop star news. Follow it while it lasts!