code: private void handleCandidateProvideDefinition(NodeTraversal t, Node n, Node parent) {
      if (t.inGlobalHoistScope()) {
        String name = null;
        if (n.isName() && NodeUtil.isNameDeclaration(parent)) {
          name = n.getString();
        } else if (n.isAssign() && parent.isExprResult()) {
          name = n.getFirstChild().getQualifiedName();
        }
  
        if (name != null) {
          if (parent.getBooleanProp(Node.IS_NAMESPACE)) {
            // TODO(b/128361464): stop including goog.module exports in this case.
            processProvideFromPreviousPass(t, name, parent);
          } else {
            ProvidedName pn = providedNames.get(name);
            if (pn != null) {
              pn.addDefinition(parent, t.getModule());
            }
          }
        }
      }
    }
docs: Handles a candidate definition for a goog.provided name.