That's actually a new featured of Java 7 (type inferencing for generic object creation). See: Type Inference for Generic Instance Creation

The problem is actually here:


items = (T[]) new...