System Verilog Macro usage

Hi all,
I want this macro definition to be expanded when this macro get called as `macro_chk .this macro expansion is working fine if all arguments inside the macro finishes in single line but when it takes more than one line then this macro doesn’t work as expected(not expands). How should I enhance this macro so that it can catch its definition even used in multiple lines?

`macro_chk(while(reg_data[7:4]== 'h5 || reg_data[7:4]== 'h3
            || reg_data[7:4]== 'h7 || reg_data[7:4]== 'h9)
            ,driver_if.clk, reg_values )
            


`define macro_chk(condition,clk,change) \
begin \
    int value = 500; \
     fork \
     begin   \
       condition;
         $display("[ Waiting for change done"); \
     end  \
     begin \
       while (1) begin \
         @(posedge clk); \
          value--;  \
       $display("val= %0d",value); \
         if ( value== 0) begin \
            fall_to_zero = 1'b1;  \
            break;  \
         end  \
       end \
     end  \
    join_any \
      disable fork;  \
     if (fall_to_zero) begin \
         $display("ended waiting for change!"); \
         $finish ;  \
     end \
end 

In reply to Himanshu_D:

Since we cannot run this code, you need to show us the difference in behavior from when it works and when it does not work.

when all the arguments of macro_chk are in a single line, my regression doesn't show any error or it's compiled clean but when the arguments take more than one line then it shows compilation error as:- Error-[SE] Syntax error Following verilog source has syntax error : "file_name", line_number(expanding macro macro_chk)

here line_number is line where macro is used. so how i can improve the macro so that it can work fine with multiple lines also?

In reply to Himanshu_D:

There is nothing wrong with your macro usage. However, there is a infinite 0-delay while-loop which is the condition argument to your macro.

Since we cannot run this code, you’ll have to take this up with your tool vendor as it might be a tool specific issue.