emacs-devel
[Top][All Lists]
Advanced

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

Re: Questioning the new behavior of `open-line'.


From: Yuri Khan
Subject: Re: Questioning the new behavior of `open-line'.
Date: Thu, 12 Nov 2015 20:44:09 +0600

On Thu, Nov 12, 2015 at 8:16 PM, Rasmus <address@hidden> wrote:

> Picture 1
>
>       var svg = div.append("svg")|
>
>           .attr("width", box_plot.w)
>                    .attr("height", box_plot.h);
>
> Picture 2
>
>     var svg = div.append("svg")|
>         .classed("myclass", true)
>                  .attr("width", box_plot.w)
>                  .attr("height", box_plot.h);

Both cases demonstrate a bug caused by the lack of a suitable
Javascript indentation heuristic. Something along the lines of “_if_
the line starts with a dot _and_ the previous line ends with \(a
dot\), followed by an identifier, followed by balanced parentheses,
_and_ the previous line’s indentation does not contain any tab
characters, _then_ align to the position of \1”.

Arguably, they should be solved by adding that heuristic, not by
breaking open-line and/or newline-and-indent.



reply via email to

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