Re: Re: Flat Short of MEMORY_BLOCK

Eric Bezault <ericb-D6Qt/9opevxWk0Htik3J/[email protected]>
Newsgroups gmane.comp.lang.eiffel.gobo.general
Organization Gobo
Message-ID <[email protected]>
Franck Arnaud wrote:
> I think Brian later asked whether inline C was OK within 
> ifdef for a compiler (subset) that needs a C compiler, so 
> perhaps something like.
> 
> #ifdef COMPILER_IN_MODE_THAT_REQUIRES_C_COMPILER
>   ... inline C ...
> #else
>   regular Eiffel
> #endif
> 
> This does not suffer the problem of requiring a C compiler 
> when not necessary, but on the other hand we usually want to 
> minimise conditional code.

But why not using the regular Eiffel code all the time?
At least we won't have to modify our #ifdefs when an Eiffel
compiler which used to require a C compiler adds a compilation
mode for which it is not the case anymore.

> I don't know whether it's a good 
> idea or not (well, one thing is that if it's done for speed, 
> the difference should be benchmarked, we don't want to have 
> conditional code based on a guess).

I cannot see why user-written C code could be faster
than the equivalent functionality provided by the
compilers when they require a C compiler as back-end.
If it was faster to write inline C code, that's what
the Eiffel compiler should have provided in its Eiffel
class, no?

-- 
Eric Bezault
mailto:ericb-D6Qt/9opevxWk0Htik3J/[email protected]
http://www.gobosoft.com




To Post a message, send it to:   [email protected]
To Unsubscribe, send a blank message to: [email protected] 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
     http://groups.yahoo.com/group/gobo-eiffel/

<*> To unsubscribe from this group, send an email to:
     [email protected]

<*> Your use of Yahoo! Groups is subject to:
     http://docs.yahoo.com/info/terms/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.