Roi Martin <jroi.mar...@gmail.com> writes:

> Maybe, we could have an alist that associates a language to some kind of
> "setup" function.  For instance, in the case of Scheme, it would read
> the `:scheme' argument and set the geiser implementation.  However, I'm
> not sure if it is worth it.  Also, I'm not familiar with the code base
> of org-mode, so bear with me. Probably, what I'm proposing does not make
> sense or is not the optimal solution.
>
> What do you think?

The problem is deeper.
Org mode does not even always call a given major mode for each src
block. For the purposes of fontification, a single major mode buffer may
be created and then reused to fontify src blocks with the same language.

If you want some kind of "setup" function, it is what scheme-mode-hook
(or <major-mode>-hook) is for.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>

Reply via email to