Update parameter add code to correctly handle a non-Module scope

A package can have parameters, but it does not have specparams or
keep the order the parameters are defined. This patch skips these
items if the scope is not a Module.