1--TEST-- 2Bug #76534 (PHP hangs on 'illegal string offset on string references with an error handler) 3--FILE-- 4<?php 5set_error_handler(function ($severity, $message, $file, $line) { 6 throw new \Exception($message); 7}); 8 9$x = "foo"; 10$y = &$x["2bar"]; 11?> 12--EXPECTF-- 13Fatal error: Uncaught Exception: Illegal string offset "2bar" in %s:%d 14Stack trace: 15#0 %s(%d): {closure:%s:%d}(2, 'Illegal string ...', '%s', 7) 16#1 {main} 17 thrown in %sbug76534.php on line %d 18