-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

This matches the behaviour of MSVC better in cases when there is
a mix of values < 0 and values > 0x7FFFFFFF in the same enum,
which, without this change, prompts GCC to increase enum size to 8 bytes.

Fixes bug #456

patch is attached

- -- 
O< ascii ribbon - stop html email! - www.asciiribbon.org

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJXGl48AAoJEOs4Jb6SI2Cwp3QH/1bl0MLE0oK9bDBo8Gsi+IXN
0Ra2B8AbXWgE2HvZepac8EkymxfqvuyIPSqZKgAqxgw+KsR9MiVzrVMAspInL9cw
sgyBbCa4UE7BoEjqWVPdYxRzMebRs7uQFvKgDX0RW4TMsZgexSDsgEIU2rRyzW8f
cmv31uPwWEedSCTvfrHi94ic8Ken3EkuIUXE11ShRAFL4JgY7L1wdkIzqwU6BgKX
jmLiW6TWtPxDHXoZ4l8Qf9s+OCOSf3wOP0C+xCQC56cKCGRJ060M7wxM3nGg2QtL
aP4jpsgy3zgI/mxNf6N+BPySRc510N+W9lW6IeBPUBtk2ESJa6h043z9BKMS97Q=
=Pk8Z
-----END PGP SIGNATURE-----
From 9c267d96aac4bd3cc00aaf4a174312fc55f0a32c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=D0=A0=D1=83=D1=81=D0=BB=D0=B0=D0=BD=20=D0=98=D0=B6=D0=B1?=
 =?UTF-8?q?=D1=83=D0=BB=D0=B0=D1=82=D0=BE=D0=B2?= <lrn1...@gmail.com>
Date: Fri, 22 Apr 2016 05:12:09 +0000
Subject: [PATCH] Cast certain enums to int

This matches the behaviour of MSVC better in cases when there is
a mix of values < 0 and values > 0x7FFFFFFF in the same enum,
which, without this change, prompts GCC to increase enum size to 8 bytes.

Fixes bug #456
---
 mingw-w64-headers/include/adoint_backcompat.h | 10 +++---
 mingw-w64-headers/include/tom.h               | 50 +++++++++++++--------------
 mingw-w64-headers/include/wingdi.h            | 34 +++++++++---------
 3 files changed, 47 insertions(+), 47 deletions(-)

diff --git a/mingw-w64-headers/include/adoint_backcompat.h 
b/mingw-w64-headers/include/adoint_backcompat.h
index bbc3c42..f816cb6 100755
--- a/mingw-w64-headers/include/adoint_backcompat.h
+++ b/mingw-w64-headers/include/adoint_backcompat.h
@@ -461,11 +461,11 @@ extern "C" {
   } ConnectModeEnum;
   typedef DECLSPEC_UUID ("00000570-0000-0010-8000-00AA006D2EA4")
   enum RecordCreateOptionsEnum { adCreateCollection = 0x2000,
-    adCreateStructDoc = 0x80000000,
-    adCreateNonCollection = 0,
-    adOpenIfExists = 0x2000000,
-    adCreateOverwrite = 0x4000000,
-    adFailIfNotExists = -1
+    adCreateStructDoc = (int) 0x80000000,
+    adCreateNonCollection = (int) 0,
+    adOpenIfExists = (int) 0x2000000,
+    adCreateOverwrite = (int) 0x4000000,
+    adFailIfNotExists = (int) -1
   } RecordCreateOptionsEnum;
   typedef DECLSPEC_UUID ("00000571-0000-0010-8000-00AA006D2EA4")
   enum RecordOpenOptionsEnum { adOpenRecordUnspecified = -1,
diff --git a/mingw-w64-headers/include/tom.h b/mingw-w64-headers/include/tom.h
index c3bc7a3..1bb7545 100644
--- a/mingw-w64-headers/include/tom.h
+++ b/mingw-w64-headers/include/tom.h
@@ -121,31 +121,31 @@ extern "C" {
 #ifndef __tom_LIBRARY_DEFINED__
 #define __tom_LIBRARY_DEFINED__
   typedef enum __MIDL___MIDL_itf_tom_0000_0001 {
-    tomFalse = 0,tomTrue = -1,tomUndefined = -9999999,tomToggle = 
-9999998,tomAutoColor = -9999997,tomDefault = -9999996,tomSuspend = -9999995,
-    tomResume = -9999994,tomApplyNow = 0,tomApplyLater = 1,tomTrackParms = 
2,tomCacheParms = 3,tomBackward = 0xc0000001,tomForward = 0x3fffffff,
-    tomMove = 0,tomExtend = 1,tomNoSelection = 0,tomSelectionIP = 
1,tomSelectionNormal = 2,tomSelectionFrame = 3,tomSelectionColumn = 4,
-    tomSelectionRow = 5,tomSelectionBlock = 6,tomSelectionInlineShape = 
7,tomSelectionShape = 8,tomSelStartActive = 1,tomSelAtEOL = 2,
-    tomSelOvertype = 4,tomSelActive = 8,tomSelReplace = 16,tomEnd = 0,tomStart 
= 32,tomCollapseEnd = 0,tomCollapseStart = 1,tomClientCoord = 256,
-    tomNone = 0,tomSingle = 1,tomWords = 2,tomDouble = 3,tomDotted = 4,tomDash 
= 5,tomDashDot = 6,tomDashDotDot = 7,tomWave = 8,tomThick = 9,
-    tomHair = 10,tomLineSpaceSingle = 0,tomLineSpace1pt5 = 
1,tomLineSpaceDouble = 2,tomLineSpaceAtLeast = 3,tomLineSpaceExactly = 4,
-    tomLineSpaceMultiple = 5,tomAlignLeft = 0,tomAlignCenter = 1,tomAlignRight 
= 2,tomAlignJustify = 3,tomAlignDecimal = 3,tomAlignBar = 4,
-    tomAlignInterWord = 3,tomAlignInterLetter = 4,tomAlignScaled = 
5,tomAlignGlyphs = 6,tomAlignSnapGrid = 7,tomSpaces = 0,tomDots = 1,tomDashes = 
2,
-    tomLines = 3,tomThickLines = 4,tomEquals = 5,tomTabBack = -3,tomTabNext = 
-2,tomTabHere = -1,tomListNone = 0,tomListBullet = 1,
-    tomListNumberAsArabic = 2,tomListNumberAsLCLetter = 
3,tomListNumberAsUCLetter = 4,tomListNumberAsLCRoman = 5,tomListNumberAsUCRoman 
= 6,
-    tomListNumberAsSequence = 7,tomListParentheses = 0x10000,tomListPeriod = 
0x20000,tomListPlain = 0x30000,tomCharacter = 1,tomWord = 2,
-    tomSentence = 3,tomParagraph = 4,tomLine = 5,tomStory = 6,tomScreen = 
7,tomSection = 8,tomColumn = 9,tomRow = 10,tomWindow = 11,tomCell = 12,
-    tomCharFormat = 13,tomParaFormat = 14,tomTable = 15,tomObject = 
16,tomMatchWord = 2,tomMatchCase = 4,tomMatchPattern = 8,tomUnknownStory = 0,
-    tomMainTextStory = 1,tomFootnotesStory = 2,tomEndnotesStory = 
3,tomCommentsStory = 4,tomTextFrameStory = 5,tomEvenPagesHeaderStory = 6,
-    tomPrimaryHeaderStory = 7,tomEvenPagesFooterStory = 
8,tomPrimaryFooterStory = 9,tomFirstPageHeaderStory = 
10,tomFirstPageFooterStory = 11,
-    tomNoAnimation = 0,tomLasVegasLights = 1,tomBlinkingBackground = 
2,tomSparkleText = 3,tomMarchingBlackAnts = 4,tomMarchingRedAnts = 5,
-    tomShimmer = 6,tomWipeDown = 7,tomWipeRight = 8,tomAnimationMax = 
8,tomLowerCase = 0,tomUpperCase = 1,tomTitleCase = 2,tomSentenceCase = 4,
-    tomToggleCase = 5,tomReadOnly = 0x100,tomShareDenyRead = 
0x200,tomShareDenyWrite = 0x400,tomPasteFile = 0x1000,tomCreateNew = 0x10,
-    tomCreateAlways = 0x20,tomOpenExisting = 0x30,tomOpenAlways = 
0x40,tomTruncateExisting = 0x50,tomRTF = 0x1,tomText = 0x2,tomHTML = 0x3,
-    tomWordDocument = 0x4,tomBold = 0x80000001,tomItalic = 
0x80000002,tomUnderline = 0x80000004,tomStrikeout = 0x80000008,tomProtected = 
0x80000010,
-    tomLink = 0x80000020,tomSmallCaps = 0x80000040,tomAllCaps = 
0x80000080,tomHidden = 0x80000100,tomOutline = 0x80000200,tomShadow = 
0x80000400,
-    tomEmboss = 0x80000800,tomImprint = 0x80001000,tomDisabled = 
0x80002000,tomRevised = 0x80004000,tomNormalCaret = 0,tomKoreanBlockCaret = 0x1,
-    tomIncludeInset = 0x1,tomIgnoreCurrentFont = 0,tomMatchFontCharset = 
0x1,tomMatchFontSignature = 0x2,tomCharset = 0x80000000,tomRE10Mode = 0x1,
-    tomNoIME = 0x80000,tomSelfIME = 0x40000
+    tomFalse = (int) 0,tomTrue = (int) -1,tomUndefined = (int) 
-9999999,tomToggle = (int) -9999998,tomAutoColor = (int) -9999997,tomDefault = 
(int) -9999996,tomSuspend = (int) -9999995,
+    tomResume = (int) -9999994,tomApplyNow = (int) 0,tomApplyLater = (int) 
1,tomTrackParms = (int) 2,tomCacheParms = (int) 3,tomBackward = (int) 
0xc0000001,tomForward = (int) 0x3fffffff,
+    tomMove = (int) 0,tomExtend = (int) 1,tomNoSelection = (int) 
0,tomSelectionIP = (int) 1,tomSelectionNormal = (int) 2,tomSelectionFrame = 
(int) 3,tomSelectionColumn = (int) 4,
+    tomSelectionRow = (int) 5,tomSelectionBlock = (int) 
6,tomSelectionInlineShape = (int) 7,tomSelectionShape = (int) 
8,tomSelStartActive = (int) 1,tomSelAtEOL = (int) 2,
+    tomSelOvertype = (int) 4,tomSelActive = (int) 8,tomSelReplace = (int) 
16,tomEnd = (int) 0,tomStart = (int) 32,tomCollapseEnd = (int) 
0,tomCollapseStart = (int) 1,tomClientCoord = (int) 256,
+    tomNone = (int) 0,tomSingle = (int) 1,tomWords = (int) 2,tomDouble = (int) 
3,tomDotted = (int) 4,tomDash = (int) 5,tomDashDot = (int) 6,tomDashDotDot = 
(int) 7,tomWave = (int) 8,tomThick = (int) 9,
+    tomHair = (int) 10,tomLineSpaceSingle = (int) 0,tomLineSpace1pt5 = (int) 
1,tomLineSpaceDouble = (int) 2,tomLineSpaceAtLeast = (int) 
3,tomLineSpaceExactly = (int) 4,
+    tomLineSpaceMultiple = (int) 5,tomAlignLeft = (int) 0,tomAlignCenter = 
(int) 1,tomAlignRight = (int) 2,tomAlignJustify = (int) 3,tomAlignDecimal = 
(int) 3,tomAlignBar = (int) 4,
+    tomAlignInterWord = (int) 3,tomAlignInterLetter = (int) 4,tomAlignScaled = 
(int) 5,tomAlignGlyphs = (int) 6,tomAlignSnapGrid = (int) 7,tomSpaces = (int) 
0,tomDots = (int) 1,tomDashes = (int) 2,
+    tomLines = (int) 3,tomThickLines = (int) 4,tomEquals = (int) 5,tomTabBack 
= (int) -3,tomTabNext = (int) -2,tomTabHere = (int) -1,tomListNone = (int) 
0,tomListBullet = (int) 1,
+    tomListNumberAsArabic = (int) 2,tomListNumberAsLCLetter = (int) 
3,tomListNumberAsUCLetter = (int) 4,tomListNumberAsLCRoman = (int) 
5,tomListNumberAsUCRoman = (int) 6,
+    tomListNumberAsSequence = (int) 7,tomListParentheses = (int) 
0x10000,tomListPeriod = (int) 0x20000,tomListPlain = (int) 0x30000,tomCharacter 
= (int) 1,tomWord = (int) 2,
+    tomSentence = (int) 3,tomParagraph = (int) 4,tomLine = (int) 5,tomStory = 
(int) 6,tomScreen = (int) 7,tomSection = (int) 8,tomColumn = (int) 9,tomRow = 
(int) 10,tomWindow = (int) 11,tomCell = (int) 12,
+    tomCharFormat = (int) 13,tomParaFormat = (int) 14,tomTable = (int) 
15,tomObject = (int) 16,tomMatchWord = (int) 2,tomMatchCase = (int) 
4,tomMatchPattern = (int) 8,tomUnknownStory = (int) 0,
+    tomMainTextStory = (int) 1,tomFootnotesStory = (int) 2,tomEndnotesStory = 
(int) 3,tomCommentsStory = (int) 4,tomTextFrameStory = (int) 
5,tomEvenPagesHeaderStory = (int) 6,
+    tomPrimaryHeaderStory = (int) 7,tomEvenPagesFooterStory = (int) 
8,tomPrimaryFooterStory = (int) 9,tomFirstPageHeaderStory = (int) 
10,tomFirstPageFooterStory = (int) 11,
+    tomNoAnimation = (int) 0,tomLasVegasLights = (int) 1,tomBlinkingBackground 
= (int) 2,tomSparkleText = (int) 3,tomMarchingBlackAnts = (int) 
4,tomMarchingRedAnts = (int) 5,
+    tomShimmer = (int) 6,tomWipeDown = (int) 7,tomWipeRight = (int) 
8,tomAnimationMax = (int) 8,tomLowerCase = (int) 0,tomUpperCase = (int) 
1,tomTitleCase = (int) 2,tomSentenceCase = (int) 4,
+    tomToggleCase = (int) 5,tomReadOnly = (int) 0x100,tomShareDenyRead = (int) 
0x200,tomShareDenyWrite = (int) 0x400,tomPasteFile = (int) 0x1000,tomCreateNew 
= (int) 0x10,
+    tomCreateAlways = (int) 0x20,tomOpenExisting = (int) 0x30,tomOpenAlways = 
(int) 0x40,tomTruncateExisting = (int) 0x50,tomRTF = (int) 0x1,tomText = (int) 
0x2,tomHTML = (int) 0x3,
+    tomWordDocument = (int) 0x4,tomBold = (int) 0x80000001,tomItalic = (int) 
0x80000002,tomUnderline = (int) 0x80000004,tomStrikeout = (int) 
0x80000008,tomProtected = (int) 0x80000010,
+    tomLink = (int) 0x80000020,tomSmallCaps = (int) 0x80000040,tomAllCaps = 
(int) 0x80000080,tomHidden = (int) 0x80000100,tomOutline = (int) 
0x80000200,tomShadow = (int) 0x80000400,
+    tomEmboss = (int) 0x80000800,tomImprint = (int) 0x80001000,tomDisabled = 
(int) 0x80002000,tomRevised = (int) 0x80004000,tomNormalCaret = (int) 
0,tomKoreanBlockCaret = (int) 0x1,
+    tomIncludeInset = (int) 0x1,tomIgnoreCurrentFont = (int) 
0,tomMatchFontCharset = (int) 0x1,tomMatchFontSignature = (int) 0x2,tomCharset 
= (int) 0x80000000,tomRE10Mode = (int) 0x1,
+    tomNoIME = (int) 0x80000,tomSelfIME = (int) 0x40000
   } tomConstants;
 
   EXTERN_C const IID LIBID_tom;
diff --git a/mingw-w64-headers/include/wingdi.h 
b/mingw-w64-headers/include/wingdi.h
index 1dd0efa..e0ae2ec 100644
--- a/mingw-w64-headers/include/wingdi.h
+++ b/mingw-w64-headers/include/wingdi.h
@@ -2071,23 +2071,23 @@ extern "C" {
   } DISPLAYCONFIG_RATIONAL;
 
   typedef enum {
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_OTHER = -1,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_HD15 =  0,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_SVIDEO =  1,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_COMPOSITE_VIDEO =  2,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_COMPONENT_VIDEO =  3,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_DVI =  4,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_HDMI =  5,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_LVDS =  6,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_D_JPN  =  8,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_SDI =  9,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_DISPLAYPORT_EXTERNAL = 10,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_DISPLAYPORT_EMBEDDED = 11,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_UDI_EXTERNAL = 12,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_UDI_EMBEDDED = 13,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_SDTVDONGLE = 14,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_INTERNAL = 0x80000000,
-    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_FORCE_UINT32 = 0xFFFFFFFF
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_OTHER = (int) -1,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_HD15 = (int) 0,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_SVIDEO = (int) 1,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_COMPOSITE_VIDEO = (int) 2,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_COMPONENT_VIDEO = (int) 3,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_DVI = (int) 4,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_HDMI = (int) 5,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_LVDS = (int) 6,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_D_JPN  = (int) 8,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_SDI = (int) 9,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_DISPLAYPORT_EXTERNAL = (int) 10,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_DISPLAYPORT_EMBEDDED = (int) 11,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_UDI_EXTERNAL = (int) 12,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_UDI_EMBEDDED = (int) 13,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_SDTVDONGLE = (int) 14,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_INTERNAL = (int) 0x80000000,
+    DISPLAYCONFIG_OUTPUT_TECHNOLOGY_FORCE_UINT32 = (int) 0xFFFFFFFF
   } DISPLAYCONFIG_VIDEO_OUTPUT_TECHNOLOGY;
 
   typedef enum {
-- 
2.4.0

------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to