You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To give flexibility, and support systems that do not or cannot install php-bcmath, I suggest adding some assertions in AbstractUnit::as() or in BinaryCalculator to check that the bcmath extension is installed if someone is attempting to use the BinaryCalculator.
It appears this is approach is already taken for ext-intlhere.
The text was updated successfully, but these errors were encountered:
Currently, there is a requirement for
ext-bcmath
to be installed:unit-converter/composer.json
Lines 12 to 16 in a873250
However, it is possible to use
SimpleCalculator
instead ofBinaryCalculator
:unit-converter/src/Unit/AbstractUnit.php
Lines 128 to 135 in a873250
To give flexibility, and support systems that do not or cannot install
php-bcmath
, I suggest adding some assertions inAbstractUnit::as()
or inBinaryCalculator
to check that thebcmath
extension is installed if someone is attempting to use the BinaryCalculator.It appears this is approach is already taken for
ext-intl
here.The text was updated successfully, but these errors were encountered: