I wrote a small patch to manipulate cdata section in cduce as follow:
abate@zed.fr:~/Projects/cduce-ocaml-3.10$ledit ./cduce
CDuce version 0.5.0
# cdata_of ;;
- : String -> String = <fun>
# type a = <tag>Cdata ;;
Characters 6-7:
Capture variable not allowed: Cdata
# type a = <tag>String ;;
# let b : a = <tag>(cdata_of "ggg>>" );;
val b : a = <tag> 'ggg>>'
# print_xml b ;;
- : Latin1 = "<tag><![CDATA[ggg>>]]></tag>"
# let [ c ] = map [ b ] with c -> c ;;
val c : a = <tag> ggg>>
# print_xml c;;
- : Latin1 = "<tag><![CDATA[ggg>>]]></tag>"
the code in in the svn repository: http://cduce.org/cgi-bin/viewcvs.cgi/cduce/trunk/?root=svn