VScode+fortls: #include not recongnized #353
-
Dear all, I have a problem that seems to be benign, yet I could not figure out the solution myself. My FORTRAN code uses
directives, rather than the fortran-build-in
because the latter does not feature preprocessor directives. In particular, I have a module:
and if I edit the file I realize that |
Beta Was this translation helpful? Give feedback.
Replies: 6 comments
-
I don't know if this was ever addressed. I at least have the same problem still, and i think this would be a nice feature to add. Did you end up fixing it yourself? |
Beta Was this translation helpful? Give feedback.
-
I did not manage to find a fix for it, nor has it caught the developers attention :) |
Beta Was this translation helpful? Give feedback.
-
Okay, thanks for letting me know. It seems there could be a fix in the file def serve_document_symbols(self, request: dict):
...
# Add scopes to outline view
test_output = []
for scope in file_obj.ast.get_scopes():
if (
not scope.name # Skip empty strings
or scope.name.startswith("#") # Skip comments <- Here
or scope.get_type() == SELECT_TYPE_ID # Skip select types
):
continue
... I don't know if there is other places it would have to change, or if the preprocessor can be activated in a different way. This would suggest compiler directives is not supported or handled somewhere else? |
Beta Was this translation helpful? Give feedback.
-
I realized that this thread is in the "discussions" and not posted as an issue. maybe that is why it went unnoticed? |
Beta Was this translation helpful? Give feedback.
-
Yes, maybe marked as enhancement or bug as it should be compatible. |
Beta Was this translation helpful? Give feedback.
-
I created the issue here: |
Beta Was this translation helpful? Give feedback.
Yes, maybe marked as enhancement or bug as it should be compatible.