[commit: ghc] wip/merge: rts: remove old-style field designator extension (#9396) (36e3acd)

git at git.haskell.org git at git.haskell.org
Wed Nov 19 03:38:47 UTC 2014


Repository : ssh://git@git.haskell.org/ghc

On branch  : wip/merge
Link       : http://ghc.haskell.org/trac/ghc/changeset/36e3acdafe29854690659d177c078291bacac9c2/ghc

>---------------------------------------------------------------

commit 36e3acdafe29854690659d177c078291bacac9c2
Author: Austin Seipp <austin at well-typed.com>
Date:   Tue Nov 18 21:21:47 2014 -0600

    rts: remove old-style field designator extension (#9396)
    
    Authored-by: jrp
    
    Signed-off-by: Austin Seipp <austin at well-typed.com>


>---------------------------------------------------------------

36e3acdafe29854690659d177c078291bacac9c2
 includes/rts/prof/CCS.h | 48 ++++++++++++++++++++++++------------------------
 rts/RetainerSet.c       | 10 +++++-----
 2 files changed, 29 insertions(+), 29 deletions(-)

diff --git a/includes/rts/prof/CCS.h b/includes/rts/prof/CCS.h
index 85b03f3..74f18b8 100644
--- a/includes/rts/prof/CCS.h
+++ b/includes/rts/prof/CCS.h
@@ -210,32 +210,32 @@ extern CostCentreStack * RTS_VAR(CCS_LIST);         // registered CCS list
  * Declaring Cost Centres & Cost Centre Stacks.
  * -------------------------------------------------------------------------- */
 
-# define CC_DECLARE(cc_ident,name,mod,loc,caf,is_local) \
-     is_local CostCentre cc_ident[1]                    \
-       = {{ ccID       : 0,                             \
-            label      : name,                          \
-            module     : mod,                           \
-            srcloc     : loc,                           \
-            time_ticks : 0,                             \
-            mem_alloc  : 0,                             \
-            link       : 0,                             \
-            is_caf     : caf                            \
+# define CC_DECLARE(cc_ident,name,mod,loc,caf,is_local)  \
+     is_local CostCentre cc_ident[1]                     \
+       = {{ .ccID       = 0,                             \
+            .label      = name,                          \
+            .module     = mod,                           \
+            .srcloc     = loc,                           \
+            .time_ticks = 0,                             \
+            .mem_alloc  = 0,                             \
+            .link       = 0,                             \
+            .is_caf     = caf                            \
          }};
 
-# define CCS_DECLARE(ccs_ident,cc_ident,is_local)       \
-     is_local CostCentreStack ccs_ident[1]              \
-       = {{ ccsID               : 0,                    \
-            cc                  : cc_ident,             \
-            prevStack           : NULL,                 \
-            indexTable          : NULL,                 \
-            root                : NULL,                 \
-            depth               : 0,                    \
-            selected            : 0,                    \
-            scc_count           : 0,                    \
-            time_ticks          : 0,                    \
-            mem_alloc           : 0,                    \
-            inherited_ticks     : 0,                    \
-            inherited_alloc     : 0                     \
+# define CCS_DECLARE(ccs_ident,cc_ident,is_local)        \
+     is_local CostCentreStack ccs_ident[1]               \
+       = {{ .ccsID               = 0,                    \
+            .cc                  = cc_ident,             \
+            .prevStack           = NULL,                 \
+            .indexTable          = NULL,                 \
+            .root                = NULL,                 \
+            .depth               = 0,                    \
+            .selected            = 0,                    \
+            .scc_count           = 0,                    \
+            .time_ticks          = 0,                    \
+            .mem_alloc           = 0,                    \
+            .inherited_ticks     = 0,                    \
+            .inherited_alloc     = 0                     \
        }};
 
 /* -----------------------------------------------------------------------------
diff --git a/rts/RetainerSet.c b/rts/RetainerSet.c
index 1905866..234532a 100644
--- a/rts/RetainerSet.c
+++ b/rts/RetainerSet.c
@@ -40,11 +40,11 @@ static int nextId;              // id of next retainer set
  * from growing too large.
  * -------------------------------------------------------------------------- */
 RetainerSet rs_MANY = {
-    num : 0,
-    hashKey : 0,
-    link : NULL,
-    id : 1,
-    element : {}
+    .num     = 0,
+    .hashKey = 0,
+    .link    = NULL,
+    .id      = 1,
+    .element = {}
 };
 
 /* -----------------------------------------------------------------------------



More information about the ghc-commits mailing list