We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 90ceac6 + b47a48f commit 6bf1d24Copy full SHA for 6bf1d24
ext/opcache/tests/jit/bug81512.phpt
@@ -0,0 +1,33 @@
1
+--TEST--
2
+Bug #81512: Unexpected behavior with arrays and JIT
3
+--INI--
4
+opcache.enable=1
5
+opcache.enable_cli=1
6
+opcache.file_update_protection=0
7
+opcache.jit_buffer_size=1M
8
+--FILE--
9
+<?php
10
+$pipe = [['val1'],['val2'],];
11
+
12
+for ($i = 0; $i < 30; ++$i) {
13
+ echo "$i ";
14
+ if (!is_pipeline($pipe)) {
15
+ echo 'ERROR ';
16
+ }
17
+}
18
19
+function is_pipeline($pipeline): bool {
20
+ foreach ($pipeline as $stage) {
21
+ if (!is_array($stage)) {
22
+ return false; // must never happen
23
24
25
+ $stage = (array) $stage;
26
+ reset($stage);
27
28
29
+ return true;
30
31
+?>
32
+--EXPECT--
33
+0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
0 commit comments