Actually, when you put it like that, it makes sense.. .I hadn't really
thought about it that way.

Mark

On 10/24/07, Sean Corfield <[EMAIL PROTECTED]> wrote:
>
> On 10/23/07, Mark Mandel <[EMAIL PROTECTED]> wrote:
> > I don't know *how* this works, but apparently it does.
>
> Why are you surprised this works? It relies on dynamic binding, just
> as you'd expect surely?
>
> >                 func("dynamic");
>
> This executes the function in the context of the CFC...
>
> > <cffunction name="test" hint="" access="public" returntype="void"
> > output="false">
> >         <cfargument name="test" hint="" type="string" required="Yes">
> >         <cfscript>
> >                 instance.test = arguments.test;
>
> ...so when this executes, it looks up "instance" in the calling
> context which is the enclosing CFC and thus it looks in the CFC's
> "variables" scope.
>
> There's no surprise here.
> --
> Sean A Corfield -- (904) 302-SEAN
> An Architect's View -- http://corfield.org/
>
> "If you're not annoying somebody, you're not really alive."
> -- Margaret Atwood
>
> >
>


-- 
E: [EMAIL PROTECTED]
W: www.compoundtheory.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CFCDev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cfcdev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to