sdo message
[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
| [List Home]
Subject: ISSUE 48: Mapping for Decimal and Integer for C++
- From: Bryan Aupperle <aupperle@us.ibm.com>
- To: sdo@lists.oasis-open.org
- Date: Fri, 16 May 2008 12:53:31 -0400
I've been looking into this and there
is a proposal for decimal floating-point support (http://www.open-std.org/JTC1/SC22/WG21/docs/papers/2005/n1839.html)
which defines decimal32, decimal64 and decimal128 types and operations
for C++ decimal 64 allows for 16 digits and an exponent of -383 to
384. While decimal allows for 34 digits and an exponent of -6143
to 6144. The former is not quite large enough to for a minimally
conforming Decimal implementation (a minimum of 18 digits), but the later
is (decimal128 is optional in the draft).
I realize that the decimal types are
not yet a standard and not implement in all compilers (gcc does implement
them)
So I see three options for this issue.
1) Do nothing and simply admit there
is no natural mapping for Decimal and Integer in the most general case.
2) Map Decimal and Integer to string
when there are no facets constraining the value to fit in SDO:double or
SDO:long respectively. This does not allow for any arithmetic operations
on these types.
3) Permit mapping to decimal128 if supported
by the compiler. This still leaves range constraints, but they are
very generous.
Option 3 is a step forward and allows
option 2 as a fallback.
What do folks think?
Bryan Aupperle, Ph.D.
STSM, WebSphere Enterprise Platform Software Solution Architect
Research Triangle Park, NC
+1 919-254-7508 (T/L 444-7508)
Internet Address: aupperle@us.ibm.com
[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
| [List Home]