5 echo
"Usage: php gen_rare_cp_bitvec.php ./common_codepoints.txt\n";
13 if (
false !== $hashPos =
strpos($line,
'#')) {
14 $line =
substr($line, 0, $hashPos);
23 $start =
hexdec($range[0]);
26 for ($i = $start; $i <= $end; $i++) {
27 $bitvec[$i >> 5] &= ~(1 << ($i & 0x1F));
43static const uint32_t rare_codepoint_bitvec[] = {
46for ($i = 0; $i < 0xFFFF / 32; $i++) {
array_fill(int $start_index, int $count, mixed $value)
hexdec(string $hex_string)
trim(string $string, string $characters=" \n\r\t\v\0")
file_get_contents(string $filename, bool $use_include_path=false, $context=null, int $offset=0, ?int $length=null)
explode(string $separator, string $string, int $limit=PHP_INT_MAX)
strpos(string $haystack, string $needle, int $offset=0)
file_put_contents(string $filename, mixed $data, int $flags=0, $context=null)
str_pad(string $string, int $length, string $pad_string=" ", int $pad_type=STR_PAD_RIGHT)
substr(string $string, int $offset, ?int $length=null)
foreach(explode("\n", $input) as $line) $result