3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $count = 7999; $string = str_repeat("a", $count); var_dump(preg_match('/\A( [\x09\x0A\x0D\x20-\x7E] | [\xC2-\xDF][\x80-\xBF] | \xE0[\xA0-\xBF][\x80-\xBF] | [\xE1-\xEC\xEE\xEF][\x80-\xBF]{2} | \xED[\x80-\x9F][\x80-\xBF] | \xF0[\x90-\xBF][\x80-\xBF]{2} | [\xF1-\xF3][\x80-\xBF]{3} | \xF4[\x80-\x8F][\x80-\xBF]{2} )*\z/x', $string)); ?>
Output for 7.0.0 - 7.1.0
bool(false)
Output for 4.3.0 - 4.4.8, 5.0.0 - 5.2.3, 5.3.23 - 5.5.35, 5.6.0 - 5.6.21, hhvm-3.10.0 - 3.12.0
int(1)
Output for 4.4.9, 5.2.4 - 5.3.22, 5.5.36 - 5.5.37, 5.6.22 - 5.6.28

Process exited with code 139.