Plurrrr

Fri 17 Dec 2021

A Beginner's Guide to Parsing in Rust

Parsers are crucial for many data processing tasks. Contrary to what appearances might imply, writing a parser from scratch is not difficult given the right starting point. This article presents a flexible system for writing custom parsers for a wide range of languages. It assumes some experience with Rust, but no experience with language theory. More experienced readers might want to skip directly to the Lyn crate.

Source: A Beginner's Guide to Parsing in Rust, an article by Richard L. Apodaca.

Rust Error Handling

Error handling in Rust has been a topic of discussion for years. There's a working group devoted to it (announcement here) that seems active, but to be honest I haven't heard a lot from them (naturally, a few days after I wrote this, they popped-up on Reddit). There has, however, been a steady stream of articles & posts about best practices in this regard. I surveyed them while reconsidering my own error-handling strategy for mpdpopm & found myself taking pieces from each, but no one author really captured my thinking. With this, I throw my own thoughts on the pile.

Source: Rust Error Handling.