[wp-hackers] Micro optimization - is_a() vs instanceof
dyordan1 at ramapo.edu
Fri Jan 4 19:17:10 UTC 2013
Well that's a whole different story. I expected a lot more than 57 matches. We should really get this thing done then. As Otto said, fix-it-if-you-spot-it seems like a good approach but didn't Jeff Morris already do the whole thing? Seems reasonable to just get a patch and get it over with if that's fine with the big guys.
On Fri, 4 Jan 2013, at 1:33 PM, Jeff Morris wrote:
> On 04/01/2013 17:32, Otto wrote:
>> The difference is probably negliable, but it adds up over time. It
>> would make sense to switch to instanceof anywhere that it is possible
>> to do so, however I don't think it is a pressing concern. One of those
>> fix-it-if-you-spot-it things.
> IDE search on WP 3.5, "is_a(":
> /wp-includes/ : 53 matches
> /wp-admin/includes/ : 4 matches
> About an hour's work to refactor, and that's being meticulous.
> For bbpress 2.2.3 I also got:
> /wp-content/plugins/bbpress/includes/ : 7 matches
> A dime to a dollar says they'll fix it before WP core does.
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
More information about the wp-hackers