By using always_latch or always_ff a designers intent to infer a latch or a sequential logic respectively, but if the logic is not correct software tools can warn the designer that the intended hardware logic is not inferred properly.
eg:
always_ff @ (posedge clk or negedge rst)
begin
if (!rst)
a <= '0;
end
For the above code the designer intended to get only a sequential logic and not a latch but a latch would be generated in actual (Any static tool will generate a warning message as "Latch will be inferred for the logic")
Similarly for the below code the designers intent is to infer a hardware latch so tool will(understand your logic better) and won't report it.
always_latch
begin
if (rst)
a <= b;
end
Latch is a sequential logic which works on levels of clocks instead of clock edges.
In general best practice is to use Non-blocking assignments for sequential logic and blocking assignments for combinatorial logic which is explained in detail under Section 5.0
Verilog coding guidelines of Nonblocking Assignments in Verilog Synthesis, Coding Styles That Kill!
Guideline #2: When modeling latches, use nonblocking assignments.