Suggestion of improving error reporting.
Alan Aspuru-Guzik
alan@aspuru.com
Fri Jul 23 10:45:00 GMT 2004
Dear all,
As always I thank Brian and all the authors for the library I use for my
own work all the time.
There is a small suggestions that could improve the life of us, the
developers a lot:
When a matrix is wrongly accessed, one gets the following errors:
#if GSL_RANGE_CHECK
if (i >= m->size1)
{
GSL_ERROR_VAL("first index out of range", GSL_EINVAL, 0) ;
}
else if (j >= m->size2)
{
GSL_ERROR_VAL("second index out of range", GSL_EINVAL, 0) ;
}
#endif
Would it be possible to report the indexes and also the two sizes of the
matrix (or the index and the size of the vector) so when somebody
debugs, one doesn't need to go to the debugger or printf to find it?
If peple think it is useful, I could write a patch for this.
Alan
--
- - - - - - - - - - - - - [ cut here ] - - - - - - - - - - - - - - - - -
Alán Aspuru-Guzik [http://alan.aspuru.com]
More information about the Gsl-discuss
mailing list