#include <string.h>
#include "gvalue.h"
+#include "gtype-private.h"
#include "genums.h"
DEFINE_CAST (uint64_long, v_uint64, glong, v_long);
DEFINE_CAST (uint64_ulong, v_uint64, gulong, v_ulong);
DEFINE_CAST (uint64_int64, v_uint64, gint64, v_int64);
-#ifdef _MSC_VER
-/* work around error C2520: conversion from unsigned __int64 to double
- * not implemented, use signed __int64
- * If it is supported don't miss to g_value_register_transform_func() below
- */
-#pragma message ("Check if cast from uint64 to double is supported with msvc 6.0")
-#else
DEFINE_CAST (uint64_float, v_uint64, gfloat, v_float);
DEFINE_CAST (uint64_double, v_uint64, gdouble, v_double);
-#endif
DEFINE_CAST (float_s8, v_float, gint8, v_int);
DEFINE_CAST (float_u8, v_float, guint8, v_uint);
DEFINE_CAST (float_int, v_float, gint, v_int);
DEFINE_BOOL_CHECK (int_bool, v_int);
DEFINE_BOOL_CHECK (uint_bool, v_uint);
DEFINE_BOOL_CHECK (long_bool, v_long);
-DEFINE_BOOL_CHECK (ulong_bool, v_uint);
+DEFINE_BOOL_CHECK (ulong_bool, v_ulong);
DEFINE_BOOL_CHECK (int64_bool, v_int64);
DEFINE_BOOL_CHECK (uint64_bool, v_uint64);
g_string_append (gstring, flags_value->value_name);
flags_value = g_flags_get_first_value (class, v_flags);
}
- while (flags_value);
+ while (flags_value && v_flags);
if (v_flags)
dest_value->data[0].v_pointer = g_strdup_printf ("%s | %u",
/* registration
*/
void
-g_value_transforms_init (void)
+_g_value_transforms_init (void)
{
/* some transformations are a bit questionable,
* we currently skip those