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

Syntax highlighting errors #125

Open
sconwayaus opened this issue Jun 22, 2021 · 2 comments · May be fixed by #150
Open

Syntax highlighting errors #125

sconwayaus opened this issue Jun 22, 2021 · 2 comments · May be fixed by #150

Comments

@sconwayaus
Copy link

sconwayaus commented Jun 22, 2021

Hello,

Found a couple of syntax highlighting corner cases.

  1. Declaring a class variable (maybe with parameters) causes the next control statement to highlight incorrectly (in this case the "function" on line 5 and "if" on line 18)
    error1

  2. When instantiating a module, adding a comment after the parameter list causes the instance name to highlight incorrectly (line 46).
    error2

  3. Line 56, Packet should be Green (entity.name.type), displayed as Light Blue (variable).
    Screenshot (3)

  4. scope not highlighted correctly on 284. Commenting out line 279 resolves the issue, similarly removing the space between "Packet" and "#" resolves the issue, but causes Packet to not be highlighted correctly.
    Screenshot (4)

@sconwayaus
Copy link
Author

Another corner case when importing DPI-C function.

Screenshot - import

@joecrop
Copy link
Collaborator

joecrop commented Mar 10, 2022

@sconwayaus I am able to reproduce (and solve) issues 1, 3, and 4. But my test case for issue 2 dies not fail when I add a comment on any line. Can you re-confirm issue 3?

For issue 1 and 3. The syntax highlighting was actually wrong. The symbol should have been identified as storage.type.user-defined.systemverilog which is a dark blue color like this:

image

I kind of like the green, but the blue is technically correct. Do you have any concerns with it being blue moving forward?

I have not looked at issue 5 yet.

@joecrop joecrop linked a pull request Mar 10, 2022 that will close this issue
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

Successfully merging a pull request may close this issue.

2 participants