Merge pull request #5714 from alexischr/update_bockbuild
[mono.git] / mono / sgen / sgen-scan-object.h
index 9d1611c22c36a44b7aeace6bc378dee47f033c07..d6da307a734ee4d0cb74039412d0eb0004be9c17 100644 (file)
@@ -1,22 +1,12 @@
-/*
- * sgen-scan-object.h: Generic object scan.
+/**
+ * \file
+ * Generic object scan.
  *
  * Copyright 2001-2003 Ximian, Inc
  * Copyright 2003-2010 Novell, Inc.
  * Copyright (C) 2013 Xamarin Inc
  *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License 2.0 as published by the Free Software Foundation;
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License 2.0 along with this library; if not, write to the Free
- * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Licensed under the MIT license. See LICENSE file in the project root for full license information.
  *
  *
  * Scans one object, using the OBJ_XXX macros.  The start of the
@@ -46,7 +36,7 @@
 {
 #ifndef SCAN_OBJECT_NOVTABLE
 #if defined(SGEN_HEAVY_BINARY_PROTOCOL) && defined(SCAN_OBJECT_PROTOCOL)
-       binary_protocol_scan_begin (start, SGEN_LOAD_VTABLE (start), sgen_safe_object_get_size ((GCObject*)start));
+       binary_protocol_scan_begin ((GCObject*)start, SGEN_LOAD_VTABLE ((GCObject*)start), sgen_safe_object_get_size ((GCObject*)start));
 #endif
 #else
 #if defined(SGEN_HEAVY_BINARY_PROTOCOL) && defined(SCAN_OBJECT_PROTOCOL)
 #endif
        switch (desc & DESC_TYPE_MASK) {
        case DESC_TYPE_RUN_LENGTH:
-#define SCAN OBJ_RUN_LEN_FOREACH_PTR (desc, start)
+#define SCAN OBJ_RUN_LEN_FOREACH_PTR (desc, ((GCObject*)start))
 #ifndef SCAN_OBJECT_NOSCAN
                SCAN;
 #endif
 #undef SCAN
                break;
        case DESC_TYPE_VECTOR:
-#define SCAN OBJ_VECTOR_FOREACH_PTR (desc, start)
+#define SCAN OBJ_VECTOR_FOREACH_PTR (desc, ((GCObject*)start))
 #ifndef SCAN_OBJECT_NOSCAN
                SCAN;
 #endif
 #undef SCAN
                break;
        case DESC_TYPE_BITMAP:
-#define SCAN OBJ_BITMAP_FOREACH_PTR (desc, start)
+#define SCAN OBJ_BITMAP_FOREACH_PTR (desc, ((GCObject*)start))
 #ifndef SCAN_OBJECT_NOSCAN
                SCAN;
 #endif
@@ -77,7 +67,7 @@
                break;
        case DESC_TYPE_COMPLEX:
                /* this is a complex object */
-#define SCAN OBJ_COMPLEX_FOREACH_PTR (desc, start)
+#define SCAN OBJ_COMPLEX_FOREACH_PTR (desc, ((GCObject*)start))
 #ifndef SCAN_OBJECT_NOSCAN
                SCAN;
 #endif
@@ -86,7 +76,7 @@
 #ifndef SCAN_OBJECT_NOVTABLE
        case DESC_TYPE_COMPLEX_ARR:
                /* this is an array of complex structs */
-#define SCAN OBJ_COMPLEX_ARR_FOREACH_PTR (desc, start)
+#define SCAN OBJ_COMPLEX_ARR_FOREACH_PTR (desc, ((GCObject*)start))
 #ifndef SCAN_OBJECT_NOSCAN
                SCAN;
 #endif