}
-#if 0
/************************************************************************/
/* utf8 */
/* insert BLACK HEART SUIT to ensure UTF-8 doesn't get mangled */
*/
G_CONST_RETURN char *test_utf8_const_return (void)
{
+ /* transfer mode none */
return utf8_const;
}
*/
char *test_utf8_nonconst_return (void)
{
+ /* transfer mode full */
return g_strdup (utf8_nonconst);
}
void test_utf8_nonconst_in (char *in)
{
+ /* transfer mode full */
g_assert (strcmp (in, utf8_nonconst) == 0);
+ g_free(in);
}
void test_utf8_const_in (const char *in)
{
+ /* transfer mode none */
g_assert (strcmp (in, utf8_const) == 0);
}
+/**
+ * test_utf8_out:
+ * @out: (out) (transfer full):
+ */
void test_utf8_out (char **out)
{
+ /* out parameter, transfer mode full */
*out = g_strdup (utf8_nonconst);
}
+/**
+ * test_utf8_inout:
+ * @inout: (inout):
+ */
void test_utf8_inout (char **inout)
{
+ /* inout parameter, transfer mode full */
g_assert (strcmp (*inout, utf8_const) == 0);
- *input = g_strdup (utf8_nonconst);
+ g_free(*inout);
+ *inout = g_strdup (utf8_nonconst);
}
-#endif
/**
* test_filename_return:
gdouble test_double (gdouble in);
time_t test_timet (time_t in);
GType test_gtype (GType in);
-#if 0
+
/* utf8 */
G_CONST_RETURN char *test_utf8_const_return (void);
char *test_utf8_nonconst_return (void);
void test_utf8_const_in (const char *in);
void test_utf8_out (char **out);
void test_utf8_inout (char **inout);
-#endif
GSList *test_filename_return (void);
+
/* non-basic-types */
/* array */
gboolean test_strv_in (char **arr);