• Advertisement

Archived

This topic is now archived and is closed to further replies.

this pointer

This topic is 5466 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am totally confused when to use this->pointer and when to not use it? I have seen some people are using it, and some others aren''t ... also searched for an answer but couldn''t find one... any help would be appreciated... Thanks in advanced.

Share this post


Link to post
Share on other sites
Advertisement
this is useful when dealing with overloaded operators.

Kuphryn

Share this post


Link to post
Share on other sites
The this pointer is used in whatever situation an object need to identify or refer to itself. There are many situations when this is necessary, when overloading operators for instance.

quote:
when to use this->pointer and when to not use it?

Use it when you need to use it.

this->link might be useful.

Regards Mats

Share this post


Link to post
Share on other sites

  • Advertisement