Sunday, November 23, 2008

Stupid Type Erasure

I want to create a freaking generic array, dang it!

public T[] makeArray(int size)
{
return new T[size]; // compiler error. why? because Java sucks
}