
This makes goog.dom.findNodes_ more efficient for all cases I tried. Some benchmarks with a similar construct can be found here: http://jsperf.com/iterate-children and here: http://jsperf.com/nextsibling-vs-childnodes, where it shows to be faster in firefox, chrome, IE and safari. I also tried an implementation using this for getting elements with class 'ci' or 'ch' in resourcepicker.js in calendar, and there too the proposed new implementation was faster.

R=pallosp
DELTA=3  (2 added, 0 deleted, 1 changed)


Revision created by MOE tool push_codebase.
MOE_MIGRATION=2489


yamadatomonori/closure-library,yamadatomonori/closure-library,yamadatomonori/closure-library