- or download this
#!/usr/bin/perl --
use strict; use warnings;
use File::Slurp;
...
$ret ;
}
__END__
- or download this
$ cat core.abnf
BIT = "0" / "1"
CR = %d13
...
CR = %b1101
CRLF = CR LF
LF = %x0A
- or download this
$ perl abnf.to.grammars.pl core.abnf
<rule: BIT> 0 | 1
<rule: CR> \15
...
<rule: CR> \15
<rule: CRLF> (?: <CR><LF> )
<rule: LF> \x0A