This is a good slogan, but there's some subtleties when it comes to HTTP status codes. That is, there are the defined ones, but any number is legit, so you end up with an enum with a member that's basically "anything we don't know about", so it's not as clear-cut as it is in other situations.
Good point, this is where Rust's flexible enums are an advantage relative to C-style. If you'll forgive the Haskell syntax, you can have something like:
data StatusCoode
= Ok200
| Missing404
| Error500
| OtherStatusCode Int
To rephrase the slogan a bit - make an illegal state a bit more difficult to represent or at least the risk of an illegal state clear to the programmer.
And of course a problem with this is any status code now has two representations: the canonical enum variant, and the catch-all variant with the same numeric value.
As Jane Street Says, make illegal state unrepresentable.