data/full_repos/permissive/143278/ivltests/param_tern.v
data/verilator_xmls/5236241d-e474-4783-a828-20889b4150b5.xml
module main;

   parameter PARM08 = 8;
   parameter PARM04 = PARM08 >> 1;
   parameter PARM16 = PARM08 << 1;

   parameter PARM10 = ((PARM08 <=2) ? 1:
                      ((PARM08 <=4) ? 2:
                      ((PARM08 <=8) ? 3:4)));


   wire [PARM04 : 0] in04;
   wire [PARM16 : 0] in05;

   reg [PARM08 : 0]  out00;
   reg [PARM04 : 0]  out04;
   reg [PARM16 : 0]  out05;


   wire [PARM10:0]   in99;

   initial begin
      if (PARM08 !== 8) begin
	 $display("FAILED -- PARM08 == %b", PARM08);
	 $finish;
      end

      if (PARM04 !== 4) begin
	 $display("FAILED -- PARM04 == %b", PARM04);
	 $finish;
      end

      if (PARM16 !== 16) begin
	 $display("FAILED -- PARM16 == %b", PARM16);
	 $finish;
      end


      if (PARM10 !== 3) begin
	 $display("FAILED -- PARM10 == %b", PARM10);
	 $finish;
      end

      $display("PASSED");
   end

endmodule
module main;


   parameter PARM08 = 8;
   parameter PARM04 = PARM08 >> 1;
   parameter PARM16 = PARM08 << 1;

   parameter PARM10 = ((PARM08 <=2) ? 1:
                      ((PARM08 <=4) ? 2:
                      ((PARM08 <=8) ? 3:4)));


   wire [PARM04 : 0] in04;
   wire [PARM16 : 0] in05;

   reg [PARM08 : 0]  out00;
   reg [PARM04 : 0]  out04;
   reg [PARM16 : 0]  out05;


   wire [PARM10:0]   in99;

   initial begin
      if (PARM08 !== 8) begin
	 $display("FAILED -- PARM08 == %b", PARM08);
	 $finish;
      end

      if (PARM04 !== 4) begin
	 $display("FAILED -- PARM04 == %b", PARM04);
	 $finish;
      end

      if (PARM16 !== 16) begin
	 $display("FAILED -- PARM16 == %b", PARM16);
	 $finish;
      end


      if (PARM10 !== 3) begin
	 $display("FAILED -- PARM10 == %b", PARM10);
	 $finish;
      end

      $display("PASSED");
   end

endmodule