On Thu, Oct 2, 2008 at 1:17 AM, Jos Timanta Tarigan
<[EMAIL PROTECTED]> wrote:
> Hi,
>
> I'm having a class with lots of variables, and each one has a set get
> method.
> Its actually not very important but I hate having too much names in a class.
>
> For example i have a method that require a parameter var1, and the name var1
> already used by the global variable. In java we can access both by using
> this.var1 for global variable and var1 for local variable.
>
> Is it possible to do the same in C++? How can I do it?
>
> Thanks in advance
>
> Regards
>
> Jos Timanta Tarigan
>
Hi

This should be possible by using the scope resolution (::) operator to
access the global variable.

Thanks!! and have a nice day!!
Jaspreet

Reply via email to