I'm still wanting to convert HDS to use a more typesafe data structure to
represent locators.
ie
typedef struct hdsloc {
char loc[DAT__SZLOC];
} hdsloc;
rather than
char loc[DAT__SZLOC];
As you know, at issue is the 4 NDF C routines that either use or return
locators.
I've looked through the CVS tree and it seems that there is a little bit
in GAIA and CCDPACK that uses locators with C NDF and a little bit more in
ICL and CONVERT. Hardly a lot and it seems it is definitely manageable
from the view point of fixing up the CVS code. Of course, some of those
routines may be using locators to call fortran HDS but some of them will
simply be using null locators for ndfFind etc.
What I'm really saying is that I am going to take this work on unless
someone "talks me down" using the "but hundreds of users around the world
use C NDF interface for their own programs and they will be upset"
argument. I'll counter this on the grounds that
* If they are using DAT__ROOT locators then it will be a trivial change
to their code to make it work.
* If they are using HDS then they have bigger problems anyway because
there was no official C interface to HDS at the time (and it still isn't
complete). Those people can make the short declaration change and simply
use loc->loc when calling the Fortran directly.
So I'm not convinced this is a big deal. If people really really object
then those 4 routines in NDF can stay as they are and 4 new routines can
be added with an "S" (for struct) suffix. eg ndfFindS. Then old code will
still work fine. I just don't like adding 4 new routines like that.
[What I'd really like is to change all the "int indf" to Ndf* just like in
Grp but I'm assuming that I won't get many positives in that attempt].
--
Tim Jenness
JAC software
http://www.jach.hawaii.edu/~timj
|