code: public void putAll(Map<? extends K, ? extends V> m) {
          if (m instanceof EnumMap) {
              EnumMap<?, ?> em = (EnumMap<?, ?>)m;
              if (em.keyType != keyType) {
                  if (em.isEmpty())
                      return;
                  throw new ClassCastException(em.keyType + " != " + keyType);
              }
  
              for (int i = 0; i < keyUniverse.length; i++) {
                  Object emValue = em.vals[i];
                  if (emValue != null) {
                      if (vals[i] == null)
                          size++;
                      vals[i] = emValue;
                  }
              }
          } else {
              super.putAll(m);
          }
      }
docs: Copies all of the mappings from the specified map to this map.
  These mappings will replace any mappings that this map had for
  any of the keys currently in the specified map.
  
  @param m the mappings to be stored in this map
  @throws NullPointerException the specified map is null, or if
  one or more keys in the specified map are null