Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/common/lib/libprop Eliminate use of C++ keywords and don't n...



details:   https://anonhg.NetBSD.org/src/rev/ffea57c5623b
branches:  trunk
changeset: 802153:ffea57c5623b
user:      matt <matt%NetBSD.org@localhost>
date:      Fri Sep 05 05:19:24 2014 +0000

description:
Eliminate use of C++ keywords and don't nest struct definitions.

diffstat:

 common/lib/libprop/prop_ingest.c |   6 +++---
 common/lib/libprop/prop_number.c |  24 +++++++++++++-----------
 2 files changed, 16 insertions(+), 14 deletions(-)

diffs (68 lines):

diff -r 56c318e2de17 -r ffea57c5623b common/lib/libprop/prop_ingest.c
--- a/common/lib/libprop/prop_ingest.c  Thu Sep 04 19:07:47 2014 +0000
+++ b/common/lib/libprop/prop_ingest.c  Fri Sep 05 05:19:24 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: prop_ingest.c,v 1.4 2012/07/27 09:10:59 pooka Exp $    */
+/*     $NetBSD: prop_ingest.c,v 1.5 2014/09/05 05:19:24 matt Exp $     */
 
 /*-
  * Copyright (c) 2006 The NetBSD Foundation, Inc.
@@ -44,7 +44,7 @@
  *     Allocate and initialize an ingest context.
  */
 prop_ingest_context_t
-prop_ingest_context_alloc(void *private)
+prop_ingest_context_alloc(void *xprivate)
 {
        prop_ingest_context_t ctx;
 
@@ -53,7 +53,7 @@
                ctx->pic_error = PROP_INGEST_ERROR_NO_ERROR;
                ctx->pic_type = PROP_TYPE_UNKNOWN;
                ctx->pic_key = NULL;
-               ctx->pic_private = private;
+               ctx->pic_private = xprivate;
        }
        return (ctx);
 }
diff -r 56c318e2de17 -r ffea57c5623b common/lib/libprop/prop_number.c
--- a/common/lib/libprop/prop_number.c  Thu Sep 04 19:07:47 2014 +0000
+++ b/common/lib/libprop/prop_number.c  Fri Sep 05 05:19:24 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: prop_number.c,v 1.26 2014/03/26 18:12:46 christos Exp $        */
+/*     $NetBSD: prop_number.c,v 1.27 2014/09/05 05:19:24 matt Exp $    */
 
 /*-
  * Copyright (c) 2006 The NetBSD Foundation, Inc.
@@ -43,19 +43,21 @@
 #include <stdlib.h>
 #endif
 
+struct _prop_number_value {
+       union {
+               int64_t  pnu_signed;
+               uint64_t pnu_unsigned;
+       } pnv_un;
+#define        pnv_signed      pnv_un.pnu_signed
+#define        pnv_unsigned    pnv_un.pnu_unsigned
+       unsigned int    pnv_is_unsigned :1,
+                                       :31;
+};
+
 struct _prop_number {
        struct _prop_object     pn_obj;
        struct rb_node          pn_link;
-       struct _prop_number_value {
-               union {
-                       int64_t  pnu_signed;
-                       uint64_t pnu_unsigned;
-               } pnv_un;
-#define        pnv_signed      pnv_un.pnu_signed
-#define        pnv_unsigned    pnv_un.pnu_unsigned
-               unsigned int    pnv_is_unsigned :1,
-                                               :31;
-       } pn_value;
+       struct _prop_number_value pn_value;
 };
 
 _PROP_POOL_INIT(_prop_number_pool, sizeof(struct _prop_number), "propnmbr")



Home | Main Index | Thread Index | Old Index