Add `ClarifyingSymbol` to `CurrencyDisplay`
PostScripton opened this issue · 0 comments
PostScripton commented
This means that currencies with, for example, $
symbol will identify their true nature.
For example, both Canadian and American dollars have the same symbol $
, and in order to understand which is which, ClarifyingSymbol
comes into place.
$cad = currency('CAD')->setDisplay(CurrencyDisplay::ClarifyingSymbol);
$cadMoney = money('2500', $cad);
$usd = currency('USD')->setDisplay(CurrencyDisplay::ClarifyingSymbol);
$usdMoney = money('2500', $usd);
$cadMoney->toString(); // "CA$ 0.25"
$usdMoney->toString(); // "US$ 0.25"