403Webshell
Server IP : 217.160.0.135  /  Your IP : 216.73.217.85
Web Server : Apache
System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64
User : sws1074145052 ( 1074145052)
PHP Version : 8.3.32
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/pythran/optimizations/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/pythran/optimizations/__pycache__/square.cpython-311.pyc
�

cR�a���j�dZddlmZddlmZmZddlmZddlm	Z	ddl
ZddlZGd�de��Z
dS)	z) Replaces **2 by a call to numpy.square. �)�Transformation)�
ASTMatcher�AST_any)�mangle)�isnumNc
��eZdZdZeje��ej��ejdd����Z	ej
ejeje
d��ej��dd��dej����e��ejdd��gg��Zd�Zd�Zd�Zd	�Zd
�Zd�ZdS)�Squarea�
    Replaces **2 by a call to numpy.square.

    >>> import gast as ast
    >>> from pythran import passmanager, backend
    >>> node = ast.parse('a**2')
    >>> pm = passmanager.PassManager("test")
    >>> _, node = pm.apply(Square, node)
    >>> print(pm.dump(backend.Python, node))
    import numpy as __pythran_import_numpy
    __pythran_import_numpy.square(a)
    >>> node = ast.parse('__pythran_import_numpy.power(a,2)')
    >>> pm = passmanager.PassManager("test")
    >>> _, node = pm.apply(Square, node)
    >>> print(pm.dump(backend.Python, node))
    import numpy as __pythran_import_numpy
    __pythran_import_numpy.square(a)
    �N�numpy�powerc�.�tj|��dS)N)r�__init__)�selfs �>/usr/lib/python3/dist-packages/pythran/optimizations/square.pyrzSquare.__init__)s�����%�%�%�%�%�c��dx|_|_tjt	d��tj��dd��}tjtj|dtj����|gg��S)NTr�square)�update�need_import�ast�Namer�Load�Call�	Attribute)r�value�module_names   r�replacezSquare.replace,sc��)-�-���d�&��h�v�g�����
�
�D�$�G�G���x��
�k�8�S�X�Z�Z�H�H����%�%�	%rc���d|_|�|��|jrTtjdt	d�����}tj|g���}|j�d|��|S)NFr)�name�asname)�namesr)r�
generic_visitr�aliasr�Import�body�insert)r�node�import_alias�importIts    r�visit_ModulezSquare.visit_Module2st�� ������4� � � ���	*��9�'�&��/�/�J�J�J�L��z���7�7�7�H��I���Q��)�)�)��rc�$�|dkrtjdd��S|dkr|S|�|��}|�||dz	��}|dzr9tj|tj��t
j|����S|S)Nr�)r�Constantr�
expand_pow�BinOp�Mult�copy�deepcopy)rr'�n�node_square�node_pows     rr.zSquare.expand_pow;s�����6�6��<��4�(�(�(�
�!�V�V��K��,�,�t�,�,�K����{�A��F�;�;�H��1�u�
 ��y��3�8�:�:�t�}�T�7J�7J�K�K�K��rc��|�|��ttj���|��r|�|j��St|jtj
��rVt|j��rB|jj
}t|��|kr!|dkr|�|j|��S|S|S�Nr)r"rr	�POW_PATTERN�searchr�left�
isinstance�opr�Powr�rightr�intr.)rr'r3s   r�visit_BinOpzSquare.visit_BinOpHs������4� � � ��f�(�)�)�0�0��6�6�		��<�<��	�*�*�*�
�����
)�
)�	�e�D�J�.?�.?�	��
� �A��1�v�v��{�{�q�1�u�u����t�y�!�4�4�4����Krc���|�|��ttj���|��r |�|jd��S|Sr7)r"rr	�
POWER_PATTERNr9r�args)rr's  r�
visit_CallzSquare.visit_CallUsT�����4� � � ��f�*�+�+�2�2�4�8�8�	��<�<��	�!��-�-�-��Kr)�__name__�
__module__�__qualname__�__doc__rr/rr=r-r8rrrrrrBrrr*r.r@rD�rrr	r	s"��������&�#�)�G�G�I�I�w�s�w�y�y�,�#�,�q�$�2G�2G�H�H�K��C�H���
�h�c�h�v�v�g������
�
�D�$�G�G���c�h�j�j�	"�	"�
����L�C�L��D�)�)�*�
���M�&�&�&�%�%�%���� � � ��������rr	)rH�pythran.passmanagerr�pythran.analyses.ast_matcherrr�pythran.conversionr�
pythran.utilsr�gastrr1r	rIrr�<module>rOs���/�/�.�.�.�.�.�.�<�<�<�<�<�<�<�<�%�%�%�%�%�%���������������N�N�N�N�N�^�N�N�N�N�Nr

Youez - 2016 - github.com/yon3zu
LinuXploit