function parseSubParameters(def, spec, scope) {
    const value = spec[def.name];
    if (def.array) {
      if (!isArray(value)) {
        // signals not allowed!
        error('Expected an array of sub-parameters. Instead: ' + $(value));
      }
      return value.map(v => parseSubParameter(def, v, scope));
    } else {
      return parseSubParameter(def, value, scope);
    }
  }
Parse a parameter that contains one or more sub-parameter objects.