Vendor/phpspreadsheet/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Writer/Xls/BIFFwriter.php
public static function getByteOrder()
    {
        if (!isset(self::$byteOrder)) {
            // Check if "pack" gives the required IEEE 64bit float
            $teststr = pack('d', 1.2345);
            $number = pack('C8', 0x8D, 0x97, 0x6E, 0x12, 0x83, 0xC0, 0xF3, 0x3F);
            if ($number == $teststr) {
                $byte_order = 0; // Little Endian
            } elseif ($number == strrev($teststr)) {
                $byte_order = 1; // Big Endian
            } else {
                // Give up. I'll fix this in a later version.
                throw new WriterException('Required floating point format not supported on this platform.');
            }
            self::$byteOrder = $byte_order;
        }

        return self::$byteOrder;
    }
public static function getByteOrder()
    {
        if (!isset(self::$byteOrder)) {
            // Check if "pack" gives the required IEEE 64bit float
            $teststr = pack('d', 1.2345);
            $number = pack('C8', 0x8D, 0x97, 0x6E, 0x12, 0x83, 0xC0, 0xF3, 0x3F);
            if ($number == $teststr) {
                $byte_order = 0; // Little Endian
            } elseif ($number == strrev($teststr)) {
                $byte_order = 1; // Big Endian
            } else {
                // Give up. I'll fix this in a later version.
                throw new WriterException('Required floating point format not supported on this platform.');
            }
            self::$byteOrder = $byte_order;
        }

        return self::$byteOrder;
    }
Determine the byte order and store it as class data to avoid
recalculating it for each call to new().

@return int