
    BVh                     |    d Z ddlmZmZ ddlZddlmZmZ ddl	m
Z
  ed      Zdedee   f   d	edee   f   fd
Zy)z9TFDecorator-aware replacements for the contextlib module.    )CallableIteratorN)ContextManagerTypeVar)tf_decorator_Ttarget.returnc                 Z    t        j                  |       }t        j                  | |d      S )a  A tf_decorator-aware wrapper for `contextlib.contextmanager`.

  Usage is identical to `contextlib.contextmanager`.

  Args:
    target: A callable to be wrapped in a contextmanager.
  Returns:
    A callable that can be used inside of a `with` statement.
  contextmanager)_contextlibr   r   make_decorator)r	   context_managers     T/home/dcms/DCMS/lib/python3.12/site-packages/tensorflow/python/util/tf_contextlib.pyr   r      s*      ..v6/		$	$V_>N	OO    )__doc__collections.abcr   r   
contextlibr   typingr   r   tensorflow.python.utilr   r   r    r   r   <module>r      sU    @ .   * /T]PS(2,&'Pc>"%%&Pr   