[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Tree-sitter integration in python.el
From: |
Matthias Meulien |
Subject: |
Re: Tree-sitter integration in python.el |
Date: |
Tue, 04 Oct 2022 19:11:34 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
Eli Zaretskii <eliz@gnu.org> writes:
>> From: Matthias Meulien <orontee@gmail.com>
>> Cc: casouri@gmail.com, emacs-devel@gnu.org
>> Date: Tue, 04 Oct 2022 13:21:45 +0200
>>
>> Eli Zaretskii <eliz@gnu.org> writes:
>>
>> > (...) Would you please share the changes you made, FTR? Then others
>> > who face the same problem could easily find the solution. TIA.
>>
>> Sure, but let me make clear that it's an unclean hack and using
>> https://github.com/casouri/tree-sitter-module may prove to be more
>> robust.
>
> Understood, thanks.
>
>> diff --unified tree-sitter-ruby/Makefile tree-sitter-python/Makefile
>> --- tree-sitter-ruby/Makefile 2022-10-03 23:01:34.963750322 +0200
>> +++ tree-sitter-python/Makefile 2022-10-04 13:06:46.014817832 +0200
>> @@ -31,7 +31,7 @@
>> ifeq (, $(CPPSRC))
>> ADDITIONALLIBS :=
>> else
>> - ADDITIONALLIBS := -lc++
>> + ADDITIONALLIBS :=
>> endif
>
> Any reason why you needed to use the C++ compiler?
Well, I saw the C++ file tree-sitter-python/src/parser.cc
(cf.
https://github.com/tree-sitter/tree-sitter-python/blob/master/src/scanner.cc#L1)
and also got a linker error when using the original Makefile where gcc
use option -lc++. I didn't try to understand that error, I am used to
compile C++ using g++ so I just changed the Makefile to fix an error
I've not truly understood.
Note that
https://github.com/casouri/tree-sitter-module/blob/master/build.sh#L46
switch to using c++ compiler when a parser.cc file is found.
--
Matthias
- Re: [External] : Re: Tree-sitter integration in python.el, (continued)
- Re: [External] : Re: Tree-sitter integration in python.el, Augusto Stoffel, 2022/10/10
- Re: Tree-sitter integration in python.el, Yuan Fu, 2022/10/08
- Re: Tree-sitter integration in python.el, Augusto Stoffel, 2022/10/10
- Re: Tree-sitter integration in python.el, Yuan Fu, 2022/10/10
- Re: Tree-sitter integration in python.el, Augusto Stoffel, 2022/10/10
- Re: Tree-sitter integration in python.el, Yuan Fu, 2022/10/12
- Re: Tree-sitter integration in python.el, Stefan Monnier, 2022/10/11
- Re: Tree-sitter integration in python.el, Eli Zaretskii, 2022/10/04
- Re: Tree-sitter integration in python.el, Matthias Meulien, 2022/10/04
- Re: Tree-sitter integration in python.el, Eli Zaretskii, 2022/10/04
- Re: Tree-sitter integration in python.el,
Matthias Meulien <=
Re: Tree-sitter integration in python.el, Yuan Fu, 2022/10/03
Re: Tree-sitter integration in python.el, address@hidden, 2022/10/03
Re: Tree-sitter integration in python.el, Matthias Meulien, 2022/10/03