U
    nËj3  ã                   @   s   G d d„ dƒZ dS )c                   @   sL   e Zd ZdZeddœdd„Zedœdd„Zedœd	d
„Ze	e
dœdd„ZdS )ÚDocat  Define the documentation of a type annotation using `Annotated`, to be
        used in class attributes, function and method parameters, return values,
        and variables.

    The value should be a positional-only string literal to allow static tools
    like editors and documentation generators to use it.

    This complements docstrings.

    The string value passed is available in the attribute `documentation`.

    Example:

    ```Python
    from typing import Annotated
    from annotated_doc import Doc

    def hi(name: Annotated[str, Doc("Who to say hi to")]) -> None:
        print(f"Hi, {name}!")
    ```
    N)ÚdocumentationÚreturnc                C   s
   || _ d S ©N©r   )Úselfr   © r   ú6/tmp/pip-unpacked-wheel-hy0lgshf/annotated_doc/main.pyÚ__init__   s    zDoc.__init__)r   c                 C   s   d| j ›d�S )NzDoc(ú)r   ©r   r   r   r   Ú__repr__   s    zDoc.__repr__c                 C   s
   t | jƒS r   )Úhashr   r   r   r   r   Ú__hash__   s    zDoc.__hash__)Úotherr   c                 C   s   t |tƒstS | j|jkS r   )Ú
isinstancer   ÚNotImplementedr   )r   r   r   r   r   Ú__eq__!   s    
z
Doc.__eq__)Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ústrr	   r   Úintr   ÚobjectÚboolr   r   r   r   r   r      s
   r   N)r   r   r   r   r   Ú<module>   ó    