+/* }}} */
+
+/* Cycript: @class Declaration {{{ */
+ClassSuperOpt
+ : ":" MemberExpressionNoBF { $$ = $2; }
+ | { $$ = NULL; }
+ ;
+
+ClassFieldList
+ : "{" "}" { $$ = NULL; }
+ ;
+
+MessageScope
+ : "+" { $$ = false; }
+ | "-" { $$ = true; }
+ ;
+
+TypeOpt
+ : "(" Expression ")" { $$ = $2; }
+ | { $$ = NULL; }
+ ;
+
+MessageParameter
+ : Word ":" TypeOpt Identifier { $$ = new(driver.pool_) CYMessageParameter($1, $3, $4); }
+ ;
+
+MessageParameterListOpt
+ : MessageParameterList { $$ = $1; }
+ | { $$ = NULL; }
+ ;
+
+MessageParameterList
+ : MessageParameter MessageParameterListOpt { $1->SetNext($2); $$ = $1; }
+ ;
+
+MessageParameters
+ : MessageParameterList { $$ = $1; }
+ | Word { $$ = new(driver.pool_) CYMessageParameter($1, NULL, NULL); }
+ ;
+
+ClassMessageDeclaration
+ : MessageScope TypeOpt MessageParameters "{" FunctionBody "}" { $$ = new(driver.pool_) CYMessage($1, $2, $3, $5); }
+ ;
+
+ClassMessageDeclarationListOpt
+ : ClassMessageDeclarationListOpt ClassMessageDeclaration { $2->SetNext($1); $$ = $2; }
+ | { $$ = NULL; }
+ ;
+
+ClassName
+ : Identifier { $$ = $1; }
+ | "(" AssignmentExpression ")" { $$ = $2; }
+ ;
+
+ClassNameOpt
+ : ClassName { $$ = $1; }
+ | { $$ = NULL; }
+ ;
+
+ClassExpression
+ : "@class" ClassNameOpt ClassSuperOpt ClassFieldList ClassMessageDeclarationListOpt "@end" { $$ = new(driver.pool_) CYClassExpression($2, $3, $4, $5); }
+ ;
+
+ClassStatement
+ : "@class" ClassName ClassSuperOpt ClassFieldList ClassMessageDeclarationListOpt "@end" { $$ = new(driver.pool_) CYClassStatement($2, $3, $4, $5); }
+ ;
+
+CategoryStatement
+ : "@class" ClassName ClassMessageDeclarationListOpt "@end" { $$ = new(driver.pool_) CYCategory($2, $3); }
+ ;
+
+PrimaryExpression
+ : ClassExpression { $$ = $1; }
+ ;
+
+Statement_
+ : ClassStatement { $$ = $1; }
+ | CategoryStatement { $$ = $1; }
+ ;
+/* }}} */
+/* Cycript: Send Message {{{ */
+VariadicCall
+ : "," AssignmentExpression VariadicCall { $$ = new(driver.pool_) CYArgument(NULL, $2, $3); }
+ | { $$ = NULL; }
+ ;
+
+SelectorCall_
+ : SelectorCall { $$ = $1; }
+ | VariadicCall { $$ = $1; }
+ ;
+
+SelectorCall
+ : WordOpt ":" AssignmentExpression SelectorCall_ { $$ = new(driver.pool_) CYArgument($1 ?: new(driver.pool_) CYBlank(), $3, $4); }
+ ;
+
+SelectorList
+ : SelectorCall { $$ = $1; }
+ | Word { $$ = new(driver.pool_) CYArgument($1, NULL); }
+ ;
+
+MessageExpression
+ : "[" AssignmentExpression SelectorList "]" { $$ = new(driver.pool_) CYSend($2, $3); }
+ ;
+
+SelectorExpressionOpt
+ : SelectorExpression_ { $$ = $1; }
+ | { $$ = NULL; }
+ ;
+
+SelectorExpression_
+ : WordOpt ":" SelectorExpressionOpt { $$ = new(driver.pool_) CYSelectorPart($1, true, $3); }
+ ;
+
+SelectorExpression
+ : SelectorExpression_ { $$ = $1; }
+ | Word { $$ = new(driver.pool_) CYSelectorPart($1, false, NULL); }
+ ;
+
+PrimaryExpression_
+ : MessageExpression { $$ = $1; }
+ | "@selector" "(" SelectorExpression ")" { $$ = new(driver.pool_) CYSelector($3); }
+ ;
+/* }}} */
+/* Cycript: Pointer Indirection/Addressing {{{ */
+AssigneeExpression_
+ : "*" UnaryExpression { $$ = new(driver.pool_) CYIndirect($2); }
+ ;
+
+UnaryExpression_
+ : "&" UnaryExpression { $$ = new(driver.pool_) CYAddressOf($2); }
+ ;
+
+MemberAccess
+ : "->" Identifier { $$ = new(driver.pool_) CYIndirectMember(NULL, new(driver.pool_) CYString($2)); }
+ ;
+/* }}} */
+/* ECMAScript5: Object Literal Trailing Comma {{{ */
+PropertyNameAndValueList_
+ : "," { $$ = NULL; }
+ ;
+/* }}} */
+/* JavaScript 1.7: Array Comprehensions {{{ */
+IfComprehension
+ : "if" "(" Expression ")" { $$ = new(driver.pool_) CYIfComprehension($3); }
+ ;
+
+ForComprehension
+ : "for" "(" Identifier "in" Expression ")" { $$ = new(driver.pool_) CYForInComprehension($3, $5); }
+ | "for" "each" "(" Identifier "in" Expression ")" { $$ = new(driver.pool_) CYForEachInComprehension($4, $6); }
+ ;
+
+ComprehensionListOpt
+ : ComprehensionList { $$ = $1; }
+ | IfComprehension { $$ = $1; }
+ | { $$ = NULL; }
+ ;
+
+ComprehensionList
+ : ForComprehension ComprehensionListOpt { $1->SetNext($2); $$ = $1; }
+ ;
+
+PrimaryExpression_
+ : "[" AssignmentExpression ComprehensionList "]" { $$ = new(driver.pool_) CYArrayComprehension($2, $3); }
+ ;
+/* }}} */
+/* JavaScript 1.7: for each {{{ */
+ForInStatement
+ : "for" "each" "(" ForInStatementInitialiser "in" Expression ")" Statement { $$ = new(driver.pool_) CYForEachIn($4, $6, $8); }
+ ;
+/* }}} */
+/* JavaScript 1.7: let Statements {{{ *//*
+LetStatement
+ : "let" "(" VariableDeclarationList ")" Block_ { $$ = new(driver.pool_) CYLet($3, $5); }
+ ;
+
+Statement
+ : LetStatement
+ ;
+*//* }}} */
+/* JavaScript FTW: Function Statements {{{ */
+Statement
+ : FunctionDeclaration { driver.Warning(yylloc, "warning, FunctionDeclaration is a SourceElement, not a Statement"); } { $$ = $1; }
+ ;
+/* }}} */