develooper Front page | perl.perl5.porters | Postings from August 2001

RE: marking can() coderef as a method

Thread Previous | Thread Next
From:
Geoffrey Young
Date:
August 24, 2001 05:42
Subject:
RE: marking can() coderef as a method
Message ID:
A14A9ADE3BEAD311AF95009027B6FBE0011E2138@corpex.laserlink.net


> -----Original Message-----
> From: Michael G Schwern [mailto:schwern@pobox.com]
> Sent: Friday, August 24, 2001 8:19 AM
> To: Geoffrey Young
> Cc: 'perl5-porters@perl.org'
> Subject: Re: marking can() coderef as a method
> 
> 
> On Fri, Aug 24, 2001 at 08:08:10AM -0400, Geoffrey Young wrote:
> >   cv = sv_2cv(sv, &stash, &gv, FALSE);
> >   if (cv && (CvFLAGS(cv) & CVf_METHOD)) {
> 
> Seeing as how the CVf_METHOD flag only gets set if the 'method'
> attribute is used

ah, I was wondering about the origin of that.  

> it would be a lot easier to just use the attributes
> module than XS code.

well, the effect I wanted requires XS, since XS will be calling the coderef
- it was attaching CVf_METHOD to the reference that was causing me grief.

turns out attributes were exactly what I was after.  problem solved - thanks

--Geoff

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About