o
    ¹i­  ã                   @   s&   d Z ddlmZ dedefdd„ZdS )zUUtils for interoperability with other libraries.

Just CFFI pointer casting for now.
é    )ÚAnyÚnÚreturnc                 C   s^   t | tƒr| S zddl}W n	 ty   Y nw | ¡ }t | |jƒr)t| d| ¡ƒS td|  ƒ‚)zZCast an address to a Python int

    This could be a Python integer or a CFFI pointer
    r   NÚsize_tzCannot cast %r to int)Ú
isinstanceÚintÚcffiÚImportErrorÚFFIÚCDataÚcastÚ
ValueError)r   r   Úffi© r   úL/var/www/edux/Edux_v2/venv/lib/python3.10/site-packages/zmq/utils/interop.pyÚcast_int_addr   s   
ÿr   N)Ú__doc__Útypingr   r   r   r   r   r   r   Ú<module>   s    