o
    —ôj5  ã                   @  s8   d Z ddlmZ ddlmZ 	 dgZ
G dd„ deƒZdS )	a?  
You cannot subclass bool, and this is necessary for round-tripping anchored
bool values (and also if you want to preserve the original way of writing)

bool.__bases__ is type 'int', so that is what is used as the basis for ScalarBoolean as well.

You can use these in an if statement, but not when testing equivalence
é    )Úannotations)ÚAnchorF)ÚTextÚAnyÚDictÚListÚScalarBooleanc                   @  s<   e Zd Zddd„Zeddd	„ƒZdddd„Zdddd„ZdS )r   Úclsr   ÚargsÚkwÚreturnc                 O  s>   |  dd ¡}tj| g|¢R i |¤Ž}|d ur|j|dd� |S )NÚanchorT)Úalways_dump)ÚpopÚintÚ__new__Úyaml_set_anchor)r	   r
   r   r   Úb© r   úi/var/www/html/academy/tools/voices/clone/cosy-venv/lib/python3.10/site-packages/ruamel/yaml/scalarbool.pyr      s
   zScalarBoolean.__new__c                 C  s(   t | tjƒst| tjtƒ ƒ t| tjƒS ©N)Úhasattrr   ÚattribÚsetattrÚgetattr)Úselfr   r   r   r      s   zScalarBoolean.anchorFÚanyÚboolc                 C  s&   t | tjƒsd S |s| jjr| jS d S r   )r   r   r   r   r   )r   r   r   r   r   Úyaml_anchor"   s
   zScalarBoolean.yaml_anchorÚvaluer   ÚNonec                 C  s   || j _|| j _d S r   )r   r   r   )r   r   r   r   r   r   r   )   s   zScalarBoolean.yaml_set_anchorN)r	   r   r
   r   r   r   r   r   )r   r   )F)r   r   r   r   )r   r   r   r   r   r    )Ú__name__Ú
__module__Ú__qualname__r   Úpropertyr   r   r   r   r   r   r   r      s    
N)Ú__doc__Ú
__future__r   Úruamel.yaml.anchorr   Útypingr   r   r   r   Ú__all__r   r   r   r   r   r   Ú<module>   s    	