dynamic_cast

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • puzzlecracker

    dynamic_cast

    Is it possible for a dynamic_cast to return a non-null pointer even
    though source pointer and target pointer don't belong to class
    hierarchy?
  • Victor Bazarov

    #2
    Re: dynamic_cast

    puzzlecracker wrote:
    Is it possible for a dynamic_cast to return a non-null pointer even
    though source pointer and target pointer don't belong to class
    hierarchy?
    Please post code. Could it be that you're passing a non-class pointer
    to the cast, like a void*?

    V
    --
    Please remove capital 'A's when replying by e-mail
    I do not respond to top-posted replies, please don't ask

    Comment

    Working...