[Top][All Lists]

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

Re: How to add pseudo vector types

From: Stephen Leake
Subject: Re: How to add pseudo vector types
Date: Wed, 21 Jul 2021 14:54:00 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (windows-nt)

Clément Pit-Claudel <cpitclaudel@gmail.com> writes:

> On 7/21/21 12:29 PM, Stephen Leake wrote:
>> Yes, for both tree-sitter and wisi. wisi can take even longer if lots of
>> error correction is required (I have a time-out set at 5 seconds). But
>> that happens when the file is first opened; I doubt any user would start
>> typing that fast. I know I typically take a while to just look at the
>> text, and then navigate to the point of interest.
> I'm not sure. We've had significant complaint in Flycheck for freezing
> Emacs for <1s: we have a synchronous sanity check to determine whether
> a checker can execute in a buffer (it runs a single time, and it
> should be async but I haven't gotten around to rewriting it). The
> problem is that some programs, including eslint, can take as much 1s,
> and in some bad cases 2-3 seconds, to parse their own config and
> decide if they can even run.


> Users have complained about this delay. It might be better if they
> were able to scroll around, though — is that what happens with WISI?

wisi supports partial parse; if a buffer is larger than a user-settable
threshold, for font-lock it parses only the request region of the file,
expanded to reasonable start/end points.

So in that mode, the initial parse of even a very large buffer is fast.

However, using that for indentation is problematic, which is why I'm
implementing incremental parse.

I think continuing to support both will be useful.

> But if we have a fully synchronous TS, then that won't be possible
> either: it will be a complete Emacs freeze, no?

It should only freeze write operations on that buffer, so marking it
read-only while waiting for the parse results might be best.

-- Stephe

reply via email to

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