What version of C++ is good ?

This is a discussion on What version of C++ is good ? within the C++ Programming forums, part of the General Programming Boards category; I am currently using VC++ 2008 Express Edition. As I have understand this is non-standard and therefor other versions of ...

  1. #1
    Registered User
    Join Date
    Dec 2007
    Posts
    383

    What version of C++ is good ?

    I am currently using VC++ 2008 Express Edition.
    As I have understand this is non-standard and therefor other versions of
    C++ could be a better choice.

    What I wonder is, what version of C++ is a better alternative.
    To keep in mind is that I need a version that reads .txt files and do Very fast calculations on these and on Arrays as I am very depending of that.

    VC++ 2008 does fast calculations and from what I understand C# is a bit slower on that part and calculations on Arrays.
    I would also be happy to use C# 2008 Express Edition if it really is that fast in calculations as the VC++ 2008 Express Edition.
    So I need a combination of Windows Form Application and fast Calculations.

    Thanks in advance !
    Last edited by Coding; 02-10-2008 at 05:19 AM.

  2. #2
    C++まいる!Cをこわせ! Elysia's Avatar
    Join Date
    Oct 2007
    Posts
    22,538
    You seem to misunderstand.
    C++ is native and always been and always will be. Microsoft introduced their own C++ targeting the .NET Framework. This C++ is non-standard and it referred to C++ .NET, or Managed C++. This is slow.
    C# is also managed and targets the .NET Framework, but is standard. But the whole managed business is slow.
    Native C++, the real C++, is what you want. And that is using the edition you're using now. Do Win32 projects and not Windows Forms.

    There is no such thing as Windows Form Application and fast calculations. Well, unless you're willing to write dlls in C++ and interoperate to those dlls from C#, which can use Windows Forms. This is also acceptable, but tricky.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  3. #3
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,893
    You seem to misunderstand, Elysia. C++ does not specify any execution model at all.

    All right. You could say that there's three versions of C++. The first is pre-standard C++. This is roughly what Bjarne Stroustrup developed over the years. It doesn't have any properly specified feature set, and compilers built to this differ widely. Thankfully, they're also nearly extinct. Turbo C++ 3.0 and Visual C++ 6 are the last pre-standard compilers that still see some use, from what I can tell.)
    The second is C++98 (and its minor revision, C++03), based on the 1998 ISO C++ standard (or the 2003 revision, incorporating all resolved defect reports to this point). All current compilers aim to support this standard to the best extent possible; few if any manage it fully.
    The third is the upcoming C++09, the major revision of the C++ standard hopefully to be completed in 2009. Compilers are slowly starting to implement some of its features as experimental extensions; e.g. GCC 4.3 has support for quite a few of them.

    Now, separate from that are compilers and their versions. The most popular compilers are GCC and MSC.
    GCC is the GNU Compiler Collection, the dominant compiler on Linux, but also exists for many other OSs, including Windows (as part of the MinGW project). It supports many, many different platforms, is highly conforming to the standard, and produces quite good code.
    MSC is Microsoft's C and C++ compiler. It is part of the Visual Studio suite and thus better known as Visual C++. It has acceptable to good standards conformance (since 7.1, i.e. Visual C++.Net 2003, improving in every subsequent version) and produces very good code, but only for Windows platforms. It's also considerably faster at compiling than GCC.
    Other compilers of interest are Comeau C++, for its extreme standards compliance, and Intel C++, for its exceptional code generation (IA-32, IA-64 and Intel 64 architectures only, of course).


    And then there's the C++-similar stuff. Managed C++ was Microsoft's first attempt at getting C++ to interoperate with their .Net framework. It was a spectacular failure. It was ugly and bugly.
    C++/CLI was their second, considerably better attempt. It's still a horrible hybrid of poorly interacting features, but at least it won't hang your DLLs. It also has an ECMA standard going for it.
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

  4. #4
    C++まいる!Cをこわせ! Elysia's Avatar
    Join Date
    Oct 2007
    Posts
    22,538
    Microsoft and their stupid languages.
    C++/CLI is just managed 2.0, even though it's being standardized. They pretty much ruined the syntax too.
    However, it's still managed so using native with is not the easiest thing.
    And managed is slow. Remember that.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  5. #5
    Registered User
    Join Date
    Sep 2006
    Posts
    835
    > The third is the upcoming C++09, the major revision of the C++ standard hopefully to be completed in
    > 2009. Compilers are slowly starting to implement some of its features as experimental extensions; e.g. GCC 4.3
    > has support for quite a few of them.

    After the C++98 standard came out, do you know how much of a time lag there was before compilers (in particular GCC) had reasonably full support, and do you think it will be roughly the same after C++09? I'm wondering how long it will be before being able to write code (in particular threaded code) using it. Also, do you know why there's such a long lag after C99 with most compilers still not fully supporting it? Is it just lack of demand?

  6. #6
    C++まいる!Cをこわせ! Elysia's Avatar
    Join Date
    Oct 2007
    Posts
    22,538
    I'm thinking it's also because of the difficulty in writing a compiler plus the time it takes to create an implementation of the features for the standard.
    And compiler vendors are afraid to start implementing things before the standard is actually finished, because they've gotten burned before.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  7. #7
    Emulator
    Join Date
    Feb 2008
    Posts
    43
    Well i'm using Dev C++ and I do not recommend VC++.
    Hand over your source code, and nobody gets hurt.

  8. #8
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Portugal
    Posts
    7,436
    Quote Originally Posted by robatino View Post
    Also, do you know why there's such a long lag after C99 with most compilers still not fully supporting it? Is it just lack of demand?
    I'm in no way in the know. So I apologize if what I'm saying is incorrect. However, the general feeling I have as a hobbyist without any kind of urge to know everything about C or C++, is the fact C99 did manage to separate C and C++ paths. I don't feel C as a subset of C++ anymore (or C++ as a superset of C, for the more sensitive). Particularly because the C committee seemed to insist at the time in bringing new features through changes to language instead of library additions.

    I'm unsure if the upcoming C++09 manages do close the gap, or make it less wide. And that is the reason of the wait. Visual C++, for instance, seems to ignore for the most part C99.
    The programmer’s wife tells him: “Run to the store and pick up a loaf of bread. If they have eggs, get a dozen.”
    The programmer comes home with 12 loaves of bread.


    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  9. #9
    C++まいる!Cをこわせ! Elysia's Avatar
    Join Date
    Oct 2007
    Posts
    22,538
    Quote Originally Posted by PЯO View Post
    ...and I do not recommend VC++.
    Why?
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  10. #10
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,893
    GCC's adoption of C++98 was fluid, as becomes an open-source project. It's hard to say when it had reasonable support, although my memories seem to point to 3.2 as a version that sees a significant drop in the number of workarounds employed in Boost (typically a pretty good measure of conformance).
    MS's adoption, on the other hand, was sudden. They released VC++6 only months before the ratification of C++98 - from what I heard in an only partially successful attempt to force the committee to see their way in a few contentious issues - and then did nothing for a long time. VC++.Net 2002 came out in 2002 and provided an updated standard library, but nearly no improvements in the compiler itself. (They were probably busy with Managed C++.) VC++.Net 2003 came out a year later and finally contained a massive leap towards conformance.
    Given MS's current stance on the issue, however, I expect support for the bulk of C++09 to be considerably faster, perhaps as soon as 2011.


    As for C99, I think the lack of adoption is simply because nobody cares about this update. The C programmers seem generally happy with what they have.
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

  11. #11
    Super Moderator VirtualAce's Avatar
    Join Date
    Aug 2001
    Posts
    9,596
    I use MSVS 2005 at home and 2003 at work. Personally I'd be lost without the nice features you get with MSVS. I'm not a MS hater or an MS lover but they deserve some props for 2003 and 2005. 2003 is horrible with C# and can hose your project but that's been fixed in 2005. 2005 is an extremely good compiler which produces very good code (for the Windows platform). I've not experienced 2008 yet but I will be purchasing it when it hits the shelves. And they updated MFC which shows me .NET CLI was a miserable failure. If they had not altered the syntax of C++ just to get .NET to work it probably would have been more well received. A lot of programmers would not mind calling out to this library or that b/c we do this every day. But changing the actual syntax of C++ and adding reserved keywords is going too far in my opinion.
    Last edited by VirtualAce; 02-10-2008 at 09:47 AM.

  12. #12
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,893
    C++/CLI is and remains a glue language. Thus, it must work with classic C++ and .Net equally. Thus, it requires separate syntax for each.

    The design choices are appropriate for a glue language. In my opinion, the problem is that marketing failed to remember that that was all that it was.
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

  13. #13
    Registered User
    Join Date
    Oct 2001
    Posts
    2,129
    How does C++.NET fit into all of this?

  14. #14
    C++まいる!Cをこわせ! Elysia's Avatar
    Join Date
    Oct 2007
    Posts
    22,538
    .NET is Managed C++... the nonstandard one.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  15. #15
    Registered User
    Join Date
    Oct 2001
    Posts
    2,129
    Oh ok so they're the same thing.

Page 1 of 2 12 LastLast
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Problem building Quake source
    By Silvercord in forum Game Programming
    Replies: 16
    Last Post: 07-11-2010, 09:13 AM
  2. OpenGl Version
    By Nextstopearth in forum Game Programming
    Replies: 6
    Last Post: 11-26-2008, 06:56 AM
  3. Question about atheists
    By gcn_zelda in forum A Brief History of Cprogramming.com
    Replies: 160
    Last Post: 08-11-2003, 11:50 AM
  4. Just made a big-ass trade: was it good?
    By civix in forum A Brief History of Cprogramming.com
    Replies: 41
    Last Post: 01-20-2003, 08:14 AM
  5. i need links to good windows tuts...
    By Jackmar in forum Windows Programming
    Replies: 3
    Last Post: 05-18-2002, 11:16 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21