1--TEST--
2BcMath\Number calc non-numeric string by operator
3--EXTENSIONS--
4bcmath
5--FILE--
6<?php
7$num = new BcMath\Number(100);
8
9try {
10    $num + 'a';
11} catch (Error $e) {
12    echo $e->getMessage() . "\n";
13}
14
15try {
16    $num - 'a';
17} catch (Error $e) {
18    echo $e->getMessage() . "\n";
19}
20
21try {
22    $num * 'a';
23} catch (Error $e) {
24    echo $e->getMessage() . "\n";
25}
26
27try {
28    $num / 'a';
29} catch (Error $e) {
30    echo $e->getMessage() . "\n";
31}
32
33try {
34    $num % 'a';
35} catch (Error $e) {
36    echo $e->getMessage() . "\n";
37}
38
39try {
40    $num ** 'a';
41} catch (Error $e) {
42    echo $e->getMessage() . "\n";
43}
44?>
45--EXPECT--
46Right string operand cannot be converted to BcMath\Number
47Right string operand cannot be converted to BcMath\Number
48Right string operand cannot be converted to BcMath\Number
49Right string operand cannot be converted to BcMath\Number
50Right string operand cannot be converted to BcMath\Number
51Right string operand cannot be converted to BcMath\Number
52