Search:

Type: Posts; User: deoren

Page 1 of 3 1 2 3

Search: Search took 0.01 seconds.

  1. I wanted to reply back and mention that while...

    I wanted to reply back and mention that while looking over the errata for the next chapter I found an errata entry for the author's example code that I posted here:




    Thanks again to everyone...
  2. Well said and thanks for the reminder. I knew...

    Well said and thanks for the reminder. I knew there were many reasons given why initialization lists were preferred but I couldn't recall the details. For the most part I've been going chapter by...
  3. That is what I was thinking also. Using that...

    That is what I was thinking also. Using that approach resulted in zero issues and no memory leaks reported (that happened to be the focus of the end of the chapter).




    Thanks for that....
  4. Not sure. Here are the sources were I found the...

    Not sure. Here are the sources were I found the statement that it was allowed:


    StackOverflow comment #3194802
    Google Books, C++ Primer Plus, 6e, bottom of page
  5. Destructor will erroneously attempt to delete memory that was not allocated?

    Hi,

    First of all, thanks for reading this.

    Chapter 11 in Ivor Horton's Beginning Visual C++ 2008 is dedicated to debugging. You start off typing code exactly as presented and then as the...
  6. *Whew* Thanks for the confirmation.

    *Whew*

    Thanks for the confirmation.
  7. Chapter 9, Exercise 4 - Ordered Binary Tree - Beginning Visual C++ 2008

    I know, another binary tree thread. I found many of them when I searched prior to creating this thread, so my apologies if you're a regular and are tired of seeing them.

    Hopefully the mental block...
  8. I'm far too new to C++ to provide any help, but...

    I'm far too new to C++ to provide any help, but I'd suggest posting snippets of the error messages to provide additional details.
  9. Replies
    16
    Views
    16,030

    I'm now fairly confident I understand what you...

    I'm now fairly confident I understand what you were saying with the Animal-Dog-Cat example:



    //...
  10. Replies
    16
    Views
    16,030

    Thank you, that makes a lot of sense. I also...

    Thank you, that makes a lot of sense.

    I also worked through the example classes you mentioned and got the behavior you described, and was reminded of the same example in Larry Ullman's book. I...
  11. Replies
    16
    Views
    16,030

    MK27, I'm going to reply back to your recent...

    MK27,

    I'm going to reply back to your recent post later today (about to have to leave for something), but I realized I made the same mistake again due to a failure in multi-tasking:

    I ended up...
  12. Replies
    16
    Views
    16,030

    Thanks to everyone who replied with corrections...

    Thanks to everyone who replied with corrections and further explanation. I really appreciate it.



    Good catch, I *think* I meant to say:

    That is where I was having some trouble understanding...
  13. Replies
    16
    Views
    16,030

    Thanks for the reply CornedBee. So, if I'm...

    Thanks for the reply CornedBee.



    So, if I'm understanding what you're telling me, in the code provided by whiteflags previously:



    void A::foo() { cout << "called A::foo(void)\n"; }...
  14. Replies
    16
    Views
    16,030

    Understood. Sorry, but I'm still getting...

    Understood.




    Sorry, but I'm still getting hung up on the use of the word overload. From what I understood, overloading only applies to functions within the same scope.
  15. Replies
    16
    Views
    16,030

    Overloading, Overriding, and Hiding - help?

    As I'm reading various books and online resources I'm seeing different terms used to describe what I think are the same thing, but I can't quite be sure due to my inexperience.

    Thanks in advance...
  16. Great points, thank you both!

    Great points, thank you both!
  17. Replies
    6
    Views
    1,191

    Edit: I see that MK27 has already responded,...

    Edit:

    I see that MK27 has already responded, so ignore this post. His contains much more relevant information.



    I don't have the answer, and haven't tried learning C programming in ages, but...
  18. Good point. I'll stick with using them unless I...

    Good point. I'll stick with using them unless I find that existing code is already using #pragma once instead of include guards.



    For now I'm going to have to accept this and just go with it,...
  19. After rereading Serapth's pseudocode, I finally...

    After rereading Serapth's pseudocode, I finally understood why this is useful. Then, after reading the sections about virtual functions from these books, the how it works finally made sense:


    ...
  20. Sorry, I just noticed how my reply read. I had...

    Sorry, I just noticed how my reply read. I had originally drafted a reply to laserlight referring to doing that, and wanting to know if either of two other approaches would work, but I scrapped it...
  21. I think I answered my own question. Not only was...

    I think I answered my own question. Not only was broken code provided, but the following section where the syntax for making a class a friend of another class was wrong too:


    friend CCarton;
    ...
  22. Thanks for the reply. Thanks for...

    Thanks for the reply.



    Thanks for confirming that. I'll look to other books for better examples of 'Class Members as Friends'.




    So if I'm understanding you right, the CCarton class...
  23. Class Members as Friends - Beginning Visual C++ 2008

    Hi,

    I was working through all of the example code in chapter 9, Class Inheritance and Virtual Functions, when I came upon the Class Members as Friends portion of the chapter. It looked really...
  24. Thank you both for the links and the information....

    Thank you both for the links and the information. I'll be sure to read through the info and reply back with my results. :)
  25. Having trouble understanding why a pointer to a base class is necessary

    Hi,

    Thanks in advance for reading this.



    Relevant source code files:
Results 1 to 25 of 63
Page 1 of 3 1 2 3