Current Path : /usr/local/lib/python2.5/ctypes/test/ |
FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64 |
Current File : //usr/local/lib/python2.5/ctypes/test/test_byteswap.pyc |
³ò h”Rc @ s‹ d d k Z d d k Z d d k Z d d k Z d d k l Z d d k Td „ Z d e i f d „ ƒ YZ e d j o e i ƒ n d S( iÿÿÿÿN( t hexlify( t *c C s t t | ƒ ƒ i ƒ S( N( R t buffert upper( t s( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyt bin s t Testc B st e Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z RS( c C sR t i t i IJx; t d ƒ D]- } t ƒ } t | d | d ƒ t | ƒ q Wd S( Ni s i%si ( t syst stderrt byteordert ranget BITSt setattrt dump( t selft it bits( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyt X_test s c C sÞ t i d j o3 | i t i t j ƒ | i t i i t j ƒ n0 | i t i t j ƒ | i t i i t j ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ d S( Nt littlei4 s >ht 1234s <ht 3412( R R t failUnlesst c_shortt __ctype_le__t __ctype_be__t failUnlessEqualR t structt packt valuet c_ushort( R R ( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyt test_endian_short s* """"c C sÞ t i d j o3 | i t i t j ƒ | i t i i t j ƒ n0 | i t i t j ƒ | i t i i t j ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ d S( NR ixV4s >it 12345678s <it 78563412s >Is <I( R R R t c_intR R R R R R R t c_uint( R R ( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyt test_endian_int3 s* """"c C sÞ t i d j o3 | i t i t j ƒ | i t i i t j ƒ n0 | i t i t j ƒ | i t i i t j ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ t i d ƒ } | i t t i d d ƒ ƒ d ƒ | i t | ƒ d ƒ | i | i d ƒ d S( NR IïÍ«xV4s >qt 1234567890ABCDEFs <qt EFCDAB9078563412s >Qs <Q( R R R t c_longlongR R R R R R R t c_ulonglong( R R ( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyt test_endian_longlongO s* """"c C su t i d j o3 | i t i t j ƒ | i t i i t j ƒ n0 | i t i t j ƒ | i t i i t j ƒ t t i ƒ } | i t t i d t i ƒ ƒ t | ƒ ƒ | i | i t i d ƒ t i t i ƒ } | i | i t i d ƒ | i t t i d t i ƒ ƒ t | ƒ ƒ t i t i ƒ } | i | i t i d ƒ | i t t i d t i ƒ ƒ t | ƒ ƒ d S( NR t fi s <fs >f( R R R t c_floatR R t matht piR R R R t failUnlessAlmostEqualR ( R R ( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyt test_endian_floatk s ++c C sl t i d j o3 | i t i t j ƒ | i t i i t j ƒ n0 | i t i t j ƒ | i t i i t j ƒ t t i ƒ } | i | i t i ƒ | i t t i d t i ƒ ƒ t | ƒ ƒ t i t i ƒ } | i | i t i ƒ | i t t i d t i ƒ ƒ t | ƒ ƒ t i t i ƒ } | i | i t i ƒ | i t t i d t i ƒ ƒ t | ƒ ƒ d S( NR t ds <ds >d( R R R t c_doubleR R R+ R, R R R R R ( R R ( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyt test_endian_double} s ++c C sˆ | i t i t j ƒ | i t i t j ƒ | i t i t j ƒ | i t i t j ƒ | i t i t j ƒ | i t i t j ƒ d S( N( R t c_byteR R t c_ubytet c_char( R ( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyt test_endian_otherŽ s c C sb t i d j o t } n t } d | f d „ ƒ Y} d t f d t f d t f d t f d t f d t f d t f d t f d t f d t f d t f d t f d t f d t d f d t d f d t d f d t d d d f g } | | _ xh t t t t ƒ f D]Q } | i d | f ƒ d | f d „ ƒ Y} | i t t | d d | f g ƒ q Wd S( NR t Tc B s e Z RS( ( t __name__t __module__( ( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyR6 ž s t at bt cR/ t eR) t gt hR t kt lt mt nt b1i t b2t b3i t xc B s e Z RS( ( R7 R8 ( ( ( s5 /usr/local/lib/python2.5/ctypes/test/test_byteswap.pyR6 · s t _fields_( R R t BigEndianStructuret LittleEndianStructureR3 R2 R R R! R"