Sort of a nitpick, but... Any reason to capture the results of `TrimFunc` into `uints`? Perhaps just returning the result of `TrimFunc` would suffice.