[Dynamite] compile status

Ewan Birney birney@ebi.ac.uk
Sat, 15 Apr 2000 19:00:29 +0100 (BST)


a) I have a cvs repository. It is at /home/birney/repository - module -
telegraph. Layout is reasonably self explanatory

b) I had to do quite a bit of editing to get the basic C generated by the
compile to work. This is checked in as Edits in the compiler directory - I
could not make good sense of the idlstubs perl - this is common with
compilers as the parse tree is usually at odds with the logical output...

The src/SeqModule has the generated *and then edited* .c files in them.
Ian - you need to check out the repository if possible and go through my
edit points. Once we get the idlstubs program generating valid and correct
C that will really help us.

I had a crisis in confidence about whether we should be writing our own
compiler or not. Or whether we should be going to C++. Or standard C CORBA
mapping. I got over it. We should see how this pans out and then reasses
what is going on. At the end of the day, the implementation from well
defined definitions is the easiest part of this project. (if a little
tedious).


Cat'ing the Edits in so that Ian has a idea of what to do.

BTW - Ian - awesome perl script. Your perl level is way above mine.


# generic problem in putting * in the wrong place for pointer-to-func
# declarations
typedef euString (*Seq_LightSeq_name_ptr) (Seq_LightSeq);     /* pointer
to nam
 method */


# line missing ;
void Seq_unref_impl (void*);          /* implementation destructor */

# to get size information into seqmodule_priv.c it needs to include
# seqmodule_impl.h
#include "seqmodule_impl.h"


# casts from eu_malloc/eu_calloc to pointer types in priv.c
 
  switch (lightSeq->_priv.ref--)
    {
    case 0:
      Seq_LightSeq_raise (lightSeq, Seq_LightSeq_BadReferenceCount);
      break;
    case 1:
      (*lightSeq->_priv.unref_impl) (lightSeq->_priv.deriv);   /* call
implemen
ation destructor */
      (*lightSeq->_priv.swansong) (lightSeq->_priv.deriv);     /* call
Euclid d
structor */
      break;
    default:
      break;
    }


# structs need to have _str removed in the callocs to build them
seqmodule_priv.c: In function `Seq_SeqImage_calloc':
seqmodule_priv.c:94: `Seq_SeqImage_str' undeclared (first use in this
function)
seqmodule_priv.c:94: (Each undeclared identifier is reported only once
seqmodule_priv.c:94: for each function it appears in.)


#duplication of Euclid ref/unref/dump calls for Seq and other objects
# in priv.c

# no cast in unref chains in impl.c
void Seq_unref_impl (void* seq)
{
  Seq_LightSeq_unref_impl (((Seq)seq)->lightSeq);     /* chained
unref_impl */
}


# type mismatch between pub.h declaration of dump_impl and impl.c
# stub function. solved by editing pub.h
 


-----------------------------------------------------------------
Ewan Birney. Mobile: +44 (0)7970 151230, Work: +44 1223 494420
<birney@ebi.ac.uk>. 
-----------------------------------------------------------------