Refine function signature parsing