News for hackers. Stuff that matters.
Re:Don't Use ISO/IEC 14977:1996 Extended Backus-Naur Form (E... by alfiedotwtf on Monday May 19, 2025 @10:05PM (#44037078)
So if not EBNF for defining grammars, what should people be using ie what would be your preferred that would be powerfully enough and general purpose?

I’ve never seen PCRE used for grammars and not sure if it would be powerfully enough for all cases, but personally I think it would be pretty cool since I find it easier to read than EBNF and it’s so widely used people can slot a specification right into code and it should just work

Re:Don't Use ISO/IEC 14977:1996 Extended Backus-Naur Form (E... by dwheeler on Tuesday May 20, 2025 @07:20AM (#44040229)
One of those alternative specifications is in the W3C Extensible Markup Language (XML) 1.0 (Fifth Edition). As I note, "The W3C specification is much more similar to typical regex syntax making it much easier for today's software developers to understand), avoids the key problems of 14977:1996, and is already clearly described." It's freely available from w3c. You don't need to use XML to use it.
Re:Don't Use ISO/IEC 14977:1996 Extended Backus-Naur Form (E... by alfiedotwtf on Wednesday May 21, 2025 @03:17AM (#44049081)
Oops, sorry. When you said that I thought there was going to be an actual specification of the grammar specification itself rather than the application in use. Ok cool, got it thanks :)