Commit 5105ccbb by Zachary Snow

use scoped errors in struct conversion

parent c843efd5
// pattern: pattern '\{..x: 1,..y: 2.\} has extra named fields \["y"\] that are not in struct packed \{..logic x;.\} // pattern: pattern '\{..x: 1,..y: 2.\} has extra named fields \["y"\] that are not in struct packed \{..logic x;.\}
// location: struct_extra_named_field.sv:4:5
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
// pattern: pattern '\{..1,..2.\} doesn't have the same number of items as struct packed \{..logic x;.\} // pattern: pattern '\{..1,..2.\} doesn't have the same number of items as struct packed \{..logic x;.\}
// location: struct_extra_unnamed_field.sv:4:5
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
// pattern: invalid pattern key -1 is not a type, field name, or index // pattern: invalid pattern key -1 is not a type, field name, or index
// location: struct_invalid_key.sv:4:5
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
// pattern: illegal access to bit 0 of s\.x, which has type logic // pattern: illegal access to bit 0 of s\.x, which has type logic
// location: struct_logic_bit.sv:7:13
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
// pattern: illegal access to range \[0:0\] of s\.x, which has type logic // pattern: illegal access to range \[0:0\] of s\.x, which has type logic
// location: struct_logic_part_range.sv:7:13
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
// pattern: illegal access to range \[0\+:1\] of s\.x, which has type logic // pattern: illegal access to range \[0\+:1\] of s\.x, which has type logic
// location: struct_logic_part_select.sv:7:13
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
// pattern: couldn't find field 'y' from struct definition struct packed \{..logic x;..logic y;.\} in struct pattern '\{..x: 1.\} // pattern: couldn't find field 'y' from struct definition struct packed \{..logic x;..logic y;.\} in struct pattern '\{..x: 1.\}
// location: struct_missing_field.sv:4:5
module top; module top;
struct packed { struct packed {
logic x, y; logic x, y;
......
// pattern: pattern index 1'bx is not an integer // pattern: pattern index 1'bx is not an integer
// location: struct_non_integer.sv:4:5
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
// pattern: pattern index 1 is out of bounds for struct packed \{..logic x;.\} // pattern: pattern index 1 is out of bounds for struct packed \{..logic x;.\}
// location: struct_out_of_bounds.sv:4:5
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
// pattern: pattern index -1 is out of bounds for struct packed \{..logic x;.\} // pattern: pattern index -1 is out of bounds for struct packed \{..logic x;.\}
// location: struct_out_of_bounds_neg.sv:4:5
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
// pattern: field 'y' not found in struct packed \{..logic x;.\} // pattern: field 'y' not found in struct packed \{..logic x;.\}
// location: struct_unknown_field.sv:8:5
module top; module top;
struct packed { struct packed {
logic x; logic x;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment