mirror of
https://github.com/Microsoft/calculator.git
synced 2025-08-22 14:13:30 -07:00
Make _number.mant an std::vector (rather than a non-standard flexible array member)
This commit is contained in:
parent
82ea309e70
commit
3355947ed8
1 changed files with 1 additions and 6 deletions
|
@ -55,8 +55,6 @@ typedef enum eANGLE_TYPE ANGLE_TYPE;
|
||||||
//
|
//
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
||||||
#pragma warning(push)
|
|
||||||
#pragma warning(disable:4200) // nonstandard extension used : zero-sized array in struct/union
|
|
||||||
typedef struct _number
|
typedef struct _number
|
||||||
{
|
{
|
||||||
int32_t sign; // The sign of the mantissa, +1, or -1
|
int32_t sign; // The sign of the mantissa, +1, or -1
|
||||||
|
@ -64,11 +62,8 @@ typedef struct _number
|
||||||
// radix being used.
|
// radix being used.
|
||||||
int32_t exp; // The offset of digits from the radix point
|
int32_t exp; // The offset of digits from the radix point
|
||||||
// (decimal point in radix 10)
|
// (decimal point in radix 10)
|
||||||
MANTTYPE mant[];
|
std::vector<MANTTYPE> mant;
|
||||||
// This is actually allocated as a continuation of the
|
|
||||||
// NUMBER structure.
|
|
||||||
} NUMBER, *PNUMBER, **PPNUMBER;
|
} NUMBER, *PNUMBER, **PPNUMBER;
|
||||||
#pragma warning(pop)
|
|
||||||
|
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue