Mangling for cent/ucent

Iain Buclaw ibuclaw at ubuntu.com
Sat Feb 23 09:26:57 PST 2013


On Feb 23, 2013 4:41 PM, "Daniel Murphy" <yebblies at nospamgmail.com> wrote:
>
> "Iain Buclaw" <ibuclaw at ubuntu.com> wrote in message
> news:mailman.1485.1361633569.22503.digitalmars-d at puremagic.com...
> >
> > No reason not to allow all typical numeric operations.  Of course you'll
> > need explicit casts to do 'long = cent' operations, and 'cent =
long+long'
> > should not require a cast.
> >
> > Overall, there's nothing that looks too special about the type, and
> > support
> > for it appears to work just fine when testing simple working cases on
> > 32bit.
> >
>
> The problem is in adding complete support to the frontend, you need
128-bit
> integer literals, constant folding, ctfe and range propagation.  There's
> probably more work involved in adding it to the dmd frontend than the dmd
> backend.
>

I don't use any part of the dmd backend. :o)

Constant folding and ctfe wouldn't be high priorities for this type.
Support in frontend would be more equal to, say how vectors are handled.

Regards
-- 
Iain Buclaw

*(p < e ? p++ : p) = (c & 0x0f) + '0';
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20130223/edd85e7b/attachment.html>


More information about the Digitalmars-d mailing list