
    E#i1                        S SK r S SKJrJr  Sr\ R
                  " \S9r\ R                  " S 5      r\ R                  " S5      r	S\
S\
4S jrS	\
S\\
\
4   4S
 jrS	\
S\\
\
4   4S jrS	\
S\
S\\ R                  \ R                  4   4S jrS	\
S\
S\\ R                  \ R                  4   4S jrS\
S\\ R                  /\ R                  4   4S jrg)    N)CallableTuplei  )prec
   xreturnc                 .    U S-  S:X  a  U $ U S-   U S-  -
  $ )N    r    )r   s    m/home/james-whalen/.local/lib/python3.13/site-packages/ccxt/static_dependencies/ethereum/abi/utils/numeric.pyceil32r      s$    B!12R1r6!22    num_bitsc                     SSU -  S-
  4$ )Nr         r   r   s    r   compute_unsigned_integer_boundsr      s    		8a r   c                 .    SSU S-
  -  -  SU S-
  -  S-
  4$ )Nr   r   r   r   s    r   compute_signed_integer_boundsr      s.    
Q8a<  	hla r   frac_placesc                     [        U 5      S   n[        R                  " [        5         [        R                  " U5      [
        U* -  -  nS S S 5        [        U4$ ! , (       d  f       [        W4$ = f)Nr   )r   decimallocalcontextabi_decimal_contextDecimalTENZERO)r   r   	int_upperuppers       r   compute_unsigned_fixed_boundsr"   !   sb     09!<I			1	2	*S;,->> 
3 ; 
3	2 ;s   "A
A0c                    [        U 5      u  p#[        R                  " [        5         [        U* -  n[        R
                  " U5      U-  n[        R
                  " U5      U-  nS S S 5        XV4$ ! , (       d  f       WW4$ = fN)r   r   r   r   r   r   )r   r   	int_lowerr    explowerr!   s          r   compute_signed_fixed_boundsr(   -   sv     9BI			1	2K<	*S0	*S0 
3
 < 
3	2
 %<s   =A00
Bplacesc                 x  ^ [        U [        5      (       d  [        SU  S[        U 5       S35      e[        R
                  " [        5         [        U * -  mSSS5        S[        R                  S[        R                  4U4S jjnU S:  a  S	U  3OS
U *  3nSU 3nX1l	        X1l
        U$ ! , (       d  f       NZ= f)zg
Returns a function that shifts the decimal point of decimal values to the
right by ``places`` places.
z*Argument `places` must be int.  Got value z	 of type .Nr   r   c                 x   > [         R                  " [        5         U T-  sS S S 5        $ ! , (       d  f       g = fr$   )r   r   r   )r   scaling_factors    r   fscale_places.<locals>.fI   s&    !!"56~% 766s   +
9r   EnegEpos	scale_by_)
isinstanceint
ValueErrortyper   r   r   r   r   __name____qualname__)r)   r.   places_repr	func_namer-   s       @r   scale_placesr;   ;   s    
 fc""8 AF|nA'
 	

 
		1	2vg 
3&W__ & & &,aZD/tVG95EKK=)IJNH 
3	2s   B++
B9)r   typingr   r   ABI_DECIMAL_PRECContextr   r   r   r   r4   r   r   r   r"   r(   r;   r   r   r   <module>r?      s   
  oo+;< qoob3c 3c 3c eCHo C E#s(O 			 7??GOO+,	 7??GOO+, 7??*;W__*L!M r   