Anonymous avatar Anonymous committed 3d47927

Rename some things.

Comments (0)

Files changed (8)

     
     let test_error () =
         let factory = parser_factory () in
+        let p = parser_create factory in
         try
-            let p = parser_create factory in
             parse_string p "foo" Final;
             failwith "Expected to raise exception"
         with
         | Error ERROR_SYNTAX ->
-            ()
+            parser_recycle factory p
         | Error code ->
+            parser_recycle factory p;
             failwith (error_string code)
     
     let test_basic1 () =
                 jout#debug "%s" (Buffer.contents b)
             end
         in
+        let p = parser_create factory in
         try
-            let p = parser_create factory in
             assert begin
                 let b = preamble ~p in
                 Printf.bprintf b "//\\//\\//\\//\\//\\//\\ begin\n";
             parser_recycle factory p
         with
         | Error code ->
-            failwith (error_string code)
-        
+            parser_recycle factory p;
+            failwith (error_string code)        
     
     let test () =
         test_error ();
 
     open Cf_parser.Op
     
-    type validator_foo_t = {
+    type validator_foo = {
         v_att_const_: int option;
         v_att_array_: string list option;
         v_content_: string;
 module Attr_map = Cf_rbtree.Map(String)
 
 (*
-type external_entity_ref_t = {
+type external_entity_ref = {
     eer_context: string option;
     eer_base: string option;
     eer_systemId: string;
 }
 *)
 
-type xml_decl_t = {
+type xml_decl = {
     xml_version: string option;
     xml_encoding: string option;
-    xml_standalone: Xml_expat.standalone_t;
+    xml_standalone: Xml_expat.standalone;
 }
 
-type processing_instruction_t = {
+type processing_instruction = {
     pi_target: string;
     pi_data: string;
 }
 
-type position_t = {
+type position = {
     pos_byte_count: nativeint;
     pos_line_number: nativeint;
     pos_column_number: nativeint;
 }
 
-type token_t =
+let get_position parser = {
+    pos_byte_count = Xml_expat.get_current_byte_count parser;
+    pos_line_number = Xml_expat.get_current_line_number parser;
+    pos_column_number = Xml_expat.get_current_column_number parser;
+}
+
+type token =
     | T_character_data of string
     | T_element_start of string * (string * string) list
     | T_element_end of string
-    | T_processing_instruction of processing_instruction_t
+    | T_processing_instruction of processing_instruction
     | T_cdata_start
     | T_cdata_end
     | T_comment of string
     | T_default_text of string
-    | T_error of Xml_expat.error_t
-    | T_xml_decl of xml_decl_t
+    | T_error of Xml_expat.error
+    | T_xml_decl of xml_decl
     | T_end_of_document
 
 let string_option_to_string = function
     | T_end_of_document ->
         "T_end_of_document"
 
-type t = token_t * position_t
+type t = token * position
 
 let rec queue_drain_ q =
     lazy begin
         
         val queue_ = Queue.create ()
         
-        method private push_position =
-            let count = Xml_expat.get_current_byte_count p in
-            let line = Xml_expat.get_current_line_number p in
-            let col = Xml_expat.get_current_column_number p in
-            {
-                pos_byte_count = count;
-                pos_line_number = line;
-                pos_column_number = col;
-            }
+        method position = get_position p
         
         method private h_xml_decl ?version ?encoding standalone =
-            let pos = self#push_position in
+            let pos = self#position in
             let decl = {
                 xml_version = version;
                 xml_encoding = encoding;
             Queue.add (T_xml_decl decl, pos) queue_
         
         method private h_default_text data =
-            let pos = self#push_position in
+            let pos = self#position in
             Queue.add (T_default_text data, pos) queue_
         
         method private h_character_data data =
-            let pos = self#push_position in
+            let pos = self#position in
             Queue.add (T_character_data data, pos) queue_
         
         method private h_element_start tag attrs =
-            let pos = self#push_position in
+            let pos = self#position in
             Queue.add (T_element_start (tag, attrs), pos) queue_
         
         method private h_element_end tag =
-            let pos = self#push_position in
+            let pos = self#position in
             Queue.add (T_element_end tag, pos) queue_
         
         method private h_processing_instruction target data =
-            let pos = self#push_position in
+            let pos = self#position in
             let pi = { pi_target = target; pi_data = data } in
             Queue.add (T_processing_instruction pi, pos) queue_
         
         method private h_cdata_start () =
-            let pos = self#push_position in
+            let pos = self#position in
             Queue.add (T_cdata_start, pos) queue_
         
         method private h_cdata_end () =
-            let pos = self#push_position in
+            let pos = self#position in
             Queue.add (T_cdata_end, pos) queue_
         
         method private h_comment text =
-            let pos = self#push_position in
+            let pos = self#position in
             Queue.add (T_comment text, pos) queue_
 
         method private ingest message final =
                     try
                         Xml_expat.parse_message p message final;
                         if final = Xml_expat.Final then begin
-                            let pos = self#push_position in
+                            let pos = self#position in
                             Queue.add (T_end_of_document, pos) queue_;
                             Xml_expat.parser_recycle factory p
                         end
                     with
                     | Xml_expat.Error xerr ->
-                        let pos = self#push_position in
-                        Queue.add (T_error xerr, pos) queue_
+                        let pos = self#position in
+                        Queue.add (T_error xerr, pos) queue_;
+                        Xml_expat.parser_recycle factory p
                 end;
                 Queue.transfer queue_ q;
                 final_ <- final

xml/xml_event.mli

 
 module Attr_map: Cf_map.T with type Key.t = string
 
-type xml_decl_t = {
+type xml_decl = {
     xml_version: string option;
     xml_encoding: string option;
-    xml_standalone: Xml_expat.standalone_t;
+    xml_standalone: Xml_expat.standalone;
 }
 
-type processing_instruction_t = {
+type processing_instruction = {
     pi_target: string;
     pi_data: string;
 }
 
-type position_t = {
+type position = {
     pos_byte_count: nativeint;
     pos_line_number: nativeint;
     pos_column_number: nativeint;
 }
 
-type token_t =
+val get_position: Xml_expat.parser -> position
+
+type token =
     | T_character_data of string
     | T_element_start of string * (string * string) list
     | T_element_end of string
-    | T_processing_instruction of processing_instruction_t
+    | T_processing_instruction of processing_instruction
     | T_cdata_start
     | T_cdata_end
     | T_comment of string
     | T_default_text of string
-    | T_error of Xml_expat.error_t
-    | T_xml_decl of xml_decl_t
+    | T_error of Xml_expat.error
+    | T_xml_decl of xml_decl
     | T_end_of_document
 
-val token_to_string: token_t -> string
+val token_to_string: token -> string
 
-type t = token_t * position_t
+type t = token * position
 
 class streamer:
-    ?encoding:string -> Xml_expat.parser_factory_t ->
+    ?encoding:string -> Xml_expat.parser_factory ->
     object         
+        method position: position
         method push: Cf_message.t -> t Cf_seq.t
         method final: Cf_message.t -> t Cf_seq.t
     end
 
 val stream:
-    ?encoding:string -> Xml_expat.parser_factory_t -> Cf_message.t ->
+    ?encoding:string -> Xml_expat.parser_factory -> Cf_message.t ->
     t Cf_seq.t
 
-(*--- End of File [ cf_event.mli ] ---*)
+(*--- End of File [ xml_event.mli ] ---*)
 (*---------------------------------------------------------------------------*
   IMPLEMENTATION  xml_expat.ml
 
-  Copyright (c) 2003-2006, James H. Woodyatt
+  Copyright (c) 2003-2007, James H. Woodyatt
   All rights reserved.
 
   Redistribution and use in source and binary forms, with or without
 external version_: unit -> string = "xml_expat_version"
 let version = version_ ()
 
-type numeric_version_t = { major: int; minor: int; micro: int }
+type numeric_version = { major: int; minor: int; micro: int }
 external numeric_version_:
-    unit -> numeric_version_t = "xml_expat_numeric_version"
+    unit -> numeric_version = "xml_expat_numeric_version"
 let numeric_version = numeric_version_ ()
 
-type error_t =
+type parser
+
+type error =
   | ERROR_NO_MEMORY | ERROR_SYNTAX | ERROR_NO_ELEMENTS | ERROR_INVALID_TOKEN
   | ERROR_UNCLOSED_TOKEN | ERROR_PARTIAL_CHAR | ERROR_TAG_MISMATCH
   | ERROR_DUPLICATE_ATTRIBUTE | ERROR_JUNK_AFTER_DOC_ELEMENT
   | ERROR_FEATURE_REQUIRES_XML_DTD | ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING
   | ERROR_UNKNOWN of int
 
-exception Error of error_t
-let _ =
-    Callback.register_exception "Xml_expat.Error" (Error (ERROR_UNKNOWN 0));;
+exception Error of error
 
-external error_string: error_t -> string = "xml_expat_error_string"
+let _ = Callback.register_exception "Xml_expat.Error" (Error (ERROR_UNKNOWN 0))
 
-type parser_t
+external error_string: error -> string = "xml_expat_error_string"
 
-type parser_factory_t = {
+type parser_factory = {
     f_separator_: char option;
-    f_queue_: parser_t Weak.t Queue.t;
+    f_queue_: parser Weak.t Queue.t;
 }
 
 external parser_create_aux:
-    ?encoding:string -> ?separator:char -> unit -> parser_t =
+    ?encoding:string -> ?separator:char -> unit -> parser =
     "xml_expat_parser_create_aux"
 
 external parser_reset:
-    ?encoding:string -> parser_t -> unit = "xml_expat_parser_reset"
+    ?encoding:string -> parser -> unit = "xml_expat_parser_reset"
     
 let parser_factory ?separator () = {
     f_separator_ = separator;
     Queue.add weak factory.f_queue_
 
 external get_current_byte_index:
-    parser_t -> nativeint = "xml_expat_get_current_byte_index"
+    parser -> nativeint = "xml_expat_get_current_byte_index"
 
 external get_current_byte_count:
-    parser_t -> nativeint = "xml_expat_get_current_byte_count"
+    parser -> nativeint = "xml_expat_get_current_byte_count"
 
 external get_current_column_number:
-    parser_t -> nativeint = "xml_expat_get_current_column_number"
+    parser -> nativeint = "xml_expat_get_current_column_number"
 
 external get_current_line_number:
-    parser_t -> nativeint = "xml_expat_get_current_line_number"
+    parser -> nativeint = "xml_expat_get_current_line_number"
 
-type final_t = Push | Final
+type final = Push | Final
 
 external parse_string:
-    parser_t -> string -> final_t -> unit = "xml_expat_parse_string"
+    parser -> string -> final -> unit = "xml_expat_parse_string"
 
 external parse_substring:
-    parser_t -> string -> int -> int -> final_t -> unit =
+    parser -> string -> int -> int -> final -> unit =
     "xml_expat_parse_substring"
 
 external parse_message:
-    parser_t -> (string * int * int) list -> final_t -> unit =
+    parser -> (string * int * int) list -> final -> unit =
     "xml_expat_parse_message"
 
-type standalone_t = SA_no | SA_yes | SA_implied
+type standalone = SA_no | SA_yes | SA_implied
 
 external set_handler_xml_decl:
-    parser_t ->
-    (?version:string -> ?encoding:string -> standalone_t -> unit) option ->
+    parser ->
+    (?version:string -> ?encoding:string -> standalone -> unit) option ->
     unit = "xml_expat_set_handler_xml_decl"
 
 external set_handler_character_data:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_handler_character_data"
 
 external set_handler_element_start:
-    parser_t -> (string -> (string * string) list -> unit) option -> unit =
+    parser -> (string -> (string * string) list -> unit) option -> unit =
     "xml_expat_set_handler_element_start"
 
 external set_handler_element_end:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_handler_element_end"
 
 external set_handler_processing_instruction:
-    parser_t -> (string -> string -> unit) option -> unit =
+    parser -> (string -> string -> unit) option -> unit =
     "xml_expat_set_handler_processing_instruction"
 
 external set_handler_cdata_start:
-    parser_t -> (unit -> unit) option -> unit =
+    parser -> (unit -> unit) option -> unit =
     "xml_expat_set_handler_cdata_start"
 
 external set_handler_cdata_end:
-    parser_t -> (unit -> unit) option -> unit =
+    parser -> (unit -> unit) option -> unit =
     "xml_expat_set_handler_cdata_end"
 
 external set_handler_external_entity_ref:
-    parser_t -> (string option -> string option -> string -> string option ->
+    parser -> (string option -> string option -> string -> string option ->
     unit) option -> unit = "xml_expat_set_handler_external_entity_ref"
 
 external set_handler_comment:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_handler_comment"
 
 external set_handler_default:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_handler_default"
 
 (*--- End of File [ xml_expat.ml ] ---*)

xml/xml_expat.mli

 (*---------------------------------------------------------------------------*
   INTERFACE  xml_expat.mli
 
-  Copyright (c) 2003-2006, James H. Woodyatt
+  Copyright (c) 2003-2007, James H. Woodyatt
   All rights reserved.
 
   Redistribution and use in source and binary forms, with or without
 
 val version: string
 
-type numeric_version_t = { major: int; minor: int; micro: int }
-val numeric_version: numeric_version_t
+type numeric_version = { major: int; minor: int; micro: int }
+val numeric_version: numeric_version
 
-type error_t =
+type parser and parser_factory
+
+type error =
   | ERROR_NO_MEMORY | ERROR_SYNTAX | ERROR_NO_ELEMENTS | ERROR_INVALID_TOKEN
   | ERROR_UNCLOSED_TOKEN | ERROR_PARTIAL_CHAR | ERROR_TAG_MISMATCH
   | ERROR_DUPLICATE_ATTRIBUTE | ERROR_JUNK_AFTER_DOC_ELEMENT
   | ERROR_FEATURE_REQUIRES_XML_DTD | ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING
   | ERROR_UNKNOWN of int
 
-exception Error of error_t
+exception Error of error
 
-val error_string: error_t -> string
+val error_string: error -> string
 
-type parser_t and parser_factory_t
+val parser_factory: ?separator:char -> unit -> parser_factory
+val parser_create: ?encoding:string -> parser_factory -> parser
+val parser_recycle: parser_factory -> parser -> unit
 
-val parser_factory: ?separator:char -> unit -> parser_factory_t
-val parser_create: ?encoding:string -> parser_factory_t -> parser_t
-val parser_recycle: parser_factory_t -> parser_t -> unit
+val get_current_byte_index: parser -> nativeint
+val get_current_byte_count: parser -> nativeint
+val get_current_column_number: parser -> nativeint
+val get_current_line_number: parser -> nativeint
 
-val get_current_byte_index: parser_t -> nativeint
-val get_current_byte_count: parser_t -> nativeint
-val get_current_column_number: parser_t -> nativeint
-val get_current_line_number: parser_t -> nativeint
+type final = Push | Final
 
-type final_t = Push | Final
+val parse_string: parser -> string -> final -> unit
+val parse_substring: parser -> string -> int -> int -> final -> unit
+val parse_message: parser -> Cf_message.t -> final -> unit
 
-val parse_string: parser_t -> string -> final_t -> unit
-val parse_substring: parser_t -> string -> int -> int -> final_t -> unit
-val parse_message: parser_t -> Cf_message.t -> final_t -> unit
-
-type standalone_t = SA_no | SA_yes | SA_implied
+type standalone = SA_no | SA_yes | SA_implied
 
 val set_handler_xml_decl:
-    parser_t ->
-    (?version:string -> ?encoding:string -> standalone_t -> unit) option ->
+    parser ->
+    (?version:string -> ?encoding:string -> standalone -> unit) option ->
     unit
 
 val set_handler_character_data:
-    parser_t -> (string -> unit) option -> unit
+    parser -> (string -> unit) option -> unit
 
 val set_handler_element_start:
-    parser_t -> (string -> (string * string) list -> unit) option -> unit
+    parser -> (string -> (string * string) list -> unit) option -> unit
 
 val set_handler_element_end:
-    parser_t -> (string -> unit) option -> unit
+    parser -> (string -> unit) option -> unit
 
 val set_handler_processing_instruction:
-    parser_t -> (string -> string -> unit) option -> unit
+    parser -> (string -> string -> unit) option -> unit
 
 val set_handler_cdata_start:
-    parser_t -> (unit -> unit) option -> unit
+    parser -> (unit -> unit) option -> unit
 
 val set_handler_cdata_end:
-    parser_t -> (unit -> unit) option -> unit
+    parser -> (unit -> unit) option -> unit
 
 val set_handler_comment:
-    parser_t -> (string -> unit) option -> unit
+    parser -> (string -> unit) option -> unit
 
 val set_handler_default:
-    parser_t -> (string -> unit) option -> unit
+    parser -> (string -> unit) option -> unit
 
 (*--- End of File [ xml_expat.mli ] ---*)

xml/xml_expat_p.c

 };
 
 static const int xml_expat_standalone_array[] = { 0, 1, -1 };
-static const Xml_expat_constant_table_t xml_expat_standalone_table = {
+static const Xml_expat_constant_table_t xml_expat_standaloneable = {
     xml_expat_standalone_array, 3, 0
 };
 
 }
 
 /*---
-  external numeric_version_: unit -> numeric_version_t
+  external numeric_version_: unit -> numeric_version
   ---*/
 CAMLprim value xml_expat_numeric_version(value unit)
 {
 }
 
 /*---
-  external error_string: error_t -> string
+  external error_string: error -> string
   ---*/
 CAMLprim value xml_expat_error_string(value errorVal)
 {
 
 /*---
   external parser_create_aux:
-     ?encoding:string -> ?separator:char -> unit -> parser_t
+     ?encoding:string -> ?separator:char -> unit -> parser
   ---*/
 CAMLprim value xml_expat_parser_create_aux
    (value encodingVal, value separatorVal, value lambdaVal)
 
 
 /*---
-  external parser_reset: ?encoding:string -> parser_t -> unit
+  external parser_reset: ?encoding:string -> parser -> unit
   ---*/
 CAMLprim void xml_expat_parser_reset(value encodingVal, value parserVal)
 {
 
 /*---
   external get_current_byte_index:
-    parser_t -> nativeint = "xml_expat_get_current_byte_index"
+    parser -> nativeint = "xml_expat_get_current_byte_index"
   ---*/
 CAMLprim value xml_expat_get_current_byte_index(value parserVal)
 {
 
 /*---
   external get_current_byte_count:
-    parser_t -> nativeint = "xml_expat_get_current_byte_count"
+    parser -> nativeint = "xml_expat_get_current_byte_count"
   ---*/
 CAMLprim value xml_expat_get_current_byte_count(value parserVal)
 {
 
 /*---
   external get_current_column_number:
-    parser_t -> nativeint = "xml_expat_get_current_column_number"
+    parser -> nativeint = "xml_expat_get_current_column_number"
   ---*/
 CAMLprim value xml_expat_get_current_column_number(value parserVal)
 {
 
 /*---
   external get_current_line_number:
-    parser_t -> nativeint = "xml_expat_get_current_line_number"
+    parser -> nativeint = "xml_expat_get_current_line_number"
   ---*/
 CAMLprim value xml_expat_get_current_line_number(value parserVal)
 {
 
 /*---
   external parse_string:
-    parser_t -> string -> final_t -> unit
+    parser -> string -> final -> unit
   ---*/
 CAMLprim void xml_expat_parse_string
    (value parserVal, value bufferVal, value finalVal)
 
 /*---
   external parse_substring:
-    parser_t -> string -> int -> int -> final_t -> unit
+    parser -> string -> int -> int -> final -> unit
   ---*/
 CAMLprim void xml_expat_parse_substring
    (value parserVal, value bufferVal, value posVal, value lenVal,
 
 /*---
   external parse_message:
-    parser_t -> (string * int * int) list -> final_t -> unit
+    parser -> (string * int * int) list -> final -> unit
   ---*/
 CAMLprim void xml_expat_parse_message
    (value parserVal, value cellVal, value finalVal)
     versionVal = xml_expat_val_string_option(version);
     encodingVal = xml_expat_val_string_option(encoding);
     standaloneVal =
-        xml_expat_get_constant(&xml_expat_standalone_table, standalone);
+        xml_expat_get_constant(&xml_expat_standaloneable, standalone);
     
     handlerVal = Field(*userDataValPtr, Xml_expat_handler_xml_decl);
     assert(Is_block(handlerVal));    
 
 /*---
   external set_handler_xml_decl:
-    parser_t ->
-    (?version:string -> ?encoding:string -> standalone_t -> unit) option ->
+    parser ->
+    (?version:string -> ?encoding:string -> standalone -> unit) option ->
     unit = "xml_expat_set_handler_xml_decl"
   ---*/
 CAMLprim void xml_expat_set_handler_xml_decl
 
 /*---
   external set_handler_character_data:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_handler_character_data"
   ---*/
 CAMLprim void xml_expat_set_handler_character_data
 
 /*---
   external set_handler_element_start:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_handler_element_start"
   ---*/
 CAMLprim void xml_expat_set_handler_element_start
 
 /*---
   external set_handler_element_end:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_handler_element_end"
   ---*/
 CAMLprim void xml_expat_set_handler_element_end
 
 /*---
   external set_handler_processing_instruction:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_handler_processing_instruction"
   ---*/
 CAMLprim void xml_expat_set_handler_processing_instruction
 
 /*---
   external set_handler_cdata_start:
-    parser_t -> (unit -> unit) option -> unit =
+    parser -> (unit -> unit) option -> unit =
     "xml_expat_set_handler_cdata_start"
   ---*/
 CAMLprim void xml_expat_set_handler_cdata_start
 
 /*---
   external set_handler_cdata_end:
-    parser_t -> (unit -> unit) option -> unit =
+    parser -> (unit -> unit) option -> unit =
     "xml_expat_set_handler_cdata_end"
   ---*/
 CAMLprim void xml_expat_set_handler_cdata_end
 
 /*---
   external set_handler_external_entity_ref:
-    parser_t -> (string option -> string option -> string -> string option ->
+    parser -> (string option -> string option -> string -> string option ->
     unit) option -> unit = "xml_expat_set_handler_external_entity_ref"
   ---*/
 CAMLprim void xml_expat_set_handler_external_entity_ref
 
 /*---
   external set_handler_comment:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_handler_comment"
   ---*/
 CAMLprim void xml_expat_set_handler_comment
 
 /*---
   external set_handler_default:
-    parser_t -> (string -> unit) option -> unit =
+    parser -> (string -> unit) option -> unit =
     "xml_expat_set_default_handler"
   ---*/
 CAMLprim void xml_expat_set_handler_default(value parserVal, value handlerVal)

xml/xml_parser.ml

     | Cf_seq.Z -> None
     | Cf_seq.P (event, _) -> raise (Invalid event)
 
-type space_handling_t = S_default | S_preserve
+type space_handling = S_default | S_preserve
 
 (*
 val validated_element:
-    tag:string -> attr:(Xml_event.position_t -> 'a -> string * string -> 'a) ->
-    content:('a -> 'a t) -> ?space:space_handling_t -> 'a -> 'a t
+    tag:string -> attr:(Xml_event.position -> 'a -> string * string -> 'a) ->
+    content:('a -> 'a t) -> ?space:space_handling -> 'a -> 'a t
 *)
 
 let validated_element ~tag ~attr ~content ?(space = S_default) =

xml/xml_parser.mli

 val character_data: string t
 val element_start: (string * (string * string) list) t
 val element_end: string t
-val processing_instruction: Xml_event.processing_instruction_t t
+val processing_instruction: Xml_event.processing_instruction t
 val cdata_start: unit t
 val cdata_end: unit t
 val comment: string t
 val default_text: string t
-val xml_decl: Xml_event.xml_decl_t t
+val xml_decl: Xml_event.xml_decl t
 val end_of_document: unit t
 
 val accumulated_character_data: Cf_message.t t
 
 val invalid: 'a t
 
-type space_handling_t = S_default | S_preserve
+type space_handling = S_default | S_preserve
 
 val validated_element:
-    tag:string -> attr:(Xml_event.position_t -> 'a -> string * string -> 'a) ->
-    content:('a -> 'a t) -> ?space:space_handling_t -> 'a -> 'a t
+    tag:string -> attr:(Xml_event.position -> 'a -> string * string -> 'a) ->
+    content:('a -> 'a t) -> ?space:space_handling -> 'a -> 'a t
 
 val split_attribute_value: (char, string list) Cf_parser.t
 
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.