[fpc-pascal] Exploring block statements with CodeTools not working

Mattias Gaertner nc-gaertnma at netcologne.de
Mon Oct 17 10:31:17 CEST 2022


On Mon, 17 Oct 2022 08:41:23 +0700
Hairy Pixels via fpc-pascal <fpc-pascal at lists.freepascal.org> wrote:

> > On Oct 16, 2022, at 9:53 PM, Mattias Gaertner via fpc-pascal
> > <fpc-pascal at lists.freepascal.org> wrote:
> > 
> > Blocks like WHILE and TRY.
> > 
> > Codetools are optimized for finding declarations of a few
> > expressions between edits. To find the parameters, call for each
> > identifier followed by ( the FindCodeContext function.  
> 
> So inlay hints need to be computed with a document range so we don’t
> know a single X,Y position we could use to call FindCodeContext. If I
> had a list of identifiers which were function calls in begin blocks I
> could call FindCodeContext based on those. Is that possible?

Yes

Mattias


More information about the fpc-pascal mailing list