reduce unnecessary type allocations