I'm trying to make a counter on verilog using ise xilinx 14.7, webpack version.
Actually, I copied a counter from the book "Digital Design using digilent FPGA Boards" by R. Haskell and D. Hanna in order to understand it and make some modifications.
While syntaxis is all good, when I try to Synthetize the top module, it says unexpected token and illegal redeclaration about variables I'm calling from one of the modules, just like this picture shows. I'm new to verilog, please, if you could tell me what I'm doing wrong, I'd be very thankful.