]> git.lizzy.rs Git - rust.git/commit
io::ErrorKind: rationalise ordering in main enum
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Tue, 24 Aug 2021 15:53:58 +0000 (16:53 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Tue, 24 Aug 2021 15:53:58 +0000 (16:53 +0100)
commit4c0203eb4b3406cd2088c5d0092a0445294e2f6c
treeb1199f5012ed6171ac1b5cd0cd887428fbe36d7d
parent54df693dd7e6668b78f0636e269f7f928d4932d2
io::ErrorKind: rationalise ordering in main enum

It is useful to keep some coherent structure to this ordering.  In
particular, Other and Uncategorized should be next to each other, at
the end.

Also it seems to make sense to treat UnexpectedEof and OutOfMemory
specially, since they are not like the other errors (despite
OutOfMemory also being generatable by some OS errors).

So:
 * Move Other to the end, just before Uncategorized
 * Move Unsupported to between Interrupted and UnexpectedEof
 * Add some comments documenting where to add things

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
library/std/src/io/error.rs