Not quite right. the size constant "2" in 2'h08 means two bits. According Verilog LRM IEEE 1800:
The first token, a size constant, shall specify the size of the integer literal constant in terms of its exact
number of bits. It shall be specified as a nonzero unsigned decimal number. For example, the size
specification for two hexadecimal digits is eight because one hexadecimal digit requires 4 bits.
The compiler should give a warning that the specified number value exceeds the bit length. The actual value would be 2'b00, the intended constant is 8'h08. The other question is, what happens if you compare integers of different bit length.
--- Updated ---
According to LRM
If the operands are of unequal bit lengths, the smaller operand shall be zero-extended to the size of the larger operand.
Respectively the actual relational expression is 8'b0000 < 8'b1001, value should be 1 (true). Presumed, the original post doesn't hide some important information, e.g. the numbers are signed rather than unsigned.
Curiously, the comparison result would be 1 in both cases, there must be another hidden point. Need to see the complete code containing the comparison.