xref: /php-src/tests/lang/bug24054.phpt (revision 3a4b8966)
1--TEST--
2Bug #24054 (Assignment operator *= broken)
3--FILE--
4<?php
5
6define('LONG_MAX', is_int(5000000000)? 9223372036854775807 : 0x7FFFFFFF);
7define('LONG_MIN', -LONG_MAX - 1);
8printf("%d,%d,%d,%d\n",is_int(LONG_MIN  ),is_int(LONG_MAX  ),
9                       is_int(LONG_MIN-1),is_int(LONG_MAX+1));
10
11$i = LONG_MAX;
12$j = $i * 1001;
13$i *= 1001;
14
15var_dump($i === $j);
16
17?>
18--EXPECT--
191,1,0,0
20bool(true)
21