[plt-scheme] equal? for native extension types [patch]

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Tue Feb 13 20:41:16 EST 2007

BTW, I see that the test file has

 typedef struct {
   Scheme_Type type;
   int x;
 } dummy;

That was right a few versions back, but new Scheme types should now
start with `Scheme_Object' instead of `Scheme_Type':

 typedef struct {
   Scheme_Object so; /* set so.type, which is a Scheme_Type */
   int x;
 } dummy;

It usually doesn't matter for CGC, though casts between `dummy*' and
`Scheme_Object*' can run afoul of C99 aliasing rules if you use
`Scheme_Type'. Also, the difference is important for 3m, where
`Scheme_Object' has an extra field.

I see that some of the examples in "collects/mzscheme/examples" are
wrong, too, and I'll fix those.


Posted on the users mailing list.