v1.07 An MFC class which provides 96 bit integers
If you have every been doing any arithmetic which stretches the limits of the
build in "__int64" data type in Visual C++, then here is a class which
gives you an extra 4 bytes to play with.
- Provides constructors which convert between all the basic types (including
__int64) to CInt96.
- All the standard operators are provided allowing the class to be used as
if it was an intrinsic data type.
- Methods are provided to convert to and from Hex, binary and decimal strings.
- Functions are available to allow individual bits to be easily set or retrieved.
The enclosed zip file contains the CInt96 source
code and a simple console program which exercises the class.
- You are allowed to include the source code in any product (commercial, shareware,
freeware or otherwise) when your product is released in binary form.
- You are allowed to modify the source code in any way you want except you
cannot modify the copyright details at the top of each module.
- If you want to distribute source code with your application, then you are
only allowed to distribute versions released by the author. This is to maintain
a single distribution point for the source code.
28 August 2016
V1.07 (31 January 2006)
- Updated copyright details.
- Updated the code to exclude MFC specific logic using the preprocessor macro
_AFX instead of _GNUC__. This allows the core of the class to be used in non
MFC projects on windows compilers. Thanks to Larry Hastings for this update.
- Updated documentation to use the same style as the web site.
V1.06 (26 March 2005)
- Code is now compatible with Cygwin/gcc. Note that the screen output conversion
and MFC archived functions have been ifdef'ed out. Thanks to David Moloney for
this nice addition.
V1.05 (20 November 2002)
- Updated the copyright message in the header and cpp file
- Added missing stdafx.h/cpp to the download zip file
- Fixed a logic error in the operator< and operator> methods when comparing
negative and positive values. Thanks to Steffen Offermann for reporting and
fixing this problem.
V1.04 (5 December 1999)
- Fixed problem with operator* which was giving incorrect results in some
cases, Thanks go to G.J.E. Visser for finding this.
V1.03 (28 October 1999)
- Fixed another bug in operator!=
- removed the use of MAXDWORD and replaced with 0xFFFFFFFF.
V1.02 (26 October 1999)
- Fixed bug in operator!=.
- Fixed bug in operator^.
- Fixed bug in operator| .
- Fixed bug in operator&.
- All relational and equality operators now return "int" instead
- Provision of operators which convert back to basic C types.
- Improved the performance of operator*.
- Fixed problem with 0/0 which was returning 0 instead of the correct value
undefined i.e. divide by 0 exception. Thanks to G.J.E. Visser finding all these
V1.01 (17 October 1999)
- Fix for the function FormatAsDecimal which was failing when the number starts
with a "10".
v1.0 (11 July 1999)