Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IMPLICIT statement without enclosing scope #264

Open
warrenstephens opened this issue Mar 2, 2023 · 2 comments
Open

IMPLICIT statement without enclosing scope #264

warrenstephens opened this issue Mar 2, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@warrenstephens
Copy link

The fortls linter gives an IMPLICIT statement without enclosing scope on the IMPLICIT statement like this:

      BLOCKDATA
      IMPLICIT NONE
      COMMON /GRAPHQWDATA/ CCLIENT
      CHARACTER*8 CCLIENT
      DATA CCLIENT /'SCANMF'C/
      ENDBLOCKDATA

A red underline is on the word NONE.

Moved to inside the COMMON it says the same thing.

This is with the Modern Fortran v3.2.0 extension in VS Code. The fortls version is 2.13.0

The block is followed by a PROGRAM, and so forth.

@warrenstephens warrenstephens added the bug Something isn't working label Mar 2, 2023
@gnikit
Copy link
Member

gnikit commented Mar 2, 2023

Thanks for the issue @warrenstephens, if I had to guess why that is I would say that it probably related to how we serve diagnostics and in general processes BLOCK DATA, DATA and COMMON statements. A lot of the Fortran77 features that have been superseded by Fortran 90+ features are not that well supported.

I will investigate this further.

@warrenstephens
Copy link
Author

You are welcome! 😉

I have lots of old code, but only a few COMMON blocks to deal with while reviving an old project which is mostly F90.

Modernizing with Intel oneAPI Fortran, also a fan of VScode.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants