Bug on serialization when passing a List to a generic class