Did I find the right examples for you? yes no

All Samples(83)  |  Call(83)  |  Derive(0)  |  Import(0)
float.__getformat__(typestr) -> string

You probably don't want to use this function.  It exists mainly to be
used in Python's test suite.

typestr must be 'double' or 'float'.  This function returns whichever of
'unknown', 'IEEE, big-endian' or 'IEEE, little-endian' best describes the
format of floating point numbers used by the C type named by typestr.

src/s/y/Sypy-HEAD/rlib/rdtoa.py   Sypy(Download)
# and the C double's endianness (which should be equal)
if hasattr(float, '__getformat__'):
    assert float.__getformat__('double') == 'IEEE, %s-endian' % sys.byteorder
if sys.byteorder == 'little':
    source_file = ['#define DOUBLE_IS_LITTLE_ENDIAN_IEEE754']

src/m/a/main-HEAD/External.LCA_RESTRICTED/Languages/IronPython/27/Lib/test/test_float.py   main(Download)
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
 
    def tearDown(self):
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
        float.__setformat__('double', 'unknown')
        float.__setformat__('float', 'unknown')

src/m/a/main-HEAD/External.LCA_RESTRICTED/Languages/CPython/27/Lib/test/test_float.py   main(Download)
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
 
    def tearDown(self):
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
        float.__setformat__('double', 'unknown')
        float.__setformat__('float', 'unknown')

src/i/r/ironpython3-HEAD/Src/StdLib/Lib/test/test_float.py   ironpython3(Download)
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
 
    def tearDown(self):
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
        float.__setformat__('double', 'unknown')
        float.__setformat__('float', 'unknown')

src/p/l/plexnet-HEAD/third_party/generic/pypy/lib-python/modified-2.5.2/test/test_float.py   plexnet(Download)
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
 
    def tearDown(self):
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
        float.__setformat__('double', 'unknown')
        float.__setformat__('float', 'unknown')

src/p/l/plexnet-HEAD/third_party/generic/pypy/lib-python/2.5.2/test/test_float.py   plexnet(Download)
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
 
    def tearDown(self):
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
        float.__setformat__('double', 'unknown')
        float.__setformat__('float', 'unknown')

src/t/r/TrustRouter-HEAD/client/packaging/Windows/Python32/Lib/test/test_float.py   TrustRouter(Download)
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
 
    def tearDown(self):
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
        float.__setformat__('double', 'unknown')
        float.__setformat__('float', 'unknown')

src/s/y/Sypy-HEAD/objspace/std/test/test_floatobject.py   Sypy(Download)
    def test___getformat__(self):
        assert float.__getformat__("float") != "unknown"
        assert float.__getformat__("double") != "unknown"
        raises(ValueError, float.__getformat__, "random")
 

src/e/m/empythoned-HEAD/cpython/Lib/test/test_float.py   empythoned(Download)
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
 
    def tearDown(self):
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
        float.__setformat__('double', 'unknown')
        float.__setformat__('float', 'unknown')

src/g/i/gitstack-HEAD/python/Lib/test/test_float.py   gitstack(Download)
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
 
    def tearDown(self):
    def setUp(self):
        self.save_formats = {'double':float.__getformat__('double'),
                             'float':float.__getformat__('float')}
        float.__setformat__('double', 'unknown')
        float.__setformat__('float', 'unknown')

  1 | 2 | 3  Next