aksiksi / histweet

A CLI tool that simplifies managing your Twitter history.
1 stars 0 forks source link

Improve parser implementation #11

Closed aksiksi closed 3 years ago

aksiksi commented 4 years ago

Use types to encode parse nodes (more type-safe). See: https://eli.thegreenplace.net/2018/go-and-algebraic-data-types/

aksiksi commented 3 years ago

Actually, the parser might need to be rewritten. Here is a rule that should fail to parse, but doesn't:

age > 3m && likes >= 34) || text !~ \"xyz\"

aksiksi commented 3 years ago

Kind of closed by b821c50599ad70e0e4ca970319d8b4a09f1e73fd.