1 #ifndef STLPLUS_PERSISTENT_FLOAT
2 #define STLPLUS_PERSISTENT_FLOAT
3 ////////////////////////////////////////////////////////////////////////////////
5 // Author: Andy Rushton
6 // Copyright: (c) Southampton University 1999-2004
7 // (c) Andy Rushton 2004-2009
8 // License: BSD License, see ../docs/license.html
10 // Persistence of floating-point types
12 // Note: despite years and years of IEEE standardisation, not all
13 // architectures use IEEE-standard representations of floating-point numbers.
14 // Therefore a binary dump is not necessarily portable between platforms.
15 // Solving this is (currently) beyond the scope of the STLplus project.
17 // If you want to be strictly portable to all platforms, do not dump/restore float
19 ////////////////////////////////////////////////////////////////////////////////
20 #include "persistence_fixes.hpp"
21 #include "persistent_contexts.hpp"
23 ////////////////////////////////////////////////////////////////////////////////
28 void dump_float(dump_context
&, const float& data
) throw(persistent_dump_failed
);
29 void restore_float(restore_context
&, float& data
) throw(persistent_restore_failed
);
31 void dump_double(dump_context
&, const double& data
) throw(persistent_dump_failed
);
32 void restore_double(restore_context
&, double& data
) throw(persistent_restore_failed
);
34 } // end namespace stlplus
36 ////////////////////////////////////////////////////////////////////////////////