[antlr-interest] Bash Grammer

Andy Tripp antlr at jazillian.com
Thu May 11 07:53:30 PDT 2006


A quick google for "shell grammar parser" lead to this...
http://compilers.iecc.com/comparch/article/05-10-058

...which leads to a mention of a bash-like shell called 'rc', part of 
plan9, which has
a grammar written in yacc:
http://plan9.bell-labs.com/sys/doc/rc.pdf

...and plan9 source seems to be available under an OSI-approved license:
http://plan9.bell-labs.com/plan9/download.html

How did we ever find anything before google? :)
Andy

Sohail Somani wrote:

>Phew, I thought I was the only one :)
>
>On Thu, 2006-05-11 at 15:55 +0200, Martin Probst wrote:
>  
>
>>Hi,
>>
>>I've not heard of one and there is none on the ANTLR grammar page.  
>>However I would think that this might be the most horrible language  
>>to parse on earth. There is nothing as inconsequent, ambiguous and  
>>plain senseless as the standard "sh" language. I would really pity  
>>anyone having to write a grammar for that.
>>
>>Martin
>>
>>Am 11.05.2006 um 14:03 schrieb Henry Butowsky:
>>
>>    
>>
>>>Hi Guys,
>>>Out of interst has anybody done a bash (sh)  grammer with  ANTLR --
>>>Could be an interesting project ?
>>>
>>>Regards Henry
>>>
>>>
>>>      
>>>
>
>  
>



More information about the antlr-interest mailing list