code: private static void paramNamesOf(Node node, ImmutableList.Builder<Node> names) {
      switch (node.getToken()) {
        case NAME:
          names.add(node);
          break;
  
        case REST:
        case DEFAULT_VALUE:
          paramNamesOf(node.getFirstChild(), names);
          break;
  
        case PARAM_LIST:
        case ARRAY_PATTERN:
          for (Node child = node.getFirstChild(); child != null; child = child.getNext()) {
            paramNamesOf(child, names);
          }
          break;
  
        case OBJECT_PATTERN:
          for (Node child = node.getFirstChild(); child != null; child = child.getNext()) {
            checkArgument(child.isStringKey() || child.isComputedProp(), child);
            paramNamesOf(child.getLastChild(), names);
          }
          break;
  
        default:
          checkArgument(false, node);
          break;
      }
    }
docs: Recursively collects the NAME parameter nodes of a FUNCTION.
  
  <p>This lookup abstracts over the other legal node types in a PARAM_LIST. It includes only
  those nodes that declare bindings within the function body.