[ExI] The tyranny of context free grammars

Eugen Leitl eugen at leitl.org
Tue Dec 7 20:01:42 UTC 2010


On Tue, Dec 07, 2010 at 11:13:03AM -0700, Keith Henson wrote:

> I agree with Ryan that Perl (and Forth) are nearly impossible to

It is quite possible to write very readable, verbose Perl.
It is also quite possible to write extremely terse, incomprehensible
Perl.

Forth isn't really a good comparison, because you typically implement
a DSL in Forth, which then can have arbitrary syntax.

Consider the following Forth sources written for this minimal
CPU (defined in VeriLog:
http://excamera.com/files/j1demo/verilog/j1.v )

This implements the basic Forth words from primitives:
http://excamera.com/files/j1demo/docforth/basewords.fs.html

This is an Ethernet driver:
http://excamera.com/files/j1demo/docforth/eth-ax88796.fs.html

ARP: http://excamera.com/files/j1demo/docforth/arp.fs.html

IP: http://excamera.com/files/j1demo/docforth/ip.fs.html

UDP: http://excamera.com/files/j1demo/docforth/udp.fs.html

etc, see http://excamera.com/sphinx/fpga-j1.html

> maintain.  That's because it's nearly impossible to read code and
> figure out what it does.

Only if the programmer is trying to be too clever for their
own good.

-- 
Eugen* Leitl <a href="http://leitl.org">leitl</a> http://leitl.org
______________________________________________________________
ICBM: 48.07100, 11.36820 http://www.ativel.com http://postbiota.org
8B29F6BE: 099D 78BA 2FD3 B014 B08A  7779 75B0 2443 8B29 F6BE



More information about the extropy-chat mailing list