diff options
Diffstat (limited to 'tests/cpp/include/variables/011-012-value-casting-operators.h')
-rw-r--r-- | tests/cpp/include/variables/011-012-value-casting-operators.h | 52 |
1 files changed, 0 insertions, 52 deletions
diff --git a/tests/cpp/include/variables/011-012-value-casting-operators.h b/tests/cpp/include/variables/011-012-value-casting-operators.h deleted file mode 100644 index 2d791b2..0000000 --- a/tests/cpp/include/variables/011-012-value-casting-operators.h +++ /dev/null @@ -1,52 +0,0 @@ -/** - * - * Test variables - * 011-value-casting-operators.phpt - * 012-value-casting-operators-double.phpt - * - */ - - - -/** - * Set up namespace - */ -namespace TestVariables { - - /* - * Test Php::Value casting operators - */ - void value_casting(Php::Parameters ¶ms) - { - Php::Value value = params[0]; - - int64_t value1 = value; - std::string value2 = value; - bool value4 = value; - - Php::out << " long:" << value1 << "\n string:" << value2 << "\n bool:" << bool2str(value4) << std::endl; - } - - - /* - * Test Php::Value casting operators - */ - void value_cast2double(Php::Parameters ¶ms) - { - Php::Value value = params[0]; - double value3 = value; - - /* - * The remark (from valmat). - * Somehow std::to_string truncates the tail of numbers of type `double` when converting it to a string. - * So I wrote my own function `double2str()`, which does not have this drawback. - */ - Php::out << double2str(value3) << std::endl; - } - - -/** - * End of namespace - */ -} - |