to_string


Description:

[ CCode ( cname = "g_strdup_printf" , instance_pos = -1 ) ]
public string to_string (string format = "%c")

Converts the value to its equivalent string representation

Example: Char to string:

public static int main (string[] args) {
// Output: ``azAZ09``
print ('a'.to_string ());
print ('z'.to_string ());
print ('A'.to_string ());
print ('Z'.to_string ());
print ('0'.to_string ());
print ('9'.to_string ());

// Output: ````
print (((char) 0).to_string ());

// Output: ``<newline>``
print ('\n'.to_string ());
return 0;
}

valac --pkg glib-2.0 char.to_string.vala