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

[Clarification] No warning reported if object is not set #299

Open
nselvara opened this issue Apr 29, 2024 · 2 comments
Open

[Clarification] No warning reported if object is not set #299

nselvara opened this issue Apr 29, 2024 · 2 comments

Comments

@nselvara
Copy link

As an addendum to this issue: #298
If one doesn't use/set the object (port, signal, variable), VHDL-LS correctly flags a warning that it's not set - all good :) .
However, if the object is used for example as bla'sig_obj'subtype then the warning goes away even though the object is kind of not set. I'm not sure if that's a desirable feature to also output warning if the signal is not set rather than just used to get meta data.

@Schottkyc137
Copy link
Contributor

It's a good question whether this should be marked as an unused declaration or not. rust-analyzer does something similar when a variable is only used in recursion, so maybe vhdl_ls should emit an error in a similar fashion?

@nselvara
Copy link
Author

nselvara commented May 5, 2024

Or maybe, we introduce 2 kind of flags, which then indicates that the object is only used as a reference and the other one remains the same if it's not used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants