xref: /PHP-7.4/Zend/tests/self_mod.phpt (revision 1e82ad80)
1--TEST--
2Moduloing strings
3--FILE--
4<?php
5
6$s = "123";
7$s1 = "test";
8$s2 = "45345some";
9
10$s %= 22;
11var_dump($s);
12
13$s1 %= 11;
14var_dump($s1);
15
16$s2 %= 33;
17var_dump($s2);
18
19echo "Done\n";
20?>
21--EXPECTF--
22int(13)
23
24Warning: A non-numeric value encountered in %s on line %d
25int(0)
26
27Notice: A non well formed numeric value encountered in %s on line %d
28int(3)
29Done
30