Getopt thinks a path is a comment
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)\/\/.*$//;
Also available in: Atom