1--TEST-- 2Bug #70089 (segfault in PHP 7 at ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER ()) 3--INI-- 4opcache.enable=0 5--FILE-- 6<?php 7function dummy($a) { 8} 9 10try { 11 chr(0)[0][] = 1; 12} catch (Error $e) { 13 var_dump($e->getMessage()); 14} 15try { 16 unset(chr(0)[0][0]); 17} catch (Error $e) { 18 var_dump($e->getMessage()); 19} 20eval("function runtimetest(&\$a) {} "); 21try { 22 runtimetest(chr(0)[0]); 23} catch (Error $e) { 24 var_dump($e->getMessage()); 25} 26 27try { 28 ++chr(0)[0]; 29} catch (Error $e) { 30 var_dump($e->getMessage()); 31} 32?> 33--EXPECTF-- 34string(36) "Cannot use string offset as an array" 35string(27) "Cannot unset string offsets" 36string(41) "Only variables can be passed by reference" 37string(41) "Cannot increment/decrement string offsets" 38