Team Ai
Datasetpublic

codekingpro/portable-devtools

sourceHugging Faceupdated 5mo agoView on Hugging Face
1likes15kdownloads
_fallback.cpython-313.pyc81 linesDownload Raw Back to __pycache__
1�

2u�j�����SSKJr SSKJr SSKJr SSKJr SSK	J3r SSKJ
r
 \
(aSSKJr \\4rSS	jrSS4jrSSjrSSS
jjrSSSjjrSSSjjrSSSjjrSSjrg)�)�annotations)�	b64decode)�	b64encode)�encodebytes)�Error)�
TYPE_CHECKING�)�Bufferc��US:Xdeg)Nr�fallback�)�flagss �XD:\code\apps\devtools\python\user_packages\Python313\site-packages\pybase64/_fallback.py�_get_simd_namers���A�:��:��c��g)Nrr
r
rr�_get_simd_pathrs��rc���[U[5(aURS5$[U[55(aU$[
U5nUR(d&URR<SS3n[U5eUR5$![a Sn[	U5Sef=f![a( SURR<S3n[U5Sef=f)N�asciiz4string argument should contain only ASCII characters�s�': underlying buffer is not C-contiguousz<argument should be a bytes-like object or ASCII string, not )
�6isinstance�str�encode�UnicodeEncodeError�7ValueError�_bytes_types�8memoryview�c_contiguous�	__class__�__name__�BufferError�tobytes�	TypeError)r�msg�mvs   r�9_get_bytesr's����!�S���	,��8�8�G�$�$��!�\�"�"���'�
��]������[�[�)�)�.�A�.�.U�V�C��c�"�"��z�z�|���"�	,�H�C��S�/�t�+�	,���'�
��;�;�/�/�4�!�4�
6�	���n�$�&�'�s�B�AB.�B+�.2C Nc�j�[U5nUb[U5nU(a�[U5S-S:wa
Sn[U5e[XSS9nSn[U5S:�a2SnUSS:XaUS-
nUS	S:XaUS-
nS10[U5S--U-11nU[U5:wa
Sn[U5eU$[XSS9$)a�Decode bytes encoded with the standard Base64 alphabet.12 13Argument ``s`` is a :term:`bytes-like object` or ASCII string to14decode.15 16Optional ``altchars`` must be a :term:`bytes-like object` or ASCII17string of length 2 which specifies the alternative alphabet used instead18of the '+' and '/' characters.19 20If ``validate`` is ``False`` (the default), characters that are neither in21the normal base-64 alphabet nor the alternative alphabet are discarded22prior to the padding check.23If ``validate`` is ``True``, these non-alphabet characters in the input24result in a :exc:`binascii.Error`.25 26The result is returned as a :class:`bytes` object.27 28A :exc:`binascii.Error` is raised if ``s`` is incorrectly padded.29�rzIncorrect paddingF)�validate������=r	������zNon-base64 digit found)r'�len�
BinAsciiError�builtin_decode)r�altcharsr*r%�result�expected_len�paddings       rrr/s���,	�1�
�A����h�'����q�6�A�:��?�%�C���$�$���e�<�����q�6�A�:��G���u��{��1�����u��{��1�����A��!��,�w�6�L��3�v�;�&�*�C���$�$��
��!��6�6rc�(�[[XUS95$)a�Decode bytes encoded with the standard Base64 alphabet.30 31Argument ``s`` is a :term:`bytes-like object` or ASCII string to32decode.33 34Optional ``altchars`` must be a :term:`bytes-like object` or ASCII35string of length 2 which specifies the alternative alphabet used instead36of the '+' and '/' characters.37 38If ``validate`` is ``False`` (the default), characters that are neither in39the normal base-64 alphabet nor the alternative alphabet are discarded40prior to the padding check.41If ``validate`` is ``True``, these non-alphabet characters in the input42result in a :exc:`binascii.Error`.43 44The result is returned as a :class:`bytearray` object.45 46A :exc:`binascii.Error` is raised if ``s`` is incorrectly padded.47)r2r*)�	bytearrayr)rr2r*s   r�b64decode_as_bytearrayr8_s��,�Y�q�h�G�H�Hrc��[U5nUR(d&URR<SS3n[	U5eUb[U5n[
X5$)atEncode bytes using the standard Base64 alphabet.48 49Argument ``s`` is a :term:`bytes-like object` to encode.50 51Optional ``altchars`` must be a byte string of length 2 which specifies52an alternative alphabet for the '+' and '/' characters.  This allows an53application to e.g. generate url or filesystem safe Base64 strings.54 55The result is returned as a :class:`bytes` object.56rr)rrr r!r"r'�builtin_encode)rr2r&r%s    rrrxsW��57�A��B�
�?�?����%�%�*��*�*Q�R���#������h�'���!�&�&rc�6�[X5RS5$)arEncode bytes using the standard Base64 alphabet.58 59Argument ``s`` is a :term:`bytes-like object` to encode.60 61Optional ``altchars`` must be a byte string of length 2 which specifies62an alternative alphabet for the '+' and '/' characters.  This allows an63application to e.g. generate url or filesystem safe Base64 strings.64 65The result is returned as a :class:`str` object.66r)r�decode)rr2s  r�b64encode_as_stringr=�s���Q�!�(�(��1�1rc��[U5nUR(d&URR<SS3n[	U5e[U5$)aEncode bytes into a bytes object with newlines (b'\\n') inserted after67every 76 bytes of output, and ensuring that there is a trailing newline,68as per :rfc:`2045` (MIME).69 70Argument ``s`` is a :term:`bytes-like object` to encode.71 72The result is returned as a :class:`bytes` object.73rr)rrr r!r"�builtin_encodebytes)rr&r%s   rrr�sG��74�A��B�
�?�?����%�%�*��*�*Q�R���#����q�!�!r)r�int�returnr)rAr@)r�str | BufferrAzbytes | bytearray)NF)rrBr2�str | Buffer | Noner*�boolrA�bytes)rrBr2rCr*rDrAr7)N)rr75r2rCrArE)rr76r2rCrAr)rr77rArE)�78__future__r�base64rr1rr:rr?�binasciirr0�typingr�_typingr79rEr7rrrr'r8r=r
rr�<module>rKs���"�.�.�5�+� ����y�!���80
�'�0MR�-7��-7�2�-7�EI�-7�81�-7�bMR�I��I�2�I�EI�I��I�2'�(2�
"r
codekingpro/portable-devtools · Team Ai