News for hackers. Stuff that matters.
Re:Pattern Matching Without Regex – Introducing the Rosie Pa... by wild_preference on Wednesday November 14, 2018 @12:41PM (#18451824)
Though to be fair it's not obvious where to encode validation. You're saying it should be intrinsic in the parsing rules of ipv4. But there are reasons why you would want to validate in a separate pass.

For example, the more errors you parse, then the better error messages and introspection you have (structured data) when you want to validate.

It's a classic trade-off.

You're right though, doesn't make a very good example.

There are no comments on this comment yet.