Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Omitted information concerning exceptions that could be raised. #6168
Original bug ID: 6168
Unix.stat function may raise Unix.Unix_error exception.
Like in case of Unix.execv and others, it would be beneficial to state it also explicitely in case of Unix.stat function.
(If that is the intended documenting policy concerning exceptions.)
I've reported similar problem before:
There may be more of these kind of omissions.
Comment author: @xavierleroy
Any single function from the Unix module can raise Unix_error if the underlying system call fails. There is no point in mentioning it for every single function.
The documentation for the Unix module says:
"exception Unix_error of error * string * string
Raised by the system calls below when an error is encountered. [...]"
If this is not clear enough, we should make it clearer that any of the Unix functions can raise Unix_error. But please don't submit one bug report per Unix function.