[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: PL support
From: |
Stefan Monnier |
Subject: |
Re: PL support |
Date: |
Sat, 09 May 2020 16:08:14 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
> They do have this problem, and they usually address it with hand written
> fix-up and glue code. (See the IntelliJ family.) I really want modes (and
> multi-modes) driven entirely by declarative (and customizable!) grammars ---
tree-sitter is basically doing just that.
LSP is different because it usually goes further than just the grammar,
providing information based on scoping and typing rules rules.
Type checking is much less standardized than parsing. For parsing we
know that a GLR engine should be able to handle the vast majority of
circumstances fairly efficiently. For type checking every compiler
implements basically its own approach by hand, and the algorithms and
data-structures can be fairly different between a C++ compiler, a Rust
compiler, and a Haskell compiler (and while parsing-time is usually
negligible and linear in complexity, time to perform type checking is
something at which engineering efforts are throw to keep it in check
because it can blow up in complexity).
So, I think the current state of the art is pretty far from knowing what
would be a good *declarative* specification of typing rules for use by
a generic tool providing the same kind of functionality as LSP servers.
Stefan
PS: We do know fairly well how to specify typing rules declaratively on
paper (where efficiency is not a concern), tho, so there's hope.
- Re: PL support (was: Drop the Copyright Assignment requirement for Emacs), (continued)
- Re: PL support (was: Drop the Copyright Assignment requirement for Emacs), Philippe Vaucher, 2020/05/09
- Re: PL support, David Engster, 2020/05/09
- Re: PL support (was: Drop the Copyright Assignment requirement for Emacs), Eli Zaretskii, 2020/05/09
- Re: PL support, Dmitry Gutov, 2020/05/09
- Re: PL support (was: Drop the Copyright Assignment requirement for Emacs), João Távora, 2020/05/09
- Re: PL support (was: Drop the Copyright Assignment requirement for Emacs), Daniel Colascione, 2020/05/09
- Re: PL support (was: Drop the Copyright Assignment requirement for Emacs), Eli Zaretskii, 2020/05/09
- Re: PL support (was: Drop the Copyright Assignment requirement for Emacs), João Távora, 2020/05/09
- Re: PL support (was: Drop the Copyright Assignment requirement for Emacs), Eli Zaretskii, 2020/05/09
- Re: PL support (was: Drop the Copyright Assignment requirement for Emacs), Daniel Colascione, 2020/05/09
- Re: PL support,
Stefan Monnier <=
- Re: PL support, Dmitry Gutov, 2020/05/09
- Re: PL support, Eli Zaretskii, 2020/05/09
- Re: PL support, João Távora, 2020/05/09
- Re: PL support, Eli Zaretskii, 2020/05/09
- Re: PL support, João Távora, 2020/05/09
- Re: PL support, Eli Zaretskii, 2020/05/09
- Re: PL support, João Távora, 2020/05/09
- Re: PL support, Eli Zaretskii, 2020/05/09
- Re: PL support, Yuan Fu, 2020/05/09
- Re: PL support, João Távora, 2020/05/09