poco icon indicating copy to clipboard operation
poco copied to clipboard

`Dynamic::Var` silently loses precision on int->float conversion

Open aleks-f opened this issue 1 year ago • 2 comments

Description As stated - on integral to floating point conversion, loss of precision is suppressed and ignored.

To Reproduce Assign an int value occupying more than 23 bits (on most platforms) to a float.

Expected behavior Precision loss should be allowed (as is in the language type system). However, it should be possible to enforce strict no-precision-loss policy for integral to floating point conversions.

aleks-f avatar Jan 29 '24 19:01 aleks-f

Should Poco consider migrating to std::any now that C++17 is supported?

andrewauclair avatar Jan 29 '24 21:01 andrewauclair

Should Poco consider migrating to std::any now that C++17 is supported?

Poco::Any and std::any originate from the same source - Kevlin Henney's boost::any. I have no cycles to replace it, and I'm not sure it is worth the effort, either.

aleks-f avatar Jan 29 '24 21:01 aleks-f