Re: Cracking DES with C++ is faster than Java?
From: Phil Carmody (thefatphil_demunged_at_yahoo.co.uk)
Date: 04/28/04
- Next message: Bernard Koninckx: "Re: validating xml with an external DTD"
- Previous message: Psycho0190: "MFC Application using the JNI (Java Native Interface)"
- In reply to: Julie: "Re: Cracking DES with C++ is faster than Java?"
- Next in thread: Douglas A. Gwyn: "Re: Cracking DES with C++ is faster than Java?"
- Reply: Douglas A. Gwyn: "Re: Cracking DES with C++ is faster than Java?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 28 Apr 2004 11:05:54 +0300
Julie <julie@nospam.com> writes:
> "Douglas A. Gwyn" wrote:
> >
> > Julie wrote:
> > > What is being talked about is if you take a C source file and create an
> > > executable, then take that same source file and compile it as C++, you will end
> > > up w/ (virtually) identical executables.
> >
> > (Since the languages do not have a subset/
> > superset relationship,
>
> ??? How have you determined that? Do you have any substantive references?
How about the standards? Doug is more well aware of the standard than most.
How about the section in Stroustrup that covers things that used to be legal
in C that aren't legal in C++?
> not, name something that exists in C but not C++ (excluding new C features
> introduced since the last C++ standard).
There are hundreds of examples.
Dumb examples, which you should have been able to work out yourself, would
be major changes to language structure such as:
- Use of C++-only keywords as variable names is legal in C,
int class;
- Change in comment syntax, the ability in trad C to have a /*comment*/
immmediately after a division symbol.
i = x//**/y
;
> > in general compiling a
> > C source program with a C++ compiler is not safe.)
However, I'd disagree with Doug's "in general" - unless he means
"given arbitrary source by other people". I frequently migrate
my own old C code to C++ with no changes at all. I don't remember
the last time I encountered _any_ of the many issues.
In general, for me, it is perfectly safe to compile as C++ the code
that I have previously been compiling as C. I know others who
migrate code safely too. In fact in general, people I know migrate
code safely.
Phil
-- 1st bug in MS win2k source code found after 20 minutes: scanline.cpp 2nd and 3rd bug found after 10 more minutes: gethost.c Both non-exploitable. (The 2nd/3rd ones might be, depending on the CRTL)
- Next message: Bernard Koninckx: "Re: validating xml with an external DTD"
- Previous message: Psycho0190: "MFC Application using the JNI (Java Native Interface)"
- In reply to: Julie: "Re: Cracking DES with C++ is faster than Java?"
- Next in thread: Douglas A. Gwyn: "Re: Cracking DES with C++ is faster than Java?"
- Reply: Douglas A. Gwyn: "Re: Cracking DES with C++ is faster than Java?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|