U
    Dvfò  ã                   @   s   d Z dd„ Zdd„ ZdS )z2Private utility methods used by the subset modulesc                     s   ‡ fdd„}|S )zOReturns a decorator function that adds a new method to one or
    more classes.c                    sf   g }ˆ D ]X}||krq|  |¡ |jdks2tdƒ‚t|| jƒrRtd|j| jf ƒ‚t|| j| ƒ qd S )NZDefaultTablezOops, table class not found.z!Oops, class '%s' has method '%s'.)ÚappendÚ__name__ÚAssertionErrorÚhasattrÚsetattr)ÚmethodÚdoneZclazz©Úclazzes© ú9/tmp/pip-unpacked-wheel-qlge9rch/fontTools/subset/util.pyÚwrapper   s    
 ÿþz_add_method.<locals>.wrapperr
   )r	   r   r
   r   r   Ú_add_method   s    r   c                 C   s   t t| ƒƒS )N)ÚsortedÚset)Úlr
   r
   r   Ú
_uniq_sort   s    r   N)Ú__doc__r   r   r
   r
   r
   r   Ú<module>   s   