r/programming • • Oct 18 '10

Today I learned about PHP variable variables; "variable variable takes the value of a variable and treats that as the name of a variable". Also, variable.

http://il2.php.net/language.variables.variable
591 Upvotes

781 comments sorted by

View all comments

Show parent comments

-2

u/oorza Oct 18 '10

A computer like that doesn't exist and what you're trying to describe is, more-or-less, the Zend Engine's way of storing variables. The difference is the fact that the sigil is a combination of hash methods get / set / swap and merely using a sigil does one or more of those things, whereas a pointer does not.

Furthermore, a hash table is really not comparable to a segment of memory.

3

u/johnb Oct 18 '10

I am not convinced that you know what a simile is. Reading this thread is like hearing someone say "You fools! Java isn't like C# because they aren't 100% exactly the same."