emacs-devel
[Top][All Lists]
Advanced

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

Re: Tree-sitter introduction documentation


From: João Távora
Subject: Re: Tree-sitter introduction documentation
Date: Sat, 17 Dec 2022 10:40:35 +0000

I've just run admin/notes/tree-sitter/build-modules/batch.sh and
it worked flawlessly and built many .so.

Could probably have used Make instead of Bash, but worked fine
regardless, and reasonably quickly.

There's one thing that I think could be added which is that the
admin/notes/tree-sitter/build-modules/dist path relative to the
Emacs source directory be pre-set in the variable
treesit-extra-load-path, or something to that effect. Then this could
be even smoother.

But could it be smoother yet?  After all, all that build.sh does
is download and compile some C/C++ code after downloading it
from the internet. Why can't we bundle this code with the Emacs
source distribution and build the shared objects as part of the
normal build process? 

Bundling is also one way to help us pin the grammar version,
a dependency of our major mode source code.  The way it is
right now, it seems that if the upstream repository introduces
an incompatible change in the Foo grammar, our foo-ts-mode
will break.

The grammar repositories seem to be MIT licensed, and we
already promote its download anyway. I'm not an expert, but
it seems MIT is compatible with GPL, so we could carry some
MIT code in our repo.

João

reply via email to

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