|
Posted by Steve on 09/24/07 21:35
"Michael Fesser" <netizen@gmx.de> wrote in message
news:60agf3dds15g16okej94srele60sifocfu@4ax.com...
> .oO(Steve)
>
>>"gosha bine" <stereofrog@gmail.com> wrote in message
>>news:46f823bf$0$31121$6e1ede2f@read.cnntp.org...
>>>
>>> Please read the chapter called "references are not pointers" in the
>>> manual.
>>
>>'chapter' ? oh, you mean the quoted text of a usenet post? may i ask, who
>>is
>>jani?
>
> From the manual (not the UCNs):
>
> | They are not like C pointers; instead, they are symbol table aliases.
> | Note that in PHP, variable name and variable content are different, so
> | the same content can have different names.
yes, however very nearly all semantics at this point.
>>gosha, you'd be wise at this point to draw the distinctions yourself (if
>>not
>>capable, use a supported reference [no pun]). but, since references
>>provide
>>identical behaviors to pointers
>
> They don't. A pointer contains an address in memory, which could be a
> variable or the entry point of a function. You can even point to a
> pointer to a pointer - a thing that _cannot_ be done with references,
> because a reference is just an alias name for something.
and THIS would be the distinction.
>>the only difference that i see is the
>>literal words themselves (one, 'pointer', the other, 'reference')...and
>>perhaps some symantics somewhere.
>
> Even in C/C++ pointers and references are two different concepts.
>
>>as it is, REFERENCES like POINTERS speak to POINTING TO AN ADDRESS or a
>>COPY
>>OF A VALUE AT AN ADDRESS...which is EXACTLY WHAT A POINTER IS/DOES.
>
> Correct, but that's not what a reference does.
you take all the fun out of this micha! i wanted gosha to say all of that. i
thought his quoted support was lack luster (i guess what i found on the net
was not the same as what he was refering to). ;^)
Navigation:
[Reply to this message]
|