I created a function to compute the AES S-Box. This is its code:
let sBox k =
match k with
| 0uy -> 0x63uy
| 1uy -> 0x7cuy
| 2uy -> 0x77uy
| 3uy -> 0x7buy
/// It lasts forever...
| 251uy -> 0x0fuy
| 252uy -> 0xb0uy
| 253uy -> 0x54uy
| 254uy -> 0xbbuy
| 255uy -> 0x16uy
However, the compiler raises an "Incomplete pattern matches on this expression" warning, even though my code handles all 256 possible cases for the byte type.
Repro steps
Already covered.
Expected behavior
Code compiles successfuly without warnings.
Actual behavior

Known workarounds
Have a redundant wildcard case at the end of match statement.
I created a function to compute the AES S-Box. This is its code:
However, the compiler raises an "Incomplete pattern matches on this expression" warning, even though my code handles all 256 possible cases for the
bytetype.Repro steps
Already covered.
Expected behavior
Code compiles successfuly without warnings.
Actual behavior
Known workarounds
Have a redundant wildcard case at the end of
matchstatement.