xref: /PHP-7.4/ext/ffi/tests/042.phpt (revision 1449d496)
1--TEST--
2FFI 042: Next array element
3--SKIPIF--
4<?php require_once('skipif.inc'); ?>
5--INI--
6ffi.enable=1
7--FILE--
8<?php
9$a = FFI::new("uint8_t[8]");
10$a[] = 0;
11?>
12--EXPECTF--
13Fatal error: Uncaught FFI\Exception: Cannot add next element to object of type FFI\CData in %s:3
14Stack trace:
15#0 {main}
16  thrown in %s on line 3
17