hi all,
I am getting the below error.
Error-[IND] Identifier not declared
slave_write_driver.sv, 78
Identifier 'ADDR_WIDTH' has not been declared yet. If this error is not
expected, please check if you have set `default_nettype to none.
Error-[IND] Identifier not declared
slave_write_driver.sv, 78
Identifier 'DATA_WIDTH' has not been declared yet. If this error is not
expected, please check if you have set `default_nettype to none.
I am using two different files named as ‘.sv’ and ‘.svh’
.sv file format is having the definition of the methods, and .svh file is having methods prototype in it.
below code is stored in .svh format file
extern function slave_write_transaction #(ADDR_WIDTH,DATA_WIDTH) w_get_pkt();
below code is stored in .sv format file
function slave_write_transaction #(ADDR_WIDTH,DATA_WIDTH) axi_slave_write_driver::w_get_pkt();
slave_write_transaction #(ADDR_WIDTH,DATA_WIDTH) w_packet=new();
w_packet=w_queue.pop_front();
return w_packet;
endfunction:w_get_pkt
I had also used the typedef,
typedef slave_write_transaction #(ADDR_WIDTH,DATA_WIDTH) class_handle
but none of the solution worked.
I have included the file first .svh and then .sv file.
Am I missing something?
please help me out.
since main code is of hundreds of line, I did not find it appropriate to share it here.
thanks and regards