OmniPascal 0.16.0 – Auto uses and auto declarations

After quite a long time there’s a new version available. There are two new features helping you to stay focused:


1. Symbol creation suggestions

Type the name of a new variable, field or method and use it would have already been declared. When you’re done place the cursor inside the name. OmniPascal will try to find possible declarations for the new symbol. You only need to pick one from the lightbulb.


2. Automatic uses suggestions

Type the name of the class or function you want to use. If the name can’t be resolved in the current scope a lightbulb pops up offering you to add the corresponding unit automatically. No need to add it manually or perform a global search just to find out where it is declared.


How does it work?

On startup the workspace will be indexed. OmniPascal (partially) will parse all pascal files and create an in-memory-index of all symbols in the global scope. With this index OmniPascal can provide uses suggestions almost instantly.
The first run may take longer as it creates a file cache so that future starts are faster.
You can choose whether you want to have indexed
  – the workspace
  – or the entire search path including system units.


As a side effect of the new symbol index the “Go to Symbol in Workspace”-feature has also been implemented with this release. You can jump to any indexed symbol by just typing its name.

ChangeLog

– Automatic declaration of variables, fields and methods
– The new setting “omnipascal.symbolIndex” defines the locations to be indexed
– Implemented workspace symbol provider (working on the new symbol index)
– Automatic uses suggestion
– The new setting “omnipascal.usesListStyle” defines how new uses entries are being added to the uses sections (one item per line or multiple items per line)
– The new setting “omnipascal.namingConventionString” defines whether the String type is being offered as “String” or “string” in code completion and hints
– Code completion on type names offers static accessible symbols only
– Improved parser speed
– tasks.json generated when loading a project is now version 2.0.0
– Bugfix: Method calls with negative constant literals sometimes resolved to unsigned integer types instead of signed types
– Bugfix: Failed to load projects where a property was declared multiple times within the same property group
– Bugfix: Generated Lazarus build scripts contain workaround to nothing-to-do-bug

You Might Also Like

3 Comments

  • Rodrigo Farias Rezino

    August 13, 2018

    Nice! I was afraid you had stopped the project.

    Reply
  • Rodrigo Farias Rezino

    August 13, 2018

    By the way, do you have plans for Dfms ?
    Maybe not rendering, but at least support highlight ?
    If we can collaborate with the project it would be nice.

    Reply
  • Benny

    August 15, 2018

    Thanks for the nice update. Good to see that OmniPascal is still active.

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *