From 1c117ac0236517d0d7150dcc8d1fed19288bd692 Mon Sep 17 00:00:00 2001 From: Eddie Hung Date: Thu, 14 May 2020 10:46:40 -0700 Subject: [PATCH] verilog: do not warn for attributes on null statements --- frontends/verilog/verilog_parser.y | 2 -- tests/verilog/bug2037.ys | 8 ++++---- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/frontends/verilog/verilog_parser.y b/frontends/verilog/verilog_parser.y index eb7e136ae..475557af9 100644 --- a/frontends/verilog/verilog_parser.y +++ b/frontends/verilog/verilog_parser.y @@ -2230,7 +2230,6 @@ behavioral_stmt: non_opt_delay behavioral_stmt | attr simple_behavioral_stmt ';' | attr ';' { - log_file_warning(current_filename, get_line_num(), "Attribute(s) attached to null statement. Ignoring.\n"); free_attr($1); } | attr hierarchical_id { @@ -2534,7 +2533,6 @@ module_gen_body: gen_stmt_or_module_body_stmt: gen_stmt | module_body_stmt | attr ';' { - log_file_warning(current_filename, get_line_num(), "Attribute(s) attached to null statement. Ignoring.\n"); free_attr($1); }; diff --git a/tests/verilog/bug2037.ys b/tests/verilog/bug2037.ys index 42c4b8f5d..eb4f0fac4 100644 --- a/tests/verilog/bug2037.ys +++ b/tests/verilog/bug2037.ys @@ -1,4 +1,3 @@ -logger -expect warning "Attribute\(s\) attached to null statement\. Ignoring\." 1 logger -expect-no-warnings read_verilog <