code: function (attrs/*, ...*/) {
      if (HTML.isArray(attrs)) {
        var argsCopy = SLICE.call(arguments);
        var result = attrs;
        for (var i = 0; i < attrs.length; i++) {
          var oldItem = attrs[i];
          argsCopy[0] = oldItem;
          var newItem = this.visitAttributes.apply(this, argsCopy);
          if (newItem !== oldItem) {
            // copy on write
            if (result === attrs)
              result = attrs.slice();
            result[i] = newItem;
          }
        }
        return result;
      }
  
      if (attrs && HTML.isConstructedObject(attrs)) {
        throw new Error("The basic HTML.TransformingVisitor does not support " +
                        "foreign objects in attributes.  Define a custom " +
                        "visitAttributes for this case.");
      }
  
      var oldAttrs = attrs;
      var newAttrs = oldAttrs;
      if (oldAttrs) {
        var attrArgs = [null, null];
        attrArgs.push.apply(attrArgs, arguments);
        for (var k in oldAttrs) {
          var oldValue = oldAttrs[k];
          attrArgs[0] = k;
          attrArgs[1] = oldValue;
          var newValue = this.visitAttribute.apply(this, attrArgs);
          if (newValue !== oldValue) {
            // copy on write
            if (newAttrs === oldAttrs)
              newAttrs = _assign({}, oldAttrs);
            newAttrs[k] = newValue;
          }
        }
      }
  
      return newAttrs;
    }
docs: Transform the `.attrs` property of a tag, which may be a dictionary, an array, or in some uses, a foreign object (such as a template tag).