module mult(a, b, p);
input [16:0] a;
input [16:0] b;
output p;
wire [31:0] p;
reg i;
wire pv;
wire bp;
assign pv = 32'b0;
assign bp = {16'b0,b} ;
initial begin
for (i = 0; i < 32 ; i = i + 1)
begin
if (a[i] == 1'b1)
begin
pv <= pv + bp;
end
bp <= bp << 1 ;
end
end
assign p = pv;
endmodule
I get the following error while compiling the code, line 37 Reference to scalar wire 'pv' is not a legal reg or variable lvalue line 37 Illegal left hand side of nonblocking assignment line 39 Reference to scalar wire 'bp' is not a legal reg or variable lvalue line 39 Illegal left hand side of nonblocking assignment
Pls help.