Fix linebreak at define macro usage

This commit is contained in:
dalance 2019-12-02 11:47:43 +09:00
parent d8b238c268
commit b5a4cad61a
2 changed files with 15 additions and 6 deletions

View File

@ -2,6 +2,8 @@
## [Unreleased](https://github.com/dalance/sv-parser/compare/v0.4.5...Unreleased) - ReleaseDate
* [Fix] wrong linebreak at define macro usage
## [v0.4.5](https://github.com/dalance/sv-parser/compare/v0.4.4...v0.4.5) - 2019-11-28
* [Fix] wrong space at define macro usage

View File

@ -493,9 +493,9 @@ fn resolve_text_macro_usage<T: AsRef<Path>, U: AsRef<Path>>(
.replace("``", "")
.replace("`\\`\"", "\\\"")
.replace("`\"", "\"")
.replace("\\\n", "")
.replace("\\\r\n", "")
.replace("\\\r", ""),
.replace("\\\n", "\n")
.replace("\\\r\n", "\r\n")
.replace("\\\r", "\r"),
);
}
}
@ -616,7 +616,9 @@ endmodule
module a ();
assign a_0__x = a[0].x; assign a_0__y = a[0].y; assign a_1__x = a[1].x; assign a_1__y = a[1].y; endmodule
assign a_0__x = a[0].x;
assign a_0__y = a[0].y; assign a_1__x = a[1].x;
assign a_1__y = a[1].y; endmodule
"##
);
}
@ -630,8 +632,13 @@ module a ();
r##"
module a ();
always @(posedge clk) begin if (!(!(a[i].b && c[i]))) begin $display ("xxx(()[]]{}}}", a[i].b, c[i])
; end end ;
always @(posedge clk) begin
if (!(!(a[i].b && c[i]))) begin
$display ("xxx(()[]]{}}}", a[i].b, c[i])
;
end
end
;
endmodule
"##