More precise slicing for functions