Title | Documentation could say more about meaning of result codes |
Status | closed |
Priority | nice |
Assigned user | Richard Brooksby |
Organization | Ravenbrook |
Description | The reference manual entry for mps_res_t [1] says, "see the documentation of the function" for the meaning of MPS_RES_FAIL, but in fact very few functions list possible result codes that might be returned by a function or what they mean. (Usually the description is something like, "MPS_RES_OK if successful, some other result code otherwise.") I wrote an explanation for this: "The modular nature of the MPS means that it is not usually possible for a function description to list the possible error codes that it might return. A function in the public interface typically calls methods of an arena class and one or more pool classes, any of which might fail. The MPS is extensible with new arena and pool classes, which might fail in new and interesting ways, so the only future-proof behaviour is for a client program to assume that any MPS function that returns a result code can return any result code." However, RB thinks there may be cases where we could in fact say a bit more about the meaning of some of the result codes returned by some of the functions. |
Analysis | This would require a lot of inspection, and I think the value is quite low. Wash your dog before doing this. GDR 2013-05-16: job003485 has another proposal for improving error handling. |
How found | inspection |
Evidence | [1] <http://info.ravenbrook.com/project/mps/version/1.110/manual/reference/#mps_res_t > |
Observed in | 1.110.0 |
Created by | Gareth Rees |
Created on | 2012-10-24 15:37:01 |
Last modified by | Gareth Rees |
Last modified on | 2018-06-26 09:12:40 |
History | 2012-10-24 GDR Created. |
Change | Effect | Date | User | Description |
---|---|---|---|---|
180049 | closed | 2012-10-24 12:26:07 | Gareth Rees | Write error chapter. |