Re: Another EU 2.5 suggestion...

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

--- Isaac Raway <isaac-topica at blueapples.org> wrote:
> 
> Matt Lewis wrote:
> 
> >As others have noted, Euphoria *can* be compiled (using the Euphoria 
> >runtime library).  In order to have the eval() functionality, though, 
> >you'd probably need an additional library to do the parsing, as well as a 
> >thin interpreter that could call the run time libarary.
> >
> No, it cannot be compiled.
> 
> An approximately equivalent C source file can be generated, which is
> then compiled. This is very different from an actual compiler, as it
> introduces another layer in the process with it's own questions. Such a
> question was cited in another response to this thread, where Aku assumed
> that the translator should discard variable names. I don't know that it
> does this now, as I don=92t use it, but it certainly is not a requirement
> that it does.

I think we're getting into semantics here.  We could get real silly and say
that compiling doesn't give you an executable--you have to link first.  So the
translation is just another step in the process (like a preprocessor). 
Variable names aren't exactly dropped, but they aren't currently stored in a
symbol table.  This would be part of the job of the extra libraries that I
mentioned.

> The facility I described (euParse(), euRun() and eval()) should execute
> just fine in a translated program. If not, then the translator would be
> changing the semantics of the program to the point that little else
> should be expected to execute properly either.

I don't think this is the proper way to go.  What about dynamically created
code to be eval'd?  There's no way to pre-translate/compile that.
 
> Even if would not work in a translated program, this should not be of
> concern to a new version of the language. The translator will just have
> to "grow up", so to speak, and support the new feature.

I agree, it just has to be planned out.  But it also has to be below a certain
level of complexity, I suspect, before Rob would agree to implement it.

Matt Lewis


__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free web site building tool. Try it!
http://webhosting.yahoo.com/ps/sb/

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

Search



Quick Links

User menu

Not signed in.

Misc Menu