Improved named arguments

Note that this optimization is only needed when using named parameters. When not using named parameters, the generated arguments are already "optimized".