generics - reducing warnings