Home
last modified time | relevance | path

Searched refs:pack (Results 1 – 25 of 64) sorted by relevance

123

/PHP-7.0/ext/standard/tests/strings/
H A Dpack.phpt2 Generic pack()/unpack() tests
13 echo '"'.pack("A9", "hello").'"';
16 print_r(unpack("C", pack("C", -127)));
17 print_r(unpack("C", pack("C", 127)));
18 print_r(unpack("C", pack("C", 255)));
19 print_r(unpack("C", pack("C", -129)));
21 print_r(unpack("H", pack("H", 0x04)));
24 print_r(unpack("I", pack("I", 0)));
31 print_r(unpack("L", pack("L", 0)));
37 print_r(unpack("N", pack("N", 0)));
[all …]
H A Dpack_float.phpt6 'pack e',
7 bin2hex(pack("e", "")),
11 bin2hex(pack("e", 0)),
12 bin2hex(pack("e", 1)),
23 'pack E',
40 'pack g',
57 'pack G',
117 string(6) "pack e"
133 string(6) "pack E"
149 string(6) "pack g"
[all …]
H A Dpack64.phpt2 64bit pack()/unpack() tests
11 print_r(unpack("Q", pack("Q", 0xfffffffffffe)));
12 print_r(unpack("Q", pack("Q", 0)));
14 print_r(unpack("Q", pack("Q", -1)));
17 print_r(unpack("J", pack("J", 0xfffffffffffe)));
18 print_r(unpack("J", pack("J", 0)));
20 print_r(unpack("J", pack("J", -1)));
24 print_r(unpack("P", pack("P", 0)));
26 print_r(unpack("P", pack("P", -1)));
30 print_r(unpack("q", pack("q", 0)));
[all …]
H A Dpack_Z.phpt2 pack()/unpack(): "Z" format
6 pack("Z0", "f"),
7 pack("Z5", "foo\0"),
8 pack("Z4", "fooo"),
9 pack("Z4", "foo"),
10 pack("Z*", "foo"),
H A Dpack64_32.phpt2 64bit pack()/unpack() tests
11 var_dump(pack("Q", 0));
12 var_dump(pack("J", 0));
13 var_dump(pack("P", 0));
14 var_dump(pack("q", 0));
22 Warning: pack(): 64-bit format codes are not available for 32-bit versions of PHP in %s on line %d
25 Warning: pack(): 64-bit format codes are not available for 32-bit versions of PHP in %s on line %d
28 Warning: pack(): 64-bit format codes are not available for 32-bit versions of PHP in %s on line %d
31 Warning: pack(): 64-bit format codes are not available for 32-bit versions of PHP in %s on line %d
H A Dpack_A.phpt2 pack()/unpack(): "A" modifier
6 pack("A5", "foo "),
7 pack("A4", "fooo"),
8 pack("A4", "foo"),
H A Dbug35817.phpt5 $a = pack("H3","181");
9 $a = pack("H2","18");
13 $a = pack("H","1");
H A Dbug70487.phpt2 Bug #70487: pack('x') produces an error
6 var_dump(pack('x') === "\0");
H A Dunpack_error.phpt8 * Source code: ext/standard/pack.c
18 var_dump(unpack("I", pack("I", 65534), $extra_arg));
22 var_dump(unpack("B", pack("I", 65534)));
H A Dbug69522.phpt5 $a = pack("AAAAAAAAAAAA", 1,2,3,4,5,6,7,8,9,10,11,12);
H A Dhtmlentities20.phpt7 $retval = pack('C', $k);
9 $retval = pack('C2',
13 $retval = pack('C3',
18 $retval = pack('C4',
/PHP-7.0/ext/mbstring/tests/
H A Dmb_convert_encoding_stateful.phpt11 echo bin2hex(mb_convert_encoding(pack("H*", "1b24401b24402121"), "UTF-8", "ISO-2022-JP")), "\n";
12 echo bin2hex(mb_convert_encoding(pack("H*", "1b24421b24422121"), "UTF-8", "ISO-2022-JP")), "\n";
13 echo bin2hex(mb_convert_encoding(pack("H*", "1b28421b284261626364"), "UTF-8", "ISO-2022-JP")), "\n";
14 echo bin2hex(mb_convert_encoding(pack("H*", "1b284a1b284a61626364"), "UTF-8", "ISO-2022-JP")), "\n";
15 echo bin2hex(mb_convert_encoding(pack("H*", "1b24401b284261626364"), "UTF-8", "ISO-2022-JP")), "\n";
16 echo bin2hex(mb_convert_encoding(pack("H*", "1b24401b284a61626364"), "UTF-8", "ISO-2022-JP")), "\n";
17 echo bin2hex(mb_convert_encoding(pack("H*", "1b24421b284261626364"), "UTF-8", "ISO-2022-JP")), "\n";
18 echo bin2hex(mb_convert_encoding(pack("H*", "1b24421b284a61626364"), "UTF-8", "ISO-2022-JP")), "\n";
20 echo bin2hex(mb_convert_encoding(pack("H*", "1b2429430e0f61626364"), "UTF-8", "ISO-2022-KR")), "\n";
22 echo bin2hex(mb_convert_encoding(pack("H*", "7e7b7e7d61626364"), "UTF-8", "HZ")), "\n";
/PHP-7.0/ext/phar/tests/zip/files/
H A Dcorrupt_zipmaker.php.inc91 $file = "PK\x03\x04\x14\x00\x00\x00" . pack('v', $compmethod) .
98 $file = "PK\x03\x04\x14\x00\x00\x00" . pack('v', $fakecomp) .
105 $file = "PK\x03\x04\x14\x00\x01\x00" . pack('v', $compmethod) .
112 $file = "PK\x03\x04\x14\x00\x00\x00" . pack('v', $compmethod) .
287 pack("vvVVv", $this->count, $this->count,
293 pack("vvVVv", $this->count, $this->count,
299 pack("vvVVv", $this->count + 1, $this->count,
305 pack("vvVVv", $this->count, $this->count + 1,
311 pack("vvVVv", $this->count, $this->count,
317 pack("vvVVv", $this->count, $this->count,
[all …]
/PHP-7.0/ext/gd/tests/
H A Dbug72339.phpt16 fwrite($fh, pack("n", 2));
17 fwrite($fh, pack("n", 1));
18 fwrite($fh, pack("n", 1));
19 fwrite($fh, pack("n", 0x40));
20 fwrite($fh, pack("n", 2));
21 fwrite($fh, pack("n", 0x5AA0)); // Chunks Wide
22 fwrite($fh, pack("n", 0x5B00)); // Chunks Vertically
/PHP-7.0/ext/phar/
H A Dtar.h23 #pragma pack(1)
34 # pragma pack 0
58 # pragma pack 0
98 #pragma pack()
/PHP-7.0/ext/phar/tests/
H A D010.phpt15 $manifest = pack('V', 1) . 'a' . pack('VVVVVV', 0, time(), 0, crc32(b''), 0x00000000, 0);
16 $file .= pack('VVnVV', strlen($manifest), 1, 0x1000, 0x00000000, 3) . 'hio' . pack('V', 0) . $manif…
/PHP-7.0/ext/standard/
H A Dpack.h24 PHP_MINIT_FUNCTION(pack);
25 PHP_FUNCTION(pack);
/PHP-7.0/ext/phar/tests/files/
H A Dphar_test.inc43 $manifest .= pack('V', strlen($name)) . (binary)$name;
44 …$manifest .= pack('VVVVVV', $ulen, $time, $clen, $crc32, $flags|$perm, strlen($meta)) . (binary)$m…
55 $manifest = pack('VnVV', count($files), isset($hasdir) ? 0x1110 : 0x1000, $gflags, strlen($alias)) …
57 $file .= pack('V', strlen($manifest)) . $manifest;
/PHP-7.0/ext/phar/tests/cache_list/files/
H A Dphar_test.inc43 $manifest .= pack('V', strlen($name)) . (binary)$name;
44 …$manifest .= pack('VVVVVV', $ulen, $time, $clen, $crc32, $flags|$perm, strlen($meta)) . (binary)$m…
55 $manifest = pack('VnVV', count($files), isset($hasdir) ? 0x1110 : 0x1000, $gflags, strlen($alias)) …
57 $file .= pack('V', strlen($manifest)) . $manifest;
/PHP-7.0/ext/dba/tests/
H A Dbug38698.phpt12 return 0x00FF === current(unpack('v', pack('S',0x00FF)));
19 dba_insert(pack('V',129), "Booo!", $db_make);
21 dba_insert(pack('i',129), "Booo!", $db_make);
/PHP-7.0/ext/standard/tests/serialize/
H A Dprecision.phpt5 if (pack('s', 1) != "\x01\x00")
27 $num = unpack("d", pack("H*", $ns)); $num = reset($num);
30 $repr = unpack("H*", pack("d", $num2)); $repr = reset($repr);
/PHP-7.0/ext/phar/tests/tar/files/
H A Dtarmaker.php.inc80 $block = pack('a100a8a8a8a12A12',
89 $blockend = pack('a1a100a6a2a32a32a8a8a155a12',
108 $checksum = pack('a8', sprintf('%6s ', decoct($checksum)));
166 fwrite($this->tmp, pack('a1024', ''));
H A Dcorrupt_tarmaker.php.inc87 $block = pack('a100a8a8a8a12A12',
96 $blockend = pack('a1a100a6a2a32a32a8a8a155a12',
116 $checksum = pack('a8', sprintf('%6s ', decoct($checksum)));
174 fwrite($this->tmp, pack('a1024', ''));
H A Dmake.dangerous.tar.php.inc81 $block = pack('a100a8a8a8a12A12',
90 $blockend = pack('a1a100a6a2a32a32a8a8a155a12',
109 $checksum = pack('a8', sprintf('%6s ', decoct($checksum)));
167 fwrite($this->tmp, pack('a1024', ''));
/PHP-7.0/win32/build/
H A DMakefile162 -rd /s /q $(BUILD_DIR)\php-test-pack-$(PHP_VERSION_STRING)
164 …-del /f /q $(BUILD_DIR)\php-debug-pack-$(PHP_VERSION_STRING)$(PHP_ZTS_ARCHIVE_POSTFIX)-Win32-$(PHP…
166 -del /f /q $(BUILD_DIR)\php-test-pack-$(PHP_VERSION_STRING).zip
193 …-del /f /q $(BUILD_DIR)\php-debug-pack-$(PHP_VERSION_STRING)$(PHP_ZTS_ARCHIVE_POSTFIX)-Win32-$(PHP…
200 cd $(BUILD_DIR)\php-test-pack-$(PHP_VERSION_STRING)
201 -$(ZIP) -9 -q -r ..\php-test-pack-$(PHP_VERSION_STRING).zip .
203 …-$(ZIP) -9 -q php-debug-pack-$(PHP_VERSION_STRING)$(PHP_ZTS_ARCHIVE_POSTFIX)-Win32-$(PHP_COMPILER_…
204 …-$(ZIP) -9 -q -r php-devel-pack-$(PHP_VERSION_STRING)$(PHP_ZTS_ARCHIVE_POSTFIX)-Win32-$(PHP_COMPIL…

Completed in 26 milliseconds

123