-
-
Notifications
You must be signed in to change notification settings - Fork 30
Pre Release
- Linter
-
User Interface (UI)
- Run and Debug individual files
- Log Channel improvements
- Setting verbosity level
- Added Fortran Logo icon
- Added relative path resolution for
fortls
and formatters - Added variable resolution support for
fortls
- Added
fpm.toml
schema validation - Improved Installation of dependencies using VS Code Tasks
- New Commands
- New Settings
- Other Changes
- π Bug Fixes π
Adds some initial support for fypp
when using gfortran
. More compilers will follow soon!
Added support for parsing plain text diagnostics from gfortran
v11+
thus allowing the display of multiline diagnostics
module err_mod
private
implicit none ! <- Error here previously not shown
contains
subroutine foo(arg1, arg2)
integer, intent(in) :: arg1, arg2
print*, 'arg1:', arg1, 'arg2:', arg2
end subroutine foo
subroutine proc_with_err()
call foo()
end subroutine proc_with_err
end module err_mod
The LFortran linter is now available in the extension. It can be enabled by setting the fortran.linter.compiler
setting to lfortran
.
By default, now the linter uses a unique VS Code, workspace specific persistent cache directory to store all output files generated by the linter. This should prevent
any unexpected behaviour where the linter produces unwanted .mod
files that
are then picked up by the build system.
You can clean the cache by running the Fortran: Clean Linter generated files
command, see Commands for more details.
A series of new commands have been added, see New Commands section for more details.
Fortran: Initialize Fortran Linter
Fortran: Clean Linter generated files
Fortran: Clean All Linter Diagnostics
You can now run and debug individual files. This is useful for debugging small snippets of code. To do this, right-click on the file and select Run File
or Debug File
from the context menu.
The Modern Fortran
log channel has had a small revamp.
Logs are now colourized to make reading them easier
You can now choose the verbosity level of the extension by setting the following option in the settings
{
"fortran.logging.level": "Error"
}
Added a new icon for the Fortran Language files
It is now possible to define the path to fortls
or the formatters using relative
paths to the top-most workspace folder.
"fortran.fortls.path": "./venv/bin/fortls"
Previously, internal VS Code variables like ${workspaceFolder}
were not resolved
when defining the path to fortls
. This has now been fixed.
"fortran.fortls.path": "${workspaceFolder}/venv/bin/fortls"
Leveraging the support for schemas from the Even Better TOML extension,
Modern Fortran now provides a schema for fpm.toml
file validation and autocompletion.
The extension dependencies are now installed using Visual Studio Code's Tasks. That means that the commands are run from within the VS Code terminal, inheriting any environment variables already present. Particularly useful when using Python virtual environments.
A series of new commands have been added for the linter
Runs a naive mock compilation of all the Fortran source files found in the project
in order to generate the .mod
and .smod
files necessary for the linter. This
also generates all the Diagnostics for the project.
Cleans all the .mod
and .smod
files generated by the linter that are placed
in the persistent cache storage of VS Code for this workspace.
Cleans all the diagnostics generated by the linter.
Hide release notes when the extension in being installed or updated.
"fortran.notifications.releaseNotes": true
An option, by default true
that will attempt to initialize the linter with
all the Fortran source files found in the workspace upon the extension activation.
Performs the same task as the Fortran: Initialize Fortran Linter
command.
An option to keep or discard all the diagnostics generated by running the initialization process of the linter.
An option to set the verbosity level of the extension log channel.
Converted the linter into using asynchronous processes, which should improve the overall performance and responsiveness of the diagnostics.
The native symbol provider (one used when fortls
is not present) has been updated
to use the new VS Code API.
The fast-glob
module was causing issues with the linter when using the **
glob pattern. The parent directory would not be included in the results see, https://github.com/mrmlnc/fast-glob/issues/47.
This was problematic since users had to define the include directories twice,
once with the glob pattern and once without it. We have switched to the glob
,
which is slower but does not suffer from this issue.
The cache used by the linter should help mitigate any performance issues.
- Fixed bug where the linter's internal cache directory would not always exist (#698)