Merge arguments and local scope

@bennadel Lucee comes with a setting to merge the form and url scope, if enabled one is just an alias to the other, as you suggested also for this case. problem with that solution is backward compatibility, the situation that someone has the same key in local and arguments scope with different values would no longer work. if merged we would let the local scope point to the arguments scope.

@Leftbower Lucee 6 is released

@AdamCameron if it would be clear i would never started that thread ;-). ATM i see no valid solution for this, this is actually something bugging me for a long time. Having a setting in the Admin, that is off by default is not worth the effort in my opinion, because most people will never enable it.
I’m aware that the implementation in Lucee and ACF differs, in Lucee this scopes are completely separated and in ACF the arguments scope is inside the local scope with special behaviour.
The following code shows the only 2 cases that differs from ACF to Lucee because of this TryCF.com

We will for sure not change that behaviour in Lucee to be ACF compatible, because nobody ever did complain about this difference so far, the only complain we got about the local scope in the past, was that Lucee (or better Railo back then), did allow to set "var " not only at the top of the function, but later ACF did change that behaviour, so today that works the same way as in Lucee.

The reason for a possible change is simply performance, if you address an argument in the scope without defining the scope, it always checks first the local scope before the arguments scope and because in a regular application this happens a lot, it is worth thinking about improving this behaviour. the whole function handling is under consideration.

For example one idea is that Lucee detects if the arguments scope get overwritten in a function and then handles it differently, because this is a rare occasion it is worth to handle a “readonly” arguments scope in a different way. Also a function is called more than once normally, so some initial overhead makes sense.