1
0
forked from GitHub/gf-core

JS.cf : Changed the JS grammar to support strings as property names in objects. Changed pretty much all the files in the same folder as well as GFCCToJS.hs and SISR.hs to reflect the changes.

This commit is contained in:
meza
2008-04-29 13:05:24 +00:00
parent ba6a2b5d6e
commit 314f147bff
10 changed files with 148 additions and 115 deletions

View File

@@ -188,7 +188,7 @@ Expr12 : Expr13 { $1 }
Property :: { Property }
Property : Ident ':' Expr { Prop $1 $3 }
Property : PropertyName ':' Expr { Prop $1 $3 }
ListProperty :: { [Property] }
@@ -197,6 +197,11 @@ ListProperty : {- empty -} { [] }
| Property ',' ListProperty { (:) $1 $3 }
PropertyName :: { PropertyName }
PropertyName : Ident { IdentPropName $1 }
| String { StringPropName $1 }
{