because you have this in the code.
.a(a)
you can't pass an array through verilog module ports. In my opinion this is the biggest flaw of Verilog and should have been changed in 2001. Systemverilog supports arrays passed through module ports, but I'm not sure how well supported it is. Modelsim supports it but I'm pretty sure ISE doesn't and Vivado doesn't (I'll admit I haven't tested it on Vivado) not sure about Quartus II. If you stick with Verilog you'll have to perform conversions of the array to a bus then back again.
Sorrry, I didn't notice the array the first time I looked at your code, though I did notice the {} ;-).