1666 Commits

Author SHA1 Message Date
Boulanger
fce0e11dd4 Add defensive code for "als-object-dir" with aggregate project
Add a test.

Closes eng/ide/ada_language_server#1773
2026-02-02 10:15:17 +01:00
Boulanger
ef2ea12f81 Handle deletion only from xdiff
Add a test

Delete extra test-loc.xml

Depends-On: eng/ide/xdiff!9

For eng/ide/ada_language_server#1768
2026-01-30 09:58:35 +00:00
Vivek Mathur
a0026d775d Generate Subprogram: restrict type back to Subp_Decl 2026-01-29 22:30:06 +00:00
Maxim Reznik
06fcade425 Disable onTypeFormating if there is a new line
after previous construct. Like:

```ada
procedure A is
   Already_Formatted : constant := 1;

<ENTER>
```
2026-01-28 16:54:16 +02:00
Vivek Mathur
5d5b4c115c Generate Subprogram stub copies declaration style 2026-01-27 17:26:17 +00:00
Boulanger
e7c1a5bb05 Fix onTypeFormatting at the top of the file
Case where previous_token retuns no_token

Closes eng/ide/ada_language_server#1767
2026-01-22 17:35:39 +01:00
Maxim Reznik
0fc219f100 Fix search path order in GPR server
to make it honor GPR_PROJECT_PATH priority.
2026-01-20 12:48:50 +00:00
Anthony Leonardo Gracio
b2f0338734 Handle source file mentions for GPR textDocument/definition
Querying 'textDocument/definition' on a source file mention
in a GPR file (e.g: 'for Main use ("main.adb")' now opens
the mentioned source file.

For eng/ide/ada_language_server#1733
2026-01-19 12:45:12 +00:00
Andry Ogorodnik
33869a6f5f Check that children is not null
For eng/ide/ada_language_server#1758
2026-01-16 17:26:26 +00:00
Anthony Leonardo Gracio
c08cf53590 Display unit in completion item labelDetails
When the client supports it, which is the case of
VS Code.

In addition display the symbol's fully qualified
name at the top of the 'details' field.

Tests have been adapted accordingly.

For eng/ide/ada_language_server#1734
2026-01-15 16:38:20 +00:00
Maxim Reznik
1b8d48b368 Implementation of textDocument/linkedEditingRange
For now it works only on defining names and returns all references
in the current file.
2026-01-14 12:52:01 +02:00
Vivek Mathur
f235f86da5 Offer Generate Package action on package declaration lines only 2026-01-05 09:40:28 +00:00
Anthony Leonardo Gracio
4094bd6419 Adapt to new GPR2 API
The Current_Directory parameter of the Default_Search_Paths
function has been removed.

For eng/ide/ada_language_server#1752
2026-01-02 15:46:30 +00:00
Vivek Mathur
2fe481fe44 Add Generate Package code action 2026-01-02 12:34:07 +00:00
Anthony Leonardo Gracio
811b0604ce Handle Clean, Format, Check and Emulator packages
For tool switches completion.

Adapt the Python script to handle more switches formats
(e.g: switches with a short and long version, like '-v,
--verbose').

For eng/ide/ada_language_server#1741
2025-12-19 09:06:30 +00:00
Anthony Leonardo Gracio
8cfac45f07 Add labelDetails to completion switches
If the client supports it, which is the case of VS Code.

labelDetails are displayed in gray, next to the completion
item's label: displaying the doc here gives a preview to
the user, which is particularly useful when trying to
understand what the selected switch is doing.

Add a test.

For eng/ide/ada_language_server#1741
2025-12-18 11:39:54 +00:00
Anthony Leonardo Gracio
8de8a243b0 Handle 'Builder' package in tool switches completion
And refine the snippet creation logic, by handling
more formats (e.g: '--db dir').

For eng/ide/ada_language_server#1741
2025-12-18 11:39:54 +00:00
Anthony Leonardo Gracio
d54fa4f711 Add final tab stop after GPR tool switch snippets
This is more user-friendly when the user wants to specify
several switches in a row.

For eng/ide/ada_language_server#1741
2025-12-18 11:39:54 +00:00
Vivek Mathur
3dca80deb1 Add Generate Subprogram refactoring code action 2025-12-16 18:57:27 +00:00
Anthony Leonardo Gracio
0754a214e8 Create snippets for GPR tool switches with parameters
For eng/ide/ada_language_server#1741
2025-12-15 11:27:49 +00:00
Anthony Leonardo Gracio
66aa3be3d3 Associate GNATprove switches to Prove package
Instead of 'Analyzer', which is for GNAT SAS.

For eng/ide/ada_language_server#1741
2025-12-12 14:49:54 +00:00
Anthony Leonardo Gracio
ea2af3bbd4 Few improvements to GPR tool switches completion
* Trigger it only if 'use' has been specified after
  Default_Switches or Switches

* Handle concatenation constructs
  (e.g: 'for Default_Switches ("ada") use Var1 & Var2 & (')

* Add more tests

For eng/ide/ada_language_server#1741
2025-12-11 15:19:29 +00:00
Andry Ogorodnik
1f29c2cab8 Added extendedProject field for locations
To separate locations for the root project and the extended project

For eng/ide/ada_language_server#1739
2025-12-03 16:20:23 +02:00
Andry Ogorodnik
7598089534 Fix exception in the lsp-ada_inline_value.adb
Rised LANGKIT_SUPPORT.ERRORS.PRECONDITION_FAILURE

For eng/ide/ada_language_server#1727
2025-12-02 16:43:02 +02:00
Anthony Leonardo Gracio
38743e231c Provide completion help for tool switches in GPR files
The database is created via a Python script that parses the
--help output of tools, and encapsulates it in a JSON-structured
string database in Ada.

The GPR file parser has been modified to handle completion for
the Default_Switches and Switches attributes inside packages,
and propose completion when available.

For eng/ide/ada_language_server#1741
2025-11-28 16:22:54 +00:00