CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Page 3 of 3 FirstFirst 123
Results 31 to 37 of 37
  1. #31
    Join Date
    Feb 2003
    Location
    Iasi - Romania
    Posts
    8,244

    Re: Am I ready for C++ and MFC ?

    Quote Originally Posted by Paul McKenzie View Post
    Doing 'C' things on these types usually results in undefined behaviour.
    One possible next question may be:
    "Hi Paul,
    what you mean by undefined behaviour ?"
    Ovidiu
    "When in Rome, do as Romans do."
    My latest articles: https://codexpertro.wordpress.com/

  2. #32
    Join Date
    May 2004
    Posts
    7

    Re: Am I ready for C++ and MFC ?

    You never say what you plan to do with programming once you learn C or C++.

    I used to program in C++, including managed C++, C, VisualBasic, Pascal, etc. Since C# came out I haven't bothered with C++. It's much easier to write Windows program in C# than in C++. Also, managed C++ is a very wierd form of C++, not at all standard.

    IMO, the main reasons for using C++ are:
    1. To support legacy programs.
    2. To write low level code, like device drivers
    and 3. To write code that is portable to other operating systems

  3. #33
    Join Date
    Apr 2008
    Posts
    725

    Re: Am I ready for C++ and MFC ?

    4. when you need to control memory management.
    5. when other dependencies are not acceptable e.g. .net

  4. #34
    Join Date
    Apr 2000
    Location
    Belgium (Europe)
    Posts
    4,626

    Re: Am I ready for C++ and MFC ?

    While it certainly is possible to have sources in a variety of languages and then link these into a single binary, personal experience in this matter would make me recommend avoiding this. It invariably causes a number of issues, especially if not everyone on the team is equally proficient in each of the languages.

    If you have a project where several parts HAVE to be made in different languages, I would recommend making each of the languages build their own binary (DLL's) and use the defined exports of those. While it takes some more planning and setting up different projects at the start, it usually is much more convenient down the road.

  5. #35
    Join Date
    Apr 2000
    Location
    Belgium (Europe)
    Posts
    4,626

    Re: Am I ready for C++ and MFC ?

    As to why c++

    6. When performance matters
    7. When you have developed good libraries and follow some basic rules, C++ is just as easy to use as C# to write (windows) programs. The rules aren't necessarily a limitation. You can write "bad" programs in C# just as well.
    8. When timely resource recuperation matters. (garbage collection is notoriously bad in this respect).
    ... to be continued ...

  6. #36
    Join Date
    May 2004
    Posts
    7

    Re: Am I ready for C++ and MFC ?

    Certainly those other items, 4 - 8, may justify using C++ instead of C#, but for most programs those considerations don't usually come into play. By the way, I'm really talking about writing Windows programs. For other OS's there may be other considerations.

    I'm not sure that item 7, saying C++ is just as easy to use as C#, is true. Not having to worry about pointers, or that wierd caret notation, or making sure that you are really writing managed code, makes C# a lot easier to write.

    Also, DanLeon /C++ for. Since he is just learning, if he wants to write Windows programs, C# is really the way to go.

  7. #37
    Join Date
    Apr 2008
    Posts
    725

    Re: Am I ready for C++ and MFC ?

    Quote Originally Posted by cgantz2000 View Post
    Certainly those other items, 4 - 8, may justify using C++ instead of C#, but for most programs those considerations don't usually come into play. By the way, I'm really talking about writing Windows programs. For other OS's there may be other considerations.

    I'm not sure that item 7, saying C++ is just as easy to use as C#, is true. Not having to worry about pointers, or that wierd caret notation, or making sure that you are really writing managed code, makes C# a lot easier to write.

    Also, DanLeon /C++ for. Since he is just learning, if he wants to write Windows programs, C# is really the way to go.
    they were reasons to use c++. The caret syntax is "Managed c++" and therefore not c++. Pointers are a non-issue with smart pointers, namely boost or maybe Qt, not std::auto_ptr. No one was talking about reasons to use managed, or suggesting that someone starting out should look into managed c++.

Page 3 of 3 FirstFirst 123

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured