mirror of https://github.com/zachjs/sv2v.git
tolerate escaped vendor comments within macros
This commit is contained in:
parent
581a7911de
commit
c17d859988
|
|
@ -546,6 +546,10 @@ preprocessInput = do
|
||||||
'/' : '*' : _ -> removeThrough "*/"
|
'/' : '*' : _ -> removeThrough "*/"
|
||||||
'`' : '"' : _ -> handleBacktickString
|
'`' : '"' : _ -> handleBacktickString
|
||||||
'"' : _ -> handleString
|
'"' : _ -> handleString
|
||||||
|
'/' : '`' : '`' : '*' : _ ->
|
||||||
|
if null macroStack
|
||||||
|
then consume
|
||||||
|
else removeThrough "*``/"
|
||||||
'`' : '`' : _ -> do
|
'`' : '`' : _ -> do
|
||||||
if null macroStack
|
if null macroStack
|
||||||
then do
|
then do
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,4 @@
|
||||||
|
// pattern: Parse error
|
||||||
|
module top;
|
||||||
|
/``* some awful garbage *``/
|
||||||
|
endmodule
|
||||||
|
|
@ -0,0 +1,4 @@
|
||||||
|
`define YUCK /``* some awful garbage *``/
|
||||||
|
module top;
|
||||||
|
`YUCK
|
||||||
|
endmodule
|
||||||
Loading…
Reference in New Issue