Expose text arrays the same way as regular arrays

Store the content of text arrays both in the "elems" array and in a
string. While it does duplicate the data, this makes it possible to
access arrays containing UTF-8 or ASCII data the same way as regular
arrays.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>