U Ø üe­ã@s,ddlZddlZdd„Zdd„Zdd„ZdS)éNcCsTt|tƒrt d|¡Sz$| d¡}t d|¡}| d¡}Wntk rNYnX|S)NZNFDúutf-8)Ú isinstanceÚstrÚ unicodedataÚ normalizeÚdecodeÚencodeÚ UnicodeError)Úpath©r úF/opt/hc_python/lib/python3.8/site-packages/setuptools/unicode_utils.pyÚ decomposes    r c CsZt|tƒr|St ¡pd}|df}|D].}z| |¡WStk rRYq&Yq&Xq&dS)zY Ensure that the given path is decoded, NONE when no expected encoding works rN)rrÚsysÚgetfilesystemencodingrÚUnicodeDecodeError)r Zfs_encÚ candidatesÚencr r r Úfilesys_decodes  rcCs(z | |¡WStk r"YdSXdS)z/turn unicode encoding into a functional routineN)rÚUnicodeEncodeError)Ústringrr r r Ú try_encode%s r)rrr rrr r r r Ús