lilypond-devel
[Top][All Lists]
Advanced

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

Re: Require path separators in assignments/overrides (issue 286680043 by


From: dak
Subject: Re: Require path separators in assignments/overrides (issue 286680043 by address@hidden)
Date: Mon, 14 Mar 2016 07:06:11 +0000

Reviewers: thomasmorley651, lemzwerg,

Message:
On 2016/03/14 06:40:27, lemzwerg wrote:
LGTM.

I assume that convert-ly already does the right thing...

Somewhere in the leadup to 2.18.  However, i kept \override Context.Grob
property.subproperty (without the dot in the middle) working.  It's just
the subproperty subdivision dot that is no longer optional.

Description:
Require path separators in assignments/overrides

Historical assignments/overrides like
Variable #'x #'y = 7
or
\override Glissando.bound-details #'left #'Y = #3
without dots between the various path components do not match the syntax
of
\revert and music functions or other uses.  Disallow the non-separation
by '.' or ',' of such path components.

Please review this at https://codereview.appspot.com/286680043/

Affected files (+1, -9 lines):
  M lily/parser.yy


Index: lily/parser.yy
diff --git a/lily/parser.yy b/lily/parser.yy
index 29ecf1c3222f88e4d8a7b6325486d24c098fa605..2b2f16d1dc61bda7010f44804ed1f551fd585a14 100644
--- a/lily/parser.yy
+++ b/lily/parser.yy
@@ -644,11 +644,6 @@ assignment:
                parser->lexer_->set_identifier ($1, $3);
                 $$ = SCM_UNSPECIFIED;
        }
-       | assignment_id property_path '=' identifier_init {
-               SCM path = scm_cons (scm_string_to_symbol ($1), $2);
-               parser->lexer_->set_identifier (path, $4);
-                $$ = SCM_UNSPECIFIED;
-       }
        | assignment_id '.' property_path '=' identifier_init {
                SCM path = scm_cons (scm_string_to_symbol ($1), $3);
                parser->lexer_->set_identifier (path, $5);
@@ -2558,9 +2553,6 @@ property_path:
        symbol_list_rev  {
                $$ = scm_reverse_x ($1, SCM_EOL);
        }
-       | symbol_list_rev property_path {
-               $$ = scm_reverse_x ($1, $2);
-       }
        ;

 property_operation:
@@ -2570,7 +2562,7 @@ property_operation:
        | UNSET symbol {
                $$ = scm_list_2 (ly_symbol2scm ("unset"), $2);
        }
-       | OVERRIDE property_path '=' scalar {
+       | OVERRIDE revert_arg '=' scalar {
                if (scm_ilength ($2) < 2) {
                        parser->parser_error (@2, _("bad grob property path"));
                        $$ = SCM_UNDEFINED;





reply via email to

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