Infer dependencies from function arguments