XP is just a number | |
PerlMonks |
Re: Procedural and object oriented interface in Perl/XSby dave_the_m (Monsignor) |
on Oct 23, 2014 at 12:23 UTC ( [id://1104764]=note: print w/replies, xml ) | Need Help?? |
Perl doesn't make any distinction between a function call and a method call (except that which function to call is resolved at run-time). $x->foo($y,$z) just calls foo($x,$y,$z),and Class->foo($y,$z) just calls foo('Class',$y,$z).
So if you want your function (be it perl or XS code) to tell the difference, you need to make the function be called in a slightly different way to make a distinction Dave.
In Section
Seekers of Perl Wisdom
|
|