[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: trunk r114534: Get Ruby's SMIE code to pass the test suite.
From: |
Dmitry Gutov |
Subject: |
Re: trunk r114534: Get Ruby's SMIE code to pass the test suite. |
Date: |
Mon, 21 Oct 2013 18:16:54 +0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) |
Stefan Monnier <address@hidden> writes:
>> 1) Is `assoc' any different from `left' in practice?
>
> Yes: with `assoc', when you have "a + b + c", smie first tries to align
> "c" with "b", whereas with `left' it would skip "b" and go straight to
> "a". When there are only 3 elements, it rarely makes a difference, but
> for things like "," or ";" where there can be tens or hundreds of
> elements, the different can be very significant in terms of
> indentation speed. Also, it makes a difference if the user purposefully
> "misindents" some of the elements, of course.
I see.
> Maybe change the tokenizer so that a ".qux" *at smie-bolp* is tokenized
> as "." and "qux"?
That will probably break the following modified example:
class C
def foo
self
.end
D.new
.class
end
end
But I guess we can make the tokenizer both return "." as a separate
token and include it in the token that goes after it.
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Dmitry Gutov, 2013/10/05
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Stefan Monnier, 2013/10/06
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Dmitry Gutov, 2013/10/06
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Stefan Monnier, 2013/10/07
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Dmitry Gutov, 2013/10/21
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Stefan Monnier, 2013/10/21
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite.,
Dmitry Gutov <=
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Stefan Monnier, 2013/10/21
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Dmitry Gutov, 2013/10/21
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Stefan Monnier, 2013/10/22
- Re: trunk r114534: Get Ruby's SMIE code to pass the test suite., Stefan Monnier, 2013/10/22