Lint warning on conditional expression is statically evaluated to false

I am working on cleaning of Lint_warnings. In that one warning is that " conditional expression is statically evaluated to false ". The message detail is Constant conditional expression is encountered. As a result the statements in the false branches of the ‘if’ block will not be analyzed.
please help me on this.
Thanks in advance.

In reply to kichu:

This is basically a dead code warning, code that will never get executed. To get rid of the warning message you need to either fix the conditional expression so it is no longer a constant, or get rid of the conditional-if statement. We can’t help you without seeing any code or knowing what the intended behavior is supposed to be.

In reply to dave_59:

Hi dave, really thanks for your reply.
But I am not able to find the issue exactly where it exists.
I am sharing that little code below to get more help. It is showing warning at line number 11(`axiMemSlaveInfo).
The ‘strb’ is 4 bit variable here.
If possible can you please any idea now ??

1 function void do_write_mem (
2 input bit [ADDR_WIDTH-1:0] addr,
3 input bit [DATA_WIDTH-1:0] data,
4 input bit [STRB_WIDTH-1:0] strb);
5
6 bit [ADDR_WIDTH-BYTESEL_BITS-1:0] memIdx;
7 bit [DATA_WIDTH-1:0] expandedStrb;
8 bit [DATA_WIDTH-1:0] maskedData;
9
10 memIdx = addr[ADDR_WIDTH-1:BYTESEL_BITS];
11 axiMemSlaveInfo(5, instName, $sformatf("do_write_mem: addr=0x%h, data=0x%h, strb=0x%h, 12 ~strb=0x%h", addr, data, strb, ~strb)) 13 if (~strb == 0) begin // strb is all ones 14 targetMainMem[memIdx] = data; 15 end 16 else begin 17 expandedStrb = '0; 18 for (integer i=0; i<STRB_WIDTH; i++) begin 19 expandedStrb = expandedStrb >> 8; 20 if (strb[i]) begin 21 expandedStrb[DATA_WIDTH-1:DATA_WIDTH-8] = '1; 22 end 23 end 24 if (targetMainMem.exists(memIdx)) begin 25 maskedData = (targetMainMem[memIdx] & (~expandedStrb)) 26 | (data & expandedStrb); 27 end 28 else begin 29 maskedData = (data & expandedStrb); 30 end 31 if (!targetMainMemErrors.exists(memIdx) || targetMainMemErrors[memIdx] === 0) 32 targetMainMem[memIdx] = maskedData; 33 else 34 targetMainMem[memIdx] = 0; 35 end 36 axiMemSlaveInfo(5, instName, $sformatf(“do_write_mem: Wrote 0x%h to memory index 0x%h”, 37 maskedData, memIdx))
38 endfunction : do_write_mem