Thread: Virtual Table

  1. #16
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    It can get very complex with multiple, virtual and non-virtual inheritance.
    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

  2. #17
    Registered User
    Join Date
    Jun 2008
    Posts
    13
    Wow !!
    appologies for not able to monitor this forum for quite for some time, didn't ever expected we would be having discussions on this too.
    However i see questions about the origin of this question as well, Quite strange ....do we have to really waste our time for that?

    expecting people to be generous enough to share if they know something, guess thats why such forums are made.

    anyway i was asked this question when some of our freinds were discussing some concepts of c++ involving virtual functions.

    Anyway if any one has some clear picture about the question then is invited to share it.
    and please if you have some junk to flood here in this space then probably some crap chat machine can quench your thirst for that.

    Its no intelligent to ask a question over the asked question.
    Hope all of you have worked with virtual functions and virtual classes and was genuin replies from your end.

    Its would have been so great of all of you if you could have atleast given the answer considering the way you use it so we could have had knowledge of different kind of implementations we were talking about all the while.

    any ways hope have no offended you and if at all i have then possibly you sould be thinking a bit before answering to this.

  3. #18
    Technical Lead QuantumPete's Avatar
    Join Date
    Aug 2007
    Location
    London, UK
    Posts
    894
    Quote Originally Posted by C-RaT View Post
    if you have some junk to flood here in this space then probably some crap chat machine can quench your thirst for that.
    ...
    Its no intelligent to ask a question over the asked question.
    ...
    you sould be thinking a bit before answering to this.
    You're not exactly making friends with those kind of comments. We'll always be happy to help and answer your question (which I believe we did), but we won't do someone's homework for them and, unfortunately, that's what your question sounded like.

    QuantumPete
    "No-one else has reported this problem, you're either crazy or a liar" - Dogbert Technical Support
    "Have you tried turning it off and on again?" - The IT Crowd

  4. #19
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    Not to mention that it's been answered:
    In any existing known compiler there is ONE vtable.

    Quote Originally Posted by Cornedbee
    Anyway, there's no compiler that creates more than one vtable for any given class.

    An entirely different question is how many vptrs F will contain.
    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  5. #20
    Algorithm Dissector iMalc's Avatar
    Join Date
    Dec 2005
    Location
    New Zealand
    Posts
    6,318
    Quote Originally Posted by C-RaT View Post
    Its no intelligent to ask a question over the asked question.
    Pure insolence. It's amazing how many general forum ettiquite guidelines you've broken in just a single post.

    If you had asked what is the diameter of a ball, then you're suggesting that people should not ask whether it is a golf-ball, tennis-ball, or basket-ball etc. Fine then, the answer is 42!
    My homepage
    Advice: Take only as directed - If symptoms persist, please see your debugger

    Linus Torvalds: "But it clearly is the only right way. The fact that everybody else does it some other way only means that they are wrong"

  6. #21
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Quote Originally Posted by C-RaT View Post
    ....do we have to really waste our time for that?

    expecting people to be generous enough to share if they know something, guess thats why such forums are made.

    ...

    Anyway if any one has some clear picture about the question then is invited to share it.
    and please if you have some junk to flood here in this space then probably some crap chat machine can quench your thirst for that.

    Its no intelligent to ask a question over the asked question.
    Hope all of you have worked with virtual functions and virtual classes and was genuin replies from your end.

    Its would have been so great of all of you if you could have atleast given the answer considering the way you use it so we could have had knowledge of different kind of implementations we were talking about all the while.
    Those are quite rude comments.
    Actually, I want to say it's you who asked a crap question. It's only fair.

    any ways hope have no offended you and if at all i have then possibly you sould be thinking a bit before answering to this.
    Laughable!
    You come here, insult everyone and hope they will be nice to you?
    And I will add something else: since this forum is about portability and standard compliance, answering your question is not done easily or SHOULD not be done by us, because it's IMPLEMENTATION DEPENDANT. Meaning every compiler does it differently, so you should NOT rely on it.
    Now go away. Shoo.
    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. #22
    Banned master5001's Avatar
    Join Date
    Aug 2001
    Location
    Visalia, CA, USA
    Posts
    3,685
    I wish I were the type of person who can just drop into a forum in a foreign tongue, then crudely construct a question that is has no simple answer, then scoff at those who attempted to answer the question all while pointing out the complexity of a real answer. Kudos to you, C-RaT, you have made my day by giving me a smile. As long as you exist, I know I am not the biggest jerk in the world.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 48
    Last Post: 09-26-2008, 03:45 AM
  2. Pure Virtual Function - Virtual Method Table
    By u_peerless in forum C++ Programming
    Replies: 8
    Last Post: 06-07-2008, 01:19 AM
  3. Writing array, to file
    By zootreeves in forum C Programming
    Replies: 9
    Last Post: 09-08-2007, 05:06 PM
  4. C++ XML Class
    By edwardtisdale in forum C++ Programming
    Replies: 0
    Last Post: 12-10-2001, 11:14 PM
  5. Exporting Object Hierarchies from a DLL
    By andy668 in forum C++ Programming
    Replies: 0
    Last Post: 10-20-2001, 01:26 PM