Merge pull request #5714 from alexischr/update_bockbuild
[mono.git] / mono / mini / cfgdump.c
index fb4f06fb9bed0356940ade628058ec623d250af1..36c9ffac877b0a822328e5f09df25603dfddc2a4 100644 (file)
@@ -1,4 +1,5 @@
-/*
+/**
+ * \file
  * Copyright (C) 2016 Xamarin Inc
  * Licensed under the MIT license. See LICENSE file in the project root for full license information.
  */
@@ -21,7 +22,6 @@
 #include <unistd.h>
 #include <errno.h>
 #include <arpa/inet.h>
-#include <errno.h>
 
 #if 0
 #define CFG_DEBUG
@@ -438,15 +438,15 @@ constant_pool_hash (ConstantPoolEntry *entry)
                        return instruction_hash ((MonoInst *) entry->data);
                case PT_SIGNATURE: {
                        MonoMethodSignature *sig = (MonoMethodSignature *) entry->data;
-                       guint ret = (guint) sig->ret;
+                       guint ret = GPOINTER_TO_UINT (sig->ret);
                        for (int i = 0; i < sig->param_count; i++) {
-                               ret ^= (guint) sig->params [i] << (i + 1);
+                               ret ^= GPOINTER_TO_UINT (sig->params [i]) << (i + 1);
                        }
                        return ret;
                }
                case PT_INPUTTYPE: // TODO: singleton.
                case PT_ENUMKLASS:
-                       return (guint) entry->data;
+                       return GPOINTER_TO_UINT (entry->data);
        }
        g_assert (FALSE);
        return FALSE;