fix these type constraints (rafl)