U
    wh                     @   sD   d dl mZ d dlZG dd dZeejjejjf dddZdS )    )UnionNc                   @   s@   e Zd Zejjeejjejjf dddZ	dd Z
dd ZdS )	_InsertPoint)insert_point_graphinsert_pointc                 C   s   || _ || _d | _d S N)r   gguard)selfr   r    r
   E/var/www/html/venv/lib/python3.8/site-packages/torch/jit/_ir_utils.py__init__   s    z_InsertPoint.__init__c                 C   s   | j  | _| j | j d S r   )r   ZinsertPointprev_insert_pointsetInsertPointr   )r	   r
   r
   r   	__enter__   s    z_InsertPoint.__enter__c                 G   s   | j | j d S r   )r   r   r   )r	   argsr
   r
   r   __exit__   s    z_InsertPoint.__exit__N)__name__
__module____qualname__torch_CZGraphr   NodeBlockr   r   r   r
   r
   r
   r   r      s
   	r   )r   c                 C   s
   t | |S r   )r   )r	   r   r
   r
   r   insert_point_guard   s    r   )typingr   r   r   r   r   r   r   r
   r
   r
   r   <module>   s   