[Prev][Next][Index][Thread]

Re: d2c - processing error in Define Class



In article <889atr$i$1@mserv2.dl.ac.uk>,
  "Gareth Baker" <G.J.Baker@dl.ac.uk> wrote:
>
> define constant <a_new_type> = one-of(#"t1", #"t2", ..., #"t17");
>
> define class <new_class> (<object>)
>     slot a_slot :: <a_new_type>;
> end class;
>
[snip d2c problem with above code]
>
> does anyone know what d2c is complaining about. The code compiles OK
with
> Fun-O Dylan.

Hm!  Maybe I'm doing something incorrect here, but I enter your code
into the FD playground.  The first statement compiles okay, but the
second returns a 'Reference to undefined binding "<a_new_type>"' error.

BUT!  When I convert your underscores to dashes ("_" => "-") in all the
names, it works fine.  This is on FD version 2.0 beta 3.  Underscores
*should* be okay (according to the DRM they are "graphic characters",
but they are allowed in names under certain conditions that your names
appear to follow), maybe FD (and perhaps also) d2c are a bit more picky
about how you name names.  Have you tried your code in d2c using dashes
instead of underscores?

Sincerely,
Douglas M. Auclair
Dylan evangelization through education


Sent via Deja.com http://www.deja.com/
Before you buy.



Follow-Ups: