Comment 25 for bug 1655158

Revision history for this message
Mike Rylander (mrylander) wrote :

Thanks, Blake. I think the loop is an order of magnitude more readable maintainable, and definitely the right choice a the implementation level. We're talking about a loop of, at most, three executions of six lines of code, most of which are setting and concatenating variables. Perl would be doing that anyway internally in the implicit loop generated by them map, so we're not saving anything there, really, and since you're only executing a single regex in the loop version, instead of up to 3 in the nested ternary, I suspect we end up saving cycles.