old_contents: ##
  # See the file COPYRIGHT for copyright information.
  #
  # Licensed under the Apache License, Version 2.0 (the "License");
  # you may not use this file except in compliance with the License.
  # You may obtain a copy of the License at
  #
  #     http://www.apache.org/licenses/LICENSE-2.0
  #
  # Unless required by applicable law or agreed to in writing, software
  # distributed under the License is distributed on an "AS IS" BASIS,
  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  # See the License for the specific language governing permissions and
  # limitations under the License.
  ##
  
  """
  Replace mix-in
  """
  
  from typing import Any, TypeVar
  
  from attr import asdict
  
  
  __all__ = ()
  
  
  TAttrsObject = TypeVar("TAttrsObject")
  
  
  
  class ReplaceMixIn():
      """
      Mix-in class with replace method for :mod:`attr` classes.
      """
  
      def replace(self: TAttrsObject, **kwargs: Any) -> TAttrsObject:
          """
          Return a new address with the same values, except those specified by
          keyword arguments.
          """
          newArgs = asdict(self, recurse=False)
          newArgs.update(kwargs)
          return self.__class__(**newArgs)
  
new_contents: ##
  # See the file COPYRIGHT for copyright information.
  #
  # Licensed under the Apache License, Version 2.0 (the "License");
  # you may not use this file except in compliance with the License.
  # You may obtain a copy of the License at
  #
  #     http://www.apache.org/licenses/LICENSE-2.0
  #
  # Unless required by applicable law or agreed to in writing, software
  # distributed under the License is distributed on an "AS IS" BASIS,
  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  # See the License for the specific language governing permissions and
  # limitations under the License.
  ##
  
  """
  Replace mix-in
  """
  
  from typing import Any, TypeVar
  
  from attr import evolve
  
  __all__ = ()
  
  
  TAttrsObject = TypeVar("TAttrsObject")
  
  
  
  class ReplaceMixIn():
      """
      Mix-in class with replace method for :mod:`attr` classes.
      """
  
      def replace(self: TAttrsObject, **kwargs: Any) -> TAttrsObject:
          """
          Return a new address with the same values, except those specified by
          keyword arguments.
          """
          return evolve(self, **kwargs)
  
subject: Use attr.evolve()