Re: load user defined module

new topic     » goto parent     » topic index » view thread      » older message » newer message

Derek Parnell writes:
> Robert,
> is this the sort of thing you are suggesting for us ? ...
> ...
> ...
> As you could imagine, it would not take much for this to
> become very hard to maintain. Can you suggest a better approach?

I don't know. There are various approaches that you could take.
Igor's dynamic include approach is one, although it won't
work with the binder or translator.
A lot depends on the specific situation - how much code is in
common across platforms, can the differences be expressed as
different data rather than different code, etc. You might even
use 3 different sequences of routine id's for 3 platforms.
I'm sure you can come up with as good a solution as I might.
The conditional compilation approach can get ugly too.
If you look at the C source for Euphoria, you'll see sections of
very ugly code because of all the conditional compilation
directives for different platforms. I do it because people
demand maximum speed and minimum interpreter size.
I'd need to see some real cross-platform examples 
to get interested in adding conditional compilation.
I just haven't seen many.

Regards,
   Rob Craig
   Rapid Deployment Software
   http://www.RapidEuphoria.com

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu