Author Topic: systemVerilog: vars starting with x and z have different highlight  (Read 2264 times)

meidavec

  • Junior Community Member
  • Posts: 3
  • Hero Points: 1
In a systemVerilog file, I have a different highlight color for the first character of variables starting with "x" or "z". Is this just my system? Or perhaps an oversight in the syntax highlighting code? I don't see this for any other characters, and only on the first character. I will attach a sample file. I am using SlickEdit Pro 2017 v22.0.0.9 64 bit on Windows 7.

Lee

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1299
  • Hero Points: 130
Re: systemVerilog: vars starting with x and z have different highlight
« Reply #1 on: October 27, 2017, 01:16:12 PM »
Thanks for the report and the concise example.  The color coding engine has been re-worked for v22, and that appears to be an issue where it is mistakenly color coding the  x and z as a number literal.  I will file a defect and start working on a fix for this.

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 6826
  • Hero Points: 526
Re: systemVerilog: vars starting with x and z have different highlight
« Reply #2 on: October 27, 2017, 06:42:44 PM »
We will have a hot fix for this soon.

You can fix this yourself by modifying your color coding settings for SystemVerilog (Verilog has the same problem).

The Number regex in the Tokens tab (torwards botom of list): '(([sS]|)[dD]([xXzZ?]_@|[0-9_]@))|[01xXzZ]

Needs parentheses like this: '((([sS]|)[dD]([xXzZ?]_@|[0-9_]@))|[01xXzZ])

meidavec

  • Junior Community Member
  • Posts: 3
  • Hero Points: 1
Re: systemVerilog: vars starting with x and z have different highlight
« Reply #3 on: November 03, 2017, 06:15:19 PM »
The workaround looks good here!
Thanks for another very prompt fix. Your customers are very happy when you listen, and extra happy when you have solutions  :)

byates

  • Senior Community Member
  • Posts: 106
  • Hero Points: 8
Re: systemVerilog: vars starting with x and z have different highlight
« Reply #4 on: December 08, 2017, 07:11:30 PM »
I have seen this same issue. Note, the hotfix didn't fix it for me on two installs because the old regex value was still in the list. Once I deleted it (the old one) then color coding worked.

However, "highlight matching symbol under cursor" does not work for identifiers which start with x or z even after the fix.

Edited: seems like highlight does work mostly. Something may have been off with the color coding engine. It often stops working until a key is pressed or SE is restarted.
« Last Edit: December 08, 2017, 07:20:38 PM by byates »