>> What's the difference between pointers and references?  Where can I read
>> about that difference?
> 
> The key difference in my mind is this: Perl references are defined in
> terms of perl datatypes. C pointers are defined (more or less) in
> terms of memory locations.
> 
> If you think about Perl references in terms of *what they do* and not
> *how they work*, it becomes much clearer. There is nothing you can do
> to a perl reference to get its "memory address", so that doesn't fit
> within the conceptual framework of Perl references. Perl references
> are simply scalar values which provide an indirect form of access to
> other perl objects (including scalars, hashes, OO types...). You can
> create a reference from a named or anonymous variable, and you can
> dereference that reference to get the original object. You can think
> of them as labels or tags or handles; all of these ideas fit the
> paradigm created by the interface of the reference.


This is exactly what I needed, thanks Philip!

- Bryan



--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to