Question about: & operator.
#1

Ok, i have a single question if you can answer to me ...
In C++, there is an ampersand ( & ) that change the value of a variable when it returns it.
My question, is .. how can i use that operator :
Just look:
C++
Код:
int return_ovalue ( int& x) { x = x; return x; } // it return the value and also change it... :)
In PAWN: what i've tried:
Код:
stock SetVal(new& x) { x = x ;return x; } / the same thing as in c++
But whenever i compile i get errors..
Reply


Messages In This Thread
Question about: & operator. - by XStormiest - 19.02.2014, 12:37
Re: Question about: & operator. - by Lordzy - 19.02.2014, 12:40
Re: Question about: & operator. - by XStormiest - 19.02.2014, 12:41
Re: Question about: & operator. - by RajatPawar - 19.02.2014, 12:42
Re: Question about: & operator. - by XStormiest - 19.02.2014, 12:48

Forum Jump:


Users browsing this thread: 1 Guest(s)