diff options
author | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2011-06-07 18:23:16 +0000 |
---|---|---|
committer | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2011-06-07 18:23:16 +0000 |
commit | d4c3c3cc7aa35acdc94ab4bd5b067e128f1f3da3 (patch) | |
tree | d5b48a3aa02f0f66642456b5868a60aae661e482 | |
parent | 9b3978aa17faada4c62c5df00eba0a161b611d7a (diff) | |
download | ATCD-d4c3c3cc7aa35acdc94ab4bd5b067e128f1f3da3.tar.gz |
ChangeLogTag: Tue Jun 7 18:20:36 UTC 2011 Jeff Parsons <j.parsons@vanderbilt.edu>
-rw-r--r-- | ACE/ChangeLog | 10 | ||||
-rw-r--r-- | ACE/ace/CDR_Base.h | 9 |
2 files changed, 17 insertions, 2 deletions
diff --git a/ACE/ChangeLog b/ACE/ChangeLog index 010653050a4..c8be26dff2f 100644 --- a/ACE/ChangeLog +++ b/ACE/ChangeLog @@ -1,3 +1,13 @@ +Tue Jun 7 18:20:36 UTC 2011 Jeff Parsons <j.parsons@vanderbilt.edu> + + * ace/CDR_Base.h: + + Added an inline function called LongDoubleAssign tha works + as an alternative to the struct constructor of the same + name when a 16-byte native long double exists and the struct + is not defined. Thanks again to Adam Mitz <mitza at ociweb dot com> + for the idea. + Mon Jun 6 22:17:26 UTC 2011 Adam Mitz <mitza@ociweb.com> * ace/CDR_Base.h: diff --git a/ACE/ace/CDR_Base.h b/ACE/ace/CDR_Base.h index 63def9e208e..2589f1dea5b 100644 --- a/ACE/ace/CDR_Base.h +++ b/ACE/ace/CDR_Base.h @@ -291,10 +291,15 @@ public: typedef long double LongDouble; # define ACE_CDR_LONG_DOUBLE_INITIALIZER 0 # define ACE_CDR_LONG_DOUBLE_ASSIGNMENT(LHS, RHS) LHS = RHS + + // Trivial alternative to the derived class of the same name below, + // so the same code will work whether or not a native long double + // is used. + inline LongDouble LongDoubleAssign (const LongDouble &ld) {return ld;} # else # define NONNATIVE_LONGDOUBLE -# define ACE_CDR_LONG_DOUBLE_INITIALIZER {{0}} -# define ACE_CDR_LONG_DOUBLE_ASSIGNMENT(LHS, RHS) LHS.assign (RHS) +# define ACE_CDR_LONG_DOUBLE_INITIALIZER {{0}} +# define ACE_CDR_LONG_DOUBLE_ASSIGNMENT(LHS, RHS) LHS.assign (RHS) struct ACE_Export LongDouble { |