+ 1
What is the use of this-> ?
2 Answers
+ 1
Inside a class method, you must use this->, when there is a name conflict. For example, an argument passed in to the method has the same name as a property you need to access. You can use it everytime, if you wish to, to make it obvious you are accessing a property or method of the instance.
+ 1
Thanks Johnđ