From 3355947ed86660e5013506cde4c87e4efd11f80a Mon Sep 17 00:00:00 2001 From: fwcd Date: Sat, 6 Apr 2019 16:08:43 +0200 Subject: [PATCH] Make _number.mant an std::vector (rather than a non-standard flexible array member) --- src/CalcManager/Ratpack/ratpak.h | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/CalcManager/Ratpack/ratpak.h b/src/CalcManager/Ratpack/ratpak.h index efb33a8f..c3d98bb1 100644 --- a/src/CalcManager/Ratpack/ratpak.h +++ b/src/CalcManager/Ratpack/ratpak.h @@ -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 { int32_t sign; // The sign of the mantissa, +1, or -1 @@ -64,11 +62,8 @@ typedef struct _number // radix being used. int32_t exp; // The offset of digits from the radix point // (decimal point in radix 10) - MANTTYPE mant[]; - // This is actually allocated as a continuation of the - // NUMBER structure. + std::vector mant; } NUMBER, *PNUMBER, **PPNUMBER; -#pragma warning(pop) //-----------------------------------------------------------------------------