all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Bozhidar Batsov <bozhidar@batsov.com>
To: Dmitry Gutov <dgutov@yandex.ru>
Cc: 16593@debbugs.gnu.org
Subject: bug#16593: 24.3.50; ruby-mode: align chained method calls on multiple lines
Date: Fri, 31 Jan 2014 15:31:39 +0200	[thread overview]
Message-ID: <36E0FC636D784647B549AAECE2F67A18@gmail.com> (raw)
In-Reply-To: <52EB1B96.4020602@yandex.ru>

[-- Attachment #1: Type: text/plain, Size: 1820 bytes --]

Tested the patch locally and it works perfectly. IMO this patch should definitely be installed now, given its small scope and the fact it fixes problems in the current code (as well as providing an important customization option). 

-- 
Cheers,
Bozhidar


On Friday, January 31, 2014 at 5:42 AM, Dmitry Gutov wrote:

> On 30.01.2014 16:35, Stefan Monnier wrote:
> > > Warning (smie): Conflict: . </= .
> > > Warning (smie): Conflict: . </= .
> > > 
> > 
> > 
> > The smie-precs->prec2 part of your grammar says that "." = "." (because
> > of the new (assoc ".") you add there).
> > 
> > But the BNF part of your grammar says "." < "." (i.e. "foo . bar . baz"
> > is parsed as "foo . (bar . baz)" because of (id "." exp).
> > 
> 
> 
> Fantastic, thanks for the explanation. With (assoc ".") changed to 
> (right "."), the warning is gone.
> 
> I've also fixed the precedence of "." vs "? :" and modified a test case 
> respectively. See the new patch attached.
> 
> Do you think it's not too late in the feature freeze to install a change 
> like this, or should we wait until the trunk reopens?
> 
> We have a decent number of test cases, so it's not like the patch is 
> likely to introduce major breakage.
> 
> > Apparently there is no more conflict in the BNF in this respect so the
> > disambiguation constraint (assoc ".") that's passed to it is ignored.
> > 
> 
> 
> Without that constraint there, SMIE showed warnings about ambiguities 
> between ".", "," and "=". It somehow ignored the associativity, though.
> 
> The warnings with the previous patch also were gone when only the second 
> one (assoc ".") were changed to (right "."). The first one, in the BNF 
> disambiguation part, could be either.
> 
> Bozhidar, would you care to test the new patch? 
> 
> 
> Attachments: 
> - ruby-chained-calls.diff
> 



[-- Attachment #2: Type: text/html, Size: 3377 bytes --]

  reply	other threads:[~2014-01-31 13:31 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-30  4:24 bug#16593: 24.3.50; ruby-mode: align chained method calls on multiple lines Dmitry Gutov
2014-01-30 14:35 ` Stefan Monnier
2014-01-31  3:42   ` Dmitry Gutov
2014-01-31 13:31     ` Bozhidar Batsov [this message]
2014-01-31 17:04       ` Dmitry Gutov
2014-01-31 17:18         ` Glenn Morris
2014-01-31 17:33           ` Dmitry Gutov
2014-01-31 14:33     ` Stefan Monnier
2014-01-31 17:34       ` Dmitry Gutov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=36E0FC636D784647B549AAECE2F67A18@gmail.com \
    --to=bozhidar@batsov.com \
    --cc=16593@debbugs.gnu.org \
    --cc=dgutov@yandex.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.