get_tempfile_suffix
uses the setting syntax_map
so I can't remove it
#1868
Labels
get_tempfile_suffix
uses the setting syntax_map
so I can't remove it
#1868
The setting
syntax_map
has been deprecated. We have some help text in the settings file but this text is misleading because the setting isn't used anymore to select linters for a given view. (We only use selector or scopes for this.)But we still use syntax_map in the tempfile suffix code. For example haskell defines
It has a mapping from syntax (which is the base or stem (=name without suffix in Python terminology)) to the file extension (suffix in Python land) used when generating tempfiles.
So the users uses
'Packages/Haskell/Haskell.sublime-syntax'
for its view, and therefore we use "hs" as the tempfile suffix.But if the user writes literal haskell bird style (
LiterateHaskellBirdStyle
) must be mapped tolhs
but the syntax is not in the mapping.The user can now define
to make it work. So we map from our used syntax, to the one defined in the plugin code, which maps finally to the wanted extension.
Nobody does that because it is way too complicated. Esp. that we first map to
literate haskell
is pure magic, the user must lookup the source code.Anyhow that's the wanted legacy functionality.
Ideally we could lookup and ask Sublime Text which is a (or the) typical extension for this syntax/language. Or we at least had a direct mapping from used syntax or base scope (
source.haskell.bird
) to extension.The text was updated successfully, but these errors were encountered: