string.v 234 Bytes
Newer Older
1
module top;
2
    localparam FOO = "some useful string";
3 4
    localparam WIDTH = $bits("some useful string");
    localparam [WIDTH-1:0] BAR = "some other useful string"; // clipped
5 6
    initial $display("'%s' '%s'", FOO, BAR);
endmodule