emacs-devel
[Top][All Lists]
Advanced

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

Re: exposing the effective mode in a multi-mode


From: Dmitry Gutov
Subject: Re: exposing the effective mode in a multi-mode
Date: Thu, 21 Sep 2017 17:19:52 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:56.0) Gecko/20100101 Thunderbird/56.0

On 9/20/17 7:18 AM, Tom Tromey wrote:
"Dmitry" == Dmitry Gutov <address@hidden> writes:

Dmitry> So I thought it might be useful to return the name of the language
Dmitry> instead of the mode. The default implementation could look like this:

Are there modes that can adapt to multiple different major modes for
language, but without knowing the details of the major mode?  I don't
know but it seems iffy to me.

Do you know many cases where this isn't true?

Its the usual case in company-mode backends, I think. E.g., company-clang only cares that the edited language is one from a given list, not about the current major mode. Same for third-party backends for JS, and company-css, of course.

There might be some problems about unknown major modes setting the syntax table to unreasonable values, but we could treat those as bugs in those major modes.

Anyway, my suggestion makes things more complex. I'm not seeing a lot of reaction to it, so maybe disregard for now. We could add some major-mode->language mapping later down the road.



reply via email to

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