Changed parameter info array element name from pos to position for readability
Enhanced logic to build previous_params pattern

When a position is specified for parameter and is higher than 0, build one pattern to match a set number of previous parameters. When position is not set, accept anything before target parameter.

This new logic is also easier to read than previous binary if operator.