[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Guidelines for the "symbol" syntax class
From: |
John Wiegley |
Subject: |
Re: Guidelines for the "symbol" syntax class |
Date: |
Sun, 03 Jan 2016 16:55:44 -0800 |
User-agent: |
Gnus/5.130014 (Ma Gnus v0.14) Emacs/24.5 (darwin) |
>>>>> Dmitry Gutov <address@hidden> writes:
> That's why I'm asking if there are any existing guidelines, formal or
> informal, that I can take into consideration. That might also inform changes
> to xref-collection-references and company-dabbrev-code; not just ruby-mode.
> Would anyone care for another wall of text?
I suppose my informal guideline is to implement a strategy that works best for
the mode you want to derive information from, and to not expect syntax classes
to be a capable enough interface. I'd expect Ruby symbols to include ":",
personally. A::B is the qualified name of a symbol -- although "B" is
technically an unqualified symbol in its own right within that qualified name.
Better yet, define a more general API that all modes can use, since many modes
struggle with these same issues (imenu, thing-at-pt, dabbrev, etc). This
echoes back to our long IDE thread. Perhaps we need layered, semantically-
defined classes, such that a given text position might occur within many such
layers (for example, selection might choose B, A::B, or A::B.foo, depending on
how many times I smash the "select current" key).
--
John Wiegley GPG fingerprint = 4710 CF98 AF9B 327B B80F
http://newartisans.com 60E1 46C4 BD1A 7AC1 4BA2
- Guidelines for the "symbol" syntax class, Dmitry Gutov, 2016/01/03
- Re: Guidelines for the "symbol" syntax class, John Wiegley, 2016/01/03
- Re: Guidelines for the "symbol" syntax class, Dmitry Gutov, 2016/01/03
- Re: Guidelines for the "symbol" syntax class, Stefan Monnier, 2016/01/03
- Re: Guidelines for the "symbol" syntax class, Dmitry Gutov, 2016/01/03
- Re: Guidelines for the "symbol" syntax class, John Yates, 2016/01/03
- Re: Guidelines for the "symbol" syntax class, Dmitry Gutov, 2016/01/03
- Message not available
- Re: Guidelines for the "symbol" syntax class, Dmitry Gutov, 2016/01/03
- Re: Guidelines for the "symbol" syntax class,
John Wiegley <=
- Re: Guidelines for the "symbol" syntax class, Dmitry Gutov, 2016/01/03
- Re: Guidelines for the "symbol" syntax class, Stefan Monnier, 2016/01/03
- Re: Guidelines for the "symbol" syntax class, Dmitry Gutov, 2016/01/03
- Message not available
- Message not available
- Message not available
- Re: Guidelines for the "symbol" syntax class, Dmitry Gutov, 2016/01/03