# New Ticket Created by Patrick R. Michaud # Please include the string: [perl #48631] # in the subject line of all future correspondence about this issue. # <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=48631 >
This ticket is asking for some convenient mechanism to have a :method be automatically entered as a sub in the namespace. This used to be the situation prior to the pdd15oo merge, and I've come across some instances in perl6 and PGE where this is really needed. We can either provide a flag to :method that means "also add the method to the namespace", or we could let :method automatically be placed in the namespace unless another flag (e.g., :anon) is present. For now, PGE is working around the problem by generating both a method and a sub: ## method redispatches to sub 'foo' in the same namespace .sub 'foo' :method .param pmc options :slurpy :named $P0 = get_global 'foo' .return $P0(self, options :flat :named) .end .sub 'foo' .param pmc invocant .param pmc options :slurpy :named # ... do foo processing here ... .end Thanks, Pm