Re: Java's performance far better that optimized C++

From: Rob Williscroft (rtw_at_freenet.co.uk)
Date: 06/17/04


Date: 17 Jun 2004 09:10:21 GMT

Mark A. Gibbs wrote in news:479Ac.292231$Ar.124314
@twister01.bloor.is.net.cable.rogers.com in comp.lang.c++:

> assert some_test() : "Message on assertion fail";
>
> is actually:
>
> if (assertions_enabled_)
> {
> if (some_test())
> {
> throw new AssertionError("Message on assertion fail");
> }
> }
>
>

Why, when loading the class without asserts enabled can't the loader
just strip the whole thing ?. (rhetorical - of course it can).

Indeed (since were in c.l.c++) can't a C++ compiler compile to the
the java vm (I'm told its turing complete :) and #define assert( x )
as:

#define assert( x ) emit( "assert (%b) : \" #x "\";", x )

Not a fan of java BTW, just bored with this whole nonsense thread.

Rob.

-- 
http://www.victim-prime.dsl.pipex.com/


Relevant Pages

  • Re: XP SP3 will not boot
    ... As the OS is loading, it gets to a point loading ... I noticed in another post some issues with AMD processors. ... Thanks for you help Mark. ... Mark L. Ferguson MS-MVP ...
    (microsoft.public.windowsxp.help_and_support)
  • Re: Humax PVR-9200T - upgrading loader version
    ... I assume you have loader version 4.07 (which says STING on the front panel ... while it is loading) and want to upgrade to 4.09. ... sound from SCART pass-through with the new loader - rather annoying if you ... are watching a videotape. ...
    (uk.tech.digital-tv)
  • Re: Avoiding templates, alternative design?
    ... > Mark A. Gibbs (aka. Indi) ...
    (alt.comp.lang.learn.c-cpp)
  • Re: Avoiding templates, alternative design?
    ... > Mark A. Gibbs (aka. Indi) ...
    (comp.lang.cpp)
  • Re: function adaptors for member functions
    ... Mark A. Gibbs wrote: ... so i rewrote it in place just to give you the gist of the problem. ... > helper function cause it means i'm gonna need like twenty of them. ...
    (comp.lang.cpp)