Details
-
Sub-task
-
Status: Closed
-
Major
-
Resolution: Won't Fix
-
None
-
None
-
None
Description
Wherever we use the enhanced for construction:
for ( FormalParameter : Expression ) Statement
where the Expression evaluates to an array or collection type that supports random access, we can avoid creating iterator objects, unless we are also using the iterator to remove items while iterating by using the basic for statement instead:
for ( ForInit ; Expression ; ForUpdate ) Statement
Attachments
Issue Links
- relates to
-
HBASE-12096 In ZKSplitLog Coordination and AggregateImplementation replace enhaced for statements with basic for statement to avoid unnecessary object allocation
- Closed