[thelist] another php question: object reference syntax

Tom Dell'Aringa pixelmech at yahoo.com
Wed Jul 17 16:53:01 CDT 2002


Ok, clear on it and thanks!
--- Michael Kimsal <michael at tapinternet.com> wrote:
> Jonathan_A_McPherson at rl.gov wrote:
> >>Ok, that makes sense. I seem to remember this talk about pointers
> >>when going through a Java class, and you often see those caveats
> in
> >>Java books (at least that I have read.) Coming from
> Java/JavaScript
> >>it seemed odd.
> >>
> >>So - I CAN use dot syntax, but if I make a pointer, I have to use
> ->
> >>correct?
> >
>
> Not in PHP.  PHP requires objects to use the -> no matter what.
>
> Consider that Java compiles and PHP is (generally) interpreted.
> Having
> to determine if a . or -> are appropriate is going to take a bit
> longer.  I think that's why there's a strict separation of thingys
> (. and -> and whatever else).
>
> Consider also that . is used for variable concatenation.  That is
> easier (and probably used more often) than object property/method
> accessing.
>
>
>
>
> Michael Kimsal
> http://www.phpappserver.com
> 734-480-9961
>
>
> --
> For unsubscribe and other options, including
> the Tip Harvester and archive of thelist go to:
> http://lists.evolt.org Workers of the Web, evolt !


=====
var me = tom.pixelmech.webDeveloper();
http://www.pixelmech.com/

__________________________________________________
Do You Yahoo!?
Yahoo! Autos - Get free new car price quotes
http://autos.yahoo.com



More information about the thelist mailing list