Print labels (=QName -> qname.ml? )
[tatoo.git] / src / qNameSet.ml
index 4035957..8746b09 100644 (file)
 include FiniteCofinite.Make(Ptset.Make(QName))
 
 module Weak = FiniteCofinite.Weak(Ptset.Weak(QName))
+
+(* BEGIN : Lucca Hirschi *)
+let to_string set =
+  String.concat " "
+    [
+      (match (kind set) with
+       | `Finite -> "F("
+       | `Cofinite  -> "Cof(")
+      ;
+      if is_empty (complement set) then
+       "ΓΈ"
+      else
+       ( String.concat " "
+           (List.map (fun name -> QName.to_string name) (elements (complement set))))
+      ;
+      ")"
+    ]
+(* END : Lucca Hirschi *)