[svn:parrot] r47769 - trunk/src

NotFound at svn.parrot.org NotFound at svn.parrot.org
Tue Jun 22 22:37:46 UTC 2010


Author: NotFound
Date: Tue Jun 22 22:37:44 2010
New Revision: 47769
URL: https://trac.parrot.org/parrot/changeset/47769

Log:
PARROT_const_cast is stricter in C++ than in C, adding casts to make it work

Modified:
   trunk/src/pmc_freeze.c

Modified: trunk/src/pmc_freeze.c
==============================================================================
--- trunk/src/pmc_freeze.c	Tue Jun 22 21:06:39 2010	(r47768)
+++ trunk/src/pmc_freeze.c	Tue Jun 22 22:37:44 2010	(r47769)
@@ -81,7 +81,7 @@
     PMC * const pf_pmc = Parrot_pmc_new(interp, enum_class_UnManagedStruct);
     DECL_CONST_CAST;
 
-    VTABLE_set_pointer(interp, pf_pmc, PARROT_const_cast(void *, pf));
+    VTABLE_set_pointer(interp, pf_pmc, PARROT_const_cast(void *, (const void*)pf));
 
     visitor  = Parrot_pmc_new_init(interp, enum_class_ImageIO, pf_pmc);
     VTABLE_set_pmc(interp, visitor, pmc);
@@ -136,7 +136,7 @@
     PMC *visitor, *pmc_result;
     DECL_CONST_CAST;
 
-    VTABLE_set_pointer(interp, pf_pmc, PARROT_const_cast(void *, pf));
+    VTABLE_set_pointer(interp, pf_pmc, PARROT_const_cast(void *, (const void *)pf));
 
     visitor = Parrot_pmc_new_init(interp, enum_class_ImageIOSize, pf_pmc);
     VTABLE_set_pmc(interp, visitor, pmc);


More information about the parrot-commits mailing list