bison-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Named symbol references


From: Joel E. Denny
Subject: Re: [PATCH] Named symbol references
Date: Wed, 18 Feb 2009 21:10:46 -0500 (EST)

On Wed, 18 Feb 2009, Akim Demaille wrote:

> >>> "JED" == Joel E Denny <address@hidden> writes:

>  > Your requirement that $$ and @$ always be used for the LHS somehow feels 
>  > cleaner to me at the moment.  I think I can train my brain to ignore the 
>  > LHS symbol name when I see the $exp or $term in your examples:
> 
>  >   exp : exp { $$ = $exp; }[left] + exp[right] { $$ = $<type>left + $right; 
> }
> 
>  >   term: term '*' fact { $$ = $term * $fact; } ;
> 
>  > Does this bother anyone?
> 
> I am not really comfortable with that, but I can live with it.

The more I've thought about it since writing that email, the more I've 
leaned the other way.  Maybe it's sometimes a nice convention that the LHS 
value is always written as $$.  Then again, maybe it's sometimes more 
expressive and more consistent if the LHS value uses an alphabetical name 
just as all the RHS values do.  Besides, my intuition strongly suggests 
that the $exp and $term in the above examples are ambiguous.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]