On 05/04/2009, at 12:15 AM, Emmanuel Onzon wrote: > > Erick missed that, but I fixed it .. it is VERY UGLY because > basically EVERY production has to > return every non-terminal in its RHS in a Bind_to_const list. So > each non-terminal is bound > on EVERY occurrence. DSSL structure could fix that by requiring all > global non-terminals > be defined, but it is still a pain because if you import another > DSSL into this one, > you have to bind every non-terminal in it (in case of recursion we > can have forward > references). > > If you have a better interface in mind I'm open to suggestions. > I think I could add an option that would allow to define > a default constructor. Each time a new non terminal is not > bound to a constructor, it would be bound to the default one. > Would that solve the problem of ugliness ? >
No, I think that is dangerous: this is the users problem. It is extra work, Felix has to scan all the productions or otherwise properly manage the grammar so it KNOWS all the non-terminals before submitting to Dypgen. My fix is a hack that's all. I hate defaults .. don't go there, one uses them then doesn't know how to handle the exceptions or that the system is secretly doing things. By the way .. the bug is now fixed, everything is building :) -- john skaller skal...@users.sourceforge.net ------------------------------------------------------------------------------ _______________________________________________ Felix-language mailing list Felix-language@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/felix-language