> But this patch simply ignores the 3 passed groups. Shouldn't it push > :common instead? > > my @args = grep { !/:response|:server|:args_how/ } @_; > push @args, ":common" if @_ != @args;
yeah, I thought about that afterward, since :response does include :common. but it wouldn't help on empty args, just on :response - :common isn't any use to the other two skipped tags.
so I'll do something with :common on :response and leave the others.
> > If someone used: > > use Apache::Constants qw(:response); > > your patch won't make the code working, besides suppressing the import > error. >
indeed.
but I already mentioned that there are lots of other cases that would also break, such as using MOVED or SERVER_BUILT. and there's no easy way around it without simply aliasing _every_ constant in mp1 to its mp2 equivalent, forgoing entirely a simple pass of @_ to import().
so, I dunno. keeping the code simple and catching the most common cases, or doing a complete match and polluting the caller's namespace with constants they most likely won't need?
--Geoff