Run Rector on your code to see what it can do for you:
var_dump(preg_match('#[0-9]+#u', '1')); var_dump(preg_match('#[\d]+#u', '1')); -var_dump(preg_match('#[0-9]+#', '1')); +var_dump(preg_match('#\d+#', '1')); var_dump(preg_match('#[\d]+#', '1'));
Applied Rules:
Not a change you expect?
rector.php