On Tuesday, September 30, 2003, at 05:03 PM, [EMAIL PROTECTED] wrote:

Any diff between MYPKG::hello(); and MYPKG->hello(); ?

Yes. MYPKG::hello() is a standard subroutine call, targeting a definition for hello() found in MYPKG. You should rarely need this form as you would usually import need subroutines in the use statement, assuming the traditional package/module relationship.


MYPKG->hello() is an object oriented method call to class method hello() of the MYPGK class. This is how you use object oriented modules, typically to reach their constructors. Don't use this unless you know hello() is a class method though, as the class name will be the first argument. This call is slower, due to inheritance issues.

Hope that helps.

James


-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to