Project

General

Profile

[logo] 
 
Home
News
Activity
About/Contact
Major Tools
  Dinotrace
  Verilator
  Verilog-mode
  Verilog-Perl
Other Tools
  IPC::Locker
  Parallel::Forker
  Voneline
General Info
  Papers

Issue #1610

Getopt thinks a path is a comment

Added by Peter Nelson 2 months ago. Updated 2 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
% Done:

0%


Description

When passed a -f file.vc Getopt will strip any comments: https://metacpan.org/release/Verilog-Perl/source/Getopt.pm#L84 $line =~ s/\/\/.*$//;

The problem is paths can have // in them - such as /home/foo//bar. This line will spuriously strip the path to be /home/foo.

The regex needs to check the comment has a preceding start-of-line or space: $line =~ s/(?:^|\s)\/\/.*$//;

History

#1 Updated by Wilson Snyder 2 months ago

  • Status changed from New to Confirmed

Indeed, good point & other simulators handle this.

To give you author credit, do you signoff for me to git commit with your name and email address?

#2 Updated by Peter Nelson 2 months ago

No need for author credit, I'd rather not have my email address in more places that get spam =p

#3 Updated by Wilson Snyder 2 months ago

  • Status changed from Confirmed to Resolved

That's why I ask ;)

Pushed to git towards eventual 3.470 release.

Also available in: Atom