]> rtime.felk.cvut.cz Git - l4.git/blob - l4/pkg/ocaml/ocaml/contrib/camlp4/boot/Camlp4.ml
Update
[l4.git] / l4 / pkg / ocaml / ocaml / contrib / camlp4 / boot / Camlp4.ml
1 module Debug :
2   sig
3     (****************************************************************************)
4     (*                                                                          *)
5     (*                              Objective Caml                              *)
6     (*                                                                          *)
7     (*                            INRIA Rocquencourt                            *)
8     (*                                                                          *)
9     (*  Copyright  2006   Institut National de Recherche  en  Informatique et   *)
10     (*  en Automatique.  All rights reserved.  This file is distributed under   *)
11     (*  the terms of the GNU Library General Public License, with the special   *)
12     (*  exception on linking described in LICENSE at the top of the Objective   *)
13     (*  Caml source tree.                                                       *)
14     (*                                                                          *)
15     (****************************************************************************)
16     (* Authors:
17  * - Daniel de Rauglaudre: initial version
18  * - Nicolas Pouillard: refactoring
19  *)
20     (* camlp4r *)
21     type section = string
22     
23     val mode : section -> bool
24       
25     val printf : section -> ('a, Format.formatter, unit) format -> 'a
26       
27   end =
28   struct
29     (****************************************************************************)
30     (*                                                                          *)
31     (*                              Objective Caml                              *)
32     (*                                                                          *)
33     (*                            INRIA Rocquencourt                            *)
34     (*                                                                          *)
35     (*  Copyright  2006   Institut National de Recherche  en  Informatique et   *)
36     (*  en Automatique.  All rights reserved.  This file is distributed under   *)
37     (*  the terms of the GNU Library General Public License, with the special   *)
38     (*  exception on linking described in LICENSE at the top of the Objective   *)
39     (*  Caml source tree.                                                       *)
40     (*                                                                          *)
41     (****************************************************************************)
42     (* Authors:
43  * - Daniel de Rauglaudre: initial version
44  * - Nicolas Pouillard: refactoring
45  *)
46     (* camlp4r *)
47     open Format
48       
49     module Debug = struct let mode _ = false
50                              end
51       
52     type section = string
53     
54     let out_channel =
55       try
56         let f = Sys.getenv "CAMLP4_DEBUG_FILE"
57         in
58           open_out_gen [ Open_wronly; Open_creat; Open_append; Open_text ]
59             0o666 f
60       with | Not_found -> stderr
61       
62     module StringSet = Set.Make(String)
63       
64     let mode =
65       try
66         let str = Sys.getenv "CAMLP4_DEBUG" in
67         let rec loop acc i =
68           try
69             let pos = String.index_from str i ':'
70             in
71               loop (StringSet.add (String.sub str i (pos - i)) acc) (pos + 1)
72           with
73           | Not_found ->
74               StringSet.add (String.sub str i ((String.length str) - i)) acc in
75         let sections = loop StringSet.empty 0
76         in
77           if StringSet.mem "*" sections
78           then (fun _ -> true)
79           else (fun x -> StringSet.mem x sections)
80       with | Not_found -> (fun _ -> false)
81       
82     let formatter =
83       let header = "camlp4-debug: " in
84       let normal s =
85         let rec self from accu =
86           try
87             let i = String.index_from s from '\n'
88             in self (i + 1) ((String.sub s from ((i - from) + 1)) :: accu)
89           with
90           | Not_found ->
91               (String.sub s from ((String.length s) - from)) :: accu
92         in String.concat header (List.rev (self 0 [])) in
93       let after_new_line str = header ^ (normal str) in
94       let f = ref after_new_line in
95       let output str chr =
96         (output_string out_channel (!f str);
97          output_char out_channel chr;
98          f := if chr = '\n' then after_new_line else normal)
99       in
100         make_formatter
101           (fun buf pos len ->
102              let p = pred len in output (String.sub buf pos p) buf.[pos + p])
103           (fun () -> flush out_channel)
104       
105     let printf section fmt = fprintf formatter ("%s: " ^^ fmt) section
106       
107   end
108   
109 module Options :
110   sig
111     (****************************************************************************)
112     (*                                                                          *)
113     (*                              Objective Caml                              *)
114     (*                                                                          *)
115     (*                            INRIA Rocquencourt                            *)
116     (*                                                                          *)
117     (*  Copyright  2006   Institut National de Recherche  en  Informatique et   *)
118     (*  en Automatique.  All rights reserved.  This file is distributed under   *)
119     (*  the terms of the GNU Library General Public License, with the special   *)
120     (*  exception on linking described in LICENSE at the top of the Objective   *)
121     (*  Caml source tree.                                                       *)
122     (*                                                                          *)
123     (****************************************************************************)
124     (* Authors:
125  * - Daniel de Rauglaudre: initial version
126  * - Nicolas Pouillard: refactoring
127  *)
128     type spec_list = (string * Arg.spec * string) list
129     
130     val init : spec_list -> unit
131       
132     val add : string -> Arg.spec -> string -> unit
133       
134     (** Add an option to the command line options. *)
135     val print_usage_list : spec_list -> unit
136       
137     val ext_spec_list : unit -> spec_list
138       
139     val parse : (string -> unit) -> string array -> string list
140       
141   end =
142   struct
143     (****************************************************************************)
144     (*                                                                          *)
145     (*                              Objective Caml                              *)
146     (*                                                                          *)
147     (*                            INRIA Rocquencourt                            *)
148     (*                                                                          *)
149     (*  Copyright  2006   Institut National de Recherche  en  Informatique et   *)
150     (*  en Automatique.  All rights reserved.  This file is distributed under   *)
151     (*  the terms of the GNU Library General Public License, with the special   *)
152     (*  exception on linking described in LICENSE at the top of the Objective   *)
153     (*  Caml source tree.                                                       *)
154     (*                                                                          *)
155     (****************************************************************************)
156     (* Authors:
157  * - Daniel de Rauglaudre: initial version
158  * - Nicolas Pouillard: refactoring
159  *)
160     type spec_list = (string * Arg.spec * string) list
161     
162     open Format
163       
164     let rec action_arg s sl =
165       function
166       | Arg.Unit f -> if s = "" then (f (); Some sl) else None
167       | Arg.Bool f ->
168           if s = ""
169           then
170             (match sl with
171              | s :: sl ->
172                  (try (f (bool_of_string s); Some sl)
173                   with | Invalid_argument "bool_of_string" -> None)
174              | [] -> None)
175           else
176             (try (f (bool_of_string s); Some sl)
177              with | Invalid_argument "bool_of_string" -> None)
178       | Arg.Set r -> if s = "" then (r := true; Some sl) else None
179       | Arg.Clear r -> if s = "" then (r := false; Some sl) else None
180       | Arg.Rest f -> (List.iter f (s :: sl); Some [])
181       | Arg.String f ->
182           if s = ""
183           then (match sl with | s :: sl -> (f s; Some sl) | [] -> None)
184           else (f s; Some sl)
185       | Arg.Set_string r ->
186           if s = ""
187           then (match sl with | s :: sl -> (r := s; Some sl) | [] -> None)
188           else (r := s; Some sl)
189       | Arg.Int f ->
190           if s = ""
191           then
192             (match sl with
193              | s :: sl ->
194                  (try (f (int_of_string s); Some sl)
195                   with | Failure "int_of_string" -> None)
196              | [] -> None)
197           else
198             (try (f (int_of_string s); Some sl)
199              with | Failure "int_of_string" -> None)
200       | Arg.Set_int r ->
201           if s = ""
202           then
203             (match sl with
204              | s :: sl ->
205                  (try (r := int_of_string s; Some sl)
206                   with | Failure "int_of_string" -> None)
207              | [] -> None)
208           else
209             (try (r := int_of_string s; Some sl)
210              with | Failure "int_of_string" -> None)
211       | Arg.Float f ->
212           if s = ""
213           then
214             (match sl with
215              | s :: sl -> (f (float_of_string s); Some sl)
216              | [] -> None)
217           else (f (float_of_string s); Some sl)
218       | Arg.Set_float r ->
219           if s = ""
220           then
221             (match sl with
222              | s :: sl -> (r := float_of_string s; Some sl)
223              | [] -> None)
224           else (r := float_of_string s; Some sl)
225       | Arg.Tuple specs ->
226           let rec action_args s sl =
227             (function
228              | [] -> Some sl
229              | spec :: spec_list ->
230                  (match action_arg s sl spec with
231                   | None -> action_args "" [] spec_list
232                   | Some (s :: sl) -> action_args s sl spec_list
233                   | Some sl -> action_args "" sl spec_list))
234           in action_args s sl specs
235       | Arg.Symbol (syms, f) ->
236           (match if s = "" then sl else s :: sl with
237            | s :: sl when List.mem s syms -> (f s; Some sl)
238            | _ -> None)
239       
240     let common_start s1 s2 =
241       let rec loop i =
242         if (i == (String.length s1)) || (i == (String.length s2))
243         then i
244         else if s1.[i] == s2.[i] then loop (i + 1) else i
245       in loop 0
246       
247     let parse_arg fold s sl =
248       fold
249         (fun (name, action, _) acu ->
250            let i = common_start s name
251            in
252              if i == (String.length name)
253              then
254                (try
255                   action_arg (String.sub s i ((String.length s) - i)) sl
256                     action
257                 with | Arg.Bad _ -> acu)
258              else acu)
259         None
260       
261     let rec parse_aux fold anon_fun =
262       function
263       | [] -> []
264       | s :: sl ->
265           if ((String.length s) > 1) && (s.[0] = '-')
266           then
267             (match parse_arg fold s sl with
268              | Some sl -> parse_aux fold anon_fun sl
269              | None -> s :: (parse_aux fold anon_fun sl))
270           else ((anon_fun s : unit); parse_aux fold anon_fun sl)
271       
272     let align_doc key s =
273       let s =
274         let rec loop i =
275           if i = (String.length s)
276           then ""
277           else
278             if s.[i] = ' '
279             then loop (i + 1)
280             else String.sub s i ((String.length s) - i)
281         in loop 0 in
282       let (p, s) =
283         if (String.length s) > 0
284         then
285           if s.[0] = '<'
286           then
287             (let rec loop i =
288                if i = (String.length s)
289                then ("", s)
290                else
291                  if s.[i] <> '>'
292                  then loop (i + 1)
293                  else
294                    (let p = String.sub s 0 (i + 1) in
295                     let rec loop i =
296                       if i >= (String.length s)
297                       then (p, "")
298                       else
299                         if s.[i] = ' '
300                         then loop (i + 1)
301                         else (p, (String.sub s i ((String.length s) - i)))
302                     in loop (i + 1))
303              in loop 0)
304           else ("", s)
305         else ("", "") in
306       let tab =
307         String.make (max 1 ((16 - (String.length key)) - (String.length p)))
308           ' '
309       in p ^ (tab ^ s)
310       
311     let make_symlist l =
312       match l with
313       | [] -> "<none>"
314       | h :: t ->
315           (List.fold_left (fun x y -> x ^ ("|" ^ y)) ("{" ^ h) t) ^ "}"
316       
317     let print_usage_list l =
318       List.iter
319         (fun (key, spec, doc) ->
320            match spec with
321            | Arg.Symbol (symbs, _) ->
322                let s = make_symlist symbs in
323                let synt = key ^ (" " ^ s)
324                in eprintf "  %s %s\n" synt (align_doc synt doc)
325            | _ -> eprintf "  %s %s\n" key (align_doc key doc))
326         l
327       
328     let remaining_args argv =
329       let rec loop l i =
330         if i == (Array.length argv) then l else loop (argv.(i) :: l) (i + 1)
331       in List.rev (loop [] (!Arg.current + 1))
332       
333     let init_spec_list = ref []
334       
335     let ext_spec_list = ref []
336       
337     let init spec_list = init_spec_list := spec_list
338       
339     let add name spec descr =
340       ext_spec_list := (name, spec, descr) :: !ext_spec_list
341       
342     let fold f init =
343       let spec_list = !init_spec_list @ !ext_spec_list in
344       let specs = Sort.list (fun (k1, _, _) (k2, _, _) -> k1 >= k2) spec_list
345       in List.fold_right f specs init
346       
347     let parse anon_fun argv =
348       let remaining_args = remaining_args argv
349       in parse_aux fold anon_fun remaining_args
350       
351     let ext_spec_list () = !ext_spec_list
352       
353   end
354   
355 module Sig =
356   struct
357     (* camlp4r *)
358     (****************************************************************************)
359     (*                                                                          *)
360     (*                              Objective Caml                              *)
361     (*                                                                          *)
362     (*                            INRIA Rocquencourt                            *)
363     (*                                                                          *)
364     (*  Copyright  2006   Institut National de Recherche  en  Informatique et   *)
365     (*  en Automatique.  All rights reserved.  This file is distributed under   *)
366     (*  the terms of the GNU Library General Public License, with the special   *)
367     (*  exception on linking described in LICENSE at the top of the Objective   *)
368     (*  Caml source tree.                                                       *)
369     (*                                                                          *)
370     (****************************************************************************)
371     (* Authors:
372  * - Daniel de Rauglaudre: initial version
373  * - Nicolas Pouillard: refactoring
374  *)
375     (** Camlp4 signature repository *)
376     (** {6 Basic signatures} *)
377     (** Signature with just a type. *)
378     module type Type = sig type t
379                             end
380       
381     (** Signature for errors modules, an Error modules can be registred with
382     the {!ErrorHandler.Register} functor in order to be well printed. *)
383     module type Error =
384       sig
385         type t
386         
387         exception E of t
388           
389         val to_string : t -> string
390           
391         val print : Format.formatter -> t -> unit
392           
393       end
394       
395     (** A signature for extensions identifiers. *)
396     module type Id =
397       sig
398         (** The name of the extension, typically the module name. *)
399         val name : string
400           
401         (** The version of the extension, typically $ Id$ with a versionning system. *)
402         val version : string
403           
404       end
405       
406     (** A signature for warnings abstract from locations. *)
407     module Warning (Loc : Type) =
408       struct
409         module type S =
410           sig
411             type warning = Loc.t -> string -> unit
412             
413             val default_warning : warning
414               
415             val current_warning : warning ref
416               
417             val print_warning : warning
418               
419           end
420           
421       end
422       
423     (** {6 Advanced signatures} *)
424     (** A signature for locations. *)
425     module type Loc =
426       sig
427         type t
428         
429         (** Return a start location for the given file name.
430       This location starts at the begining of the file. *)
431         val mk : string -> t
432           
433         (** The [ghost] location can be used when no location
434       information is available. *)
435         val ghost : t
436           
437         (** {6 Conversion functions} *)
438         (** Return a location where both positions are set the given position. *)
439         val of_lexing_position : Lexing.position -> t
440           
441         (** Return an OCaml location. *)
442         val to_ocaml_location : t -> Camlp4_import.Location.t
443           
444         (** Return a location from an OCaml location. *)
445         val of_ocaml_location : Camlp4_import.Location.t -> t
446           
447         (** Return a location from ocamllex buffer. *)
448         val of_lexbuf : Lexing.lexbuf -> t
449           
450         (** Return a location from [(file_name, start_line, start_bol, start_off,
451       stop_line,  stop_bol,  stop_off, ghost)]. *)
452         val of_tuple :
453           (string * int * int * int * int * int * int * bool) -> t
454           
455         (** Return [(file_name, start_line, start_bol, start_off,
456       stop_line,  stop_bol,  stop_off, ghost)]. *)
457         val to_tuple :
458           t -> (string * int * int * int * int * int * int * bool)
459           
460         (** [merge loc1 loc2] Return a location that starts at [loc1] and end at [loc2]. *)
461         val merge : t -> t -> t
462           
463         (** The stop pos becomes equal to the start pos. *)
464         val join : t -> t
465           
466         (** [move selector n loc]
467       Return the location where positions are moved.
468       Affected positions are chosen with [selector].
469       Returned positions have their character offset plus [n]. *)
470         val move : [ | `start | `stop | `both ] -> int -> t -> t
471           
472         (** [shift n loc] Return the location where the new start position is the old
473       stop position, and where the new stop position character offset is the
474       old one plus [n]. *)
475         val shift : int -> t -> t
476           
477         (** [move_line n loc] Return the location with the old line count plus [n].
478       The "begin of line" of both positions become the current offset. *)
479         val move_line : int -> t -> t
480           
481         (** {6 Accessors} *)
482         (** Return the file name *)
483         val file_name : t -> string
484           
485         (** Return the line number of the begining of this location. *)
486         val start_line : t -> int
487           
488         (** Return the line number of the ending of this location. *)
489         val stop_line : t -> int
490           
491         (** Returns the number of characters from the begining of the file
492       to the begining of the line of location's begining. *)
493         val start_bol : t -> int
494           
495         (** Returns the number of characters from the begining of the file
496       to the begining of the line of location's ending. *)
497         val stop_bol : t -> int
498           
499         (** Returns the number of characters from the begining of the file
500       of the begining of this location. *)
501         val start_off : t -> int
502           
503         (** Return the number of characters from the begining of the file
504       of the ending of this location. *)
505         val stop_off : t -> int
506           
507         (** Return the start position as a Lexing.position. *)
508         val start_pos : t -> Lexing.position
509           
510         (** Return the stop position as a Lexing.position. *)
511         val stop_pos : t -> Lexing.position
512           
513         (** Generally, return true if this location does not come
514       from an input stream. *)
515         val is_ghost : t -> bool
516           
517         (** Return the associated ghost location. *)
518         val ghostify : t -> t
519           
520         (** Return the location with the give file name *)
521         val set_file_name : string -> t -> t
522           
523         (** [strictly_before loc1 loc2] True if the stop position of [loc1] is
524       strictly_before the start position of [loc2]. *)
525         val strictly_before : t -> t -> bool
526           
527         (** Return the location with an absolute file name. *)
528         val make_absolute : t -> t
529           
530         (** Print the location into the formatter in a format suitable for error
531       reporting. *)
532         val print : Format.formatter -> t -> unit
533           
534         (** Print the location in a short format useful for debugging. *)
535         val dump : Format.formatter -> t -> unit
536           
537         (** Same as {!print} but return a string instead of printting it. *)
538         val to_string : t -> string
539           
540         (** [Exc_located loc e] is an encapsulation of the exception [e] with
541       the input location [loc]. To be used in quotation expanders
542       and in grammars to specify some input location for an error.
543       Do not raise this exception directly: rather use the following
544       function [Loc.raise]. *)
545         exception Exc_located of t * exn
546           
547         (** [raise loc e], if [e] is already an [Exc_located] exception,
548       re-raise it, else raise the exception [Exc_located loc e]. *)
549         val raise : t -> exn -> 'a
550           
551         (** The name of the location variable used in grammars and in
552       the predefined quotations for OCaml syntax trees. Default: [_loc]. *)
553         val name : string ref
554           
555       end
556       
557     (** Abstract syntax tree minimal signature.
558     Types of this signature are abstract.
559     See the {!Camlp4Ast} signature for a concrete definition. *)
560     module type Ast =
561       sig
562         (** {6 Syntactic categories as abstract types} *)
563         type loc
564         
565         type meta_bool
566         
567         type 'a meta_option
568         
569         type 'a meta_list
570         
571         type ctyp
572         
573         type patt
574         
575         type expr
576         
577         type module_type
578         
579         type sig_item
580         
581         type with_constr
582         
583         type module_expr
584         
585         type str_item
586         
587         type class_type
588         
589         type class_sig_item
590         
591         type class_expr
592         
593         type class_str_item
594         
595         type match_case
596         
597         type ident
598         
599         type binding
600         
601         type rec_binding
602         
603         type module_binding
604         
605         (** {6 Location accessors} *)
606         val loc_of_ctyp : ctyp -> loc
607           
608         val loc_of_patt : patt -> loc
609           
610         val loc_of_expr : expr -> loc
611           
612         val loc_of_module_type : module_type -> loc
613           
614         val loc_of_module_expr : module_expr -> loc
615           
616         val loc_of_sig_item : sig_item -> loc
617           
618         val loc_of_str_item : str_item -> loc
619           
620         val loc_of_class_type : class_type -> loc
621           
622         val loc_of_class_sig_item : class_sig_item -> loc
623           
624         val loc_of_class_expr : class_expr -> loc
625           
626         val loc_of_class_str_item : class_str_item -> loc
627           
628         val loc_of_with_constr : with_constr -> loc
629           
630         val loc_of_binding : binding -> loc
631           
632         val loc_of_rec_binding : rec_binding -> loc
633           
634         val loc_of_module_binding : module_binding -> loc
635           
636         val loc_of_match_case : match_case -> loc
637           
638         val loc_of_ident : ident -> loc
639           
640         (** {6 Traversals} *)
641         (** This class is the base class for map traversal on the Ast.
642       To make a custom traversal class one just extend it like that:
643       
644       This example swap pairs expression contents:
645       open Camlp4.PreCast;
646       [class swap = object
647         inherit Ast.map as super;
648         method expr e =
649           match super#expr e with
650           \[ <:expr\@_loc< ($e1$, $e2$) >> -> <:expr< ($e2$, $e1$) >>
651           | e -> e \];
652       end;
653       value _loc = Loc.ghost;
654       value map = (new swap)#expr;
655       assert (map <:expr< fun x -> (x, 42) >> = <:expr< fun x -> (42, x) >>);]
656   *)
657         class map :
658           object ('self_type)
659             method string : string -> string
660               
661             method list :
662               'a 'b. ('self_type -> 'a -> 'b) -> 'a list -> 'b list
663               
664             method meta_bool : meta_bool -> meta_bool
665               
666             method meta_option :
667               'a 'b.
668                 ('self_type -> 'a -> 'b) -> 'a meta_option -> 'b meta_option
669               
670             method meta_list :
671               'a 'b. ('self_type -> 'a -> 'b) -> 'a meta_list -> 'b meta_list
672               
673             method loc : loc -> loc
674               
675             method expr : expr -> expr
676               
677             method patt : patt -> patt
678               
679             method ctyp : ctyp -> ctyp
680               
681             method str_item : str_item -> str_item
682               
683             method sig_item : sig_item -> sig_item
684               
685             method module_expr : module_expr -> module_expr
686               
687             method module_type : module_type -> module_type
688               
689             method class_expr : class_expr -> class_expr
690               
691             method class_type : class_type -> class_type
692               
693             method class_sig_item : class_sig_item -> class_sig_item
694               
695             method class_str_item : class_str_item -> class_str_item
696               
697             method with_constr : with_constr -> with_constr
698               
699             method binding : binding -> binding
700               
701             method rec_binding : rec_binding -> rec_binding
702               
703             method module_binding : module_binding -> module_binding
704               
705             method match_case : match_case -> match_case
706               
707             method ident : ident -> ident
708               
709             method unknown : 'a. 'a -> 'a
710               
711           end
712           
713         (** Fold style traversal *)
714         class fold :
715           object ('self_type)
716             method string : string -> 'self_type
717               
718             method list :
719               'a. ('self_type -> 'a -> 'self_type) -> 'a list -> 'self_type
720               
721             method meta_bool : meta_bool -> 'self_type
722               
723             method meta_option :
724               'a.
725                 ('self_type -> 'a -> 'self_type) ->
726                   'a meta_option -> 'self_type
727               
728             method meta_list :
729               'a.
730                 ('self_type -> 'a -> 'self_type) ->
731                   'a meta_list -> 'self_type
732               
733             method loc : loc -> 'self_type
734               
735             method expr : expr -> 'self_type
736               
737             method patt : patt -> 'self_type
738               
739             method ctyp : ctyp -> 'self_type
740               
741             method str_item : str_item -> 'self_type
742               
743             method sig_item : sig_item -> 'self_type
744               
745             method module_expr : module_expr -> 'self_type
746               
747             method module_type : module_type -> 'self_type
748               
749             method class_expr : class_expr -> 'self_type
750               
751             method class_type : class_type -> 'self_type
752               
753             method class_sig_item : class_sig_item -> 'self_type
754               
755             method class_str_item : class_str_item -> 'self_type
756               
757             method with_constr : with_constr -> 'self_type
758               
759             method binding : binding -> 'self_type
760               
761             method rec_binding : rec_binding -> 'self_type
762               
763             method module_binding : module_binding -> 'self_type
764               
765             method match_case : match_case -> 'self_type
766               
767             method ident : ident -> 'self_type
768               
769             method unknown : 'a. 'a -> 'self_type
770               
771           end
772           
773       end
774       
775     (** Signature for OCaml syntax trees. *)
776     (*
777     This signature is an extension of {!Ast}
778     It provides:
779       - Types for all kinds of structure.
780       - Map: A base class for map traversals.
781       - Map classes and functions for common kinds.
782
783     == Core language ==
784     ctyp               :: Representaion of types
785     patt               :: The type of patterns
786     expr               :: The type of expressions
787     match_case         :: The type of cases for match/function/try constructions
788     ident              :: The type of identifiers (including path like Foo(X).Bar.y)
789     binding            :: The type of let bindings
790     rec_binding        :: The type of record definitions
791
792     == Modules ==
793     module_type        :: The type of module types
794     sig_item           :: The type of signature items
795     str_item           :: The type of structure items
796     module_expr        :: The type of module expressions
797     module_binding     :: The type of recursive module definitions
798     with_constr        :: The type of `with' constraints
799
800     == Classes ==
801     class_type         :: The type of class types
802     class_sig_item     :: The type of class signature items
803     class_expr         :: The type of class expressions
804     class_str_item     :: The type of class structure items
805  *)
806     module type Camlp4Ast =
807       sig
808         (** The inner module for locations *)
809         module Loc : Loc
810           
811         type loc =
812           Loc.
813           t
814           and meta_bool =
815           | BTrue | BFalse | BAnt of string
816           and 'a meta_option =
817           | ONone | OSome of 'a | OAnt of string
818           and 'a meta_list =
819           | LNil | LCons of 'a * 'a meta_list | LAnt of string
820           and ident =
821           | IdAcc of loc * ident * ident
822           | (* i . i *)
823           IdApp of loc * ident * ident
824           | (* i i *)
825           IdLid of loc * string
826           | (* foo *)
827           IdUid of loc * string
828           | (* Bar *)
829           IdAnt of loc * string
830           and (* $s$ *)
831           ctyp =
832           | TyNil of loc
833           | TyAli of loc * ctyp * ctyp
834           | (* t as t *)
835           (* list 'a as 'a *)
836           TyAny of loc
837           | (* _ *)
838           TyApp of loc * ctyp * ctyp
839           | (* t t *)
840           (* list 'a *)
841           TyArr of loc * ctyp * ctyp
842           | (* t -> t *)
843           (* int -> string *)
844           TyCls of loc * ident
845           | (* #i *)
846           (* #point *)
847           TyLab of loc * string * ctyp
848           | (* ~s:t *)
849           TyId of loc * ident
850           | (* i *)
851           (* Lazy.t *)
852           TyMan of loc * ctyp * ctyp
853           | (* t == t *)
854           (* type t = [ A | B ] == Foo.t *)
855           (* type t 'a 'b 'c = t constraint t = t constraint t = t *)
856           TyDcl of loc * string * ctyp list * ctyp * (ctyp * ctyp) list
857           | (* < (t)? (..)? > *)
858           (* < move : int -> 'a .. > as 'a  *)
859           TyObj of loc * ctyp * meta_bool
860           | TyOlb of loc * string * ctyp
861           | (* ?s:t *)
862           TyPol of loc * ctyp * ctyp
863           | (* ! t . t *)
864           (* ! 'a . list 'a -> 'a *)
865           TyQuo of loc * string
866           | (* 's *)
867           TyQuP of loc * string
868           | (* +'s *)
869           TyQuM of loc * string
870           | (* -'s *)
871           TyVrn of loc * string
872           | (* `s *)
873           TyRec of loc * ctyp
874           | (* { t } *)
875           (* { foo : int ; bar : mutable string } *)
876           TyCol of loc * ctyp * ctyp
877           | (* t : t *)
878           TySem of loc * ctyp * ctyp
879           | (* t; t *)
880           TyCom of loc * ctyp * ctyp
881           | (* t, t *)
882           TySum of loc * ctyp
883           | (* [ t ] *)
884           (* [ A of int and string | B ] *)
885           TyOf of loc * ctyp * ctyp
886           | (* t of t *)
887           (* A of int *)
888           TyAnd of loc * ctyp * ctyp
889           | (* t and t *)
890           TyOr of loc * ctyp * ctyp
891           | (* t | t *)
892           TyPrv of loc * ctyp
893           | (* private t *)
894           TyMut of loc * ctyp
895           | (* mutable t *)
896           TyTup of loc * ctyp
897           | (* ( t ) *)
898           (* (int * string) *)
899           TySta of loc * ctyp * ctyp
900           | (* t * t *)
901           TyVrnEq of loc * ctyp
902           | (* [ = t ] *)
903           TyVrnSup of loc * ctyp
904           | (* [ > t ] *)
905           TyVrnInf of loc * ctyp
906           | (* [ < t ] *)
907           TyVrnInfSup of loc * ctyp * ctyp
908           | (* [ < t > t ] *)
909           TyAmp of loc * ctyp * ctyp
910           | (* t & t *)
911           TyOfAmp of loc * ctyp * ctyp
912           | (* t of & t *)
913           TyAnt of loc * string
914           and (* $s$ *)
915           patt =
916           | PaNil of loc
917           | PaId of loc * ident
918           | (* i *)
919           PaAli of loc * patt * patt
920           | (* p as p *)
921           (* (Node x y as n) *)
922           PaAnt of loc * string
923           | (* $s$ *)
924           PaAny of loc
925           | (* _ *)
926           PaApp of loc * patt * patt
927           | (* p p *)
928           (* fun x y -> *)
929           PaArr of loc * patt
930           | (* [| p |] *)
931           PaCom of loc * patt * patt
932           | (* p, p *)
933           PaSem of loc * patt * patt
934           | (* p; p *)
935           PaChr of loc * string
936           | (* c *)
937           (* 'x' *)
938           PaInt of loc * string
939           | PaInt32 of loc * string
940           | PaInt64 of loc * string
941           | PaNativeInt of loc * string
942           | PaFlo of loc * string
943           | PaLab of loc * string * patt
944           | (* ~s or ~s:(p) *)
945           (* ?s or ?s:(p) *)
946           PaOlb of loc * string * patt
947           | (* ?s:(p = e) or ?(p = e) *)
948           PaOlbi of loc * string * patt * expr
949           | PaOrp of loc * patt * patt
950           | (* p | p *)
951           PaRng of loc * patt * patt
952           | (* p .. p *)
953           PaRec of loc * patt
954           | (* { p } *)
955           PaEq of loc * ident * patt
956           | (* i = p *)
957           PaStr of loc * string
958           | (* s *)
959           PaTup of loc * patt
960           | (* ( p ) *)
961           PaTyc of loc * patt * ctyp
962           | (* (p : t) *)
963           PaTyp of loc * ident
964           | (* #i *)
965           PaVrn of loc * string
966           | (* `s *)
967           PaLaz of loc * patt
968           and (* lazy p *)
969           expr =
970           | ExNil of loc
971           | ExId of loc * ident
972           | (* i *)
973           ExAcc of loc * expr * expr
974           | (* e.e *)
975           ExAnt of loc * string
976           | (* $s$ *)
977           ExApp of loc * expr * expr
978           | (* e e *)
979           ExAre of loc * expr * expr
980           | (* e.(e) *)
981           ExArr of loc * expr
982           | (* [| e |] *)
983           ExSem of loc * expr * expr
984           | (* e; e *)
985           ExAsf of loc
986           | (* assert False *)
987           ExAsr of loc * expr
988           | (* assert e *)
989           ExAss of loc * expr * expr
990           | (* e := e *)
991           ExChr of loc * string
992           | (* 'c' *)
993           ExCoe of loc * expr * ctyp * ctyp
994           | (* (e : t) or (e : t :> t) *)
995           ExFlo of loc * string
996           | (* 3.14 *)
997           (* for s = e to/downto e do { e } *)
998           ExFor of loc * string * expr * expr * meta_bool * expr
999           | ExFun of loc * match_case
1000           | (* fun [ mc ] *)
1001           ExIfe of loc * expr * expr * expr
1002           | (* if e then e else e *)
1003           ExInt of loc * string
1004           | (* 42 *)
1005           ExInt32 of loc * string
1006           | ExInt64 of loc * string
1007           | ExNativeInt of loc * string
1008           | ExLab of loc * string * expr
1009           | (* ~s or ~s:e *)
1010           ExLaz of loc * expr
1011           | (* lazy e *)
1012           (* let b in e or let rec b in e *)
1013           ExLet of loc * meta_bool * binding * expr
1014           | (* let module s = me in e *)
1015           ExLmd of loc * string * module_expr * expr
1016           | (* match e with [ mc ] *)
1017           ExMat of loc * expr * match_case
1018           | (* new i *)
1019           ExNew of loc * ident
1020           | (* object ((p))? (cst)? end *)
1021           ExObj of loc * patt * class_str_item
1022           | (* ?s or ?s:e *)
1023           ExOlb of loc * string * expr
1024           | (* {< rb >} *)
1025           ExOvr of loc * rec_binding
1026           | (* { rb } or { (e) with rb } *)
1027           ExRec of loc * rec_binding * expr
1028           | (* do { e } *)
1029           ExSeq of loc * expr
1030           | (* e#s *)
1031           ExSnd of loc * expr * string
1032           | (* e.[e] *)
1033           ExSte of loc * expr * expr
1034           | (* s *)
1035           (* "foo" *)
1036           ExStr of loc * string
1037           | (* try e with [ mc ] *)
1038           ExTry of loc * expr * match_case
1039           | (* (e) *)
1040           ExTup of loc * expr
1041           | (* e, e *)
1042           ExCom of loc * expr * expr
1043           | (* (e : t) *)
1044           ExTyc of loc * expr * ctyp
1045           | (* `s *)
1046           ExVrn of loc * string
1047           | (* while e do { e } *)
1048           ExWhi of loc * expr * expr
1049           and module_type =
1050           | MtNil of loc
1051           | (* i *)
1052           (* A.B.C *)
1053           MtId of loc * ident
1054           | (* functor (s : mt) -> mt *)
1055           MtFun of loc * string * module_type * module_type
1056           | (* 's *)
1057           MtQuo of loc * string
1058           | (* sig sg end *)
1059           MtSig of loc * sig_item
1060           | (* mt with wc *)
1061           MtWit of loc * module_type * with_constr
1062           | MtAnt of loc * string
1063           and (* $s$ *)
1064           sig_item =
1065           | SgNil of loc
1066           | (* class cict *)
1067           SgCls of loc * class_type
1068           | (* class type cict *)
1069           SgClt of loc * class_type
1070           | (* sg ; sg *)
1071           SgSem of loc * sig_item * sig_item
1072           | (* # s or # s e *)
1073           SgDir of loc * string * expr
1074           | (* exception t *)
1075           SgExc of loc * ctyp
1076           | (* external s : t = s ... s *)
1077           SgExt of loc * string * ctyp * string meta_list
1078           | (* include mt *)
1079           SgInc of loc * module_type
1080           | (* module s : mt *)
1081           SgMod of loc * string * module_type
1082           | (* module rec mb *)
1083           SgRecMod of loc * module_binding
1084           | (* module type s = mt *)
1085           SgMty of loc * string * module_type
1086           | (* open i *)
1087           SgOpn of loc * ident
1088           | (* type t *)
1089           SgTyp of loc * ctyp
1090           | (* value s : t *)
1091           SgVal of loc * string * ctyp
1092           | SgAnt of loc * string
1093           and (* $s$ *)
1094           with_constr =
1095           | WcNil of loc
1096           | (* type t = t *)
1097           WcTyp of loc * ctyp * ctyp
1098           | (* module i = i *)
1099           WcMod of loc * ident * ident
1100           | (* wc and wc *)
1101           WcAnd of loc * with_constr * with_constr
1102           | WcAnt of loc * string
1103           and (* $s$ *)
1104           binding =
1105           | BiNil of loc
1106           | (* bi and bi *)
1107           (* let a = 42 and c = 43 *)
1108           BiAnd of loc * binding * binding
1109           | (* p = e *)
1110           (* let patt = expr *)
1111           BiEq of loc * patt * expr
1112           | BiAnt of loc * string
1113           and (* $s$ *)
1114           rec_binding =
1115           | RbNil of loc
1116           | (* rb ; rb *)
1117           RbSem of loc * rec_binding * rec_binding
1118           | (* i = e *)
1119           RbEq of loc * ident * expr
1120           | RbAnt of loc * string
1121           and (* $s$ *)
1122           module_binding =
1123           | MbNil of loc
1124           | (* mb and mb *)
1125           (* module rec (s : mt) = me and (s : mt) = me *)
1126           MbAnd of loc * module_binding * module_binding
1127           | (* s : mt = me *)
1128           MbColEq of loc * string * module_type * module_expr
1129           | (* s : mt *)
1130           MbCol of loc * string * module_type
1131           | MbAnt of loc * string
1132           and (* $s$ *)
1133           match_case =
1134           | McNil of loc
1135           | (* a | a *)
1136           McOr of loc * match_case * match_case
1137           | (* p (when e)? -> e *)
1138           McArr of loc * patt * expr * expr
1139           | McAnt of loc * string
1140           and (* $s$ *)
1141           module_expr =
1142           | MeNil of loc
1143           | (* i *)
1144           MeId of loc * ident
1145           | (* me me *)
1146           MeApp of loc * module_expr * module_expr
1147           | (* functor (s : mt) -> me *)
1148           MeFun of loc * string * module_type * module_expr
1149           | (* struct st end *)
1150           MeStr of loc * str_item
1151           | (* (me : mt) *)
1152           MeTyc of loc * module_expr * module_type
1153           | MeAnt of loc * string
1154           and (* $s$ *)
1155           str_item =
1156           | StNil of loc
1157           | (* class cice *)
1158           StCls of loc * class_expr
1159           | (* class type cict *)
1160           StClt of loc * class_type
1161           | (* st ; st *)
1162           StSem of loc * str_item * str_item
1163           | (* # s or # s e *)
1164           StDir of loc * string * expr
1165           | (* exception t or exception t = i *)
1166           StExc of loc * ctyp * (*FIXME*) ident meta_option
1167           | (* e *)
1168           StExp of loc * expr
1169           | (* external s : t = s ... s *)
1170           StExt of loc * string * ctyp * string meta_list
1171           | (* include me *)
1172           StInc of loc * module_expr
1173           | (* module s = me *)
1174           StMod of loc * string * module_expr
1175           | (* module rec mb *)
1176           StRecMod of loc * module_binding
1177           | (* module type s = mt *)
1178           StMty of loc * string * module_type
1179           | (* open i *)
1180           StOpn of loc * ident
1181           | (* type t *)
1182           StTyp of loc * ctyp
1183           | (* value (rec)? bi *)
1184           StVal of loc * meta_bool * binding
1185           | StAnt of loc * string
1186           and (* $s$ *)
1187           class_type =
1188           | CtNil of loc
1189           | (* (virtual)? i ([ t ])? *)
1190           CtCon of loc * meta_bool * ident * ctyp
1191           | (* [t] -> ct *)
1192           CtFun of loc * ctyp * class_type
1193           | (* object ((t))? (csg)? end *)
1194           CtSig of loc * ctyp * class_sig_item
1195           | (* ct and ct *)
1196           CtAnd of loc * class_type * class_type
1197           | (* ct : ct *)
1198           CtCol of loc * class_type * class_type
1199           | (* ct = ct *)
1200           CtEq of loc * class_type * class_type
1201           | (* $s$ *)
1202           CtAnt of loc * string
1203           and class_sig_item =
1204           | CgNil of loc
1205           | (* type t = t *)
1206           CgCtr of loc * ctyp * ctyp
1207           | (* csg ; csg *)
1208           CgSem of loc * class_sig_item * class_sig_item
1209           | (* inherit ct *)
1210           CgInh of loc * class_type
1211           | (* method s : t or method private s : t *)
1212           CgMth of loc * string * meta_bool * ctyp
1213           | (* value (virtual)? (mutable)? s : t *)
1214           CgVal of loc * string * meta_bool * meta_bool * ctyp
1215           | (* method virtual (mutable)? s : t *)
1216           CgVir of loc * string * meta_bool * ctyp
1217           | CgAnt of loc * string
1218           and (* $s$ *)
1219           class_expr =
1220           | CeNil of loc
1221           | (* ce e *)
1222           CeApp of loc * class_expr * expr
1223           | (* (virtual)? i ([ t ])? *)
1224           CeCon of loc * meta_bool * ident * ctyp
1225           | (* fun p -> ce *)
1226           CeFun of loc * patt * class_expr
1227           | (* let (rec)? bi in ce *)
1228           CeLet of loc * meta_bool * binding * class_expr
1229           | (* object ((p))? (cst)? end *)
1230           CeStr of loc * patt * class_str_item
1231           | (* ce : ct *)
1232           CeTyc of loc * class_expr * class_type
1233           | (* ce and ce *)
1234           CeAnd of loc * class_expr * class_expr
1235           | (* ce = ce *)
1236           CeEq of loc * class_expr * class_expr
1237           | (* $s$ *)
1238           CeAnt of loc * string
1239           and class_str_item =
1240           | CrNil of loc
1241           | (* cst ; cst *)
1242           CrSem of loc * class_str_item * class_str_item
1243           | (* type t = t *)
1244           CrCtr of loc * ctyp * ctyp
1245           | (* inherit ce or inherit ce as s *)
1246           CrInh of loc * class_expr * string
1247           | (* initializer e *)
1248           CrIni of loc * expr
1249           | (* method (private)? s : t = e or method (private)? s = e *)
1250           CrMth of loc * string * meta_bool * expr * ctyp
1251           | (* value (mutable)? s = e *)
1252           CrVal of loc * string * meta_bool * expr
1253           | (* method virtual (private)? s : t *)
1254           CrVir of loc * string * meta_bool * ctyp
1255           | (* value virtual (private)? s : t *)
1256           CrVvr of loc * string * meta_bool * ctyp
1257           | CrAnt of loc * string
1258         
1259         val loc_of_ctyp : ctyp -> loc
1260           
1261         val loc_of_patt : patt -> loc
1262           
1263         val loc_of_expr : expr -> loc
1264           
1265         val loc_of_module_type : module_type -> loc
1266           
1267         val loc_of_module_expr : module_expr -> loc
1268           
1269         val loc_of_sig_item : sig_item -> loc
1270           
1271         val loc_of_str_item : str_item -> loc
1272           
1273         val loc_of_class_type : class_type -> loc
1274           
1275         val loc_of_class_sig_item : class_sig_item -> loc
1276           
1277         val loc_of_class_expr : class_expr -> loc
1278           
1279         val loc_of_class_str_item : class_str_item -> loc
1280           
1281         val loc_of_with_constr : with_constr -> loc
1282           
1283         val loc_of_binding : binding -> loc
1284           
1285         val loc_of_rec_binding : rec_binding -> loc
1286           
1287         val loc_of_module_binding : module_binding -> loc
1288           
1289         val loc_of_match_case : match_case -> loc
1290           
1291         val loc_of_ident : ident -> loc
1292           
1293         module Meta :
1294           sig
1295             module type META_LOC =
1296               sig
1297                 val meta_loc_patt : loc -> loc -> patt
1298                   
1299                 val meta_loc_expr : loc -> loc -> expr
1300                   
1301               end
1302               
1303             module MetaLoc :
1304               sig
1305                 val meta_loc_patt : loc -> loc -> patt
1306                   
1307                 val meta_loc_expr : loc -> loc -> expr
1308                   
1309               end
1310               
1311             module MetaGhostLoc :
1312               sig
1313                 val meta_loc_patt : loc -> 'a -> patt
1314                   
1315                 val meta_loc_expr : loc -> 'a -> expr
1316                   
1317               end
1318               
1319             module MetaLocVar :
1320               sig
1321                 val meta_loc_patt : loc -> 'a -> patt
1322                   
1323                 val meta_loc_expr : loc -> 'a -> expr
1324                   
1325               end
1326               
1327             module Make (MetaLoc : META_LOC) :
1328               sig
1329                 module Expr :
1330                   sig
1331                     val meta_string : loc -> string -> expr
1332                       
1333                     val meta_int : loc -> string -> expr
1334                       
1335                     val meta_float : loc -> string -> expr
1336                       
1337                     val meta_char : loc -> string -> expr
1338                       
1339                     val meta_bool : loc -> bool -> expr
1340                       
1341                     val meta_list :
1342                       (loc -> 'a -> expr) -> loc -> 'a list -> expr
1343                       
1344                     val meta_binding : loc -> binding -> expr
1345                       
1346                     val meta_rec_binding : loc -> rec_binding -> expr
1347                       
1348                     val meta_class_expr : loc -> class_expr -> expr
1349                       
1350                     val meta_class_sig_item : loc -> class_sig_item -> expr
1351                       
1352                     val meta_class_str_item : loc -> class_str_item -> expr
1353                       
1354                     val meta_class_type : loc -> class_type -> expr
1355                       
1356                     val meta_ctyp : loc -> ctyp -> expr
1357                       
1358                     val meta_expr : loc -> expr -> expr
1359                       
1360                     val meta_ident : loc -> ident -> expr
1361                       
1362                     val meta_match_case : loc -> match_case -> expr
1363                       
1364                     val meta_module_binding : loc -> module_binding -> expr
1365                       
1366                     val meta_module_expr : loc -> module_expr -> expr
1367                       
1368                     val meta_module_type : loc -> module_type -> expr
1369                       
1370                     val meta_patt : loc -> patt -> expr
1371                       
1372                     val meta_sig_item : loc -> sig_item -> expr
1373                       
1374                     val meta_str_item : loc -> str_item -> expr
1375                       
1376                     val meta_with_constr : loc -> with_constr -> expr
1377                       
1378                   end
1379                   
1380                 module Patt :
1381                   sig
1382                     val meta_string : loc -> string -> patt
1383                       
1384                     val meta_int : loc -> string -> patt
1385                       
1386                     val meta_float : loc -> string -> patt
1387                       
1388                     val meta_char : loc -> string -> patt
1389                       
1390                     val meta_bool : loc -> bool -> patt
1391                       
1392                     val meta_list :
1393                       (loc -> 'a -> patt) -> loc -> 'a list -> patt
1394                       
1395                     val meta_binding : loc -> binding -> patt
1396                       
1397                     val meta_rec_binding : loc -> rec_binding -> patt
1398                       
1399                     val meta_class_expr : loc -> class_expr -> patt
1400                       
1401                     val meta_class_sig_item : loc -> class_sig_item -> patt
1402                       
1403                     val meta_class_str_item : loc -> class_str_item -> patt
1404                       
1405                     val meta_class_type : loc -> class_type -> patt
1406                       
1407                     val meta_ctyp : loc -> ctyp -> patt
1408                       
1409                     val meta_expr : loc -> expr -> patt
1410                       
1411                     val meta_ident : loc -> ident -> patt
1412                       
1413                     val meta_match_case : loc -> match_case -> patt
1414                       
1415                     val meta_module_binding : loc -> module_binding -> patt
1416                       
1417                     val meta_module_expr : loc -> module_expr -> patt
1418                       
1419                     val meta_module_type : loc -> module_type -> patt
1420                       
1421                     val meta_patt : loc -> patt -> patt
1422                       
1423                     val meta_sig_item : loc -> sig_item -> patt
1424                       
1425                     val meta_str_item : loc -> str_item -> patt
1426                       
1427                     val meta_with_constr : loc -> with_constr -> patt
1428                       
1429                   end
1430                   
1431               end
1432               
1433           end
1434           
1435         class map :
1436           object ('self_type)
1437             method string : string -> string
1438               
1439             method list :
1440               'a 'b. ('self_type -> 'a -> 'b) -> 'a list -> 'b list
1441               
1442             method meta_bool : meta_bool -> meta_bool
1443               
1444             method meta_option :
1445               'a 'b.
1446                 ('self_type -> 'a -> 'b) -> 'a meta_option -> 'b meta_option
1447               
1448             method meta_list :
1449               'a 'b. ('self_type -> 'a -> 'b) -> 'a meta_list -> 'b meta_list
1450               
1451             method loc : loc -> loc
1452               
1453             method expr : expr -> expr
1454               
1455             method patt : patt -> patt
1456               
1457             method ctyp : ctyp -> ctyp
1458               
1459             method str_item : str_item -> str_item
1460               
1461             method sig_item : sig_item -> sig_item
1462               
1463             method module_expr : module_expr -> module_expr
1464               
1465             method module_type : module_type -> module_type
1466               
1467             method class_expr : class_expr -> class_expr
1468               
1469             method class_type : class_type -> class_type
1470               
1471             method class_sig_item : class_sig_item -> class_sig_item
1472               
1473             method class_str_item : class_str_item -> class_str_item
1474               
1475             method with_constr : with_constr -> with_constr
1476               
1477             method binding : binding -> binding
1478               
1479             method rec_binding : rec_binding -> rec_binding
1480               
1481             method module_binding : module_binding -> module_binding
1482               
1483             method match_case : match_case -> match_case
1484               
1485             method ident : ident -> ident
1486               
1487             method unknown : 'a. 'a -> 'a
1488               
1489           end
1490           
1491         class fold :
1492           object ('self_type)
1493             method string : string -> 'self_type
1494               
1495             method list :
1496               'a. ('self_type -> 'a -> 'self_type) -> 'a list -> 'self_type
1497               
1498             method meta_bool : meta_bool -> 'self_type
1499               
1500             method meta_option :
1501               'a.
1502                 ('self_type -> 'a -> 'self_type) ->
1503                   'a meta_option -> 'self_type
1504               
1505             method meta_list :
1506               'a.
1507                 ('self_type -> 'a -> 'self_type) ->
1508                   'a meta_list -> 'self_type
1509               
1510             method loc : loc -> 'self_type
1511               
1512             method expr : expr -> 'self_type
1513               
1514             method patt : patt -> 'self_type
1515               
1516             method ctyp : ctyp -> 'self_type
1517               
1518             method str_item : str_item -> 'self_type
1519               
1520             method sig_item : sig_item -> 'self_type
1521               
1522             method module_expr : module_expr -> 'self_type
1523               
1524             method module_type : module_type -> 'self_type
1525               
1526             method class_expr : class_expr -> 'self_type
1527               
1528             method class_type : class_type -> 'self_type
1529               
1530             method class_sig_item : class_sig_item -> 'self_type
1531               
1532             method class_str_item : class_str_item -> 'self_type
1533               
1534             method with_constr : with_constr -> 'self_type
1535               
1536             method binding : binding -> 'self_type
1537               
1538             method rec_binding : rec_binding -> 'self_type
1539               
1540             method module_binding : module_binding -> 'self_type
1541               
1542             method match_case : match_case -> 'self_type
1543               
1544             method ident : ident -> 'self_type
1545               
1546             method unknown : 'a. 'a -> 'self_type
1547               
1548           end
1549           
1550         val map_expr : (expr -> expr) -> map
1551           
1552         val map_patt : (patt -> patt) -> map
1553           
1554         val map_ctyp : (ctyp -> ctyp) -> map
1555           
1556         val map_str_item : (str_item -> str_item) -> map
1557           
1558         val map_sig_item : (sig_item -> sig_item) -> map
1559           
1560         val map_loc : (loc -> loc) -> map
1561           
1562         val ident_of_expr : expr -> ident
1563           
1564         val ident_of_patt : patt -> ident
1565           
1566         val ident_of_ctyp : ctyp -> ident
1567           
1568         val biAnd_of_list : binding list -> binding
1569           
1570         val rbSem_of_list : rec_binding list -> rec_binding
1571           
1572         val paSem_of_list : patt list -> patt
1573           
1574         val paCom_of_list : patt list -> patt
1575           
1576         val tyOr_of_list : ctyp list -> ctyp
1577           
1578         val tyAnd_of_list : ctyp list -> ctyp
1579           
1580         val tyAmp_of_list : ctyp list -> ctyp
1581           
1582         val tySem_of_list : ctyp list -> ctyp
1583           
1584         val tyCom_of_list : ctyp list -> ctyp
1585           
1586         val tySta_of_list : ctyp list -> ctyp
1587           
1588         val stSem_of_list : str_item list -> str_item
1589           
1590         val sgSem_of_list : sig_item list -> sig_item
1591           
1592         val crSem_of_list : class_str_item list -> class_str_item
1593           
1594         val cgSem_of_list : class_sig_item list -> class_sig_item
1595           
1596         val ctAnd_of_list : class_type list -> class_type
1597           
1598         val ceAnd_of_list : class_expr list -> class_expr
1599           
1600         val wcAnd_of_list : with_constr list -> with_constr
1601           
1602         val meApp_of_list : module_expr list -> module_expr
1603           
1604         val mbAnd_of_list : module_binding list -> module_binding
1605           
1606         val mcOr_of_list : match_case list -> match_case
1607           
1608         val idAcc_of_list : ident list -> ident
1609           
1610         val idApp_of_list : ident list -> ident
1611           
1612         val exSem_of_list : expr list -> expr
1613           
1614         val exCom_of_list : expr list -> expr
1615           
1616         val list_of_ctyp : ctyp -> ctyp list -> ctyp list
1617           
1618         val list_of_binding : binding -> binding list -> binding list
1619           
1620         val list_of_rec_binding :
1621           rec_binding -> rec_binding list -> rec_binding list
1622           
1623         val list_of_with_constr :
1624           with_constr -> with_constr list -> with_constr list
1625           
1626         val list_of_patt : patt -> patt list -> patt list
1627           
1628         val list_of_expr : expr -> expr list -> expr list
1629           
1630         val list_of_str_item : str_item -> str_item list -> str_item list
1631           
1632         val list_of_sig_item : sig_item -> sig_item list -> sig_item list
1633           
1634         val list_of_class_sig_item :
1635           class_sig_item -> class_sig_item list -> class_sig_item list
1636           
1637         val list_of_class_str_item :
1638           class_str_item -> class_str_item list -> class_str_item list
1639           
1640         val list_of_class_type :
1641           class_type -> class_type list -> class_type list
1642           
1643         val list_of_class_expr :
1644           class_expr -> class_expr list -> class_expr list
1645           
1646         val list_of_module_expr :
1647           module_expr -> module_expr list -> module_expr list
1648           
1649         val list_of_module_binding :
1650           module_binding -> module_binding list -> module_binding list
1651           
1652         val list_of_match_case :
1653           match_case -> match_case list -> match_case list
1654           
1655         val list_of_ident : ident -> ident list -> ident list
1656           
1657         val safe_string_escaped : string -> string
1658           
1659         val is_irrefut_patt : patt -> bool
1660           
1661         val is_constructor : ident -> bool
1662           
1663         val is_patt_constructor : patt -> bool
1664           
1665         val is_expr_constructor : expr -> bool
1666           
1667         val ty_of_stl : (Loc.t * string * (ctyp list)) -> ctyp
1668           
1669         val ty_of_sbt : (Loc.t * string * bool * ctyp) -> ctyp
1670           
1671         val bi_of_pe : (patt * expr) -> binding
1672           
1673         val pel_of_binding : binding -> (patt * expr) list
1674           
1675         val binding_of_pel : (patt * expr) list -> binding
1676           
1677         val sum_type_of_list : (Loc.t * string * (ctyp list)) list -> ctyp
1678           
1679         val record_type_of_list : (Loc.t * string * bool * ctyp) list -> ctyp
1680           
1681       end
1682       
1683     module Camlp4AstToAst (M : Camlp4Ast) : Ast with type loc = M.loc
1684       and type meta_bool = M.meta_bool
1685       and type 'a meta_option = 'a M.meta_option
1686       and type 'a meta_list = 'a M.meta_list and type ctyp = M.ctyp
1687       and type patt = M.patt and type expr = M.expr
1688       and type module_type = M.module_type and type sig_item = M.sig_item
1689       and type with_constr = M.with_constr
1690       and type module_expr = M.module_expr and type str_item = M.str_item
1691       and type class_type = M.class_type
1692       and type class_sig_item = M.class_sig_item
1693       and type class_expr = M.class_expr
1694       and type class_str_item = M.class_str_item and type binding = M.binding
1695       and type rec_binding = M.rec_binding
1696       and type module_binding = M.module_binding
1697       and type match_case = M.match_case and type ident = M.ident = M
1698       
1699     module MakeCamlp4Ast (Loc : Type) =
1700       struct
1701         type loc =
1702           Loc.
1703           t
1704           and meta_bool =
1705           | BTrue | BFalse | BAnt of string
1706           and 'a meta_option =
1707           | ONone | OSome of 'a | OAnt of string
1708           and 'a meta_list =
1709           | LNil | LCons of 'a * 'a meta_list | LAnt of string
1710           and ident =
1711           | IdAcc of loc * ident * ident
1712           | IdApp of loc * ident * ident
1713           | IdLid of loc * string
1714           | IdUid of loc * string
1715           | IdAnt of loc * string
1716           and ctyp =
1717           | TyNil of loc
1718           | TyAli of loc * ctyp * ctyp
1719           | TyAny of loc
1720           | TyApp of loc * ctyp * ctyp
1721           | TyArr of loc * ctyp * ctyp
1722           | TyCls of loc * ident
1723           | TyLab of loc * string * ctyp
1724           | TyId of loc * ident
1725           | TyMan of loc * ctyp * ctyp
1726           | TyDcl of loc * string * ctyp list * ctyp * (ctyp * ctyp) list
1727           | TyObj of loc * ctyp * meta_bool
1728           | TyOlb of loc * string * ctyp
1729           | TyPol of loc * ctyp * ctyp
1730           | TyQuo of loc * string
1731           | TyQuP of loc * string
1732           | TyQuM of loc * string
1733           | TyVrn of loc * string
1734           | TyRec of loc * ctyp
1735           | TyCol of loc * ctyp * ctyp
1736           | TySem of loc * ctyp * ctyp
1737           | TyCom of loc * ctyp * ctyp
1738           | TySum of loc * ctyp
1739           | TyOf of loc * ctyp * ctyp
1740           | TyAnd of loc * ctyp * ctyp
1741           | TyOr of loc * ctyp * ctyp
1742           | TyPrv of loc * ctyp
1743           | TyMut of loc * ctyp
1744           | TyTup of loc * ctyp
1745           | TySta of loc * ctyp * ctyp
1746           | TyVrnEq of loc * ctyp
1747           | TyVrnSup of loc * ctyp
1748           | TyVrnInf of loc * ctyp
1749           | TyVrnInfSup of loc * ctyp * ctyp
1750           | TyAmp of loc * ctyp * ctyp
1751           | TyOfAmp of loc * ctyp * ctyp
1752           | TyAnt of loc * string
1753           and patt =
1754           | PaNil of loc
1755           | PaId of loc * ident
1756           | PaAli of loc * patt * patt
1757           | PaAnt of loc * string
1758           | PaAny of loc
1759           | PaApp of loc * patt * patt
1760           | PaArr of loc * patt
1761           | PaCom of loc * patt * patt
1762           | PaSem of loc * patt * patt
1763           | PaChr of loc * string
1764           | PaInt of loc * string
1765           | PaInt32 of loc * string
1766           | PaInt64 of loc * string
1767           | PaNativeInt of loc * string
1768           | PaFlo of loc * string
1769           | PaLab of loc * string * patt
1770           | PaOlb of loc * string * patt
1771           | PaOlbi of loc * string * patt * expr
1772           | PaOrp of loc * patt * patt
1773           | PaRng of loc * patt * patt
1774           | PaRec of loc * patt
1775           | PaEq of loc * ident * patt
1776           | PaStr of loc * string
1777           | PaTup of loc * patt
1778           | PaTyc of loc * patt * ctyp
1779           | PaTyp of loc * ident
1780           | PaVrn of loc * string
1781           | PaLaz of loc * patt
1782           and expr =
1783           | ExNil of loc
1784           | ExId of loc * ident
1785           | ExAcc of loc * expr * expr
1786           | ExAnt of loc * string
1787           | ExApp of loc * expr * expr
1788           | ExAre of loc * expr * expr
1789           | ExArr of loc * expr
1790           | ExSem of loc * expr * expr
1791           | ExAsf of loc
1792           | ExAsr of loc * expr
1793           | ExAss of loc * expr * expr
1794           | ExChr of loc * string
1795           | ExCoe of loc * expr * ctyp * ctyp
1796           | ExFlo of loc * string
1797           | ExFor of loc * string * expr * expr * meta_bool * expr
1798           | ExFun of loc * match_case
1799           | ExIfe of loc * expr * expr * expr
1800           | ExInt of loc * string
1801           | ExInt32 of loc * string
1802           | ExInt64 of loc * string
1803           | ExNativeInt of loc * string
1804           | ExLab of loc * string * expr
1805           | ExLaz of loc * expr
1806           | ExLet of loc * meta_bool * binding * expr
1807           | ExLmd of loc * string * module_expr * expr
1808           | ExMat of loc * expr * match_case
1809           | ExNew of loc * ident
1810           | ExObj of loc * patt * class_str_item
1811           | ExOlb of loc * string * expr
1812           | ExOvr of loc * rec_binding
1813           | ExRec of loc * rec_binding * expr
1814           | ExSeq of loc * expr
1815           | ExSnd of loc * expr * string
1816           | ExSte of loc * expr * expr
1817           | ExStr of loc * string
1818           | ExTry of loc * expr * match_case
1819           | ExTup of loc * expr
1820           | ExCom of loc * expr * expr
1821           | ExTyc of loc * expr * ctyp
1822           | ExVrn of loc * string
1823           | ExWhi of loc * expr * expr
1824           and module_type =
1825           | MtNil of loc
1826           | MtId of loc * ident
1827           | MtFun of loc * string * module_type * module_type
1828           | MtQuo of loc * string
1829           | MtSig of loc * sig_item
1830           | MtWit of loc * module_type * with_constr
1831           | MtAnt of loc * string
1832           and sig_item =
1833           | SgNil of loc
1834           | SgCls of loc * class_type
1835           | SgClt of loc * class_type
1836           | SgSem of loc * sig_item * sig_item
1837           | SgDir of loc * string * expr
1838           | SgExc of loc * ctyp
1839           | SgExt of loc * string * ctyp * string meta_list
1840           | SgInc of loc * module_type
1841           | SgMod of loc * string * module_type
1842           | SgRecMod of loc * module_binding
1843           | SgMty of loc * string * module_type
1844           | SgOpn of loc * ident
1845           | SgTyp of loc * ctyp
1846           | SgVal of loc * string * ctyp
1847           | SgAnt of loc * string
1848           and with_constr =
1849           | WcNil of loc
1850           | WcTyp of loc * ctyp * ctyp
1851           | WcMod of loc * ident * ident
1852           | WcAnd of loc * with_constr * with_constr
1853           | WcAnt of loc * string
1854           and binding =
1855           | BiNil of loc
1856           | BiAnd of loc * binding * binding
1857           | BiEq of loc * patt * expr
1858           | BiAnt of loc * string
1859           and rec_binding =
1860           | RbNil of loc
1861           | RbSem of loc * rec_binding * rec_binding
1862           | RbEq of loc * ident * expr
1863           | RbAnt of loc * string
1864           and module_binding =
1865           | MbNil of loc
1866           | MbAnd of loc * module_binding * module_binding
1867           | MbColEq of loc * string * module_type * module_expr
1868           | MbCol of loc * string * module_type
1869           | MbAnt of loc * string
1870           and match_case =
1871           | McNil of loc
1872           | McOr of loc * match_case * match_case
1873           | McArr of loc * patt * expr * expr
1874           | McAnt of loc * string
1875           and module_expr =
1876           | MeNil of loc
1877           | MeId of loc * ident
1878           | MeApp of loc * module_expr * module_expr
1879           | MeFun of loc * string * module_type * module_expr
1880           | MeStr of loc * str_item
1881           | MeTyc of loc * module_expr * module_type
1882           | MeAnt of loc * string
1883           and str_item =
1884           | StNil of loc
1885           | StCls of loc * class_expr
1886           | StClt of loc * class_type
1887           | StSem of loc * str_item * str_item
1888           | StDir of loc * string * expr
1889           | StExc of loc * ctyp * ident meta_option
1890           | StExp of loc * expr
1891           | StExt of loc * string * ctyp * string meta_list
1892           | StInc of loc * module_expr
1893           | StMod of loc * string * module_expr
1894           | StRecMod of loc * module_binding
1895           | StMty of loc * string * module_type
1896           | StOpn of loc * ident
1897           | StTyp of loc * ctyp
1898           | StVal of loc * meta_bool * binding
1899           | StAnt of loc * string
1900           and class_type =
1901           | CtNil of loc
1902           | CtCon of loc * meta_bool * ident * ctyp
1903           | CtFun of loc * ctyp * class_type
1904           | CtSig of loc * ctyp * class_sig_item
1905           | CtAnd of loc * class_type * class_type
1906           | CtCol of loc * class_type * class_type
1907           | CtEq of loc * class_type * class_type
1908           | CtAnt of loc * string
1909           and class_sig_item =
1910           | CgNil of loc
1911           | CgCtr of loc * ctyp * ctyp
1912           | CgSem of loc * class_sig_item * class_sig_item
1913           | CgInh of loc * class_type
1914           | CgMth of loc * string * meta_bool * ctyp
1915           | CgVal of loc * string * meta_bool * meta_bool * ctyp
1916           | CgVir of loc * string * meta_bool * ctyp
1917           | CgAnt of loc * string
1918           and class_expr =
1919           | CeNil of loc
1920           | CeApp of loc * class_expr * expr
1921           | CeCon of loc * meta_bool * ident * ctyp
1922           | CeFun of loc * patt * class_expr
1923           | CeLet of loc * meta_bool * binding * class_expr
1924           | CeStr of loc * patt * class_str_item
1925           | CeTyc of loc * class_expr * class_type
1926           | CeAnd of loc * class_expr * class_expr
1927           | CeEq of loc * class_expr * class_expr
1928           | CeAnt of loc * string
1929           and class_str_item =
1930           | CrNil of loc
1931           | CrSem of loc * class_str_item * class_str_item
1932           | CrCtr of loc * ctyp * ctyp
1933           | CrInh of loc * class_expr * string
1934           | CrIni of loc * expr
1935           | CrMth of loc * string * meta_bool * expr * ctyp
1936           | CrVal of loc * string * meta_bool * expr
1937           | CrVir of loc * string * meta_bool * ctyp
1938           | CrVvr of loc * string * meta_bool * ctyp
1939           | CrAnt of loc * string
1940         
1941       end
1942       
1943     type ('a, 'loc) stream_filter =
1944       ('a * 'loc) Stream.t -> ('a * 'loc) Stream.t
1945     
1946     module type AstFilters =
1947       sig
1948         module Ast : Camlp4Ast
1949           
1950         type 'a filter = 'a -> 'a
1951         
1952         val register_sig_item_filter : Ast.sig_item filter -> unit
1953           
1954         val register_str_item_filter : Ast.str_item filter -> unit
1955           
1956         val register_topphrase_filter : Ast.str_item filter -> unit
1957           
1958         val fold_interf_filters :
1959           ('a -> Ast.sig_item filter -> 'a) -> 'a -> 'a
1960           
1961         val fold_implem_filters :
1962           ('a -> Ast.str_item filter -> 'a) -> 'a -> 'a
1963           
1964         val fold_topphrase_filters :
1965           ('a -> Ast.str_item filter -> 'a) -> 'a -> 'a
1966           
1967       end
1968       
1969     module type DynAst =
1970       sig
1971         module Ast : Ast
1972           
1973         type 'a tag
1974         
1975         val ctyp_tag : Ast.ctyp tag
1976           
1977         val patt_tag : Ast.patt tag
1978           
1979         val expr_tag : Ast.expr tag
1980           
1981         val module_type_tag : Ast.module_type tag
1982           
1983         val sig_item_tag : Ast.sig_item tag
1984           
1985         val with_constr_tag : Ast.with_constr tag
1986           
1987         val module_expr_tag : Ast.module_expr tag
1988           
1989         val str_item_tag : Ast.str_item tag
1990           
1991         val class_type_tag : Ast.class_type tag
1992           
1993         val class_sig_item_tag : Ast.class_sig_item tag
1994           
1995         val class_expr_tag : Ast.class_expr tag
1996           
1997         val class_str_item_tag : Ast.class_str_item tag
1998           
1999         val match_case_tag : Ast.match_case tag
2000           
2001         val ident_tag : Ast.ident tag
2002           
2003         val binding_tag : Ast.binding tag
2004           
2005         val rec_binding_tag : Ast.rec_binding tag
2006           
2007         val module_binding_tag : Ast.module_binding tag
2008           
2009         val string_of_tag : 'a tag -> string
2010           
2011         module Pack (X : sig type 'a t
2012                               end) :
2013           sig
2014             type pack
2015             
2016             val pack : 'a tag -> 'a X.t -> pack
2017               
2018             val unpack : 'a tag -> pack -> 'a X.t
2019               
2020             val print_tag : Format.formatter -> pack -> unit
2021               
2022           end
2023           
2024       end
2025       
2026     type quotation =
2027       { q_name : string; q_loc : string; q_shift : int; q_contents : string
2028       }
2029     
2030     module type Quotation =
2031       sig
2032         module Ast : Ast
2033           
2034         module DynAst : DynAst with module Ast = Ast
2035           
2036         open Ast
2037           
2038         type 'a expand_fun = loc -> string option -> string -> 'a
2039         
2040         val add : string -> 'a DynAst.tag -> 'a expand_fun -> unit
2041           
2042         val find : string -> 'a DynAst.tag -> 'a expand_fun
2043           
2044         val default : string ref
2045           
2046         val parse_quotation_result :
2047           (loc -> string -> 'a) -> loc -> quotation -> string -> string -> 'a
2048           
2049         val translate : (string -> string) ref
2050           
2051         val expand : loc -> quotation -> 'a DynAst.tag -> 'a
2052           
2053         val dump_file : (string option) ref
2054           
2055         module Error : Error
2056           
2057       end
2058       
2059     module type Token =
2060       sig
2061         module Loc : Loc
2062           
2063         type t
2064         
2065         val to_string : t -> string
2066           
2067         val print : Format.formatter -> t -> unit
2068           
2069         val match_keyword : string -> t -> bool
2070           
2071         val extract_string : t -> string
2072           
2073         module Filter :
2074           sig
2075             type token_filter = (t, Loc.t) stream_filter
2076             
2077             type t
2078             
2079             val mk : (string -> bool) -> t
2080               
2081             val define_filter : t -> (token_filter -> token_filter) -> unit
2082               
2083             val filter : t -> token_filter
2084               
2085             val keyword_added : t -> string -> bool -> unit
2086               
2087             val keyword_removed : t -> string -> unit
2088               
2089           end
2090           
2091         module Error : Error
2092           
2093       end
2094       
2095     type camlp4_token =
2096       | KEYWORD of string
2097       | SYMBOL of string
2098       | LIDENT of string
2099       | UIDENT of string
2100       | ESCAPED_IDENT of string
2101       | INT of int * string
2102       | INT32 of int32 * string
2103       | INT64 of int64 * string
2104       | NATIVEINT of nativeint * string
2105       | FLOAT of float * string
2106       | CHAR of char * string
2107       | STRING of string * string
2108       | LABEL of string
2109       | OPTLABEL of string
2110       | QUOTATION of quotation
2111       | ANTIQUOT of string * string
2112       | COMMENT of string
2113       | BLANKS of string
2114       | NEWLINE
2115       | LINE_DIRECTIVE of int * string option
2116       | EOI
2117     
2118     module type Camlp4Token = Token with type t = camlp4_token
2119       
2120     module type DynLoader =
2121       sig
2122         type t
2123         
2124         exception Error of string * string
2125           
2126         val mk : ?ocaml_stdlib: bool -> ?camlp4_stdlib: bool -> unit -> t
2127           
2128         val fold_load_path : t -> (string -> 'a -> 'a) -> 'a -> 'a
2129           
2130         val load : t -> string -> unit
2131           
2132         val include_dir : t -> string -> unit
2133           
2134         val find_in_path : t -> string -> string
2135           
2136         val is_native : bool
2137           
2138       end
2139       
2140     module Grammar =
2141       struct
2142         module type Action =
2143           sig
2144             type t
2145             
2146             val mk : 'a -> t
2147               
2148             val get : t -> 'a
2149               
2150             val getf : t -> 'a -> 'b
2151               
2152             val getf2 : t -> 'a -> 'b -> 'c
2153               
2154           end
2155           
2156         type assoc = | NonA | RightA | LeftA
2157         
2158         type position =
2159           | First
2160           | Last
2161           | Before of string
2162           | After of string
2163           | Level of string
2164         
2165         module type Structure =
2166           sig
2167             module Loc : Loc
2168               
2169             module Action : Action
2170               
2171             module Token : Token with module Loc = Loc
2172               
2173             type gram
2174             
2175             type internal_entry
2176             
2177             type tree
2178             
2179             type token_pattern = ((Token.t -> bool) * string)
2180             
2181             type symbol =
2182               | Smeta of string * symbol list * Action.t
2183               | Snterm of internal_entry
2184               | Snterml of internal_entry * string
2185               | Slist0 of symbol
2186               | Slist0sep of symbol * symbol
2187               | Slist1 of symbol
2188               | Slist1sep of symbol * symbol
2189               | Sopt of symbol
2190               | Sself
2191               | Snext
2192               | Stoken of token_pattern
2193               | Skeyword of string
2194               | Stree of tree
2195             
2196             type production_rule = ((symbol list) * Action.t)
2197             
2198             type single_extend_statment =
2199               ((string option) * (assoc option) * (production_rule list))
2200             
2201             type extend_statment =
2202               ((position option) * (single_extend_statment list))
2203             
2204             type delete_statment = symbol list
2205             
2206             type ('a, 'b, 'c) fold =
2207               internal_entry ->
2208                 symbol list -> ('a Stream.t -> 'b) -> 'a Stream.t -> 'c
2209             
2210             type ('a, 'b, 'c) foldsep =
2211               internal_entry ->
2212                 symbol list ->
2213                   ('a Stream.t -> 'b) ->
2214                     ('a Stream.t -> unit) -> 'a Stream.t -> 'c
2215             
2216           end
2217           
2218         module type Dynamic =
2219           sig
2220             include Structure
2221               
2222             val mk : unit -> gram
2223               
2224             module Entry :
2225               sig
2226                 type 'a t
2227                 
2228                 val mk : gram -> string -> 'a t
2229                   
2230                 val of_parser :
2231                   gram ->
2232                     string -> ((Token.t * Loc.t) Stream.t -> 'a) -> 'a t
2233                   
2234                 val setup_parser :
2235                   'a t -> ((Token.t * Loc.t) Stream.t -> 'a) -> unit
2236                   
2237                 val name : 'a t -> string
2238                   
2239                 val print : Format.formatter -> 'a t -> unit
2240                   
2241                 val dump : Format.formatter -> 'a t -> unit
2242                   
2243                 val obj : 'a t -> internal_entry
2244                   
2245                 val clear : 'a t -> unit
2246                   
2247               end
2248               
2249             val get_filter : gram -> Token.Filter.t
2250               
2251             type 'a not_filtered
2252             
2253             val extend : 'a Entry.t -> extend_statment -> unit
2254               
2255             val delete_rule : 'a Entry.t -> delete_statment -> unit
2256               
2257             val srules :
2258               'a Entry.t -> ((symbol list) * Action.t) list -> symbol
2259               
2260             val sfold0 : ('a -> 'b -> 'b) -> 'b -> (_, 'a, 'b) fold
2261               
2262             val sfold1 : ('a -> 'b -> 'b) -> 'b -> (_, 'a, 'b) fold
2263               
2264             val sfold0sep : ('a -> 'b -> 'b) -> 'b -> (_, 'a, 'b) foldsep
2265               
2266             val lex :
2267               gram ->
2268                 Loc.t ->
2269                   char Stream.t -> ((Token.t * Loc.t) Stream.t) not_filtered
2270               
2271             val lex_string :
2272               gram ->
2273                 Loc.t -> string -> ((Token.t * Loc.t) Stream.t) not_filtered
2274               
2275             val filter :
2276               gram ->
2277                 ((Token.t * Loc.t) Stream.t) not_filtered ->
2278                   (Token.t * Loc.t) Stream.t
2279               
2280             val parse : 'a Entry.t -> Loc.t -> char Stream.t -> 'a
2281               
2282             val parse_string : 'a Entry.t -> Loc.t -> string -> 'a
2283               
2284             val parse_tokens_before_filter :
2285               'a Entry.t -> ((Token.t * Loc.t) Stream.t) not_filtered -> 'a
2286               
2287             val parse_tokens_after_filter :
2288               'a Entry.t -> (Token.t * Loc.t) Stream.t -> 'a
2289               
2290           end
2291           
2292         module type Static =
2293           sig
2294             include Structure
2295               
2296             module Entry :
2297               sig
2298                 type 'a t
2299                 
2300                 val mk : string -> 'a t
2301                   
2302                 val of_parser :
2303                   string -> ((Token.t * Loc.t) Stream.t -> 'a) -> 'a t
2304                   
2305                 val setup_parser :
2306                   'a t -> ((Token.t * Loc.t) Stream.t -> 'a) -> unit
2307                   
2308                 val name : 'a t -> string
2309                   
2310                 val print : Format.formatter -> 'a t -> unit
2311                   
2312                 val dump : Format.formatter -> 'a t -> unit
2313                   
2314                 val obj : 'a t -> internal_entry
2315                   
2316                 val clear : 'a t -> unit
2317                   
2318               end
2319               
2320             val get_filter : unit -> Token.Filter.t
2321               
2322             type 'a not_filtered
2323             
2324             val extend : 'a Entry.t -> extend_statment -> unit
2325               
2326             val delete_rule : 'a Entry.t -> delete_statment -> unit
2327               
2328             val srules :
2329               'a Entry.t -> ((symbol list) * Action.t) list -> symbol
2330               
2331             val sfold0 : ('a -> 'b -> 'b) -> 'b -> (_, 'a, 'b) fold
2332               
2333             val sfold1 : ('a -> 'b -> 'b) -> 'b -> (_, 'a, 'b) fold
2334               
2335             val sfold0sep : ('a -> 'b -> 'b) -> 'b -> (_, 'a, 'b) foldsep
2336               
2337             val lex :
2338               Loc.t ->
2339                 char Stream.t -> ((Token.t * Loc.t) Stream.t) not_filtered
2340               
2341             val lex_string :
2342               Loc.t -> string -> ((Token.t * Loc.t) Stream.t) not_filtered
2343               
2344             val filter :
2345               ((Token.t * Loc.t) Stream.t) not_filtered ->
2346                 (Token.t * Loc.t) Stream.t
2347               
2348             val parse : 'a Entry.t -> Loc.t -> char Stream.t -> 'a
2349               
2350             val parse_string : 'a Entry.t -> Loc.t -> string -> 'a
2351               
2352             val parse_tokens_before_filter :
2353               'a Entry.t -> ((Token.t * Loc.t) Stream.t) not_filtered -> 'a
2354               
2355             val parse_tokens_after_filter :
2356               'a Entry.t -> (Token.t * Loc.t) Stream.t -> 'a
2357               
2358           end
2359           
2360       end
2361       
2362     module type Lexer =
2363       sig
2364         module Loc : Loc
2365           
2366         module Token : Token with module Loc = Loc
2367           
2368         module Error : Error
2369           
2370         val mk : unit -> Loc.t -> char Stream.t -> (Token.t * Loc.t) Stream.t
2371           
2372       end
2373       
2374     module Parser (Ast : Ast) =
2375       struct
2376         module type SIMPLE =
2377           sig
2378             val parse_expr : Ast.loc -> string -> Ast.expr
2379               
2380             val parse_patt : Ast.loc -> string -> Ast.patt
2381               
2382           end
2383           
2384         module type S =
2385           sig
2386             val parse_implem :
2387               ?directive_handler: (Ast.str_item -> Ast.str_item option) ->
2388                 Ast.loc -> char Stream.t -> Ast.str_item
2389               
2390             val parse_interf :
2391               ?directive_handler: (Ast.sig_item -> Ast.sig_item option) ->
2392                 Ast.loc -> char Stream.t -> Ast.sig_item
2393               
2394           end
2395           
2396       end
2397       
2398     module Printer (Ast : Ast) =
2399       struct
2400         module type S =
2401           sig
2402             val print_interf :
2403               ?input_file: string ->
2404                 ?output_file: string -> Ast.sig_item -> unit
2405               
2406             val print_implem :
2407               ?input_file: string ->
2408                 ?output_file: string -> Ast.str_item -> unit
2409               
2410           end
2411           
2412       end
2413       
2414     module type Syntax =
2415       sig
2416         module Loc : Loc
2417           
2418         module Ast : Ast with type loc = Loc.t
2419           
2420         module Token : Token with module Loc = Loc
2421           
2422         module Gram : Grammar.Static with module Loc = Loc
2423           and module Token = Token
2424           
2425         module Quotation : Quotation with module Ast = Ast
2426           
2427         module AntiquotSyntax : Parser(Ast).SIMPLE
2428           
2429         include Warning(Loc).S
2430           
2431         include Parser(Ast).S
2432           
2433         include Printer(Ast).S
2434           
2435       end
2436       
2437     module type Camlp4Syntax =
2438       sig
2439         module Loc : Loc
2440           
2441         module Ast : Camlp4Ast with module Loc = Loc
2442           
2443         module Token : Camlp4Token with module Loc = Loc
2444           
2445         module Gram : Grammar.Static with module Loc = Loc
2446           and module Token = Token
2447           
2448         module Quotation : Quotation with module Ast = Camlp4AstToAst(Ast)
2449           
2450         module AntiquotSyntax : Parser(Ast).SIMPLE
2451           
2452         include Warning(Loc).S
2453           
2454         include Parser(Ast).S
2455           
2456         include Printer(Ast).S
2457           
2458         val interf : ((Ast.sig_item list) * (Loc.t option)) Gram.Entry.t
2459           
2460         val implem : ((Ast.str_item list) * (Loc.t option)) Gram.Entry.t
2461           
2462         val top_phrase : (Ast.str_item option) Gram.Entry.t
2463           
2464         val use_file : ((Ast.str_item list) * (Loc.t option)) Gram.Entry.t
2465           
2466         val a_CHAR : string Gram.Entry.t
2467           
2468         val a_FLOAT : string Gram.Entry.t
2469           
2470         val a_INT : string Gram.Entry.t
2471           
2472         val a_INT32 : string Gram.Entry.t
2473           
2474         val a_INT64 : string Gram.Entry.t
2475           
2476         val a_LABEL : string Gram.Entry.t
2477           
2478         val a_LIDENT : string Gram.Entry.t
2479           
2480         val a_NATIVEINT : string Gram.Entry.t
2481           
2482         val a_OPTLABEL : string Gram.Entry.t
2483           
2484         val a_STRING : string Gram.Entry.t
2485           
2486         val a_UIDENT : string Gram.Entry.t
2487           
2488         val a_ident : string Gram.Entry.t
2489           
2490         val amp_ctyp : Ast.ctyp Gram.Entry.t
2491           
2492         val and_ctyp : Ast.ctyp Gram.Entry.t
2493           
2494         val match_case : Ast.match_case Gram.Entry.t
2495           
2496         val match_case0 : Ast.match_case Gram.Entry.t
2497           
2498         val match_case_quot : Ast.match_case Gram.Entry.t
2499           
2500         val binding : Ast.binding Gram.Entry.t
2501           
2502         val binding_quot : Ast.binding Gram.Entry.t
2503           
2504         val rec_binding_quot : Ast.rec_binding Gram.Entry.t
2505           
2506         val class_declaration : Ast.class_expr Gram.Entry.t
2507           
2508         val class_description : Ast.class_type Gram.Entry.t
2509           
2510         val class_expr : Ast.class_expr Gram.Entry.t
2511           
2512         val class_expr_quot : Ast.class_expr Gram.Entry.t
2513           
2514         val class_fun_binding : Ast.class_expr Gram.Entry.t
2515           
2516         val class_fun_def : Ast.class_expr Gram.Entry.t
2517           
2518         val class_info_for_class_expr : Ast.class_expr Gram.Entry.t
2519           
2520         val class_info_for_class_type : Ast.class_type Gram.Entry.t
2521           
2522         val class_longident : Ast.ident Gram.Entry.t
2523           
2524         val class_longident_and_param : Ast.class_expr Gram.Entry.t
2525           
2526         val class_name_and_param : (string * Ast.ctyp) Gram.Entry.t
2527           
2528         val class_sig_item : Ast.class_sig_item Gram.Entry.t
2529           
2530         val class_sig_item_quot : Ast.class_sig_item Gram.Entry.t
2531           
2532         val class_signature : Ast.class_sig_item Gram.Entry.t
2533           
2534         val class_str_item : Ast.class_str_item Gram.Entry.t
2535           
2536         val class_str_item_quot : Ast.class_str_item Gram.Entry.t
2537           
2538         val class_structure : Ast.class_str_item Gram.Entry.t
2539           
2540         val class_type : Ast.class_type Gram.Entry.t
2541           
2542         val class_type_declaration : Ast.class_type Gram.Entry.t
2543           
2544         val class_type_longident : Ast.ident Gram.Entry.t
2545           
2546         val class_type_longident_and_param : Ast.class_type Gram.Entry.t
2547           
2548         val class_type_plus : Ast.class_type Gram.Entry.t
2549           
2550         val class_type_quot : Ast.class_type Gram.Entry.t
2551           
2552         val comma_ctyp : Ast.ctyp Gram.Entry.t
2553           
2554         val comma_expr : Ast.expr Gram.Entry.t
2555           
2556         val comma_ipatt : Ast.patt Gram.Entry.t
2557           
2558         val comma_patt : Ast.patt Gram.Entry.t
2559           
2560         val comma_type_parameter : Ast.ctyp Gram.Entry.t
2561           
2562         val constrain : (Ast.ctyp * Ast.ctyp) Gram.Entry.t
2563           
2564         val constructor_arg_list : Ast.ctyp Gram.Entry.t
2565           
2566         val constructor_declaration : Ast.ctyp Gram.Entry.t
2567           
2568         val constructor_declarations : Ast.ctyp Gram.Entry.t
2569           
2570         val ctyp : Ast.ctyp Gram.Entry.t
2571           
2572         val ctyp_quot : Ast.ctyp Gram.Entry.t
2573           
2574         val cvalue_binding : Ast.expr Gram.Entry.t
2575           
2576         val direction_flag : Ast.meta_bool Gram.Entry.t
2577           
2578         val dummy : unit Gram.Entry.t
2579           
2580         val eq_expr : (string -> Ast.patt -> Ast.patt) Gram.Entry.t
2581           
2582         val expr : Ast.expr Gram.Entry.t
2583           
2584         val expr_eoi : Ast.expr Gram.Entry.t
2585           
2586         val expr_quot : Ast.expr Gram.Entry.t
2587           
2588         val field_expr : Ast.rec_binding Gram.Entry.t
2589           
2590         val field_expr_list : Ast.rec_binding Gram.Entry.t
2591           
2592         val fun_binding : Ast.expr Gram.Entry.t
2593           
2594         val fun_def : Ast.expr Gram.Entry.t
2595           
2596         val ident : Ast.ident Gram.Entry.t
2597           
2598         val ident_quot : Ast.ident Gram.Entry.t
2599           
2600         val ipatt : Ast.patt Gram.Entry.t
2601           
2602         val ipatt_tcon : Ast.patt Gram.Entry.t
2603           
2604         val label : string Gram.Entry.t
2605           
2606         val label_declaration : Ast.ctyp Gram.Entry.t
2607           
2608         val label_declaration_list : Ast.ctyp Gram.Entry.t
2609           
2610         val label_expr : Ast.rec_binding Gram.Entry.t
2611           
2612         val label_expr_list : Ast.rec_binding Gram.Entry.t
2613           
2614         val label_ipatt : Ast.patt Gram.Entry.t
2615           
2616         val label_ipatt_list : Ast.patt Gram.Entry.t
2617           
2618         val label_longident : Ast.ident Gram.Entry.t
2619           
2620         val label_patt : Ast.patt Gram.Entry.t
2621           
2622         val label_patt_list : Ast.patt Gram.Entry.t
2623           
2624         val labeled_ipatt : Ast.patt Gram.Entry.t
2625           
2626         val let_binding : Ast.binding Gram.Entry.t
2627           
2628         val meth_list : (Ast.ctyp * Ast.meta_bool) Gram.Entry.t
2629           
2630         val meth_decl : Ast.ctyp Gram.Entry.t
2631           
2632         val module_binding : Ast.module_binding Gram.Entry.t
2633           
2634         val module_binding0 : Ast.module_expr Gram.Entry.t
2635           
2636         val module_binding_quot : Ast.module_binding Gram.Entry.t
2637           
2638         val module_declaration : Ast.module_type Gram.Entry.t
2639           
2640         val module_expr : Ast.module_expr Gram.Entry.t
2641           
2642         val module_expr_quot : Ast.module_expr Gram.Entry.t
2643           
2644         val module_longident : Ast.ident Gram.Entry.t
2645           
2646         val module_longident_with_app : Ast.ident Gram.Entry.t
2647           
2648         val module_rec_declaration : Ast.module_binding Gram.Entry.t
2649           
2650         val module_type : Ast.module_type Gram.Entry.t
2651           
2652         val module_type_quot : Ast.module_type Gram.Entry.t
2653           
2654         val more_ctyp : Ast.ctyp Gram.Entry.t
2655           
2656         val name_tags : Ast.ctyp Gram.Entry.t
2657           
2658         val opt_as_lident : string Gram.Entry.t
2659           
2660         val opt_class_self_patt : Ast.patt Gram.Entry.t
2661           
2662         val opt_class_self_type : Ast.ctyp Gram.Entry.t
2663           
2664         val opt_comma_ctyp : Ast.ctyp Gram.Entry.t
2665           
2666         val opt_dot_dot : Ast.meta_bool Gram.Entry.t
2667           
2668         val opt_eq_ctyp : Ast.ctyp Gram.Entry.t
2669           
2670         val opt_expr : Ast.expr Gram.Entry.t
2671           
2672         val opt_meth_list : Ast.ctyp Gram.Entry.t
2673           
2674         val opt_mutable : Ast.meta_bool Gram.Entry.t
2675           
2676         val opt_polyt : Ast.ctyp Gram.Entry.t
2677           
2678         val opt_private : Ast.meta_bool Gram.Entry.t
2679           
2680         val opt_rec : Ast.meta_bool Gram.Entry.t
2681           
2682         val opt_virtual : Ast.meta_bool Gram.Entry.t
2683           
2684         val opt_when_expr : Ast.expr Gram.Entry.t
2685           
2686         val patt : Ast.patt Gram.Entry.t
2687           
2688         val patt_as_patt_opt : Ast.patt Gram.Entry.t
2689           
2690         val patt_eoi : Ast.patt Gram.Entry.t
2691           
2692         val patt_quot : Ast.patt Gram.Entry.t
2693           
2694         val patt_tcon : Ast.patt Gram.Entry.t
2695           
2696         val phrase : Ast.str_item Gram.Entry.t
2697           
2698         val poly_type : Ast.ctyp Gram.Entry.t
2699           
2700         val row_field : Ast.ctyp Gram.Entry.t
2701           
2702         val sem_expr : Ast.expr Gram.Entry.t
2703           
2704         val sem_expr_for_list : (Ast.expr -> Ast.expr) Gram.Entry.t
2705           
2706         val sem_patt : Ast.patt Gram.Entry.t
2707           
2708         val sem_patt_for_list : (Ast.patt -> Ast.patt) Gram.Entry.t
2709           
2710         val semi : unit Gram.Entry.t
2711           
2712         val sequence : Ast.expr Gram.Entry.t
2713           
2714         val do_sequence : Ast.expr Gram.Entry.t
2715           
2716         val sig_item : Ast.sig_item Gram.Entry.t
2717           
2718         val sig_item_quot : Ast.sig_item Gram.Entry.t
2719           
2720         val sig_items : Ast.sig_item Gram.Entry.t
2721           
2722         val star_ctyp : Ast.ctyp Gram.Entry.t
2723           
2724         val str_item : Ast.str_item Gram.Entry.t
2725           
2726         val str_item_quot : Ast.str_item Gram.Entry.t
2727           
2728         val str_items : Ast.str_item Gram.Entry.t
2729           
2730         val type_constraint : unit Gram.Entry.t
2731           
2732         val type_declaration : Ast.ctyp Gram.Entry.t
2733           
2734         val type_ident_and_parameters :
2735           (string * (Ast.ctyp list)) Gram.Entry.t
2736           
2737         val type_kind : Ast.ctyp Gram.Entry.t
2738           
2739         val type_longident : Ast.ident Gram.Entry.t
2740           
2741         val type_longident_and_parameters : Ast.ctyp Gram.Entry.t
2742           
2743         val type_parameter : Ast.ctyp Gram.Entry.t
2744           
2745         val type_parameters : (Ast.ctyp -> Ast.ctyp) Gram.Entry.t
2746           
2747         val typevars : Ast.ctyp Gram.Entry.t
2748           
2749         val val_longident : Ast.ident Gram.Entry.t
2750           
2751         val value_let : unit Gram.Entry.t
2752           
2753         val value_val : unit Gram.Entry.t
2754           
2755         val with_constr : Ast.with_constr Gram.Entry.t
2756           
2757         val with_constr_quot : Ast.with_constr Gram.Entry.t
2758           
2759         val prefixop : Ast.expr Gram.Entry.t
2760           
2761         val infixop0 : Ast.expr Gram.Entry.t
2762           
2763         val infixop1 : Ast.expr Gram.Entry.t
2764           
2765         val infixop2 : Ast.expr Gram.Entry.t
2766           
2767         val infixop3 : Ast.expr Gram.Entry.t
2768           
2769         val infixop4 : Ast.expr Gram.Entry.t
2770           
2771       end
2772       
2773     module type SyntaxExtension =
2774       functor (Syn : Syntax) -> Syntax with module Loc = Syn.Loc
2775         and module Ast = Syn.Ast and module Token = Syn.Token
2776         and module Gram = Syn.Gram and module Quotation = Syn.Quotation
2777       
2778   end
2779   
2780 module ErrorHandler :
2781   sig
2782     val print : Format.formatter -> exn -> unit
2783       
2784     val try_print : Format.formatter -> exn -> unit
2785       
2786     val to_string : exn -> string
2787       
2788     val try_to_string : exn -> string
2789       
2790     val register : (Format.formatter -> exn -> unit) -> unit
2791       
2792     module Register (Error : Sig.Error) : sig  end
2793       
2794     module ObjTools :
2795       sig
2796         val print : Format.formatter -> Obj.t -> unit
2797           
2798         val print_desc : Format.formatter -> Obj.t -> unit
2799           
2800         val to_string : Obj.t -> string
2801           
2802         val desc : Obj.t -> string
2803           
2804       end
2805       
2806   end =
2807   struct
2808     open Format
2809       
2810     module ObjTools =
2811       struct
2812         let desc obj =
2813           if Obj.is_block obj
2814           then "tag = " ^ (string_of_int (Obj.tag obj))
2815           else "int_val = " ^ (string_of_int (Obj.obj obj))
2816           
2817         let rec to_string r =
2818           if Obj.is_int r
2819           then
2820             (let i : int = Obj.magic r
2821              in (string_of_int i) ^ (" | CstTag" ^ (string_of_int (i + 1))))
2822           else
2823             (let rec get_fields acc =
2824                function
2825                | 0 -> acc
2826                | n -> let n = n - 1 in get_fields ((Obj.field r n) :: acc) n in
2827              let rec is_list r =
2828                if Obj.is_int r
2829                then r = (Obj.repr 0)
2830                else
2831                  (let s = Obj.size r
2832                   and t = Obj.tag r
2833                   in (t = 0) && ((s = 2) && (is_list (Obj.field r 1)))) in
2834              let rec get_list r =
2835                if Obj.is_int r
2836                then []
2837                else
2838                  (let h = Obj.field r 0
2839                   and t = get_list (Obj.field r 1)
2840                   in h :: t) in
2841              let opaque name = "<" ^ (name ^ ">") in
2842              let s = Obj.size r
2843              and t = Obj.tag r
2844              in
2845                match t with
2846                | _ when is_list r ->
2847                    let fields = get_list r
2848                    in
2849                      "[" ^
2850                        ((String.concat "; " (List.map to_string fields)) ^
2851                           "]")
2852                | 0 ->
2853                    let fields = get_fields [] s
2854                    in
2855                      "(" ^
2856                        ((String.concat ", " (List.map to_string fields)) ^
2857                           ")")
2858                | x when x = Obj.lazy_tag -> opaque "lazy"
2859                | x when x = Obj.closure_tag -> opaque "closure"
2860                | x when x = Obj.object_tag ->
2861                    let fields = get_fields [] s in
2862                    let (_class, id, slots) =
2863                      (match fields with
2864                       | h :: h' :: t -> (h, h', t)
2865                       | _ -> assert false)
2866                    in
2867                      "Object #" ^
2868                        ((to_string id) ^
2869                           (" (" ^
2870                              ((String.concat ", " (List.map to_string slots))
2871                                 ^ ")")))
2872                | x when x = Obj.infix_tag -> opaque "infix"
2873                | x when x = Obj.forward_tag -> opaque "forward"
2874                | x when x < Obj.no_scan_tag ->
2875                    let fields = get_fields [] s
2876                    in
2877                      "Tag" ^
2878                        ((string_of_int t) ^
2879                           (" (" ^
2880                              ((String.concat ", " (List.map to_string fields))
2881                                 ^ ")")))
2882                | x when x = Obj.string_tag ->
2883                    "\"" ^ ((String.escaped (Obj.magic r : string)) ^ "\"")
2884                | x when x = Obj.double_tag ->
2885                    string_of_float (Obj.magic r : float)
2886                | x when x = Obj.abstract_tag -> opaque "abstract"
2887                | x when x = Obj.custom_tag -> opaque "custom"
2888                | x when x = Obj.final_tag -> opaque "final"
2889                | _ ->
2890                    failwith
2891                      ("ObjTools.to_string: unknown tag (" ^
2892                         ((string_of_int t) ^ ")")))
2893           
2894         let print ppf x = fprintf ppf "%s" (to_string x)
2895           
2896         let print_desc ppf x = fprintf ppf "%s" (desc x)
2897           
2898       end
2899       
2900     let default_handler ppf x =
2901       let x = Obj.repr x
2902       in
2903         (fprintf ppf "Camlp4: Uncaught exception: %s"
2904            (Obj.obj (Obj.field (Obj.field x 0) 0) : string);
2905          if (Obj.size x) > 1
2906          then
2907            (pp_print_string ppf " (";
2908             for i = 1 to (Obj.size x) - 1 do
2909               if i > 1 then pp_print_string ppf ", " else ();
2910               ObjTools.print ppf (Obj.field x i)
2911             done;
2912             pp_print_char ppf ')')
2913          else ();
2914          fprintf ppf "@.")
2915       
2916     let handler =
2917       ref (fun ppf default_handler exn -> default_handler ppf exn)
2918       
2919     let register f =
2920       let current_handler = !handler
2921       in
2922         handler :=
2923           fun ppf default_handler exn ->
2924             try f ppf exn
2925             with | exn -> current_handler ppf default_handler exn
2926       
2927     module Register (Error : Sig.Error) =
2928       struct
2929         let _ =
2930           let current_handler = !handler
2931           in
2932             handler :=
2933               fun ppf default_handler ->
2934                 function
2935                 | Error.E x -> Error.print ppf x
2936                 | x -> current_handler ppf default_handler x
2937           
2938       end
2939       
2940     let gen_print ppf default_handler =
2941       function
2942       | Out_of_memory -> fprintf ppf "Out of memory"
2943       | Assert_failure ((file, line, char)) ->
2944           fprintf ppf "Assertion failed, file %S, line %d, char %d" file line
2945             char
2946       | Match_failure ((file, line, char)) ->
2947           fprintf ppf "Pattern matching failed, file %S, line %d, char %d"
2948             file line char
2949       | Failure str -> fprintf ppf "Failure: %S" str
2950       | Invalid_argument str -> fprintf ppf "Invalid argument: %S" str
2951       | Sys_error str -> fprintf ppf "I/O error: %S" str
2952       | Stream.Failure -> fprintf ppf "Parse failure"
2953       | Stream.Error str -> fprintf ppf "Parse error: %s" str
2954       | x -> !handler ppf default_handler x
2955       
2956     let print ppf = gen_print ppf default_handler
2957       
2958     let try_print ppf = gen_print ppf (fun _ -> raise)
2959       
2960     let to_string exn =
2961       let buf = Buffer.create 128 in
2962       let () = bprintf buf "%a" print exn in Buffer.contents buf
2963       
2964     let try_to_string exn =
2965       let buf = Buffer.create 128 in
2966       let () = bprintf buf "%a" try_print exn in Buffer.contents buf
2967       
2968   end
2969   
2970 module Struct =
2971   struct
2972     module Loc : sig include Sig.Loc
2973                         end =
2974       struct
2975         open Format
2976           
2977         type pos = { line : int; bol : int; off : int }
2978         
2979         type t =
2980           { file_name : string; start : pos; stop : pos; ghost : bool
2981           }
2982         
2983         let dump_sel f x =
2984           let s =
2985             match x with
2986             | `start -> "`start"
2987             | `stop -> "`stop"
2988             | `both -> "`both"
2989             | _ -> "<not-printable>"
2990           in pp_print_string f s
2991           
2992         let dump_pos f x =
2993           fprintf f "@[<hov 2>{ line = %d ;@ bol = %d ;@ off = %d } : pos@]"
2994             x.line x.bol x.off
2995           
2996         let dump_long f x =
2997           fprintf f
2998             "@[<hov 2>{ file_name = %s ;@ start = %a (%d-%d);@ stop = %a (%d);@ ghost = %b@ } : Loc.t@]"
2999             x.file_name dump_pos x.start (x.start.off - x.start.bol)
3000             (x.stop.off - x.start.bol) dump_pos x.stop
3001             (x.stop.off - x.stop.bol) x.ghost
3002           
3003         let dump f x =
3004           fprintf f "[%S: %d:%d-%d %d:%d%t]" x.file_name x.start.line
3005             (x.start.off - x.start.bol) (x.stop.off - x.start.bol)
3006             x.stop.line (x.stop.off - x.stop.bol)
3007             (fun o -> if x.ghost then fprintf o " (ghost)" else ())
3008           
3009         let start_pos = { line = 1; bol = 0; off = 0; }
3010           
3011         let ghost =
3012           {
3013             file_name = "ghost-location";
3014             start = start_pos;
3015             stop = start_pos;
3016             ghost = true;
3017           }
3018           
3019         let mk file_name =
3020           {
3021             file_name = file_name;
3022             start = start_pos;
3023             stop = start_pos;
3024             ghost = false;
3025           }
3026           
3027         let of_tuple (file_name, start_line, start_bol, start_off, stop_line,
3028                       stop_bol, stop_off, ghost)
3029                      =
3030           {
3031             file_name = file_name;
3032             start = { line = start_line; bol = start_bol; off = start_off; };
3033             stop = { line = stop_line; bol = stop_bol; off = stop_off; };
3034             ghost = ghost;
3035           }
3036           
3037         let to_tuple {
3038                        file_name = file_name;
3039                        start =
3040                          {
3041                            line = start_line;
3042                            bol = start_bol;
3043                            off = start_off
3044                          };
3045                        stop =
3046                          { line = stop_line; bol = stop_bol; off = stop_off };
3047                        ghost = ghost
3048                      } =
3049           (file_name, start_line, start_bol, start_off, stop_line, stop_bol,
3050            stop_off, ghost)
3051           
3052         let pos_of_lexing_position p =
3053           let pos =
3054             {
3055               line = p.Lexing.pos_lnum;
3056               bol = p.Lexing.pos_bol;
3057               off = p.Lexing.pos_cnum;
3058             }
3059           in pos
3060           
3061         let pos_to_lexing_position p file_name =
3062           {
3063             Lexing.pos_fname = file_name;
3064             pos_lnum = p.line;
3065             pos_bol = p.bol;
3066             pos_cnum = p.off;
3067           }
3068           
3069         let better_file_name a b =
3070           match (a, b) with
3071           | ("", "") -> a
3072           | ("", x) -> x
3073           | (x, "") -> x
3074           | ("-", x) -> x
3075           | (x, "-") -> x
3076           | (x, _) -> x
3077           
3078         let of_lexbuf lb =
3079           let start = Lexing.lexeme_start_p lb
3080           and stop = Lexing.lexeme_end_p lb in
3081           let loc =
3082             {
3083               file_name =
3084                 better_file_name start.Lexing.pos_fname stop.Lexing.pos_fname;
3085               start = pos_of_lexing_position start;
3086               stop = pos_of_lexing_position stop;
3087               ghost = false;
3088             }
3089           in loc
3090           
3091         let of_lexing_position pos =
3092           let loc =
3093             {
3094               file_name = pos.Lexing.pos_fname;
3095               start = pos_of_lexing_position pos;
3096               stop = pos_of_lexing_position pos;
3097               ghost = false;
3098             }
3099           in loc
3100           
3101         let to_ocaml_location x =
3102           {
3103             Camlp4_import.Location.loc_start =
3104               pos_to_lexing_position x.start x.file_name;
3105             loc_end = pos_to_lexing_position x.stop x.file_name;
3106             loc_ghost = x.ghost;
3107           }
3108           
3109         let of_ocaml_location {
3110                                 Camlp4_import.Location.loc_start = a;
3111                                 loc_end = b;
3112                                 loc_ghost = g
3113                               } =
3114           let res =
3115             {
3116               file_name =
3117                 better_file_name a.Lexing.pos_fname b.Lexing.pos_fname;
3118               start = pos_of_lexing_position a;
3119               stop = pos_of_lexing_position b;
3120               ghost = g;
3121             }
3122           in res
3123           
3124         let start_pos x = pos_to_lexing_position x.start x.file_name
3125           
3126         let stop_pos x = pos_to_lexing_position x.stop x.file_name
3127           
3128         let merge a b =
3129           if a == b
3130           then a
3131           else
3132             (let r =
3133                match ((a.ghost), (b.ghost)) with
3134                | (false, false) -> { (a) with stop = b.stop; }
3135                | (true, true) -> { (a) with stop = b.stop; }
3136                | (true, _) -> { (a) with stop = b.stop; }
3137                | (_, true) -> { (b) with start = a.start; }
3138              in r)
3139           
3140         let join x = { (x) with stop = x.start; }
3141           
3142         let map f start_stop_both x =
3143           match start_stop_both with
3144           | `start -> { (x) with start = f x.start; }
3145           | `stop -> { (x) with stop = f x.stop; }
3146           | `both -> { (x) with start = f x.start; stop = f x.stop; }
3147           
3148         let move_pos chars x = { (x) with off = x.off + chars; }
3149           
3150         let move s chars x = map (move_pos chars) s x
3151           
3152         let move_line lines x =
3153           let move_line_pos x =
3154             { (x) with line = x.line + lines; bol = x.off; }
3155           in map move_line_pos `both x
3156           
3157         let shift width x =
3158           { (x) with start = x.stop; stop = move_pos width x.stop; }
3159           
3160         let file_name x = x.file_name
3161           
3162         let start_line x = x.start.line
3163           
3164         let stop_line x = x.stop.line
3165           
3166         let start_bol x = x.start.bol
3167           
3168         let stop_bol x = x.stop.bol
3169           
3170         let start_off x = x.start.off
3171           
3172         let stop_off x = x.stop.off
3173           
3174         let is_ghost x = x.ghost
3175           
3176         let set_file_name s x = { (x) with file_name = s; }
3177           
3178         let ghostify x = { (x) with ghost = true; }
3179           
3180         let make_absolute x =
3181           let pwd = Sys.getcwd ()
3182           in
3183             if Filename.is_relative x.file_name
3184             then { (x) with file_name = Filename.concat pwd x.file_name; }
3185             else x
3186           
3187         let strictly_before x y =
3188           let b = (x.stop.off < y.start.off) && (x.file_name = y.file_name)
3189           in b
3190           
3191         let to_string x =
3192           let (a, b) = ((x.start), (x.stop)) in
3193           let res =
3194             sprintf "File \"%s\", line %d, characters %d-%d" x.file_name
3195               a.line (a.off - a.bol) (b.off - a.bol)
3196           in
3197             if x.start.line <> x.stop.line
3198             then
3199               sprintf "%s (end at line %d, character %d)" res x.stop.line
3200                 (b.off - b.bol)
3201             else res
3202           
3203         let print out x = pp_print_string out (to_string x)
3204           
3205         let check x msg =
3206           if
3207             ((start_line x) > (stop_line x)) ||
3208               (((start_bol x) > (stop_bol x)) ||
3209                  (((start_off x) > (stop_off x)) ||
3210                     (((start_line x) < 0) ||
3211                        (((stop_line x) < 0) ||
3212                           (((start_bol x) < 0) ||
3213                              (((stop_bol x) < 0) ||
3214                                 (((start_off x) < 0) || ((stop_off x) < 0))))))))
3215           then
3216             (eprintf "*** Warning: (%s) strange positions ***\n%a@\n" msg
3217                print x;
3218              false)
3219           else true
3220           
3221         exception Exc_located of t * exn
3222           
3223         let _ =
3224           ErrorHandler.register
3225             (fun ppf ->
3226                function
3227                | Exc_located (loc, exn) ->
3228                    fprintf ppf "%a:@\n%a" print loc ErrorHandler.print exn
3229                | exn -> raise exn)
3230           
3231         let name = ref "_loc"
3232           
3233         let raise loc exc =
3234           match exc with
3235           | Exc_located (_, _) -> raise exc
3236           | _ -> raise (Exc_located (loc, exc))
3237           
3238       end
3239       
3240     module Token :
3241       sig
3242         module Make (Loc : Sig.Loc) : Sig.Camlp4Token with module Loc = Loc
3243           
3244         module Eval :
3245           sig
3246             val char : string -> char
3247               
3248             val string : ?strict: unit -> string -> string
3249               
3250           end
3251           
3252       end =
3253       struct
3254         open Format
3255           
3256         module Make (Loc : Sig.Loc) : Sig.Camlp4Token with module Loc = Loc =
3257           struct
3258             module Loc = Loc
3259               
3260             open Sig
3261               
3262             type t = camlp4_token
3263             
3264             type token = t
3265             
3266             let to_string =
3267               function
3268               | KEYWORD s -> sprintf "KEYWORD %S" s
3269               | SYMBOL s -> sprintf "SYMBOL %S" s
3270               | LIDENT s -> sprintf "LIDENT %S" s
3271               | UIDENT s -> sprintf "UIDENT %S" s
3272               | INT (_, s) -> sprintf "INT %s" s
3273               | INT32 (_, s) -> sprintf "INT32 %sd" s
3274               | INT64 (_, s) -> sprintf "INT64 %sd" s
3275               | NATIVEINT (_, s) -> sprintf "NATIVEINT %sd" s
3276               | FLOAT (_, s) -> sprintf "FLOAT %s" s
3277               | CHAR (_, s) -> sprintf "CHAR '%s'" s
3278               | STRING (_, s) -> sprintf "STRING \"%s\"" s
3279               | LABEL s -> sprintf "LABEL %S" s
3280               | OPTLABEL s -> sprintf "OPTLABEL %S" s
3281               | ANTIQUOT (n, s) -> sprintf "ANTIQUOT %s: %S" n s
3282               | QUOTATION x ->
3283                   sprintf
3284                     "QUOTATION { q_name=%S; q_loc=%S; q_shift=%d; q_contents=%S }"
3285                     x.q_name x.q_loc x.q_shift x.q_contents
3286               | COMMENT s -> sprintf "COMMENT %S" s
3287               | BLANKS s -> sprintf "BLANKS %S" s
3288               | NEWLINE -> sprintf "NEWLINE"
3289               | EOI -> sprintf "EOI"
3290               | ESCAPED_IDENT s -> sprintf "ESCAPED_IDENT %S" s
3291               | LINE_DIRECTIVE (i, None) -> sprintf "LINE_DIRECTIVE %d" i
3292               | LINE_DIRECTIVE (i, (Some s)) ->
3293                   sprintf "LINE_DIRECTIVE %d %S" i s
3294               
3295             let print ppf x = pp_print_string ppf (to_string x)
3296               
3297             let match_keyword kwd =
3298               function | KEYWORD kwd' when kwd = kwd' -> true | _ -> false
3299               
3300             let extract_string =
3301               function
3302               | KEYWORD s | SYMBOL s | LIDENT s | UIDENT s | INT (_, s) |
3303                   INT32 (_, s) | INT64 (_, s) | NATIVEINT (_, s) |
3304                   FLOAT (_, s) | CHAR (_, s) | STRING (_, s) | LABEL s |
3305                   OPTLABEL s | COMMENT s | BLANKS s | ESCAPED_IDENT s -> s
3306               | tok ->
3307                   invalid_arg
3308                     ("Cannot extract a string from this token: " ^
3309                        (to_string tok))
3310               
3311             module Error =
3312               struct
3313                 type t =
3314                   | Illegal_token of string
3315                   | Keyword_as_label of string
3316                   | Illegal_token_pattern of string * string
3317                   | Illegal_constructor of string
3318                 
3319                 exception E of t
3320                   
3321                 let print ppf =
3322                   function
3323                   | Illegal_token s -> fprintf ppf "Illegal token (%s)" s
3324                   | Keyword_as_label kwd ->
3325                       fprintf ppf
3326                         "`%s' is a keyword, it cannot be used as label name"
3327                         kwd
3328                   | Illegal_token_pattern (p_con, p_prm) ->
3329                       fprintf ppf "Illegal token pattern: %s %S" p_con p_prm
3330                   | Illegal_constructor con ->
3331                       fprintf ppf "Illegal constructor %S" con
3332                   
3333                 let to_string x =
3334                   let b = Buffer.create 50 in
3335                   let () = bprintf b "%a" print x in Buffer.contents b
3336                   
3337               end
3338               
3339             let _ = let module M = ErrorHandler.Register(Error) in ()
3340               
3341             module Filter =
3342               struct
3343                 type token_filter = (t, Loc.t) stream_filter
3344                 
3345                 type t =
3346                   { is_kwd : string -> bool; mutable filter : token_filter
3347                   }
3348                 
3349                 let err error loc =
3350                   raise (Loc.Exc_located (loc, Error.E error))
3351                   
3352                 let keyword_conversion tok is_kwd =
3353                   match tok with
3354                   | SYMBOL s | LIDENT s | UIDENT s when is_kwd s -> KEYWORD s
3355                   | ESCAPED_IDENT s -> LIDENT s
3356                   | _ -> tok
3357                   
3358                 let check_keyword_as_label tok loc is_kwd =
3359                   let s =
3360                     match tok with | LABEL s -> s | OPTLABEL s -> s | _ -> ""
3361                   in
3362                     if (s <> "") && (is_kwd s)
3363                     then err (Error.Keyword_as_label s) loc
3364                     else ()
3365                   
3366                 let check_unknown_keywords tok loc =
3367                   match tok with
3368                   | SYMBOL s -> err (Error.Illegal_token s) loc
3369                   | _ -> ()
3370                   
3371                 let error_no_respect_rules p_con p_prm =
3372                   raise
3373                     (Error.E (Error.Illegal_token_pattern (p_con, p_prm)))
3374                   
3375                 let check_keyword _ = true
3376                   
3377                 let error_on_unknown_keywords = ref false
3378                   
3379                 let rec ignore_layout (__strm : _ Stream.t) =
3380                   match Stream.peek __strm with
3381                   | Some
3382                       (((COMMENT _ | BLANKS _ | NEWLINE |
3383                            LINE_DIRECTIVE (_, _)),
3384                         _))
3385                       -> (Stream.junk __strm; ignore_layout __strm)
3386                   | Some x ->
3387                       (Stream.junk __strm;
3388                        let s = __strm
3389                        in
3390                          Stream.icons x
3391                            (Stream.slazy (fun _ -> ignore_layout s)))
3392                   | _ -> Stream.sempty
3393                   
3394                 let mk is_kwd = { is_kwd = is_kwd; filter = ignore_layout; }
3395                   
3396                 let filter x =
3397                   let f tok loc =
3398                     let tok = keyword_conversion tok x.is_kwd
3399                     in
3400                       (check_keyword_as_label tok loc x.is_kwd;
3401                        if !error_on_unknown_keywords
3402                        then check_unknown_keywords tok loc
3403                        else ();
3404                        (tok, loc)) in
3405                   let rec filter (__strm : _ Stream.t) =
3406                     match Stream.peek __strm with
3407                     | Some ((tok, loc)) ->
3408                         (Stream.junk __strm;
3409                          let s = __strm
3410                          in
3411                            Stream.lcons (fun _ -> f tok loc)
3412                              (Stream.slazy (fun _ -> filter s)))
3413                     | _ -> Stream.sempty in
3414                   let rec tracer (__strm : _ Stream.t) =
3415                     match Stream.peek __strm with
3416                     | Some (((_tok, _loc) as x)) ->
3417                         (Stream.junk __strm;
3418                          let xs = __strm
3419                          in
3420                            Stream.icons x (Stream.slazy (fun _ -> tracer xs)))
3421                     | _ -> Stream.sempty
3422                   in fun strm -> tracer (x.filter (filter strm))
3423                   
3424                 let define_filter x f = x.filter <- f x.filter
3425                   
3426                 let keyword_added _ _ _ = ()
3427                   
3428                 let keyword_removed _ _ = ()
3429                   
3430               end
3431               
3432           end
3433           
3434         module Eval =
3435           struct
3436             let valch x = (Char.code x) - (Char.code '0')
3437               
3438             let valch_hex x =
3439               let d = Char.code x
3440               in
3441                 if d >= 97
3442                 then d - 87
3443                 else if d >= 65 then d - 55 else d - 48
3444               
3445             let rec skip_indent (__strm : _ Stream.t) =
3446               match Stream.peek __strm with
3447               | Some (' ' | '\t') -> (Stream.junk __strm; skip_indent __strm)
3448               | _ -> ()
3449               
3450             let skip_opt_linefeed (__strm : _ Stream.t) =
3451               match Stream.peek __strm with
3452               | Some '\010' -> (Stream.junk __strm; ())
3453               | _ -> ()
3454               
3455             let chr c =
3456               if (c < 0) || (c > 255)
3457               then failwith "invalid char token"
3458               else Char.chr c
3459               
3460             let rec backslash (__strm : _ Stream.t) =
3461               match Stream.peek __strm with
3462               | Some '\010' -> (Stream.junk __strm; '\010')
3463               | Some '\013' -> (Stream.junk __strm; '\013')
3464               | Some 'n' -> (Stream.junk __strm; '\n')
3465               | Some 'r' -> (Stream.junk __strm; '\r')
3466               | Some 't' -> (Stream.junk __strm; '\t')
3467               | Some 'b' -> (Stream.junk __strm; '\b')
3468               | Some '\\' -> (Stream.junk __strm; '\\')
3469               | Some '"' -> (Stream.junk __strm; '"')
3470               | Some '\'' -> (Stream.junk __strm; '\'')
3471               | Some ' ' -> (Stream.junk __strm; ' ')
3472               | Some (('0' .. '9' as c1)) ->
3473                   (Stream.junk __strm;
3474                    (match Stream.peek __strm with
3475                     | Some (('0' .. '9' as c2)) ->
3476                         (Stream.junk __strm;
3477                          (match Stream.peek __strm with
3478                           | Some (('0' .. '9' as c3)) ->
3479                               (Stream.junk __strm;
3480                                chr
3481                                  (((100 * (valch c1)) + (10 * (valch c2))) +
3482                                     (valch c3)))
3483                           | _ -> raise (Stream.Error "")))
3484                     | _ -> raise (Stream.Error "")))
3485               | Some 'x' ->
3486                   (Stream.junk __strm;
3487                    (match Stream.peek __strm with
3488                     | Some (('0' .. '9' | 'a' .. 'f' | 'A' .. 'F' as c1)) ->
3489                         (Stream.junk __strm;
3490                          (match Stream.peek __strm with
3491                           | Some
3492                               (('0' .. '9' | 'a' .. 'f' | 'A' .. 'F' as c2))
3493                               ->
3494                               (Stream.junk __strm;
3495                                chr ((16 * (valch_hex c1)) + (valch_hex c2)))
3496                           | _ -> raise (Stream.Error "")))
3497                     | _ -> raise (Stream.Error "")))
3498               | _ -> raise Stream.Failure
3499               
3500             let rec backslash_in_string strict store (__strm : _ Stream.t) =
3501               match Stream.peek __strm with
3502               | Some '\010' -> (Stream.junk __strm; skip_indent __strm)
3503               | Some '\013' ->
3504                   (Stream.junk __strm;
3505                    let s = __strm in (skip_opt_linefeed s; skip_indent s))
3506               | _ ->
3507                   (match try Some (backslash __strm)
3508                          with | Stream.Failure -> None
3509                    with
3510                    | Some x -> store x
3511                    | _ ->
3512                        (match Stream.peek __strm with
3513                         | Some c when not strict ->
3514                             (Stream.junk __strm; store '\\'; store c)
3515                         | _ -> failwith "invalid string token"))
3516               
3517             let char s =
3518               if (String.length s) = 1
3519               then s.[0]
3520               else
3521                 if (String.length s) = 0
3522                 then failwith "invalid char token"
3523                 else
3524                   (let (__strm : _ Stream.t) = Stream.of_string s
3525                    in
3526                      match Stream.peek __strm with
3527                      | Some '\\' ->
3528                          (Stream.junk __strm;
3529                           (try backslash __strm
3530                            with | Stream.Failure -> raise (Stream.Error "")))
3531                      | _ -> failwith "invalid char token")
3532               
3533             let string ?strict s =
3534               let buf = Buffer.create 23 in
3535               let store = Buffer.add_char buf in
3536               let rec parse (__strm : _ Stream.t) =
3537                 match Stream.peek __strm with
3538                 | Some '\\' ->
3539                     (Stream.junk __strm;
3540                      let _ =
3541                        (try backslash_in_string (strict <> None) store __strm
3542                         with | Stream.Failure -> raise (Stream.Error ""))
3543                      in parse __strm)
3544                 | Some c ->
3545                     (Stream.junk __strm;
3546                      let s = __strm in (store c; parse s))
3547                 | _ -> Buffer.contents buf
3548               in parse (Stream.of_string s)
3549               
3550           end
3551           
3552       end
3553       
3554     module Lexer =
3555       struct
3556         module TokenEval = Token.Eval
3557           
3558         module Make (Token : Sig.Camlp4Token) =
3559           struct
3560             module Loc = Token.Loc
3561               
3562             module Token = Token
3563               
3564             open Lexing
3565               
3566             open Sig
3567               
3568             module Error =
3569               struct
3570                 type t =
3571                   | Illegal_character of char
3572                   | Illegal_escape of string
3573                   | Unterminated_comment
3574                   | Unterminated_string
3575                   | Unterminated_quotation
3576                   | Unterminated_antiquot
3577                   | Unterminated_string_in_comment
3578                   | Comment_start
3579                   | Comment_not_end
3580                   | Literal_overflow of string
3581                 
3582                 exception E of t
3583                   
3584                 open Format
3585                   
3586                 let print ppf =
3587                   function
3588                   | Illegal_character c ->
3589                       fprintf ppf "Illegal character (%s)" (Char.escaped c)
3590                   | Illegal_escape s ->
3591                       fprintf ppf
3592                         "Illegal backslash escape in string or character (%s)"
3593                         s
3594                   | Unterminated_comment ->
3595                       fprintf ppf "Comment not terminated"
3596                   | Unterminated_string ->
3597                       fprintf ppf "String literal not terminated"
3598                   | Unterminated_string_in_comment ->
3599                       fprintf ppf
3600                         "This comment contains an unterminated string literal"
3601                   | Unterminated_quotation ->
3602                       fprintf ppf "Quotation not terminated"
3603                   | Unterminated_antiquot ->
3604                       fprintf ppf "Antiquotation not terminated"
3605                   | Literal_overflow ty ->
3606                       fprintf ppf
3607                         "Integer literal exceeds the range of representable integers of type %s"
3608                         ty
3609                   | Comment_start ->
3610                       fprintf ppf "this is the start of a comment"
3611                   | Comment_not_end ->
3612                       fprintf ppf "this is not the end of a comment"
3613                   
3614                 let to_string x =
3615                   let b = Buffer.create 50 in
3616                   let () = bprintf b "%a" print x in Buffer.contents b
3617                   
3618               end
3619               
3620             let _ = let module M = ErrorHandler.Register(Error) in ()
3621               
3622             open Error
3623               
3624             type context =
3625               { loc : Loc.t; in_comment : bool; quotations : bool;
3626                 antiquots : bool; lexbuf : lexbuf; buffer : Buffer.t
3627               }
3628             
3629             let default_context lb =
3630               {
3631                 loc = Loc.ghost;
3632                 in_comment = false;
3633                 quotations = true;
3634                 antiquots = false;
3635                 lexbuf = lb;
3636                 buffer = Buffer.create 256;
3637               }
3638               
3639             let store c = Buffer.add_string c.buffer (Lexing.lexeme c.lexbuf)
3640               
3641             let istore_char c i =
3642               Buffer.add_char c.buffer (Lexing.lexeme_char c.lexbuf i)
3643               
3644             let buff_contents c =
3645               let contents = Buffer.contents c.buffer
3646               in (Buffer.reset c.buffer; contents)
3647               
3648             let loc c = Loc.merge c.loc (Loc.of_lexbuf c.lexbuf)
3649               
3650             let quotations c = c.quotations
3651               
3652             let antiquots c = c.antiquots
3653               
3654             let is_in_comment c = c.in_comment
3655               
3656             let in_comment c = { (c) with in_comment = true; }
3657               
3658             let set_start_p c = c.lexbuf.lex_start_p <- Loc.start_pos c.loc
3659               
3660             let move_start_p shift c =
3661               let p = c.lexbuf.lex_start_p
3662               in
3663                 c.lexbuf.lex_start_p <-
3664                   { (p) with pos_cnum = p.pos_cnum + shift; }
3665               
3666             let update_loc c = { (c) with loc = Loc.of_lexbuf c.lexbuf; }
3667               
3668             let with_curr_loc f c = f (update_loc c) c.lexbuf
3669               
3670             let parse_nested f c =
3671               (with_curr_loc f c; set_start_p c; buff_contents c)
3672               
3673             let shift n c = { (c) with loc = Loc.move `both n c.loc; }
3674               
3675             let store_parse f c = (store c; f c c.lexbuf)
3676               
3677             let parse f c = f c c.lexbuf
3678               
3679             let mk_quotation quotation c name loc shift =
3680               let s = parse_nested quotation (update_loc c) in
3681               let contents = String.sub s 0 ((String.length s) - 2)
3682               in
3683                 QUOTATION
3684                   {
3685                     q_name = name;
3686                     q_loc = loc;
3687                     q_shift = shift;
3688                     q_contents = contents;
3689                   }
3690               
3691             let update_loc c file line absolute chars =
3692               let lexbuf = c.lexbuf in
3693               let pos = lexbuf.lex_curr_p in
3694               let new_file =
3695                 match file with | None -> pos.pos_fname | Some s -> s
3696               in
3697                 lexbuf.lex_curr_p <-
3698                   {
3699                     (pos)
3700                     with
3701                     pos_fname = new_file;
3702                     pos_lnum = if absolute then line else pos.pos_lnum + line;
3703                     pos_bol = pos.pos_cnum - chars;
3704                   }
3705               
3706             let err error loc = raise (Loc.Exc_located (loc, Error.E error))
3707               
3708             let warn error loc =
3709               Format.eprintf "Warning: %a: %a@." Loc.print loc Error.print
3710                 error
3711               
3712             let __ocaml_lex_tables =
3713               {
3714                 Lexing.lex_base =
3715                   "\000\000\223\255\224\255\224\000\226\255\253\000\035\001\072\001\
3716     \109\001\146\001\091\000\183\001\068\000\190\001\218\001\227\255\
3717     \122\000\002\002\071\002\110\002\176\000\244\255\129\002\162\002\
3718     \235\002\187\003\154\004\246\004\124\000\001\000\255\255\198\005\
3719     \253\255\150\006\252\255\245\255\246\255\247\255\253\000\224\000\
3720     \086\000\091\000\054\003\006\004\029\002\237\001\182\004\109\000\
3721     \118\007\091\000\253\000\093\000\243\255\242\255\241\255\106\005\
3722     \077\003\108\000\087\003\017\006\151\007\218\007\001\008\068\008\
3723     \107\008\107\000\239\255\126\008\075\001\210\008\249\008\060\009\
3724     \232\255\231\255\230\255\099\009\166\009\205\009\016\010\055\010\
3725     \249\001\228\255\229\255\238\255\090\010\127\010\164\010\201\010\
3726     \238\010\019\011\056\011\091\011\128\011\165\011\202\011\239\011\
3727     \020\012\057\012\094\012\011\007\136\005\004\000\233\255\008\000\
3728     \054\001\245\002\009\000\005\000\233\255\131\012\138\012\175\012\
3729     \212\012\249\012\000\013\037\013\068\013\096\013\133\013\138\013\
3730     \205\013\242\013\023\014\085\014\241\255\006\000\242\255\243\255\
3731     \148\002\251\255\047\015\123\000\109\000\125\000\255\255\254\255\
3732     \253\255\111\015\046\016\254\016\206\017\174\018\129\000\017\001\
3733     \130\000\141\000\249\255\248\255\247\255\237\006\109\003\143\000\
3734     \246\255\035\004\145\000\245\255\160\014\149\000\244\255\086\004\
3735     \247\255\248\255\007\000\249\255\201\018\255\255\250\255\121\016\
3736     \154\004\253\255\091\001\057\001\171\004\252\255\073\017\251\255\
3737     \240\018\051\019\018\020\048\020\255\255\015\021\238\021\015\022\
3738     \079\022\255\255\031\023\254\255\164\001\251\255\010\000\252\255\
3739     \253\255\128\000\079\001\255\255\095\023\030\024\238\024\190\025\
3740     \254\255\154\026\253\255\254\255\201\000\116\027\077\028\255\255\
3741     \028\001\029\029\206\001\251\255\080\001\013\000\253\255\254\255\
3742     \255\255\252\255\093\029\028\030\236\030\188\031";
3743                 Lexing.lex_backtrk =
3744                   "\255\255\255\255\255\255\030\000\255\255\028\000\030\000\030\000\
3745     \030\000\030\000\028\000\028\000\028\000\028\000\028\000\255\255\
3746     \028\000\030\000\030\000\028\000\028\000\255\255\006\000\006\000\
3747     \005\000\004\000\030\000\030\000\001\000\000\000\255\255\255\255\
3748     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\007\000\
3749     \255\255\255\255\255\255\006\000\006\000\006\000\007\000\255\255\
3750     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\014\000\
3751     \014\000\014\000\255\255\255\255\255\255\255\255\255\255\028\000\
3752     \028\000\015\000\255\255\028\000\255\255\255\255\028\000\255\255\
3753     \255\255\255\255\255\255\028\000\028\000\255\255\255\255\255\255\
3754     \255\255\255\255\255\255\255\255\255\255\030\000\021\000\020\000\
3755     \018\000\030\000\018\000\018\000\018\000\018\000\028\000\018\000\
3756     \255\255\019\000\030\000\255\255\255\255\022\000\255\255\255\255\
3757     \255\255\255\255\255\255\022\000\255\255\255\255\255\255\255\255\
3758     \028\000\255\255\028\000\255\255\028\000\028\000\028\000\028\000\
3759     \030\000\030\000\030\000\255\255\255\255\013\000\255\255\255\255\
3760     \014\000\255\255\003\000\014\000\014\000\014\000\255\255\255\255\
3761     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
3762     \255\255\005\000\255\255\255\255\255\255\255\255\255\255\255\255\
3763     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
3764     \255\255\255\255\006\000\255\255\008\000\255\255\255\255\005\000\
3765     \005\000\255\255\001\000\001\000\255\255\255\255\255\255\255\255\
3766     \000\000\001\000\001\000\255\255\255\255\002\000\002\000\255\255\
3767     \255\255\255\255\255\255\255\255\255\255\255\255\003\000\255\255\
3768     \255\255\004\000\004\000\255\255\255\255\255\255\255\255\255\255\
3769     \255\255\255\255\255\255\255\255\002\000\002\000\002\000\255\255\
3770     \255\255\255\255\255\255\255\255\004\000\002\000\255\255\255\255\
3771     \255\255\255\255\255\255\255\255\255\255\255\255";
3772                 Lexing.lex_default =
3773                   "\001\000\000\000\000\000\255\255\000\000\255\255\255\255\255\255\
3774     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\000\000\
3775     \255\255\255\255\255\255\255\255\049\000\000\000\255\255\255\255\
3776     \255\255\255\255\255\255\255\255\255\255\255\255\000\000\255\255\
3777     \000\000\255\255\000\000\000\000\000\000\000\000\255\255\255\255\
3778     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
3779     \054\000\255\255\255\255\255\255\000\000\000\000\000\000\255\255\
3780     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
3781     \255\255\255\255\000\000\255\255\255\255\255\255\255\255\255\255\
3782     \000\000\000\000\000\000\255\255\255\255\255\255\255\255\255\255\
3783     \255\255\000\000\000\000\000\000\255\255\255\255\255\255\255\255\
3784     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
3785     \255\255\255\255\255\255\103\000\255\255\255\255\000\000\103\000\
3786     \104\000\103\000\106\000\255\255\000\000\255\255\255\255\255\255\
3787     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
3788     \255\255\255\255\255\255\124\000\000\000\255\255\000\000\000\000\
3789     \142\000\000\000\255\255\255\255\255\255\255\255\000\000\000\000\
3790     \000\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
3791     \255\255\255\255\000\000\000\000\000\000\255\255\255\255\255\255\
3792     \000\000\255\255\255\255\000\000\255\255\255\255\000\000\160\000\
3793     \000\000\000\000\255\255\000\000\166\000\000\000\000\000\255\255\
3794     \255\255\000\000\255\255\255\255\255\255\000\000\255\255\000\000\
3795     \255\255\255\255\255\255\255\255\000\000\255\255\255\255\255\255\
3796     \255\255\000\000\255\255\000\000\189\000\000\000\255\255\000\000\
3797     \000\000\255\255\255\255\000\000\255\255\255\255\255\255\255\255\
3798     \000\000\202\000\000\000\000\000\255\255\255\255\255\255\000\000\
3799     \255\255\255\255\211\000\000\000\255\255\255\255\000\000\000\000\
3800     \000\000\000\000\255\255\255\255\255\255\255\255";
3801                 Lexing.lex_trans =
3802                   "\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
3803     \000\000\028\000\030\000\030\000\028\000\029\000\102\000\108\000\
3804     \126\000\163\000\102\000\108\000\191\000\101\000\107\000\214\000\
3805     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
3806     \028\000\003\000\021\000\016\000\004\000\009\000\009\000\020\000\
3807     \019\000\005\000\018\000\003\000\015\000\003\000\014\000\009\000\
3808     \023\000\022\000\022\000\022\000\022\000\022\000\022\000\022\000\
3809     \022\000\022\000\013\000\012\000\017\000\006\000\007\000\026\000\
3810     \009\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3811     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3812     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3813     \024\000\024\000\024\000\011\000\003\000\005\000\009\000\025\000\
3814     \015\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3815     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3816     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3817     \025\000\025\000\025\000\010\000\008\000\005\000\027\000\015\000\
3818     \117\000\117\000\053\000\100\000\052\000\028\000\045\000\045\000\
3819     \028\000\115\000\117\000\044\000\044\000\044\000\044\000\044\000\
3820     \044\000\044\000\044\000\053\000\066\000\118\000\135\000\116\000\
3821     \115\000\115\000\100\000\117\000\028\000\046\000\046\000\046\000\
3822     \046\000\046\000\046\000\046\000\046\000\046\000\046\000\134\000\
3823     \148\000\147\000\099\000\099\000\099\000\099\000\099\000\099\000\
3824     \099\000\099\000\099\000\099\000\146\000\138\000\152\000\136\000\
3825     \155\000\117\000\051\000\137\000\158\000\050\000\200\000\000\000\
3826     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3827     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3828     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\118\000\
3829     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\025\000\
3830     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3831     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3832     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\208\000\
3833     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3834     \002\000\003\000\000\000\203\000\003\000\003\000\003\000\051\000\
3835     \255\255\255\255\003\000\003\000\048\000\003\000\003\000\003\000\
3836     \039\000\039\000\039\000\039\000\039\000\039\000\039\000\039\000\
3837     \039\000\039\000\003\000\144\000\003\000\003\000\003\000\003\000\
3838     \003\000\000\000\096\000\096\000\052\000\038\000\084\000\000\000\
3839     \047\000\000\000\047\000\084\000\096\000\046\000\046\000\046\000\
3840     \046\000\046\000\046\000\046\000\046\000\046\000\046\000\084\000\
3841     \147\000\084\000\084\000\084\000\003\000\096\000\003\000\039\000\
3842     \102\000\000\000\171\000\101\000\003\000\038\000\000\000\003\000\
3843     \009\000\009\000\208\000\000\000\084\000\003\000\003\000\000\000\
3844     \003\000\006\000\009\000\000\000\068\000\000\000\203\000\068\000\
3845     \106\000\171\000\084\000\096\000\003\000\085\000\003\000\006\000\
3846     \006\000\006\000\003\000\009\000\171\000\171\000\000\000\000\000\
3847     \000\000\003\000\000\000\068\000\003\000\121\000\121\000\000\000\
3848     \000\000\084\000\003\000\003\000\074\000\003\000\007\000\121\000\
3849     \000\000\084\000\084\000\171\000\000\000\000\000\000\000\003\000\
3850     \084\000\009\000\120\000\000\000\007\000\007\000\007\000\003\000\
3851     \121\000\197\000\219\000\195\000\217\000\000\000\003\000\196\000\
3852     \218\000\003\000\009\000\009\000\000\000\000\000\005\000\003\000\
3853     \003\000\000\000\003\000\006\000\009\000\000\000\000\000\085\000\
3854     \084\000\003\000\000\000\000\000\003\000\005\000\121\000\085\000\
3855     \000\000\006\000\006\000\006\000\003\000\009\000\191\000\000\000\
3856     \255\255\190\000\000\000\003\000\000\000\000\000\003\000\009\000\
3857     \009\000\000\000\000\000\094\000\003\000\003\000\000\000\003\000\
3858     \009\000\009\000\000\000\000\000\120\000\005\000\003\000\000\000\
3859     \000\000\003\000\005\000\009\000\098\000\000\000\009\000\009\000\
3860     \009\000\003\000\009\000\000\000\000\000\000\000\000\000\000\000\
3861     \214\000\000\000\000\000\213\000\117\000\117\000\000\000\000\000\
3862     \194\000\000\000\193\000\111\000\111\000\115\000\117\000\005\000\
3863     \000\000\085\000\005\000\003\000\109\000\111\000\003\000\094\000\
3864     \009\000\116\000\216\000\116\000\115\000\115\000\000\000\117\000\
3865     \114\000\000\000\109\000\112\000\112\000\000\000\111\000\111\000\
3866     \111\000\000\000\080\000\084\000\000\000\080\000\000\000\000\000\
3867     \112\000\111\000\212\000\000\000\000\000\000\000\098\000\094\000\
3868     \003\000\000\000\000\000\000\000\110\000\117\000\109\000\109\000\
3869     \109\000\080\000\111\000\005\000\111\000\045\000\045\000\000\000\
3870     \000\000\000\000\081\000\003\000\000\000\000\000\003\000\009\000\
3871     \009\000\000\000\000\000\084\000\003\000\003\000\000\000\003\000\
3872     \006\000\009\000\000\000\116\000\000\000\000\000\255\255\084\000\
3873     \111\000\036\000\110\000\005\000\086\000\000\000\088\000\006\000\
3874     \006\000\003\000\087\000\000\000\000\000\000\000\000\000\000\000\
3875     \000\000\000\000\000\000\000\000\045\000\044\000\044\000\044\000\
3876     \044\000\044\000\044\000\044\000\044\000\000\000\110\000\084\000\
3877     \000\000\037\000\000\000\035\000\000\000\000\000\003\000\084\000\
3878     \009\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
3879     \003\000\036\000\000\000\003\000\003\000\003\000\000\000\000\000\
3880     \083\000\003\000\003\000\000\000\003\000\003\000\003\000\060\000\
3881     \000\000\000\000\060\000\000\000\044\000\000\000\085\000\084\000\
3882     \003\000\003\000\000\000\003\000\003\000\003\000\003\000\003\000\
3883     \000\000\037\000\000\000\035\000\000\000\000\000\060\000\061\000\
3884     \000\000\000\000\061\000\064\000\064\000\000\000\000\000\000\000\
3885     \065\000\061\000\000\000\061\000\062\000\064\000\144\000\000\000\
3886     \000\000\143\000\000\000\003\000\192\000\003\000\000\000\000\000\
3887     \063\000\000\000\062\000\062\000\062\000\061\000\064\000\039\000\
3888     \000\000\022\000\022\000\022\000\022\000\022\000\022\000\022\000\
3889     \022\000\022\000\022\000\145\000\000\000\000\000\000\000\000\000\
3890     \000\000\000\000\000\000\003\000\000\000\003\000\038\000\000\000\
3891     \000\000\000\000\061\000\000\000\064\000\036\000\215\000\000\000\
3892     \039\000\000\000\022\000\022\000\022\000\022\000\022\000\022\000\
3893     \022\000\022\000\022\000\022\000\000\000\000\000\000\000\000\000\
3894     \022\000\000\000\000\000\000\000\040\000\000\000\038\000\038\000\
3895     \000\000\000\000\063\000\000\000\061\000\037\000\036\000\035\000\
3896     \141\000\041\000\000\000\000\000\000\000\000\000\000\000\000\000\
3897     \000\000\000\000\042\000\000\000\000\000\000\000\105\000\102\000\
3898     \000\000\022\000\101\000\000\000\040\000\000\000\000\000\038\000\
3899     \000\000\000\000\000\000\000\000\000\000\000\000\037\000\000\000\
3900     \035\000\041\000\024\000\000\000\000\000\105\000\000\000\104\000\
3901     \000\000\000\000\042\000\024\000\024\000\024\000\024\000\024\000\
3902     \024\000\024\000\024\000\024\000\024\000\000\000\000\000\000\000\
3903     \000\000\000\000\000\000\000\000\024\000\024\000\024\000\024\000\
3904     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3905     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3906     \024\000\024\000\024\000\024\000\024\000\024\000\000\000\000\000\
3907     \000\000\000\000\024\000\000\000\024\000\024\000\024\000\024\000\
3908     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3909     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3910     \024\000\024\000\024\000\024\000\024\000\024\000\043\000\043\000\
3911     \043\000\043\000\043\000\043\000\043\000\043\000\043\000\043\000\
3912     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\043\000\
3913     \043\000\043\000\043\000\043\000\043\000\058\000\058\000\058\000\
3914     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\049\000\
3915     \049\000\049\000\049\000\049\000\049\000\049\000\049\000\049\000\
3916     \049\000\000\000\000\000\000\000\255\255\000\000\000\000\043\000\
3917     \043\000\043\000\043\000\043\000\043\000\153\000\153\000\153\000\
3918     \153\000\153\000\153\000\153\000\153\000\153\000\153\000\000\000\
3919     \000\000\000\000\000\000\024\000\024\000\024\000\024\000\024\000\
3920     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3921     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3922     \024\000\024\000\000\000\024\000\024\000\024\000\024\000\024\000\
3923     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3924     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3925     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
3926     \024\000\024\000\025\000\024\000\024\000\024\000\024\000\024\000\
3927     \024\000\024\000\024\000\025\000\025\000\025\000\025\000\025\000\
3928     \025\000\025\000\025\000\025\000\025\000\255\255\000\000\000\000\
3929     \000\000\000\000\000\000\000\000\025\000\025\000\025\000\025\000\
3930     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3931     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3932     \025\000\025\000\025\000\025\000\025\000\025\000\000\000\000\000\
3933     \000\000\000\000\025\000\000\000\025\000\025\000\025\000\025\000\
3934     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3935     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3936     \025\000\025\000\025\000\025\000\025\000\025\000\043\000\043\000\
3937     \043\000\043\000\043\000\043\000\043\000\043\000\043\000\043\000\
3938     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\043\000\
3939     \043\000\043\000\043\000\043\000\043\000\000\000\000\000\000\000\
3940     \000\000\000\000\036\000\154\000\154\000\154\000\154\000\154\000\
3941     \154\000\154\000\154\000\154\000\154\000\000\000\000\000\000\000\
3942     \163\000\000\000\000\000\162\000\000\000\043\000\000\000\043\000\
3943     \043\000\043\000\043\000\043\000\043\000\000\000\000\000\000\000\
3944     \000\000\000\000\037\000\000\000\035\000\000\000\000\000\000\000\
3945     \165\000\000\000\000\000\025\000\025\000\025\000\025\000\025\000\
3946     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3947     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3948     \025\000\025\000\000\000\025\000\025\000\025\000\025\000\025\000\
3949     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3950     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3951     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
3952     \025\000\025\000\164\000\025\000\025\000\025\000\025\000\025\000\
3953     \025\000\025\000\025\000\003\000\000\000\000\000\003\000\003\000\
3954     \003\000\000\000\000\000\000\000\003\000\003\000\000\000\003\000\
3955     \003\000\003\000\172\000\172\000\172\000\172\000\172\000\172\000\
3956     \172\000\172\000\172\000\172\000\003\000\000\000\003\000\003\000\
3957     \003\000\003\000\003\000\173\000\173\000\173\000\173\000\173\000\
3958     \173\000\173\000\173\000\173\000\173\000\000\000\046\000\046\000\
3959     \046\000\046\000\046\000\046\000\046\000\046\000\046\000\046\000\
3960     \000\000\000\000\000\000\000\000\000\000\000\000\003\000\000\000\
3961     \003\000\033\000\000\000\033\000\033\000\033\000\033\000\033\000\
3962     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
3963     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
3964     \033\000\033\000\033\000\033\000\033\000\046\000\003\000\003\000\
3965     \003\000\000\000\003\000\003\000\003\000\000\000\000\000\000\000\
3966     \003\000\003\000\000\000\003\000\003\000\003\000\000\000\000\000\
3967     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
3968     \003\000\000\000\003\000\003\000\003\000\003\000\003\000\000\000\
3969     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
3970     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
3971     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
3972     \000\000\000\000\003\000\000\000\003\000\031\000\161\000\031\000\
3973     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3974     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3975     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3976     \031\000\000\000\003\000\000\000\003\000\000\000\000\000\000\000\
3977     \000\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
3978     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
3979     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
3980     \033\000\100\000\033\000\033\000\033\000\033\000\033\000\033\000\
3981     \033\000\033\000\059\000\059\000\059\000\059\000\059\000\059\000\
3982     \059\000\059\000\059\000\059\000\000\000\000\000\000\000\000\000\
3983     \100\000\000\000\000\000\059\000\059\000\059\000\059\000\059\000\
3984     \059\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
3985     \099\000\099\000\099\000\099\000\099\000\099\000\099\000\099\000\
3986     \099\000\099\000\000\000\000\000\000\000\000\000\000\000\000\000\
3987     \000\000\000\000\000\000\059\000\059\000\059\000\059\000\059\000\
3988     \059\000\000\000\000\000\000\000\000\000\031\000\031\000\031\000\
3989     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3990     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3991     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3992     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3993     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3994     \032\000\000\000\000\000\000\000\000\000\000\000\000\000\031\000\
3995     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3996     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3997     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
3998     \031\000\000\000\000\000\000\000\000\000\031\000\000\000\031\000\
3999     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
4000     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
4001     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
4002     \031\000\049\000\049\000\049\000\049\000\049\000\049\000\049\000\
4003     \049\000\049\000\049\000\000\000\000\000\000\000\000\000\000\000\
4004     \000\000\000\000\049\000\049\000\049\000\049\000\049\000\049\000\
4005     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4006     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4007     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4008     \000\000\000\000\049\000\049\000\049\000\049\000\049\000\049\000\
4009     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4010     \000\000\000\000\000\000\000\000\000\000\000\000\031\000\031\000\
4011     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
4012     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
4013     \031\000\031\000\031\000\031\000\031\000\000\000\031\000\031\000\
4014     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
4015     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
4016     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
4017     \031\000\031\000\031\000\031\000\031\000\033\000\031\000\031\000\
4018     \031\000\031\000\031\000\031\000\031\000\031\000\033\000\033\000\
4019     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4020     \034\000\000\000\000\000\000\000\000\000\000\000\000\000\033\000\
4021     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4022     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4023     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4024     \033\000\000\000\000\000\000\000\000\000\033\000\000\000\033\000\
4025     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4026     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4027     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4028     \033\000\000\000\000\000\000\000\105\000\102\000\000\000\000\000\
4029     \101\000\000\000\000\000\000\000\000\000\156\000\156\000\156\000\
4030     \156\000\156\000\156\000\156\000\156\000\156\000\156\000\000\000\
4031     \000\000\000\000\000\000\105\000\000\000\104\000\156\000\156\000\
4032     \156\000\156\000\156\000\156\000\000\000\000\000\000\000\000\000\
4033     \000\000\000\000\000\000\099\000\099\000\099\000\099\000\099\000\
4034     \099\000\099\000\099\000\099\000\099\000\000\000\000\000\000\000\
4035     \000\000\000\000\000\000\000\000\000\000\000\000\156\000\156\000\
4036     \156\000\156\000\156\000\156\000\000\000\000\000\033\000\033\000\
4037     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4038     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4039     \033\000\033\000\033\000\033\000\033\000\000\000\033\000\033\000\
4040     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4041     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4042     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
4043     \033\000\033\000\033\000\033\000\033\000\000\000\033\000\033\000\
4044     \033\000\033\000\033\000\033\000\033\000\033\000\057\000\000\000\
4045     \057\000\000\000\000\000\000\000\000\000\057\000\000\000\000\000\
4046     \060\000\000\000\000\000\060\000\000\000\000\000\056\000\056\000\
4047     \056\000\056\000\056\000\056\000\056\000\056\000\056\000\056\000\
4048     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\060\000\
4049     \078\000\000\000\000\000\078\000\078\000\078\000\000\000\000\000\
4050     \000\000\079\000\078\000\000\000\078\000\078\000\078\000\000\000\
4051     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4052     \000\000\078\000\057\000\078\000\078\000\078\000\078\000\078\000\
4053     \057\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4054     \000\000\000\000\000\000\068\000\057\000\000\000\068\000\000\000\
4055     \057\000\000\000\057\000\000\000\000\000\000\000\055\000\000\000\
4056     \000\000\000\000\000\000\078\000\000\000\078\000\000\000\000\000\
4057     \000\000\000\000\068\000\069\000\000\000\000\000\069\000\069\000\
4058     \069\000\000\000\000\000\072\000\071\000\069\000\000\000\069\000\
4059     \069\000\069\000\068\000\255\255\000\000\068\000\000\000\000\000\
4060     \000\000\000\000\000\000\078\000\069\000\078\000\069\000\069\000\
4061     \069\000\069\000\069\000\000\000\000\000\000\000\000\000\000\000\
4062     \000\000\068\000\069\000\000\000\000\000\069\000\070\000\070\000\
4063     \000\000\000\000\072\000\071\000\069\000\000\000\069\000\077\000\
4064     \070\000\000\000\000\000\000\000\000\000\000\000\069\000\000\000\
4065     \069\000\000\000\000\000\077\000\000\000\077\000\077\000\077\000\
4066     \069\000\070\000\000\000\000\000\000\000\000\000\000\000\000\000\
4067     \000\000\000\000\000\000\000\000\000\000\068\000\000\000\000\000\
4068     \068\000\000\000\000\000\000\000\000\000\000\000\069\000\000\000\
4069     \069\000\000\000\000\000\000\000\000\000\069\000\000\000\070\000\
4070     \000\000\000\000\000\000\000\000\068\000\069\000\000\000\000\000\
4071     \069\000\076\000\076\000\000\000\000\000\072\000\071\000\069\000\
4072     \000\000\069\000\075\000\076\000\068\000\000\000\255\255\068\000\
4073     \000\000\000\000\000\000\000\000\000\000\077\000\075\000\069\000\
4074     \075\000\075\000\075\000\069\000\076\000\000\000\000\000\000\000\
4075     \000\000\000\000\000\000\068\000\069\000\000\000\000\000\069\000\
4076     \070\000\070\000\000\000\067\000\072\000\071\000\069\000\000\000\
4077     \069\000\070\000\070\000\000\000\000\000\000\000\000\000\000\000\
4078     \069\000\000\000\076\000\067\000\067\000\070\000\067\000\070\000\
4079     \070\000\070\000\069\000\070\000\067\000\067\000\000\000\000\000\
4080     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4081     \067\000\000\000\067\000\067\000\067\000\000\000\067\000\000\000\
4082     \075\000\000\000\069\000\000\000\000\000\000\000\067\000\069\000\
4083     \000\000\070\000\000\000\000\000\000\000\000\000\000\000\000\000\
4084     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4085     \000\000\067\000\000\000\068\000\067\000\000\000\068\000\000\000\
4086     \000\000\000\000\000\000\000\000\000\000\000\000\067\000\070\000\
4087     \000\000\069\000\000\000\000\000\000\000\000\000\000\000\000\000\
4088     \000\000\000\000\068\000\069\000\000\000\000\000\069\000\069\000\
4089     \069\000\067\000\067\000\073\000\071\000\069\000\000\000\069\000\
4090     \069\000\069\000\068\000\000\000\000\000\068\000\000\000\000\000\
4091     \000\000\000\000\000\000\000\000\069\000\000\000\069\000\069\000\
4092     \069\000\069\000\069\000\000\000\000\000\000\000\000\000\000\000\
4093     \000\000\068\000\069\000\000\000\000\000\069\000\070\000\070\000\
4094     \000\000\067\000\073\000\071\000\069\000\000\000\069\000\070\000\
4095     \070\000\000\000\000\000\000\000\000\000\000\000\069\000\000\000\
4096     \069\000\000\000\000\000\070\000\000\000\070\000\070\000\070\000\
4097     \069\000\070\000\000\000\000\000\000\000\000\000\000\000\000\000\
4098     \000\000\000\000\000\000\000\000\000\000\068\000\000\000\000\000\
4099     \068\000\000\000\000\000\000\000\000\000\000\000\069\000\000\000\
4100     \069\000\000\000\000\000\000\000\067\000\069\000\000\000\070\000\
4101     \000\000\000\000\000\000\000\000\068\000\069\000\000\000\000\000\
4102     \069\000\069\000\069\000\000\000\000\000\000\000\071\000\069\000\
4103     \000\000\069\000\069\000\069\000\068\000\000\000\000\000\068\000\
4104     \000\000\000\000\000\000\000\000\067\000\070\000\069\000\069\000\
4105     \069\000\069\000\069\000\069\000\069\000\000\000\000\000\000\000\
4106     \000\000\000\000\000\000\068\000\069\000\000\000\000\000\069\000\
4107     \076\000\076\000\000\000\000\000\073\000\071\000\069\000\000\000\
4108     \069\000\075\000\076\000\000\000\000\000\000\000\000\000\000\000\
4109     \069\000\000\000\069\000\000\000\000\000\075\000\000\000\075\000\
4110     \075\000\075\000\069\000\076\000\000\000\000\000\000\000\000\000\
4111     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\068\000\
4112     \000\000\000\000\068\000\000\000\000\000\000\000\000\000\000\000\
4113     \069\000\000\000\069\000\000\000\000\000\000\000\000\000\069\000\
4114     \000\000\076\000\000\000\000\000\000\000\000\000\068\000\069\000\
4115     \000\000\000\000\069\000\076\000\076\000\000\000\067\000\073\000\
4116     \071\000\069\000\000\000\069\000\076\000\076\000\068\000\000\000\
4117     \000\000\068\000\000\000\000\000\000\000\000\000\000\000\075\000\
4118     \076\000\069\000\076\000\076\000\076\000\069\000\076\000\000\000\
4119     \000\000\000\000\000\000\000\000\000\000\068\000\069\000\000\000\
4120     \000\000\069\000\070\000\070\000\000\000\000\000\073\000\071\000\
4121     \069\000\000\000\069\000\077\000\070\000\000\000\000\000\000\000\
4122     \000\000\067\000\069\000\000\000\076\000\000\000\000\000\077\000\
4123     \000\000\077\000\077\000\077\000\069\000\070\000\000\000\000\000\
4124     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4125     \000\000\080\000\000\000\000\000\080\000\000\000\000\000\000\000\
4126     \000\000\067\000\076\000\000\000\069\000\000\000\000\000\000\000\
4127     \000\000\069\000\000\000\070\000\000\000\000\000\000\000\000\000\
4128     \080\000\078\000\000\000\000\000\078\000\078\000\078\000\000\000\
4129     \000\000\082\000\079\000\078\000\000\000\078\000\078\000\078\000\
4130     \080\000\000\000\000\000\080\000\000\000\000\000\000\000\000\000\
4131     \000\000\077\000\078\000\069\000\078\000\078\000\078\000\078\000\
4132     \078\000\000\000\000\000\000\000\000\000\000\000\000\000\080\000\
4133     \078\000\000\000\000\000\078\000\078\000\078\000\000\000\000\000\
4134     \000\000\079\000\078\000\000\000\078\000\078\000\078\000\000\000\
4135     \000\000\000\000\000\000\000\000\078\000\000\000\078\000\000\000\
4136     \000\000\078\000\000\000\078\000\078\000\078\000\078\000\078\000\
4137     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\096\000\
4138     \096\000\000\000\000\000\084\000\000\000\000\000\000\000\000\000\
4139     \084\000\096\000\000\000\000\000\078\000\000\000\078\000\000\000\
4140     \000\000\000\000\000\000\078\000\084\000\078\000\084\000\084\000\
4141     \084\000\000\000\096\000\000\000\000\000\000\000\000\000\000\000\
4142     \003\000\000\000\000\000\003\000\009\000\009\000\000\000\000\000\
4143     \005\000\003\000\003\000\000\000\003\000\006\000\009\000\000\000\
4144     \000\000\000\000\000\000\078\000\000\000\078\000\000\000\084\000\
4145     \096\000\085\000\000\000\006\000\006\000\006\000\003\000\009\000\
4146     \000\000\000\000\000\000\000\000\000\000\003\000\000\000\000\000\
4147     \003\000\009\000\009\000\000\000\000\000\005\000\003\000\003\000\
4148     \000\000\003\000\006\000\009\000\000\000\000\000\084\000\084\000\
4149     \000\000\000\000\000\000\003\000\084\000\009\000\085\000\000\000\
4150     \006\000\006\000\006\000\003\000\009\000\000\000\000\000\000\000\
4151     \000\000\000\000\003\000\000\000\000\000\003\000\009\000\009\000\
4152     \000\000\000\000\094\000\003\000\003\000\000\000\003\000\009\000\
4153     \009\000\000\000\000\000\085\000\005\000\003\000\000\000\000\000\
4154     \003\000\084\000\009\000\098\000\000\000\009\000\009\000\009\000\
4155     \003\000\009\000\000\000\000\000\000\000\000\000\000\000\090\000\
4156     \000\000\000\000\003\000\093\000\093\000\000\000\000\000\084\000\
4157     \090\000\090\000\000\000\090\000\091\000\093\000\000\000\000\000\
4158     \085\000\005\000\003\000\000\000\000\000\003\000\094\000\009\000\
4159     \092\000\000\000\006\000\091\000\089\000\090\000\093\000\000\000\
4160     \000\000\000\000\000\000\000\000\003\000\000\000\000\000\003\000\
4161     \009\000\009\000\000\000\000\000\084\000\003\000\003\000\000\000\
4162     \003\000\006\000\009\000\000\000\000\000\098\000\094\000\003\000\
4163     \000\000\000\000\090\000\084\000\093\000\085\000\000\000\006\000\
4164     \006\000\097\000\003\000\009\000\000\000\000\000\000\000\000\000\
4165     \000\000\090\000\000\000\000\000\003\000\090\000\090\000\000\000\
4166     \000\000\000\000\090\000\090\000\000\000\090\000\090\000\090\000\
4167     \000\000\000\000\092\000\084\000\090\000\000\000\000\000\003\000\
4168     \084\000\009\000\090\000\000\000\003\000\090\000\003\000\090\000\
4169     \090\000\000\000\000\000\000\000\090\000\000\000\000\000\003\000\
4170     \093\000\093\000\000\000\000\000\084\000\090\000\090\000\000\000\
4171     \090\000\091\000\093\000\000\000\000\000\000\000\000\000\085\000\
4172     \084\000\003\000\000\000\000\000\090\000\092\000\090\000\006\000\
4173     \091\000\006\000\090\000\093\000\000\000\000\000\000\000\000\000\
4174     \000\000\090\000\000\000\000\000\003\000\093\000\093\000\000\000\
4175     \000\000\005\000\090\000\090\000\000\000\090\000\091\000\093\000\
4176     \000\000\000\000\000\000\000\000\090\000\000\000\090\000\090\000\
4177     \084\000\093\000\092\000\000\000\006\000\091\000\006\000\090\000\
4178     \093\000\000\000\000\000\000\000\000\000\000\000\090\000\000\000\
4179     \000\000\003\000\093\000\093\000\000\000\000\000\094\000\090\000\
4180     \090\000\000\000\090\000\093\000\093\000\000\000\000\000\092\000\
4181     \084\000\090\000\000\000\000\000\090\000\084\000\093\000\095\000\
4182     \000\000\009\000\093\000\009\000\090\000\093\000\000\000\000\000\
4183     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\096\000\
4184     \096\000\000\000\000\000\094\000\000\000\000\000\000\000\000\000\
4185     \096\000\096\000\000\000\000\000\092\000\005\000\090\000\000\000\
4186     \000\000\090\000\094\000\093\000\096\000\000\000\096\000\096\000\
4187     \096\000\000\000\096\000\000\000\000\000\000\000\000\000\000\000\
4188     \090\000\000\000\000\000\003\000\093\000\093\000\000\000\000\000\
4189     \094\000\090\000\090\000\000\000\090\000\093\000\093\000\000\000\
4190     \000\000\095\000\094\000\090\000\000\000\000\000\000\000\094\000\
4191     \096\000\095\000\000\000\009\000\093\000\009\000\090\000\093\000\
4192     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4193     \000\000\096\000\096\000\000\000\000\000\094\000\000\000\000\000\
4194     \000\000\000\000\096\000\096\000\000\000\000\000\096\000\094\000\
4195     \000\000\000\000\000\000\090\000\094\000\093\000\096\000\000\000\
4196     \096\000\096\000\096\000\000\000\096\000\000\000\000\000\000\000\
4197     \000\000\000\000\003\000\000\000\000\000\003\000\009\000\009\000\
4198     \000\000\000\000\084\000\003\000\003\000\000\000\003\000\006\000\
4199     \009\000\000\000\000\000\095\000\094\000\090\000\000\000\000\000\
4200     \000\000\094\000\096\000\085\000\000\000\006\000\006\000\006\000\
4201     \003\000\009\000\000\000\000\000\000\000\000\000\000\000\003\000\
4202     \000\000\000\000\003\000\009\000\009\000\000\000\000\000\094\000\
4203     \003\000\003\000\000\000\003\000\009\000\009\000\000\000\000\000\
4204     \096\000\094\000\000\000\000\000\000\000\003\000\084\000\009\000\
4205     \098\000\000\000\009\000\009\000\009\000\003\000\009\000\000\000\
4206     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4207     \111\000\111\000\000\000\000\000\084\000\000\000\000\000\111\000\
4208     \111\000\109\000\111\000\005\000\000\000\085\000\084\000\003\000\
4209     \109\000\111\000\003\000\094\000\009\000\110\000\000\000\109\000\
4210     \109\000\109\000\000\000\111\000\110\000\000\000\109\000\109\000\
4211     \109\000\000\000\111\000\000\000\000\000\000\000\000\000\000\000\
4212     \000\000\000\000\000\000\000\000\111\000\111\000\000\000\000\000\
4213     \094\000\000\000\098\000\094\000\003\000\111\000\111\000\000\000\
4214     \084\000\111\000\000\000\000\000\000\000\000\000\000\000\084\000\
4215     \111\000\113\000\000\000\111\000\111\000\111\000\000\000\111\000\
4216     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4217     \000\000\111\000\111\000\000\000\000\000\084\000\000\000\110\000\
4218     \084\000\000\000\109\000\111\000\000\000\000\000\110\000\005\000\
4219     \000\000\000\000\000\000\000\000\094\000\111\000\110\000\000\000\
4220     \109\000\109\000\109\000\000\000\111\000\000\000\000\000\000\000\
4221     \000\000\000\000\000\000\000\000\000\000\000\000\111\000\111\000\
4222     \000\000\000\000\094\000\000\000\000\000\111\000\111\000\111\000\
4223     \111\000\005\000\000\000\113\000\094\000\000\000\109\000\111\000\
4224     \000\000\084\000\111\000\113\000\000\000\111\000\111\000\111\000\
4225     \000\000\111\000\110\000\000\000\109\000\109\000\109\000\000\000\
4226     \111\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4227     \000\000\000\000\117\000\117\000\000\000\000\000\000\000\000\000\
4228     \110\000\084\000\000\000\115\000\117\000\000\000\094\000\111\000\
4229     \000\000\000\000\000\000\000\000\000\000\084\000\111\000\115\000\
4230     \000\000\116\000\115\000\115\000\000\000\117\000\000\000\000\000\
4231     \000\000\117\000\117\000\000\000\000\000\000\000\000\000\000\000\
4232     \000\000\000\000\115\000\117\000\000\000\113\000\094\000\000\000\
4233     \000\000\000\000\000\000\000\000\110\000\005\000\115\000\000\000\
4234     \116\000\115\000\115\000\117\000\117\000\117\000\117\000\000\000\
4235     \067\000\000\000\000\000\000\000\000\000\000\000\117\000\117\000\
4236     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4237     \000\000\000\000\117\000\000\000\117\000\117\000\117\000\000\000\
4238     \117\000\115\000\117\000\000\000\000\000\000\000\000\000\000\000\
4239     \000\000\000\000\119\000\119\000\000\000\000\000\000\000\119\000\
4240     \119\000\000\000\067\000\118\000\119\000\000\000\000\000\000\000\
4241     \119\000\119\000\000\000\067\000\000\000\000\000\117\000\118\000\
4242     \115\000\118\000\118\000\118\000\119\000\119\000\119\000\119\000\
4243     \119\000\000\000\119\000\000\000\000\000\000\000\000\000\000\000\
4244     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4245     \000\000\000\000\000\000\067\000\117\000\000\000\000\000\000\000\
4246     \000\000\000\000\000\000\119\000\000\000\067\000\000\000\000\000\
4247     \119\000\000\000\000\000\000\000\000\000\000\000\003\000\000\000\
4248     \000\000\003\000\121\000\121\000\000\000\000\000\005\000\003\000\
4249     \003\000\000\000\003\000\007\000\121\000\000\000\000\000\000\000\
4250     \000\000\118\000\000\000\000\000\000\000\067\000\119\000\120\000\
4251     \000\000\007\000\007\000\007\000\003\000\121\000\000\000\000\000\
4252     \000\000\000\000\000\000\003\000\000\000\000\000\003\000\121\000\
4253     \121\000\000\000\000\000\094\000\003\000\003\000\000\000\003\000\
4254     \121\000\121\000\000\000\000\000\000\000\000\000\000\000\000\000\
4255     \000\000\003\000\005\000\121\000\122\000\000\000\121\000\121\000\
4256     \121\000\003\000\121\000\000\000\000\000\000\000\000\000\000\000\
4257     \003\000\000\000\000\000\003\000\121\000\121\000\000\000\000\000\
4258     \094\000\003\000\003\000\000\000\003\000\121\000\121\000\000\000\
4259     \000\000\120\000\005\000\003\000\000\000\000\000\003\000\094\000\
4260     \121\000\122\000\000\000\121\000\121\000\121\000\003\000\121\000\
4261     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\126\000\
4262     \000\000\000\000\125\000\000\000\000\000\000\000\000\000\000\000\
4263     \000\000\000\000\000\000\000\000\000\000\000\000\122\000\094\000\
4264     \003\000\000\000\000\000\003\000\094\000\121\000\000\000\129\000\
4265     \000\000\000\000\000\000\000\000\128\000\133\000\000\000\132\000\
4266     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4267     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4268     \000\000\131\000\000\000\122\000\094\000\003\000\130\000\130\000\
4269     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4270     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4271     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4272     \000\000\000\000\000\000\000\000\130\000\000\000\130\000\130\000\
4273     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4274     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4275     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4276     \157\000\157\000\157\000\157\000\157\000\157\000\157\000\157\000\
4277     \157\000\157\000\000\000\000\000\000\000\000\000\000\000\000\000\
4278     \000\000\157\000\157\000\157\000\157\000\157\000\157\000\000\000\
4279     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4280     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4281     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4282     \000\000\157\000\157\000\157\000\157\000\157\000\157\000\000\000\
4283     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4284     \000\000\000\000\000\000\000\000\000\000\130\000\130\000\130\000\
4285     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4286     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4287     \130\000\130\000\130\000\130\000\000\000\130\000\130\000\130\000\
4288     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4289     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4290     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4291     \130\000\130\000\130\000\130\000\000\000\130\000\130\000\130\000\
4292     \130\000\130\000\130\000\130\000\130\000\127\000\130\000\000\000\
4293     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\130\000\
4294     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4295     \130\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4296     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4297     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4298     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4299     \130\000\130\000\000\000\000\000\000\000\000\000\130\000\000\000\
4300     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4301     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4302     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4303     \130\000\130\000\000\000\000\000\000\000\000\000\000\000\000\000\
4304     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4305     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4306     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4307     \140\000\140\000\000\000\000\000\000\000\000\000\140\000\000\000\
4308     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4309     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4310     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4311     \140\000\140\000\000\000\000\000\000\000\000\000\000\000\130\000\
4312     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4313     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4314     \130\000\130\000\130\000\130\000\130\000\130\000\000\000\130\000\
4315     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4316     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4317     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
4318     \130\000\130\000\130\000\130\000\130\000\130\000\000\000\130\000\
4319     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\140\000\
4320     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4321     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4322     \140\000\140\000\140\000\140\000\140\000\140\000\000\000\140\000\
4323     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4324     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4325     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4326     \140\000\140\000\140\000\140\000\140\000\140\000\000\000\140\000\
4327     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\139\000\
4328     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4329     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4330     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4331     \139\000\000\000\000\000\000\000\000\000\139\000\000\000\139\000\
4332     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4333     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4334     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4335     \139\000\174\000\174\000\174\000\174\000\174\000\174\000\174\000\
4336     \174\000\174\000\174\000\000\000\000\000\000\000\000\000\000\000\
4337     \000\000\000\000\174\000\174\000\174\000\174\000\174\000\174\000\
4338     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4339     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4340     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4341     \000\000\000\000\174\000\174\000\174\000\174\000\174\000\174\000\
4342     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4343     \000\000\000\000\000\000\000\000\000\000\000\000\139\000\139\000\
4344     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4345     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4346     \139\000\139\000\139\000\139\000\139\000\000\000\139\000\139\000\
4347     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4348     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4349     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4350     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4351     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4352     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4353     \000\000\000\000\136\000\000\000\000\000\000\000\137\000\139\000\
4354     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4355     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4356     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4357     \139\000\000\000\000\000\000\000\000\000\139\000\000\000\139\000\
4358     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4359     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4360     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4361     \139\000\175\000\175\000\175\000\175\000\175\000\175\000\175\000\
4362     \175\000\175\000\175\000\000\000\000\000\000\000\000\000\000\000\
4363     \000\000\000\000\175\000\175\000\175\000\175\000\175\000\175\000\
4364     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4365     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4366     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4367     \000\000\000\000\175\000\175\000\175\000\175\000\175\000\175\000\
4368     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4369     \000\000\000\000\000\000\000\000\000\000\000\000\139\000\139\000\
4370     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4371     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4372     \139\000\139\000\139\000\139\000\139\000\000\000\139\000\139\000\
4373     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4374     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4375     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
4376     \139\000\139\000\139\000\139\000\139\000\140\000\139\000\139\000\
4377     \139\000\139\000\139\000\139\000\139\000\139\000\140\000\140\000\
4378     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4379     \000\000\000\000\136\000\000\000\000\000\000\000\000\000\140\000\
4380     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4381     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4382     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4383     \140\000\000\000\000\000\000\000\000\000\140\000\000\000\140\000\
4384     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4385     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4386     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4387     \140\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4388     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4389     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4390     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4391     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4392     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4393     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4394     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4395     \000\000\000\000\000\000\000\000\000\000\000\000\140\000\140\000\
4396     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4397     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4398     \140\000\140\000\140\000\140\000\140\000\000\000\140\000\140\000\
4399     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4400     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4401     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
4402     \140\000\140\000\140\000\140\000\140\000\000\000\140\000\140\000\
4403     \140\000\140\000\140\000\140\000\140\000\140\000\151\000\000\000\
4404     \151\000\000\000\000\000\171\000\000\000\151\000\170\000\000\000\
4405     \000\000\000\000\000\000\000\000\000\000\000\000\150\000\150\000\
4406     \150\000\150\000\150\000\150\000\150\000\150\000\150\000\150\000\
4407     \000\000\169\000\000\000\169\000\000\000\000\000\000\000\000\000\
4408     \169\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4409     \000\000\168\000\168\000\168\000\168\000\168\000\168\000\168\000\
4410     \168\000\168\000\168\000\000\000\000\000\000\000\000\000\000\000\
4411     \000\000\000\000\151\000\000\000\000\000\000\000\000\000\000\000\
4412     \151\000\176\000\000\000\000\000\176\000\176\000\176\000\000\000\
4413     \000\000\000\000\176\000\176\000\151\000\176\000\176\000\176\000\
4414     \151\000\000\000\151\000\000\000\000\000\169\000\149\000\000\000\
4415     \000\000\000\000\176\000\169\000\176\000\176\000\176\000\176\000\
4416     \176\000\000\000\000\000\000\000\000\000\000\000\000\000\169\000\
4417     \000\000\000\000\000\000\169\000\000\000\169\000\000\000\000\000\
4418     \000\000\167\000\000\000\000\000\000\000\000\000\000\000\000\000\
4419     \000\000\000\000\000\000\000\000\176\000\000\000\176\000\000\000\
4420     \000\000\000\000\000\000\000\000\178\000\000\000\000\000\178\000\
4421     \178\000\178\000\000\000\000\000\000\000\178\000\178\000\000\000\
4422     \178\000\178\000\178\000\000\000\000\000\000\000\000\000\000\000\
4423     \000\000\000\000\000\000\000\000\176\000\178\000\176\000\178\000\
4424     \178\000\178\000\178\000\178\000\179\000\179\000\179\000\179\000\
4425     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4426     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4427     \179\000\179\000\179\000\179\000\179\000\179\000\000\000\178\000\
4428     \000\000\178\000\179\000\000\000\179\000\179\000\179\000\179\000\
4429     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4430     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4431     \179\000\179\000\179\000\179\000\179\000\179\000\000\000\178\000\
4432     \000\000\178\000\000\000\000\000\000\000\000\000\000\000\000\000\
4433     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4434     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4435     \000\000\255\255\000\000\000\000\000\000\000\000\000\000\000\000\
4436     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4437     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4438     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4439     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4440     \000\000\000\000\000\000\179\000\179\000\179\000\179\000\179\000\
4441     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4442     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4443     \179\000\179\000\000\000\179\000\179\000\179\000\179\000\179\000\
4444     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4445     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4446     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4447     \179\000\179\000\000\000\179\000\179\000\179\000\179\000\179\000\
4448     \179\000\179\000\179\000\178\000\000\000\000\000\178\000\178\000\
4449     \178\000\000\000\000\000\000\000\178\000\178\000\000\000\178\000\
4450     \178\000\178\000\000\000\000\000\000\000\000\000\000\000\000\000\
4451     \000\000\000\000\000\000\000\000\178\000\000\000\178\000\178\000\
4452     \178\000\178\000\178\000\000\000\000\000\000\000\000\000\179\000\
4453     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4454     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4455     \179\000\179\000\000\000\000\000\180\000\000\000\178\000\000\000\
4456     \178\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4457     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4458     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4459     \179\000\179\000\179\000\000\000\000\000\000\000\178\000\179\000\
4460     \178\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4461     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4462     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4463     \179\000\179\000\179\000\000\000\000\000\000\000\000\000\000\000\
4464     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4465     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4466     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4467     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4468     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4469     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4470     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4471     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4472     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4473     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4474     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\000\000\
4475     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4476     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4477     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4478     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\000\000\
4479     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
4480     \182\000\000\000\000\000\182\000\182\000\182\000\000\000\000\000\
4481     \000\000\182\000\182\000\000\000\182\000\182\000\182\000\000\000\
4482     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4483     \000\000\182\000\000\000\182\000\182\000\182\000\182\000\182\000\
4484     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4485     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4486     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4487     \183\000\183\000\000\000\182\000\000\000\182\000\183\000\000\000\
4488     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4489     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4490     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4491     \183\000\183\000\000\000\182\000\000\000\182\000\000\000\000\000\
4492     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4493     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4494     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4495     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4496     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4497     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4498     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4499     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\183\000\
4500     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4501     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4502     \183\000\183\000\183\000\183\000\183\000\183\000\000\000\183\000\
4503     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4504     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4505     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4506     \183\000\183\000\183\000\183\000\183\000\183\000\000\000\183\000\
4507     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\182\000\
4508     \000\000\000\000\182\000\182\000\182\000\000\000\000\000\000\000\
4509     \182\000\182\000\000\000\182\000\182\000\182\000\000\000\000\000\
4510     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4511     \182\000\000\000\182\000\182\000\182\000\182\000\182\000\000\000\
4512     \000\000\000\000\000\000\000\000\000\000\000\000\183\000\000\000\
4513     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\183\000\
4514     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4515     \183\000\000\000\182\000\185\000\182\000\000\000\000\000\184\000\
4516     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4517     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4518     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4519     \183\000\183\000\182\000\000\000\182\000\000\000\183\000\000\000\
4520     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4521     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4522     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4523     \183\000\183\000\000\000\000\000\000\000\000\000\000\000\000\000\
4524     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4525     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4526     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4527     \186\000\186\000\000\000\000\000\000\000\000\000\186\000\000\000\
4528     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4529     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4530     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4531     \186\000\186\000\000\000\000\000\000\000\000\000\000\000\183\000\
4532     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4533     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4534     \183\000\183\000\183\000\183\000\183\000\183\000\000\000\183\000\
4535     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4536     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4537     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
4538     \183\000\183\000\183\000\183\000\183\000\183\000\000\000\183\000\
4539     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\186\000\
4540     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4541     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4542     \186\000\186\000\186\000\186\000\186\000\186\000\000\000\186\000\
4543     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4544     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4545     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4546     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4547     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4548     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4549     \186\000\000\000\000\000\187\000\000\000\000\000\000\000\000\000\
4550     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4551     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4552     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4553     \186\000\186\000\000\000\000\000\000\000\000\000\186\000\000\000\
4554     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4555     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4556     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4557     \186\000\186\000\000\000\000\000\000\000\000\000\000\000\000\000\
4558     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4559     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4560     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4561     \199\000\199\000\000\000\000\000\000\000\000\000\199\000\000\000\
4562     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4563     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4564     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4565     \199\000\199\000\000\000\000\000\000\000\000\000\000\000\186\000\
4566     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4567     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4568     \186\000\186\000\186\000\186\000\186\000\186\000\000\000\186\000\
4569     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4570     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4571     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
4572     \186\000\186\000\186\000\186\000\186\000\186\000\000\000\186\000\
4573     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\199\000\
4574     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4575     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4576     \199\000\199\000\199\000\199\000\199\000\199\000\000\000\199\000\
4577     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4578     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4579     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4580     \199\000\199\000\199\000\199\000\199\000\199\000\000\000\199\000\
4581     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\198\000\
4582     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4583     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4584     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4585     \198\000\000\000\000\000\000\000\000\000\198\000\000\000\198\000\
4586     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4587     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4588     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4589     \198\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4590     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4591     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4592     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4593     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4594     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4595     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4596     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4597     \000\000\000\000\000\000\000\000\000\000\000\000\198\000\198\000\
4598     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4599     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4600     \198\000\198\000\198\000\198\000\198\000\000\000\198\000\198\000\
4601     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4602     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4603     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4604     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4605     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4606     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4607     \000\000\000\000\195\000\000\000\000\000\000\000\196\000\198\000\
4608     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4609     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4610     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4611     \198\000\000\000\000\000\000\000\000\000\198\000\000\000\198\000\
4612     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4613     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4614     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4615     \198\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4616     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4617     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4618     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4619     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4620     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4621     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4622     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4623     \000\000\000\000\000\000\000\000\000\000\000\000\198\000\198\000\
4624     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4625     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4626     \198\000\198\000\198\000\198\000\198\000\000\000\198\000\198\000\
4627     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4628     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4629     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
4630     \198\000\198\000\198\000\198\000\198\000\199\000\198\000\198\000\
4631     \198\000\198\000\198\000\198\000\198\000\198\000\199\000\199\000\
4632     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4633     \000\000\000\000\195\000\000\000\000\000\000\000\000\000\199\000\
4634     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4635     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4636     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4637     \199\000\000\000\000\000\000\000\000\000\199\000\000\000\199\000\
4638     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4639     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4640     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4641     \199\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4642     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4643     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4644     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4645     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4646     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4647     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4648     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4649     \000\000\000\000\000\000\000\000\000\000\000\000\199\000\199\000\
4650     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4651     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4652     \199\000\199\000\199\000\199\000\199\000\000\000\199\000\199\000\
4653     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4654     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4655     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
4656     \199\000\199\000\199\000\199\000\199\000\000\000\199\000\199\000\
4657     \199\000\199\000\199\000\199\000\199\000\199\000\207\000\000\000\
4658     \000\000\205\000\000\000\000\000\000\000\000\000\000\000\000\000\
4659     \204\000\000\000\205\000\205\000\205\000\205\000\205\000\205\000\
4660     \205\000\205\000\205\000\205\000\203\000\000\000\000\000\000\000\
4661     \000\000\000\000\000\000\205\000\205\000\205\000\205\000\205\000\
4662     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
4663     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
4664     \205\000\205\000\205\000\205\000\205\000\000\000\000\000\000\000\
4665     \000\000\205\000\206\000\205\000\205\000\205\000\205\000\205\000\
4666     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
4667     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
4668     \205\000\205\000\205\000\205\000\205\000\000\000\000\000\000\000\
4669     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4670     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4671     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4672     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4673     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4674     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4675     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4676     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4677     \000\000\000\000\205\000\205\000\205\000\205\000\205\000\205\000\
4678     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
4679     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
4680     \205\000\000\000\205\000\205\000\205\000\205\000\205\000\205\000\
4681     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
4682     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
4683     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
4684     \205\000\000\000\205\000\205\000\205\000\205\000\205\000\205\000\
4685     \205\000\205\000\255\255\209\000\000\000\000\000\000\000\000\000\
4686     \000\000\000\000\000\000\000\000\209\000\209\000\209\000\209\000\
4687     \209\000\209\000\209\000\209\000\209\000\209\000\203\000\000\000\
4688     \000\000\000\000\000\000\000\000\000\000\209\000\209\000\209\000\
4689     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4690     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4691     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\000\000\
4692     \000\000\000\000\000\000\209\000\000\000\209\000\209\000\209\000\
4693     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4694     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4695     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\000\000\
4696     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4697     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4698     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4699     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4700     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4701     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4702     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4703     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4704     \000\000\000\000\000\000\000\000\209\000\209\000\209\000\209\000\
4705     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4706     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4707     \209\000\209\000\209\000\000\000\209\000\209\000\209\000\209\000\
4708     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4709     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4710     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4711     \209\000\209\000\209\000\000\000\209\000\209\000\209\000\209\000\
4712     \209\000\209\000\209\000\209\000\209\000\000\000\000\000\000\000\
4713     \000\000\000\000\000\000\208\000\000\000\209\000\209\000\209\000\
4714     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\203\000\
4715     \000\000\000\000\000\000\000\000\000\000\000\000\209\000\209\000\
4716     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4717     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4718     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4719     \000\000\000\000\000\000\000\000\209\000\000\000\209\000\209\000\
4720     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4721     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4722     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4723     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4724     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4725     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4726     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4727     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4728     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4729     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4730     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4731     \000\000\000\000\000\000\000\000\000\000\209\000\209\000\209\000\
4732     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4733     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4734     \209\000\209\000\209\000\209\000\000\000\209\000\209\000\209\000\
4735     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4736     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4737     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4738     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4739     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4740     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\203\000\
4741     \000\000\000\000\000\000\000\000\000\000\000\000\209\000\209\000\
4742     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4743     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4744     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4745     \000\000\000\000\000\000\000\000\209\000\000\000\209\000\209\000\
4746     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4747     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4748     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4749     \000\000\000\000\000\000\000\000\000\000\000\000\221\000\221\000\
4750     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4751     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4752     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4753     \000\000\000\000\000\000\000\000\221\000\000\000\221\000\221\000\
4754     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4755     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4756     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4757     \000\000\000\000\000\000\000\000\000\000\209\000\209\000\209\000\
4758     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4759     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4760     \209\000\209\000\209\000\209\000\000\000\209\000\209\000\209\000\
4761     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4762     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4763     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
4764     \209\000\209\000\209\000\209\000\000\000\209\000\209\000\209\000\
4765     \209\000\209\000\209\000\209\000\209\000\221\000\221\000\221\000\
4766     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4767     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4768     \221\000\221\000\221\000\221\000\000\000\221\000\221\000\221\000\
4769     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4770     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4771     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4772     \221\000\221\000\221\000\221\000\000\000\221\000\221\000\221\000\
4773     \221\000\221\000\221\000\221\000\221\000\220\000\220\000\220\000\
4774     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4775     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4776     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\000\000\
4777     \000\000\000\000\000\000\220\000\000\000\220\000\220\000\220\000\
4778     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4779     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4780     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\000\000\
4781     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4782     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4783     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4784     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4785     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4786     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4787     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4788     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4789     \000\000\000\000\000\000\000\000\220\000\220\000\220\000\220\000\
4790     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4791     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4792     \220\000\220\000\220\000\000\000\220\000\220\000\220\000\220\000\
4793     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4794     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4795     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4796     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4797     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4798     \220\000\220\000\220\000\220\000\220\000\220\000\000\000\000\000\
4799     \217\000\000\000\000\000\000\000\218\000\220\000\220\000\220\000\
4800     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4801     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4802     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\000\000\
4803     \000\000\000\000\000\000\220\000\000\000\220\000\220\000\220\000\
4804     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4805     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4806     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\000\000\
4807     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4808     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4809     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4810     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4811     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4812     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4813     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4814     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4815     \000\000\000\000\000\000\000\000\220\000\220\000\220\000\220\000\
4816     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4817     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4818     \220\000\220\000\220\000\000\000\220\000\220\000\220\000\220\000\
4819     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4820     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4821     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
4822     \220\000\220\000\220\000\221\000\220\000\220\000\220\000\220\000\
4823     \220\000\220\000\220\000\220\000\221\000\221\000\221\000\221\000\
4824     \221\000\221\000\221\000\221\000\221\000\221\000\000\000\000\000\
4825     \217\000\000\000\000\000\000\000\000\000\221\000\221\000\221\000\
4826     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4827     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4828     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\000\000\
4829     \000\000\000\000\000\000\221\000\000\000\221\000\221\000\221\000\
4830     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4831     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4832     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\000\000\
4833     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4834     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4835     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4836     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4837     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4838     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4839     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4840     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4841     \000\000\000\000\000\000\000\000\221\000\221\000\221\000\221\000\
4842     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4843     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4844     \221\000\221\000\221\000\000\000\221\000\221\000\221\000\221\000\
4845     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4846     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4847     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
4848     \221\000\221\000\221\000\000\000\221\000\221\000\221\000\221\000\
4849     \221\000\221\000\221\000\221\000\000\000";
4850                 Lexing.lex_check =
4851                   "\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
4852     \255\255\000\000\000\000\029\000\000\000\000\000\101\000\107\000\
4853     \125\000\162\000\103\000\106\000\190\000\103\000\106\000\213\000\
4854     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
4855     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4856     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4857     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4858     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4859     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4860     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4861     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4862     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4863     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4864     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4865     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4866     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\012\000\
4867     \010\000\010\000\049\000\016\000\051\000\028\000\040\000\040\000\
4868     \028\000\010\000\010\000\041\000\041\000\041\000\041\000\041\000\
4869     \041\000\041\000\041\000\057\000\065\000\010\000\132\000\010\000\
4870     \010\000\010\000\016\000\010\000\028\000\047\000\047\000\047\000\
4871     \047\000\047\000\047\000\047\000\047\000\047\000\047\000\133\000\
4872     \142\000\144\000\016\000\016\000\016\000\016\000\016\000\016\000\
4873     \016\000\016\000\016\000\016\000\145\000\131\000\151\000\131\000\
4874     \154\000\010\000\020\000\131\000\157\000\020\000\193\000\255\255\
4875     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4876     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4877     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\010\000\
4878     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4879     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4880     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4881     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\204\000\
4882     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
4883     \000\000\003\000\255\255\204\000\003\000\003\000\003\000\050\000\
4884     \103\000\106\000\003\000\003\000\020\000\003\000\003\000\003\000\
4885     \039\000\039\000\039\000\039\000\039\000\039\000\039\000\039\000\
4886     \039\000\039\000\003\000\143\000\003\000\003\000\003\000\003\000\
4887     \003\000\255\255\005\000\005\000\050\000\039\000\005\000\255\255\
4888     \038\000\255\255\038\000\005\000\005\000\038\000\038\000\038\000\
4889     \038\000\038\000\038\000\038\000\038\000\038\000\038\000\005\000\
4890     \143\000\005\000\005\000\005\000\003\000\005\000\003\000\039\000\
4891     \104\000\255\255\171\000\104\000\006\000\039\000\255\255\006\000\
4892     \006\000\006\000\208\000\255\255\006\000\006\000\006\000\255\255\
4893     \006\000\006\000\006\000\255\255\068\000\255\255\208\000\068\000\
4894     \104\000\171\000\005\000\005\000\003\000\006\000\003\000\006\000\
4895     \006\000\006\000\006\000\006\000\170\000\170\000\255\255\255\255\
4896     \255\255\007\000\255\255\068\000\007\000\007\000\007\000\255\255\
4897     \255\255\007\000\007\000\007\000\068\000\007\000\007\000\007\000\
4898     \255\255\005\000\005\000\170\000\255\255\255\255\255\255\006\000\
4899     \006\000\006\000\007\000\255\255\007\000\007\000\007\000\007\000\
4900     \007\000\194\000\212\000\194\000\212\000\255\255\008\000\194\000\
4901     \212\000\008\000\008\000\008\000\255\255\255\255\008\000\008\000\
4902     \008\000\255\255\008\000\008\000\008\000\255\255\255\255\006\000\
4903     \006\000\006\000\255\255\255\255\007\000\007\000\007\000\008\000\
4904     \255\255\008\000\008\000\008\000\008\000\008\000\188\000\255\255\
4905     \020\000\188\000\255\255\009\000\255\255\255\255\009\000\009\000\
4906     \009\000\255\255\255\255\009\000\009\000\009\000\255\255\009\000\
4907     \009\000\009\000\255\255\255\255\007\000\007\000\007\000\255\255\
4908     \255\255\008\000\008\000\008\000\009\000\255\255\009\000\009\000\
4909     \009\000\009\000\009\000\255\255\255\255\255\255\255\255\255\255\
4910     \210\000\255\255\255\255\210\000\011\000\011\000\255\255\255\255\
4911     \188\000\255\255\188\000\013\000\013\000\011\000\011\000\013\000\
4912     \255\255\008\000\008\000\008\000\013\000\013\000\009\000\009\000\
4913     \009\000\011\000\210\000\011\000\011\000\011\000\255\255\011\000\
4914     \013\000\255\255\013\000\013\000\013\000\255\255\013\000\014\000\
4915     \014\000\255\255\080\000\014\000\255\255\080\000\255\255\255\255\
4916     \014\000\014\000\210\000\255\255\255\255\255\255\009\000\009\000\
4917     \009\000\255\255\255\255\255\255\014\000\011\000\014\000\014\000\
4918     \014\000\080\000\014\000\013\000\013\000\045\000\045\000\255\255\
4919     \255\255\255\255\080\000\017\000\255\255\255\255\017\000\017\000\
4920     \017\000\255\255\255\255\017\000\017\000\017\000\255\255\017\000\
4921     \017\000\017\000\255\255\011\000\255\255\255\255\104\000\014\000\
4922     \014\000\045\000\013\000\013\000\017\000\255\255\017\000\017\000\
4923     \017\000\017\000\017\000\255\255\255\255\255\255\255\255\255\255\
4924     \255\255\255\255\255\255\255\255\045\000\044\000\044\000\044\000\
4925     \044\000\044\000\044\000\044\000\044\000\255\255\014\000\014\000\
4926     \255\255\045\000\255\255\045\000\255\255\255\255\017\000\017\000\
4927     \017\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
4928     \018\000\044\000\255\255\018\000\018\000\018\000\255\255\255\255\
4929     \018\000\018\000\018\000\255\255\018\000\018\000\018\000\019\000\
4930     \255\255\255\255\019\000\255\255\044\000\255\255\017\000\017\000\
4931     \017\000\018\000\255\255\018\000\018\000\018\000\018\000\018\000\
4932     \255\255\044\000\255\255\044\000\255\255\255\255\019\000\019\000\
4933     \255\255\255\255\019\000\019\000\019\000\255\255\255\255\255\255\
4934     \019\000\019\000\255\255\019\000\019\000\019\000\128\000\255\255\
4935     \255\255\128\000\255\255\018\000\188\000\018\000\255\255\255\255\
4936     \019\000\255\255\019\000\019\000\019\000\019\000\019\000\022\000\
4937     \255\255\022\000\022\000\022\000\022\000\022\000\022\000\022\000\
4938     \022\000\022\000\022\000\128\000\255\255\255\255\255\255\255\255\
4939     \255\255\255\255\255\255\018\000\255\255\018\000\022\000\255\255\
4940     \255\255\255\255\019\000\255\255\019\000\022\000\210\000\255\255\
4941     \023\000\255\255\023\000\023\000\023\000\023\000\023\000\023\000\
4942     \023\000\023\000\023\000\023\000\255\255\255\255\255\255\255\255\
4943     \022\000\255\255\255\255\255\255\023\000\255\255\022\000\023\000\
4944     \255\255\255\255\019\000\255\255\019\000\022\000\023\000\022\000\
4945     \128\000\023\000\255\255\255\255\255\255\255\255\255\255\255\255\
4946     \255\255\255\255\023\000\255\255\255\255\255\255\105\000\105\000\
4947     \255\255\023\000\105\000\255\255\023\000\255\255\255\255\023\000\
4948     \255\255\255\255\255\255\255\255\255\255\255\255\023\000\255\255\
4949     \023\000\023\000\024\000\255\255\255\255\105\000\255\255\105\000\
4950     \255\255\255\255\023\000\024\000\024\000\024\000\024\000\024\000\
4951     \024\000\024\000\024\000\024\000\024\000\255\255\255\255\255\255\
4952     \255\255\255\255\255\255\255\255\024\000\024\000\024\000\024\000\
4953     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
4954     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
4955     \024\000\024\000\024\000\024\000\024\000\024\000\255\255\255\255\
4956     \255\255\255\255\024\000\255\255\024\000\024\000\024\000\024\000\
4957     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
4958     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
4959     \024\000\024\000\024\000\024\000\024\000\024\000\042\000\042\000\
4960     \042\000\042\000\042\000\042\000\042\000\042\000\042\000\042\000\
4961     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\042\000\
4962     \042\000\042\000\042\000\042\000\042\000\056\000\056\000\056\000\
4963     \056\000\056\000\056\000\056\000\056\000\056\000\056\000\058\000\
4964     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
4965     \058\000\255\255\255\255\255\255\128\000\255\255\255\255\042\000\
4966     \042\000\042\000\042\000\042\000\042\000\150\000\150\000\150\000\
4967     \150\000\150\000\150\000\150\000\150\000\150\000\150\000\255\255\
4968     \255\255\255\255\255\255\024\000\024\000\024\000\024\000\024\000\
4969     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
4970     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
4971     \024\000\024\000\255\255\024\000\024\000\024\000\024\000\024\000\
4972     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
4973     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
4974     \024\000\024\000\024\000\024\000\024\000\024\000\024\000\024\000\
4975     \024\000\024\000\025\000\024\000\024\000\024\000\024\000\024\000\
4976     \024\000\024\000\024\000\025\000\025\000\025\000\025\000\025\000\
4977     \025\000\025\000\025\000\025\000\025\000\105\000\255\255\255\255\
4978     \255\255\255\255\255\255\255\255\025\000\025\000\025\000\025\000\
4979     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
4980     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
4981     \025\000\025\000\025\000\025\000\025\000\025\000\255\255\255\255\
4982     \255\255\255\255\025\000\255\255\025\000\025\000\025\000\025\000\
4983     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
4984     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
4985     \025\000\025\000\025\000\025\000\025\000\025\000\043\000\043\000\
4986     \043\000\043\000\043\000\043\000\043\000\043\000\043\000\043\000\
4987     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\043\000\
4988     \043\000\043\000\043\000\043\000\043\000\255\255\255\255\255\255\
4989     \255\255\255\255\043\000\153\000\153\000\153\000\153\000\153\000\
4990     \153\000\153\000\153\000\153\000\153\000\255\255\255\255\255\255\
4991     \159\000\255\255\255\255\159\000\255\255\043\000\255\255\043\000\
4992     \043\000\043\000\043\000\043\000\043\000\255\255\255\255\255\255\
4993     \255\255\255\255\043\000\255\255\043\000\255\255\255\255\255\255\
4994     \159\000\255\255\255\255\025\000\025\000\025\000\025\000\025\000\
4995     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
4996     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
4997     \025\000\025\000\255\255\025\000\025\000\025\000\025\000\025\000\
4998     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
4999     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
5000     \025\000\025\000\025\000\025\000\025\000\025\000\025\000\025\000\
5001     \025\000\025\000\159\000\025\000\025\000\025\000\025\000\025\000\
5002     \025\000\025\000\025\000\026\000\255\255\255\255\026\000\026\000\
5003     \026\000\255\255\255\255\255\255\026\000\026\000\255\255\026\000\
5004     \026\000\026\000\168\000\168\000\168\000\168\000\168\000\168\000\
5005     \168\000\168\000\168\000\168\000\026\000\255\255\026\000\026\000\
5006     \026\000\026\000\026\000\172\000\172\000\172\000\172\000\172\000\
5007     \172\000\172\000\172\000\172\000\172\000\255\255\046\000\046\000\
5008     \046\000\046\000\046\000\046\000\046\000\046\000\046\000\046\000\
5009     \255\255\255\255\255\255\255\255\255\255\255\255\026\000\255\255\
5010     \026\000\026\000\255\255\026\000\026\000\026\000\026\000\026\000\
5011     \026\000\026\000\026\000\026\000\026\000\026\000\026\000\026\000\
5012     \026\000\026\000\026\000\026\000\026\000\026\000\026\000\026\000\
5013     \026\000\026\000\026\000\026\000\026\000\046\000\026\000\027\000\
5014     \026\000\255\255\027\000\027\000\027\000\255\255\255\255\255\255\
5015     \027\000\027\000\255\255\027\000\027\000\027\000\255\255\255\255\
5016     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5017     \027\000\255\255\027\000\027\000\027\000\027\000\027\000\255\255\
5018     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5019     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5020     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5021     \255\255\255\255\027\000\255\255\027\000\027\000\159\000\027\000\
5022     \027\000\027\000\027\000\027\000\027\000\027\000\027\000\027\000\
5023     \027\000\027\000\027\000\027\000\027\000\027\000\027\000\027\000\
5024     \027\000\027\000\027\000\027\000\027\000\027\000\027\000\027\000\
5025     \027\000\255\255\027\000\255\255\027\000\255\255\255\255\255\255\
5026     \255\255\026\000\026\000\026\000\026\000\026\000\026\000\026\000\
5027     \026\000\026\000\026\000\026\000\026\000\026\000\026\000\026\000\
5028     \026\000\026\000\026\000\026\000\026\000\026\000\026\000\026\000\
5029     \026\000\100\000\026\000\026\000\026\000\026\000\026\000\026\000\
5030     \026\000\026\000\055\000\055\000\055\000\055\000\055\000\055\000\
5031     \055\000\055\000\055\000\055\000\255\255\255\255\255\255\255\255\
5032     \100\000\255\255\255\255\055\000\055\000\055\000\055\000\055\000\
5033     \055\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5034     \100\000\100\000\100\000\100\000\100\000\100\000\100\000\100\000\
5035     \100\000\100\000\255\255\255\255\255\255\255\255\255\255\255\255\
5036     \255\255\255\255\255\255\055\000\055\000\055\000\055\000\055\000\
5037     \055\000\255\255\255\255\255\255\255\255\027\000\027\000\027\000\
5038     \027\000\027\000\027\000\027\000\027\000\027\000\027\000\027\000\
5039     \027\000\027\000\027\000\027\000\027\000\027\000\027\000\027\000\
5040     \027\000\027\000\027\000\027\000\027\000\031\000\027\000\027\000\
5041     \027\000\027\000\027\000\027\000\027\000\027\000\031\000\031\000\
5042     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5043     \031\000\255\255\255\255\255\255\255\255\255\255\255\255\031\000\
5044     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5045     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5046     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5047     \031\000\255\255\255\255\255\255\255\255\031\000\255\255\031\000\
5048     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5049     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5050     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5051     \031\000\059\000\059\000\059\000\059\000\059\000\059\000\059\000\
5052     \059\000\059\000\059\000\255\255\255\255\255\255\255\255\255\255\
5053     \255\255\255\255\059\000\059\000\059\000\059\000\059\000\059\000\
5054     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5055     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5056     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5057     \255\255\255\255\059\000\059\000\059\000\059\000\059\000\059\000\
5058     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5059     \255\255\255\255\255\255\255\255\255\255\255\255\031\000\031\000\
5060     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5061     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5062     \031\000\031\000\031\000\031\000\031\000\255\255\031\000\031\000\
5063     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5064     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5065     \031\000\031\000\031\000\031\000\031\000\031\000\031\000\031\000\
5066     \031\000\031\000\031\000\031\000\031\000\033\000\031\000\031\000\
5067     \031\000\031\000\031\000\031\000\031\000\031\000\033\000\033\000\
5068     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5069     \033\000\255\255\255\255\255\255\255\255\255\255\255\255\033\000\
5070     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5071     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5072     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5073     \033\000\255\255\255\255\255\255\255\255\033\000\255\255\033\000\
5074     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5075     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5076     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5077     \033\000\255\255\255\255\255\255\099\000\099\000\255\255\255\255\
5078     \099\000\255\255\255\255\255\255\255\255\149\000\149\000\149\000\
5079     \149\000\149\000\149\000\149\000\149\000\149\000\149\000\255\255\
5080     \255\255\255\255\255\255\099\000\255\255\099\000\149\000\149\000\
5081     \149\000\149\000\149\000\149\000\255\255\255\255\255\255\255\255\
5082     \255\255\255\255\255\255\099\000\099\000\099\000\099\000\099\000\
5083     \099\000\099\000\099\000\099\000\099\000\255\255\255\255\255\255\
5084     \255\255\255\255\255\255\255\255\255\255\255\255\149\000\149\000\
5085     \149\000\149\000\149\000\149\000\255\255\255\255\033\000\033\000\
5086     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5087     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5088     \033\000\033\000\033\000\033\000\033\000\255\255\033\000\033\000\
5089     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5090     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5091     \033\000\033\000\033\000\033\000\033\000\033\000\033\000\033\000\
5092     \033\000\033\000\033\000\033\000\033\000\255\255\033\000\033\000\
5093     \033\000\033\000\033\000\033\000\033\000\033\000\048\000\255\255\
5094     \048\000\255\255\255\255\255\255\255\255\048\000\255\255\255\255\
5095     \060\000\255\255\255\255\060\000\255\255\255\255\048\000\048\000\
5096     \048\000\048\000\048\000\048\000\048\000\048\000\048\000\048\000\
5097     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\060\000\
5098     \060\000\255\255\255\255\060\000\060\000\060\000\255\255\255\255\
5099     \255\255\060\000\060\000\255\255\060\000\060\000\060\000\255\255\
5100     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5101     \255\255\060\000\048\000\060\000\060\000\060\000\060\000\060\000\
5102     \048\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5103     \255\255\255\255\255\255\061\000\048\000\255\255\061\000\255\255\
5104     \048\000\255\255\048\000\255\255\255\255\255\255\048\000\255\255\
5105     \255\255\255\255\255\255\060\000\255\255\060\000\255\255\255\255\
5106     \255\255\255\255\061\000\061\000\255\255\255\255\061\000\061\000\
5107     \061\000\255\255\255\255\061\000\061\000\061\000\255\255\061\000\
5108     \061\000\061\000\062\000\099\000\255\255\062\000\255\255\255\255\
5109     \255\255\255\255\255\255\060\000\061\000\060\000\061\000\061\000\
5110     \061\000\061\000\061\000\255\255\255\255\255\255\255\255\255\255\
5111     \255\255\062\000\062\000\255\255\255\255\062\000\062\000\062\000\
5112     \255\255\255\255\062\000\062\000\062\000\255\255\062\000\062\000\
5113     \062\000\255\255\255\255\255\255\255\255\255\255\061\000\255\255\
5114     \061\000\255\255\255\255\062\000\255\255\062\000\062\000\062\000\
5115     \062\000\062\000\255\255\255\255\255\255\255\255\255\255\255\255\
5116     \255\255\255\255\255\255\255\255\255\255\063\000\255\255\255\255\
5117     \063\000\255\255\255\255\255\255\255\255\255\255\061\000\255\255\
5118     \061\000\255\255\255\255\255\255\255\255\062\000\255\255\062\000\
5119     \255\255\255\255\255\255\255\255\063\000\063\000\255\255\255\255\
5120     \063\000\063\000\063\000\255\255\255\255\063\000\063\000\063\000\
5121     \255\255\063\000\063\000\063\000\064\000\255\255\048\000\064\000\
5122     \255\255\255\255\255\255\255\255\255\255\062\000\063\000\062\000\
5123     \063\000\063\000\063\000\063\000\063\000\255\255\255\255\255\255\
5124     \255\255\255\255\255\255\064\000\064\000\255\255\255\255\064\000\
5125     \064\000\064\000\255\255\064\000\064\000\064\000\064\000\255\255\
5126     \064\000\064\000\064\000\255\255\255\255\255\255\255\255\255\255\
5127     \063\000\255\255\063\000\067\000\067\000\064\000\067\000\064\000\
5128     \064\000\064\000\064\000\064\000\067\000\067\000\255\255\255\255\
5129     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5130     \067\000\255\255\067\000\067\000\067\000\255\255\067\000\255\255\
5131     \063\000\255\255\063\000\255\255\255\255\255\255\064\000\064\000\
5132     \255\255\064\000\255\255\255\255\255\255\255\255\255\255\255\255\
5133     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5134     \255\255\067\000\255\255\069\000\067\000\255\255\069\000\255\255\
5135     \255\255\255\255\255\255\255\255\255\255\255\255\064\000\064\000\
5136     \255\255\064\000\255\255\255\255\255\255\255\255\255\255\255\255\
5137     \255\255\255\255\069\000\069\000\255\255\255\255\069\000\069\000\
5138     \069\000\067\000\067\000\069\000\069\000\069\000\255\255\069\000\
5139     \069\000\069\000\070\000\255\255\255\255\070\000\255\255\255\255\
5140     \255\255\255\255\255\255\255\255\069\000\255\255\069\000\069\000\
5141     \069\000\069\000\069\000\255\255\255\255\255\255\255\255\255\255\
5142     \255\255\070\000\070\000\255\255\255\255\070\000\070\000\070\000\
5143     \255\255\070\000\070\000\070\000\070\000\255\255\070\000\070\000\
5144     \070\000\255\255\255\255\255\255\255\255\255\255\069\000\255\255\
5145     \069\000\255\255\255\255\070\000\255\255\070\000\070\000\070\000\
5146     \070\000\070\000\255\255\255\255\255\255\255\255\255\255\255\255\
5147     \255\255\255\255\255\255\255\255\255\255\071\000\255\255\255\255\
5148     \071\000\255\255\255\255\255\255\255\255\255\255\069\000\255\255\
5149     \069\000\255\255\255\255\255\255\070\000\070\000\255\255\070\000\
5150     \255\255\255\255\255\255\255\255\071\000\071\000\255\255\255\255\
5151     \071\000\071\000\071\000\255\255\255\255\255\255\071\000\071\000\
5152     \255\255\071\000\071\000\071\000\075\000\255\255\255\255\075\000\
5153     \255\255\255\255\255\255\255\255\070\000\070\000\071\000\070\000\
5154     \071\000\071\000\071\000\071\000\071\000\255\255\255\255\255\255\
5155     \255\255\255\255\255\255\075\000\075\000\255\255\255\255\075\000\
5156     \075\000\075\000\255\255\255\255\075\000\075\000\075\000\255\255\
5157     \075\000\075\000\075\000\255\255\255\255\255\255\255\255\255\255\
5158     \071\000\255\255\071\000\255\255\255\255\075\000\255\255\075\000\
5159     \075\000\075\000\075\000\075\000\255\255\255\255\255\255\255\255\
5160     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\076\000\
5161     \255\255\255\255\076\000\255\255\255\255\255\255\255\255\255\255\
5162     \071\000\255\255\071\000\255\255\255\255\255\255\255\255\075\000\
5163     \255\255\075\000\255\255\255\255\255\255\255\255\076\000\076\000\
5164     \255\255\255\255\076\000\076\000\076\000\255\255\076\000\076\000\
5165     \076\000\076\000\255\255\076\000\076\000\076\000\077\000\255\255\
5166     \255\255\077\000\255\255\255\255\255\255\255\255\255\255\075\000\
5167     \076\000\075\000\076\000\076\000\076\000\076\000\076\000\255\255\
5168     \255\255\255\255\255\255\255\255\255\255\077\000\077\000\255\255\
5169     \255\255\077\000\077\000\077\000\255\255\255\255\077\000\077\000\
5170     \077\000\255\255\077\000\077\000\077\000\255\255\255\255\255\255\
5171     \255\255\076\000\076\000\255\255\076\000\255\255\255\255\077\000\
5172     \255\255\077\000\077\000\077\000\077\000\077\000\255\255\255\255\
5173     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5174     \255\255\078\000\255\255\255\255\078\000\255\255\255\255\255\255\
5175     \255\255\076\000\076\000\255\255\076\000\255\255\255\255\255\255\
5176     \255\255\077\000\255\255\077\000\255\255\255\255\255\255\255\255\
5177     \078\000\078\000\255\255\255\255\078\000\078\000\078\000\255\255\
5178     \255\255\078\000\078\000\078\000\255\255\078\000\078\000\078\000\
5179     \079\000\255\255\255\255\079\000\255\255\255\255\255\255\255\255\
5180     \255\255\077\000\078\000\077\000\078\000\078\000\078\000\078\000\
5181     \078\000\255\255\255\255\255\255\255\255\255\255\255\255\079\000\
5182     \079\000\255\255\255\255\079\000\079\000\079\000\255\255\255\255\
5183     \255\255\079\000\079\000\255\255\079\000\079\000\079\000\255\255\
5184     \255\255\255\255\255\255\255\255\078\000\255\255\078\000\255\255\
5185     \255\255\079\000\255\255\079\000\079\000\079\000\079\000\079\000\
5186     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\084\000\
5187     \084\000\255\255\255\255\084\000\255\255\255\255\255\255\255\255\
5188     \084\000\084\000\255\255\255\255\078\000\255\255\078\000\255\255\
5189     \255\255\255\255\255\255\079\000\084\000\079\000\084\000\084\000\
5190     \084\000\255\255\084\000\255\255\255\255\255\255\255\255\255\255\
5191     \085\000\255\255\255\255\085\000\085\000\085\000\255\255\255\255\
5192     \085\000\085\000\085\000\255\255\085\000\085\000\085\000\255\255\
5193     \255\255\255\255\255\255\079\000\255\255\079\000\255\255\084\000\
5194     \084\000\085\000\255\255\085\000\085\000\085\000\085\000\085\000\
5195     \255\255\255\255\255\255\255\255\255\255\086\000\255\255\255\255\
5196     \086\000\086\000\086\000\255\255\255\255\086\000\086\000\086\000\
5197     \255\255\086\000\086\000\086\000\255\255\255\255\084\000\084\000\
5198     \255\255\255\255\255\255\085\000\085\000\085\000\086\000\255\255\
5199     \086\000\086\000\086\000\086\000\086\000\255\255\255\255\255\255\
5200     \255\255\255\255\087\000\255\255\255\255\087\000\087\000\087\000\
5201     \255\255\255\255\087\000\087\000\087\000\255\255\087\000\087\000\
5202     \087\000\255\255\255\255\085\000\085\000\085\000\255\255\255\255\
5203     \086\000\086\000\086\000\087\000\255\255\087\000\087\000\087\000\
5204     \087\000\087\000\255\255\255\255\255\255\255\255\255\255\088\000\
5205     \255\255\255\255\088\000\088\000\088\000\255\255\255\255\088\000\
5206     \088\000\088\000\255\255\088\000\088\000\088\000\255\255\255\255\
5207     \086\000\086\000\086\000\255\255\255\255\087\000\087\000\087\000\
5208     \088\000\255\255\088\000\088\000\088\000\088\000\088\000\255\255\
5209     \255\255\255\255\255\255\255\255\089\000\255\255\255\255\089\000\
5210     \089\000\089\000\255\255\255\255\089\000\089\000\089\000\255\255\
5211     \089\000\089\000\089\000\255\255\255\255\087\000\087\000\087\000\
5212     \255\255\255\255\088\000\088\000\088\000\089\000\255\255\089\000\
5213     \089\000\089\000\089\000\089\000\255\255\255\255\255\255\255\255\
5214     \255\255\090\000\255\255\255\255\090\000\090\000\090\000\255\255\
5215     \255\255\255\255\090\000\090\000\255\255\090\000\090\000\090\000\
5216     \255\255\255\255\088\000\088\000\088\000\255\255\255\255\089\000\
5217     \089\000\089\000\090\000\255\255\090\000\090\000\090\000\090\000\
5218     \090\000\255\255\255\255\255\255\091\000\255\255\255\255\091\000\
5219     \091\000\091\000\255\255\255\255\091\000\091\000\091\000\255\255\
5220     \091\000\091\000\091\000\255\255\255\255\255\255\255\255\089\000\
5221     \089\000\089\000\255\255\255\255\090\000\091\000\090\000\091\000\
5222     \091\000\091\000\091\000\091\000\255\255\255\255\255\255\255\255\
5223     \255\255\092\000\255\255\255\255\092\000\092\000\092\000\255\255\
5224     \255\255\092\000\092\000\092\000\255\255\092\000\092\000\092\000\
5225     \255\255\255\255\255\255\255\255\090\000\255\255\090\000\091\000\
5226     \091\000\091\000\092\000\255\255\092\000\092\000\092\000\092\000\
5227     \092\000\255\255\255\255\255\255\255\255\255\255\093\000\255\255\
5228     \255\255\093\000\093\000\093\000\255\255\255\255\093\000\093\000\
5229     \093\000\255\255\093\000\093\000\093\000\255\255\255\255\091\000\
5230     \091\000\091\000\255\255\255\255\092\000\092\000\092\000\093\000\
5231     \255\255\093\000\093\000\093\000\093\000\093\000\255\255\255\255\
5232     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\094\000\
5233     \094\000\255\255\255\255\094\000\255\255\255\255\255\255\255\255\
5234     \094\000\094\000\255\255\255\255\092\000\092\000\092\000\255\255\
5235     \255\255\093\000\093\000\093\000\094\000\255\255\094\000\094\000\
5236     \094\000\255\255\094\000\255\255\255\255\255\255\255\255\255\255\
5237     \095\000\255\255\255\255\095\000\095\000\095\000\255\255\255\255\
5238     \095\000\095\000\095\000\255\255\095\000\095\000\095\000\255\255\
5239     \255\255\093\000\093\000\093\000\255\255\255\255\255\255\094\000\
5240     \094\000\095\000\255\255\095\000\095\000\095\000\095\000\095\000\
5241     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5242     \255\255\096\000\096\000\255\255\255\255\096\000\255\255\255\255\
5243     \255\255\255\255\096\000\096\000\255\255\255\255\094\000\094\000\
5244     \255\255\255\255\255\255\095\000\095\000\095\000\096\000\255\255\
5245     \096\000\096\000\096\000\255\255\096\000\255\255\255\255\255\255\
5246     \255\255\255\255\097\000\255\255\255\255\097\000\097\000\097\000\
5247     \255\255\255\255\097\000\097\000\097\000\255\255\097\000\097\000\
5248     \097\000\255\255\255\255\095\000\095\000\095\000\255\255\255\255\
5249     \255\255\096\000\096\000\097\000\255\255\097\000\097\000\097\000\
5250     \097\000\097\000\255\255\255\255\255\255\255\255\255\255\098\000\
5251     \255\255\255\255\098\000\098\000\098\000\255\255\255\255\098\000\
5252     \098\000\098\000\255\255\098\000\098\000\098\000\255\255\255\255\
5253     \096\000\096\000\255\255\255\255\255\255\097\000\097\000\097\000\
5254     \098\000\255\255\098\000\098\000\098\000\098\000\098\000\255\255\
5255     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5256     \109\000\109\000\255\255\255\255\109\000\255\255\255\255\110\000\
5257     \110\000\109\000\109\000\110\000\255\255\097\000\097\000\097\000\
5258     \110\000\110\000\098\000\098\000\098\000\109\000\255\255\109\000\
5259     \109\000\109\000\255\255\109\000\110\000\255\255\110\000\110\000\
5260     \110\000\255\255\110\000\255\255\255\255\255\255\255\255\255\255\
5261     \255\255\255\255\255\255\255\255\111\000\111\000\255\255\255\255\
5262     \111\000\255\255\098\000\098\000\098\000\111\000\111\000\255\255\
5263     \109\000\109\000\255\255\255\255\255\255\255\255\255\255\110\000\
5264     \110\000\111\000\255\255\111\000\111\000\111\000\255\255\111\000\
5265     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5266     \255\255\112\000\112\000\255\255\255\255\112\000\255\255\109\000\
5267     \109\000\255\255\112\000\112\000\255\255\255\255\110\000\110\000\
5268     \255\255\255\255\255\255\255\255\111\000\111\000\112\000\255\255\
5269     \112\000\112\000\112\000\255\255\112\000\255\255\255\255\255\255\
5270     \255\255\255\255\255\255\255\255\255\255\255\255\113\000\113\000\
5271     \255\255\255\255\113\000\255\255\255\255\114\000\114\000\113\000\
5272     \113\000\114\000\255\255\111\000\111\000\255\255\114\000\114\000\
5273     \255\255\112\000\112\000\113\000\255\255\113\000\113\000\113\000\
5274     \255\255\113\000\114\000\255\255\114\000\114\000\114\000\255\255\
5275     \114\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5276     \255\255\255\255\115\000\115\000\255\255\255\255\255\255\255\255\
5277     \112\000\112\000\255\255\115\000\115\000\255\255\113\000\113\000\
5278     \255\255\255\255\255\255\255\255\255\255\114\000\114\000\115\000\
5279     \255\255\115\000\115\000\115\000\255\255\115\000\255\255\255\255\
5280     \255\255\116\000\116\000\255\255\255\255\255\255\255\255\255\255\
5281     \255\255\255\255\116\000\116\000\255\255\113\000\113\000\255\255\
5282     \255\255\255\255\255\255\255\255\114\000\114\000\116\000\255\255\
5283     \116\000\116\000\116\000\115\000\116\000\117\000\117\000\255\255\
5284     \117\000\255\255\255\255\255\255\255\255\255\255\117\000\117\000\
5285     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5286     \255\255\255\255\117\000\255\255\117\000\117\000\117\000\255\255\
5287     \117\000\115\000\116\000\255\255\255\255\255\255\255\255\255\255\
5288     \255\255\255\255\118\000\118\000\255\255\255\255\255\255\119\000\
5289     \119\000\255\255\119\000\118\000\118\000\255\255\255\255\255\255\
5290     \119\000\119\000\255\255\117\000\255\255\255\255\117\000\118\000\
5291     \116\000\118\000\118\000\118\000\119\000\118\000\119\000\119\000\
5292     \119\000\255\255\119\000\255\255\255\255\255\255\255\255\255\255\
5293     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5294     \255\255\255\255\255\255\117\000\117\000\255\255\255\255\255\255\
5295     \255\255\255\255\255\255\118\000\255\255\119\000\255\255\255\255\
5296     \119\000\255\255\255\255\255\255\255\255\255\255\120\000\255\255\
5297     \255\255\120\000\120\000\120\000\255\255\255\255\120\000\120\000\
5298     \120\000\255\255\120\000\120\000\120\000\255\255\255\255\255\255\
5299     \255\255\118\000\255\255\255\255\255\255\119\000\119\000\120\000\
5300     \255\255\120\000\120\000\120\000\120\000\120\000\255\255\255\255\
5301     \255\255\255\255\255\255\121\000\255\255\255\255\121\000\121\000\
5302     \121\000\255\255\255\255\121\000\121\000\121\000\255\255\121\000\
5303     \121\000\121\000\255\255\255\255\255\255\255\255\255\255\255\255\
5304     \255\255\120\000\120\000\120\000\121\000\255\255\121\000\121\000\
5305     \121\000\121\000\121\000\255\255\255\255\255\255\255\255\255\255\
5306     \122\000\255\255\255\255\122\000\122\000\122\000\255\255\255\255\
5307     \122\000\122\000\122\000\255\255\122\000\122\000\122\000\255\255\
5308     \255\255\120\000\120\000\120\000\255\255\255\255\121\000\121\000\
5309     \121\000\122\000\255\255\122\000\122\000\122\000\122\000\122\000\
5310     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\123\000\
5311     \255\255\255\255\123\000\255\255\255\255\255\255\255\255\255\255\
5312     \255\255\255\255\255\255\255\255\255\255\255\255\121\000\121\000\
5313     \121\000\255\255\255\255\122\000\122\000\122\000\255\255\123\000\
5314     \255\255\255\255\255\255\255\255\123\000\123\000\255\255\123\000\
5315     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5316     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5317     \255\255\123\000\255\255\122\000\122\000\122\000\123\000\123\000\
5318     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5319     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5320     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5321     \255\255\255\255\255\255\255\255\123\000\255\255\123\000\123\000\
5322     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5323     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5324     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5325     \156\000\156\000\156\000\156\000\156\000\156\000\156\000\156\000\
5326     \156\000\156\000\255\255\255\255\255\255\255\255\255\255\255\255\
5327     \255\255\156\000\156\000\156\000\156\000\156\000\156\000\255\255\
5328     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5329     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5330     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5331     \255\255\156\000\156\000\156\000\156\000\156\000\156\000\255\255\
5332     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5333     \255\255\255\255\255\255\255\255\255\255\123\000\123\000\123\000\
5334     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5335     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5336     \123\000\123\000\123\000\123\000\255\255\123\000\123\000\123\000\
5337     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5338     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5339     \123\000\123\000\123\000\123\000\123\000\123\000\123\000\123\000\
5340     \123\000\123\000\123\000\123\000\255\255\123\000\123\000\123\000\
5341     \123\000\123\000\123\000\123\000\123\000\123\000\130\000\255\255\
5342     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\130\000\
5343     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5344     \130\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5345     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5346     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5347     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5348     \130\000\130\000\255\255\255\255\255\255\255\255\130\000\255\255\
5349     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5350     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5351     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5352     \130\000\130\000\255\255\255\255\255\255\255\255\255\255\255\255\
5353     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5354     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5355     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5356     \137\000\137\000\255\255\255\255\255\255\255\255\137\000\255\255\
5357     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5358     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5359     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5360     \137\000\137\000\255\255\255\255\255\255\255\255\255\255\130\000\
5361     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5362     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5363     \130\000\130\000\130\000\130\000\130\000\130\000\255\255\130\000\
5364     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5365     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5366     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\130\000\
5367     \130\000\130\000\130\000\130\000\130\000\130\000\255\255\130\000\
5368     \130\000\130\000\130\000\130\000\130\000\130\000\130\000\137\000\
5369     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5370     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5371     \137\000\137\000\137\000\137\000\137\000\137\000\255\255\137\000\
5372     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5373     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5374     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\137\000\
5375     \137\000\137\000\137\000\137\000\137\000\137\000\255\255\137\000\
5376     \137\000\137\000\137\000\137\000\137\000\137\000\137\000\138\000\
5377     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5378     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5379     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5380     \138\000\255\255\255\255\255\255\255\255\138\000\255\255\138\000\
5381     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5382     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5383     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5384     \138\000\167\000\167\000\167\000\167\000\167\000\167\000\167\000\
5385     \167\000\167\000\167\000\255\255\255\255\255\255\255\255\255\255\
5386     \255\255\255\255\167\000\167\000\167\000\167\000\167\000\167\000\
5387     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5388     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5389     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5390     \255\255\255\255\167\000\167\000\167\000\167\000\167\000\167\000\
5391     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5392     \255\255\255\255\255\255\255\255\255\255\255\255\138\000\138\000\
5393     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5394     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5395     \138\000\138\000\138\000\138\000\138\000\255\255\138\000\138\000\
5396     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5397     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5398     \138\000\138\000\138\000\138\000\138\000\138\000\138\000\138\000\
5399     \138\000\138\000\138\000\138\000\138\000\139\000\138\000\138\000\
5400     \138\000\138\000\138\000\138\000\138\000\138\000\139\000\139\000\
5401     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5402     \255\255\255\255\139\000\255\255\255\255\255\255\139\000\139\000\
5403     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5404     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5405     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5406     \139\000\255\255\255\255\255\255\255\255\139\000\255\255\139\000\
5407     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5408     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5409     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5410     \139\000\174\000\174\000\174\000\174\000\174\000\174\000\174\000\
5411     \174\000\174\000\174\000\255\255\255\255\255\255\255\255\255\255\
5412     \255\255\255\255\174\000\174\000\174\000\174\000\174\000\174\000\
5413     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5414     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5415     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5416     \255\255\255\255\174\000\174\000\174\000\174\000\174\000\174\000\
5417     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5418     \255\255\255\255\255\255\255\255\255\255\255\255\139\000\139\000\
5419     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5420     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5421     \139\000\139\000\139\000\139\000\139\000\255\255\139\000\139\000\
5422     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5423     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5424     \139\000\139\000\139\000\139\000\139\000\139\000\139\000\139\000\
5425     \139\000\139\000\139\000\139\000\139\000\140\000\139\000\139\000\
5426     \139\000\139\000\139\000\139\000\139\000\139\000\140\000\140\000\
5427     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5428     \255\255\255\255\140\000\255\255\255\255\255\255\255\255\140\000\
5429     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5430     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5431     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5432     \140\000\255\255\255\255\255\255\255\255\140\000\255\255\140\000\
5433     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5434     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5435     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5436     \140\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5437     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5438     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5439     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5440     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5441     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5442     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5443     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5444     \255\255\255\255\255\255\255\255\255\255\255\255\140\000\140\000\
5445     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5446     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5447     \140\000\140\000\140\000\140\000\140\000\255\255\140\000\140\000\
5448     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5449     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5450     \140\000\140\000\140\000\140\000\140\000\140\000\140\000\140\000\
5451     \140\000\140\000\140\000\140\000\140\000\255\255\140\000\140\000\
5452     \140\000\140\000\140\000\140\000\140\000\140\000\141\000\255\255\
5453     \141\000\255\255\255\255\164\000\255\255\141\000\164\000\255\255\
5454     \255\255\255\255\255\255\255\255\255\255\255\255\141\000\141\000\
5455     \141\000\141\000\141\000\141\000\141\000\141\000\141\000\141\000\
5456     \255\255\164\000\255\255\164\000\255\255\255\255\255\255\255\255\
5457     \164\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5458     \255\255\164\000\164\000\164\000\164\000\164\000\164\000\164\000\
5459     \164\000\164\000\164\000\255\255\255\255\255\255\255\255\255\255\
5460     \255\255\255\255\141\000\255\255\255\255\255\255\255\255\255\255\
5461     \141\000\176\000\255\255\255\255\176\000\176\000\176\000\255\255\
5462     \255\255\255\255\176\000\176\000\141\000\176\000\176\000\176\000\
5463     \141\000\255\255\141\000\255\255\255\255\164\000\141\000\255\255\
5464     \255\255\255\255\176\000\164\000\176\000\176\000\176\000\176\000\
5465     \176\000\255\255\255\255\255\255\255\255\255\255\255\255\164\000\
5466     \255\255\255\255\255\255\164\000\255\255\164\000\255\255\255\255\
5467     \255\255\164\000\255\255\255\255\255\255\255\255\255\255\255\255\
5468     \255\255\255\255\255\255\255\255\176\000\255\255\176\000\255\255\
5469     \255\255\255\255\255\255\255\255\177\000\255\255\255\255\177\000\
5470     \177\000\177\000\255\255\255\255\255\255\177\000\177\000\255\255\
5471     \177\000\177\000\177\000\255\255\255\255\255\255\255\255\255\255\
5472     \255\255\255\255\255\255\255\255\176\000\177\000\176\000\177\000\
5473     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5474     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5475     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5476     \177\000\177\000\177\000\177\000\177\000\177\000\255\255\177\000\
5477     \255\255\177\000\177\000\255\255\177\000\177\000\177\000\177\000\
5478     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5479     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5480     \177\000\177\000\177\000\177\000\177\000\177\000\255\255\177\000\
5481     \255\255\177\000\255\255\255\255\255\255\255\255\255\255\255\255\
5482     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5483     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5484     \255\255\164\000\255\255\255\255\255\255\255\255\255\255\255\255\
5485     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5486     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5487     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5488     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5489     \255\255\255\255\255\255\177\000\177\000\177\000\177\000\177\000\
5490     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5491     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5492     \177\000\177\000\255\255\177\000\177\000\177\000\177\000\177\000\
5493     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5494     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5495     \177\000\177\000\177\000\177\000\177\000\177\000\177\000\177\000\
5496     \177\000\177\000\255\255\177\000\177\000\177\000\177\000\177\000\
5497     \177\000\177\000\177\000\178\000\255\255\255\255\178\000\178\000\
5498     \178\000\255\255\255\255\255\255\178\000\178\000\255\255\178\000\
5499     \178\000\178\000\255\255\255\255\255\255\255\255\255\255\255\255\
5500     \255\255\255\255\255\255\255\255\178\000\255\255\178\000\178\000\
5501     \178\000\178\000\178\000\255\255\255\255\255\255\255\255\179\000\
5502     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5503     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5504     \179\000\179\000\255\255\255\255\179\000\255\255\178\000\255\255\
5505     \178\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5506     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5507     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5508     \179\000\179\000\179\000\255\255\255\255\255\255\178\000\179\000\
5509     \178\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5510     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5511     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5512     \179\000\179\000\179\000\255\255\255\255\255\255\255\255\255\255\
5513     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5514     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5515     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5516     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5517     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5518     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5519     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5520     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5521     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5522     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5523     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\255\255\
5524     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5525     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5526     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5527     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\255\255\
5528     \179\000\179\000\179\000\179\000\179\000\179\000\179\000\179\000\
5529     \181\000\255\255\255\255\181\000\181\000\181\000\255\255\255\255\
5530     \255\255\181\000\181\000\255\255\181\000\181\000\181\000\255\255\
5531     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5532     \255\255\181\000\255\255\181\000\181\000\181\000\181\000\181\000\
5533     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5534     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5535     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5536     \181\000\181\000\255\255\181\000\255\255\181\000\181\000\255\255\
5537     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5538     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5539     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5540     \181\000\181\000\255\255\181\000\255\255\181\000\255\255\255\255\
5541     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5542     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5543     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5544     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5545     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5546     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5547     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5548     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\181\000\
5549     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5550     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5551     \181\000\181\000\181\000\181\000\181\000\181\000\255\255\181\000\
5552     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5553     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5554     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
5555     \181\000\181\000\181\000\181\000\181\000\181\000\255\255\181\000\
5556     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\182\000\
5557     \255\255\255\255\182\000\182\000\182\000\255\255\255\255\255\255\
5558     \182\000\182\000\255\255\182\000\182\000\182\000\255\255\255\255\
5559     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5560     \182\000\255\255\182\000\182\000\182\000\182\000\182\000\255\255\
5561     \255\255\255\255\255\255\255\255\255\255\255\255\183\000\255\255\
5562     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\183\000\
5563     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5564     \183\000\255\255\182\000\183\000\182\000\255\255\255\255\183\000\
5565     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5566     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5567     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5568     \183\000\183\000\182\000\255\255\182\000\255\255\183\000\255\255\
5569     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5570     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5571     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5572     \183\000\183\000\255\255\255\255\255\255\255\255\255\255\255\255\
5573     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5574     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5575     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5576     \184\000\184\000\255\255\255\255\255\255\255\255\184\000\255\255\
5577     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5578     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5579     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5580     \184\000\184\000\255\255\255\255\255\255\255\255\255\255\183\000\
5581     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5582     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5583     \183\000\183\000\183\000\183\000\183\000\183\000\255\255\183\000\
5584     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5585     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5586     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
5587     \183\000\183\000\183\000\183\000\183\000\183\000\255\255\183\000\
5588     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\184\000\
5589     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5590     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5591     \184\000\184\000\184\000\184\000\184\000\184\000\255\255\184\000\
5592     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5593     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5594     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\184\000\
5595     \184\000\184\000\184\000\184\000\184\000\184\000\186\000\184\000\
5596     \184\000\184\000\184\000\184\000\184\000\184\000\184\000\186\000\
5597     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5598     \186\000\255\255\255\255\186\000\255\255\255\255\255\255\255\255\
5599     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5600     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5601     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5602     \186\000\186\000\255\255\255\255\255\255\255\255\186\000\255\255\
5603     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5604     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5605     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5606     \186\000\186\000\255\255\255\255\255\255\255\255\255\255\255\255\
5607     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5608     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5609     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5610     \196\000\196\000\255\255\255\255\255\255\255\255\196\000\255\255\
5611     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5612     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5613     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5614     \196\000\196\000\255\255\255\255\255\255\255\255\255\255\186\000\
5615     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5616     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5617     \186\000\186\000\186\000\186\000\186\000\186\000\255\255\186\000\
5618     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5619     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5620     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\186\000\
5621     \186\000\186\000\186\000\186\000\186\000\186\000\255\255\186\000\
5622     \186\000\186\000\186\000\186\000\186\000\186\000\186\000\196\000\
5623     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5624     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5625     \196\000\196\000\196\000\196\000\196\000\196\000\255\255\196\000\
5626     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5627     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5628     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\196\000\
5629     \196\000\196\000\196\000\196\000\196\000\196\000\255\255\196\000\
5630     \196\000\196\000\196\000\196\000\196\000\196\000\196\000\197\000\
5631     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5632     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5633     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5634     \197\000\255\255\255\255\255\255\255\255\197\000\255\255\197\000\
5635     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5636     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5637     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5638     \197\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5639     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5640     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5641     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5642     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5643     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5644     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5645     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5646     \255\255\255\255\255\255\255\255\255\255\255\255\197\000\197\000\
5647     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5648     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5649     \197\000\197\000\197\000\197\000\197\000\255\255\197\000\197\000\
5650     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5651     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5652     \197\000\197\000\197\000\197\000\197\000\197\000\197\000\197\000\
5653     \197\000\197\000\197\000\197\000\197\000\198\000\197\000\197\000\
5654     \197\000\197\000\197\000\197\000\197\000\197\000\198\000\198\000\
5655     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5656     \255\255\255\255\198\000\255\255\255\255\255\255\198\000\198\000\
5657     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5658     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5659     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5660     \198\000\255\255\255\255\255\255\255\255\198\000\255\255\198\000\
5661     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5662     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5663     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5664     \198\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5665     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5666     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5667     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5668     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5669     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5670     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5671     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5672     \255\255\255\255\255\255\255\255\255\255\255\255\198\000\198\000\
5673     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5674     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5675     \198\000\198\000\198\000\198\000\198\000\255\255\198\000\198\000\
5676     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5677     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5678     \198\000\198\000\198\000\198\000\198\000\198\000\198\000\198\000\
5679     \198\000\198\000\198\000\198\000\198\000\199\000\198\000\198\000\
5680     \198\000\198\000\198\000\198\000\198\000\198\000\199\000\199\000\
5681     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5682     \255\255\255\255\199\000\255\255\255\255\255\255\255\255\199\000\
5683     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5684     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5685     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5686     \199\000\255\255\255\255\255\255\255\255\199\000\255\255\199\000\
5687     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5688     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5689     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5690     \199\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5691     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5692     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5693     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5694     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5695     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5696     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5697     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5698     \255\255\255\255\255\255\255\255\255\255\255\255\199\000\199\000\
5699     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5700     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5701     \199\000\199\000\199\000\199\000\199\000\255\255\199\000\199\000\
5702     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5703     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5704     \199\000\199\000\199\000\199\000\199\000\199\000\199\000\199\000\
5705     \199\000\199\000\199\000\199\000\199\000\255\255\199\000\199\000\
5706     \199\000\199\000\199\000\199\000\199\000\199\000\201\000\255\255\
5707     \255\255\201\000\255\255\255\255\255\255\255\255\255\255\255\255\
5708     \201\000\255\255\201\000\201\000\201\000\201\000\201\000\201\000\
5709     \201\000\201\000\201\000\201\000\201\000\255\255\255\255\255\255\
5710     \255\255\255\255\255\255\201\000\201\000\201\000\201\000\201\000\
5711     \201\000\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5712     \201\000\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5713     \201\000\201\000\201\000\201\000\201\000\255\255\255\255\255\255\
5714     \255\255\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5715     \201\000\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5716     \201\000\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5717     \201\000\201\000\201\000\201\000\201\000\255\255\255\255\255\255\
5718     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5719     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5720     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5721     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5722     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5723     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5724     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5725     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5726     \255\255\255\255\201\000\201\000\201\000\201\000\201\000\201\000\
5727     \201\000\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5728     \201\000\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5729     \201\000\255\255\201\000\201\000\201\000\201\000\201\000\201\000\
5730     \201\000\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5731     \201\000\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5732     \201\000\201\000\201\000\201\000\201\000\201\000\201\000\201\000\
5733     \201\000\255\255\201\000\201\000\201\000\201\000\201\000\201\000\
5734     \201\000\201\000\201\000\205\000\255\255\255\255\255\255\255\255\
5735     \255\255\255\255\255\255\255\255\205\000\205\000\205\000\205\000\
5736     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\255\255\
5737     \255\255\255\255\255\255\255\255\255\255\205\000\205\000\205\000\
5738     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
5739     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
5740     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\255\255\
5741     \255\255\255\255\255\255\205\000\255\255\205\000\205\000\205\000\
5742     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
5743     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
5744     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\255\255\
5745     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5746     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5747     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5748     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5749     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5750     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5751     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5752     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5753     \255\255\255\255\255\255\255\255\205\000\205\000\205\000\205\000\
5754     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
5755     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
5756     \205\000\205\000\205\000\255\255\205\000\205\000\205\000\205\000\
5757     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
5758     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
5759     \205\000\205\000\205\000\205\000\205\000\205\000\205\000\205\000\
5760     \205\000\205\000\205\000\255\255\205\000\205\000\205\000\205\000\
5761     \205\000\205\000\205\000\205\000\206\000\255\255\255\255\255\255\
5762     \255\255\255\255\255\255\206\000\255\255\206\000\206\000\206\000\
5763     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5764     \255\255\255\255\255\255\255\255\255\255\255\255\206\000\206\000\
5765     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5766     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5767     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5768     \255\255\255\255\255\255\255\255\206\000\255\255\206\000\206\000\
5769     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5770     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5771     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5772     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5773     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5774     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5775     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5776     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5777     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5778     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5779     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5780     \255\255\255\255\255\255\255\255\255\255\206\000\206\000\206\000\
5781     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5782     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5783     \206\000\206\000\206\000\206\000\255\255\206\000\206\000\206\000\
5784     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5785     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5786     \206\000\206\000\206\000\206\000\206\000\206\000\206\000\206\000\
5787     \206\000\206\000\206\000\206\000\209\000\206\000\206\000\206\000\
5788     \206\000\206\000\206\000\206\000\206\000\209\000\209\000\209\000\
5789     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5790     \255\255\255\255\255\255\255\255\255\255\255\255\209\000\209\000\
5791     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5792     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5793     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5794     \255\255\255\255\255\255\255\255\209\000\255\255\209\000\209\000\
5795     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5796     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5797     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5798     \255\255\255\255\255\255\255\255\255\255\255\255\218\000\218\000\
5799     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5800     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5801     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5802     \255\255\255\255\255\255\255\255\218\000\255\255\218\000\218\000\
5803     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5804     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5805     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5806     \255\255\255\255\255\255\255\255\255\255\209\000\209\000\209\000\
5807     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5808     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5809     \209\000\209\000\209\000\209\000\255\255\209\000\209\000\209\000\
5810     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5811     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5812     \209\000\209\000\209\000\209\000\209\000\209\000\209\000\209\000\
5813     \209\000\209\000\209\000\209\000\255\255\209\000\209\000\209\000\
5814     \209\000\209\000\209\000\209\000\209\000\218\000\218\000\218\000\
5815     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5816     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5817     \218\000\218\000\218\000\218\000\255\255\218\000\218\000\218\000\
5818     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5819     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5820     \218\000\218\000\218\000\218\000\218\000\218\000\218\000\218\000\
5821     \218\000\218\000\218\000\218\000\255\255\218\000\218\000\218\000\
5822     \218\000\218\000\218\000\218\000\218\000\219\000\219\000\219\000\
5823     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\219\000\
5824     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\219\000\
5825     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\255\255\
5826     \255\255\255\255\255\255\219\000\255\255\219\000\219\000\219\000\
5827     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\219\000\
5828     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\219\000\
5829     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\255\255\
5830     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5831     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5832     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5833     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5834     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5835     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5836     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5837     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5838     \255\255\255\255\255\255\255\255\219\000\219\000\219\000\219\000\
5839     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\219\000\
5840     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\219\000\
5841     \219\000\219\000\219\000\255\255\219\000\219\000\219\000\219\000\
5842     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\219\000\
5843     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\219\000\
5844     \219\000\219\000\219\000\219\000\219\000\219\000\219\000\219\000\
5845     \219\000\219\000\219\000\220\000\219\000\219\000\219\000\219\000\
5846     \219\000\219\000\219\000\219\000\220\000\220\000\220\000\220\000\
5847     \220\000\220\000\220\000\220\000\220\000\220\000\255\255\255\255\
5848     \220\000\255\255\255\255\255\255\220\000\220\000\220\000\220\000\
5849     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
5850     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
5851     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\255\255\
5852     \255\255\255\255\255\255\220\000\255\255\220\000\220\000\220\000\
5853     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
5854     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
5855     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\255\255\
5856     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5857     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5858     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5859     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5860     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5861     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5862     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5863     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5864     \255\255\255\255\255\255\255\255\220\000\220\000\220\000\220\000\
5865     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
5866     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
5867     \220\000\220\000\220\000\255\255\220\000\220\000\220\000\220\000\
5868     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
5869     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
5870     \220\000\220\000\220\000\220\000\220\000\220\000\220\000\220\000\
5871     \220\000\220\000\220\000\221\000\220\000\220\000\220\000\220\000\
5872     \220\000\220\000\220\000\220\000\221\000\221\000\221\000\221\000\
5873     \221\000\221\000\221\000\221\000\221\000\221\000\255\255\255\255\
5874     \221\000\255\255\255\255\255\255\255\255\221\000\221\000\221\000\
5875     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
5876     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
5877     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\255\255\
5878     \255\255\255\255\255\255\221\000\255\255\221\000\221\000\221\000\
5879     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
5880     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
5881     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\255\255\
5882     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5883     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5884     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5885     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5886     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5887     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5888     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5889     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
5890     \255\255\255\255\255\255\255\255\221\000\221\000\221\000\221\000\
5891     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
5892     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
5893     \221\000\221\000\221\000\255\255\221\000\221\000\221\000\221\000\
5894     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
5895     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
5896     \221\000\221\000\221\000\221\000\221\000\221\000\221\000\221\000\
5897     \221\000\221\000\221\000\255\255\221\000\221\000\221\000\221\000\
5898     \221\000\221\000\221\000\221\000\255\255";
5899                 Lexing.lex_base_code =
5900                   "\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5901     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5902     \000\000\000\000\000\000\027\000\000\000\000\000\000\000\000\000\
5903     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5904     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5905     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5906     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5907     \000\000\000\000\000\000\000\000\066\000\101\000\136\000\171\000\
5908     \206\000\000\000\000\000\000\000\000\000\241\000\020\001\055\001\
5909     \000\000\000\000\018\000\090\001\125\001\160\001\195\001\230\001\
5910     \000\000\021\000\026\000\000\000\000\000\000\000\000\000\000\000\
5911     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5912     \000\000\000\000\000\000\247\001\040\002\000\000\034\000\000\000\
5913     \000\000\003\000\000\000\000\000\049\000\000\000\000\000\000\000\
5914     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5915     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5916     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5917     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5918     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5919     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5920     \000\000\000\000\000\000\000\000\001\000\000\000\000\000\000\000\
5921     \000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\
5922     \000\000\000\000\000\000\000\000\000\000\036\002\000\000\244\002\
5923     \000\000\000\000\000\000\061\000\000\000\000\000\000\000\000\000\
5924     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5925     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5926     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5927     \000\000\000\000\000\000\000\000\000\000\000\000";
5928                 Lexing.lex_backtrk_code =
5929                   "\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5930     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5931     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5932     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5933     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5934     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5935     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5936     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5937     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5938     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5939     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5940     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5941     \000\000\000\000\000\000\000\000\000\000\034\000\000\000\000\000\
5942     \000\000\000\000\000\000\049\000\000\000\000\000\000\000\000\000\
5943     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5944     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5945     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5946     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5947     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5948     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5949     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5950     \000\000\000\000\061\000\061\000\000\000\000\000\000\000\000\000\
5951     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5952     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5953     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5954     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5955     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5956     \000\000\000\000\000\000\000\000\000\000\000\000";
5957                 Lexing.lex_default_code =
5958                   "\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5959     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5960     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5961     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5962     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5963     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5964     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5965     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5966     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5967     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5968     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5969     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5970     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5971     \041\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5972     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5973     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5974     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5975     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5976     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5977     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5978     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5979     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5980     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5981     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5982     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5983     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5984     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5985     \000\000\000\000\000\000\000\000\000\000\000\000";
5986                 Lexing.lex_trans_code =
5987                   "\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5988     \000\000\001\000\000\000\058\000\058\000\000\000\058\000\000\000\
5989     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5990     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5991     \001\000\000\000\000\000\001\000\007\000\044\000\000\000\007\000\
5992     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
5993     \004\000\004\000\004\000\004\000\004\000\004\000\004\000\004\000\
5994     \004\000\004\000\000\000\007\000\012\000\000\000\000\000\012\000\
5995     \012\000\012\000\000\000\000\000\000\000\000\000\012\000\000\000\
5996     \012\000\012\000\012\000\007\000\000\000\000\000\007\000\000\000\
5997     \000\000\000\000\000\000\000\000\000\000\012\000\000\000\012\000\
5998     \012\000\012\000\012\000\012\000\000\000\000\000\000\000\000\000\
5999     \000\000\000\000\007\000\015\000\000\000\000\000\015\000\015\000\
6000     \015\000\000\000\000\000\000\000\015\000\015\000\000\000\015\000\
6001     \015\000\015\000\000\000\000\000\000\000\000\000\000\000\012\000\
6002     \000\000\012\000\000\000\000\000\015\000\000\000\015\000\015\000\
6003     \015\000\015\000\015\000\000\000\000\000\000\000\012\000\000\000\
6004     \000\000\012\000\012\000\012\000\000\000\000\000\000\000\012\000\
6005     \012\000\000\000\012\000\012\000\012\000\000\000\000\000\012\000\
6006     \000\000\012\000\000\000\000\000\000\000\000\000\015\000\012\000\
6007     \015\000\012\000\012\000\012\000\012\000\012\000\000\000\000\000\
6008     \000\000\012\000\000\000\000\000\012\000\012\000\012\000\000\000\
6009     \000\000\000\000\012\000\012\000\000\000\012\000\012\000\012\000\
6010     \000\000\000\000\000\000\000\000\000\000\000\000\015\000\000\000\
6011     \015\000\012\000\012\000\012\000\012\000\012\000\012\000\012\000\
6012     \012\000\000\000\000\000\000\000\012\000\000\000\000\000\012\000\
6013     \012\000\012\000\000\000\000\000\000\000\012\000\012\000\000\000\
6014     \012\000\012\000\012\000\000\000\000\000\000\000\000\000\000\000\
6015     \000\000\012\000\000\000\012\000\012\000\012\000\012\000\012\000\
6016     \012\000\012\000\012\000\012\000\000\000\000\000\000\000\012\000\
6017     \000\000\000\000\012\000\012\000\012\000\000\000\000\000\000\000\
6018     \012\000\012\000\000\000\012\000\012\000\012\000\000\000\000\000\
6019     \000\000\000\000\000\000\000\000\012\000\000\000\012\000\012\000\
6020     \012\000\012\000\012\000\012\000\012\000\012\000\012\000\000\000\
6021     \000\000\000\000\012\000\000\000\000\000\012\000\012\000\012\000\
6022     \000\000\000\000\000\000\012\000\012\000\000\000\012\000\012\000\
6023     \012\000\000\000\000\000\000\000\000\000\000\000\000\000\012\000\
6024     \000\000\012\000\012\000\012\000\012\000\012\000\012\000\012\000\
6025     \012\000\012\000\000\000\000\000\000\000\012\000\000\000\000\000\
6026     \012\000\012\000\012\000\000\000\000\000\000\000\012\000\012\000\
6027     \000\000\012\000\012\000\012\000\000\000\000\000\000\000\000\000\
6028     \000\000\000\000\012\000\000\000\012\000\012\000\012\000\012\000\
6029     \012\000\012\000\012\000\012\000\012\000\000\000\000\000\000\000\
6030     \012\000\000\000\000\000\012\000\012\000\012\000\000\000\000\000\
6031     \000\000\012\000\012\000\000\000\012\000\012\000\012\000\000\000\
6032     \000\000\000\000\000\000\000\000\000\000\012\000\000\000\012\000\
6033     \012\000\012\000\012\000\012\000\012\000\012\000\012\000\012\000\
6034     \000\000\000\000\000\000\012\000\000\000\000\000\012\000\012\000\
6035     \012\000\000\000\000\000\000\000\012\000\012\000\000\000\012\000\
6036     \012\000\012\000\000\000\000\000\000\000\000\000\000\000\000\000\
6037     \012\000\000\000\012\000\012\000\012\000\012\000\012\000\012\000\
6038     \012\000\012\000\012\000\000\000\000\000\000\000\012\000\000\000\
6039     \000\000\012\000\012\000\012\000\000\000\000\000\000\000\012\000\
6040     \012\000\000\000\012\000\012\000\012\000\000\000\000\000\000\000\
6041     \000\000\000\000\000\000\012\000\000\000\012\000\012\000\012\000\
6042     \012\000\012\000\012\000\012\000\012\000\012\000\000\000\000\000\
6043     \000\000\012\000\000\000\000\000\012\000\012\000\012\000\000\000\
6044     \000\000\000\000\012\000\012\000\000\000\012\000\012\000\012\000\
6045     \000\000\000\000\000\000\000\000\000\000\000\000\012\000\000\000\
6046     \012\000\012\000\012\000\012\000\012\000\012\000\012\000\012\000\
6047     \012\000\000\000\000\000\000\000\015\000\000\000\000\000\015\000\
6048     \015\000\015\000\000\000\000\000\000\000\015\000\015\000\000\000\
6049     \015\000\015\000\015\000\000\000\000\000\000\000\000\000\000\000\
6050     \000\000\012\000\000\000\012\000\012\000\015\000\012\000\015\000\
6051     \015\000\015\000\015\000\015\000\000\000\000\000\000\000\015\000\
6052     \000\000\000\000\015\000\015\000\015\000\000\000\000\000\000\000\
6053     \015\000\015\000\000\000\015\000\015\000\015\000\000\000\000\000\
6054     \000\000\029\000\000\000\000\000\012\000\000\000\012\000\015\000\
6055     \015\000\015\000\015\000\015\000\015\000\015\000\015\000\004\000\
6056     \004\000\004\000\004\000\004\000\004\000\004\000\004\000\004\000\
6057     \004\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\
6058     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\015\000\
6059     \000\000\015\000\015\000\000\000\015\000\000\000\000\000\000\000\
6060     \001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6061     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6062     \004\000\004\000\004\000\004\000\004\000\004\000\004\000\004\000\
6063     \004\000\004\000\015\000\000\000\015\000\058\000\058\000\058\000\
6064     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6065     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6066     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\000\000\
6067     \000\000\000\000\000\000\058\000\000\000\058\000\058\000\058\000\
6068     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6069     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6070     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\000\000\
6071     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6072     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6073     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6074     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6075     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6076     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6077     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6078     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6079     \000\000\000\000\000\000\000\000\058\000\058\000\058\000\058\000\
6080     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6081     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6082     \058\000\058\000\058\000\000\000\058\000\058\000\058\000\058\000\
6083     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6084     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6085     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6086     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6087     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6088     \058\000\058\000\058\000\058\000\058\000\058\000\000\000\000\000\
6089     \000\000\000\000\000\000\000\000\000\000\058\000\058\000\058\000\
6090     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6091     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6092     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\000\000\
6093     \000\000\000\000\000\000\058\000\000\000\058\000\058\000\058\000\
6094     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6095     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6096     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\000\000\
6097     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6098     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6099     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6100     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6101     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6102     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6103     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6104     \000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\
6105     \000\000\000\000\000\000\000\000\058\000\058\000\058\000\058\000\
6106     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6107     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6108     \058\000\058\000\058\000\000\000\058\000\058\000\058\000\058\000\
6109     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6110     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6111     \058\000\058\000\058\000\058\000\058\000\058\000\058\000\058\000\
6112     \058\000\058\000\058\000\000\000\058\000\058\000\058\000\058\000\
6113     \058\000\058\000\058\000\058\000\000\000";
6114                 Lexing.lex_check_code =
6115                   "\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6116     \255\255\016\000\104\000\164\000\170\000\104\000\164\000\255\255\
6117     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6118     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6119     \016\000\255\255\104\000\000\000\019\000\105\000\255\255\019\000\
6120     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6121     \016\000\016\000\016\000\016\000\016\000\016\000\016\000\016\000\
6122     \016\000\016\000\255\255\019\000\019\000\255\255\255\255\019\000\
6123     \019\000\019\000\255\255\255\255\255\255\255\255\019\000\255\255\
6124     \019\000\019\000\019\000\060\000\255\255\255\255\060\000\255\255\
6125     \255\255\255\255\255\255\255\255\255\255\019\000\255\255\019\000\
6126     \019\000\019\000\019\000\019\000\255\255\255\255\255\255\255\255\
6127     \255\255\255\255\060\000\060\000\255\255\255\255\060\000\060\000\
6128     \060\000\255\255\255\255\255\255\060\000\060\000\255\255\060\000\
6129     \060\000\060\000\255\255\255\255\255\255\255\255\255\255\019\000\
6130     \255\255\019\000\255\255\255\255\060\000\255\255\060\000\060\000\
6131     \060\000\060\000\060\000\255\255\255\255\255\255\061\000\255\255\
6132     \255\255\061\000\061\000\061\000\255\255\255\255\255\255\061\000\
6133     \061\000\255\255\061\000\061\000\061\000\255\255\255\255\019\000\
6134     \255\255\019\000\255\255\255\255\255\255\255\255\060\000\061\000\
6135     \060\000\061\000\061\000\061\000\061\000\061\000\255\255\255\255\
6136     \255\255\062\000\255\255\255\255\062\000\062\000\062\000\255\255\
6137     \255\255\255\255\062\000\062\000\255\255\062\000\062\000\062\000\
6138     \255\255\255\255\255\255\255\255\255\255\255\255\060\000\255\255\
6139     \060\000\061\000\062\000\061\000\062\000\062\000\062\000\062\000\
6140     \062\000\255\255\255\255\255\255\063\000\255\255\255\255\063\000\
6141     \063\000\063\000\255\255\255\255\255\255\063\000\063\000\255\255\
6142     \063\000\063\000\063\000\255\255\255\255\255\255\255\255\255\255\
6143     \255\255\061\000\255\255\061\000\062\000\063\000\062\000\063\000\
6144     \063\000\063\000\063\000\063\000\255\255\255\255\255\255\064\000\
6145     \255\255\255\255\064\000\064\000\064\000\255\255\255\255\255\255\
6146     \064\000\064\000\255\255\064\000\064\000\064\000\255\255\255\255\
6147     \104\000\255\255\255\255\255\255\062\000\255\255\062\000\063\000\
6148     \064\000\063\000\064\000\064\000\064\000\064\000\064\000\255\255\
6149     \255\255\255\255\069\000\255\255\255\255\069\000\069\000\069\000\
6150     \255\255\255\255\255\255\069\000\069\000\255\255\069\000\069\000\
6151     \069\000\255\255\255\255\255\255\255\255\255\255\255\255\063\000\
6152     \255\255\063\000\064\000\069\000\064\000\069\000\069\000\069\000\
6153     \069\000\069\000\255\255\255\255\255\255\070\000\255\255\255\255\
6154     \070\000\070\000\070\000\255\255\255\255\255\255\070\000\070\000\
6155     \255\255\070\000\070\000\070\000\255\255\255\255\255\255\255\255\
6156     \255\255\255\255\064\000\255\255\064\000\069\000\070\000\069\000\
6157     \070\000\070\000\070\000\070\000\070\000\255\255\255\255\255\255\
6158     \071\000\255\255\255\255\071\000\071\000\071\000\255\255\255\255\
6159     \255\255\071\000\071\000\255\255\071\000\071\000\071\000\255\255\
6160     \255\255\255\255\255\255\255\255\255\255\069\000\255\255\069\000\
6161     \070\000\071\000\070\000\071\000\071\000\071\000\071\000\071\000\
6162     \255\255\255\255\255\255\075\000\255\255\255\255\075\000\075\000\
6163     \075\000\255\255\255\255\255\255\075\000\075\000\255\255\075\000\
6164     \075\000\075\000\255\255\255\255\255\255\255\255\255\255\255\255\
6165     \070\000\255\255\070\000\071\000\075\000\071\000\075\000\075\000\
6166     \075\000\075\000\075\000\255\255\255\255\255\255\076\000\255\255\
6167     \255\255\076\000\076\000\076\000\255\255\255\255\255\255\076\000\
6168     \076\000\255\255\076\000\076\000\076\000\255\255\255\255\255\255\
6169     \255\255\255\255\255\255\071\000\255\255\071\000\075\000\076\000\
6170     \075\000\076\000\076\000\076\000\076\000\076\000\255\255\255\255\
6171     \255\255\077\000\255\255\255\255\077\000\077\000\077\000\255\255\
6172     \255\255\255\255\077\000\077\000\255\255\077\000\077\000\077\000\
6173     \255\255\255\255\255\255\255\255\255\255\255\255\075\000\255\255\
6174     \075\000\076\000\077\000\076\000\077\000\077\000\077\000\077\000\
6175     \077\000\255\255\255\255\255\255\078\000\255\255\255\255\078\000\
6176     \078\000\078\000\255\255\255\255\255\255\078\000\078\000\255\255\
6177     \078\000\078\000\078\000\255\255\255\255\255\255\255\255\255\255\
6178     \255\255\076\000\255\255\076\000\077\000\078\000\077\000\078\000\
6179     \078\000\078\000\078\000\078\000\255\255\255\255\255\255\079\000\
6180     \255\255\255\255\079\000\079\000\079\000\255\255\255\255\255\255\
6181     \079\000\079\000\255\255\079\000\079\000\079\000\255\255\255\255\
6182     \255\255\099\000\255\255\255\255\077\000\255\255\077\000\078\000\
6183     \079\000\078\000\079\000\079\000\079\000\079\000\079\000\099\000\
6184     \099\000\099\000\099\000\099\000\099\000\099\000\099\000\099\000\
6185     \099\000\100\000\255\255\255\255\255\255\255\255\255\255\255\255\
6186     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\078\000\
6187     \255\255\078\000\079\000\255\255\079\000\255\255\255\255\255\255\
6188     \100\000\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6189     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6190     \100\000\100\000\100\000\100\000\100\000\100\000\100\000\100\000\
6191     \100\000\100\000\079\000\255\255\079\000\181\000\181\000\181\000\
6192     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
6193     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
6194     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\255\255\
6195     \255\255\255\255\255\255\181\000\255\255\181\000\181\000\181\000\
6196     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
6197     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
6198     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\255\255\
6199     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6200     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6201     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6202     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6203     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6204     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6205     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6206     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6207     \255\255\255\255\255\255\255\255\181\000\181\000\181\000\181\000\
6208     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
6209     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
6210     \181\000\181\000\181\000\255\255\181\000\181\000\181\000\181\000\
6211     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
6212     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
6213     \181\000\181\000\181\000\181\000\181\000\181\000\181\000\181\000\
6214     \181\000\181\000\181\000\183\000\181\000\181\000\181\000\181\000\
6215     \181\000\181\000\181\000\181\000\183\000\183\000\183\000\183\000\
6216     \183\000\183\000\183\000\183\000\183\000\183\000\255\255\255\255\
6217     \255\255\255\255\255\255\255\255\255\255\183\000\183\000\183\000\
6218     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
6219     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
6220     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\255\255\
6221     \255\255\255\255\255\255\183\000\255\255\183\000\183\000\183\000\
6222     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
6223     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
6224     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\255\255\
6225     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6226     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6227     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6228     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6229     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6230     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6231     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6232     \255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\
6233     \255\255\255\255\255\255\255\255\183\000\183\000\183\000\183\000\
6234     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
6235     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
6236     \183\000\183\000\183\000\255\255\183\000\183\000\183\000\183\000\
6237     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
6238     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
6239     \183\000\183\000\183\000\183\000\183\000\183\000\183\000\183\000\
6240     \183\000\183\000\183\000\255\255\183\000\183\000\183\000\183\000\
6241     \183\000\183\000\183\000\183\000\255\255";
6242                 Lexing.lex_code =
6243                   "\255\004\255\255\009\255\255\006\255\005\255\255\007\255\255\008\
6244     \255\255\000\007\255\000\006\001\008\255\000\005\255\011\255\010\
6245     \255\255\003\255\000\004\001\009\255\011\255\255\010\255\011\255\
6246     \255\000\004\001\009\003\010\002\011\255\001\255\255\000\001\255\
6247     ";
6248               }
6249               
6250             let rec token c lexbuf =
6251               (lexbuf.Lexing.lex_mem <- Array.create 12 (-1);
6252                __ocaml_lex_token_rec c lexbuf 0)
6253             and __ocaml_lex_token_rec c lexbuf __ocaml_lex_state =
6254               match Lexing.new_engine __ocaml_lex_tables __ocaml_lex_state
6255                       lexbuf
6256               with
6257               | 0 -> (update_loc c None 1 false 0; NEWLINE)
6258               | 1 ->
6259                   let x =
6260                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6261                       lexbuf.Lexing.lex_curr_pos
6262                   in BLANKS x
6263               | 2 ->
6264                   let x =
6265                     Lexing.sub_lexeme lexbuf
6266                       (lexbuf.Lexing.lex_start_pos + 1)
6267                       (lexbuf.Lexing.lex_curr_pos + (-1))
6268                   in LABEL x
6269               | 3 ->
6270                   let x =
6271                     Lexing.sub_lexeme lexbuf
6272                       (lexbuf.Lexing.lex_start_pos + 1)
6273                       (lexbuf.Lexing.lex_curr_pos + (-1))
6274                   in OPTLABEL x
6275               | 4 ->
6276                   let x =
6277                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6278                       lexbuf.Lexing.lex_curr_pos
6279                   in LIDENT x
6280               | 5 ->
6281                   let x =
6282                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6283                       lexbuf.Lexing.lex_curr_pos
6284                   in UIDENT x
6285               | 6 ->
6286                   let i =
6287                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6288                       lexbuf.Lexing.lex_curr_pos
6289                   in
6290                     (try INT (int_of_string i, i)
6291                      with
6292                      | Failure _ ->
6293                          err (Literal_overflow "int") (Loc.of_lexbuf lexbuf))
6294               | 7 ->
6295                   let f =
6296                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6297                       lexbuf.Lexing.lex_curr_pos
6298                   in
6299                     (try FLOAT (float_of_string f, f)
6300                      with
6301                      | Failure _ ->
6302                          err (Literal_overflow "float")
6303                            (Loc.of_lexbuf lexbuf))
6304               | 8 ->
6305                   let i =
6306                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6307                       (lexbuf.Lexing.lex_curr_pos + (-1))
6308                   in
6309                     (try INT32 (Int32.of_string i, i)
6310                      with
6311                      | Failure _ ->
6312                          err (Literal_overflow "int32")
6313                            (Loc.of_lexbuf lexbuf))
6314               | 9 ->
6315                   let i =
6316                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6317                       (lexbuf.Lexing.lex_curr_pos + (-1))
6318                   in
6319                     (try INT64 (Int64.of_string i, i)
6320                      with
6321                      | Failure _ ->
6322                          err (Literal_overflow "int64")
6323                            (Loc.of_lexbuf lexbuf))
6324               | 10 ->
6325                   let i =
6326                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6327                       (lexbuf.Lexing.lex_curr_pos + (-1))
6328                   in
6329                     (try NATIVEINT (Nativeint.of_string i, i)
6330                      with
6331                      | Failure _ ->
6332                          err (Literal_overflow "nativeint")
6333                            (Loc.of_lexbuf lexbuf))
6334               | 11 ->
6335                   (with_curr_loc string c;
6336                    let s = buff_contents c in STRING (TokenEval.string s, s))
6337               | 12 ->
6338                   let x =
6339                     Lexing.sub_lexeme lexbuf
6340                       (lexbuf.Lexing.lex_start_pos + 1)
6341                       (lexbuf.Lexing.lex_curr_pos + (-1))
6342                   in
6343                     (update_loc c None 1 false 1; CHAR (TokenEval.char x, x))
6344               | 13 ->
6345                   let x =
6346                     Lexing.sub_lexeme lexbuf
6347                       (lexbuf.Lexing.lex_start_pos + 1)
6348                       (lexbuf.Lexing.lex_curr_pos + (-1))
6349                   in CHAR (TokenEval.char x, x)
6350               | 14 ->
6351                   let c =
6352                     Lexing.sub_lexeme_char lexbuf
6353                       (lexbuf.Lexing.lex_start_pos + 2)
6354                   in
6355                     err (Illegal_escape (String.make 1 c))
6356                       (Loc.of_lexbuf lexbuf)
6357               | 15 ->
6358                   (store c; COMMENT (parse_nested comment (in_comment c)))
6359               | 16 ->
6360                   (warn Comment_start (Loc.of_lexbuf lexbuf);
6361                    parse comment (in_comment c);
6362                    COMMENT (buff_contents c))
6363               | 17 ->
6364                   (warn Comment_not_end (Loc.of_lexbuf lexbuf);
6365                    move_start_p (-1) c;
6366                    SYMBOL "*")
6367               | 18 ->
6368                   let beginning =
6369                     Lexing.sub_lexeme lexbuf
6370                       (lexbuf.Lexing.lex_start_pos + 2)
6371                       lexbuf.Lexing.lex_curr_pos
6372                   in
6373                     if quotations c
6374                     then
6375                       (move_start_p (- (String.length beginning));
6376                        mk_quotation quotation c "" "" 2)
6377                     else parse (symbolchar_star ("<<" ^ beginning)) c
6378               | 19 ->
6379                   if quotations c
6380                   then
6381                     QUOTATION
6382                       {
6383                         q_name = "";
6384                         q_loc = "";
6385                         q_shift = 2;
6386                         q_contents = "";
6387                       }
6388                   else parse (symbolchar_star "<<>>") c
6389               | 20 ->
6390                   if quotations c
6391                   then with_curr_loc maybe_quotation_at c
6392                   else parse (symbolchar_star "<@") c
6393               | 21 ->
6394                   if quotations c
6395                   then with_curr_loc maybe_quotation_colon c
6396                   else parse (symbolchar_star "<:") c
6397               | 22 ->
6398                   let num =
6399                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_mem.(0)
6400                       lexbuf.Lexing.lex_mem.(1)
6401                   and name =
6402                     Lexing.sub_lexeme_opt lexbuf lexbuf.Lexing.lex_mem.(3)
6403                       lexbuf.Lexing.lex_mem.(2) in
6404                   let inum = int_of_string num
6405                   in
6406                     (update_loc c name inum true 0;
6407                      LINE_DIRECTIVE (inum, name))
6408               | 23 ->
6409                   let op =
6410                     Lexing.sub_lexeme_char lexbuf
6411                       (lexbuf.Lexing.lex_start_pos + 1)
6412                   in ESCAPED_IDENT (String.make 1 op)
6413               | 24 ->
6414                   let op =
6415                     Lexing.sub_lexeme lexbuf
6416                       (lexbuf.Lexing.lex_start_pos + 1)
6417                       (lexbuf.Lexing.lex_curr_pos + (-1))
6418                   in ESCAPED_IDENT op
6419               | 25 ->
6420                   let op =
6421                     Lexing.sub_lexeme lexbuf
6422                       (lexbuf.Lexing.lex_start_pos + 1)
6423                       lexbuf.Lexing.lex_mem.(0)
6424                   in ESCAPED_IDENT op
6425               | 26 ->
6426                   let op =
6427                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_mem.(0)
6428                       (lexbuf.Lexing.lex_curr_pos + (-1))
6429                   in ESCAPED_IDENT op
6430               | 27 ->
6431                   let op =
6432                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_mem.(0)
6433                       lexbuf.Lexing.lex_mem.(1)
6434                   in ESCAPED_IDENT op
6435               | 28 ->
6436                   let x =
6437                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6438                       lexbuf.Lexing.lex_curr_pos
6439                   in SYMBOL x
6440               | 29 ->
6441                   if antiquots c
6442                   then with_curr_loc dollar (shift 1 c)
6443                   else parse (symbolchar_star "$") c
6444               | 30 ->
6445                   let x =
6446                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6447                       lexbuf.Lexing.lex_curr_pos
6448                   in SYMBOL x
6449               | 31 ->
6450                   let pos = lexbuf.lex_curr_p
6451                   in
6452                     (lexbuf.lex_curr_p <-
6453                        {
6454                          (pos)
6455                          with
6456                          pos_bol = pos.pos_bol + 1;
6457                          pos_cnum = pos.pos_cnum + 1;
6458                        };
6459                      EOI)
6460               | 32 ->
6461                   let c =
6462                     Lexing.sub_lexeme_char lexbuf lexbuf.Lexing.lex_start_pos
6463                   in err (Illegal_character c) (Loc.of_lexbuf lexbuf)
6464               | __ocaml_lex_state ->
6465                   (lexbuf.Lexing.refill_buff lexbuf;
6466                    __ocaml_lex_token_rec c lexbuf __ocaml_lex_state)
6467             and comment c lexbuf = __ocaml_lex_comment_rec c lexbuf 123
6468             and __ocaml_lex_comment_rec c lexbuf __ocaml_lex_state =
6469               match Lexing.engine __ocaml_lex_tables __ocaml_lex_state lexbuf
6470               with
6471               | 0 -> (store c; with_curr_loc comment c; parse comment c)
6472               | 1 -> store c
6473               | 2 ->
6474                   (store c;
6475                    if quotations c then with_curr_loc quotation c else ();
6476                    parse comment c)
6477               | 3 -> store_parse comment c
6478               | 4 ->
6479                   (store c;
6480                    (try with_curr_loc string c
6481                     with
6482                     | Loc.Exc_located (_, (Error.E Unterminated_string)) ->
6483                         err Unterminated_string_in_comment (loc c));
6484                    Buffer.add_char c.buffer '"';
6485                    parse comment c)
6486               | 5 -> store_parse comment c
6487               | 6 -> store_parse comment c
6488               | 7 -> (update_loc c None 1 false 1; store_parse comment c)
6489               | 8 -> store_parse comment c
6490               | 9 -> store_parse comment c
6491               | 10 -> store_parse comment c
6492               | 11 -> store_parse comment c
6493               | 12 -> err Unterminated_comment (loc c)
6494               | 13 -> (update_loc c None 1 false 0; store_parse comment c)
6495               | 14 -> store_parse comment c
6496               | __ocaml_lex_state ->
6497                   (lexbuf.Lexing.refill_buff lexbuf;
6498                    __ocaml_lex_comment_rec c lexbuf __ocaml_lex_state)
6499             and string c lexbuf =
6500               (lexbuf.Lexing.lex_mem <- Array.create 2 (-1);
6501                __ocaml_lex_string_rec c lexbuf 159)
6502             and __ocaml_lex_string_rec c lexbuf __ocaml_lex_state =
6503               match Lexing.new_engine __ocaml_lex_tables __ocaml_lex_state
6504                       lexbuf
6505               with
6506               | 0 -> set_start_p c
6507               | 1 ->
6508                   let space =
6509                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_mem.(0)
6510                       lexbuf.Lexing.lex_curr_pos
6511                   in
6512                     (update_loc c None 1 false (String.length space);
6513                      store_parse string c)
6514               | 2 -> store_parse string c
6515               | 3 -> store_parse string c
6516               | 4 -> store_parse string c
6517               | 5 ->
6518                   let x =
6519                     Lexing.sub_lexeme_char lexbuf
6520                       (lexbuf.Lexing.lex_start_pos + 1)
6521                   in
6522                     if is_in_comment c
6523                     then store_parse string c
6524                     else
6525                       (warn (Illegal_escape (String.make 1 x))
6526                          (Loc.of_lexbuf lexbuf);
6527                        store_parse string c)
6528               | 6 -> (update_loc c None 1 false 0; store_parse string c)
6529               | 7 -> err Unterminated_string (loc c)
6530               | 8 -> store_parse string c
6531               | __ocaml_lex_state ->
6532                   (lexbuf.Lexing.refill_buff lexbuf;
6533                    __ocaml_lex_string_rec c lexbuf __ocaml_lex_state)
6534             and symbolchar_star beginning c lexbuf =
6535               __ocaml_lex_symbolchar_star_rec beginning c lexbuf 176
6536             and
6537               __ocaml_lex_symbolchar_star_rec beginning c lexbuf
6538                                               __ocaml_lex_state =
6539               match Lexing.engine __ocaml_lex_tables __ocaml_lex_state lexbuf
6540               with
6541               | 0 ->
6542                   let tok =
6543                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6544                       lexbuf.Lexing.lex_curr_pos
6545                   in
6546                     (move_start_p (- (String.length beginning)) c;
6547                      SYMBOL (beginning ^ tok))
6548               | __ocaml_lex_state ->
6549                   (lexbuf.Lexing.refill_buff lexbuf;
6550                    __ocaml_lex_symbolchar_star_rec beginning c lexbuf
6551                      __ocaml_lex_state)
6552             and maybe_quotation_at c lexbuf =
6553               __ocaml_lex_maybe_quotation_at_rec c lexbuf 177
6554             and
6555               __ocaml_lex_maybe_quotation_at_rec c lexbuf __ocaml_lex_state =
6556               match Lexing.engine __ocaml_lex_tables __ocaml_lex_state lexbuf
6557               with
6558               | 0 ->
6559                   let loc =
6560                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6561                       (lexbuf.Lexing.lex_curr_pos + (-1))
6562                   in
6563                     mk_quotation quotation c "" loc (1 + (String.length loc))
6564               | 1 ->
6565                   let tok =
6566                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6567                       lexbuf.Lexing.lex_curr_pos
6568                   in SYMBOL ("<@" ^ tok)
6569               | __ocaml_lex_state ->
6570                   (lexbuf.Lexing.refill_buff lexbuf;
6571                    __ocaml_lex_maybe_quotation_at_rec c lexbuf
6572                      __ocaml_lex_state)
6573             and maybe_quotation_colon c lexbuf =
6574               (lexbuf.Lexing.lex_mem <- Array.create 2 (-1);
6575                __ocaml_lex_maybe_quotation_colon_rec c lexbuf 181)
6576             and
6577               __ocaml_lex_maybe_quotation_colon_rec c lexbuf
6578                                                     __ocaml_lex_state =
6579               match Lexing.new_engine __ocaml_lex_tables __ocaml_lex_state
6580                       lexbuf
6581               with
6582               | 0 ->
6583                   let name =
6584                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6585                       (lexbuf.Lexing.lex_curr_pos + (-1))
6586                   in
6587                     mk_quotation quotation c name ""
6588                       (1 + (String.length name))
6589               | 1 ->
6590                   let name =
6591                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6592                       lexbuf.Lexing.lex_mem.(0)
6593                   and loc =
6594                     Lexing.sub_lexeme lexbuf (lexbuf.Lexing.lex_mem.(0) + 1)
6595                       (lexbuf.Lexing.lex_curr_pos + (-1))
6596                   in
6597                     mk_quotation quotation c name loc
6598                       ((2 + (String.length loc)) + (String.length name))
6599               | 2 ->
6600                   let tok =
6601                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6602                       lexbuf.Lexing.lex_curr_pos
6603                   in SYMBOL ("<:" ^ tok)
6604               | __ocaml_lex_state ->
6605                   (lexbuf.Lexing.refill_buff lexbuf;
6606                    __ocaml_lex_maybe_quotation_colon_rec c lexbuf
6607                      __ocaml_lex_state)
6608             and quotation c lexbuf = __ocaml_lex_quotation_rec c lexbuf 188
6609             and __ocaml_lex_quotation_rec c lexbuf __ocaml_lex_state =
6610               match Lexing.engine __ocaml_lex_tables __ocaml_lex_state lexbuf
6611               with
6612               | 0 -> (store c; with_curr_loc quotation c; parse quotation c)
6613               | 1 -> store c
6614               | 2 -> err Unterminated_quotation (loc c)
6615               | 3 -> (update_loc c None 1 false 0; store_parse quotation c)
6616               | 4 -> store_parse quotation c
6617               | __ocaml_lex_state ->
6618                   (lexbuf.Lexing.refill_buff lexbuf;
6619                    __ocaml_lex_quotation_rec c lexbuf __ocaml_lex_state)
6620             and dollar c lexbuf = __ocaml_lex_dollar_rec c lexbuf 201
6621             and __ocaml_lex_dollar_rec c lexbuf __ocaml_lex_state =
6622               match Lexing.engine __ocaml_lex_tables __ocaml_lex_state lexbuf
6623               with
6624               | 0 -> (set_start_p c; ANTIQUOT ("", ""))
6625               | 1 ->
6626                   let name =
6627                     Lexing.sub_lexeme lexbuf lexbuf.Lexing.lex_start_pos
6628                       (lexbuf.Lexing.lex_curr_pos + (-1))
6629                   in
6630                     with_curr_loc (antiquot name)
6631                       (shift (1 + (String.length name)) c)
6632               | 2 -> store_parse (antiquot "") c
6633               | __ocaml_lex_state ->
6634                   (lexbuf.Lexing.refill_buff lexbuf;
6635                    __ocaml_lex_dollar_rec c lexbuf __ocaml_lex_state)
6636             and antiquot name c lexbuf =
6637               __ocaml_lex_antiquot_rec name c lexbuf 210
6638             and __ocaml_lex_antiquot_rec name c lexbuf __ocaml_lex_state =
6639               match Lexing.engine __ocaml_lex_tables __ocaml_lex_state lexbuf
6640               with
6641               | 0 -> (set_start_p c; ANTIQUOT (name, buff_contents c))
6642               | 1 -> err Unterminated_antiquot (loc c)
6643               | 2 ->
6644                   (update_loc c None 1 false 0;
6645                    store_parse (antiquot name) c)
6646               | 3 ->
6647                   (store c;
6648                    with_curr_loc quotation c;
6649                    parse (antiquot name) c)
6650               | 4 -> store_parse (antiquot name) c
6651               | __ocaml_lex_state ->
6652                   (lexbuf.Lexing.refill_buff lexbuf;
6653                    __ocaml_lex_antiquot_rec name c lexbuf __ocaml_lex_state)
6654               
6655             let lexing_store s buff max =
6656               let rec self n s =
6657                 if n >= max
6658                 then n
6659                 else
6660                   (match Stream.peek s with
6661                    | Some x -> (Stream.junk s; buff.[n] <- x; succ n)
6662                    | _ -> n)
6663               in self 0 s
6664               
6665             let from_context c =
6666               let next _ =
6667                 let tok = with_curr_loc token c in
6668                 let loc = Loc.of_lexbuf c.lexbuf in Some (tok, loc)
6669               in Stream.from next
6670               
6671             let from_lexbuf ?(quotations = true) lb =
6672               let c =
6673                 {
6674                   (default_context lb)
6675                   with
6676                   loc = Loc.of_lexbuf lb;
6677                   antiquots = !Camlp4_config.antiquotations;
6678                   quotations = quotations;
6679                 }
6680               in from_context c
6681               
6682             let setup_loc lb loc =
6683               let start_pos = Loc.start_pos loc
6684               in
6685                 (lb.lex_abs_pos <- start_pos.pos_cnum;
6686                  lb.lex_curr_p <- start_pos)
6687               
6688             let from_string ?quotations loc str =
6689               let lb = Lexing.from_string str
6690               in (setup_loc lb loc; from_lexbuf ?quotations lb)
6691               
6692             let from_stream ?quotations loc strm =
6693               let lb = Lexing.from_function (lexing_store strm)
6694               in (setup_loc lb loc; from_lexbuf ?quotations lb)
6695               
6696             let mk () loc strm =
6697               from_stream ~quotations: !Camlp4_config.quotations loc strm
6698               
6699           end
6700           
6701       end
6702       
6703     module Camlp4Ast =
6704       struct
6705         module Make (Loc : Sig.Loc) : Sig.Camlp4Ast with module Loc = Loc =
6706           struct
6707             module Loc = Loc
6708               
6709             module Ast =
6710               struct
6711                 include Sig.MakeCamlp4Ast(Loc)
6712                   
6713                 let safe_string_escaped s =
6714                   if
6715                     ((String.length s) > 2) &&
6716                       ((s.[0] = '\\') && (s.[1] = '$'))
6717                   then s
6718                   else String.escaped s
6719                   
6720               end
6721               
6722             include Ast
6723               
6724             external loc_of_ctyp : ctyp -> Loc.t = "%field0"
6725               
6726             external loc_of_patt : patt -> Loc.t = "%field0"
6727               
6728             external loc_of_expr : expr -> Loc.t = "%field0"
6729               
6730             external loc_of_module_type : module_type -> Loc.t = "%field0"
6731               
6732             external loc_of_module_expr : module_expr -> Loc.t = "%field0"
6733               
6734             external loc_of_sig_item : sig_item -> Loc.t = "%field0"
6735               
6736             external loc_of_str_item : str_item -> Loc.t = "%field0"
6737               
6738             external loc_of_class_type : class_type -> Loc.t = "%field0"
6739               
6740             external loc_of_class_sig_item : class_sig_item -> Loc.t =
6741               "%field0"
6742               
6743             external loc_of_class_expr : class_expr -> Loc.t = "%field0"
6744               
6745             external loc_of_class_str_item : class_str_item -> Loc.t =
6746               "%field0"
6747               
6748             external loc_of_with_constr : with_constr -> Loc.t = "%field0"
6749               
6750             external loc_of_binding : binding -> Loc.t = "%field0"
6751               
6752             external loc_of_rec_binding : rec_binding -> Loc.t = "%field0"
6753               
6754             external loc_of_module_binding : module_binding -> Loc.t =
6755               "%field0"
6756               
6757             external loc_of_match_case : match_case -> Loc.t = "%field0"
6758               
6759             external loc_of_ident : ident -> Loc.t = "%field0"
6760               
6761             let ghost = Loc.ghost
6762               
6763             let rec is_module_longident =
6764               function
6765               | Ast.IdAcc (_, _, i) -> is_module_longident i
6766               | Ast.IdApp (_, i1, i2) ->
6767                   (is_module_longident i1) && (is_module_longident i2)
6768               | Ast.IdUid (_, _) -> true
6769               | _ -> false
6770               
6771             let ident_of_expr =
6772               let error () =
6773                 invalid_arg
6774                   "ident_of_expr: this expression is not an identifier" in
6775               let rec self =
6776                 function
6777                 | Ast.ExApp (_loc, e1, e2) ->
6778                     Ast.IdApp (_loc, self e1, self e2)
6779                 | Ast.ExAcc (_loc, e1, e2) ->
6780                     Ast.IdAcc (_loc, self e1, self e2)
6781                 | Ast.ExId (_, (Ast.IdLid (_, _))) -> error ()
6782                 | Ast.ExId (_, i) ->
6783                     if is_module_longident i then i else error ()
6784                 | _ -> error ()
6785               in
6786                 function
6787                 | Ast.ExId (_, i) -> i
6788                 | Ast.ExApp (_, _, _) -> error ()
6789                 | t -> self t
6790               
6791             let ident_of_ctyp =
6792               let error () =
6793                 invalid_arg "ident_of_ctyp: this type is not an identifier" in
6794               let rec self =
6795                 function
6796                 | Ast.TyApp (_loc, t1, t2) ->
6797                     Ast.IdApp (_loc, self t1, self t2)
6798                 | Ast.TyId (_, (Ast.IdLid (_, _))) -> error ()
6799                 | Ast.TyId (_, i) ->
6800                     if is_module_longident i then i else error ()
6801                 | _ -> error ()
6802               in function | Ast.TyId (_, i) -> i | t -> self t
6803               
6804             let ident_of_patt =
6805               let error () =
6806                 invalid_arg
6807                   "ident_of_patt: this pattern is not an identifier" in
6808               let rec self =
6809                 function
6810                 | Ast.PaApp (_loc, p1, p2) ->
6811                     Ast.IdApp (_loc, self p1, self p2)
6812                 | Ast.PaId (_, (Ast.IdLid (_, _))) -> error ()
6813                 | Ast.PaId (_, i) ->
6814                     if is_module_longident i then i else error ()
6815                 | _ -> error ()
6816               in function | Ast.PaId (_, i) -> i | p -> self p
6817               
6818             let rec is_irrefut_patt =
6819               function
6820               | Ast.PaId (_, (Ast.IdLid (_, _))) -> true
6821               | Ast.PaId (_, (Ast.IdUid (_, "()"))) -> true
6822               | Ast.PaAny _ -> true
6823               | Ast.PaNil _ -> true
6824               | Ast.PaAli (_, x, y) ->
6825                   (is_irrefut_patt x) && (is_irrefut_patt y)
6826               | Ast.PaRec (_, p) -> is_irrefut_patt p
6827               | Ast.PaEq (_, _, p) -> is_irrefut_patt p
6828               | Ast.PaSem (_, p1, p2) ->
6829                   (is_irrefut_patt p1) && (is_irrefut_patt p2)
6830               | Ast.PaCom (_, p1, p2) ->
6831                   (is_irrefut_patt p1) && (is_irrefut_patt p2)
6832               | Ast.PaOrp (_, p1, p2) ->
6833                   (is_irrefut_patt p1) && (is_irrefut_patt p2)
6834               | Ast.PaApp (_, p1, p2) ->
6835                   (is_irrefut_patt p1) && (is_irrefut_patt p2)
6836               | Ast.PaTyc (_, p, _) -> is_irrefut_patt p
6837               | Ast.PaTup (_, pl) -> is_irrefut_patt pl
6838               | Ast.PaOlb (_, _, (Ast.PaNil _)) -> true
6839               | Ast.PaOlb (_, _, p) -> is_irrefut_patt p
6840               | Ast.PaOlbi (_, _, p, _) -> is_irrefut_patt p
6841               | Ast.PaLab (_, _, (Ast.PaNil _)) -> true
6842               | Ast.PaLab (_, _, p) -> is_irrefut_patt p
6843               | Ast.PaLaz (_, p) -> is_irrefut_patt p
6844               | Ast.PaId (_, _) -> false
6845               | Ast.PaVrn (_, _) | Ast.PaStr (_, _) | Ast.PaRng (_, _, _) |
6846                   Ast.PaFlo (_, _) | Ast.PaNativeInt (_, _) |
6847                   Ast.PaInt64 (_, _) | Ast.PaInt32 (_, _) | Ast.PaInt (_, _)
6848                   | Ast.PaChr (_, _) | Ast.PaTyp (_, _) | Ast.PaArr (_, _) |
6849                   Ast.PaAnt (_, _) -> false
6850               
6851             let rec is_constructor =
6852               function
6853               | Ast.IdAcc (_, _, i) -> is_constructor i
6854               | Ast.IdUid (_, _) -> true
6855               | Ast.IdLid (_, _) | Ast.IdApp (_, _, _) -> false
6856               | Ast.IdAnt (_, _) -> assert false
6857               
6858             let is_patt_constructor =
6859               function
6860               | Ast.PaId (_, i) -> is_constructor i
6861               | Ast.PaVrn (_, _) -> true
6862               | _ -> false
6863               
6864             let rec is_expr_constructor =
6865               function
6866               | Ast.ExId (_, i) -> is_constructor i
6867               | Ast.ExAcc (_, e1, e2) ->
6868                   (is_expr_constructor e1) && (is_expr_constructor e2)
6869               | Ast.ExVrn (_, _) -> true
6870               | _ -> false
6871               
6872             let rec tyOr_of_list =
6873               function
6874               | [] -> Ast.TyNil ghost
6875               | [ t ] -> t
6876               | t :: ts ->
6877                   let _loc = loc_of_ctyp t
6878                   in Ast.TyOr (_loc, t, tyOr_of_list ts)
6879               
6880             let rec tyAnd_of_list =
6881               function
6882               | [] -> Ast.TyNil ghost
6883               | [ t ] -> t
6884               | t :: ts ->
6885                   let _loc = loc_of_ctyp t
6886                   in Ast.TyAnd (_loc, t, tyAnd_of_list ts)
6887               
6888             let rec tySem_of_list =
6889               function
6890               | [] -> Ast.TyNil ghost
6891               | [ t ] -> t
6892               | t :: ts ->
6893                   let _loc = loc_of_ctyp t
6894                   in Ast.TySem (_loc, t, tySem_of_list ts)
6895               
6896             let rec tyCom_of_list =
6897               function
6898               | [] -> Ast.TyNil ghost
6899               | [ t ] -> t
6900               | t :: ts ->
6901                   let _loc = loc_of_ctyp t
6902                   in Ast.TyCom (_loc, t, tyCom_of_list ts)
6903               
6904             let rec tyAmp_of_list =
6905               function
6906               | [] -> Ast.TyNil ghost
6907               | [ t ] -> t
6908               | t :: ts ->
6909                   let _loc = loc_of_ctyp t
6910                   in Ast.TyAmp (_loc, t, tyAmp_of_list ts)
6911               
6912             let rec tySta_of_list =
6913               function
6914               | [] -> Ast.TyNil ghost
6915               | [ t ] -> t
6916               | t :: ts ->
6917                   let _loc = loc_of_ctyp t
6918                   in Ast.TySta (_loc, t, tySta_of_list ts)
6919               
6920             let rec stSem_of_list =
6921               function
6922               | [] -> Ast.StNil ghost
6923               | [ t ] -> t
6924               | t :: ts ->
6925                   let _loc = loc_of_str_item t
6926                   in Ast.StSem (_loc, t, stSem_of_list ts)
6927               
6928             let rec sgSem_of_list =
6929               function
6930               | [] -> Ast.SgNil ghost
6931               | [ t ] -> t
6932               | t :: ts ->
6933                   let _loc = loc_of_sig_item t
6934                   in Ast.SgSem (_loc, t, sgSem_of_list ts)
6935               
6936             let rec biAnd_of_list =
6937               function
6938               | [] -> Ast.BiNil ghost
6939               | [ b ] -> b
6940               | b :: bs ->
6941                   let _loc = loc_of_binding b
6942                   in Ast.BiAnd (_loc, b, biAnd_of_list bs)
6943               
6944             let rec rbSem_of_list =
6945               function
6946               | [] -> Ast.RbNil ghost
6947               | [ b ] -> b
6948               | b :: bs ->
6949                   let _loc = loc_of_rec_binding b
6950                   in Ast.RbSem (_loc, b, rbSem_of_list bs)
6951               
6952             let rec wcAnd_of_list =
6953               function
6954               | [] -> Ast.WcNil ghost
6955               | [ w ] -> w
6956               | w :: ws ->
6957                   let _loc = loc_of_with_constr w
6958                   in Ast.WcAnd (_loc, w, wcAnd_of_list ws)
6959               
6960             let rec idAcc_of_list =
6961               function
6962               | [] -> assert false
6963               | [ i ] -> i
6964               | i :: is ->
6965                   let _loc = loc_of_ident i
6966                   in Ast.IdAcc (_loc, i, idAcc_of_list is)
6967               
6968             let rec idApp_of_list =
6969               function
6970               | [] -> assert false
6971               | [ i ] -> i
6972               | i :: is ->
6973                   let _loc = loc_of_ident i
6974                   in Ast.IdApp (_loc, i, idApp_of_list is)
6975               
6976             let rec mcOr_of_list =
6977               function
6978               | [] -> Ast.McNil ghost
6979               | [ x ] -> x
6980               | x :: xs ->
6981                   let _loc = loc_of_match_case x
6982                   in Ast.McOr (_loc, x, mcOr_of_list xs)
6983               
6984             let rec mbAnd_of_list =
6985               function
6986               | [] -> Ast.MbNil ghost
6987               | [ x ] -> x
6988               | x :: xs ->
6989                   let _loc = loc_of_module_binding x
6990                   in Ast.MbAnd (_loc, x, mbAnd_of_list xs)
6991               
6992             let rec meApp_of_list =
6993               function
6994               | [] -> assert false
6995               | [ x ] -> x
6996               | x :: xs ->
6997                   let _loc = loc_of_module_expr x
6998                   in Ast.MeApp (_loc, x, meApp_of_list xs)
6999               
7000             let rec ceAnd_of_list =
7001               function
7002               | [] -> Ast.CeNil ghost
7003               | [ x ] -> x
7004               | x :: xs ->
7005                   let _loc = loc_of_class_expr x
7006                   in Ast.CeAnd (_loc, x, ceAnd_of_list xs)
7007               
7008             let rec ctAnd_of_list =
7009               function
7010               | [] -> Ast.CtNil ghost
7011               | [ x ] -> x
7012               | x :: xs ->
7013                   let _loc = loc_of_class_type x
7014                   in Ast.CtAnd (_loc, x, ctAnd_of_list xs)
7015               
7016             let rec cgSem_of_list =
7017               function
7018               | [] -> Ast.CgNil ghost
7019               | [ x ] -> x
7020               | x :: xs ->
7021                   let _loc = loc_of_class_sig_item x
7022                   in Ast.CgSem (_loc, x, cgSem_of_list xs)
7023               
7024             let rec crSem_of_list =
7025               function
7026               | [] -> Ast.CrNil ghost
7027               | [ x ] -> x
7028               | x :: xs ->
7029                   let _loc = loc_of_class_str_item x
7030                   in Ast.CrSem (_loc, x, crSem_of_list xs)
7031               
7032             let rec paSem_of_list =
7033               function
7034               | [] -> Ast.PaNil ghost
7035               | [ x ] -> x
7036               | x :: xs ->
7037                   let _loc = loc_of_patt x
7038                   in Ast.PaSem (_loc, x, paSem_of_list xs)
7039               
7040             let rec paCom_of_list =
7041               function
7042               | [] -> Ast.PaNil ghost
7043               | [ x ] -> x
7044               | x :: xs ->
7045                   let _loc = loc_of_patt x
7046                   in Ast.PaCom (_loc, x, paCom_of_list xs)
7047               
7048             let rec exSem_of_list =
7049               function
7050               | [] -> Ast.ExNil ghost
7051               | [ x ] -> x
7052               | x :: xs ->
7053                   let _loc = loc_of_expr x
7054                   in Ast.ExSem (_loc, x, exSem_of_list xs)
7055               
7056             let rec exCom_of_list =
7057               function
7058               | [] -> Ast.ExNil ghost
7059               | [ x ] -> x
7060               | x :: xs ->
7061                   let _loc = loc_of_expr x
7062                   in Ast.ExCom (_loc, x, exCom_of_list xs)
7063               
7064             let ty_of_stl =
7065               function
7066               | (_loc, s, []) -> Ast.TyId (_loc, Ast.IdUid (_loc, s))
7067               | (_loc, s, tl) ->
7068                   Ast.TyOf (_loc, Ast.TyId (_loc, Ast.IdUid (_loc, s)),
7069                     tyAnd_of_list tl)
7070               
7071             let ty_of_sbt =
7072               function
7073               | (_loc, s, true, t) ->
7074                   Ast.TyCol (_loc, Ast.TyId (_loc, Ast.IdLid (_loc, s)),
7075                     Ast.TyMut (_loc, t))
7076               | (_loc, s, false, t) ->
7077                   Ast.TyCol (_loc, Ast.TyId (_loc, Ast.IdLid (_loc, s)), t)
7078               
7079             let bi_of_pe (p, e) =
7080               let _loc = loc_of_patt p in Ast.BiEq (_loc, p, e)
7081               
7082             let sum_type_of_list l = tyOr_of_list (List.map ty_of_stl l)
7083               
7084             let record_type_of_list l = tySem_of_list (List.map ty_of_sbt l)
7085               
7086             let binding_of_pel l = biAnd_of_list (List.map bi_of_pe l)
7087               
7088             let rec pel_of_binding =
7089               function
7090               | Ast.BiAnd (_, b1, b2) ->
7091                   (pel_of_binding b1) @ (pel_of_binding b2)
7092               | Ast.BiEq (_, p, e) -> [ (p, e) ]
7093               | _ -> assert false
7094               
7095             let rec list_of_binding x acc =
7096               match x with
7097               | Ast.BiAnd (_, b1, b2) ->
7098                   list_of_binding b1 (list_of_binding b2 acc)
7099               | t -> t :: acc
7100               
7101             let rec list_of_rec_binding x acc =
7102               match x with
7103               | Ast.RbSem (_, b1, b2) ->
7104                   list_of_rec_binding b1 (list_of_rec_binding b2 acc)
7105               | t -> t :: acc
7106               
7107             let rec list_of_with_constr x acc =
7108               match x with
7109               | Ast.WcAnd (_, w1, w2) ->
7110                   list_of_with_constr w1 (list_of_with_constr w2 acc)
7111               | t -> t :: acc
7112               
7113             let rec list_of_ctyp x acc =
7114               match x with
7115               | Ast.TyNil _ -> acc
7116               | Ast.TyAmp (_, x, y) | Ast.TyCom (_, x, y) |
7117                   Ast.TySta (_, x, y) | Ast.TySem (_, x, y) |
7118                   Ast.TyAnd (_, x, y) | Ast.TyOr (_, x, y) ->
7119                   list_of_ctyp x (list_of_ctyp y acc)
7120               | x -> x :: acc
7121               
7122             let rec list_of_patt x acc =
7123               match x with
7124               | Ast.PaNil _ -> acc
7125               | Ast.PaCom (_, x, y) | Ast.PaSem (_, x, y) ->
7126                   list_of_patt x (list_of_patt y acc)
7127               | x -> x :: acc
7128               
7129             let rec list_of_expr x acc =
7130               match x with
7131               | Ast.ExNil _ -> acc
7132               | Ast.ExCom (_, x, y) | Ast.ExSem (_, x, y) ->
7133                   list_of_expr x (list_of_expr y acc)
7134               | x -> x :: acc
7135               
7136             let rec list_of_str_item x acc =
7137               match x with
7138               | Ast.StNil _ -> acc
7139               | Ast.StSem (_, x, y) ->
7140                   list_of_str_item x (list_of_str_item y acc)
7141               | x -> x :: acc
7142               
7143             let rec list_of_sig_item x acc =
7144               match x with
7145               | Ast.SgNil _ -> acc
7146               | Ast.SgSem (_, x, y) ->
7147                   list_of_sig_item x (list_of_sig_item y acc)
7148               | x -> x :: acc
7149               
7150             let rec list_of_class_sig_item x acc =
7151               match x with
7152               | Ast.CgNil _ -> acc
7153               | Ast.CgSem (_, x, y) ->
7154                   list_of_class_sig_item x (list_of_class_sig_item y acc)
7155               | x -> x :: acc
7156               
7157             let rec list_of_class_str_item x acc =
7158               match x with
7159               | Ast.CrNil _ -> acc
7160               | Ast.CrSem (_, x, y) ->
7161                   list_of_class_str_item x (list_of_class_str_item y acc)
7162               | x -> x :: acc
7163               
7164             let rec list_of_class_type x acc =
7165               match x with
7166               | Ast.CtAnd (_, x, y) ->
7167                   list_of_class_type x (list_of_class_type y acc)
7168               | x -> x :: acc
7169               
7170             let rec list_of_class_expr x acc =
7171               match x with
7172               | Ast.CeAnd (_, x, y) ->
7173                   list_of_class_expr x (list_of_class_expr y acc)
7174               | x -> x :: acc
7175               
7176             let rec list_of_module_expr x acc =
7177               match x with
7178               | Ast.MeApp (_, x, y) ->
7179                   list_of_module_expr x (list_of_module_expr y acc)
7180               | x -> x :: acc
7181               
7182             let rec list_of_match_case x acc =
7183               match x with
7184               | Ast.McNil _ -> acc
7185               | Ast.McOr (_, x, y) ->
7186                   list_of_match_case x (list_of_match_case y acc)
7187               | x -> x :: acc
7188               
7189             let rec list_of_ident x acc =
7190               match x with
7191               | Ast.IdAcc (_, x, y) | Ast.IdApp (_, x, y) ->
7192                   list_of_ident x (list_of_ident y acc)
7193               | x -> x :: acc
7194               
7195             let rec list_of_module_binding x acc =
7196               match x with
7197               | Ast.MbAnd (_, x, y) ->
7198                   list_of_module_binding x (list_of_module_binding y acc)
7199               | x -> x :: acc
7200               
7201             module Meta =
7202               struct
7203                 module type META_LOC =
7204                   sig
7205                     val meta_loc_patt : Loc.t -> Loc.t -> Ast.patt
7206                       
7207                     val meta_loc_expr : Loc.t -> Loc.t -> Ast.expr
7208                       
7209                   end
7210                   
7211                 module MetaLoc =
7212                   struct
7213                     let meta_loc_patt _loc location =
7214                       let (a, b, c, d, e, f, g, h) = Loc.to_tuple location
7215                       in
7216                         Ast.PaApp (_loc,
7217                           Ast.PaId (_loc,
7218                             Ast.IdAcc (_loc, Ast.IdUid (_loc, "Loc"),
7219                               Ast.IdLid (_loc, "of_tuple"))),
7220                           Ast.PaTup (_loc,
7221                             Ast.PaCom (_loc,
7222                               Ast.PaStr (_loc, Ast.safe_string_escaped a),
7223                               Ast.PaCom (_loc,
7224                                 Ast.PaCom (_loc,
7225                                   Ast.PaCom (_loc,
7226                                     Ast.PaCom (_loc,
7227                                       Ast.PaCom (_loc,
7228                                         Ast.PaCom (_loc,
7229                                           Ast.PaInt (_loc, string_of_int b),
7230                                           Ast.PaInt (_loc, string_of_int c)),
7231                                         Ast.PaInt (_loc, string_of_int d)),
7232                                       Ast.PaInt (_loc, string_of_int e)),
7233                                     Ast.PaInt (_loc, string_of_int f)),
7234                                   Ast.PaInt (_loc, string_of_int g)),
7235                                 if h
7236                                 then
7237                                   Ast.PaId (_loc, Ast.IdUid (_loc, "True"))
7238                                 else
7239                                   Ast.PaId (_loc, Ast.IdUid (_loc, "False"))))))
7240                       
7241                     let meta_loc_expr _loc location =
7242                       let (a, b, c, d, e, f, g, h) = Loc.to_tuple location
7243                       in
7244                         Ast.ExApp (_loc,
7245                           Ast.ExId (_loc,
7246                             Ast.IdAcc (_loc, Ast.IdUid (_loc, "Loc"),
7247                               Ast.IdLid (_loc, "of_tuple"))),
7248                           Ast.ExTup (_loc,
7249                             Ast.ExCom (_loc,
7250                               Ast.ExStr (_loc, Ast.safe_string_escaped a),
7251                               Ast.ExCom (_loc,
7252                                 Ast.ExCom (_loc,
7253                                   Ast.ExCom (_loc,
7254                                     Ast.ExCom (_loc,
7255                                       Ast.ExCom (_loc,
7256                                         Ast.ExCom (_loc,
7257                                           Ast.ExInt (_loc, string_of_int b),
7258                                           Ast.ExInt (_loc, string_of_int c)),
7259                                         Ast.ExInt (_loc, string_of_int d)),
7260                                       Ast.ExInt (_loc, string_of_int e)),
7261                                     Ast.ExInt (_loc, string_of_int f)),
7262                                   Ast.ExInt (_loc, string_of_int g)),
7263                                 if h
7264                                 then
7265                                   Ast.ExId (_loc, Ast.IdUid (_loc, "True"))
7266                                 else
7267                                   Ast.ExId (_loc, Ast.IdUid (_loc, "False"))))))
7268                       
7269                   end
7270                   
7271                 module MetaGhostLoc =
7272                   struct
7273                     let meta_loc_patt _loc _ =
7274                       Ast.PaId (_loc,
7275                         Ast.IdAcc (_loc, Ast.IdUid (_loc, "Loc"),
7276                           Ast.IdLid (_loc, "ghost")))
7277                       
7278                     let meta_loc_expr _loc _ =
7279                       Ast.ExId (_loc,
7280                         Ast.IdAcc (_loc, Ast.IdUid (_loc, "Loc"),
7281                           Ast.IdLid (_loc, "ghost")))
7282                       
7283                   end
7284                   
7285                 module MetaLocVar =
7286                   struct
7287                     let meta_loc_patt _loc _ =
7288                       Ast.PaId (_loc, Ast.IdLid (_loc, !Loc.name))
7289                       
7290                     let meta_loc_expr _loc _ =
7291                       Ast.ExId (_loc, Ast.IdLid (_loc, !Loc.name))
7292                       
7293                   end
7294                   
7295                 module Make (MetaLoc : META_LOC) =
7296                   struct
7297                     open MetaLoc
7298                       
7299                     let meta_loc = meta_loc_expr
7300                       
7301                     module Expr =
7302                       struct
7303                         let meta_string _loc s = Ast.ExStr (_loc, s)
7304                           
7305                         let meta_int _loc s = Ast.ExInt (_loc, s)
7306                           
7307                         let meta_float _loc s = Ast.ExFlo (_loc, s)
7308                           
7309                         let meta_char _loc s = Ast.ExChr (_loc, s)
7310                           
7311                         let meta_bool _loc =
7312                           function
7313                           | false ->
7314                               Ast.ExId (_loc, Ast.IdUid (_loc, "False"))
7315                           | true -> Ast.ExId (_loc, Ast.IdUid (_loc, "True"))
7316                           
7317                         let rec meta_list mf_a _loc =
7318                           function
7319                           | [] -> Ast.ExId (_loc, Ast.IdUid (_loc, "[]"))
7320                           | x :: xs ->
7321                               Ast.ExApp (_loc,
7322                                 Ast.ExApp (_loc,
7323                                   Ast.ExId (_loc, Ast.IdUid (_loc, "::")),
7324                                   mf_a _loc x),
7325                                 meta_list mf_a _loc xs)
7326                           
7327                         let rec meta_binding _loc =
7328                           function
7329                           | Ast.BiAnt (x0, x1) -> Ast.ExAnt (x0, x1)
7330                           | Ast.BiEq (x0, x1, x2) ->
7331                               Ast.ExApp (_loc,
7332                                 Ast.ExApp (_loc,
7333                                   Ast.ExApp (_loc,
7334                                     Ast.ExId (_loc,
7335                                       Ast.IdAcc (_loc,
7336                                         Ast.IdUid (_loc, "Ast"),
7337                                         Ast.IdUid (_loc, "BiEq"))),
7338                                     meta_loc _loc x0),
7339                                   meta_patt _loc x1),
7340                                 meta_expr _loc x2)
7341                           | Ast.BiAnd (x0, x1, x2) ->
7342                               Ast.ExApp (_loc,
7343                                 Ast.ExApp (_loc,
7344                                   Ast.ExApp (_loc,
7345                                     Ast.ExId (_loc,
7346                                       Ast.IdAcc (_loc,
7347                                         Ast.IdUid (_loc, "Ast"),
7348                                         Ast.IdUid (_loc, "BiAnd"))),
7349                                     meta_loc _loc x0),
7350                                   meta_binding _loc x1),
7351                                 meta_binding _loc x2)
7352                           | Ast.BiNil x0 ->
7353                               Ast.ExApp (_loc,
7354                                 Ast.ExId (_loc,
7355                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7356                                     Ast.IdUid (_loc, "BiNil"))),
7357                                 meta_loc _loc x0)
7358                         and meta_class_expr _loc =
7359                           function
7360                           | Ast.CeAnt (x0, x1) -> Ast.ExAnt (x0, x1)
7361                           | Ast.CeEq (x0, x1, x2) ->
7362                               Ast.ExApp (_loc,
7363                                 Ast.ExApp (_loc,
7364                                   Ast.ExApp (_loc,
7365                                     Ast.ExId (_loc,
7366                                       Ast.IdAcc (_loc,
7367                                         Ast.IdUid (_loc, "Ast"),
7368                                         Ast.IdUid (_loc, "CeEq"))),
7369                                     meta_loc _loc x0),
7370                                   meta_class_expr _loc x1),
7371                                 meta_class_expr _loc x2)
7372                           | Ast.CeAnd (x0, x1, x2) ->
7373                               Ast.ExApp (_loc,
7374                                 Ast.ExApp (_loc,
7375                                   Ast.ExApp (_loc,
7376                                     Ast.ExId (_loc,
7377                                       Ast.IdAcc (_loc,
7378                                         Ast.IdUid (_loc, "Ast"),
7379                                         Ast.IdUid (_loc, "CeAnd"))),
7380                                     meta_loc _loc x0),
7381                                   meta_class_expr _loc x1),
7382                                 meta_class_expr _loc x2)
7383                           | Ast.CeTyc (x0, x1, x2) ->
7384                               Ast.ExApp (_loc,
7385                                 Ast.ExApp (_loc,
7386                                   Ast.ExApp (_loc,
7387                                     Ast.ExId (_loc,
7388                                       Ast.IdAcc (_loc,
7389                                         Ast.IdUid (_loc, "Ast"),
7390                                         Ast.IdUid (_loc, "CeTyc"))),
7391                                     meta_loc _loc x0),
7392                                   meta_class_expr _loc x1),
7393                                 meta_class_type _loc x2)
7394                           | Ast.CeStr (x0, x1, x2) ->
7395                               Ast.ExApp (_loc,
7396                                 Ast.ExApp (_loc,
7397                                   Ast.ExApp (_loc,
7398                                     Ast.ExId (_loc,
7399                                       Ast.IdAcc (_loc,
7400                                         Ast.IdUid (_loc, "Ast"),
7401                                         Ast.IdUid (_loc, "CeStr"))),
7402                                     meta_loc _loc x0),
7403                                   meta_patt _loc x1),
7404                                 meta_class_str_item _loc x2)
7405                           | Ast.CeLet (x0, x1, x2, x3) ->
7406                               Ast.ExApp (_loc,
7407                                 Ast.ExApp (_loc,
7408                                   Ast.ExApp (_loc,
7409                                     Ast.ExApp (_loc,
7410                                       Ast.ExId (_loc,
7411                                         Ast.IdAcc (_loc,
7412                                           Ast.IdUid (_loc, "Ast"),
7413                                           Ast.IdUid (_loc, "CeLet"))),
7414                                       meta_loc _loc x0),
7415                                     meta_meta_bool _loc x1),
7416                                   meta_binding _loc x2),
7417                                 meta_class_expr _loc x3)
7418                           | Ast.CeFun (x0, x1, x2) ->
7419                               Ast.ExApp (_loc,
7420                                 Ast.ExApp (_loc,
7421                                   Ast.ExApp (_loc,
7422                                     Ast.ExId (_loc,
7423                                       Ast.IdAcc (_loc,
7424                                         Ast.IdUid (_loc, "Ast"),
7425                                         Ast.IdUid (_loc, "CeFun"))),
7426                                     meta_loc _loc x0),
7427                                   meta_patt _loc x1),
7428                                 meta_class_expr _loc x2)
7429                           | Ast.CeCon (x0, x1, x2, x3) ->
7430                               Ast.ExApp (_loc,
7431                                 Ast.ExApp (_loc,
7432                                   Ast.ExApp (_loc,
7433                                     Ast.ExApp (_loc,
7434                                       Ast.ExId (_loc,
7435                                         Ast.IdAcc (_loc,
7436                                           Ast.IdUid (_loc, "Ast"),
7437                                           Ast.IdUid (_loc, "CeCon"))),
7438                                       meta_loc _loc x0),
7439                                     meta_meta_bool _loc x1),
7440                                   meta_ident _loc x2),
7441                                 meta_ctyp _loc x3)
7442                           | Ast.CeApp (x0, x1, x2) ->
7443                               Ast.ExApp (_loc,
7444                                 Ast.ExApp (_loc,
7445                                   Ast.ExApp (_loc,
7446                                     Ast.ExId (_loc,
7447                                       Ast.IdAcc (_loc,
7448                                         Ast.IdUid (_loc, "Ast"),
7449                                         Ast.IdUid (_loc, "CeApp"))),
7450                                     meta_loc _loc x0),
7451                                   meta_class_expr _loc x1),
7452                                 meta_expr _loc x2)
7453                           | Ast.CeNil x0 ->
7454                               Ast.ExApp (_loc,
7455                                 Ast.ExId (_loc,
7456                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7457                                     Ast.IdUid (_loc, "CeNil"))),
7458                                 meta_loc _loc x0)
7459                         and meta_class_sig_item _loc =
7460                           function
7461                           | Ast.CgAnt (x0, x1) -> Ast.ExAnt (x0, x1)
7462                           | Ast.CgVir (x0, x1, x2, x3) ->
7463                               Ast.ExApp (_loc,
7464                                 Ast.ExApp (_loc,
7465                                   Ast.ExApp (_loc,
7466                                     Ast.ExApp (_loc,
7467                                       Ast.ExId (_loc,
7468                                         Ast.IdAcc (_loc,
7469                                           Ast.IdUid (_loc, "Ast"),
7470                                           Ast.IdUid (_loc, "CgVir"))),
7471                                       meta_loc _loc x0),
7472                                     meta_string _loc x1),
7473                                   meta_meta_bool _loc x2),
7474                                 meta_ctyp _loc x3)
7475                           | Ast.CgVal (x0, x1, x2, x3, x4) ->
7476                               Ast.ExApp (_loc,
7477                                 Ast.ExApp (_loc,
7478                                   Ast.ExApp (_loc,
7479                                     Ast.ExApp (_loc,
7480                                       Ast.ExApp (_loc,
7481                                         Ast.ExId (_loc,
7482                                           Ast.IdAcc (_loc,
7483                                             Ast.IdUid (_loc, "Ast"),
7484                                             Ast.IdUid (_loc, "CgVal"))),
7485                                         meta_loc _loc x0),
7486                                       meta_string _loc x1),
7487                                     meta_meta_bool _loc x2),
7488                                   meta_meta_bool _loc x3),
7489                                 meta_ctyp _loc x4)
7490                           | Ast.CgMth (x0, x1, x2, x3) ->
7491                               Ast.ExApp (_loc,
7492                                 Ast.ExApp (_loc,
7493                                   Ast.ExApp (_loc,
7494                                     Ast.ExApp (_loc,
7495                                       Ast.ExId (_loc,
7496                                         Ast.IdAcc (_loc,
7497                                           Ast.IdUid (_loc, "Ast"),
7498                                           Ast.IdUid (_loc, "CgMth"))),
7499                                       meta_loc _loc x0),
7500                                     meta_string _loc x1),
7501                                   meta_meta_bool _loc x2),
7502                                 meta_ctyp _loc x3)
7503                           | Ast.CgInh (x0, x1) ->
7504                               Ast.ExApp (_loc,
7505                                 Ast.ExApp (_loc,
7506                                   Ast.ExId (_loc,
7507                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7508                                       Ast.IdUid (_loc, "CgInh"))),
7509                                   meta_loc _loc x0),
7510                                 meta_class_type _loc x1)
7511                           | Ast.CgSem (x0, x1, x2) ->
7512                               Ast.ExApp (_loc,
7513                                 Ast.ExApp (_loc,
7514                                   Ast.ExApp (_loc,
7515                                     Ast.ExId (_loc,
7516                                       Ast.IdAcc (_loc,
7517                                         Ast.IdUid (_loc, "Ast"),
7518                                         Ast.IdUid (_loc, "CgSem"))),
7519                                     meta_loc _loc x0),
7520                                   meta_class_sig_item _loc x1),
7521                                 meta_class_sig_item _loc x2)
7522                           | Ast.CgCtr (x0, x1, x2) ->
7523                               Ast.ExApp (_loc,
7524                                 Ast.ExApp (_loc,
7525                                   Ast.ExApp (_loc,
7526                                     Ast.ExId (_loc,
7527                                       Ast.IdAcc (_loc,
7528                                         Ast.IdUid (_loc, "Ast"),
7529                                         Ast.IdUid (_loc, "CgCtr"))),
7530                                     meta_loc _loc x0),
7531                                   meta_ctyp _loc x1),
7532                                 meta_ctyp _loc x2)
7533                           | Ast.CgNil x0 ->
7534                               Ast.ExApp (_loc,
7535                                 Ast.ExId (_loc,
7536                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7537                                     Ast.IdUid (_loc, "CgNil"))),
7538                                 meta_loc _loc x0)
7539                         and meta_class_str_item _loc =
7540                           function
7541                           | Ast.CrAnt (x0, x1) -> Ast.ExAnt (x0, x1)
7542                           | Ast.CrVvr (x0, x1, x2, x3) ->
7543                               Ast.ExApp (_loc,
7544                                 Ast.ExApp (_loc,
7545                                   Ast.ExApp (_loc,
7546                                     Ast.ExApp (_loc,
7547                                       Ast.ExId (_loc,
7548                                         Ast.IdAcc (_loc,
7549                                           Ast.IdUid (_loc, "Ast"),
7550                                           Ast.IdUid (_loc, "CrVvr"))),
7551                                       meta_loc _loc x0),
7552                                     meta_string _loc x1),
7553                                   meta_meta_bool _loc x2),
7554                                 meta_ctyp _loc x3)
7555                           | Ast.CrVir (x0, x1, x2, x3) ->
7556                               Ast.ExApp (_loc,
7557                                 Ast.ExApp (_loc,
7558                                   Ast.ExApp (_loc,
7559                                     Ast.ExApp (_loc,
7560                                       Ast.ExId (_loc,
7561                                         Ast.IdAcc (_loc,
7562                                           Ast.IdUid (_loc, "Ast"),
7563                                           Ast.IdUid (_loc, "CrVir"))),
7564                                       meta_loc _loc x0),
7565                                     meta_string _loc x1),
7566                                   meta_meta_bool _loc x2),
7567                                 meta_ctyp _loc x3)
7568                           | Ast.CrVal (x0, x1, x2, x3) ->
7569                               Ast.ExApp (_loc,
7570                                 Ast.ExApp (_loc,
7571                                   Ast.ExApp (_loc,
7572                                     Ast.ExApp (_loc,
7573                                       Ast.ExId (_loc,
7574                                         Ast.IdAcc (_loc,
7575                                           Ast.IdUid (_loc, "Ast"),
7576                                           Ast.IdUid (_loc, "CrVal"))),
7577                                       meta_loc _loc x0),
7578                                     meta_string _loc x1),
7579                                   meta_meta_bool _loc x2),
7580                                 meta_expr _loc x3)
7581                           | Ast.CrMth (x0, x1, x2, x3, x4) ->
7582                               Ast.ExApp (_loc,
7583                                 Ast.ExApp (_loc,
7584                                   Ast.ExApp (_loc,
7585                                     Ast.ExApp (_loc,
7586                                       Ast.ExApp (_loc,
7587                                         Ast.ExId (_loc,
7588                                           Ast.IdAcc (_loc,
7589                                             Ast.IdUid (_loc, "Ast"),
7590                                             Ast.IdUid (_loc, "CrMth"))),
7591                                         meta_loc _loc x0),
7592                                       meta_string _loc x1),
7593                                     meta_meta_bool _loc x2),
7594                                   meta_expr _loc x3),
7595                                 meta_ctyp _loc x4)
7596                           | Ast.CrIni (x0, x1) ->
7597                               Ast.ExApp (_loc,
7598                                 Ast.ExApp (_loc,
7599                                   Ast.ExId (_loc,
7600                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7601                                       Ast.IdUid (_loc, "CrIni"))),
7602                                   meta_loc _loc x0),
7603                                 meta_expr _loc x1)
7604                           | Ast.CrInh (x0, x1, x2) ->
7605                               Ast.ExApp (_loc,
7606                                 Ast.ExApp (_loc,
7607                                   Ast.ExApp (_loc,
7608                                     Ast.ExId (_loc,
7609                                       Ast.IdAcc (_loc,
7610                                         Ast.IdUid (_loc, "Ast"),
7611                                         Ast.IdUid (_loc, "CrInh"))),
7612                                     meta_loc _loc x0),
7613                                   meta_class_expr _loc x1),
7614                                 meta_string _loc x2)
7615                           | Ast.CrCtr (x0, x1, x2) ->
7616                               Ast.ExApp (_loc,
7617                                 Ast.ExApp (_loc,
7618                                   Ast.ExApp (_loc,
7619                                     Ast.ExId (_loc,
7620                                       Ast.IdAcc (_loc,
7621                                         Ast.IdUid (_loc, "Ast"),
7622                                         Ast.IdUid (_loc, "CrCtr"))),
7623                                     meta_loc _loc x0),
7624                                   meta_ctyp _loc x1),
7625                                 meta_ctyp _loc x2)
7626                           | Ast.CrSem (x0, x1, x2) ->
7627                               Ast.ExApp (_loc,
7628                                 Ast.ExApp (_loc,
7629                                   Ast.ExApp (_loc,
7630                                     Ast.ExId (_loc,
7631                                       Ast.IdAcc (_loc,
7632                                         Ast.IdUid (_loc, "Ast"),
7633                                         Ast.IdUid (_loc, "CrSem"))),
7634                                     meta_loc _loc x0),
7635                                   meta_class_str_item _loc x1),
7636                                 meta_class_str_item _loc x2)
7637                           | Ast.CrNil x0 ->
7638                               Ast.ExApp (_loc,
7639                                 Ast.ExId (_loc,
7640                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7641                                     Ast.IdUid (_loc, "CrNil"))),
7642                                 meta_loc _loc x0)
7643                         and meta_class_type _loc =
7644                           function
7645                           | Ast.CtAnt (x0, x1) -> Ast.ExAnt (x0, x1)
7646                           | Ast.CtEq (x0, x1, x2) ->
7647                               Ast.ExApp (_loc,
7648                                 Ast.ExApp (_loc,
7649                                   Ast.ExApp (_loc,
7650                                     Ast.ExId (_loc,
7651                                       Ast.IdAcc (_loc,
7652                                         Ast.IdUid (_loc, "Ast"),
7653                                         Ast.IdUid (_loc, "CtEq"))),
7654                                     meta_loc _loc x0),
7655                                   meta_class_type _loc x1),
7656                                 meta_class_type _loc x2)
7657                           | Ast.CtCol (x0, x1, x2) ->
7658                               Ast.ExApp (_loc,
7659                                 Ast.ExApp (_loc,
7660                                   Ast.ExApp (_loc,
7661                                     Ast.ExId (_loc,
7662                                       Ast.IdAcc (_loc,
7663                                         Ast.IdUid (_loc, "Ast"),
7664                                         Ast.IdUid (_loc, "CtCol"))),
7665                                     meta_loc _loc x0),
7666                                   meta_class_type _loc x1),
7667                                 meta_class_type _loc x2)
7668                           | Ast.CtAnd (x0, x1, x2) ->
7669                               Ast.ExApp (_loc,
7670                                 Ast.ExApp (_loc,
7671                                   Ast.ExApp (_loc,
7672                                     Ast.ExId (_loc,
7673                                       Ast.IdAcc (_loc,
7674                                         Ast.IdUid (_loc, "Ast"),
7675                                         Ast.IdUid (_loc, "CtAnd"))),
7676                                     meta_loc _loc x0),
7677                                   meta_class_type _loc x1),
7678                                 meta_class_type _loc x2)
7679                           | Ast.CtSig (x0, x1, x2) ->
7680                               Ast.ExApp (_loc,
7681                                 Ast.ExApp (_loc,
7682                                   Ast.ExApp (_loc,
7683                                     Ast.ExId (_loc,
7684                                       Ast.IdAcc (_loc,
7685                                         Ast.IdUid (_loc, "Ast"),
7686                                         Ast.IdUid (_loc, "CtSig"))),
7687                                     meta_loc _loc x0),
7688                                   meta_ctyp _loc x1),
7689                                 meta_class_sig_item _loc x2)
7690                           | Ast.CtFun (x0, x1, x2) ->
7691                               Ast.ExApp (_loc,
7692                                 Ast.ExApp (_loc,
7693                                   Ast.ExApp (_loc,
7694                                     Ast.ExId (_loc,
7695                                       Ast.IdAcc (_loc,
7696                                         Ast.IdUid (_loc, "Ast"),
7697                                         Ast.IdUid (_loc, "CtFun"))),
7698                                     meta_loc _loc x0),
7699                                   meta_ctyp _loc x1),
7700                                 meta_class_type _loc x2)
7701                           | Ast.CtCon (x0, x1, x2, x3) ->
7702                               Ast.ExApp (_loc,
7703                                 Ast.ExApp (_loc,
7704                                   Ast.ExApp (_loc,
7705                                     Ast.ExApp (_loc,
7706                                       Ast.ExId (_loc,
7707                                         Ast.IdAcc (_loc,
7708                                           Ast.IdUid (_loc, "Ast"),
7709                                           Ast.IdUid (_loc, "CtCon"))),
7710                                       meta_loc _loc x0),
7711                                     meta_meta_bool _loc x1),
7712                                   meta_ident _loc x2),
7713                                 meta_ctyp _loc x3)
7714                           | Ast.CtNil x0 ->
7715                               Ast.ExApp (_loc,
7716                                 Ast.ExId (_loc,
7717                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7718                                     Ast.IdUid (_loc, "CtNil"))),
7719                                 meta_loc _loc x0)
7720                         and meta_ctyp _loc =
7721                           function
7722                           | Ast.TyAnt (x0, x1) -> Ast.ExAnt (x0, x1)
7723                           | Ast.TyOfAmp (x0, x1, x2) ->
7724                               Ast.ExApp (_loc,
7725                                 Ast.ExApp (_loc,
7726                                   Ast.ExApp (_loc,
7727                                     Ast.ExId (_loc,
7728                                       Ast.IdAcc (_loc,
7729                                         Ast.IdUid (_loc, "Ast"),
7730                                         Ast.IdUid (_loc, "TyOfAmp"))),
7731                                     meta_loc _loc x0),
7732                                   meta_ctyp _loc x1),
7733                                 meta_ctyp _loc x2)
7734                           | Ast.TyAmp (x0, x1, x2) ->
7735                               Ast.ExApp (_loc,
7736                                 Ast.ExApp (_loc,
7737                                   Ast.ExApp (_loc,
7738                                     Ast.ExId (_loc,
7739                                       Ast.IdAcc (_loc,
7740                                         Ast.IdUid (_loc, "Ast"),
7741                                         Ast.IdUid (_loc, "TyAmp"))),
7742                                     meta_loc _loc x0),
7743                                   meta_ctyp _loc x1),
7744                                 meta_ctyp _loc x2)
7745                           | Ast.TyVrnInfSup (x0, x1, x2) ->
7746                               Ast.ExApp (_loc,
7747                                 Ast.ExApp (_loc,
7748                                   Ast.ExApp (_loc,
7749                                     Ast.ExId (_loc,
7750                                       Ast.IdAcc (_loc,
7751                                         Ast.IdUid (_loc, "Ast"),
7752                                         Ast.IdUid (_loc, "TyVrnInfSup"))),
7753                                     meta_loc _loc x0),
7754                                   meta_ctyp _loc x1),
7755                                 meta_ctyp _loc x2)
7756                           | Ast.TyVrnInf (x0, x1) ->
7757                               Ast.ExApp (_loc,
7758                                 Ast.ExApp (_loc,
7759                                   Ast.ExId (_loc,
7760                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7761                                       Ast.IdUid (_loc, "TyVrnInf"))),
7762                                   meta_loc _loc x0),
7763                                 meta_ctyp _loc x1)
7764                           | Ast.TyVrnSup (x0, x1) ->
7765                               Ast.ExApp (_loc,
7766                                 Ast.ExApp (_loc,
7767                                   Ast.ExId (_loc,
7768                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7769                                       Ast.IdUid (_loc, "TyVrnSup"))),
7770                                   meta_loc _loc x0),
7771                                 meta_ctyp _loc x1)
7772                           | Ast.TyVrnEq (x0, x1) ->
7773                               Ast.ExApp (_loc,
7774                                 Ast.ExApp (_loc,
7775                                   Ast.ExId (_loc,
7776                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7777                                       Ast.IdUid (_loc, "TyVrnEq"))),
7778                                   meta_loc _loc x0),
7779                                 meta_ctyp _loc x1)
7780                           | Ast.TySta (x0, x1, x2) ->
7781                               Ast.ExApp (_loc,
7782                                 Ast.ExApp (_loc,
7783                                   Ast.ExApp (_loc,
7784                                     Ast.ExId (_loc,
7785                                       Ast.IdAcc (_loc,
7786                                         Ast.IdUid (_loc, "Ast"),
7787                                         Ast.IdUid (_loc, "TySta"))),
7788                                     meta_loc _loc x0),
7789                                   meta_ctyp _loc x1),
7790                                 meta_ctyp _loc x2)
7791                           | Ast.TyTup (x0, x1) ->
7792                               Ast.ExApp (_loc,
7793                                 Ast.ExApp (_loc,
7794                                   Ast.ExId (_loc,
7795                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7796                                       Ast.IdUid (_loc, "TyTup"))),
7797                                   meta_loc _loc x0),
7798                                 meta_ctyp _loc x1)
7799                           | Ast.TyMut (x0, x1) ->
7800                               Ast.ExApp (_loc,
7801                                 Ast.ExApp (_loc,
7802                                   Ast.ExId (_loc,
7803                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7804                                       Ast.IdUid (_loc, "TyMut"))),
7805                                   meta_loc _loc x0),
7806                                 meta_ctyp _loc x1)
7807                           | Ast.TyPrv (x0, x1) ->
7808                               Ast.ExApp (_loc,
7809                                 Ast.ExApp (_loc,
7810                                   Ast.ExId (_loc,
7811                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7812                                       Ast.IdUid (_loc, "TyPrv"))),
7813                                   meta_loc _loc x0),
7814                                 meta_ctyp _loc x1)
7815                           | Ast.TyOr (x0, x1, x2) ->
7816                               Ast.ExApp (_loc,
7817                                 Ast.ExApp (_loc,
7818                                   Ast.ExApp (_loc,
7819                                     Ast.ExId (_loc,
7820                                       Ast.IdAcc (_loc,
7821                                         Ast.IdUid (_loc, "Ast"),
7822                                         Ast.IdUid (_loc, "TyOr"))),
7823                                     meta_loc _loc x0),
7824                                   meta_ctyp _loc x1),
7825                                 meta_ctyp _loc x2)
7826                           | Ast.TyAnd (x0, x1, x2) ->
7827                               Ast.ExApp (_loc,
7828                                 Ast.ExApp (_loc,
7829                                   Ast.ExApp (_loc,
7830                                     Ast.ExId (_loc,
7831                                       Ast.IdAcc (_loc,
7832                                         Ast.IdUid (_loc, "Ast"),
7833                                         Ast.IdUid (_loc, "TyAnd"))),
7834                                     meta_loc _loc x0),
7835                                   meta_ctyp _loc x1),
7836                                 meta_ctyp _loc x2)
7837                           | Ast.TyOf (x0, x1, x2) ->
7838                               Ast.ExApp (_loc,
7839                                 Ast.ExApp (_loc,
7840                                   Ast.ExApp (_loc,
7841                                     Ast.ExId (_loc,
7842                                       Ast.IdAcc (_loc,
7843                                         Ast.IdUid (_loc, "Ast"),
7844                                         Ast.IdUid (_loc, "TyOf"))),
7845                                     meta_loc _loc x0),
7846                                   meta_ctyp _loc x1),
7847                                 meta_ctyp _loc x2)
7848                           | Ast.TySum (x0, x1) ->
7849                               Ast.ExApp (_loc,
7850                                 Ast.ExApp (_loc,
7851                                   Ast.ExId (_loc,
7852                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7853                                       Ast.IdUid (_loc, "TySum"))),
7854                                   meta_loc _loc x0),
7855                                 meta_ctyp _loc x1)
7856                           | Ast.TyCom (x0, x1, x2) ->
7857                               Ast.ExApp (_loc,
7858                                 Ast.ExApp (_loc,
7859                                   Ast.ExApp (_loc,
7860                                     Ast.ExId (_loc,
7861                                       Ast.IdAcc (_loc,
7862                                         Ast.IdUid (_loc, "Ast"),
7863                                         Ast.IdUid (_loc, "TyCom"))),
7864                                     meta_loc _loc x0),
7865                                   meta_ctyp _loc x1),
7866                                 meta_ctyp _loc x2)
7867                           | Ast.TySem (x0, x1, x2) ->
7868                               Ast.ExApp (_loc,
7869                                 Ast.ExApp (_loc,
7870                                   Ast.ExApp (_loc,
7871                                     Ast.ExId (_loc,
7872                                       Ast.IdAcc (_loc,
7873                                         Ast.IdUid (_loc, "Ast"),
7874                                         Ast.IdUid (_loc, "TySem"))),
7875                                     meta_loc _loc x0),
7876                                   meta_ctyp _loc x1),
7877                                 meta_ctyp _loc x2)
7878                           | Ast.TyCol (x0, x1, x2) ->
7879                               Ast.ExApp (_loc,
7880                                 Ast.ExApp (_loc,
7881                                   Ast.ExApp (_loc,
7882                                     Ast.ExId (_loc,
7883                                       Ast.IdAcc (_loc,
7884                                         Ast.IdUid (_loc, "Ast"),
7885                                         Ast.IdUid (_loc, "TyCol"))),
7886                                     meta_loc _loc x0),
7887                                   meta_ctyp _loc x1),
7888                                 meta_ctyp _loc x2)
7889                           | Ast.TyRec (x0, x1) ->
7890                               Ast.ExApp (_loc,
7891                                 Ast.ExApp (_loc,
7892                                   Ast.ExId (_loc,
7893                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7894                                       Ast.IdUid (_loc, "TyRec"))),
7895                                   meta_loc _loc x0),
7896                                 meta_ctyp _loc x1)
7897                           | Ast.TyVrn (x0, x1) ->
7898                               Ast.ExApp (_loc,
7899                                 Ast.ExApp (_loc,
7900                                   Ast.ExId (_loc,
7901                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7902                                       Ast.IdUid (_loc, "TyVrn"))),
7903                                   meta_loc _loc x0),
7904                                 meta_string _loc x1)
7905                           | Ast.TyQuM (x0, x1) ->
7906                               Ast.ExApp (_loc,
7907                                 Ast.ExApp (_loc,
7908                                   Ast.ExId (_loc,
7909                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7910                                       Ast.IdUid (_loc, "TyQuM"))),
7911                                   meta_loc _loc x0),
7912                                 meta_string _loc x1)
7913                           | Ast.TyQuP (x0, x1) ->
7914                               Ast.ExApp (_loc,
7915                                 Ast.ExApp (_loc,
7916                                   Ast.ExId (_loc,
7917                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7918                                       Ast.IdUid (_loc, "TyQuP"))),
7919                                   meta_loc _loc x0),
7920                                 meta_string _loc x1)
7921                           | Ast.TyQuo (x0, x1) ->
7922                               Ast.ExApp (_loc,
7923                                 Ast.ExApp (_loc,
7924                                   Ast.ExId (_loc,
7925                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7926                                       Ast.IdUid (_loc, "TyQuo"))),
7927                                   meta_loc _loc x0),
7928                                 meta_string _loc x1)
7929                           | Ast.TyPol (x0, x1, x2) ->
7930                               Ast.ExApp (_loc,
7931                                 Ast.ExApp (_loc,
7932                                   Ast.ExApp (_loc,
7933                                     Ast.ExId (_loc,
7934                                       Ast.IdAcc (_loc,
7935                                         Ast.IdUid (_loc, "Ast"),
7936                                         Ast.IdUid (_loc, "TyPol"))),
7937                                     meta_loc _loc x0),
7938                                   meta_ctyp _loc x1),
7939                                 meta_ctyp _loc x2)
7940                           | Ast.TyOlb (x0, x1, x2) ->
7941                               Ast.ExApp (_loc,
7942                                 Ast.ExApp (_loc,
7943                                   Ast.ExApp (_loc,
7944                                     Ast.ExId (_loc,
7945                                       Ast.IdAcc (_loc,
7946                                         Ast.IdUid (_loc, "Ast"),
7947                                         Ast.IdUid (_loc, "TyOlb"))),
7948                                     meta_loc _loc x0),
7949                                   meta_string _loc x1),
7950                                 meta_ctyp _loc x2)
7951                           | Ast.TyObj (x0, x1, x2) ->
7952                               Ast.ExApp (_loc,
7953                                 Ast.ExApp (_loc,
7954                                   Ast.ExApp (_loc,
7955                                     Ast.ExId (_loc,
7956                                       Ast.IdAcc (_loc,
7957                                         Ast.IdUid (_loc, "Ast"),
7958                                         Ast.IdUid (_loc, "TyObj"))),
7959                                     meta_loc _loc x0),
7960                                   meta_ctyp _loc x1),
7961                                 meta_meta_bool _loc x2)
7962                           | Ast.TyDcl (x0, x1, x2, x3, x4) ->
7963                               Ast.ExApp (_loc,
7964                                 Ast.ExApp (_loc,
7965                                   Ast.ExApp (_loc,
7966                                     Ast.ExApp (_loc,
7967                                       Ast.ExApp (_loc,
7968                                         Ast.ExId (_loc,
7969                                           Ast.IdAcc (_loc,
7970                                             Ast.IdUid (_loc, "Ast"),
7971                                             Ast.IdUid (_loc, "TyDcl"))),
7972                                         meta_loc _loc x0),
7973                                       meta_string _loc x1),
7974                                     meta_list meta_ctyp _loc x2),
7975                                   meta_ctyp _loc x3),
7976                                 meta_list
7977                                   (fun _loc (x1, x2) ->
7978                                      Ast.ExTup (_loc,
7979                                        Ast.ExCom (_loc, meta_ctyp _loc x1,
7980                                          meta_ctyp _loc x2)))
7981                                   _loc x4)
7982                           | Ast.TyMan (x0, x1, x2) ->
7983                               Ast.ExApp (_loc,
7984                                 Ast.ExApp (_loc,
7985                                   Ast.ExApp (_loc,
7986                                     Ast.ExId (_loc,
7987                                       Ast.IdAcc (_loc,
7988                                         Ast.IdUid (_loc, "Ast"),
7989                                         Ast.IdUid (_loc, "TyMan"))),
7990                                     meta_loc _loc x0),
7991                                   meta_ctyp _loc x1),
7992                                 meta_ctyp _loc x2)
7993                           | Ast.TyId (x0, x1) ->
7994                               Ast.ExApp (_loc,
7995                                 Ast.ExApp (_loc,
7996                                   Ast.ExId (_loc,
7997                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
7998                                       Ast.IdUid (_loc, "TyId"))),
7999                                   meta_loc _loc x0),
8000                                 meta_ident _loc x1)
8001                           | Ast.TyLab (x0, x1, x2) ->
8002                               Ast.ExApp (_loc,
8003                                 Ast.ExApp (_loc,
8004                                   Ast.ExApp (_loc,
8005                                     Ast.ExId (_loc,
8006                                       Ast.IdAcc (_loc,
8007                                         Ast.IdUid (_loc, "Ast"),
8008                                         Ast.IdUid (_loc, "TyLab"))),
8009                                     meta_loc _loc x0),
8010                                   meta_string _loc x1),
8011                                 meta_ctyp _loc x2)
8012                           | Ast.TyCls (x0, x1) ->
8013                               Ast.ExApp (_loc,
8014                                 Ast.ExApp (_loc,
8015                                   Ast.ExId (_loc,
8016                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8017                                       Ast.IdUid (_loc, "TyCls"))),
8018                                   meta_loc _loc x0),
8019                                 meta_ident _loc x1)
8020                           | Ast.TyArr (x0, x1, x2) ->
8021                               Ast.ExApp (_loc,
8022                                 Ast.ExApp (_loc,
8023                                   Ast.ExApp (_loc,
8024                                     Ast.ExId (_loc,
8025                                       Ast.IdAcc (_loc,
8026                                         Ast.IdUid (_loc, "Ast"),
8027                                         Ast.IdUid (_loc, "TyArr"))),
8028                                     meta_loc _loc x0),
8029                                   meta_ctyp _loc x1),
8030                                 meta_ctyp _loc x2)
8031                           | Ast.TyApp (x0, x1, x2) ->
8032                               Ast.ExApp (_loc,
8033                                 Ast.ExApp (_loc,
8034                                   Ast.ExApp (_loc,
8035                                     Ast.ExId (_loc,
8036                                       Ast.IdAcc (_loc,
8037                                         Ast.IdUid (_loc, "Ast"),
8038                                         Ast.IdUid (_loc, "TyApp"))),
8039                                     meta_loc _loc x0),
8040                                   meta_ctyp _loc x1),
8041                                 meta_ctyp _loc x2)
8042                           | Ast.TyAny x0 ->
8043                               Ast.ExApp (_loc,
8044                                 Ast.ExId (_loc,
8045                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8046                                     Ast.IdUid (_loc, "TyAny"))),
8047                                 meta_loc _loc x0)
8048                           | Ast.TyAli (x0, x1, x2) ->
8049                               Ast.ExApp (_loc,
8050                                 Ast.ExApp (_loc,
8051                                   Ast.ExApp (_loc,
8052                                     Ast.ExId (_loc,
8053                                       Ast.IdAcc (_loc,
8054                                         Ast.IdUid (_loc, "Ast"),
8055                                         Ast.IdUid (_loc, "TyAli"))),
8056                                     meta_loc _loc x0),
8057                                   meta_ctyp _loc x1),
8058                                 meta_ctyp _loc x2)
8059                           | Ast.TyNil x0 ->
8060                               Ast.ExApp (_loc,
8061                                 Ast.ExId (_loc,
8062                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8063                                     Ast.IdUid (_loc, "TyNil"))),
8064                                 meta_loc _loc x0)
8065                         and meta_expr _loc =
8066                           function
8067                           | Ast.ExWhi (x0, x1, x2) ->
8068                               Ast.ExApp (_loc,
8069                                 Ast.ExApp (_loc,
8070                                   Ast.ExApp (_loc,
8071                                     Ast.ExId (_loc,
8072                                       Ast.IdAcc (_loc,
8073                                         Ast.IdUid (_loc, "Ast"),
8074                                         Ast.IdUid (_loc, "ExWhi"))),
8075                                     meta_loc _loc x0),
8076                                   meta_expr _loc x1),
8077                                 meta_expr _loc x2)
8078                           | Ast.ExVrn (x0, x1) ->
8079                               Ast.ExApp (_loc,
8080                                 Ast.ExApp (_loc,
8081                                   Ast.ExId (_loc,
8082                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8083                                       Ast.IdUid (_loc, "ExVrn"))),
8084                                   meta_loc _loc x0),
8085                                 meta_string _loc x1)
8086                           | Ast.ExTyc (x0, x1, x2) ->
8087                               Ast.ExApp (_loc,
8088                                 Ast.ExApp (_loc,
8089                                   Ast.ExApp (_loc,
8090                                     Ast.ExId (_loc,
8091                                       Ast.IdAcc (_loc,
8092                                         Ast.IdUid (_loc, "Ast"),
8093                                         Ast.IdUid (_loc, "ExTyc"))),
8094                                     meta_loc _loc x0),
8095                                   meta_expr _loc x1),
8096                                 meta_ctyp _loc x2)
8097                           | Ast.ExCom (x0, x1, x2) ->
8098                               Ast.ExApp (_loc,
8099                                 Ast.ExApp (_loc,
8100                                   Ast.ExApp (_loc,
8101                                     Ast.ExId (_loc,
8102                                       Ast.IdAcc (_loc,
8103                                         Ast.IdUid (_loc, "Ast"),
8104                                         Ast.IdUid (_loc, "ExCom"))),
8105                                     meta_loc _loc x0),
8106                                   meta_expr _loc x1),
8107                                 meta_expr _loc x2)
8108                           | Ast.ExTup (x0, x1) ->
8109                               Ast.ExApp (_loc,
8110                                 Ast.ExApp (_loc,
8111                                   Ast.ExId (_loc,
8112                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8113                                       Ast.IdUid (_loc, "ExTup"))),
8114                                   meta_loc _loc x0),
8115                                 meta_expr _loc x1)
8116                           | Ast.ExTry (x0, x1, x2) ->
8117                               Ast.ExApp (_loc,
8118                                 Ast.ExApp (_loc,
8119                                   Ast.ExApp (_loc,
8120                                     Ast.ExId (_loc,
8121                                       Ast.IdAcc (_loc,
8122                                         Ast.IdUid (_loc, "Ast"),
8123                                         Ast.IdUid (_loc, "ExTry"))),
8124                                     meta_loc _loc x0),
8125                                   meta_expr _loc x1),
8126                                 meta_match_case _loc x2)
8127                           | Ast.ExStr (x0, x1) ->
8128                               Ast.ExApp (_loc,
8129                                 Ast.ExApp (_loc,
8130                                   Ast.ExId (_loc,
8131                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8132                                       Ast.IdUid (_loc, "ExStr"))),
8133                                   meta_loc _loc x0),
8134                                 meta_string _loc x1)
8135                           | Ast.ExSte (x0, x1, x2) ->
8136                               Ast.ExApp (_loc,
8137                                 Ast.ExApp (_loc,
8138                                   Ast.ExApp (_loc,
8139                                     Ast.ExId (_loc,
8140                                       Ast.IdAcc (_loc,
8141                                         Ast.IdUid (_loc, "Ast"),
8142                                         Ast.IdUid (_loc, "ExSte"))),
8143                                     meta_loc _loc x0),
8144                                   meta_expr _loc x1),
8145                                 meta_expr _loc x2)
8146                           | Ast.ExSnd (x0, x1, x2) ->
8147                               Ast.ExApp (_loc,
8148                                 Ast.ExApp (_loc,
8149                                   Ast.ExApp (_loc,
8150                                     Ast.ExId (_loc,
8151                                       Ast.IdAcc (_loc,
8152                                         Ast.IdUid (_loc, "Ast"),
8153                                         Ast.IdUid (_loc, "ExSnd"))),
8154                                     meta_loc _loc x0),
8155                                   meta_expr _loc x1),
8156                                 meta_string _loc x2)
8157                           | Ast.ExSeq (x0, x1) ->
8158                               Ast.ExApp (_loc,
8159                                 Ast.ExApp (_loc,
8160                                   Ast.ExId (_loc,
8161                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8162                                       Ast.IdUid (_loc, "ExSeq"))),
8163                                   meta_loc _loc x0),
8164                                 meta_expr _loc x1)
8165                           | Ast.ExRec (x0, x1, x2) ->
8166                               Ast.ExApp (_loc,
8167                                 Ast.ExApp (_loc,
8168                                   Ast.ExApp (_loc,
8169                                     Ast.ExId (_loc,
8170                                       Ast.IdAcc (_loc,
8171                                         Ast.IdUid (_loc, "Ast"),
8172                                         Ast.IdUid (_loc, "ExRec"))),
8173                                     meta_loc _loc x0),
8174                                   meta_rec_binding _loc x1),
8175                                 meta_expr _loc x2)
8176                           | Ast.ExOvr (x0, x1) ->
8177                               Ast.ExApp (_loc,
8178                                 Ast.ExApp (_loc,
8179                                   Ast.ExId (_loc,
8180                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8181                                       Ast.IdUid (_loc, "ExOvr"))),
8182                                   meta_loc _loc x0),
8183                                 meta_rec_binding _loc x1)
8184                           | Ast.ExOlb (x0, x1, x2) ->
8185                               Ast.ExApp (_loc,
8186                                 Ast.ExApp (_loc,
8187                                   Ast.ExApp (_loc,
8188                                     Ast.ExId (_loc,
8189                                       Ast.IdAcc (_loc,
8190                                         Ast.IdUid (_loc, "Ast"),
8191                                         Ast.IdUid (_loc, "ExOlb"))),
8192                                     meta_loc _loc x0),
8193                                   meta_string _loc x1),
8194                                 meta_expr _loc x2)
8195                           | Ast.ExObj (x0, x1, x2) ->
8196                               Ast.ExApp (_loc,
8197                                 Ast.ExApp (_loc,
8198                                   Ast.ExApp (_loc,
8199                                     Ast.ExId (_loc,
8200                                       Ast.IdAcc (_loc,
8201                                         Ast.IdUid (_loc, "Ast"),
8202                                         Ast.IdUid (_loc, "ExObj"))),
8203                                     meta_loc _loc x0),
8204                                   meta_patt _loc x1),
8205                                 meta_class_str_item _loc x2)
8206                           | Ast.ExNew (x0, x1) ->
8207                               Ast.ExApp (_loc,
8208                                 Ast.ExApp (_loc,
8209                                   Ast.ExId (_loc,
8210                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8211                                       Ast.IdUid (_loc, "ExNew"))),
8212                                   meta_loc _loc x0),
8213                                 meta_ident _loc x1)
8214                           | Ast.ExMat (x0, x1, x2) ->
8215                               Ast.ExApp (_loc,
8216                                 Ast.ExApp (_loc,
8217                                   Ast.ExApp (_loc,
8218                                     Ast.ExId (_loc,
8219                                       Ast.IdAcc (_loc,
8220                                         Ast.IdUid (_loc, "Ast"),
8221                                         Ast.IdUid (_loc, "ExMat"))),
8222                                     meta_loc _loc x0),
8223                                   meta_expr _loc x1),
8224                                 meta_match_case _loc x2)
8225                           | Ast.ExLmd (x0, x1, x2, x3) ->
8226                               Ast.ExApp (_loc,
8227                                 Ast.ExApp (_loc,
8228                                   Ast.ExApp (_loc,
8229                                     Ast.ExApp (_loc,
8230                                       Ast.ExId (_loc,
8231                                         Ast.IdAcc (_loc,
8232                                           Ast.IdUid (_loc, "Ast"),
8233                                           Ast.IdUid (_loc, "ExLmd"))),
8234                                       meta_loc _loc x0),
8235                                     meta_string _loc x1),
8236                                   meta_module_expr _loc x2),
8237                                 meta_expr _loc x3)
8238                           | Ast.ExLet (x0, x1, x2, x3) ->
8239                               Ast.ExApp (_loc,
8240                                 Ast.ExApp (_loc,
8241                                   Ast.ExApp (_loc,
8242                                     Ast.ExApp (_loc,
8243                                       Ast.ExId (_loc,
8244                                         Ast.IdAcc (_loc,
8245                                           Ast.IdUid (_loc, "Ast"),
8246                                           Ast.IdUid (_loc, "ExLet"))),
8247                                       meta_loc _loc x0),
8248                                     meta_meta_bool _loc x1),
8249                                   meta_binding _loc x2),
8250                                 meta_expr _loc x3)
8251                           | Ast.ExLaz (x0, x1) ->
8252                               Ast.ExApp (_loc,
8253                                 Ast.ExApp (_loc,
8254                                   Ast.ExId (_loc,
8255                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8256                                       Ast.IdUid (_loc, "ExLaz"))),
8257                                   meta_loc _loc x0),
8258                                 meta_expr _loc x1)
8259                           | Ast.ExLab (x0, x1, x2) ->
8260                               Ast.ExApp (_loc,
8261                                 Ast.ExApp (_loc,
8262                                   Ast.ExApp (_loc,
8263                                     Ast.ExId (_loc,
8264                                       Ast.IdAcc (_loc,
8265                                         Ast.IdUid (_loc, "Ast"),
8266                                         Ast.IdUid (_loc, "ExLab"))),
8267                                     meta_loc _loc x0),
8268                                   meta_string _loc x1),
8269                                 meta_expr _loc x2)
8270                           | Ast.ExNativeInt (x0, x1) ->
8271                               Ast.ExApp (_loc,
8272                                 Ast.ExApp (_loc,
8273                                   Ast.ExId (_loc,
8274                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8275                                       Ast.IdUid (_loc, "ExNativeInt"))),
8276                                   meta_loc _loc x0),
8277                                 meta_string _loc x1)
8278                           | Ast.ExInt64 (x0, x1) ->
8279                               Ast.ExApp (_loc,
8280                                 Ast.ExApp (_loc,
8281                                   Ast.ExId (_loc,
8282                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8283                                       Ast.IdUid (_loc, "ExInt64"))),
8284                                   meta_loc _loc x0),
8285                                 meta_string _loc x1)
8286                           | Ast.ExInt32 (x0, x1) ->
8287                               Ast.ExApp (_loc,
8288                                 Ast.ExApp (_loc,
8289                                   Ast.ExId (_loc,
8290                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8291                                       Ast.IdUid (_loc, "ExInt32"))),
8292                                   meta_loc _loc x0),
8293                                 meta_string _loc x1)
8294                           | Ast.ExInt (x0, x1) ->
8295                               Ast.ExApp (_loc,
8296                                 Ast.ExApp (_loc,
8297                                   Ast.ExId (_loc,
8298                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8299                                       Ast.IdUid (_loc, "ExInt"))),
8300                                   meta_loc _loc x0),
8301                                 meta_string _loc x1)
8302                           | Ast.ExIfe (x0, x1, x2, x3) ->
8303                               Ast.ExApp (_loc,
8304                                 Ast.ExApp (_loc,
8305                                   Ast.ExApp (_loc,
8306                                     Ast.ExApp (_loc,
8307                                       Ast.ExId (_loc,
8308                                         Ast.IdAcc (_loc,
8309                                           Ast.IdUid (_loc, "Ast"),
8310                                           Ast.IdUid (_loc, "ExIfe"))),
8311                                       meta_loc _loc x0),
8312                                     meta_expr _loc x1),
8313                                   meta_expr _loc x2),
8314                                 meta_expr _loc x3)
8315                           | Ast.ExFun (x0, x1) ->
8316                               Ast.ExApp (_loc,
8317                                 Ast.ExApp (_loc,
8318                                   Ast.ExId (_loc,
8319                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8320                                       Ast.IdUid (_loc, "ExFun"))),
8321                                   meta_loc _loc x0),
8322                                 meta_match_case _loc x1)
8323                           | Ast.ExFor (x0, x1, x2, x3, x4, x5) ->
8324                               Ast.ExApp (_loc,
8325                                 Ast.ExApp (_loc,
8326                                   Ast.ExApp (_loc,
8327                                     Ast.ExApp (_loc,
8328                                       Ast.ExApp (_loc,
8329                                         Ast.ExApp (_loc,
8330                                           Ast.ExId (_loc,
8331                                             Ast.IdAcc (_loc,
8332                                               Ast.IdUid (_loc, "Ast"),
8333                                               Ast.IdUid (_loc, "ExFor"))),
8334                                           meta_loc _loc x0),
8335                                         meta_string _loc x1),
8336                                       meta_expr _loc x2),
8337                                     meta_expr _loc x3),
8338                                   meta_meta_bool _loc x4),
8339                                 meta_expr _loc x5)
8340                           | Ast.ExFlo (x0, x1) ->
8341                               Ast.ExApp (_loc,
8342                                 Ast.ExApp (_loc,
8343                                   Ast.ExId (_loc,
8344                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8345                                       Ast.IdUid (_loc, "ExFlo"))),
8346                                   meta_loc _loc x0),
8347                                 meta_string _loc x1)
8348                           | Ast.ExCoe (x0, x1, x2, x3) ->
8349                               Ast.ExApp (_loc,
8350                                 Ast.ExApp (_loc,
8351                                   Ast.ExApp (_loc,
8352                                     Ast.ExApp (_loc,
8353                                       Ast.ExId (_loc,
8354                                         Ast.IdAcc (_loc,
8355                                           Ast.IdUid (_loc, "Ast"),
8356                                           Ast.IdUid (_loc, "ExCoe"))),
8357                                       meta_loc _loc x0),
8358                                     meta_expr _loc x1),
8359                                   meta_ctyp _loc x2),
8360                                 meta_ctyp _loc x3)
8361                           | Ast.ExChr (x0, x1) ->
8362                               Ast.ExApp (_loc,
8363                                 Ast.ExApp (_loc,
8364                                   Ast.ExId (_loc,
8365                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8366                                       Ast.IdUid (_loc, "ExChr"))),
8367                                   meta_loc _loc x0),
8368                                 meta_string _loc x1)
8369                           | Ast.ExAss (x0, x1, x2) ->
8370                               Ast.ExApp (_loc,
8371                                 Ast.ExApp (_loc,
8372                                   Ast.ExApp (_loc,
8373                                     Ast.ExId (_loc,
8374                                       Ast.IdAcc (_loc,
8375                                         Ast.IdUid (_loc, "Ast"),
8376                                         Ast.IdUid (_loc, "ExAss"))),
8377                                     meta_loc _loc x0),
8378                                   meta_expr _loc x1),
8379                                 meta_expr _loc x2)
8380                           | Ast.ExAsr (x0, x1) ->
8381                               Ast.ExApp (_loc,
8382                                 Ast.ExApp (_loc,
8383                                   Ast.ExId (_loc,
8384                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8385                                       Ast.IdUid (_loc, "ExAsr"))),
8386                                   meta_loc _loc x0),
8387                                 meta_expr _loc x1)
8388                           | Ast.ExAsf x0 ->
8389                               Ast.ExApp (_loc,
8390                                 Ast.ExId (_loc,
8391                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8392                                     Ast.IdUid (_loc, "ExAsf"))),
8393                                 meta_loc _loc x0)
8394                           | Ast.ExSem (x0, x1, x2) ->
8395                               Ast.ExApp (_loc,
8396                                 Ast.ExApp (_loc,
8397                                   Ast.ExApp (_loc,
8398                                     Ast.ExId (_loc,
8399                                       Ast.IdAcc (_loc,
8400                                         Ast.IdUid (_loc, "Ast"),
8401                                         Ast.IdUid (_loc, "ExSem"))),
8402                                     meta_loc _loc x0),
8403                                   meta_expr _loc x1),
8404                                 meta_expr _loc x2)
8405                           | Ast.ExArr (x0, x1) ->
8406                               Ast.ExApp (_loc,
8407                                 Ast.ExApp (_loc,
8408                                   Ast.ExId (_loc,
8409                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8410                                       Ast.IdUid (_loc, "ExArr"))),
8411                                   meta_loc _loc x0),
8412                                 meta_expr _loc x1)
8413                           | Ast.ExAre (x0, x1, x2) ->
8414                               Ast.ExApp (_loc,
8415                                 Ast.ExApp (_loc,
8416                                   Ast.ExApp (_loc,
8417                                     Ast.ExId (_loc,
8418                                       Ast.IdAcc (_loc,
8419                                         Ast.IdUid (_loc, "Ast"),
8420                                         Ast.IdUid (_loc, "ExAre"))),
8421                                     meta_loc _loc x0),
8422                                   meta_expr _loc x1),
8423                                 meta_expr _loc x2)
8424                           | Ast.ExApp (x0, x1, x2) ->
8425                               Ast.ExApp (_loc,
8426                                 Ast.ExApp (_loc,
8427                                   Ast.ExApp (_loc,
8428                                     Ast.ExId (_loc,
8429                                       Ast.IdAcc (_loc,
8430                                         Ast.IdUid (_loc, "Ast"),
8431                                         Ast.IdUid (_loc, "ExApp"))),
8432                                     meta_loc _loc x0),
8433                                   meta_expr _loc x1),
8434                                 meta_expr _loc x2)
8435                           | Ast.ExAnt (x0, x1) -> Ast.ExAnt (x0, x1)
8436                           | Ast.ExAcc (x0, x1, x2) ->
8437                               Ast.ExApp (_loc,
8438                                 Ast.ExApp (_loc,
8439                                   Ast.ExApp (_loc,
8440                                     Ast.ExId (_loc,
8441                                       Ast.IdAcc (_loc,
8442                                         Ast.IdUid (_loc, "Ast"),
8443                                         Ast.IdUid (_loc, "ExAcc"))),
8444                                     meta_loc _loc x0),
8445                                   meta_expr _loc x1),
8446                                 meta_expr _loc x2)
8447                           | Ast.ExId (x0, x1) ->
8448                               Ast.ExApp (_loc,
8449                                 Ast.ExApp (_loc,
8450                                   Ast.ExId (_loc,
8451                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8452                                       Ast.IdUid (_loc, "ExId"))),
8453                                   meta_loc _loc x0),
8454                                 meta_ident _loc x1)
8455                           | Ast.ExNil x0 ->
8456                               Ast.ExApp (_loc,
8457                                 Ast.ExId (_loc,
8458                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8459                                     Ast.IdUid (_loc, "ExNil"))),
8460                                 meta_loc _loc x0)
8461                         and meta_ident _loc =
8462                           function
8463                           | Ast.IdAnt (x0, x1) -> Ast.ExAnt (x0, x1)
8464                           | Ast.IdUid (x0, x1) ->
8465                               Ast.ExApp (_loc,
8466                                 Ast.ExApp (_loc,
8467                                   Ast.ExId (_loc,
8468                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8469                                       Ast.IdUid (_loc, "IdUid"))),
8470                                   meta_loc _loc x0),
8471                                 meta_string _loc x1)
8472                           | Ast.IdLid (x0, x1) ->
8473                               Ast.ExApp (_loc,
8474                                 Ast.ExApp (_loc,
8475                                   Ast.ExId (_loc,
8476                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8477                                       Ast.IdUid (_loc, "IdLid"))),
8478                                   meta_loc _loc x0),
8479                                 meta_string _loc x1)
8480                           | Ast.IdApp (x0, x1, x2) ->
8481                               Ast.ExApp (_loc,
8482                                 Ast.ExApp (_loc,
8483                                   Ast.ExApp (_loc,
8484                                     Ast.ExId (_loc,
8485                                       Ast.IdAcc (_loc,
8486                                         Ast.IdUid (_loc, "Ast"),
8487                                         Ast.IdUid (_loc, "IdApp"))),
8488                                     meta_loc _loc x0),
8489                                   meta_ident _loc x1),
8490                                 meta_ident _loc x2)
8491                           | Ast.IdAcc (x0, x1, x2) ->
8492                               Ast.ExApp (_loc,
8493                                 Ast.ExApp (_loc,
8494                                   Ast.ExApp (_loc,
8495                                     Ast.ExId (_loc,
8496                                       Ast.IdAcc (_loc,
8497                                         Ast.IdUid (_loc, "Ast"),
8498                                         Ast.IdUid (_loc, "IdAcc"))),
8499                                     meta_loc _loc x0),
8500                                   meta_ident _loc x1),
8501                                 meta_ident _loc x2)
8502                         and meta_match_case _loc =
8503                           function
8504                           | Ast.McAnt (x0, x1) -> Ast.ExAnt (x0, x1)
8505                           | Ast.McArr (x0, x1, x2, x3) ->
8506                               Ast.ExApp (_loc,
8507                                 Ast.ExApp (_loc,
8508                                   Ast.ExApp (_loc,
8509                                     Ast.ExApp (_loc,
8510                                       Ast.ExId (_loc,
8511                                         Ast.IdAcc (_loc,
8512                                           Ast.IdUid (_loc, "Ast"),
8513                                           Ast.IdUid (_loc, "McArr"))),
8514                                       meta_loc _loc x0),
8515                                     meta_patt _loc x1),
8516                                   meta_expr _loc x2),
8517                                 meta_expr _loc x3)
8518                           | Ast.McOr (x0, x1, x2) ->
8519                               Ast.ExApp (_loc,
8520                                 Ast.ExApp (_loc,
8521                                   Ast.ExApp (_loc,
8522                                     Ast.ExId (_loc,
8523                                       Ast.IdAcc (_loc,
8524                                         Ast.IdUid (_loc, "Ast"),
8525                                         Ast.IdUid (_loc, "McOr"))),
8526                                     meta_loc _loc x0),
8527                                   meta_match_case _loc x1),
8528                                 meta_match_case _loc x2)
8529                           | Ast.McNil x0 ->
8530                               Ast.ExApp (_loc,
8531                                 Ast.ExId (_loc,
8532                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8533                                     Ast.IdUid (_loc, "McNil"))),
8534                                 meta_loc _loc x0)
8535                         and meta_meta_bool _loc =
8536                           function
8537                           | Ast.BAnt x0 -> Ast.ExAnt (_loc, x0)
8538                           | Ast.BFalse ->
8539                               Ast.ExId (_loc,
8540                                 Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8541                                   Ast.IdUid (_loc, "BFalse")))
8542                           | Ast.BTrue ->
8543                               Ast.ExId (_loc,
8544                                 Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8545                                   Ast.IdUid (_loc, "BTrue")))
8546                         and meta_meta_list mf_a _loc =
8547                           function
8548                           | Ast.LAnt x0 -> Ast.ExAnt (_loc, x0)
8549                           | Ast.LCons (x0, x1) ->
8550                               Ast.ExApp (_loc,
8551                                 Ast.ExApp (_loc,
8552                                   Ast.ExId (_loc,
8553                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8554                                       Ast.IdUid (_loc, "LCons"))),
8555                                   mf_a _loc x0),
8556                                 meta_meta_list mf_a _loc x1)
8557                           | Ast.LNil ->
8558                               Ast.ExId (_loc,
8559                                 Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8560                                   Ast.IdUid (_loc, "LNil")))
8561                         and meta_meta_option mf_a _loc =
8562                           function
8563                           | Ast.OAnt x0 -> Ast.ExAnt (_loc, x0)
8564                           | Ast.OSome x0 ->
8565                               Ast.ExApp (_loc,
8566                                 Ast.ExId (_loc,
8567                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8568                                     Ast.IdUid (_loc, "OSome"))),
8569                                 mf_a _loc x0)
8570                           | Ast.ONone ->
8571                               Ast.ExId (_loc,
8572                                 Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8573                                   Ast.IdUid (_loc, "ONone")))
8574                         and meta_module_binding _loc =
8575                           function
8576                           | Ast.MbAnt (x0, x1) -> Ast.ExAnt (x0, x1)
8577                           | Ast.MbCol (x0, x1, x2) ->
8578                               Ast.ExApp (_loc,
8579                                 Ast.ExApp (_loc,
8580                                   Ast.ExApp (_loc,
8581                                     Ast.ExId (_loc,
8582                                       Ast.IdAcc (_loc,
8583                                         Ast.IdUid (_loc, "Ast"),
8584                                         Ast.IdUid (_loc, "MbCol"))),
8585                                     meta_loc _loc x0),
8586                                   meta_string _loc x1),
8587                                 meta_module_type _loc x2)
8588                           | Ast.MbColEq (x0, x1, x2, x3) ->
8589                               Ast.ExApp (_loc,
8590                                 Ast.ExApp (_loc,
8591                                   Ast.ExApp (_loc,
8592                                     Ast.ExApp (_loc,
8593                                       Ast.ExId (_loc,
8594                                         Ast.IdAcc (_loc,
8595                                           Ast.IdUid (_loc, "Ast"),
8596                                           Ast.IdUid (_loc, "MbColEq"))),
8597                                       meta_loc _loc x0),
8598                                     meta_string _loc x1),
8599                                   meta_module_type _loc x2),
8600                                 meta_module_expr _loc x3)
8601                           | Ast.MbAnd (x0, x1, x2) ->
8602                               Ast.ExApp (_loc,
8603                                 Ast.ExApp (_loc,
8604                                   Ast.ExApp (_loc,
8605                                     Ast.ExId (_loc,
8606                                       Ast.IdAcc (_loc,
8607                                         Ast.IdUid (_loc, "Ast"),
8608                                         Ast.IdUid (_loc, "MbAnd"))),
8609                                     meta_loc _loc x0),
8610                                   meta_module_binding _loc x1),
8611                                 meta_module_binding _loc x2)
8612                           | Ast.MbNil x0 ->
8613                               Ast.ExApp (_loc,
8614                                 Ast.ExId (_loc,
8615                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8616                                     Ast.IdUid (_loc, "MbNil"))),
8617                                 meta_loc _loc x0)
8618                         and meta_module_expr _loc =
8619                           function
8620                           | Ast.MeAnt (x0, x1) -> Ast.ExAnt (x0, x1)
8621                           | Ast.MeTyc (x0, x1, x2) ->
8622                               Ast.ExApp (_loc,
8623                                 Ast.ExApp (_loc,
8624                                   Ast.ExApp (_loc,
8625                                     Ast.ExId (_loc,
8626                                       Ast.IdAcc (_loc,
8627                                         Ast.IdUid (_loc, "Ast"),
8628                                         Ast.IdUid (_loc, "MeTyc"))),
8629                                     meta_loc _loc x0),
8630                                   meta_module_expr _loc x1),
8631                                 meta_module_type _loc x2)
8632                           | Ast.MeStr (x0, x1) ->
8633                               Ast.ExApp (_loc,
8634                                 Ast.ExApp (_loc,
8635                                   Ast.ExId (_loc,
8636                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8637                                       Ast.IdUid (_loc, "MeStr"))),
8638                                   meta_loc _loc x0),
8639                                 meta_str_item _loc x1)
8640                           | Ast.MeFun (x0, x1, x2, x3) ->
8641                               Ast.ExApp (_loc,
8642                                 Ast.ExApp (_loc,
8643                                   Ast.ExApp (_loc,
8644                                     Ast.ExApp (_loc,
8645                                       Ast.ExId (_loc,
8646                                         Ast.IdAcc (_loc,
8647                                           Ast.IdUid (_loc, "Ast"),
8648                                           Ast.IdUid (_loc, "MeFun"))),
8649                                       meta_loc _loc x0),
8650                                     meta_string _loc x1),
8651                                   meta_module_type _loc x2),
8652                                 meta_module_expr _loc x3)
8653                           | Ast.MeApp (x0, x1, x2) ->
8654                               Ast.ExApp (_loc,
8655                                 Ast.ExApp (_loc,
8656                                   Ast.ExApp (_loc,
8657                                     Ast.ExId (_loc,
8658                                       Ast.IdAcc (_loc,
8659                                         Ast.IdUid (_loc, "Ast"),
8660                                         Ast.IdUid (_loc, "MeApp"))),
8661                                     meta_loc _loc x0),
8662                                   meta_module_expr _loc x1),
8663                                 meta_module_expr _loc x2)
8664                           | Ast.MeId (x0, x1) ->
8665                               Ast.ExApp (_loc,
8666                                 Ast.ExApp (_loc,
8667                                   Ast.ExId (_loc,
8668                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8669                                       Ast.IdUid (_loc, "MeId"))),
8670                                   meta_loc _loc x0),
8671                                 meta_ident _loc x1)
8672                           | Ast.MeNil x0 ->
8673                               Ast.ExApp (_loc,
8674                                 Ast.ExId (_loc,
8675                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8676                                     Ast.IdUid (_loc, "MeNil"))),
8677                                 meta_loc _loc x0)
8678                         and meta_module_type _loc =
8679                           function
8680                           | Ast.MtAnt (x0, x1) -> Ast.ExAnt (x0, x1)
8681                           | Ast.MtWit (x0, x1, x2) ->
8682                               Ast.ExApp (_loc,
8683                                 Ast.ExApp (_loc,
8684                                   Ast.ExApp (_loc,
8685                                     Ast.ExId (_loc,
8686                                       Ast.IdAcc (_loc,
8687                                         Ast.IdUid (_loc, "Ast"),
8688                                         Ast.IdUid (_loc, "MtWit"))),
8689                                     meta_loc _loc x0),
8690                                   meta_module_type _loc x1),
8691                                 meta_with_constr _loc x2)
8692                           | Ast.MtSig (x0, x1) ->
8693                               Ast.ExApp (_loc,
8694                                 Ast.ExApp (_loc,
8695                                   Ast.ExId (_loc,
8696                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8697                                       Ast.IdUid (_loc, "MtSig"))),
8698                                   meta_loc _loc x0),
8699                                 meta_sig_item _loc x1)
8700                           | Ast.MtQuo (x0, x1) ->
8701                               Ast.ExApp (_loc,
8702                                 Ast.ExApp (_loc,
8703                                   Ast.ExId (_loc,
8704                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8705                                       Ast.IdUid (_loc, "MtQuo"))),
8706                                   meta_loc _loc x0),
8707                                 meta_string _loc x1)
8708                           | Ast.MtFun (x0, x1, x2, x3) ->
8709                               Ast.ExApp (_loc,
8710                                 Ast.ExApp (_loc,
8711                                   Ast.ExApp (_loc,
8712                                     Ast.ExApp (_loc,
8713                                       Ast.ExId (_loc,
8714                                         Ast.IdAcc (_loc,
8715                                           Ast.IdUid (_loc, "Ast"),
8716                                           Ast.IdUid (_loc, "MtFun"))),
8717                                       meta_loc _loc x0),
8718                                     meta_string _loc x1),
8719                                   meta_module_type _loc x2),
8720                                 meta_module_type _loc x3)
8721                           | Ast.MtId (x0, x1) ->
8722                               Ast.ExApp (_loc,
8723                                 Ast.ExApp (_loc,
8724                                   Ast.ExId (_loc,
8725                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8726                                       Ast.IdUid (_loc, "MtId"))),
8727                                   meta_loc _loc x0),
8728                                 meta_ident _loc x1)
8729                           | Ast.MtNil x0 ->
8730                               Ast.ExApp (_loc,
8731                                 Ast.ExId (_loc,
8732                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8733                                     Ast.IdUid (_loc, "MtNil"))),
8734                                 meta_loc _loc x0)
8735                         and meta_patt _loc =
8736                           function
8737                           | Ast.PaLaz (x0, x1) ->
8738                               Ast.ExApp (_loc,
8739                                 Ast.ExApp (_loc,
8740                                   Ast.ExId (_loc,
8741                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8742                                       Ast.IdUid (_loc, "PaLaz"))),
8743                                   meta_loc _loc x0),
8744                                 meta_patt _loc x1)
8745                           | Ast.PaVrn (x0, x1) ->
8746                               Ast.ExApp (_loc,
8747                                 Ast.ExApp (_loc,
8748                                   Ast.ExId (_loc,
8749                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8750                                       Ast.IdUid (_loc, "PaVrn"))),
8751                                   meta_loc _loc x0),
8752                                 meta_string _loc x1)
8753                           | Ast.PaTyp (x0, x1) ->
8754                               Ast.ExApp (_loc,
8755                                 Ast.ExApp (_loc,
8756                                   Ast.ExId (_loc,
8757                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8758                                       Ast.IdUid (_loc, "PaTyp"))),
8759                                   meta_loc _loc x0),
8760                                 meta_ident _loc x1)
8761                           | Ast.PaTyc (x0, x1, x2) ->
8762                               Ast.ExApp (_loc,
8763                                 Ast.ExApp (_loc,
8764                                   Ast.ExApp (_loc,
8765                                     Ast.ExId (_loc,
8766                                       Ast.IdAcc (_loc,
8767                                         Ast.IdUid (_loc, "Ast"),
8768                                         Ast.IdUid (_loc, "PaTyc"))),
8769                                     meta_loc _loc x0),
8770                                   meta_patt _loc x1),
8771                                 meta_ctyp _loc x2)
8772                           | Ast.PaTup (x0, x1) ->
8773                               Ast.ExApp (_loc,
8774                                 Ast.ExApp (_loc,
8775                                   Ast.ExId (_loc,
8776                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8777                                       Ast.IdUid (_loc, "PaTup"))),
8778                                   meta_loc _loc x0),
8779                                 meta_patt _loc x1)
8780                           | Ast.PaStr (x0, x1) ->
8781                               Ast.ExApp (_loc,
8782                                 Ast.ExApp (_loc,
8783                                   Ast.ExId (_loc,
8784                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8785                                       Ast.IdUid (_loc, "PaStr"))),
8786                                   meta_loc _loc x0),
8787                                 meta_string _loc x1)
8788                           | Ast.PaEq (x0, x1, x2) ->
8789                               Ast.ExApp (_loc,
8790                                 Ast.ExApp (_loc,
8791                                   Ast.ExApp (_loc,
8792                                     Ast.ExId (_loc,
8793                                       Ast.IdAcc (_loc,
8794                                         Ast.IdUid (_loc, "Ast"),
8795                                         Ast.IdUid (_loc, "PaEq"))),
8796                                     meta_loc _loc x0),
8797                                   meta_ident _loc x1),
8798                                 meta_patt _loc x2)
8799                           | Ast.PaRec (x0, x1) ->
8800                               Ast.ExApp (_loc,
8801                                 Ast.ExApp (_loc,
8802                                   Ast.ExId (_loc,
8803                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8804                                       Ast.IdUid (_loc, "PaRec"))),
8805                                   meta_loc _loc x0),
8806                                 meta_patt _loc x1)
8807                           | Ast.PaRng (x0, x1, x2) ->
8808                               Ast.ExApp (_loc,
8809                                 Ast.ExApp (_loc,
8810                                   Ast.ExApp (_loc,
8811                                     Ast.ExId (_loc,
8812                                       Ast.IdAcc (_loc,
8813                                         Ast.IdUid (_loc, "Ast"),
8814                                         Ast.IdUid (_loc, "PaRng"))),
8815                                     meta_loc _loc x0),
8816                                   meta_patt _loc x1),
8817                                 meta_patt _loc x2)
8818                           | Ast.PaOrp (x0, x1, x2) ->
8819                               Ast.ExApp (_loc,
8820                                 Ast.ExApp (_loc,
8821                                   Ast.ExApp (_loc,
8822                                     Ast.ExId (_loc,
8823                                       Ast.IdAcc (_loc,
8824                                         Ast.IdUid (_loc, "Ast"),
8825                                         Ast.IdUid (_loc, "PaOrp"))),
8826                                     meta_loc _loc x0),
8827                                   meta_patt _loc x1),
8828                                 meta_patt _loc x2)
8829                           | Ast.PaOlbi (x0, x1, x2, x3) ->
8830                               Ast.ExApp (_loc,
8831                                 Ast.ExApp (_loc,
8832                                   Ast.ExApp (_loc,
8833                                     Ast.ExApp (_loc,
8834                                       Ast.ExId (_loc,
8835                                         Ast.IdAcc (_loc,
8836                                           Ast.IdUid (_loc, "Ast"),
8837                                           Ast.IdUid (_loc, "PaOlbi"))),
8838                                       meta_loc _loc x0),
8839                                     meta_string _loc x1),
8840                                   meta_patt _loc x2),
8841                                 meta_expr _loc x3)
8842                           | Ast.PaOlb (x0, x1, x2) ->
8843                               Ast.ExApp (_loc,
8844                                 Ast.ExApp (_loc,
8845                                   Ast.ExApp (_loc,
8846                                     Ast.ExId (_loc,
8847                                       Ast.IdAcc (_loc,
8848                                         Ast.IdUid (_loc, "Ast"),
8849                                         Ast.IdUid (_loc, "PaOlb"))),
8850                                     meta_loc _loc x0),
8851                                   meta_string _loc x1),
8852                                 meta_patt _loc x2)
8853                           | Ast.PaLab (x0, x1, x2) ->
8854                               Ast.ExApp (_loc,
8855                                 Ast.ExApp (_loc,
8856                                   Ast.ExApp (_loc,
8857                                     Ast.ExId (_loc,
8858                                       Ast.IdAcc (_loc,
8859                                         Ast.IdUid (_loc, "Ast"),
8860                                         Ast.IdUid (_loc, "PaLab"))),
8861                                     meta_loc _loc x0),
8862                                   meta_string _loc x1),
8863                                 meta_patt _loc x2)
8864                           | Ast.PaFlo (x0, x1) ->
8865                               Ast.ExApp (_loc,
8866                                 Ast.ExApp (_loc,
8867                                   Ast.ExId (_loc,
8868                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8869                                       Ast.IdUid (_loc, "PaFlo"))),
8870                                   meta_loc _loc x0),
8871                                 meta_string _loc x1)
8872                           | Ast.PaNativeInt (x0, x1) ->
8873                               Ast.ExApp (_loc,
8874                                 Ast.ExApp (_loc,
8875                                   Ast.ExId (_loc,
8876                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8877                                       Ast.IdUid (_loc, "PaNativeInt"))),
8878                                   meta_loc _loc x0),
8879                                 meta_string _loc x1)
8880                           | Ast.PaInt64 (x0, x1) ->
8881                               Ast.ExApp (_loc,
8882                                 Ast.ExApp (_loc,
8883                                   Ast.ExId (_loc,
8884                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8885                                       Ast.IdUid (_loc, "PaInt64"))),
8886                                   meta_loc _loc x0),
8887                                 meta_string _loc x1)
8888                           | Ast.PaInt32 (x0, x1) ->
8889                               Ast.ExApp (_loc,
8890                                 Ast.ExApp (_loc,
8891                                   Ast.ExId (_loc,
8892                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8893                                       Ast.IdUid (_loc, "PaInt32"))),
8894                                   meta_loc _loc x0),
8895                                 meta_string _loc x1)
8896                           | Ast.PaInt (x0, x1) ->
8897                               Ast.ExApp (_loc,
8898                                 Ast.ExApp (_loc,
8899                                   Ast.ExId (_loc,
8900                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8901                                       Ast.IdUid (_loc, "PaInt"))),
8902                                   meta_loc _loc x0),
8903                                 meta_string _loc x1)
8904                           | Ast.PaChr (x0, x1) ->
8905                               Ast.ExApp (_loc,
8906                                 Ast.ExApp (_loc,
8907                                   Ast.ExId (_loc,
8908                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8909                                       Ast.IdUid (_loc, "PaChr"))),
8910                                   meta_loc _loc x0),
8911                                 meta_string _loc x1)
8912                           | Ast.PaSem (x0, x1, x2) ->
8913                               Ast.ExApp (_loc,
8914                                 Ast.ExApp (_loc,
8915                                   Ast.ExApp (_loc,
8916                                     Ast.ExId (_loc,
8917                                       Ast.IdAcc (_loc,
8918                                         Ast.IdUid (_loc, "Ast"),
8919                                         Ast.IdUid (_loc, "PaSem"))),
8920                                     meta_loc _loc x0),
8921                                   meta_patt _loc x1),
8922                                 meta_patt _loc x2)
8923                           | Ast.PaCom (x0, x1, x2) ->
8924                               Ast.ExApp (_loc,
8925                                 Ast.ExApp (_loc,
8926                                   Ast.ExApp (_loc,
8927                                     Ast.ExId (_loc,
8928                                       Ast.IdAcc (_loc,
8929                                         Ast.IdUid (_loc, "Ast"),
8930                                         Ast.IdUid (_loc, "PaCom"))),
8931                                     meta_loc _loc x0),
8932                                   meta_patt _loc x1),
8933                                 meta_patt _loc x2)
8934                           | Ast.PaArr (x0, x1) ->
8935                               Ast.ExApp (_loc,
8936                                 Ast.ExApp (_loc,
8937                                   Ast.ExId (_loc,
8938                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8939                                       Ast.IdUid (_loc, "PaArr"))),
8940                                   meta_loc _loc x0),
8941                                 meta_patt _loc x1)
8942                           | Ast.PaApp (x0, x1, x2) ->
8943                               Ast.ExApp (_loc,
8944                                 Ast.ExApp (_loc,
8945                                   Ast.ExApp (_loc,
8946                                     Ast.ExId (_loc,
8947                                       Ast.IdAcc (_loc,
8948                                         Ast.IdUid (_loc, "Ast"),
8949                                         Ast.IdUid (_loc, "PaApp"))),
8950                                     meta_loc _loc x0),
8951                                   meta_patt _loc x1),
8952                                 meta_patt _loc x2)
8953                           | Ast.PaAny x0 ->
8954                               Ast.ExApp (_loc,
8955                                 Ast.ExId (_loc,
8956                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8957                                     Ast.IdUid (_loc, "PaAny"))),
8958                                 meta_loc _loc x0)
8959                           | Ast.PaAnt (x0, x1) -> Ast.ExAnt (x0, x1)
8960                           | Ast.PaAli (x0, x1, x2) ->
8961                               Ast.ExApp (_loc,
8962                                 Ast.ExApp (_loc,
8963                                   Ast.ExApp (_loc,
8964                                     Ast.ExId (_loc,
8965                                       Ast.IdAcc (_loc,
8966                                         Ast.IdUid (_loc, "Ast"),
8967                                         Ast.IdUid (_loc, "PaAli"))),
8968                                     meta_loc _loc x0),
8969                                   meta_patt _loc x1),
8970                                 meta_patt _loc x2)
8971                           | Ast.PaId (x0, x1) ->
8972                               Ast.ExApp (_loc,
8973                                 Ast.ExApp (_loc,
8974                                   Ast.ExId (_loc,
8975                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8976                                       Ast.IdUid (_loc, "PaId"))),
8977                                   meta_loc _loc x0),
8978                                 meta_ident _loc x1)
8979                           | Ast.PaNil x0 ->
8980                               Ast.ExApp (_loc,
8981                                 Ast.ExId (_loc,
8982                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
8983                                     Ast.IdUid (_loc, "PaNil"))),
8984                                 meta_loc _loc x0)
8985                         and meta_rec_binding _loc =
8986                           function
8987                           | Ast.RbAnt (x0, x1) -> Ast.ExAnt (x0, x1)
8988                           | Ast.RbEq (x0, x1, x2) ->
8989                               Ast.ExApp (_loc,
8990                                 Ast.ExApp (_loc,
8991                                   Ast.ExApp (_loc,
8992                                     Ast.ExId (_loc,
8993                                       Ast.IdAcc (_loc,
8994                                         Ast.IdUid (_loc, "Ast"),
8995                                         Ast.IdUid (_loc, "RbEq"))),
8996                                     meta_loc _loc x0),
8997                                   meta_ident _loc x1),
8998                                 meta_expr _loc x2)
8999                           | Ast.RbSem (x0, x1, x2) ->
9000                               Ast.ExApp (_loc,
9001                                 Ast.ExApp (_loc,
9002                                   Ast.ExApp (_loc,
9003                                     Ast.ExId (_loc,
9004                                       Ast.IdAcc (_loc,
9005                                         Ast.IdUid (_loc, "Ast"),
9006                                         Ast.IdUid (_loc, "RbSem"))),
9007                                     meta_loc _loc x0),
9008                                   meta_rec_binding _loc x1),
9009                                 meta_rec_binding _loc x2)
9010                           | Ast.RbNil x0 ->
9011                               Ast.ExApp (_loc,
9012                                 Ast.ExId (_loc,
9013                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9014                                     Ast.IdUid (_loc, "RbNil"))),
9015                                 meta_loc _loc x0)
9016                         and meta_sig_item _loc =
9017                           function
9018                           | Ast.SgAnt (x0, x1) -> Ast.ExAnt (x0, x1)
9019                           | Ast.SgVal (x0, x1, x2) ->
9020                               Ast.ExApp (_loc,
9021                                 Ast.ExApp (_loc,
9022                                   Ast.ExApp (_loc,
9023                                     Ast.ExId (_loc,
9024                                       Ast.IdAcc (_loc,
9025                                         Ast.IdUid (_loc, "Ast"),
9026                                         Ast.IdUid (_loc, "SgVal"))),
9027                                     meta_loc _loc x0),
9028                                   meta_string _loc x1),
9029                                 meta_ctyp _loc x2)
9030                           | Ast.SgTyp (x0, x1) ->
9031                               Ast.ExApp (_loc,
9032                                 Ast.ExApp (_loc,
9033                                   Ast.ExId (_loc,
9034                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9035                                       Ast.IdUid (_loc, "SgTyp"))),
9036                                   meta_loc _loc x0),
9037                                 meta_ctyp _loc x1)
9038                           | Ast.SgOpn (x0, x1) ->
9039                               Ast.ExApp (_loc,
9040                                 Ast.ExApp (_loc,
9041                                   Ast.ExId (_loc,
9042                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9043                                       Ast.IdUid (_loc, "SgOpn"))),
9044                                   meta_loc _loc x0),
9045                                 meta_ident _loc x1)
9046                           | Ast.SgMty (x0, x1, x2) ->
9047                               Ast.ExApp (_loc,
9048                                 Ast.ExApp (_loc,
9049                                   Ast.ExApp (_loc,
9050                                     Ast.ExId (_loc,
9051                                       Ast.IdAcc (_loc,
9052                                         Ast.IdUid (_loc, "Ast"),
9053                                         Ast.IdUid (_loc, "SgMty"))),
9054                                     meta_loc _loc x0),
9055                                   meta_string _loc x1),
9056                                 meta_module_type _loc x2)
9057                           | Ast.SgRecMod (x0, x1) ->
9058                               Ast.ExApp (_loc,
9059                                 Ast.ExApp (_loc,
9060                                   Ast.ExId (_loc,
9061                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9062                                       Ast.IdUid (_loc, "SgRecMod"))),
9063                                   meta_loc _loc x0),
9064                                 meta_module_binding _loc x1)
9065                           | Ast.SgMod (x0, x1, x2) ->
9066                               Ast.ExApp (_loc,
9067                                 Ast.ExApp (_loc,
9068                                   Ast.ExApp (_loc,
9069                                     Ast.ExId (_loc,
9070                                       Ast.IdAcc (_loc,
9071                                         Ast.IdUid (_loc, "Ast"),
9072                                         Ast.IdUid (_loc, "SgMod"))),
9073                                     meta_loc _loc x0),
9074                                   meta_string _loc x1),
9075                                 meta_module_type _loc x2)
9076                           | Ast.SgInc (x0, x1) ->
9077                               Ast.ExApp (_loc,
9078                                 Ast.ExApp (_loc,
9079                                   Ast.ExId (_loc,
9080                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9081                                       Ast.IdUid (_loc, "SgInc"))),
9082                                   meta_loc _loc x0),
9083                                 meta_module_type _loc x1)
9084                           | Ast.SgExt (x0, x1, x2, x3) ->
9085                               Ast.ExApp (_loc,
9086                                 Ast.ExApp (_loc,
9087                                   Ast.ExApp (_loc,
9088                                     Ast.ExApp (_loc,
9089                                       Ast.ExId (_loc,
9090                                         Ast.IdAcc (_loc,
9091                                           Ast.IdUid (_loc, "Ast"),
9092                                           Ast.IdUid (_loc, "SgExt"))),
9093                                       meta_loc _loc x0),
9094                                     meta_string _loc x1),
9095                                   meta_ctyp _loc x2),
9096                                 meta_meta_list meta_string _loc x3)
9097                           | Ast.SgExc (x0, x1) ->
9098                               Ast.ExApp (_loc,
9099                                 Ast.ExApp (_loc,
9100                                   Ast.ExId (_loc,
9101                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9102                                       Ast.IdUid (_loc, "SgExc"))),
9103                                   meta_loc _loc x0),
9104                                 meta_ctyp _loc x1)
9105                           | Ast.SgDir (x0, x1, x2) ->
9106                               Ast.ExApp (_loc,
9107                                 Ast.ExApp (_loc,
9108                                   Ast.ExApp (_loc,
9109                                     Ast.ExId (_loc,
9110                                       Ast.IdAcc (_loc,
9111                                         Ast.IdUid (_loc, "Ast"),
9112                                         Ast.IdUid (_loc, "SgDir"))),
9113                                     meta_loc _loc x0),
9114                                   meta_string _loc x1),
9115                                 meta_expr _loc x2)
9116                           | Ast.SgSem (x0, x1, x2) ->
9117                               Ast.ExApp (_loc,
9118                                 Ast.ExApp (_loc,
9119                                   Ast.ExApp (_loc,
9120                                     Ast.ExId (_loc,
9121                                       Ast.IdAcc (_loc,
9122                                         Ast.IdUid (_loc, "Ast"),
9123                                         Ast.IdUid (_loc, "SgSem"))),
9124                                     meta_loc _loc x0),
9125                                   meta_sig_item _loc x1),
9126                                 meta_sig_item _loc x2)
9127                           | Ast.SgClt (x0, x1) ->
9128                               Ast.ExApp (_loc,
9129                                 Ast.ExApp (_loc,
9130                                   Ast.ExId (_loc,
9131                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9132                                       Ast.IdUid (_loc, "SgClt"))),
9133                                   meta_loc _loc x0),
9134                                 meta_class_type _loc x1)
9135                           | Ast.SgCls (x0, x1) ->
9136                               Ast.ExApp (_loc,
9137                                 Ast.ExApp (_loc,
9138                                   Ast.ExId (_loc,
9139                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9140                                       Ast.IdUid (_loc, "SgCls"))),
9141                                   meta_loc _loc x0),
9142                                 meta_class_type _loc x1)
9143                           | Ast.SgNil x0 ->
9144                               Ast.ExApp (_loc,
9145                                 Ast.ExId (_loc,
9146                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9147                                     Ast.IdUid (_loc, "SgNil"))),
9148                                 meta_loc _loc x0)
9149                         and meta_str_item _loc =
9150                           function
9151                           | Ast.StAnt (x0, x1) -> Ast.ExAnt (x0, x1)
9152                           | Ast.StVal (x0, x1, x2) ->
9153                               Ast.ExApp (_loc,
9154                                 Ast.ExApp (_loc,
9155                                   Ast.ExApp (_loc,
9156                                     Ast.ExId (_loc,
9157                                       Ast.IdAcc (_loc,
9158                                         Ast.IdUid (_loc, "Ast"),
9159                                         Ast.IdUid (_loc, "StVal"))),
9160                                     meta_loc _loc x0),
9161                                   meta_meta_bool _loc x1),
9162                                 meta_binding _loc x2)
9163                           | Ast.StTyp (x0, x1) ->
9164                               Ast.ExApp (_loc,
9165                                 Ast.ExApp (_loc,
9166                                   Ast.ExId (_loc,
9167                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9168                                       Ast.IdUid (_loc, "StTyp"))),
9169                                   meta_loc _loc x0),
9170                                 meta_ctyp _loc x1)
9171                           | Ast.StOpn (x0, x1) ->
9172                               Ast.ExApp (_loc,
9173                                 Ast.ExApp (_loc,
9174                                   Ast.ExId (_loc,
9175                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9176                                       Ast.IdUid (_loc, "StOpn"))),
9177                                   meta_loc _loc x0),
9178                                 meta_ident _loc x1)
9179                           | Ast.StMty (x0, x1, x2) ->
9180                               Ast.ExApp (_loc,
9181                                 Ast.ExApp (_loc,
9182                                   Ast.ExApp (_loc,
9183                                     Ast.ExId (_loc,
9184                                       Ast.IdAcc (_loc,
9185                                         Ast.IdUid (_loc, "Ast"),
9186                                         Ast.IdUid (_loc, "StMty"))),
9187                                     meta_loc _loc x0),
9188                                   meta_string _loc x1),
9189                                 meta_module_type _loc x2)
9190                           | Ast.StRecMod (x0, x1) ->
9191                               Ast.ExApp (_loc,
9192                                 Ast.ExApp (_loc,
9193                                   Ast.ExId (_loc,
9194                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9195                                       Ast.IdUid (_loc, "StRecMod"))),
9196                                   meta_loc _loc x0),
9197                                 meta_module_binding _loc x1)
9198                           | Ast.StMod (x0, x1, x2) ->
9199                               Ast.ExApp (_loc,
9200                                 Ast.ExApp (_loc,
9201                                   Ast.ExApp (_loc,
9202                                     Ast.ExId (_loc,
9203                                       Ast.IdAcc (_loc,
9204                                         Ast.IdUid (_loc, "Ast"),
9205                                         Ast.IdUid (_loc, "StMod"))),
9206                                     meta_loc _loc x0),
9207                                   meta_string _loc x1),
9208                                 meta_module_expr _loc x2)
9209                           | Ast.StInc (x0, x1) ->
9210                               Ast.ExApp (_loc,
9211                                 Ast.ExApp (_loc,
9212                                   Ast.ExId (_loc,
9213                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9214                                       Ast.IdUid (_loc, "StInc"))),
9215                                   meta_loc _loc x0),
9216                                 meta_module_expr _loc x1)
9217                           | Ast.StExt (x0, x1, x2, x3) ->
9218                               Ast.ExApp (_loc,
9219                                 Ast.ExApp (_loc,
9220                                   Ast.ExApp (_loc,
9221                                     Ast.ExApp (_loc,
9222                                       Ast.ExId (_loc,
9223                                         Ast.IdAcc (_loc,
9224                                           Ast.IdUid (_loc, "Ast"),
9225                                           Ast.IdUid (_loc, "StExt"))),
9226                                       meta_loc _loc x0),
9227                                     meta_string _loc x1),
9228                                   meta_ctyp _loc x2),
9229                                 meta_meta_list meta_string _loc x3)
9230                           | Ast.StExp (x0, x1) ->
9231                               Ast.ExApp (_loc,
9232                                 Ast.ExApp (_loc,
9233                                   Ast.ExId (_loc,
9234                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9235                                       Ast.IdUid (_loc, "StExp"))),
9236                                   meta_loc _loc x0),
9237                                 meta_expr _loc x1)
9238                           | Ast.StExc (x0, x1, x2) ->
9239                               Ast.ExApp (_loc,
9240                                 Ast.ExApp (_loc,
9241                                   Ast.ExApp (_loc,
9242                                     Ast.ExId (_loc,
9243                                       Ast.IdAcc (_loc,
9244                                         Ast.IdUid (_loc, "Ast"),
9245                                         Ast.IdUid (_loc, "StExc"))),
9246                                     meta_loc _loc x0),
9247                                   meta_ctyp _loc x1),
9248                                 meta_meta_option meta_ident _loc x2)
9249                           | Ast.StDir (x0, x1, x2) ->
9250                               Ast.ExApp (_loc,
9251                                 Ast.ExApp (_loc,
9252                                   Ast.ExApp (_loc,
9253                                     Ast.ExId (_loc,
9254                                       Ast.IdAcc (_loc,
9255                                         Ast.IdUid (_loc, "Ast"),
9256                                         Ast.IdUid (_loc, "StDir"))),
9257                                     meta_loc _loc x0),
9258                                   meta_string _loc x1),
9259                                 meta_expr _loc x2)
9260                           | Ast.StSem (x0, x1, x2) ->
9261                               Ast.ExApp (_loc,
9262                                 Ast.ExApp (_loc,
9263                                   Ast.ExApp (_loc,
9264                                     Ast.ExId (_loc,
9265                                       Ast.IdAcc (_loc,
9266                                         Ast.IdUid (_loc, "Ast"),
9267                                         Ast.IdUid (_loc, "StSem"))),
9268                                     meta_loc _loc x0),
9269                                   meta_str_item _loc x1),
9270                                 meta_str_item _loc x2)
9271                           | Ast.StClt (x0, x1) ->
9272                               Ast.ExApp (_loc,
9273                                 Ast.ExApp (_loc,
9274                                   Ast.ExId (_loc,
9275                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9276                                       Ast.IdUid (_loc, "StClt"))),
9277                                   meta_loc _loc x0),
9278                                 meta_class_type _loc x1)
9279                           | Ast.StCls (x0, x1) ->
9280                               Ast.ExApp (_loc,
9281                                 Ast.ExApp (_loc,
9282                                   Ast.ExId (_loc,
9283                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9284                                       Ast.IdUid (_loc, "StCls"))),
9285                                   meta_loc _loc x0),
9286                                 meta_class_expr _loc x1)
9287                           | Ast.StNil x0 ->
9288                               Ast.ExApp (_loc,
9289                                 Ast.ExId (_loc,
9290                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9291                                     Ast.IdUid (_loc, "StNil"))),
9292                                 meta_loc _loc x0)
9293                         and meta_with_constr _loc =
9294                           function
9295                           | Ast.WcAnt (x0, x1) -> Ast.ExAnt (x0, x1)
9296                           | Ast.WcAnd (x0, x1, x2) ->
9297                               Ast.ExApp (_loc,
9298                                 Ast.ExApp (_loc,
9299                                   Ast.ExApp (_loc,
9300                                     Ast.ExId (_loc,
9301                                       Ast.IdAcc (_loc,
9302                                         Ast.IdUid (_loc, "Ast"),
9303                                         Ast.IdUid (_loc, "WcAnd"))),
9304                                     meta_loc _loc x0),
9305                                   meta_with_constr _loc x1),
9306                                 meta_with_constr _loc x2)
9307                           | Ast.WcMod (x0, x1, x2) ->
9308                               Ast.ExApp (_loc,
9309                                 Ast.ExApp (_loc,
9310                                   Ast.ExApp (_loc,
9311                                     Ast.ExId (_loc,
9312                                       Ast.IdAcc (_loc,
9313                                         Ast.IdUid (_loc, "Ast"),
9314                                         Ast.IdUid (_loc, "WcMod"))),
9315                                     meta_loc _loc x0),
9316                                   meta_ident _loc x1),
9317                                 meta_ident _loc x2)
9318                           | Ast.WcTyp (x0, x1, x2) ->
9319                               Ast.ExApp (_loc,
9320                                 Ast.ExApp (_loc,
9321                                   Ast.ExApp (_loc,
9322                                     Ast.ExId (_loc,
9323                                       Ast.IdAcc (_loc,
9324                                         Ast.IdUid (_loc, "Ast"),
9325                                         Ast.IdUid (_loc, "WcTyp"))),
9326                                     meta_loc _loc x0),
9327                                   meta_ctyp _loc x1),
9328                                 meta_ctyp _loc x2)
9329                           | Ast.WcNil x0 ->
9330                               Ast.ExApp (_loc,
9331                                 Ast.ExId (_loc,
9332                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9333                                     Ast.IdUid (_loc, "WcNil"))),
9334                                 meta_loc _loc x0)
9335                           
9336                       end
9337                       
9338                     let meta_loc = meta_loc_patt
9339                       
9340                     module Patt =
9341                       struct
9342                         let meta_string _loc s = Ast.PaStr (_loc, s)
9343                           
9344                         let meta_int _loc s = Ast.PaInt (_loc, s)
9345                           
9346                         let meta_float _loc s = Ast.PaFlo (_loc, s)
9347                           
9348                         let meta_char _loc s = Ast.PaChr (_loc, s)
9349                           
9350                         let meta_bool _loc =
9351                           function
9352                           | false ->
9353                               Ast.PaId (_loc, Ast.IdUid (_loc, "False"))
9354                           | true -> Ast.PaId (_loc, Ast.IdUid (_loc, "True"))
9355                           
9356                         let rec meta_list mf_a _loc =
9357                           function
9358                           | [] -> Ast.PaId (_loc, Ast.IdUid (_loc, "[]"))
9359                           | x :: xs ->
9360                               Ast.PaApp (_loc,
9361                                 Ast.PaApp (_loc,
9362                                   Ast.PaId (_loc, Ast.IdUid (_loc, "::")),
9363                                   mf_a _loc x),
9364                                 meta_list mf_a _loc xs)
9365                           
9366                         let rec meta_binding _loc =
9367                           function
9368                           | Ast.BiAnt (x0, x1) -> Ast.PaAnt (x0, x1)
9369                           | Ast.BiEq (x0, x1, x2) ->
9370                               Ast.PaApp (_loc,
9371                                 Ast.PaApp (_loc,
9372                                   Ast.PaApp (_loc,
9373                                     Ast.PaId (_loc,
9374                                       Ast.IdAcc (_loc,
9375                                         Ast.IdUid (_loc, "Ast"),
9376                                         Ast.IdUid (_loc, "BiEq"))),
9377                                     meta_loc _loc x0),
9378                                   meta_patt _loc x1),
9379                                 meta_expr _loc x2)
9380                           | Ast.BiAnd (x0, x1, x2) ->
9381                               Ast.PaApp (_loc,
9382                                 Ast.PaApp (_loc,
9383                                   Ast.PaApp (_loc,
9384                                     Ast.PaId (_loc,
9385                                       Ast.IdAcc (_loc,
9386                                         Ast.IdUid (_loc, "Ast"),
9387                                         Ast.IdUid (_loc, "BiAnd"))),
9388                                     meta_loc _loc x0),
9389                                   meta_binding _loc x1),
9390                                 meta_binding _loc x2)
9391                           | Ast.BiNil x0 ->
9392                               Ast.PaApp (_loc,
9393                                 Ast.PaId (_loc,
9394                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9395                                     Ast.IdUid (_loc, "BiNil"))),
9396                                 meta_loc _loc x0)
9397                         and meta_class_expr _loc =
9398                           function
9399                           | Ast.CeAnt (x0, x1) -> Ast.PaAnt (x0, x1)
9400                           | Ast.CeEq (x0, x1, x2) ->
9401                               Ast.PaApp (_loc,
9402                                 Ast.PaApp (_loc,
9403                                   Ast.PaApp (_loc,
9404                                     Ast.PaId (_loc,
9405                                       Ast.IdAcc (_loc,
9406                                         Ast.IdUid (_loc, "Ast"),
9407                                         Ast.IdUid (_loc, "CeEq"))),
9408                                     meta_loc _loc x0),
9409                                   meta_class_expr _loc x1),
9410                                 meta_class_expr _loc x2)
9411                           | Ast.CeAnd (x0, x1, x2) ->
9412                               Ast.PaApp (_loc,
9413                                 Ast.PaApp (_loc,
9414                                   Ast.PaApp (_loc,
9415                                     Ast.PaId (_loc,
9416                                       Ast.IdAcc (_loc,
9417                                         Ast.IdUid (_loc, "Ast"),
9418                                         Ast.IdUid (_loc, "CeAnd"))),
9419                                     meta_loc _loc x0),
9420                                   meta_class_expr _loc x1),
9421                                 meta_class_expr _loc x2)
9422                           | Ast.CeTyc (x0, x1, x2) ->
9423                               Ast.PaApp (_loc,
9424                                 Ast.PaApp (_loc,
9425                                   Ast.PaApp (_loc,
9426                                     Ast.PaId (_loc,
9427                                       Ast.IdAcc (_loc,
9428                                         Ast.IdUid (_loc, "Ast"),
9429                                         Ast.IdUid (_loc, "CeTyc"))),
9430                                     meta_loc _loc x0),
9431                                   meta_class_expr _loc x1),
9432                                 meta_class_type _loc x2)
9433                           | Ast.CeStr (x0, x1, x2) ->
9434                               Ast.PaApp (_loc,
9435                                 Ast.PaApp (_loc,
9436                                   Ast.PaApp (_loc,
9437                                     Ast.PaId (_loc,
9438                                       Ast.IdAcc (_loc,
9439                                         Ast.IdUid (_loc, "Ast"),
9440                                         Ast.IdUid (_loc, "CeStr"))),
9441                                     meta_loc _loc x0),
9442                                   meta_patt _loc x1),
9443                                 meta_class_str_item _loc x2)
9444                           | Ast.CeLet (x0, x1, x2, x3) ->
9445                               Ast.PaApp (_loc,
9446                                 Ast.PaApp (_loc,
9447                                   Ast.PaApp (_loc,
9448                                     Ast.PaApp (_loc,
9449                                       Ast.PaId (_loc,
9450                                         Ast.IdAcc (_loc,
9451                                           Ast.IdUid (_loc, "Ast"),
9452                                           Ast.IdUid (_loc, "CeLet"))),
9453                                       meta_loc _loc x0),
9454                                     meta_meta_bool _loc x1),
9455                                   meta_binding _loc x2),
9456                                 meta_class_expr _loc x3)
9457                           | Ast.CeFun (x0, x1, x2) ->
9458                               Ast.PaApp (_loc,
9459                                 Ast.PaApp (_loc,
9460                                   Ast.PaApp (_loc,
9461                                     Ast.PaId (_loc,
9462                                       Ast.IdAcc (_loc,
9463                                         Ast.IdUid (_loc, "Ast"),
9464                                         Ast.IdUid (_loc, "CeFun"))),
9465                                     meta_loc _loc x0),
9466                                   meta_patt _loc x1),
9467                                 meta_class_expr _loc x2)
9468                           | Ast.CeCon (x0, x1, x2, x3) ->
9469                               Ast.PaApp (_loc,
9470                                 Ast.PaApp (_loc,
9471                                   Ast.PaApp (_loc,
9472                                     Ast.PaApp (_loc,
9473                                       Ast.PaId (_loc,
9474                                         Ast.IdAcc (_loc,
9475                                           Ast.IdUid (_loc, "Ast"),
9476                                           Ast.IdUid (_loc, "CeCon"))),
9477                                       meta_loc _loc x0),
9478                                     meta_meta_bool _loc x1),
9479                                   meta_ident _loc x2),
9480                                 meta_ctyp _loc x3)
9481                           | Ast.CeApp (x0, x1, x2) ->
9482                               Ast.PaApp (_loc,
9483                                 Ast.PaApp (_loc,
9484                                   Ast.PaApp (_loc,
9485                                     Ast.PaId (_loc,
9486                                       Ast.IdAcc (_loc,
9487                                         Ast.IdUid (_loc, "Ast"),
9488                                         Ast.IdUid (_loc, "CeApp"))),
9489                                     meta_loc _loc x0),
9490                                   meta_class_expr _loc x1),
9491                                 meta_expr _loc x2)
9492                           | Ast.CeNil x0 ->
9493                               Ast.PaApp (_loc,
9494                                 Ast.PaId (_loc,
9495                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9496                                     Ast.IdUid (_loc, "CeNil"))),
9497                                 meta_loc _loc x0)
9498                         and meta_class_sig_item _loc =
9499                           function
9500                           | Ast.CgAnt (x0, x1) -> Ast.PaAnt (x0, x1)
9501                           | Ast.CgVir (x0, x1, x2, x3) ->
9502                               Ast.PaApp (_loc,
9503                                 Ast.PaApp (_loc,
9504                                   Ast.PaApp (_loc,
9505                                     Ast.PaApp (_loc,
9506                                       Ast.PaId (_loc,
9507                                         Ast.IdAcc (_loc,
9508                                           Ast.IdUid (_loc, "Ast"),
9509                                           Ast.IdUid (_loc, "CgVir"))),
9510                                       meta_loc _loc x0),
9511                                     meta_string _loc x1),
9512                                   meta_meta_bool _loc x2),
9513                                 meta_ctyp _loc x3)
9514                           | Ast.CgVal (x0, x1, x2, x3, x4) ->
9515                               Ast.PaApp (_loc,
9516                                 Ast.PaApp (_loc,
9517                                   Ast.PaApp (_loc,
9518                                     Ast.PaApp (_loc,
9519                                       Ast.PaApp (_loc,
9520                                         Ast.PaId (_loc,
9521                                           Ast.IdAcc (_loc,
9522                                             Ast.IdUid (_loc, "Ast"),
9523                                             Ast.IdUid (_loc, "CgVal"))),
9524                                         meta_loc _loc x0),
9525                                       meta_string _loc x1),
9526                                     meta_meta_bool _loc x2),
9527                                   meta_meta_bool _loc x3),
9528                                 meta_ctyp _loc x4)
9529                           | Ast.CgMth (x0, x1, x2, x3) ->
9530                               Ast.PaApp (_loc,
9531                                 Ast.PaApp (_loc,
9532                                   Ast.PaApp (_loc,
9533                                     Ast.PaApp (_loc,
9534                                       Ast.PaId (_loc,
9535                                         Ast.IdAcc (_loc,
9536                                           Ast.IdUid (_loc, "Ast"),
9537                                           Ast.IdUid (_loc, "CgMth"))),
9538                                       meta_loc _loc x0),
9539                                     meta_string _loc x1),
9540                                   meta_meta_bool _loc x2),
9541                                 meta_ctyp _loc x3)
9542                           | Ast.CgInh (x0, x1) ->
9543                               Ast.PaApp (_loc,
9544                                 Ast.PaApp (_loc,
9545                                   Ast.PaId (_loc,
9546                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9547                                       Ast.IdUid (_loc, "CgInh"))),
9548                                   meta_loc _loc x0),
9549                                 meta_class_type _loc x1)
9550                           | Ast.CgSem (x0, x1, x2) ->
9551                               Ast.PaApp (_loc,
9552                                 Ast.PaApp (_loc,
9553                                   Ast.PaApp (_loc,
9554                                     Ast.PaId (_loc,
9555                                       Ast.IdAcc (_loc,
9556                                         Ast.IdUid (_loc, "Ast"),
9557                                         Ast.IdUid (_loc, "CgSem"))),
9558                                     meta_loc _loc x0),
9559                                   meta_class_sig_item _loc x1),
9560                                 meta_class_sig_item _loc x2)
9561                           | Ast.CgCtr (x0, x1, x2) ->
9562                               Ast.PaApp (_loc,
9563                                 Ast.PaApp (_loc,
9564                                   Ast.PaApp (_loc,
9565                                     Ast.PaId (_loc,
9566                                       Ast.IdAcc (_loc,
9567                                         Ast.IdUid (_loc, "Ast"),
9568                                         Ast.IdUid (_loc, "CgCtr"))),
9569                                     meta_loc _loc x0),
9570                                   meta_ctyp _loc x1),
9571                                 meta_ctyp _loc x2)
9572                           | Ast.CgNil x0 ->
9573                               Ast.PaApp (_loc,
9574                                 Ast.PaId (_loc,
9575                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9576                                     Ast.IdUid (_loc, "CgNil"))),
9577                                 meta_loc _loc x0)
9578                         and meta_class_str_item _loc =
9579                           function
9580                           | Ast.CrAnt (x0, x1) -> Ast.PaAnt (x0, x1)
9581                           | Ast.CrVvr (x0, x1, x2, x3) ->
9582                               Ast.PaApp (_loc,
9583                                 Ast.PaApp (_loc,
9584                                   Ast.PaApp (_loc,
9585                                     Ast.PaApp (_loc,
9586                                       Ast.PaId (_loc,
9587                                         Ast.IdAcc (_loc,
9588                                           Ast.IdUid (_loc, "Ast"),
9589                                           Ast.IdUid (_loc, "CrVvr"))),
9590                                       meta_loc _loc x0),
9591                                     meta_string _loc x1),
9592                                   meta_meta_bool _loc x2),
9593                                 meta_ctyp _loc x3)
9594                           | Ast.CrVir (x0, x1, x2, x3) ->
9595                               Ast.PaApp (_loc,
9596                                 Ast.PaApp (_loc,
9597                                   Ast.PaApp (_loc,
9598                                     Ast.PaApp (_loc,
9599                                       Ast.PaId (_loc,
9600                                         Ast.IdAcc (_loc,
9601                                           Ast.IdUid (_loc, "Ast"),
9602                                           Ast.IdUid (_loc, "CrVir"))),
9603                                       meta_loc _loc x0),
9604                                     meta_string _loc x1),
9605                                   meta_meta_bool _loc x2),
9606                                 meta_ctyp _loc x3)
9607                           | Ast.CrVal (x0, x1, x2, x3) ->
9608                               Ast.PaApp (_loc,
9609                                 Ast.PaApp (_loc,
9610                                   Ast.PaApp (_loc,
9611                                     Ast.PaApp (_loc,
9612                                       Ast.PaId (_loc,
9613                                         Ast.IdAcc (_loc,
9614                                           Ast.IdUid (_loc, "Ast"),
9615                                           Ast.IdUid (_loc, "CrVal"))),
9616                                       meta_loc _loc x0),
9617                                     meta_string _loc x1),
9618                                   meta_meta_bool _loc x2),
9619                                 meta_expr _loc x3)
9620                           | Ast.CrMth (x0, x1, x2, x3, x4) ->
9621                               Ast.PaApp (_loc,
9622                                 Ast.PaApp (_loc,
9623                                   Ast.PaApp (_loc,
9624                                     Ast.PaApp (_loc,
9625                                       Ast.PaApp (_loc,
9626                                         Ast.PaId (_loc,
9627                                           Ast.IdAcc (_loc,
9628                                             Ast.IdUid (_loc, "Ast"),
9629                                             Ast.IdUid (_loc, "CrMth"))),
9630                                         meta_loc _loc x0),
9631                                       meta_string _loc x1),
9632                                     meta_meta_bool _loc x2),
9633                                   meta_expr _loc x3),
9634                                 meta_ctyp _loc x4)
9635                           | Ast.CrIni (x0, x1) ->
9636                               Ast.PaApp (_loc,
9637                                 Ast.PaApp (_loc,
9638                                   Ast.PaId (_loc,
9639                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9640                                       Ast.IdUid (_loc, "CrIni"))),
9641                                   meta_loc _loc x0),
9642                                 meta_expr _loc x1)
9643                           | Ast.CrInh (x0, x1, x2) ->
9644                               Ast.PaApp (_loc,
9645                                 Ast.PaApp (_loc,
9646                                   Ast.PaApp (_loc,
9647                                     Ast.PaId (_loc,
9648                                       Ast.IdAcc (_loc,
9649                                         Ast.IdUid (_loc, "Ast"),
9650                                         Ast.IdUid (_loc, "CrInh"))),
9651                                     meta_loc _loc x0),
9652                                   meta_class_expr _loc x1),
9653                                 meta_string _loc x2)
9654                           | Ast.CrCtr (x0, x1, x2) ->
9655                               Ast.PaApp (_loc,
9656                                 Ast.PaApp (_loc,
9657                                   Ast.PaApp (_loc,
9658                                     Ast.PaId (_loc,
9659                                       Ast.IdAcc (_loc,
9660                                         Ast.IdUid (_loc, "Ast"),
9661                                         Ast.IdUid (_loc, "CrCtr"))),
9662                                     meta_loc _loc x0),
9663                                   meta_ctyp _loc x1),
9664                                 meta_ctyp _loc x2)
9665                           | Ast.CrSem (x0, x1, x2) ->
9666                               Ast.PaApp (_loc,
9667                                 Ast.PaApp (_loc,
9668                                   Ast.PaApp (_loc,
9669                                     Ast.PaId (_loc,
9670                                       Ast.IdAcc (_loc,
9671                                         Ast.IdUid (_loc, "Ast"),
9672                                         Ast.IdUid (_loc, "CrSem"))),
9673                                     meta_loc _loc x0),
9674                                   meta_class_str_item _loc x1),
9675                                 meta_class_str_item _loc x2)
9676                           | Ast.CrNil x0 ->
9677                               Ast.PaApp (_loc,
9678                                 Ast.PaId (_loc,
9679                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9680                                     Ast.IdUid (_loc, "CrNil"))),
9681                                 meta_loc _loc x0)
9682                         and meta_class_type _loc =
9683                           function
9684                           | Ast.CtAnt (x0, x1) -> Ast.PaAnt (x0, x1)
9685                           | Ast.CtEq (x0, x1, x2) ->
9686                               Ast.PaApp (_loc,
9687                                 Ast.PaApp (_loc,
9688                                   Ast.PaApp (_loc,
9689                                     Ast.PaId (_loc,
9690                                       Ast.IdAcc (_loc,
9691                                         Ast.IdUid (_loc, "Ast"),
9692                                         Ast.IdUid (_loc, "CtEq"))),
9693                                     meta_loc _loc x0),
9694                                   meta_class_type _loc x1),
9695                                 meta_class_type _loc x2)
9696                           | Ast.CtCol (x0, x1, x2) ->
9697                               Ast.PaApp (_loc,
9698                                 Ast.PaApp (_loc,
9699                                   Ast.PaApp (_loc,
9700                                     Ast.PaId (_loc,
9701                                       Ast.IdAcc (_loc,
9702                                         Ast.IdUid (_loc, "Ast"),
9703                                         Ast.IdUid (_loc, "CtCol"))),
9704                                     meta_loc _loc x0),
9705                                   meta_class_type _loc x1),
9706                                 meta_class_type _loc x2)
9707                           | Ast.CtAnd (x0, x1, x2) ->
9708                               Ast.PaApp (_loc,
9709                                 Ast.PaApp (_loc,
9710                                   Ast.PaApp (_loc,
9711                                     Ast.PaId (_loc,
9712                                       Ast.IdAcc (_loc,
9713                                         Ast.IdUid (_loc, "Ast"),
9714                                         Ast.IdUid (_loc, "CtAnd"))),
9715                                     meta_loc _loc x0),
9716                                   meta_class_type _loc x1),
9717                                 meta_class_type _loc x2)
9718                           | Ast.CtSig (x0, x1, x2) ->
9719                               Ast.PaApp (_loc,
9720                                 Ast.PaApp (_loc,
9721                                   Ast.PaApp (_loc,
9722                                     Ast.PaId (_loc,
9723                                       Ast.IdAcc (_loc,
9724                                         Ast.IdUid (_loc, "Ast"),
9725                                         Ast.IdUid (_loc, "CtSig"))),
9726                                     meta_loc _loc x0),
9727                                   meta_ctyp _loc x1),
9728                                 meta_class_sig_item _loc x2)
9729                           | Ast.CtFun (x0, x1, x2) ->
9730                               Ast.PaApp (_loc,
9731                                 Ast.PaApp (_loc,
9732                                   Ast.PaApp (_loc,
9733                                     Ast.PaId (_loc,
9734                                       Ast.IdAcc (_loc,
9735                                         Ast.IdUid (_loc, "Ast"),
9736                                         Ast.IdUid (_loc, "CtFun"))),
9737                                     meta_loc _loc x0),
9738                                   meta_ctyp _loc x1),
9739                                 meta_class_type _loc x2)
9740                           | Ast.CtCon (x0, x1, x2, x3) ->
9741                               Ast.PaApp (_loc,
9742                                 Ast.PaApp (_loc,
9743                                   Ast.PaApp (_loc,
9744                                     Ast.PaApp (_loc,
9745                                       Ast.PaId (_loc,
9746                                         Ast.IdAcc (_loc,
9747                                           Ast.IdUid (_loc, "Ast"),
9748                                           Ast.IdUid (_loc, "CtCon"))),
9749                                       meta_loc _loc x0),
9750                                     meta_meta_bool _loc x1),
9751                                   meta_ident _loc x2),
9752                                 meta_ctyp _loc x3)
9753                           | Ast.CtNil x0 ->
9754                               Ast.PaApp (_loc,
9755                                 Ast.PaId (_loc,
9756                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9757                                     Ast.IdUid (_loc, "CtNil"))),
9758                                 meta_loc _loc x0)
9759                         and meta_ctyp _loc =
9760                           function
9761                           | Ast.TyAnt (x0, x1) -> Ast.PaAnt (x0, x1)
9762                           | Ast.TyOfAmp (x0, x1, x2) ->
9763                               Ast.PaApp (_loc,
9764                                 Ast.PaApp (_loc,
9765                                   Ast.PaApp (_loc,
9766                                     Ast.PaId (_loc,
9767                                       Ast.IdAcc (_loc,
9768                                         Ast.IdUid (_loc, "Ast"),
9769                                         Ast.IdUid (_loc, "TyOfAmp"))),
9770                                     meta_loc _loc x0),
9771                                   meta_ctyp _loc x1),
9772                                 meta_ctyp _loc x2)
9773                           | Ast.TyAmp (x0, x1, x2) ->
9774                               Ast.PaApp (_loc,
9775                                 Ast.PaApp (_loc,
9776                                   Ast.PaApp (_loc,
9777                                     Ast.PaId (_loc,
9778                                       Ast.IdAcc (_loc,
9779                                         Ast.IdUid (_loc, "Ast"),
9780                                         Ast.IdUid (_loc, "TyAmp"))),
9781                                     meta_loc _loc x0),
9782                                   meta_ctyp _loc x1),
9783                                 meta_ctyp _loc x2)
9784                           | Ast.TyVrnInfSup (x0, x1, x2) ->
9785                               Ast.PaApp (_loc,
9786                                 Ast.PaApp (_loc,
9787                                   Ast.PaApp (_loc,
9788                                     Ast.PaId (_loc,
9789                                       Ast.IdAcc (_loc,
9790                                         Ast.IdUid (_loc, "Ast"),
9791                                         Ast.IdUid (_loc, "TyVrnInfSup"))),
9792                                     meta_loc _loc x0),
9793                                   meta_ctyp _loc x1),
9794                                 meta_ctyp _loc x2)
9795                           | Ast.TyVrnInf (x0, x1) ->
9796                               Ast.PaApp (_loc,
9797                                 Ast.PaApp (_loc,
9798                                   Ast.PaId (_loc,
9799                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9800                                       Ast.IdUid (_loc, "TyVrnInf"))),
9801                                   meta_loc _loc x0),
9802                                 meta_ctyp _loc x1)
9803                           | Ast.TyVrnSup (x0, x1) ->
9804                               Ast.PaApp (_loc,
9805                                 Ast.PaApp (_loc,
9806                                   Ast.PaId (_loc,
9807                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9808                                       Ast.IdUid (_loc, "TyVrnSup"))),
9809                                   meta_loc _loc x0),
9810                                 meta_ctyp _loc x1)
9811                           | Ast.TyVrnEq (x0, x1) ->
9812                               Ast.PaApp (_loc,
9813                                 Ast.PaApp (_loc,
9814                                   Ast.PaId (_loc,
9815                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9816                                       Ast.IdUid (_loc, "TyVrnEq"))),
9817                                   meta_loc _loc x0),
9818                                 meta_ctyp _loc x1)
9819                           | Ast.TySta (x0, x1, x2) ->
9820                               Ast.PaApp (_loc,
9821                                 Ast.PaApp (_loc,
9822                                   Ast.PaApp (_loc,
9823                                     Ast.PaId (_loc,
9824                                       Ast.IdAcc (_loc,
9825                                         Ast.IdUid (_loc, "Ast"),
9826                                         Ast.IdUid (_loc, "TySta"))),
9827                                     meta_loc _loc x0),
9828                                   meta_ctyp _loc x1),
9829                                 meta_ctyp _loc x2)
9830                           | Ast.TyTup (x0, x1) ->
9831                               Ast.PaApp (_loc,
9832                                 Ast.PaApp (_loc,
9833                                   Ast.PaId (_loc,
9834                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9835                                       Ast.IdUid (_loc, "TyTup"))),
9836                                   meta_loc _loc x0),
9837                                 meta_ctyp _loc x1)
9838                           | Ast.TyMut (x0, x1) ->
9839                               Ast.PaApp (_loc,
9840                                 Ast.PaApp (_loc,
9841                                   Ast.PaId (_loc,
9842                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9843                                       Ast.IdUid (_loc, "TyMut"))),
9844                                   meta_loc _loc x0),
9845                                 meta_ctyp _loc x1)
9846                           | Ast.TyPrv (x0, x1) ->
9847                               Ast.PaApp (_loc,
9848                                 Ast.PaApp (_loc,
9849                                   Ast.PaId (_loc,
9850                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9851                                       Ast.IdUid (_loc, "TyPrv"))),
9852                                   meta_loc _loc x0),
9853                                 meta_ctyp _loc x1)
9854                           | Ast.TyOr (x0, x1, x2) ->
9855                               Ast.PaApp (_loc,
9856                                 Ast.PaApp (_loc,
9857                                   Ast.PaApp (_loc,
9858                                     Ast.PaId (_loc,
9859                                       Ast.IdAcc (_loc,
9860                                         Ast.IdUid (_loc, "Ast"),
9861                                         Ast.IdUid (_loc, "TyOr"))),
9862                                     meta_loc _loc x0),
9863                                   meta_ctyp _loc x1),
9864                                 meta_ctyp _loc x2)
9865                           | Ast.TyAnd (x0, x1, x2) ->
9866                               Ast.PaApp (_loc,
9867                                 Ast.PaApp (_loc,
9868                                   Ast.PaApp (_loc,
9869                                     Ast.PaId (_loc,
9870                                       Ast.IdAcc (_loc,
9871                                         Ast.IdUid (_loc, "Ast"),
9872                                         Ast.IdUid (_loc, "TyAnd"))),
9873                                     meta_loc _loc x0),
9874                                   meta_ctyp _loc x1),
9875                                 meta_ctyp _loc x2)
9876                           | Ast.TyOf (x0, x1, x2) ->
9877                               Ast.PaApp (_loc,
9878                                 Ast.PaApp (_loc,
9879                                   Ast.PaApp (_loc,
9880                                     Ast.PaId (_loc,
9881                                       Ast.IdAcc (_loc,
9882                                         Ast.IdUid (_loc, "Ast"),
9883                                         Ast.IdUid (_loc, "TyOf"))),
9884                                     meta_loc _loc x0),
9885                                   meta_ctyp _loc x1),
9886                                 meta_ctyp _loc x2)
9887                           | Ast.TySum (x0, x1) ->
9888                               Ast.PaApp (_loc,
9889                                 Ast.PaApp (_loc,
9890                                   Ast.PaId (_loc,
9891                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9892                                       Ast.IdUid (_loc, "TySum"))),
9893                                   meta_loc _loc x0),
9894                                 meta_ctyp _loc x1)
9895                           | Ast.TyCom (x0, x1, x2) ->
9896                               Ast.PaApp (_loc,
9897                                 Ast.PaApp (_loc,
9898                                   Ast.PaApp (_loc,
9899                                     Ast.PaId (_loc,
9900                                       Ast.IdAcc (_loc,
9901                                         Ast.IdUid (_loc, "Ast"),
9902                                         Ast.IdUid (_loc, "TyCom"))),
9903                                     meta_loc _loc x0),
9904                                   meta_ctyp _loc x1),
9905                                 meta_ctyp _loc x2)
9906                           | Ast.TySem (x0, x1, x2) ->
9907                               Ast.PaApp (_loc,
9908                                 Ast.PaApp (_loc,
9909                                   Ast.PaApp (_loc,
9910                                     Ast.PaId (_loc,
9911                                       Ast.IdAcc (_loc,
9912                                         Ast.IdUid (_loc, "Ast"),
9913                                         Ast.IdUid (_loc, "TySem"))),
9914                                     meta_loc _loc x0),
9915                                   meta_ctyp _loc x1),
9916                                 meta_ctyp _loc x2)
9917                           | Ast.TyCol (x0, x1, x2) ->
9918                               Ast.PaApp (_loc,
9919                                 Ast.PaApp (_loc,
9920                                   Ast.PaApp (_loc,
9921                                     Ast.PaId (_loc,
9922                                       Ast.IdAcc (_loc,
9923                                         Ast.IdUid (_loc, "Ast"),
9924                                         Ast.IdUid (_loc, "TyCol"))),
9925                                     meta_loc _loc x0),
9926                                   meta_ctyp _loc x1),
9927                                 meta_ctyp _loc x2)
9928                           | Ast.TyRec (x0, x1) ->
9929                               Ast.PaApp (_loc,
9930                                 Ast.PaApp (_loc,
9931                                   Ast.PaId (_loc,
9932                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9933                                       Ast.IdUid (_loc, "TyRec"))),
9934                                   meta_loc _loc x0),
9935                                 meta_ctyp _loc x1)
9936                           | Ast.TyVrn (x0, x1) ->
9937                               Ast.PaApp (_loc,
9938                                 Ast.PaApp (_loc,
9939                                   Ast.PaId (_loc,
9940                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9941                                       Ast.IdUid (_loc, "TyVrn"))),
9942                                   meta_loc _loc x0),
9943                                 meta_string _loc x1)
9944                           | Ast.TyQuM (x0, x1) ->
9945                               Ast.PaApp (_loc,
9946                                 Ast.PaApp (_loc,
9947                                   Ast.PaId (_loc,
9948                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9949                                       Ast.IdUid (_loc, "TyQuM"))),
9950                                   meta_loc _loc x0),
9951                                 meta_string _loc x1)
9952                           | Ast.TyQuP (x0, x1) ->
9953                               Ast.PaApp (_loc,
9954                                 Ast.PaApp (_loc,
9955                                   Ast.PaId (_loc,
9956                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9957                                       Ast.IdUid (_loc, "TyQuP"))),
9958                                   meta_loc _loc x0),
9959                                 meta_string _loc x1)
9960                           | Ast.TyQuo (x0, x1) ->
9961                               Ast.PaApp (_loc,
9962                                 Ast.PaApp (_loc,
9963                                   Ast.PaId (_loc,
9964                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
9965                                       Ast.IdUid (_loc, "TyQuo"))),
9966                                   meta_loc _loc x0),
9967                                 meta_string _loc x1)
9968                           | Ast.TyPol (x0, x1, x2) ->
9969                               Ast.PaApp (_loc,
9970                                 Ast.PaApp (_loc,
9971                                   Ast.PaApp (_loc,
9972                                     Ast.PaId (_loc,
9973                                       Ast.IdAcc (_loc,
9974                                         Ast.IdUid (_loc, "Ast"),
9975                                         Ast.IdUid (_loc, "TyPol"))),
9976                                     meta_loc _loc x0),
9977                                   meta_ctyp _loc x1),
9978                                 meta_ctyp _loc x2)
9979                           | Ast.TyOlb (x0, x1, x2) ->
9980                               Ast.PaApp (_loc,
9981                                 Ast.PaApp (_loc,
9982                                   Ast.PaApp (_loc,
9983                                     Ast.PaId (_loc,
9984                                       Ast.IdAcc (_loc,
9985                                         Ast.IdUid (_loc, "Ast"),
9986                                         Ast.IdUid (_loc, "TyOlb"))),
9987                                     meta_loc _loc x0),
9988                                   meta_string _loc x1),
9989                                 meta_ctyp _loc x2)
9990                           | Ast.TyObj (x0, x1, x2) ->
9991                               Ast.PaApp (_loc,
9992                                 Ast.PaApp (_loc,
9993                                   Ast.PaApp (_loc,
9994                                     Ast.PaId (_loc,
9995                                       Ast.IdAcc (_loc,
9996                                         Ast.IdUid (_loc, "Ast"),
9997                                         Ast.IdUid (_loc, "TyObj"))),
9998                                     meta_loc _loc x0),
9999                                   meta_ctyp _loc x1),
10000                                 meta_meta_bool _loc x2)
10001                           | Ast.TyDcl (x0, x1, x2, x3, x4) ->
10002                               Ast.PaApp (_loc,
10003                                 Ast.PaApp (_loc,
10004                                   Ast.PaApp (_loc,
10005                                     Ast.PaApp (_loc,
10006                                       Ast.PaApp (_loc,
10007                                         Ast.PaId (_loc,
10008                                           Ast.IdAcc (_loc,
10009                                             Ast.IdUid (_loc, "Ast"),
10010                                             Ast.IdUid (_loc, "TyDcl"))),
10011                                         meta_loc _loc x0),
10012                                       meta_string _loc x1),
10013                                     meta_list meta_ctyp _loc x2),
10014                                   meta_ctyp _loc x3),
10015                                 meta_list
10016                                   (fun _loc (x1, x2) ->
10017                                      Ast.PaTup (_loc,
10018                                        Ast.PaCom (_loc, meta_ctyp _loc x1,
10019                                          meta_ctyp _loc x2)))
10020                                   _loc x4)
10021                           | Ast.TyMan (x0, x1, x2) ->
10022                               Ast.PaApp (_loc,
10023                                 Ast.PaApp (_loc,
10024                                   Ast.PaApp (_loc,
10025                                     Ast.PaId (_loc,
10026                                       Ast.IdAcc (_loc,
10027                                         Ast.IdUid (_loc, "Ast"),
10028                                         Ast.IdUid (_loc, "TyMan"))),
10029                                     meta_loc _loc x0),
10030                                   meta_ctyp _loc x1),
10031                                 meta_ctyp _loc x2)
10032                           | Ast.TyId (x0, x1) ->
10033                               Ast.PaApp (_loc,
10034                                 Ast.PaApp (_loc,
10035                                   Ast.PaId (_loc,
10036                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10037                                       Ast.IdUid (_loc, "TyId"))),
10038                                   meta_loc _loc x0),
10039                                 meta_ident _loc x1)
10040                           | Ast.TyLab (x0, x1, x2) ->
10041                               Ast.PaApp (_loc,
10042                                 Ast.PaApp (_loc,
10043                                   Ast.PaApp (_loc,
10044                                     Ast.PaId (_loc,
10045                                       Ast.IdAcc (_loc,
10046                                         Ast.IdUid (_loc, "Ast"),
10047                                         Ast.IdUid (_loc, "TyLab"))),
10048                                     meta_loc _loc x0),
10049                                   meta_string _loc x1),
10050                                 meta_ctyp _loc x2)
10051                           | Ast.TyCls (x0, x1) ->
10052                               Ast.PaApp (_loc,
10053                                 Ast.PaApp (_loc,
10054                                   Ast.PaId (_loc,
10055                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10056                                       Ast.IdUid (_loc, "TyCls"))),
10057                                   meta_loc _loc x0),
10058                                 meta_ident _loc x1)
10059                           | Ast.TyArr (x0, x1, x2) ->
10060                               Ast.PaApp (_loc,
10061                                 Ast.PaApp (_loc,
10062                                   Ast.PaApp (_loc,
10063                                     Ast.PaId (_loc,
10064                                       Ast.IdAcc (_loc,
10065                                         Ast.IdUid (_loc, "Ast"),
10066                                         Ast.IdUid (_loc, "TyArr"))),
10067                                     meta_loc _loc x0),
10068                                   meta_ctyp _loc x1),
10069                                 meta_ctyp _loc x2)
10070                           | Ast.TyApp (x0, x1, x2) ->
10071                               Ast.PaApp (_loc,
10072                                 Ast.PaApp (_loc,
10073                                   Ast.PaApp (_loc,
10074                                     Ast.PaId (_loc,
10075                                       Ast.IdAcc (_loc,
10076                                         Ast.IdUid (_loc, "Ast"),
10077                                         Ast.IdUid (_loc, "TyApp"))),
10078                                     meta_loc _loc x0),
10079                                   meta_ctyp _loc x1),
10080                                 meta_ctyp _loc x2)
10081                           | Ast.TyAny x0 ->
10082                               Ast.PaApp (_loc,
10083                                 Ast.PaId (_loc,
10084                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10085                                     Ast.IdUid (_loc, "TyAny"))),
10086                                 meta_loc _loc x0)
10087                           | Ast.TyAli (x0, x1, x2) ->
10088                               Ast.PaApp (_loc,
10089                                 Ast.PaApp (_loc,
10090                                   Ast.PaApp (_loc,
10091                                     Ast.PaId (_loc,
10092                                       Ast.IdAcc (_loc,
10093                                         Ast.IdUid (_loc, "Ast"),
10094                                         Ast.IdUid (_loc, "TyAli"))),
10095                                     meta_loc _loc x0),
10096                                   meta_ctyp _loc x1),
10097                                 meta_ctyp _loc x2)
10098                           | Ast.TyNil x0 ->
10099                               Ast.PaApp (_loc,
10100                                 Ast.PaId (_loc,
10101                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10102                                     Ast.IdUid (_loc, "TyNil"))),
10103                                 meta_loc _loc x0)
10104                         and meta_expr _loc =
10105                           function
10106                           | Ast.ExWhi (x0, x1, x2) ->
10107                               Ast.PaApp (_loc,
10108                                 Ast.PaApp (_loc,
10109                                   Ast.PaApp (_loc,
10110                                     Ast.PaId (_loc,
10111                                       Ast.IdAcc (_loc,
10112                                         Ast.IdUid (_loc, "Ast"),
10113                                         Ast.IdUid (_loc, "ExWhi"))),
10114                                     meta_loc _loc x0),
10115                                   meta_expr _loc x1),
10116                                 meta_expr _loc x2)
10117                           | Ast.ExVrn (x0, x1) ->
10118                               Ast.PaApp (_loc,
10119                                 Ast.PaApp (_loc,
10120                                   Ast.PaId (_loc,
10121                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10122                                       Ast.IdUid (_loc, "ExVrn"))),
10123                                   meta_loc _loc x0),
10124                                 meta_string _loc x1)
10125                           | Ast.ExTyc (x0, x1, x2) ->
10126                               Ast.PaApp (_loc,
10127                                 Ast.PaApp (_loc,
10128                                   Ast.PaApp (_loc,
10129                                     Ast.PaId (_loc,
10130                                       Ast.IdAcc (_loc,
10131                                         Ast.IdUid (_loc, "Ast"),
10132                                         Ast.IdUid (_loc, "ExTyc"))),
10133                                     meta_loc _loc x0),
10134                                   meta_expr _loc x1),
10135                                 meta_ctyp _loc x2)
10136                           | Ast.ExCom (x0, x1, x2) ->
10137                               Ast.PaApp (_loc,
10138                                 Ast.PaApp (_loc,
10139                                   Ast.PaApp (_loc,
10140                                     Ast.PaId (_loc,
10141                                       Ast.IdAcc (_loc,
10142                                         Ast.IdUid (_loc, "Ast"),
10143                                         Ast.IdUid (_loc, "ExCom"))),
10144                                     meta_loc _loc x0),
10145                                   meta_expr _loc x1),
10146                                 meta_expr _loc x2)
10147                           | Ast.ExTup (x0, x1) ->
10148                               Ast.PaApp (_loc,
10149                                 Ast.PaApp (_loc,
10150                                   Ast.PaId (_loc,
10151                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10152                                       Ast.IdUid (_loc, "ExTup"))),
10153                                   meta_loc _loc x0),
10154                                 meta_expr _loc x1)
10155                           | Ast.ExTry (x0, x1, x2) ->
10156                               Ast.PaApp (_loc,
10157                                 Ast.PaApp (_loc,
10158                                   Ast.PaApp (_loc,
10159                                     Ast.PaId (_loc,
10160                                       Ast.IdAcc (_loc,
10161                                         Ast.IdUid (_loc, "Ast"),
10162                                         Ast.IdUid (_loc, "ExTry"))),
10163                                     meta_loc _loc x0),
10164                                   meta_expr _loc x1),
10165                                 meta_match_case _loc x2)
10166                           | Ast.ExStr (x0, x1) ->
10167                               Ast.PaApp (_loc,
10168                                 Ast.PaApp (_loc,
10169                                   Ast.PaId (_loc,
10170                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10171                                       Ast.IdUid (_loc, "ExStr"))),
10172                                   meta_loc _loc x0),
10173                                 meta_string _loc x1)
10174                           | Ast.ExSte (x0, x1, x2) ->
10175                               Ast.PaApp (_loc,
10176                                 Ast.PaApp (_loc,
10177                                   Ast.PaApp (_loc,
10178                                     Ast.PaId (_loc,
10179                                       Ast.IdAcc (_loc,
10180                                         Ast.IdUid (_loc, "Ast"),
10181                                         Ast.IdUid (_loc, "ExSte"))),
10182                                     meta_loc _loc x0),
10183                                   meta_expr _loc x1),
10184                                 meta_expr _loc x2)
10185                           | Ast.ExSnd (x0, x1, x2) ->
10186                               Ast.PaApp (_loc,
10187                                 Ast.PaApp (_loc,
10188                                   Ast.PaApp (_loc,
10189                                     Ast.PaId (_loc,
10190                                       Ast.IdAcc (_loc,
10191                                         Ast.IdUid (_loc, "Ast"),
10192                                         Ast.IdUid (_loc, "ExSnd"))),
10193                                     meta_loc _loc x0),
10194                                   meta_expr _loc x1),
10195                                 meta_string _loc x2)
10196                           | Ast.ExSeq (x0, x1) ->
10197                               Ast.PaApp (_loc,
10198                                 Ast.PaApp (_loc,
10199                                   Ast.PaId (_loc,
10200                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10201                                       Ast.IdUid (_loc, "ExSeq"))),
10202                                   meta_loc _loc x0),
10203                                 meta_expr _loc x1)
10204                           | Ast.ExRec (x0, x1, x2) ->
10205                               Ast.PaApp (_loc,
10206                                 Ast.PaApp (_loc,
10207                                   Ast.PaApp (_loc,
10208                                     Ast.PaId (_loc,
10209                                       Ast.IdAcc (_loc,
10210                                         Ast.IdUid (_loc, "Ast"),
10211                                         Ast.IdUid (_loc, "ExRec"))),
10212                                     meta_loc _loc x0),
10213                                   meta_rec_binding _loc x1),
10214                                 meta_expr _loc x2)
10215                           | Ast.ExOvr (x0, x1) ->
10216                               Ast.PaApp (_loc,
10217                                 Ast.PaApp (_loc,
10218                                   Ast.PaId (_loc,
10219                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10220                                       Ast.IdUid (_loc, "ExOvr"))),
10221                                   meta_loc _loc x0),
10222                                 meta_rec_binding _loc x1)
10223                           | Ast.ExOlb (x0, x1, x2) ->
10224                               Ast.PaApp (_loc,
10225                                 Ast.PaApp (_loc,
10226                                   Ast.PaApp (_loc,
10227                                     Ast.PaId (_loc,
10228                                       Ast.IdAcc (_loc,
10229                                         Ast.IdUid (_loc, "Ast"),
10230                                         Ast.IdUid (_loc, "ExOlb"))),
10231                                     meta_loc _loc x0),
10232                                   meta_string _loc x1),
10233                                 meta_expr _loc x2)
10234                           | Ast.ExObj (x0, x1, x2) ->
10235                               Ast.PaApp (_loc,
10236                                 Ast.PaApp (_loc,
10237                                   Ast.PaApp (_loc,
10238                                     Ast.PaId (_loc,
10239                                       Ast.IdAcc (_loc,
10240                                         Ast.IdUid (_loc, "Ast"),
10241                                         Ast.IdUid (_loc, "ExObj"))),
10242                                     meta_loc _loc x0),
10243                                   meta_patt _loc x1),
10244                                 meta_class_str_item _loc x2)
10245                           | Ast.ExNew (x0, x1) ->
10246                               Ast.PaApp (_loc,
10247                                 Ast.PaApp (_loc,
10248                                   Ast.PaId (_loc,
10249                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10250                                       Ast.IdUid (_loc, "ExNew"))),
10251                                   meta_loc _loc x0),
10252                                 meta_ident _loc x1)
10253                           | Ast.ExMat (x0, x1, x2) ->
10254                               Ast.PaApp (_loc,
10255                                 Ast.PaApp (_loc,
10256                                   Ast.PaApp (_loc,
10257                                     Ast.PaId (_loc,
10258                                       Ast.IdAcc (_loc,
10259                                         Ast.IdUid (_loc, "Ast"),
10260                                         Ast.IdUid (_loc, "ExMat"))),
10261                                     meta_loc _loc x0),
10262                                   meta_expr _loc x1),
10263                                 meta_match_case _loc x2)
10264                           | Ast.ExLmd (x0, x1, x2, x3) ->
10265                               Ast.PaApp (_loc,
10266                                 Ast.PaApp (_loc,
10267                                   Ast.PaApp (_loc,
10268                                     Ast.PaApp (_loc,
10269                                       Ast.PaId (_loc,
10270                                         Ast.IdAcc (_loc,
10271                                           Ast.IdUid (_loc, "Ast"),
10272                                           Ast.IdUid (_loc, "ExLmd"))),
10273                                       meta_loc _loc x0),
10274                                     meta_string _loc x1),
10275                                   meta_module_expr _loc x2),
10276                                 meta_expr _loc x3)
10277                           | Ast.ExLet (x0, x1, x2, x3) ->
10278                               Ast.PaApp (_loc,
10279                                 Ast.PaApp (_loc,
10280                                   Ast.PaApp (_loc,
10281                                     Ast.PaApp (_loc,
10282                                       Ast.PaId (_loc,
10283                                         Ast.IdAcc (_loc,
10284                                           Ast.IdUid (_loc, "Ast"),
10285                                           Ast.IdUid (_loc, "ExLet"))),
10286                                       meta_loc _loc x0),
10287                                     meta_meta_bool _loc x1),
10288                                   meta_binding _loc x2),
10289                                 meta_expr _loc x3)
10290                           | Ast.ExLaz (x0, x1) ->
10291                               Ast.PaApp (_loc,
10292                                 Ast.PaApp (_loc,
10293                                   Ast.PaId (_loc,
10294                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10295                                       Ast.IdUid (_loc, "ExLaz"))),
10296                                   meta_loc _loc x0),
10297                                 meta_expr _loc x1)
10298                           | Ast.ExLab (x0, x1, x2) ->
10299                               Ast.PaApp (_loc,
10300                                 Ast.PaApp (_loc,
10301                                   Ast.PaApp (_loc,
10302                                     Ast.PaId (_loc,
10303                                       Ast.IdAcc (_loc,
10304                                         Ast.IdUid (_loc, "Ast"),
10305                                         Ast.IdUid (_loc, "ExLab"))),
10306                                     meta_loc _loc x0),
10307                                   meta_string _loc x1),
10308                                 meta_expr _loc x2)
10309                           | Ast.ExNativeInt (x0, x1) ->
10310                               Ast.PaApp (_loc,
10311                                 Ast.PaApp (_loc,
10312                                   Ast.PaId (_loc,
10313                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10314                                       Ast.IdUid (_loc, "ExNativeInt"))),
10315                                   meta_loc _loc x0),
10316                                 meta_string _loc x1)
10317                           | Ast.ExInt64 (x0, x1) ->
10318                               Ast.PaApp (_loc,
10319                                 Ast.PaApp (_loc,
10320                                   Ast.PaId (_loc,
10321                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10322                                       Ast.IdUid (_loc, "ExInt64"))),
10323                                   meta_loc _loc x0),
10324                                 meta_string _loc x1)
10325                           | Ast.ExInt32 (x0, x1) ->
10326                               Ast.PaApp (_loc,
10327                                 Ast.PaApp (_loc,
10328                                   Ast.PaId (_loc,
10329                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10330                                       Ast.IdUid (_loc, "ExInt32"))),
10331                                   meta_loc _loc x0),
10332                                 meta_string _loc x1)
10333                           | Ast.ExInt (x0, x1) ->
10334                               Ast.PaApp (_loc,
10335                                 Ast.PaApp (_loc,
10336                                   Ast.PaId (_loc,
10337                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10338                                       Ast.IdUid (_loc, "ExInt"))),
10339                                   meta_loc _loc x0),
10340                                 meta_string _loc x1)
10341                           | Ast.ExIfe (x0, x1, x2, x3) ->
10342                               Ast.PaApp (_loc,
10343                                 Ast.PaApp (_loc,
10344                                   Ast.PaApp (_loc,
10345                                     Ast.PaApp (_loc,
10346                                       Ast.PaId (_loc,
10347                                         Ast.IdAcc (_loc,
10348                                           Ast.IdUid (_loc, "Ast"),
10349                                           Ast.IdUid (_loc, "ExIfe"))),
10350                                       meta_loc _loc x0),
10351                                     meta_expr _loc x1),
10352                                   meta_expr _loc x2),
10353                                 meta_expr _loc x3)
10354                           | Ast.ExFun (x0, x1) ->
10355                               Ast.PaApp (_loc,
10356                                 Ast.PaApp (_loc,
10357                                   Ast.PaId (_loc,
10358                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10359                                       Ast.IdUid (_loc, "ExFun"))),
10360                                   meta_loc _loc x0),
10361                                 meta_match_case _loc x1)
10362                           | Ast.ExFor (x0, x1, x2, x3, x4, x5) ->
10363                               Ast.PaApp (_loc,
10364                                 Ast.PaApp (_loc,
10365                                   Ast.PaApp (_loc,
10366                                     Ast.PaApp (_loc,
10367                                       Ast.PaApp (_loc,
10368                                         Ast.PaApp (_loc,
10369                                           Ast.PaId (_loc,
10370                                             Ast.IdAcc (_loc,
10371                                               Ast.IdUid (_loc, "Ast"),
10372                                               Ast.IdUid (_loc, "ExFor"))),
10373                                           meta_loc _loc x0),
10374                                         meta_string _loc x1),
10375                                       meta_expr _loc x2),
10376                                     meta_expr _loc x3),
10377                                   meta_meta_bool _loc x4),
10378                                 meta_expr _loc x5)
10379                           | Ast.ExFlo (x0, x1) ->
10380                               Ast.PaApp (_loc,
10381                                 Ast.PaApp (_loc,
10382                                   Ast.PaId (_loc,
10383                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10384                                       Ast.IdUid (_loc, "ExFlo"))),
10385                                   meta_loc _loc x0),
10386                                 meta_string _loc x1)
10387                           | Ast.ExCoe (x0, x1, x2, x3) ->
10388                               Ast.PaApp (_loc,
10389                                 Ast.PaApp (_loc,
10390                                   Ast.PaApp (_loc,
10391                                     Ast.PaApp (_loc,
10392                                       Ast.PaId (_loc,
10393                                         Ast.IdAcc (_loc,
10394                                           Ast.IdUid (_loc, "Ast"),
10395                                           Ast.IdUid (_loc, "ExCoe"))),
10396                                       meta_loc _loc x0),
10397                                     meta_expr _loc x1),
10398                                   meta_ctyp _loc x2),
10399                                 meta_ctyp _loc x3)
10400                           | Ast.ExChr (x0, x1) ->
10401                               Ast.PaApp (_loc,
10402                                 Ast.PaApp (_loc,
10403                                   Ast.PaId (_loc,
10404                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10405                                       Ast.IdUid (_loc, "ExChr"))),
10406                                   meta_loc _loc x0),
10407                                 meta_string _loc x1)
10408                           | Ast.ExAss (x0, x1, x2) ->
10409                               Ast.PaApp (_loc,
10410                                 Ast.PaApp (_loc,
10411                                   Ast.PaApp (_loc,
10412                                     Ast.PaId (_loc,
10413                                       Ast.IdAcc (_loc,
10414                                         Ast.IdUid (_loc, "Ast"),
10415                                         Ast.IdUid (_loc, "ExAss"))),
10416                                     meta_loc _loc x0),
10417                                   meta_expr _loc x1),
10418                                 meta_expr _loc x2)
10419                           | Ast.ExAsr (x0, x1) ->
10420                               Ast.PaApp (_loc,
10421                                 Ast.PaApp (_loc,
10422                                   Ast.PaId (_loc,
10423                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10424                                       Ast.IdUid (_loc, "ExAsr"))),
10425                                   meta_loc _loc x0),
10426                                 meta_expr _loc x1)
10427                           | Ast.ExAsf x0 ->
10428                               Ast.PaApp (_loc,
10429                                 Ast.PaId (_loc,
10430                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10431                                     Ast.IdUid (_loc, "ExAsf"))),
10432                                 meta_loc _loc x0)
10433                           | Ast.ExSem (x0, x1, x2) ->
10434                               Ast.PaApp (_loc,
10435                                 Ast.PaApp (_loc,
10436                                   Ast.PaApp (_loc,
10437                                     Ast.PaId (_loc,
10438                                       Ast.IdAcc (_loc,
10439                                         Ast.IdUid (_loc, "Ast"),
10440                                         Ast.IdUid (_loc, "ExSem"))),
10441                                     meta_loc _loc x0),
10442                                   meta_expr _loc x1),
10443                                 meta_expr _loc x2)
10444                           | Ast.ExArr (x0, x1) ->
10445                               Ast.PaApp (_loc,
10446                                 Ast.PaApp (_loc,
10447                                   Ast.PaId (_loc,
10448                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10449                                       Ast.IdUid (_loc, "ExArr"))),
10450                                   meta_loc _loc x0),
10451                                 meta_expr _loc x1)
10452                           | Ast.ExAre (x0, x1, x2) ->
10453                               Ast.PaApp (_loc,
10454                                 Ast.PaApp (_loc,
10455                                   Ast.PaApp (_loc,
10456                                     Ast.PaId (_loc,
10457                                       Ast.IdAcc (_loc,
10458                                         Ast.IdUid (_loc, "Ast"),
10459                                         Ast.IdUid (_loc, "ExAre"))),
10460                                     meta_loc _loc x0),
10461                                   meta_expr _loc x1),
10462                                 meta_expr _loc x2)
10463                           | Ast.ExApp (x0, x1, x2) ->
10464                               Ast.PaApp (_loc,
10465                                 Ast.PaApp (_loc,
10466                                   Ast.PaApp (_loc,
10467                                     Ast.PaId (_loc,
10468                                       Ast.IdAcc (_loc,
10469                                         Ast.IdUid (_loc, "Ast"),
10470                                         Ast.IdUid (_loc, "ExApp"))),
10471                                     meta_loc _loc x0),
10472                                   meta_expr _loc x1),
10473                                 meta_expr _loc x2)
10474                           | Ast.ExAnt (x0, x1) -> Ast.PaAnt (x0, x1)
10475                           | Ast.ExAcc (x0, x1, x2) ->
10476                               Ast.PaApp (_loc,
10477                                 Ast.PaApp (_loc,
10478                                   Ast.PaApp (_loc,
10479                                     Ast.PaId (_loc,
10480                                       Ast.IdAcc (_loc,
10481                                         Ast.IdUid (_loc, "Ast"),
10482                                         Ast.IdUid (_loc, "ExAcc"))),
10483                                     meta_loc _loc x0),
10484                                   meta_expr _loc x1),
10485                                 meta_expr _loc x2)
10486                           | Ast.ExId (x0, x1) ->
10487                               Ast.PaApp (_loc,
10488                                 Ast.PaApp (_loc,
10489                                   Ast.PaId (_loc,
10490                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10491                                       Ast.IdUid (_loc, "ExId"))),
10492                                   meta_loc _loc x0),
10493                                 meta_ident _loc x1)
10494                           | Ast.ExNil x0 ->
10495                               Ast.PaApp (_loc,
10496                                 Ast.PaId (_loc,
10497                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10498                                     Ast.IdUid (_loc, "ExNil"))),
10499                                 meta_loc _loc x0)
10500                         and meta_ident _loc =
10501                           function
10502                           | Ast.IdAnt (x0, x1) -> Ast.PaAnt (x0, x1)
10503                           | Ast.IdUid (x0, x1) ->
10504                               Ast.PaApp (_loc,
10505                                 Ast.PaApp (_loc,
10506                                   Ast.PaId (_loc,
10507                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10508                                       Ast.IdUid (_loc, "IdUid"))),
10509                                   meta_loc _loc x0),
10510                                 meta_string _loc x1)
10511                           | Ast.IdLid (x0, x1) ->
10512                               Ast.PaApp (_loc,
10513                                 Ast.PaApp (_loc,
10514                                   Ast.PaId (_loc,
10515                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10516                                       Ast.IdUid (_loc, "IdLid"))),
10517                                   meta_loc _loc x0),
10518                                 meta_string _loc x1)
10519                           | Ast.IdApp (x0, x1, x2) ->
10520                               Ast.PaApp (_loc,
10521                                 Ast.PaApp (_loc,
10522                                   Ast.PaApp (_loc,
10523                                     Ast.PaId (_loc,
10524                                       Ast.IdAcc (_loc,
10525                                         Ast.IdUid (_loc, "Ast"),
10526                                         Ast.IdUid (_loc, "IdApp"))),
10527                                     meta_loc _loc x0),
10528                                   meta_ident _loc x1),
10529                                 meta_ident _loc x2)
10530                           | Ast.IdAcc (x0, x1, x2) ->
10531                               Ast.PaApp (_loc,
10532                                 Ast.PaApp (_loc,
10533                                   Ast.PaApp (_loc,
10534                                     Ast.PaId (_loc,
10535                                       Ast.IdAcc (_loc,
10536                                         Ast.IdUid (_loc, "Ast"),
10537                                         Ast.IdUid (_loc, "IdAcc"))),
10538                                     meta_loc _loc x0),
10539                                   meta_ident _loc x1),
10540                                 meta_ident _loc x2)
10541                         and meta_match_case _loc =
10542                           function
10543                           | Ast.McAnt (x0, x1) -> Ast.PaAnt (x0, x1)
10544                           | Ast.McArr (x0, x1, x2, x3) ->
10545                               Ast.PaApp (_loc,
10546                                 Ast.PaApp (_loc,
10547                                   Ast.PaApp (_loc,
10548                                     Ast.PaApp (_loc,
10549                                       Ast.PaId (_loc,
10550                                         Ast.IdAcc (_loc,
10551                                           Ast.IdUid (_loc, "Ast"),
10552                                           Ast.IdUid (_loc, "McArr"))),
10553                                       meta_loc _loc x0),
10554                                     meta_patt _loc x1),
10555                                   meta_expr _loc x2),
10556                                 meta_expr _loc x3)
10557                           | Ast.McOr (x0, x1, x2) ->
10558                               Ast.PaApp (_loc,
10559                                 Ast.PaApp (_loc,
10560                                   Ast.PaApp (_loc,
10561                                     Ast.PaId (_loc,
10562                                       Ast.IdAcc (_loc,
10563                                         Ast.IdUid (_loc, "Ast"),
10564                                         Ast.IdUid (_loc, "McOr"))),
10565                                     meta_loc _loc x0),
10566                                   meta_match_case _loc x1),
10567                                 meta_match_case _loc x2)
10568                           | Ast.McNil x0 ->
10569                               Ast.PaApp (_loc,
10570                                 Ast.PaId (_loc,
10571                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10572                                     Ast.IdUid (_loc, "McNil"))),
10573                                 meta_loc _loc x0)
10574                         and meta_meta_bool _loc =
10575                           function
10576                           | Ast.BAnt x0 -> Ast.PaAnt (_loc, x0)
10577                           | Ast.BFalse ->
10578                               Ast.PaId (_loc,
10579                                 Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10580                                   Ast.IdUid (_loc, "BFalse")))
10581                           | Ast.BTrue ->
10582                               Ast.PaId (_loc,
10583                                 Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10584                                   Ast.IdUid (_loc, "BTrue")))
10585                         and meta_meta_list mf_a _loc =
10586                           function
10587                           | Ast.LAnt x0 -> Ast.PaAnt (_loc, x0)
10588                           | Ast.LCons (x0, x1) ->
10589                               Ast.PaApp (_loc,
10590                                 Ast.PaApp (_loc,
10591                                   Ast.PaId (_loc,
10592                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10593                                       Ast.IdUid (_loc, "LCons"))),
10594                                   mf_a _loc x0),
10595                                 meta_meta_list mf_a _loc x1)
10596                           | Ast.LNil ->
10597                               Ast.PaId (_loc,
10598                                 Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10599                                   Ast.IdUid (_loc, "LNil")))
10600                         and meta_meta_option mf_a _loc =
10601                           function
10602                           | Ast.OAnt x0 -> Ast.PaAnt (_loc, x0)
10603                           | Ast.OSome x0 ->
10604                               Ast.PaApp (_loc,
10605                                 Ast.PaId (_loc,
10606                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10607                                     Ast.IdUid (_loc, "OSome"))),
10608                                 mf_a _loc x0)
10609                           | Ast.ONone ->
10610                               Ast.PaId (_loc,
10611                                 Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10612                                   Ast.IdUid (_loc, "ONone")))
10613                         and meta_module_binding _loc =
10614                           function
10615                           | Ast.MbAnt (x0, x1) -> Ast.PaAnt (x0, x1)
10616                           | Ast.MbCol (x0, x1, x2) ->
10617                               Ast.PaApp (_loc,
10618                                 Ast.PaApp (_loc,
10619                                   Ast.PaApp (_loc,
10620                                     Ast.PaId (_loc,
10621                                       Ast.IdAcc (_loc,
10622                                         Ast.IdUid (_loc, "Ast"),
10623                                         Ast.IdUid (_loc, "MbCol"))),
10624                                     meta_loc _loc x0),
10625                                   meta_string _loc x1),
10626                                 meta_module_type _loc x2)
10627                           | Ast.MbColEq (x0, x1, x2, x3) ->
10628                               Ast.PaApp (_loc,
10629                                 Ast.PaApp (_loc,
10630                                   Ast.PaApp (_loc,
10631                                     Ast.PaApp (_loc,
10632                                       Ast.PaId (_loc,
10633                                         Ast.IdAcc (_loc,
10634                                           Ast.IdUid (_loc, "Ast"),
10635                                           Ast.IdUid (_loc, "MbColEq"))),
10636                                       meta_loc _loc x0),
10637                                     meta_string _loc x1),
10638                                   meta_module_type _loc x2),
10639                                 meta_module_expr _loc x3)
10640                           | Ast.MbAnd (x0, x1, x2) ->
10641                               Ast.PaApp (_loc,
10642                                 Ast.PaApp (_loc,
10643                                   Ast.PaApp (_loc,
10644                                     Ast.PaId (_loc,
10645                                       Ast.IdAcc (_loc,
10646                                         Ast.IdUid (_loc, "Ast"),
10647                                         Ast.IdUid (_loc, "MbAnd"))),
10648                                     meta_loc _loc x0),
10649                                   meta_module_binding _loc x1),
10650                                 meta_module_binding _loc x2)
10651                           | Ast.MbNil x0 ->
10652                               Ast.PaApp (_loc,
10653                                 Ast.PaId (_loc,
10654                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10655                                     Ast.IdUid (_loc, "MbNil"))),
10656                                 meta_loc _loc x0)
10657                         and meta_module_expr _loc =
10658                           function
10659                           | Ast.MeAnt (x0, x1) -> Ast.PaAnt (x0, x1)
10660                           | Ast.MeTyc (x0, x1, x2) ->
10661                               Ast.PaApp (_loc,
10662                                 Ast.PaApp (_loc,
10663                                   Ast.PaApp (_loc,
10664                                     Ast.PaId (_loc,
10665                                       Ast.IdAcc (_loc,
10666                                         Ast.IdUid (_loc, "Ast"),
10667                                         Ast.IdUid (_loc, "MeTyc"))),
10668                                     meta_loc _loc x0),
10669                                   meta_module_expr _loc x1),
10670                                 meta_module_type _loc x2)
10671                           | Ast.MeStr (x0, x1) ->
10672                               Ast.PaApp (_loc,
10673                                 Ast.PaApp (_loc,
10674                                   Ast.PaId (_loc,
10675                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10676                                       Ast.IdUid (_loc, "MeStr"))),
10677                                   meta_loc _loc x0),
10678                                 meta_str_item _loc x1)
10679                           | Ast.MeFun (x0, x1, x2, x3) ->
10680                               Ast.PaApp (_loc,
10681                                 Ast.PaApp (_loc,
10682                                   Ast.PaApp (_loc,
10683                                     Ast.PaApp (_loc,
10684                                       Ast.PaId (_loc,
10685                                         Ast.IdAcc (_loc,
10686                                           Ast.IdUid (_loc, "Ast"),
10687                                           Ast.IdUid (_loc, "MeFun"))),
10688                                       meta_loc _loc x0),
10689                                     meta_string _loc x1),
10690                                   meta_module_type _loc x2),
10691                                 meta_module_expr _loc x3)
10692                           | Ast.MeApp (x0, x1, x2) ->
10693                               Ast.PaApp (_loc,
10694                                 Ast.PaApp (_loc,
10695                                   Ast.PaApp (_loc,
10696                                     Ast.PaId (_loc,
10697                                       Ast.IdAcc (_loc,
10698                                         Ast.IdUid (_loc, "Ast"),
10699                                         Ast.IdUid (_loc, "MeApp"))),
10700                                     meta_loc _loc x0),
10701                                   meta_module_expr _loc x1),
10702                                 meta_module_expr _loc x2)
10703                           | Ast.MeId (x0, x1) ->
10704                               Ast.PaApp (_loc,
10705                                 Ast.PaApp (_loc,
10706                                   Ast.PaId (_loc,
10707                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10708                                       Ast.IdUid (_loc, "MeId"))),
10709                                   meta_loc _loc x0),
10710                                 meta_ident _loc x1)
10711                           | Ast.MeNil x0 ->
10712                               Ast.PaApp (_loc,
10713                                 Ast.PaId (_loc,
10714                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10715                                     Ast.IdUid (_loc, "MeNil"))),
10716                                 meta_loc _loc x0)
10717                         and meta_module_type _loc =
10718                           function
10719                           | Ast.MtAnt (x0, x1) -> Ast.PaAnt (x0, x1)
10720                           | Ast.MtWit (x0, x1, x2) ->
10721                               Ast.PaApp (_loc,
10722                                 Ast.PaApp (_loc,
10723                                   Ast.PaApp (_loc,
10724                                     Ast.PaId (_loc,
10725                                       Ast.IdAcc (_loc,
10726                                         Ast.IdUid (_loc, "Ast"),
10727                                         Ast.IdUid (_loc, "MtWit"))),
10728                                     meta_loc _loc x0),
10729                                   meta_module_type _loc x1),
10730                                 meta_with_constr _loc x2)
10731                           | Ast.MtSig (x0, x1) ->
10732                               Ast.PaApp (_loc,
10733                                 Ast.PaApp (_loc,
10734                                   Ast.PaId (_loc,
10735                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10736                                       Ast.IdUid (_loc, "MtSig"))),
10737                                   meta_loc _loc x0),
10738                                 meta_sig_item _loc x1)
10739                           | Ast.MtQuo (x0, x1) ->
10740                               Ast.PaApp (_loc,
10741                                 Ast.PaApp (_loc,
10742                                   Ast.PaId (_loc,
10743                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10744                                       Ast.IdUid (_loc, "MtQuo"))),
10745                                   meta_loc _loc x0),
10746                                 meta_string _loc x1)
10747                           | Ast.MtFun (x0, x1, x2, x3) ->
10748                               Ast.PaApp (_loc,
10749                                 Ast.PaApp (_loc,
10750                                   Ast.PaApp (_loc,
10751                                     Ast.PaApp (_loc,
10752                                       Ast.PaId (_loc,
10753                                         Ast.IdAcc (_loc,
10754                                           Ast.IdUid (_loc, "Ast"),
10755                                           Ast.IdUid (_loc, "MtFun"))),
10756                                       meta_loc _loc x0),
10757                                     meta_string _loc x1),
10758                                   meta_module_type _loc x2),
10759                                 meta_module_type _loc x3)
10760                           | Ast.MtId (x0, x1) ->
10761                               Ast.PaApp (_loc,
10762                                 Ast.PaApp (_loc,
10763                                   Ast.PaId (_loc,
10764                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10765                                       Ast.IdUid (_loc, "MtId"))),
10766                                   meta_loc _loc x0),
10767                                 meta_ident _loc x1)
10768                           | Ast.MtNil x0 ->
10769                               Ast.PaApp (_loc,
10770                                 Ast.PaId (_loc,
10771                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10772                                     Ast.IdUid (_loc, "MtNil"))),
10773                                 meta_loc _loc x0)
10774                         and meta_patt _loc =
10775                           function
10776                           | Ast.PaLaz (x0, x1) ->
10777                               Ast.PaApp (_loc,
10778                                 Ast.PaApp (_loc,
10779                                   Ast.PaId (_loc,
10780                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10781                                       Ast.IdUid (_loc, "PaLaz"))),
10782                                   meta_loc _loc x0),
10783                                 meta_patt _loc x1)
10784                           | Ast.PaVrn (x0, x1) ->
10785                               Ast.PaApp (_loc,
10786                                 Ast.PaApp (_loc,
10787                                   Ast.PaId (_loc,
10788                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10789                                       Ast.IdUid (_loc, "PaVrn"))),
10790                                   meta_loc _loc x0),
10791                                 meta_string _loc x1)
10792                           | Ast.PaTyp (x0, x1) ->
10793                               Ast.PaApp (_loc,
10794                                 Ast.PaApp (_loc,
10795                                   Ast.PaId (_loc,
10796                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10797                                       Ast.IdUid (_loc, "PaTyp"))),
10798                                   meta_loc _loc x0),
10799                                 meta_ident _loc x1)
10800                           | Ast.PaTyc (x0, x1, x2) ->
10801                               Ast.PaApp (_loc,
10802                                 Ast.PaApp (_loc,
10803                                   Ast.PaApp (_loc,
10804                                     Ast.PaId (_loc,
10805                                       Ast.IdAcc (_loc,
10806                                         Ast.IdUid (_loc, "Ast"),
10807                                         Ast.IdUid (_loc, "PaTyc"))),
10808                                     meta_loc _loc x0),
10809                                   meta_patt _loc x1),
10810                                 meta_ctyp _loc x2)
10811                           | Ast.PaTup (x0, x1) ->
10812                               Ast.PaApp (_loc,
10813                                 Ast.PaApp (_loc,
10814                                   Ast.PaId (_loc,
10815                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10816                                       Ast.IdUid (_loc, "PaTup"))),
10817                                   meta_loc _loc x0),
10818                                 meta_patt _loc x1)
10819                           | Ast.PaStr (x0, x1) ->
10820                               Ast.PaApp (_loc,
10821                                 Ast.PaApp (_loc,
10822                                   Ast.PaId (_loc,
10823                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10824                                       Ast.IdUid (_loc, "PaStr"))),
10825                                   meta_loc _loc x0),
10826                                 meta_string _loc x1)
10827                           | Ast.PaEq (x0, x1, x2) ->
10828                               Ast.PaApp (_loc,
10829                                 Ast.PaApp (_loc,
10830                                   Ast.PaApp (_loc,
10831                                     Ast.PaId (_loc,
10832                                       Ast.IdAcc (_loc,
10833                                         Ast.IdUid (_loc, "Ast"),
10834                                         Ast.IdUid (_loc, "PaEq"))),
10835                                     meta_loc _loc x0),
10836                                   meta_ident _loc x1),
10837                                 meta_patt _loc x2)
10838                           | Ast.PaRec (x0, x1) ->
10839                               Ast.PaApp (_loc,
10840                                 Ast.PaApp (_loc,
10841                                   Ast.PaId (_loc,
10842                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10843                                       Ast.IdUid (_loc, "PaRec"))),
10844                                   meta_loc _loc x0),
10845                                 meta_patt _loc x1)
10846                           | Ast.PaRng (x0, x1, x2) ->
10847                               Ast.PaApp (_loc,
10848                                 Ast.PaApp (_loc,
10849                                   Ast.PaApp (_loc,
10850                                     Ast.PaId (_loc,
10851                                       Ast.IdAcc (_loc,
10852                                         Ast.IdUid (_loc, "Ast"),
10853                                         Ast.IdUid (_loc, "PaRng"))),
10854                                     meta_loc _loc x0),
10855                                   meta_patt _loc x1),
10856                                 meta_patt _loc x2)
10857                           | Ast.PaOrp (x0, x1, x2) ->
10858                               Ast.PaApp (_loc,
10859                                 Ast.PaApp (_loc,
10860                                   Ast.PaApp (_loc,
10861                                     Ast.PaId (_loc,
10862                                       Ast.IdAcc (_loc,
10863                                         Ast.IdUid (_loc, "Ast"),
10864                                         Ast.IdUid (_loc, "PaOrp"))),
10865                                     meta_loc _loc x0),
10866                                   meta_patt _loc x1),
10867                                 meta_patt _loc x2)
10868                           | Ast.PaOlbi (x0, x1, x2, x3) ->
10869                               Ast.PaApp (_loc,
10870                                 Ast.PaApp (_loc,
10871                                   Ast.PaApp (_loc,
10872                                     Ast.PaApp (_loc,
10873                                       Ast.PaId (_loc,
10874                                         Ast.IdAcc (_loc,
10875                                           Ast.IdUid (_loc, "Ast"),
10876                                           Ast.IdUid (_loc, "PaOlbi"))),
10877                                       meta_loc _loc x0),
10878                                     meta_string _loc x1),
10879                                   meta_patt _loc x2),
10880                                 meta_expr _loc x3)
10881                           | Ast.PaOlb (x0, x1, x2) ->
10882                               Ast.PaApp (_loc,
10883                                 Ast.PaApp (_loc,
10884                                   Ast.PaApp (_loc,
10885                                     Ast.PaId (_loc,
10886                                       Ast.IdAcc (_loc,
10887                                         Ast.IdUid (_loc, "Ast"),
10888                                         Ast.IdUid (_loc, "PaOlb"))),
10889                                     meta_loc _loc x0),
10890                                   meta_string _loc x1),
10891                                 meta_patt _loc x2)
10892                           | Ast.PaLab (x0, x1, x2) ->
10893                               Ast.PaApp (_loc,
10894                                 Ast.PaApp (_loc,
10895                                   Ast.PaApp (_loc,
10896                                     Ast.PaId (_loc,
10897                                       Ast.IdAcc (_loc,
10898                                         Ast.IdUid (_loc, "Ast"),
10899                                         Ast.IdUid (_loc, "PaLab"))),
10900                                     meta_loc _loc x0),
10901                                   meta_string _loc x1),
10902                                 meta_patt _loc x2)
10903                           | Ast.PaFlo (x0, x1) ->
10904                               Ast.PaApp (_loc,
10905                                 Ast.PaApp (_loc,
10906                                   Ast.PaId (_loc,
10907                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10908                                       Ast.IdUid (_loc, "PaFlo"))),
10909                                   meta_loc _loc x0),
10910                                 meta_string _loc x1)
10911                           | Ast.PaNativeInt (x0, x1) ->
10912                               Ast.PaApp (_loc,
10913                                 Ast.PaApp (_loc,
10914                                   Ast.PaId (_loc,
10915                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10916                                       Ast.IdUid (_loc, "PaNativeInt"))),
10917                                   meta_loc _loc x0),
10918                                 meta_string _loc x1)
10919                           | Ast.PaInt64 (x0, x1) ->
10920                               Ast.PaApp (_loc,
10921                                 Ast.PaApp (_loc,
10922                                   Ast.PaId (_loc,
10923                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10924                                       Ast.IdUid (_loc, "PaInt64"))),
10925                                   meta_loc _loc x0),
10926                                 meta_string _loc x1)
10927                           | Ast.PaInt32 (x0, x1) ->
10928                               Ast.PaApp (_loc,
10929                                 Ast.PaApp (_loc,
10930                                   Ast.PaId (_loc,
10931                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10932                                       Ast.IdUid (_loc, "PaInt32"))),
10933                                   meta_loc _loc x0),
10934                                 meta_string _loc x1)
10935                           | Ast.PaInt (x0, x1) ->
10936                               Ast.PaApp (_loc,
10937                                 Ast.PaApp (_loc,
10938                                   Ast.PaId (_loc,
10939                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10940                                       Ast.IdUid (_loc, "PaInt"))),
10941                                   meta_loc _loc x0),
10942                                 meta_string _loc x1)
10943                           | Ast.PaChr (x0, x1) ->
10944                               Ast.PaApp (_loc,
10945                                 Ast.PaApp (_loc,
10946                                   Ast.PaId (_loc,
10947                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10948                                       Ast.IdUid (_loc, "PaChr"))),
10949                                   meta_loc _loc x0),
10950                                 meta_string _loc x1)
10951                           | Ast.PaSem (x0, x1, x2) ->
10952                               Ast.PaApp (_loc,
10953                                 Ast.PaApp (_loc,
10954                                   Ast.PaApp (_loc,
10955                                     Ast.PaId (_loc,
10956                                       Ast.IdAcc (_loc,
10957                                         Ast.IdUid (_loc, "Ast"),
10958                                         Ast.IdUid (_loc, "PaSem"))),
10959                                     meta_loc _loc x0),
10960                                   meta_patt _loc x1),
10961                                 meta_patt _loc x2)
10962                           | Ast.PaCom (x0, x1, x2) ->
10963                               Ast.PaApp (_loc,
10964                                 Ast.PaApp (_loc,
10965                                   Ast.PaApp (_loc,
10966                                     Ast.PaId (_loc,
10967                                       Ast.IdAcc (_loc,
10968                                         Ast.IdUid (_loc, "Ast"),
10969                                         Ast.IdUid (_loc, "PaCom"))),
10970                                     meta_loc _loc x0),
10971                                   meta_patt _loc x1),
10972                                 meta_patt _loc x2)
10973                           | Ast.PaArr (x0, x1) ->
10974                               Ast.PaApp (_loc,
10975                                 Ast.PaApp (_loc,
10976                                   Ast.PaId (_loc,
10977                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10978                                       Ast.IdUid (_loc, "PaArr"))),
10979                                   meta_loc _loc x0),
10980                                 meta_patt _loc x1)
10981                           | Ast.PaApp (x0, x1, x2) ->
10982                               Ast.PaApp (_loc,
10983                                 Ast.PaApp (_loc,
10984                                   Ast.PaApp (_loc,
10985                                     Ast.PaId (_loc,
10986                                       Ast.IdAcc (_loc,
10987                                         Ast.IdUid (_loc, "Ast"),
10988                                         Ast.IdUid (_loc, "PaApp"))),
10989                                     meta_loc _loc x0),
10990                                   meta_patt _loc x1),
10991                                 meta_patt _loc x2)
10992                           | Ast.PaAny x0 ->
10993                               Ast.PaApp (_loc,
10994                                 Ast.PaId (_loc,
10995                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
10996                                     Ast.IdUid (_loc, "PaAny"))),
10997                                 meta_loc _loc x0)
10998                           | Ast.PaAnt (x0, x1) -> Ast.PaAnt (x0, x1)
10999                           | Ast.PaAli (x0, x1, x2) ->
11000                               Ast.PaApp (_loc,
11001                                 Ast.PaApp (_loc,
11002                                   Ast.PaApp (_loc,
11003                                     Ast.PaId (_loc,
11004                                       Ast.IdAcc (_loc,
11005                                         Ast.IdUid (_loc, "Ast"),
11006                                         Ast.IdUid (_loc, "PaAli"))),
11007                                     meta_loc _loc x0),
11008                                   meta_patt _loc x1),
11009                                 meta_patt _loc x2)
11010                           | Ast.PaId (x0, x1) ->
11011                               Ast.PaApp (_loc,
11012                                 Ast.PaApp (_loc,
11013                                   Ast.PaId (_loc,
11014                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11015                                       Ast.IdUid (_loc, "PaId"))),
11016                                   meta_loc _loc x0),
11017                                 meta_ident _loc x1)
11018                           | Ast.PaNil x0 ->
11019                               Ast.PaApp (_loc,
11020                                 Ast.PaId (_loc,
11021                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11022                                     Ast.IdUid (_loc, "PaNil"))),
11023                                 meta_loc _loc x0)
11024                         and meta_rec_binding _loc =
11025                           function
11026                           | Ast.RbAnt (x0, x1) -> Ast.PaAnt (x0, x1)
11027                           | Ast.RbEq (x0, x1, x2) ->
11028                               Ast.PaApp (_loc,
11029                                 Ast.PaApp (_loc,
11030                                   Ast.PaApp (_loc,
11031                                     Ast.PaId (_loc,
11032                                       Ast.IdAcc (_loc,
11033                                         Ast.IdUid (_loc, "Ast"),
11034                                         Ast.IdUid (_loc, "RbEq"))),
11035                                     meta_loc _loc x0),
11036                                   meta_ident _loc x1),
11037                                 meta_expr _loc x2)
11038                           | Ast.RbSem (x0, x1, x2) ->
11039                               Ast.PaApp (_loc,
11040                                 Ast.PaApp (_loc,
11041                                   Ast.PaApp (_loc,
11042                                     Ast.PaId (_loc,
11043                                       Ast.IdAcc (_loc,
11044                                         Ast.IdUid (_loc, "Ast"),
11045                                         Ast.IdUid (_loc, "RbSem"))),
11046                                     meta_loc _loc x0),
11047                                   meta_rec_binding _loc x1),
11048                                 meta_rec_binding _loc x2)
11049                           | Ast.RbNil x0 ->
11050                               Ast.PaApp (_loc,
11051                                 Ast.PaId (_loc,
11052                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11053                                     Ast.IdUid (_loc, "RbNil"))),
11054                                 meta_loc _loc x0)
11055                         and meta_sig_item _loc =
11056                           function
11057                           | Ast.SgAnt (x0, x1) -> Ast.PaAnt (x0, x1)
11058                           | Ast.SgVal (x0, x1, x2) ->
11059                               Ast.PaApp (_loc,
11060                                 Ast.PaApp (_loc,
11061                                   Ast.PaApp (_loc,
11062                                     Ast.PaId (_loc,
11063                                       Ast.IdAcc (_loc,
11064                                         Ast.IdUid (_loc, "Ast"),
11065                                         Ast.IdUid (_loc, "SgVal"))),
11066                                     meta_loc _loc x0),
11067                                   meta_string _loc x1),
11068                                 meta_ctyp _loc x2)
11069                           | Ast.SgTyp (x0, x1) ->
11070                               Ast.PaApp (_loc,
11071                                 Ast.PaApp (_loc,
11072                                   Ast.PaId (_loc,
11073                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11074                                       Ast.IdUid (_loc, "SgTyp"))),
11075                                   meta_loc _loc x0),
11076                                 meta_ctyp _loc x1)
11077                           | Ast.SgOpn (x0, x1) ->
11078                               Ast.PaApp (_loc,
11079                                 Ast.PaApp (_loc,
11080                                   Ast.PaId (_loc,
11081                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11082                                       Ast.IdUid (_loc, "SgOpn"))),
11083                                   meta_loc _loc x0),
11084                                 meta_ident _loc x1)
11085                           | Ast.SgMty (x0, x1, x2) ->
11086                               Ast.PaApp (_loc,
11087                                 Ast.PaApp (_loc,
11088                                   Ast.PaApp (_loc,
11089                                     Ast.PaId (_loc,
11090                                       Ast.IdAcc (_loc,
11091                                         Ast.IdUid (_loc, "Ast"),
11092                                         Ast.IdUid (_loc, "SgMty"))),
11093                                     meta_loc _loc x0),
11094                                   meta_string _loc x1),
11095                                 meta_module_type _loc x2)
11096                           | Ast.SgRecMod (x0, x1) ->
11097                               Ast.PaApp (_loc,
11098                                 Ast.PaApp (_loc,
11099                                   Ast.PaId (_loc,
11100                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11101                                       Ast.IdUid (_loc, "SgRecMod"))),
11102                                   meta_loc _loc x0),
11103                                 meta_module_binding _loc x1)
11104                           | Ast.SgMod (x0, x1, x2) ->
11105                               Ast.PaApp (_loc,
11106                                 Ast.PaApp (_loc,
11107                                   Ast.PaApp (_loc,
11108                                     Ast.PaId (_loc,
11109                                       Ast.IdAcc (_loc,
11110                                         Ast.IdUid (_loc, "Ast"),
11111                                         Ast.IdUid (_loc, "SgMod"))),
11112                                     meta_loc _loc x0),
11113                                   meta_string _loc x1),
11114                                 meta_module_type _loc x2)
11115                           | Ast.SgInc (x0, x1) ->
11116                               Ast.PaApp (_loc,
11117                                 Ast.PaApp (_loc,
11118                                   Ast.PaId (_loc,
11119                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11120                                       Ast.IdUid (_loc, "SgInc"))),
11121                                   meta_loc _loc x0),
11122                                 meta_module_type _loc x1)
11123                           | Ast.SgExt (x0, x1, x2, x3) ->
11124                               Ast.PaApp (_loc,
11125                                 Ast.PaApp (_loc,
11126                                   Ast.PaApp (_loc,
11127                                     Ast.PaApp (_loc,
11128                                       Ast.PaId (_loc,
11129                                         Ast.IdAcc (_loc,
11130                                           Ast.IdUid (_loc, "Ast"),
11131                                           Ast.IdUid (_loc, "SgExt"))),
11132                                       meta_loc _loc x0),
11133                                     meta_string _loc x1),
11134                                   meta_ctyp _loc x2),
11135                                 meta_meta_list meta_string _loc x3)
11136                           | Ast.SgExc (x0, x1) ->
11137                               Ast.PaApp (_loc,
11138                                 Ast.PaApp (_loc,
11139                                   Ast.PaId (_loc,
11140                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11141                                       Ast.IdUid (_loc, "SgExc"))),
11142                                   meta_loc _loc x0),
11143                                 meta_ctyp _loc x1)
11144                           | Ast.SgDir (x0, x1, x2) ->
11145                               Ast.PaApp (_loc,
11146                                 Ast.PaApp (_loc,
11147                                   Ast.PaApp (_loc,
11148                                     Ast.PaId (_loc,
11149                                       Ast.IdAcc (_loc,
11150                                         Ast.IdUid (_loc, "Ast"),
11151                                         Ast.IdUid (_loc, "SgDir"))),
11152                                     meta_loc _loc x0),
11153                                   meta_string _loc x1),
11154                                 meta_expr _loc x2)
11155                           | Ast.SgSem (x0, x1, x2) ->
11156                               Ast.PaApp (_loc,
11157                                 Ast.PaApp (_loc,
11158                                   Ast.PaApp (_loc,
11159                                     Ast.PaId (_loc,
11160                                       Ast.IdAcc (_loc,
11161                                         Ast.IdUid (_loc, "Ast"),
11162                                         Ast.IdUid (_loc, "SgSem"))),
11163                                     meta_loc _loc x0),
11164                                   meta_sig_item _loc x1),
11165                                 meta_sig_item _loc x2)
11166                           | Ast.SgClt (x0, x1) ->
11167                               Ast.PaApp (_loc,
11168                                 Ast.PaApp (_loc,
11169                                   Ast.PaId (_loc,
11170                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11171                                       Ast.IdUid (_loc, "SgClt"))),
11172                                   meta_loc _loc x0),
11173                                 meta_class_type _loc x1)
11174                           | Ast.SgCls (x0, x1) ->
11175                               Ast.PaApp (_loc,
11176                                 Ast.PaApp (_loc,
11177                                   Ast.PaId (_loc,
11178                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11179                                       Ast.IdUid (_loc, "SgCls"))),
11180                                   meta_loc _loc x0),
11181                                 meta_class_type _loc x1)
11182                           | Ast.SgNil x0 ->
11183                               Ast.PaApp (_loc,
11184                                 Ast.PaId (_loc,
11185                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11186                                     Ast.IdUid (_loc, "SgNil"))),
11187                                 meta_loc _loc x0)
11188                         and meta_str_item _loc =
11189                           function
11190                           | Ast.StAnt (x0, x1) -> Ast.PaAnt (x0, x1)
11191                           | Ast.StVal (x0, x1, x2) ->
11192                               Ast.PaApp (_loc,
11193                                 Ast.PaApp (_loc,
11194                                   Ast.PaApp (_loc,
11195                                     Ast.PaId (_loc,
11196                                       Ast.IdAcc (_loc,
11197                                         Ast.IdUid (_loc, "Ast"),
11198                                         Ast.IdUid (_loc, "StVal"))),
11199                                     meta_loc _loc x0),
11200                                   meta_meta_bool _loc x1),
11201                                 meta_binding _loc x2)
11202                           | Ast.StTyp (x0, x1) ->
11203                               Ast.PaApp (_loc,
11204                                 Ast.PaApp (_loc,
11205                                   Ast.PaId (_loc,
11206                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11207                                       Ast.IdUid (_loc, "StTyp"))),
11208                                   meta_loc _loc x0),
11209                                 meta_ctyp _loc x1)
11210                           | Ast.StOpn (x0, x1) ->
11211                               Ast.PaApp (_loc,
11212                                 Ast.PaApp (_loc,
11213                                   Ast.PaId (_loc,
11214                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11215                                       Ast.IdUid (_loc, "StOpn"))),
11216                                   meta_loc _loc x0),
11217                                 meta_ident _loc x1)
11218                           | Ast.StMty (x0, x1, x2) ->
11219                               Ast.PaApp (_loc,
11220                                 Ast.PaApp (_loc,
11221                                   Ast.PaApp (_loc,
11222                                     Ast.PaId (_loc,
11223                                       Ast.IdAcc (_loc,
11224                                         Ast.IdUid (_loc, "Ast"),
11225                                         Ast.IdUid (_loc, "StMty"))),
11226                                     meta_loc _loc x0),
11227                                   meta_string _loc x1),
11228                                 meta_module_type _loc x2)
11229                           | Ast.StRecMod (x0, x1) ->
11230                               Ast.PaApp (_loc,
11231                                 Ast.PaApp (_loc,
11232                                   Ast.PaId (_loc,
11233                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11234                                       Ast.IdUid (_loc, "StRecMod"))),
11235                                   meta_loc _loc x0),
11236                                 meta_module_binding _loc x1)
11237                           | Ast.StMod (x0, x1, x2) ->
11238                               Ast.PaApp (_loc,
11239                                 Ast.PaApp (_loc,
11240                                   Ast.PaApp (_loc,
11241                                     Ast.PaId (_loc,
11242                                       Ast.IdAcc (_loc,
11243                                         Ast.IdUid (_loc, "Ast"),
11244                                         Ast.IdUid (_loc, "StMod"))),
11245                                     meta_loc _loc x0),
11246                                   meta_string _loc x1),
11247                                 meta_module_expr _loc x2)
11248                           | Ast.StInc (x0, x1) ->
11249                               Ast.PaApp (_loc,
11250                                 Ast.PaApp (_loc,
11251                                   Ast.PaId (_loc,
11252                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11253                                       Ast.IdUid (_loc, "StInc"))),
11254                                   meta_loc _loc x0),
11255                                 meta_module_expr _loc x1)
11256                           | Ast.StExt (x0, x1, x2, x3) ->
11257                               Ast.PaApp (_loc,
11258                                 Ast.PaApp (_loc,
11259                                   Ast.PaApp (_loc,
11260                                     Ast.PaApp (_loc,
11261                                       Ast.PaId (_loc,
11262                                         Ast.IdAcc (_loc,
11263                                           Ast.IdUid (_loc, "Ast"),
11264                                           Ast.IdUid (_loc, "StExt"))),
11265                                       meta_loc _loc x0),
11266                                     meta_string _loc x1),
11267                                   meta_ctyp _loc x2),
11268                                 meta_meta_list meta_string _loc x3)
11269                           | Ast.StExp (x0, x1) ->
11270                               Ast.PaApp (_loc,
11271                                 Ast.PaApp (_loc,
11272                                   Ast.PaId (_loc,
11273                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11274                                       Ast.IdUid (_loc, "StExp"))),
11275                                   meta_loc _loc x0),
11276                                 meta_expr _loc x1)
11277                           | Ast.StExc (x0, x1, x2) ->
11278                               Ast.PaApp (_loc,
11279                                 Ast.PaApp (_loc,
11280                                   Ast.PaApp (_loc,
11281                                     Ast.PaId (_loc,
11282                                       Ast.IdAcc (_loc,
11283                                         Ast.IdUid (_loc, "Ast"),
11284                                         Ast.IdUid (_loc, "StExc"))),
11285                                     meta_loc _loc x0),
11286                                   meta_ctyp _loc x1),
11287                                 meta_meta_option meta_ident _loc x2)
11288                           | Ast.StDir (x0, x1, x2) ->
11289                               Ast.PaApp (_loc,
11290                                 Ast.PaApp (_loc,
11291                                   Ast.PaApp (_loc,
11292                                     Ast.PaId (_loc,
11293                                       Ast.IdAcc (_loc,
11294                                         Ast.IdUid (_loc, "Ast"),
11295                                         Ast.IdUid (_loc, "StDir"))),
11296                                     meta_loc _loc x0),
11297                                   meta_string _loc x1),
11298                                 meta_expr _loc x2)
11299                           | Ast.StSem (x0, x1, x2) ->
11300                               Ast.PaApp (_loc,
11301                                 Ast.PaApp (_loc,
11302                                   Ast.PaApp (_loc,
11303                                     Ast.PaId (_loc,
11304                                       Ast.IdAcc (_loc,
11305                                         Ast.IdUid (_loc, "Ast"),
11306                                         Ast.IdUid (_loc, "StSem"))),
11307                                     meta_loc _loc x0),
11308                                   meta_str_item _loc x1),
11309                                 meta_str_item _loc x2)
11310                           | Ast.StClt (x0, x1) ->
11311                               Ast.PaApp (_loc,
11312                                 Ast.PaApp (_loc,
11313                                   Ast.PaId (_loc,
11314                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11315                                       Ast.IdUid (_loc, "StClt"))),
11316                                   meta_loc _loc x0),
11317                                 meta_class_type _loc x1)
11318                           | Ast.StCls (x0, x1) ->
11319                               Ast.PaApp (_loc,
11320                                 Ast.PaApp (_loc,
11321                                   Ast.PaId (_loc,
11322                                     Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11323                                       Ast.IdUid (_loc, "StCls"))),
11324                                   meta_loc _loc x0),
11325                                 meta_class_expr _loc x1)
11326                           | Ast.StNil x0 ->
11327                               Ast.PaApp (_loc,
11328                                 Ast.PaId (_loc,
11329                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11330                                     Ast.IdUid (_loc, "StNil"))),
11331                                 meta_loc _loc x0)
11332                         and meta_with_constr _loc =
11333                           function
11334                           | Ast.WcAnt (x0, x1) -> Ast.PaAnt (x0, x1)
11335                           | Ast.WcAnd (x0, x1, x2) ->
11336                               Ast.PaApp (_loc,
11337                                 Ast.PaApp (_loc,
11338                                   Ast.PaApp (_loc,
11339                                     Ast.PaId (_loc,
11340                                       Ast.IdAcc (_loc,
11341                                         Ast.IdUid (_loc, "Ast"),
11342                                         Ast.IdUid (_loc, "WcAnd"))),
11343                                     meta_loc _loc x0),
11344                                   meta_with_constr _loc x1),
11345                                 meta_with_constr _loc x2)
11346                           | Ast.WcMod (x0, x1, x2) ->
11347                               Ast.PaApp (_loc,
11348                                 Ast.PaApp (_loc,
11349                                   Ast.PaApp (_loc,
11350                                     Ast.PaId (_loc,
11351                                       Ast.IdAcc (_loc,
11352                                         Ast.IdUid (_loc, "Ast"),
11353                                         Ast.IdUid (_loc, "WcMod"))),
11354                                     meta_loc _loc x0),
11355                                   meta_ident _loc x1),
11356                                 meta_ident _loc x2)
11357                           | Ast.WcTyp (x0, x1, x2) ->
11358                               Ast.PaApp (_loc,
11359                                 Ast.PaApp (_loc,
11360                                   Ast.PaApp (_loc,
11361                                     Ast.PaId (_loc,
11362                                       Ast.IdAcc (_loc,
11363                                         Ast.IdUid (_loc, "Ast"),
11364                                         Ast.IdUid (_loc, "WcTyp"))),
11365                                     meta_loc _loc x0),
11366                                   meta_ctyp _loc x1),
11367                                 meta_ctyp _loc x2)
11368                           | Ast.WcNil x0 ->
11369                               Ast.PaApp (_loc,
11370                                 Ast.PaId (_loc,
11371                                   Ast.IdAcc (_loc, Ast.IdUid (_loc, "Ast"),
11372                                     Ast.IdUid (_loc, "WcNil"))),
11373                                 meta_loc _loc x0)
11374                           
11375                       end
11376                       
11377                   end
11378                   
11379               end
11380               
11381             class map =
11382               object ((o : 'self_type))
11383                 method string : string -> string = o#unknown
11384                   
11385                 method list :
11386                   'a 'a_out.
11387                     ('self_type -> 'a -> 'a_out) -> 'a list -> 'a_out list =
11388                   fun _f_a ->
11389                     function
11390                     | [] -> []
11391                     | _x :: _x_i1 ->
11392                         let _x = _f_a o _x in
11393                         let _x_i1 = o#list _f_a _x_i1 in _x :: _x_i1
11394                   
11395                 method with_constr : with_constr -> with_constr =
11396                   function
11397                   | WcNil _x -> let _x = o#loc _x in WcNil _x
11398                   | WcTyp (_x, _x_i1, _x_i2) ->
11399                       let _x = o#loc _x in
11400                       let _x_i1 = o#ctyp _x_i1 in
11401                       let _x_i2 = o#ctyp _x_i2 in WcTyp (_x, _x_i1, _x_i2)
11402                   | WcMod (_x, _x_i1, _x_i2) ->
11403                       let _x = o#loc _x in
11404                       let _x_i1 = o#ident _x_i1 in
11405                       let _x_i2 = o#ident _x_i2 in WcMod (_x, _x_i1, _x_i2)
11406                   | WcAnd (_x, _x_i1, _x_i2) ->
11407                       let _x = o#loc _x in
11408                       let _x_i1 = o#with_constr _x_i1 in
11409                       let _x_i2 = o#with_constr _x_i2
11410                       in WcAnd (_x, _x_i1, _x_i2)
11411                   | WcAnt (_x, _x_i1) ->
11412                       let _x = o#loc _x in
11413                       let _x_i1 = o#string _x_i1 in WcAnt (_x, _x_i1)
11414                   
11415                 method str_item : str_item -> str_item =
11416                   function
11417                   | StNil _x -> let _x = o#loc _x in StNil _x
11418                   | StCls (_x, _x_i1) ->
11419                       let _x = o#loc _x in
11420                       let _x_i1 = o#class_expr _x_i1 in StCls (_x, _x_i1)
11421                   | StClt (_x, _x_i1) ->
11422                       let _x = o#loc _x in
11423                       let _x_i1 = o#class_type _x_i1 in StClt (_x, _x_i1)
11424                   | StSem (_x, _x_i1, _x_i2) ->
11425                       let _x = o#loc _x in
11426                       let _x_i1 = o#str_item _x_i1 in
11427                       let _x_i2 = o#str_item _x_i2
11428                       in StSem (_x, _x_i1, _x_i2)
11429                   | StDir (_x, _x_i1, _x_i2) ->
11430                       let _x = o#loc _x in
11431                       let _x_i1 = o#string _x_i1 in
11432                       let _x_i2 = o#expr _x_i2 in StDir (_x, _x_i1, _x_i2)
11433                   | StExc (_x, _x_i1, _x_i2) ->
11434                       let _x = o#loc _x in
11435                       let _x_i1 = o#ctyp _x_i1 in
11436                       let _x_i2 = o#meta_option (fun o -> o#ident) _x_i2
11437                       in StExc (_x, _x_i1, _x_i2)
11438                   | StExp (_x, _x_i1) ->
11439                       let _x = o#loc _x in
11440                       let _x_i1 = o#expr _x_i1 in StExp (_x, _x_i1)
11441                   | StExt (_x, _x_i1, _x_i2, _x_i3) ->
11442                       let _x = o#loc _x in
11443                       let _x_i1 = o#string _x_i1 in
11444                       let _x_i2 = o#ctyp _x_i2 in
11445                       let _x_i3 = o#meta_list (fun o -> o#string) _x_i3
11446                       in StExt (_x, _x_i1, _x_i2, _x_i3)
11447                   | StInc (_x, _x_i1) ->
11448                       let _x = o#loc _x in
11449                       let _x_i1 = o#module_expr _x_i1 in StInc (_x, _x_i1)
11450                   | StMod (_x, _x_i1, _x_i2) ->
11451                       let _x = o#loc _x in
11452                       let _x_i1 = o#string _x_i1 in
11453                       let _x_i2 = o#module_expr _x_i2
11454                       in StMod (_x, _x_i1, _x_i2)
11455                   | StRecMod (_x, _x_i1) ->
11456                       let _x = o#loc _x in
11457                       let _x_i1 = o#module_binding _x_i1
11458                       in StRecMod (_x, _x_i1)
11459                   | StMty (_x, _x_i1, _x_i2) ->
11460                       let _x = o#loc _x in
11461                       let _x_i1 = o#string _x_i1 in
11462                       let _x_i2 = o#module_type _x_i2
11463                       in StMty (_x, _x_i1, _x_i2)
11464                   | StOpn (_x, _x_i1) ->
11465                       let _x = o#loc _x in
11466                       let _x_i1 = o#ident _x_i1 in StOpn (_x, _x_i1)
11467                   | StTyp (_x, _x_i1) ->
11468                       let _x = o#loc _x in
11469                       let _x_i1 = o#ctyp _x_i1 in StTyp (_x, _x_i1)
11470                   | StVal (_x, _x_i1, _x_i2) ->
11471                       let _x = o#loc _x in
11472                       let _x_i1 = o#meta_bool _x_i1 in
11473                       let _x_i2 = o#binding _x_i2 in StVal (_x, _x_i1, _x_i2)
11474                   | StAnt (_x, _x_i1) ->
11475                       let _x = o#loc _x in
11476                       let _x_i1 = o#string _x_i1 in StAnt (_x, _x_i1)
11477                   
11478                 method sig_item : sig_item -> sig_item =
11479                   function
11480                   | SgNil _x -> let _x = o#loc _x in SgNil _x
11481                   | SgCls (_x, _x_i1) ->
11482                       let _x = o#loc _x in
11483                       let _x_i1 = o#class_type _x_i1 in SgCls (_x, _x_i1)
11484                   | SgClt (_x, _x_i1) ->
11485                       let _x = o#loc _x in
11486                       let _x_i1 = o#class_type _x_i1 in SgClt (_x, _x_i1)
11487                   | SgSem (_x, _x_i1, _x_i2) ->
11488                       let _x = o#loc _x in
11489                       let _x_i1 = o#sig_item _x_i1 in
11490                       let _x_i2 = o#sig_item _x_i2
11491                       in SgSem (_x, _x_i1, _x_i2)
11492                   | SgDir (_x, _x_i1, _x_i2) ->
11493                       let _x = o#loc _x in
11494                       let _x_i1 = o#string _x_i1 in
11495                       let _x_i2 = o#expr _x_i2 in SgDir (_x, _x_i1, _x_i2)
11496                   | SgExc (_x, _x_i1) ->
11497                       let _x = o#loc _x in
11498                       let _x_i1 = o#ctyp _x_i1 in SgExc (_x, _x_i1)
11499                   | SgExt (_x, _x_i1, _x_i2, _x_i3) ->
11500                       let _x = o#loc _x in
11501                       let _x_i1 = o#string _x_i1 in
11502                       let _x_i2 = o#ctyp _x_i2 in
11503                       let _x_i3 = o#meta_list (fun o -> o#string) _x_i3
11504                       in SgExt (_x, _x_i1, _x_i2, _x_i3)
11505                   | SgInc (_x, _x_i1) ->
11506                       let _x = o#loc _x in
11507                       let _x_i1 = o#module_type _x_i1 in SgInc (_x, _x_i1)
11508                   | SgMod (_x, _x_i1, _x_i2) ->
11509                       let _x = o#loc _x in
11510                       let _x_i1 = o#string _x_i1 in
11511                       let _x_i2 = o#module_type _x_i2
11512                       in SgMod (_x, _x_i1, _x_i2)
11513                   | SgRecMod (_x, _x_i1) ->
11514                       let _x = o#loc _x in
11515                       let _x_i1 = o#module_binding _x_i1
11516                       in SgRecMod (_x, _x_i1)
11517                   | SgMty (_x, _x_i1, _x_i2) ->
11518                       let _x = o#loc _x in
11519                       let _x_i1 = o#string _x_i1 in
11520                       let _x_i2 = o#module_type _x_i2
11521                       in SgMty (_x, _x_i1, _x_i2)
11522                   | SgOpn (_x, _x_i1) ->
11523                       let _x = o#loc _x in
11524                       let _x_i1 = o#ident _x_i1 in SgOpn (_x, _x_i1)
11525                   | SgTyp (_x, _x_i1) ->
11526                       let _x = o#loc _x in
11527                       let _x_i1 = o#ctyp _x_i1 in SgTyp (_x, _x_i1)
11528                   | SgVal (_x, _x_i1, _x_i2) ->
11529                       let _x = o#loc _x in
11530                       let _x_i1 = o#string _x_i1 in
11531                       let _x_i2 = o#ctyp _x_i2 in SgVal (_x, _x_i1, _x_i2)
11532                   | SgAnt (_x, _x_i1) ->
11533                       let _x = o#loc _x in
11534                       let _x_i1 = o#string _x_i1 in SgAnt (_x, _x_i1)
11535                   
11536                 method rec_binding : rec_binding -> rec_binding =
11537                   function
11538                   | RbNil _x -> let _x = o#loc _x in RbNil _x
11539                   | RbSem (_x, _x_i1, _x_i2) ->
11540                       let _x = o#loc _x in
11541                       let _x_i1 = o#rec_binding _x_i1 in
11542                       let _x_i2 = o#rec_binding _x_i2
11543                       in RbSem (_x, _x_i1, _x_i2)
11544                   | RbEq (_x, _x_i1, _x_i2) ->
11545                       let _x = o#loc _x in
11546                       let _x_i1 = o#ident _x_i1 in
11547                       let _x_i2 = o#expr _x_i2 in RbEq (_x, _x_i1, _x_i2)
11548                   | RbAnt (_x, _x_i1) ->
11549                       let _x = o#loc _x in
11550                       let _x_i1 = o#string _x_i1 in RbAnt (_x, _x_i1)
11551                   
11552                 method patt : patt -> patt =
11553                   function
11554                   | PaNil _x -> let _x = o#loc _x in PaNil _x
11555                   | PaId (_x, _x_i1) ->
11556                       let _x = o#loc _x in
11557                       let _x_i1 = o#ident _x_i1 in PaId (_x, _x_i1)
11558                   | PaAli (_x, _x_i1, _x_i2) ->
11559                       let _x = o#loc _x in
11560                       let _x_i1 = o#patt _x_i1 in
11561                       let _x_i2 = o#patt _x_i2 in PaAli (_x, _x_i1, _x_i2)
11562                   | PaAnt (_x, _x_i1) ->
11563                       let _x = o#loc _x in
11564                       let _x_i1 = o#string _x_i1 in PaAnt (_x, _x_i1)
11565                   | PaAny _x -> let _x = o#loc _x in PaAny _x
11566                   | PaApp (_x, _x_i1, _x_i2) ->
11567                       let _x = o#loc _x in
11568                       let _x_i1 = o#patt _x_i1 in
11569                       let _x_i2 = o#patt _x_i2 in PaApp (_x, _x_i1, _x_i2)
11570                   | PaArr (_x, _x_i1) ->
11571                       let _x = o#loc _x in
11572                       let _x_i1 = o#patt _x_i1 in PaArr (_x, _x_i1)
11573                   | PaCom (_x, _x_i1, _x_i2) ->
11574                       let _x = o#loc _x in
11575                       let _x_i1 = o#patt _x_i1 in
11576                       let _x_i2 = o#patt _x_i2 in PaCom (_x, _x_i1, _x_i2)
11577                   | PaSem (_x, _x_i1, _x_i2) ->
11578                       let _x = o#loc _x in
11579                       let _x_i1 = o#patt _x_i1 in
11580                       let _x_i2 = o#patt _x_i2 in PaSem (_x, _x_i1, _x_i2)
11581                   | PaChr (_x, _x_i1) ->
11582                       let _x = o#loc _x in
11583                       let _x_i1 = o#string _x_i1 in PaChr (_x, _x_i1)
11584                   | PaInt (_x, _x_i1) ->
11585                       let _x = o#loc _x in
11586                       let _x_i1 = o#string _x_i1 in PaInt (_x, _x_i1)
11587                   | PaInt32 (_x, _x_i1) ->
11588                       let _x = o#loc _x in
11589                       let _x_i1 = o#string _x_i1 in PaInt32 (_x, _x_i1)
11590                   | PaInt64 (_x, _x_i1) ->
11591                       let _x = o#loc _x in
11592                       let _x_i1 = o#string _x_i1 in PaInt64 (_x, _x_i1)
11593                   | PaNativeInt (_x, _x_i1) ->
11594                       let _x = o#loc _x in
11595                       let _x_i1 = o#string _x_i1 in PaNativeInt (_x, _x_i1)
11596                   | PaFlo (_x, _x_i1) ->
11597                       let _x = o#loc _x in
11598                       let _x_i1 = o#string _x_i1 in PaFlo (_x, _x_i1)
11599                   | PaLab (_x, _x_i1, _x_i2) ->
11600                       let _x = o#loc _x in
11601                       let _x_i1 = o#string _x_i1 in
11602                       let _x_i2 = o#patt _x_i2 in PaLab (_x, _x_i1, _x_i2)
11603                   | PaOlb (_x, _x_i1, _x_i2) ->
11604                       let _x = o#loc _x in
11605                       let _x_i1 = o#string _x_i1 in
11606                       let _x_i2 = o#patt _x_i2 in PaOlb (_x, _x_i1, _x_i2)
11607                   | PaOlbi (_x, _x_i1, _x_i2, _x_i3) ->
11608                       let _x = o#loc _x in
11609                       let _x_i1 = o#string _x_i1 in
11610                       let _x_i2 = o#patt _x_i2 in
11611                       let _x_i3 = o#expr _x_i3
11612                       in PaOlbi (_x, _x_i1, _x_i2, _x_i3)
11613                   | PaOrp (_x, _x_i1, _x_i2) ->
11614                       let _x = o#loc _x in
11615                       let _x_i1 = o#patt _x_i1 in
11616                       let _x_i2 = o#patt _x_i2 in PaOrp (_x, _x_i1, _x_i2)
11617                   | PaRng (_x, _x_i1, _x_i2) ->
11618                       let _x = o#loc _x in
11619                       let _x_i1 = o#patt _x_i1 in
11620                       let _x_i2 = o#patt _x_i2 in PaRng (_x, _x_i1, _x_i2)
11621                   | PaRec (_x, _x_i1) ->
11622                       let _x = o#loc _x in
11623                       let _x_i1 = o#patt _x_i1 in PaRec (_x, _x_i1)
11624                   | PaEq (_x, _x_i1, _x_i2) ->
11625                       let _x = o#loc _x in
11626                       let _x_i1 = o#ident _x_i1 in
11627                       let _x_i2 = o#patt _x_i2 in PaEq (_x, _x_i1, _x_i2)
11628                   | PaStr (_x, _x_i1) ->
11629                       let _x = o#loc _x in
11630                       let _x_i1 = o#string _x_i1 in PaStr (_x, _x_i1)
11631                   | PaTup (_x, _x_i1) ->
11632                       let _x = o#loc _x in
11633                       let _x_i1 = o#patt _x_i1 in PaTup (_x, _x_i1)
11634                   | PaTyc (_x, _x_i1, _x_i2) ->
11635                       let _x = o#loc _x in
11636                       let _x_i1 = o#patt _x_i1 in
11637                       let _x_i2 = o#ctyp _x_i2 in PaTyc (_x, _x_i1, _x_i2)
11638                   | PaTyp (_x, _x_i1) ->
11639                       let _x = o#loc _x in
11640                       let _x_i1 = o#ident _x_i1 in PaTyp (_x, _x_i1)
11641                   | PaVrn (_x, _x_i1) ->
11642                       let _x = o#loc _x in
11643                       let _x_i1 = o#string _x_i1 in PaVrn (_x, _x_i1)
11644                   | PaLaz (_x, _x_i1) ->
11645                       let _x = o#loc _x in
11646                       let _x_i1 = o#patt _x_i1 in PaLaz (_x, _x_i1)
11647                   
11648                 method module_type : module_type -> module_type =
11649                   function
11650                   | MtNil _x -> let _x = o#loc _x in MtNil _x
11651                   | MtId (_x, _x_i1) ->
11652                       let _x = o#loc _x in
11653                       let _x_i1 = o#ident _x_i1 in MtId (_x, _x_i1)
11654                   | MtFun (_x, _x_i1, _x_i2, _x_i3) ->
11655                       let _x = o#loc _x in
11656                       let _x_i1 = o#string _x_i1 in
11657                       let _x_i2 = o#module_type _x_i2 in
11658                       let _x_i3 = o#module_type _x_i3
11659                       in MtFun (_x, _x_i1, _x_i2, _x_i3)
11660                   | MtQuo (_x, _x_i1) ->
11661                       let _x = o#loc _x in
11662                       let _x_i1 = o#string _x_i1 in MtQuo (_x, _x_i1)
11663                   | MtSig (_x, _x_i1) ->
11664                       let _x = o#loc _x in
11665                       let _x_i1 = o#sig_item _x_i1 in MtSig (_x, _x_i1)
11666                   | MtWit (_x, _x_i1, _x_i2) ->
11667                       let _x = o#loc _x in
11668                       let _x_i1 = o#module_type _x_i1 in
11669                       let _x_i2 = o#with_constr _x_i2
11670                       in MtWit (_x, _x_i1, _x_i2)
11671                   | MtAnt (_x, _x_i1) ->
11672                       let _x = o#loc _x in
11673                       let _x_i1 = o#string _x_i1 in MtAnt (_x, _x_i1)
11674                   
11675                 method module_expr : module_expr -> module_expr =
11676                   function
11677                   | MeNil _x -> let _x = o#loc _x in MeNil _x
11678                   | MeId (_x, _x_i1) ->
11679                       let _x = o#loc _x in
11680                       let _x_i1 = o#ident _x_i1 in MeId (_x, _x_i1)
11681                   | MeApp (_x, _x_i1, _x_i2) ->
11682                       let _x = o#loc _x in
11683                       let _x_i1 = o#module_expr _x_i1 in
11684                       let _x_i2 = o#module_expr _x_i2
11685                       in MeApp (_x, _x_i1, _x_i2)
11686                   | MeFun (_x, _x_i1, _x_i2, _x_i3) ->
11687                       let _x = o#loc _x in
11688                       let _x_i1 = o#string _x_i1 in
11689                       let _x_i2 = o#module_type _x_i2 in
11690                       let _x_i3 = o#module_expr _x_i3
11691                       in MeFun (_x, _x_i1, _x_i2, _x_i3)
11692                   | MeStr (_x, _x_i1) ->
11693                       let _x = o#loc _x in
11694                       let _x_i1 = o#str_item _x_i1 in MeStr (_x, _x_i1)
11695                   | MeTyc (_x, _x_i1, _x_i2) ->
11696                       let _x = o#loc _x in
11697                       let _x_i1 = o#module_expr _x_i1 in
11698                       let _x_i2 = o#module_type _x_i2
11699                       in MeTyc (_x, _x_i1, _x_i2)
11700                   | MeAnt (_x, _x_i1) ->
11701                       let _x = o#loc _x in
11702                       let _x_i1 = o#string _x_i1 in MeAnt (_x, _x_i1)
11703                   
11704                 method module_binding : module_binding -> module_binding =
11705                   function
11706                   | MbNil _x -> let _x = o#loc _x in MbNil _x
11707                   | MbAnd (_x, _x_i1, _x_i2) ->
11708                       let _x = o#loc _x in
11709                       let _x_i1 = o#module_binding _x_i1 in
11710                       let _x_i2 = o#module_binding _x_i2
11711                       in MbAnd (_x, _x_i1, _x_i2)
11712                   | MbColEq (_x, _x_i1, _x_i2, _x_i3) ->
11713                       let _x = o#loc _x in
11714                       let _x_i1 = o#string _x_i1 in
11715                       let _x_i2 = o#module_type _x_i2 in
11716                       let _x_i3 = o#module_expr _x_i3
11717                       in MbColEq (_x, _x_i1, _x_i2, _x_i3)
11718                   | MbCol (_x, _x_i1, _x_i2) ->
11719                       let _x = o#loc _x in
11720                       let _x_i1 = o#string _x_i1 in
11721                       let _x_i2 = o#module_type _x_i2
11722                       in MbCol (_x, _x_i1, _x_i2)
11723                   | MbAnt (_x, _x_i1) ->
11724                       let _x = o#loc _x in
11725                       let _x_i1 = o#string _x_i1 in MbAnt (_x, _x_i1)
11726                   
11727                 method meta_option :
11728                   'a 'a_out.
11729                     ('self_type -> 'a -> 'a_out) ->
11730                       'a meta_option -> 'a_out meta_option =
11731                   fun _f_a ->
11732                     function
11733                     | ONone -> ONone
11734                     | OSome _x -> let _x = _f_a o _x in OSome _x
11735                     | OAnt _x -> let _x = o#string _x in OAnt _x
11736                   
11737                 method meta_list :
11738                   'a 'a_out.
11739                     ('self_type -> 'a -> 'a_out) ->
11740                       'a meta_list -> 'a_out meta_list =
11741                   fun _f_a ->
11742                     function
11743                     | LNil -> LNil
11744                     | LCons (_x, _x_i1) ->
11745                         let _x = _f_a o _x in
11746                         let _x_i1 = o#meta_list _f_a _x_i1
11747                         in LCons (_x, _x_i1)
11748                     | LAnt _x -> let _x = o#string _x in LAnt _x
11749                   
11750                 method meta_bool : meta_bool -> meta_bool =
11751                   function
11752                   | BTrue -> BTrue
11753                   | BFalse -> BFalse
11754                   | BAnt _x -> let _x = o#string _x in BAnt _x
11755                   
11756                 method match_case : match_case -> match_case =
11757                   function
11758                   | McNil _x -> let _x = o#loc _x in McNil _x
11759                   | McOr (_x, _x_i1, _x_i2) ->
11760                       let _x = o#loc _x in
11761                       let _x_i1 = o#match_case _x_i1 in
11762                       let _x_i2 = o#match_case _x_i2
11763                       in McOr (_x, _x_i1, _x_i2)
11764                   | McArr (_x, _x_i1, _x_i2, _x_i3) ->
11765                       let _x = o#loc _x in
11766                       let _x_i1 = o#patt _x_i1 in
11767                       let _x_i2 = o#expr _x_i2 in
11768                       let _x_i3 = o#expr _x_i3
11769                       in McArr (_x, _x_i1, _x_i2, _x_i3)
11770                   | McAnt (_x, _x_i1) ->
11771                       let _x = o#loc _x in
11772                       let _x_i1 = o#string _x_i1 in McAnt (_x, _x_i1)
11773                   
11774                 method loc : loc -> loc = o#unknown
11775                   
11776                 method ident : ident -> ident =
11777                   function
11778                   | IdAcc (_x, _x_i1, _x_i2) ->
11779                       let _x = o#loc _x in
11780                       let _x_i1 = o#ident _x_i1 in
11781                       let _x_i2 = o#ident _x_i2 in IdAcc (_x, _x_i1, _x_i2)
11782                   | IdApp (_x, _x_i1, _x_i2) ->
11783                       let _x = o#loc _x in
11784                       let _x_i1 = o#ident _x_i1 in
11785                       let _x_i2 = o#ident _x_i2 in IdApp (_x, _x_i1, _x_i2)
11786                   | IdLid (_x, _x_i1) ->
11787                       let _x = o#loc _x in
11788                       let _x_i1 = o#string _x_i1 in IdLid (_x, _x_i1)
11789                   | IdUid (_x, _x_i1) ->
11790                       let _x = o#loc _x in
11791                       let _x_i1 = o#string _x_i1 in IdUid (_x, _x_i1)
11792                   | IdAnt (_x, _x_i1) ->
11793                       let _x = o#loc _x in
11794                       let _x_i1 = o#string _x_i1 in IdAnt (_x, _x_i1)
11795                   
11796                 method expr : expr -> expr =
11797                   function
11798                   | ExNil _x -> let _x = o#loc _x in ExNil _x
11799                   | ExId (_x, _x_i1) ->
11800                       let _x = o#loc _x in
11801                       let _x_i1 = o#ident _x_i1 in ExId (_x, _x_i1)
11802                   | ExAcc (_x, _x_i1, _x_i2) ->
11803                       let _x = o#loc _x in
11804                       let _x_i1 = o#expr _x_i1 in
11805                       let _x_i2 = o#expr _x_i2 in ExAcc (_x, _x_i1, _x_i2)
11806                   | ExAnt (_x, _x_i1) ->
11807                       let _x = o#loc _x in
11808                       let _x_i1 = o#string _x_i1 in ExAnt (_x, _x_i1)
11809                   | ExApp (_x, _x_i1, _x_i2) ->
11810                       let _x = o#loc _x in
11811                       let _x_i1 = o#expr _x_i1 in
11812                       let _x_i2 = o#expr _x_i2 in ExApp (_x, _x_i1, _x_i2)
11813                   | ExAre (_x, _x_i1, _x_i2) ->
11814                       let _x = o#loc _x in
11815                       let _x_i1 = o#expr _x_i1 in
11816                       let _x_i2 = o#expr _x_i2 in ExAre (_x, _x_i1, _x_i2)
11817                   | ExArr (_x, _x_i1) ->
11818                       let _x = o#loc _x in
11819                       let _x_i1 = o#expr _x_i1 in ExArr (_x, _x_i1)
11820                   | ExSem (_x, _x_i1, _x_i2) ->
11821                       let _x = o#loc _x in
11822                       let _x_i1 = o#expr _x_i1 in
11823                       let _x_i2 = o#expr _x_i2 in ExSem (_x, _x_i1, _x_i2)
11824                   | ExAsf _x -> let _x = o#loc _x in ExAsf _x
11825                   | ExAsr (_x, _x_i1) ->
11826                       let _x = o#loc _x in
11827                       let _x_i1 = o#expr _x_i1 in ExAsr (_x, _x_i1)
11828                   | ExAss (_x, _x_i1, _x_i2) ->
11829                       let _x = o#loc _x in
11830                       let _x_i1 = o#expr _x_i1 in
11831                       let _x_i2 = o#expr _x_i2 in ExAss (_x, _x_i1, _x_i2)
11832                   | ExChr (_x, _x_i1) ->
11833                       let _x = o#loc _x in
11834                       let _x_i1 = o#string _x_i1 in ExChr (_x, _x_i1)
11835                   | ExCoe (_x, _x_i1, _x_i2, _x_i3) ->
11836                       let _x = o#loc _x in
11837                       let _x_i1 = o#expr _x_i1 in
11838                       let _x_i2 = o#ctyp _x_i2 in
11839                       let _x_i3 = o#ctyp _x_i3
11840                       in ExCoe (_x, _x_i1, _x_i2, _x_i3)
11841                   | ExFlo (_x, _x_i1) ->
11842                       let _x = o#loc _x in
11843                       let _x_i1 = o#string _x_i1 in ExFlo (_x, _x_i1)
11844                   | ExFor (_x, _x_i1, _x_i2, _x_i3, _x_i4, _x_i5) ->
11845                       let _x = o#loc _x in
11846                       let _x_i1 = o#string _x_i1 in
11847                       let _x_i2 = o#expr _x_i2 in
11848                       let _x_i3 = o#expr _x_i3 in
11849                       let _x_i4 = o#meta_bool _x_i4 in
11850                       let _x_i5 = o#expr _x_i5
11851                       in ExFor (_x, _x_i1, _x_i2, _x_i3, _x_i4, _x_i5)
11852                   | ExFun (_x, _x_i1) ->
11853                       let _x = o#loc _x in
11854                       let _x_i1 = o#match_case _x_i1 in ExFun (_x, _x_i1)
11855                   | ExIfe (_x, _x_i1, _x_i2, _x_i3) ->
11856                       let _x = o#loc _x in
11857                       let _x_i1 = o#expr _x_i1 in
11858                       let _x_i2 = o#expr _x_i2 in
11859                       let _x_i3 = o#expr _x_i3
11860                       in ExIfe (_x, _x_i1, _x_i2, _x_i3)
11861                   | ExInt (_x, _x_i1) ->
11862                       let _x = o#loc _x in
11863                       let _x_i1 = o#string _x_i1 in ExInt (_x, _x_i1)
11864                   | ExInt32 (_x, _x_i1) ->
11865                       let _x = o#loc _x in
11866                       let _x_i1 = o#string _x_i1 in ExInt32 (_x, _x_i1)
11867                   | ExInt64 (_x, _x_i1) ->
11868                       let _x = o#loc _x in
11869                       let _x_i1 = o#string _x_i1 in ExInt64 (_x, _x_i1)
11870                   | ExNativeInt (_x, _x_i1) ->
11871                       let _x = o#loc _x in
11872                       let _x_i1 = o#string _x_i1 in ExNativeInt (_x, _x_i1)
11873                   | ExLab (_x, _x_i1, _x_i2) ->
11874                       let _x = o#loc _x in
11875                       let _x_i1 = o#string _x_i1 in
11876                       let _x_i2 = o#expr _x_i2 in ExLab (_x, _x_i1, _x_i2)
11877                   | ExLaz (_x, _x_i1) ->
11878                       let _x = o#loc _x in
11879                       let _x_i1 = o#expr _x_i1 in ExLaz (_x, _x_i1)
11880                   | ExLet (_x, _x_i1, _x_i2, _x_i3) ->
11881                       let _x = o#loc _x in
11882                       let _x_i1 = o#meta_bool _x_i1 in
11883                       let _x_i2 = o#binding _x_i2 in
11884                       let _x_i3 = o#expr _x_i3
11885                       in ExLet (_x, _x_i1, _x_i2, _x_i3)
11886                   | ExLmd (_x, _x_i1, _x_i2, _x_i3) ->
11887                       let _x = o#loc _x in
11888                       let _x_i1 = o#string _x_i1 in
11889                       let _x_i2 = o#module_expr _x_i2 in
11890                       let _x_i3 = o#expr _x_i3
11891                       in ExLmd (_x, _x_i1, _x_i2, _x_i3)
11892                   | ExMat (_x, _x_i1, _x_i2) ->
11893                       let _x = o#loc _x in
11894                       let _x_i1 = o#expr _x_i1 in
11895                       let _x_i2 = o#match_case _x_i2
11896                       in ExMat (_x, _x_i1, _x_i2)
11897                   | ExNew (_x, _x_i1) ->
11898                       let _x = o#loc _x in
11899                       let _x_i1 = o#ident _x_i1 in ExNew (_x, _x_i1)
11900                   | ExObj (_x, _x_i1, _x_i2) ->
11901                       let _x = o#loc _x in
11902                       let _x_i1 = o#patt _x_i1 in
11903                       let _x_i2 = o#class_str_item _x_i2
11904                       in ExObj (_x, _x_i1, _x_i2)
11905                   | ExOlb (_x, _x_i1, _x_i2) ->
11906                       let _x = o#loc _x in
11907                       let _x_i1 = o#string _x_i1 in
11908                       let _x_i2 = o#expr _x_i2 in ExOlb (_x, _x_i1, _x_i2)
11909                   | ExOvr (_x, _x_i1) ->
11910                       let _x = o#loc _x in
11911                       let _x_i1 = o#rec_binding _x_i1 in ExOvr (_x, _x_i1)
11912                   | ExRec (_x, _x_i1, _x_i2) ->
11913                       let _x = o#loc _x in
11914                       let _x_i1 = o#rec_binding _x_i1 in
11915                       let _x_i2 = o#expr _x_i2 in ExRec (_x, _x_i1, _x_i2)
11916                   | ExSeq (_x, _x_i1) ->
11917                       let _x = o#loc _x in
11918                       let _x_i1 = o#expr _x_i1 in ExSeq (_x, _x_i1)
11919                   | ExSnd (_x, _x_i1, _x_i2) ->
11920                       let _x = o#loc _x in
11921                       let _x_i1 = o#expr _x_i1 in
11922                       let _x_i2 = o#string _x_i2 in ExSnd (_x, _x_i1, _x_i2)
11923                   | ExSte (_x, _x_i1, _x_i2) ->
11924                       let _x = o#loc _x in
11925                       let _x_i1 = o#expr _x_i1 in
11926                       let _x_i2 = o#expr _x_i2 in ExSte (_x, _x_i1, _x_i2)
11927                   | ExStr (_x, _x_i1) ->
11928                       let _x = o#loc _x in
11929                       let _x_i1 = o#string _x_i1 in ExStr (_x, _x_i1)
11930                   | ExTry (_x, _x_i1, _x_i2) ->
11931                       let _x = o#loc _x in
11932                       let _x_i1 = o#expr _x_i1 in
11933                       let _x_i2 = o#match_case _x_i2
11934                       in ExTry (_x, _x_i1, _x_i2)
11935                   | ExTup (_x, _x_i1) ->
11936                       let _x = o#loc _x in
11937                       let _x_i1 = o#expr _x_i1 in ExTup (_x, _x_i1)
11938                   | ExCom (_x, _x_i1, _x_i2) ->
11939                       let _x = o#loc _x in
11940                       let _x_i1 = o#expr _x_i1 in
11941                       let _x_i2 = o#expr _x_i2 in ExCom (_x, _x_i1, _x_i2)
11942                   | ExTyc (_x, _x_i1, _x_i2) ->
11943                       let _x = o#loc _x in
11944                       let _x_i1 = o#expr _x_i1 in
11945                       let _x_i2 = o#ctyp _x_i2 in ExTyc (_x, _x_i1, _x_i2)
11946                   | ExVrn (_x, _x_i1) ->
11947                       let _x = o#loc _x in
11948                       let _x_i1 = o#string _x_i1 in ExVrn (_x, _x_i1)
11949                   | ExWhi (_x, _x_i1, _x_i2) ->
11950                       let _x = o#loc _x in
11951                       let _x_i1 = o#expr _x_i1 in
11952                       let _x_i2 = o#expr _x_i2 in ExWhi (_x, _x_i1, _x_i2)
11953                   
11954                 method ctyp : ctyp -> ctyp =
11955                   function
11956                   | TyNil _x -> let _x = o#loc _x in TyNil _x
11957                   | TyAli (_x, _x_i1, _x_i2) ->
11958                       let _x = o#loc _x in
11959                       let _x_i1 = o#ctyp _x_i1 in
11960                       let _x_i2 = o#ctyp _x_i2 in TyAli (_x, _x_i1, _x_i2)
11961                   | TyAny _x -> let _x = o#loc _x in TyAny _x
11962                   | TyApp (_x, _x_i1, _x_i2) ->
11963                       let _x = o#loc _x in
11964                       let _x_i1 = o#ctyp _x_i1 in
11965                       let _x_i2 = o#ctyp _x_i2 in TyApp (_x, _x_i1, _x_i2)
11966                   | TyArr (_x, _x_i1, _x_i2) ->
11967                       let _x = o#loc _x in
11968                       let _x_i1 = o#ctyp _x_i1 in
11969                       let _x_i2 = o#ctyp _x_i2 in TyArr (_x, _x_i1, _x_i2)
11970                   | TyCls (_x, _x_i1) ->
11971                       let _x = o#loc _x in
11972                       let _x_i1 = o#ident _x_i1 in TyCls (_x, _x_i1)
11973                   | TyLab (_x, _x_i1, _x_i2) ->
11974                       let _x = o#loc _x in
11975                       let _x_i1 = o#string _x_i1 in
11976                       let _x_i2 = o#ctyp _x_i2 in TyLab (_x, _x_i1, _x_i2)
11977                   | TyId (_x, _x_i1) ->
11978                       let _x = o#loc _x in
11979                       let _x_i1 = o#ident _x_i1 in TyId (_x, _x_i1)
11980                   | TyMan (_x, _x_i1, _x_i2) ->
11981                       let _x = o#loc _x in
11982                       let _x_i1 = o#ctyp _x_i1 in
11983                       let _x_i2 = o#ctyp _x_i2 in TyMan (_x, _x_i1, _x_i2)
11984                   | TyDcl (_x, _x_i1, _x_i2, _x_i3, _x_i4) ->
11985                       let _x = o#loc _x in
11986                       let _x_i1 = o#string _x_i1 in
11987                       let _x_i2 = o#list (fun o -> o#ctyp) _x_i2 in
11988                       let _x_i3 = o#ctyp _x_i3 in
11989                       let _x_i4 =
11990                         o#list
11991                           (fun o (_x, _x_i1) ->
11992                              let _x = o#ctyp _x in
11993                              let _x_i1 = o#ctyp _x_i1 in (_x, _x_i1))
11994                           _x_i4
11995                       in TyDcl (_x, _x_i1, _x_i2, _x_i3, _x_i4)
11996                   | TyObj (_x, _x_i1, _x_i2) ->
11997                       let _x = o#loc _x in
11998                       let _x_i1 = o#ctyp _x_i1 in
11999                       let _x_i2 = o#meta_bool _x_i2
12000                       in TyObj (_x, _x_i1, _x_i2)
12001                   | TyOlb (_x, _x_i1, _x_i2) ->
12002                       let _x = o#loc _x in
12003                       let _x_i1 = o#string _x_i1 in
12004                       let _x_i2 = o#ctyp _x_i2 in TyOlb (_x, _x_i1, _x_i2)
12005                   | TyPol (_x, _x_i1, _x_i2) ->
12006                       let _x = o#loc _x in
12007                       let _x_i1 = o#ctyp _x_i1 in
12008                       let _x_i2 = o#ctyp _x_i2 in TyPol (_x, _x_i1, _x_i2)
12009                   | TyQuo (_x, _x_i1) ->
12010                       let _x = o#loc _x in
12011                       let _x_i1 = o#string _x_i1 in TyQuo (_x, _x_i1)
12012                   | TyQuP (_x, _x_i1) ->
12013                       let _x = o#loc _x in
12014                       let _x_i1 = o#string _x_i1 in TyQuP (_x, _x_i1)
12015                   | TyQuM (_x, _x_i1) ->
12016                       let _x = o#loc _x in
12017                       let _x_i1 = o#string _x_i1 in TyQuM (_x, _x_i1)
12018                   | TyVrn (_x, _x_i1) ->
12019                       let _x = o#loc _x in
12020                       let _x_i1 = o#string _x_i1 in TyVrn (_x, _x_i1)
12021                   | TyRec (_x, _x_i1) ->
12022                       let _x = o#loc _x in
12023                       let _x_i1 = o#ctyp _x_i1 in TyRec (_x, _x_i1)
12024                   | TyCol (_x, _x_i1, _x_i2) ->
12025                       let _x = o#loc _x in
12026                       let _x_i1 = o#ctyp _x_i1 in
12027                       let _x_i2 = o#ctyp _x_i2 in TyCol (_x, _x_i1, _x_i2)
12028                   | TySem (_x, _x_i1, _x_i2) ->
12029                       let _x = o#loc _x in
12030                       let _x_i1 = o#ctyp _x_i1 in
12031                       let _x_i2 = o#ctyp _x_i2 in TySem (_x, _x_i1, _x_i2)
12032                   | TyCom (_x, _x_i1, _x_i2) ->
12033                       let _x = o#loc _x in
12034                       let _x_i1 = o#ctyp _x_i1 in
12035                       let _x_i2 = o#ctyp _x_i2 in TyCom (_x, _x_i1, _x_i2)
12036                   | TySum (_x, _x_i1) ->
12037                       let _x = o#loc _x in
12038                       let _x_i1 = o#ctyp _x_i1 in TySum (_x, _x_i1)
12039                   | TyOf (_x, _x_i1, _x_i2) ->
12040                       let _x = o#loc _x in
12041                       let _x_i1 = o#ctyp _x_i1 in
12042                       let _x_i2 = o#ctyp _x_i2 in TyOf (_x, _x_i1, _x_i2)
12043                   | TyAnd (_x, _x_i1, _x_i2) ->
12044                       let _x = o#loc _x in
12045                       let _x_i1 = o#ctyp _x_i1 in
12046                       let _x_i2 = o#ctyp _x_i2 in TyAnd (_x, _x_i1, _x_i2)
12047                   | TyOr (_x, _x_i1, _x_i2) ->
12048                       let _x = o#loc _x in
12049                       let _x_i1 = o#ctyp _x_i1 in
12050                       let _x_i2 = o#ctyp _x_i2 in TyOr (_x, _x_i1, _x_i2)
12051                   | TyPrv (_x, _x_i1) ->
12052                       let _x = o#loc _x in
12053                       let _x_i1 = o#ctyp _x_i1 in TyPrv (_x, _x_i1)
12054                   | TyMut (_x, _x_i1) ->
12055                       let _x = o#loc _x in
12056                       let _x_i1 = o#ctyp _x_i1 in TyMut (_x, _x_i1)
12057                   | TyTup (_x, _x_i1) ->
12058                       let _x = o#loc _x in
12059                       let _x_i1 = o#ctyp _x_i1 in TyTup (_x, _x_i1)
12060                   | TySta (_x, _x_i1, _x_i2) ->
12061                       let _x = o#loc _x in
12062                       let _x_i1 = o#ctyp _x_i1 in
12063                       let _x_i2 = o#ctyp _x_i2 in TySta (_x, _x_i1, _x_i2)
12064                   | TyVrnEq (_x, _x_i1) ->
12065                       let _x = o#loc _x in
12066                       let _x_i1 = o#ctyp _x_i1 in TyVrnEq (_x, _x_i1)
12067                   | TyVrnSup (_x, _x_i1) ->
12068                       let _x = o#loc _x in
12069                       let _x_i1 = o#ctyp _x_i1 in TyVrnSup (_x, _x_i1)
12070                   | TyVrnInf (_x, _x_i1) ->
12071                       let _x = o#loc _x in
12072                       let _x_i1 = o#ctyp _x_i1 in TyVrnInf (_x, _x_i1)
12073                   | TyVrnInfSup (_x, _x_i1, _x_i2) ->
12074                       let _x = o#loc _x in
12075                       let _x_i1 = o#ctyp _x_i1 in
12076                       let _x_i2 = o#ctyp _x_i2
12077                       in TyVrnInfSup (_x, _x_i1, _x_i2)
12078                   | TyAmp (_x, _x_i1, _x_i2) ->
12079                       let _x = o#loc _x in
12080                       let _x_i1 = o#ctyp _x_i1 in
12081                       let _x_i2 = o#ctyp _x_i2 in TyAmp (_x, _x_i1, _x_i2)
12082                   | TyOfAmp (_x, _x_i1, _x_i2) ->
12083                       let _x = o#loc _x in
12084                       let _x_i1 = o#ctyp _x_i1 in
12085                       let _x_i2 = o#ctyp _x_i2 in TyOfAmp (_x, _x_i1, _x_i2)
12086                   | TyAnt (_x, _x_i1) ->
12087                       let _x = o#loc _x in
12088                       let _x_i1 = o#string _x_i1 in TyAnt (_x, _x_i1)
12089                   
12090                 method class_type : class_type -> class_type =
12091                   function
12092                   | CtNil _x -> let _x = o#loc _x in CtNil _x
12093                   | CtCon (_x, _x_i1, _x_i2, _x_i3) ->
12094                       let _x = o#loc _x in
12095                       let _x_i1 = o#meta_bool _x_i1 in
12096                       let _x_i2 = o#ident _x_i2 in
12097                       let _x_i3 = o#ctyp _x_i3
12098                       in CtCon (_x, _x_i1, _x_i2, _x_i3)
12099                   | CtFun (_x, _x_i1, _x_i2) ->
12100                       let _x = o#loc _x in
12101                       let _x_i1 = o#ctyp _x_i1 in
12102                       let _x_i2 = o#class_type _x_i2
12103                       in CtFun (_x, _x_i1, _x_i2)
12104                   | CtSig (_x, _x_i1, _x_i2) ->
12105                       let _x = o#loc _x in
12106                       let _x_i1 = o#ctyp _x_i1 in
12107                       let _x_i2 = o#class_sig_item _x_i2
12108                       in CtSig (_x, _x_i1, _x_i2)
12109                   | CtAnd (_x, _x_i1, _x_i2) ->
12110                       let _x = o#loc _x in
12111                       let _x_i1 = o#class_type _x_i1 in
12112                       let _x_i2 = o#class_type _x_i2
12113                       in CtAnd (_x, _x_i1, _x_i2)
12114                   | CtCol (_x, _x_i1, _x_i2) ->
12115                       let _x = o#loc _x in
12116                       let _x_i1 = o#class_type _x_i1 in
12117                       let _x_i2 = o#class_type _x_i2
12118                       in CtCol (_x, _x_i1, _x_i2)
12119                   | CtEq (_x, _x_i1, _x_i2) ->
12120                       let _x = o#loc _x in
12121                       let _x_i1 = o#class_type _x_i1 in
12122                       let _x_i2 = o#class_type _x_i2
12123                       in CtEq (_x, _x_i1, _x_i2)
12124                   | CtAnt (_x, _x_i1) ->
12125                       let _x = o#loc _x in
12126                       let _x_i1 = o#string _x_i1 in CtAnt (_x, _x_i1)
12127                   
12128                 method class_str_item : class_str_item -> class_str_item =
12129                   function
12130                   | CrNil _x -> let _x = o#loc _x in CrNil _x
12131                   | CrSem (_x, _x_i1, _x_i2) ->
12132                       let _x = o#loc _x in
12133                       let _x_i1 = o#class_str_item _x_i1 in
12134                       let _x_i2 = o#class_str_item _x_i2
12135                       in CrSem (_x, _x_i1, _x_i2)
12136                   | CrCtr (_x, _x_i1, _x_i2) ->
12137                       let _x = o#loc _x in
12138                       let _x_i1 = o#ctyp _x_i1 in
12139                       let _x_i2 = o#ctyp _x_i2 in CrCtr (_x, _x_i1, _x_i2)
12140                   | CrInh (_x, _x_i1, _x_i2) ->
12141                       let _x = o#loc _x in
12142                       let _x_i1 = o#class_expr _x_i1 in
12143                       let _x_i2 = o#string _x_i2 in CrInh (_x, _x_i1, _x_i2)
12144                   | CrIni (_x, _x_i1) ->
12145                       let _x = o#loc _x in
12146                       let _x_i1 = o#expr _x_i1 in CrIni (_x, _x_i1)
12147                   | CrMth (_x, _x_i1, _x_i2, _x_i3, _x_i4) ->
12148                       let _x = o#loc _x in
12149                       let _x_i1 = o#string _x_i1 in
12150                       let _x_i2 = o#meta_bool _x_i2 in
12151                       let _x_i3 = o#expr _x_i3 in
12152                       let _x_i4 = o#ctyp _x_i4
12153                       in CrMth (_x, _x_i1, _x_i2, _x_i3, _x_i4)
12154                   | CrVal (_x, _x_i1, _x_i2, _x_i3) ->
12155                       let _x = o#loc _x in
12156                       let _x_i1 = o#string _x_i1 in
12157                       let _x_i2 = o#meta_bool _x_i2 in
12158                       let _x_i3 = o#expr _x_i3
12159                       in CrVal (_x, _x_i1, _x_i2, _x_i3)
12160                   | CrVir (_x, _x_i1, _x_i2, _x_i3) ->
12161                       let _x = o#loc _x in
12162                       let _x_i1 = o#string _x_i1 in
12163                       let _x_i2 = o#meta_bool _x_i2 in
12164                       let _x_i3 = o#ctyp _x_i3
12165                       in CrVir (_x, _x_i1, _x_i2, _x_i3)
12166                   | CrVvr (_x, _x_i1, _x_i2, _x_i3) ->
12167                       let _x = o#loc _x in
12168                       let _x_i1 = o#string _x_i1 in
12169                       let _x_i2 = o#meta_bool _x_i2 in
12170                       let _x_i3 = o#ctyp _x_i3
12171                       in CrVvr (_x, _x_i1, _x_i2, _x_i3)
12172                   | CrAnt (_x, _x_i1) ->
12173                       let _x = o#loc _x in
12174                       let _x_i1 = o#string _x_i1 in CrAnt (_x, _x_i1)
12175                   
12176                 method class_sig_item : class_sig_item -> class_sig_item =
12177                   function
12178                   | CgNil _x -> let _x = o#loc _x in CgNil _x
12179                   | CgCtr (_x, _x_i1, _x_i2) ->
12180                       let _x = o#loc _x in
12181                       let _x_i1 = o#ctyp _x_i1 in
12182                       let _x_i2 = o#ctyp _x_i2 in CgCtr (_x, _x_i1, _x_i2)
12183                   | CgSem (_x, _x_i1, _x_i2) ->
12184                       let _x = o#loc _x in
12185                       let _x_i1 = o#class_sig_item _x_i1 in
12186                       let _x_i2 = o#class_sig_item _x_i2
12187                       in CgSem (_x, _x_i1, _x_i2)
12188                   | CgInh (_x, _x_i1) ->
12189                       let _x = o#loc _x in
12190                       let _x_i1 = o#class_type _x_i1 in CgInh (_x, _x_i1)
12191                   | CgMth (_x, _x_i1, _x_i2, _x_i3) ->
12192                       let _x = o#loc _x in
12193                       let _x_i1 = o#string _x_i1 in
12194                       let _x_i2 = o#meta_bool _x_i2 in
12195                       let _x_i3 = o#ctyp _x_i3
12196                       in CgMth (_x, _x_i1, _x_i2, _x_i3)
12197                   | CgVal (_x, _x_i1, _x_i2, _x_i3, _x_i4) ->
12198                       let _x = o#loc _x in
12199                       let _x_i1 = o#string _x_i1 in
12200                       let _x_i2 = o#meta_bool _x_i2 in
12201                       let _x_i3 = o#meta_bool _x_i3 in
12202                       let _x_i4 = o#ctyp _x_i4
12203                       in CgVal (_x, _x_i1, _x_i2, _x_i3, _x_i4)
12204                   | CgVir (_x, _x_i1, _x_i2, _x_i3) ->
12205                       let _x = o#loc _x in
12206                       let _x_i1 = o#string _x_i1 in
12207                       let _x_i2 = o#meta_bool _x_i2 in
12208                       let _x_i3 = o#ctyp _x_i3
12209                       in CgVir (_x, _x_i1, _x_i2, _x_i3)
12210                   | CgAnt (_x, _x_i1) ->
12211                       let _x = o#loc _x in
12212                       let _x_i1 = o#string _x_i1 in CgAnt (_x, _x_i1)
12213                   
12214                 method class_expr : class_expr -> class_expr =
12215                   function
12216                   | CeNil _x -> let _x = o#loc _x in CeNil _x
12217                   | CeApp (_x, _x_i1, _x_i2) ->
12218                       let _x = o#loc _x in
12219                       let _x_i1 = o#class_expr _x_i1 in
12220                       let _x_i2 = o#expr _x_i2 in CeApp (_x, _x_i1, _x_i2)
12221                   | CeCon (_x, _x_i1, _x_i2, _x_i3) ->
12222                       let _x = o#loc _x in
12223                       let _x_i1 = o#meta_bool _x_i1 in
12224                       let _x_i2 = o#ident _x_i2 in
12225                       let _x_i3 = o#ctyp _x_i3
12226                       in CeCon (_x, _x_i1, _x_i2, _x_i3)
12227                   | CeFun (_x, _x_i1, _x_i2) ->
12228                       let _x = o#loc _x in
12229                       let _x_i1 = o#patt _x_i1 in
12230                       let _x_i2 = o#class_expr _x_i2
12231                       in CeFun (_x, _x_i1, _x_i2)
12232                   | CeLet (_x, _x_i1, _x_i2, _x_i3) ->
12233                       let _x = o#loc _x in
12234                       let _x_i1 = o#meta_bool _x_i1 in
12235                       let _x_i2 = o#binding _x_i2 in
12236                       let _x_i3 = o#class_expr _x_i3
12237                       in CeLet (_x, _x_i1, _x_i2, _x_i3)
12238                   | CeStr (_x, _x_i1, _x_i2) ->
12239                       let _x = o#loc _x in
12240                       let _x_i1 = o#patt _x_i1 in
12241                       let _x_i2 = o#class_str_item _x_i2
12242                       in CeStr (_x, _x_i1, _x_i2)
12243                   | CeTyc (_x, _x_i1, _x_i2) ->
12244                       let _x = o#loc _x in
12245                       let _x_i1 = o#class_expr _x_i1 in
12246                       let _x_i2 = o#class_type _x_i2
12247                       in CeTyc (_x, _x_i1, _x_i2)
12248                   | CeAnd (_x, _x_i1, _x_i2) ->
12249                       let _x = o#loc _x in
12250                       let _x_i1 = o#class_expr _x_i1 in
12251                       let _x_i2 = o#class_expr _x_i2
12252                       in CeAnd (_x, _x_i1, _x_i2)
12253                   | CeEq (_x, _x_i1, _x_i2) ->
12254                       let _x = o#loc _x in
12255                       let _x_i1 = o#class_expr _x_i1 in
12256                       let _x_i2 = o#class_expr _x_i2
12257                       in CeEq (_x, _x_i1, _x_i2)
12258                   | CeAnt (_x, _x_i1) ->
12259                       let _x = o#loc _x in
12260                       let _x_i1 = o#string _x_i1 in CeAnt (_x, _x_i1)
12261                   
12262                 method binding : binding -> binding =
12263                   function
12264                   | BiNil _x -> let _x = o#loc _x in BiNil _x
12265                   | BiAnd (_x, _x_i1, _x_i2) ->
12266                       let _x = o#loc _x in
12267                       let _x_i1 = o#binding _x_i1 in
12268                       let _x_i2 = o#binding _x_i2 in BiAnd (_x, _x_i1, _x_i2)
12269                   | BiEq (_x, _x_i1, _x_i2) ->
12270                       let _x = o#loc _x in
12271                       let _x_i1 = o#patt _x_i1 in
12272                       let _x_i2 = o#expr _x_i2 in BiEq (_x, _x_i1, _x_i2)
12273                   | BiAnt (_x, _x_i1) ->
12274                       let _x = o#loc _x in
12275                       let _x_i1 = o#string _x_i1 in BiAnt (_x, _x_i1)
12276                   
12277                 method unknown : 'a. 'a -> 'a = fun x -> x
12278                   
12279               end
12280               
12281             class fold =
12282               object ((o : 'self_type))
12283                 method string : string -> 'self_type = o#unknown
12284                   
12285                 method list :
12286                   'a.
12287                     ('self_type -> 'a -> 'self_type) -> 'a list -> 'self_type =
12288                   fun _f_a ->
12289                     function
12290                     | [] -> o
12291                     | _x :: _x_i1 ->
12292                         let o = _f_a o _x in let o = o#list _f_a _x_i1 in o
12293                   
12294                 method with_constr : with_constr -> 'self_type =
12295                   function
12296                   | WcNil _x -> let o = o#loc _x in o
12297                   | WcTyp (_x, _x_i1, _x_i2) ->
12298                       let o = o#loc _x in
12299                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12300                   | WcMod (_x, _x_i1, _x_i2) ->
12301                       let o = o#loc _x in
12302                       let o = o#ident _x_i1 in let o = o#ident _x_i2 in o
12303                   | WcAnd (_x, _x_i1, _x_i2) ->
12304                       let o = o#loc _x in
12305                       let o = o#with_constr _x_i1 in
12306                       let o = o#with_constr _x_i2 in o
12307                   | WcAnt (_x, _x_i1) ->
12308                       let o = o#loc _x in let o = o#string _x_i1 in o
12309                   
12310                 method str_item : str_item -> 'self_type =
12311                   function
12312                   | StNil _x -> let o = o#loc _x in o
12313                   | StCls (_x, _x_i1) ->
12314                       let o = o#loc _x in let o = o#class_expr _x_i1 in o
12315                   | StClt (_x, _x_i1) ->
12316                       let o = o#loc _x in let o = o#class_type _x_i1 in o
12317                   | StSem (_x, _x_i1, _x_i2) ->
12318                       let o = o#loc _x in
12319                       let o = o#str_item _x_i1 in
12320                       let o = o#str_item _x_i2 in o
12321                   | StDir (_x, _x_i1, _x_i2) ->
12322                       let o = o#loc _x in
12323                       let o = o#string _x_i1 in let o = o#expr _x_i2 in o
12324                   | StExc (_x, _x_i1, _x_i2) ->
12325                       let o = o#loc _x in
12326                       let o = o#ctyp _x_i1 in
12327                       let o = o#meta_option (fun o -> o#ident) _x_i2 in o
12328                   | StExp (_x, _x_i1) ->
12329                       let o = o#loc _x in let o = o#expr _x_i1 in o
12330                   | StExt (_x, _x_i1, _x_i2, _x_i3) ->
12331                       let o = o#loc _x in
12332                       let o = o#string _x_i1 in
12333                       let o = o#ctyp _x_i2 in
12334                       let o = o#meta_list (fun o -> o#string) _x_i3 in o
12335                   | StInc (_x, _x_i1) ->
12336                       let o = o#loc _x in let o = o#module_expr _x_i1 in o
12337                   | StMod (_x, _x_i1, _x_i2) ->
12338                       let o = o#loc _x in
12339                       let o = o#string _x_i1 in
12340                       let o = o#module_expr _x_i2 in o
12341                   | StRecMod (_x, _x_i1) ->
12342                       let o = o#loc _x in let o = o#module_binding _x_i1 in o
12343                   | StMty (_x, _x_i1, _x_i2) ->
12344                       let o = o#loc _x in
12345                       let o = o#string _x_i1 in
12346                       let o = o#module_type _x_i2 in o
12347                   | StOpn (_x, _x_i1) ->
12348                       let o = o#loc _x in let o = o#ident _x_i1 in o
12349                   | StTyp (_x, _x_i1) ->
12350                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12351                   | StVal (_x, _x_i1, _x_i2) ->
12352                       let o = o#loc _x in
12353                       let o = o#meta_bool _x_i1 in
12354                       let o = o#binding _x_i2 in o
12355                   | StAnt (_x, _x_i1) ->
12356                       let o = o#loc _x in let o = o#string _x_i1 in o
12357                   
12358                 method sig_item : sig_item -> 'self_type =
12359                   function
12360                   | SgNil _x -> let o = o#loc _x in o
12361                   | SgCls (_x, _x_i1) ->
12362                       let o = o#loc _x in let o = o#class_type _x_i1 in o
12363                   | SgClt (_x, _x_i1) ->
12364                       let o = o#loc _x in let o = o#class_type _x_i1 in o
12365                   | SgSem (_x, _x_i1, _x_i2) ->
12366                       let o = o#loc _x in
12367                       let o = o#sig_item _x_i1 in
12368                       let o = o#sig_item _x_i2 in o
12369                   | SgDir (_x, _x_i1, _x_i2) ->
12370                       let o = o#loc _x in
12371                       let o = o#string _x_i1 in let o = o#expr _x_i2 in o
12372                   | SgExc (_x, _x_i1) ->
12373                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12374                   | SgExt (_x, _x_i1, _x_i2, _x_i3) ->
12375                       let o = o#loc _x in
12376                       let o = o#string _x_i1 in
12377                       let o = o#ctyp _x_i2 in
12378                       let o = o#meta_list (fun o -> o#string) _x_i3 in o
12379                   | SgInc (_x, _x_i1) ->
12380                       let o = o#loc _x in let o = o#module_type _x_i1 in o
12381                   | SgMod (_x, _x_i1, _x_i2) ->
12382                       let o = o#loc _x in
12383                       let o = o#string _x_i1 in
12384                       let o = o#module_type _x_i2 in o
12385                   | SgRecMod (_x, _x_i1) ->
12386                       let o = o#loc _x in let o = o#module_binding _x_i1 in o
12387                   | SgMty (_x, _x_i1, _x_i2) ->
12388                       let o = o#loc _x in
12389                       let o = o#string _x_i1 in
12390                       let o = o#module_type _x_i2 in o
12391                   | SgOpn (_x, _x_i1) ->
12392                       let o = o#loc _x in let o = o#ident _x_i1 in o
12393                   | SgTyp (_x, _x_i1) ->
12394                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12395                   | SgVal (_x, _x_i1, _x_i2) ->
12396                       let o = o#loc _x in
12397                       let o = o#string _x_i1 in let o = o#ctyp _x_i2 in o
12398                   | SgAnt (_x, _x_i1) ->
12399                       let o = o#loc _x in let o = o#string _x_i1 in o
12400                   
12401                 method rec_binding : rec_binding -> 'self_type =
12402                   function
12403                   | RbNil _x -> let o = o#loc _x in o
12404                   | RbSem (_x, _x_i1, _x_i2) ->
12405                       let o = o#loc _x in
12406                       let o = o#rec_binding _x_i1 in
12407                       let o = o#rec_binding _x_i2 in o
12408                   | RbEq (_x, _x_i1, _x_i2) ->
12409                       let o = o#loc _x in
12410                       let o = o#ident _x_i1 in let o = o#expr _x_i2 in o
12411                   | RbAnt (_x, _x_i1) ->
12412                       let o = o#loc _x in let o = o#string _x_i1 in o
12413                   
12414                 method patt : patt -> 'self_type =
12415                   function
12416                   | PaNil _x -> let o = o#loc _x in o
12417                   | PaId (_x, _x_i1) ->
12418                       let o = o#loc _x in let o = o#ident _x_i1 in o
12419                   | PaAli (_x, _x_i1, _x_i2) ->
12420                       let o = o#loc _x in
12421                       let o = o#patt _x_i1 in let o = o#patt _x_i2 in o
12422                   | PaAnt (_x, _x_i1) ->
12423                       let o = o#loc _x in let o = o#string _x_i1 in o
12424                   | PaAny _x -> let o = o#loc _x in o
12425                   | PaApp (_x, _x_i1, _x_i2) ->
12426                       let o = o#loc _x in
12427                       let o = o#patt _x_i1 in let o = o#patt _x_i2 in o
12428                   | PaArr (_x, _x_i1) ->
12429                       let o = o#loc _x in let o = o#patt _x_i1 in o
12430                   | PaCom (_x, _x_i1, _x_i2) ->
12431                       let o = o#loc _x in
12432                       let o = o#patt _x_i1 in let o = o#patt _x_i2 in o
12433                   | PaSem (_x, _x_i1, _x_i2) ->
12434                       let o = o#loc _x in
12435                       let o = o#patt _x_i1 in let o = o#patt _x_i2 in o
12436                   | PaChr (_x, _x_i1) ->
12437                       let o = o#loc _x in let o = o#string _x_i1 in o
12438                   | PaInt (_x, _x_i1) ->
12439                       let o = o#loc _x in let o = o#string _x_i1 in o
12440                   | PaInt32 (_x, _x_i1) ->
12441                       let o = o#loc _x in let o = o#string _x_i1 in o
12442                   | PaInt64 (_x, _x_i1) ->
12443                       let o = o#loc _x in let o = o#string _x_i1 in o
12444                   | PaNativeInt (_x, _x_i1) ->
12445                       let o = o#loc _x in let o = o#string _x_i1 in o
12446                   | PaFlo (_x, _x_i1) ->
12447                       let o = o#loc _x in let o = o#string _x_i1 in o
12448                   | PaLab (_x, _x_i1, _x_i2) ->
12449                       let o = o#loc _x in
12450                       let o = o#string _x_i1 in let o = o#patt _x_i2 in o
12451                   | PaOlb (_x, _x_i1, _x_i2) ->
12452                       let o = o#loc _x in
12453                       let o = o#string _x_i1 in let o = o#patt _x_i2 in o
12454                   | PaOlbi (_x, _x_i1, _x_i2, _x_i3) ->
12455                       let o = o#loc _x in
12456                       let o = o#string _x_i1 in
12457                       let o = o#patt _x_i2 in let o = o#expr _x_i3 in o
12458                   | PaOrp (_x, _x_i1, _x_i2) ->
12459                       let o = o#loc _x in
12460                       let o = o#patt _x_i1 in let o = o#patt _x_i2 in o
12461                   | PaRng (_x, _x_i1, _x_i2) ->
12462                       let o = o#loc _x in
12463                       let o = o#patt _x_i1 in let o = o#patt _x_i2 in o
12464                   | PaRec (_x, _x_i1) ->
12465                       let o = o#loc _x in let o = o#patt _x_i1 in o
12466                   | PaEq (_x, _x_i1, _x_i2) ->
12467                       let o = o#loc _x in
12468                       let o = o#ident _x_i1 in let o = o#patt _x_i2 in o
12469                   | PaStr (_x, _x_i1) ->
12470                       let o = o#loc _x in let o = o#string _x_i1 in o
12471                   | PaTup (_x, _x_i1) ->
12472                       let o = o#loc _x in let o = o#patt _x_i1 in o
12473                   | PaTyc (_x, _x_i1, _x_i2) ->
12474                       let o = o#loc _x in
12475                       let o = o#patt _x_i1 in let o = o#ctyp _x_i2 in o
12476                   | PaTyp (_x, _x_i1) ->
12477                       let o = o#loc _x in let o = o#ident _x_i1 in o
12478                   | PaVrn (_x, _x_i1) ->
12479                       let o = o#loc _x in let o = o#string _x_i1 in o
12480                   | PaLaz (_x, _x_i1) ->
12481                       let o = o#loc _x in let o = o#patt _x_i1 in o
12482                   
12483                 method module_type : module_type -> 'self_type =
12484                   function
12485                   | MtNil _x -> let o = o#loc _x in o
12486                   | MtId (_x, _x_i1) ->
12487                       let o = o#loc _x in let o = o#ident _x_i1 in o
12488                   | MtFun (_x, _x_i1, _x_i2, _x_i3) ->
12489                       let o = o#loc _x in
12490                       let o = o#string _x_i1 in
12491                       let o = o#module_type _x_i2 in
12492                       let o = o#module_type _x_i3 in o
12493                   | MtQuo (_x, _x_i1) ->
12494                       let o = o#loc _x in let o = o#string _x_i1 in o
12495                   | MtSig (_x, _x_i1) ->
12496                       let o = o#loc _x in let o = o#sig_item _x_i1 in o
12497                   | MtWit (_x, _x_i1, _x_i2) ->
12498                       let o = o#loc _x in
12499                       let o = o#module_type _x_i1 in
12500                       let o = o#with_constr _x_i2 in o
12501                   | MtAnt (_x, _x_i1) ->
12502                       let o = o#loc _x in let o = o#string _x_i1 in o
12503                   
12504                 method module_expr : module_expr -> 'self_type =
12505                   function
12506                   | MeNil _x -> let o = o#loc _x in o
12507                   | MeId (_x, _x_i1) ->
12508                       let o = o#loc _x in let o = o#ident _x_i1 in o
12509                   | MeApp (_x, _x_i1, _x_i2) ->
12510                       let o = o#loc _x in
12511                       let o = o#module_expr _x_i1 in
12512                       let o = o#module_expr _x_i2 in o
12513                   | MeFun (_x, _x_i1, _x_i2, _x_i3) ->
12514                       let o = o#loc _x in
12515                       let o = o#string _x_i1 in
12516                       let o = o#module_type _x_i2 in
12517                       let o = o#module_expr _x_i3 in o
12518                   | MeStr (_x, _x_i1) ->
12519                       let o = o#loc _x in let o = o#str_item _x_i1 in o
12520                   | MeTyc (_x, _x_i1, _x_i2) ->
12521                       let o = o#loc _x in
12522                       let o = o#module_expr _x_i1 in
12523                       let o = o#module_type _x_i2 in o
12524                   | MeAnt (_x, _x_i1) ->
12525                       let o = o#loc _x in let o = o#string _x_i1 in o
12526                   
12527                 method module_binding : module_binding -> 'self_type =
12528                   function
12529                   | MbNil _x -> let o = o#loc _x in o
12530                   | MbAnd (_x, _x_i1, _x_i2) ->
12531                       let o = o#loc _x in
12532                       let o = o#module_binding _x_i1 in
12533                       let o = o#module_binding _x_i2 in o
12534                   | MbColEq (_x, _x_i1, _x_i2, _x_i3) ->
12535                       let o = o#loc _x in
12536                       let o = o#string _x_i1 in
12537                       let o = o#module_type _x_i2 in
12538                       let o = o#module_expr _x_i3 in o
12539                   | MbCol (_x, _x_i1, _x_i2) ->
12540                       let o = o#loc _x in
12541                       let o = o#string _x_i1 in
12542                       let o = o#module_type _x_i2 in o
12543                   | MbAnt (_x, _x_i1) ->
12544                       let o = o#loc _x in let o = o#string _x_i1 in o
12545                   
12546                 method meta_option :
12547                   'a.
12548                     ('self_type -> 'a -> 'self_type) ->
12549                       'a meta_option -> 'self_type =
12550                   fun _f_a ->
12551                     function
12552                     | ONone -> o
12553                     | OSome _x -> let o = _f_a o _x in o
12554                     | OAnt _x -> let o = o#string _x in o
12555                   
12556                 method meta_list :
12557                   'a.
12558                     ('self_type -> 'a -> 'self_type) ->
12559                       'a meta_list -> 'self_type =
12560                   fun _f_a ->
12561                     function
12562                     | LNil -> o
12563                     | LCons (_x, _x_i1) ->
12564                         let o = _f_a o _x in
12565                         let o = o#meta_list _f_a _x_i1 in o
12566                     | LAnt _x -> let o = o#string _x in o
12567                   
12568                 method meta_bool : meta_bool -> 'self_type =
12569                   function
12570                   | BTrue -> o
12571                   | BFalse -> o
12572                   | BAnt _x -> let o = o#string _x in o
12573                   
12574                 method match_case : match_case -> 'self_type =
12575                   function
12576                   | McNil _x -> let o = o#loc _x in o
12577                   | McOr (_x, _x_i1, _x_i2) ->
12578                       let o = o#loc _x in
12579                       let o = o#match_case _x_i1 in
12580                       let o = o#match_case _x_i2 in o
12581                   | McArr (_x, _x_i1, _x_i2, _x_i3) ->
12582                       let o = o#loc _x in
12583                       let o = o#patt _x_i1 in
12584                       let o = o#expr _x_i2 in let o = o#expr _x_i3 in o
12585                   | McAnt (_x, _x_i1) ->
12586                       let o = o#loc _x in let o = o#string _x_i1 in o
12587                   
12588                 method loc : loc -> 'self_type = o#unknown
12589                   
12590                 method ident : ident -> 'self_type =
12591                   function
12592                   | IdAcc (_x, _x_i1, _x_i2) ->
12593                       let o = o#loc _x in
12594                       let o = o#ident _x_i1 in let o = o#ident _x_i2 in o
12595                   | IdApp (_x, _x_i1, _x_i2) ->
12596                       let o = o#loc _x in
12597                       let o = o#ident _x_i1 in let o = o#ident _x_i2 in o
12598                   | IdLid (_x, _x_i1) ->
12599                       let o = o#loc _x in let o = o#string _x_i1 in o
12600                   | IdUid (_x, _x_i1) ->
12601                       let o = o#loc _x in let o = o#string _x_i1 in o
12602                   | IdAnt (_x, _x_i1) ->
12603                       let o = o#loc _x in let o = o#string _x_i1 in o
12604                   
12605                 method expr : expr -> 'self_type =
12606                   function
12607                   | ExNil _x -> let o = o#loc _x in o
12608                   | ExId (_x, _x_i1) ->
12609                       let o = o#loc _x in let o = o#ident _x_i1 in o
12610                   | ExAcc (_x, _x_i1, _x_i2) ->
12611                       let o = o#loc _x in
12612                       let o = o#expr _x_i1 in let o = o#expr _x_i2 in o
12613                   | ExAnt (_x, _x_i1) ->
12614                       let o = o#loc _x in let o = o#string _x_i1 in o
12615                   | ExApp (_x, _x_i1, _x_i2) ->
12616                       let o = o#loc _x in
12617                       let o = o#expr _x_i1 in let o = o#expr _x_i2 in o
12618                   | ExAre (_x, _x_i1, _x_i2) ->
12619                       let o = o#loc _x in
12620                       let o = o#expr _x_i1 in let o = o#expr _x_i2 in o
12621                   | ExArr (_x, _x_i1) ->
12622                       let o = o#loc _x in let o = o#expr _x_i1 in o
12623                   | ExSem (_x, _x_i1, _x_i2) ->
12624                       let o = o#loc _x in
12625                       let o = o#expr _x_i1 in let o = o#expr _x_i2 in o
12626                   | ExAsf _x -> let o = o#loc _x in o
12627                   | ExAsr (_x, _x_i1) ->
12628                       let o = o#loc _x in let o = o#expr _x_i1 in o
12629                   | ExAss (_x, _x_i1, _x_i2) ->
12630                       let o = o#loc _x in
12631                       let o = o#expr _x_i1 in let o = o#expr _x_i2 in o
12632                   | ExChr (_x, _x_i1) ->
12633                       let o = o#loc _x in let o = o#string _x_i1 in o
12634                   | ExCoe (_x, _x_i1, _x_i2, _x_i3) ->
12635                       let o = o#loc _x in
12636                       let o = o#expr _x_i1 in
12637                       let o = o#ctyp _x_i2 in let o = o#ctyp _x_i3 in o
12638                   | ExFlo (_x, _x_i1) ->
12639                       let o = o#loc _x in let o = o#string _x_i1 in o
12640                   | ExFor (_x, _x_i1, _x_i2, _x_i3, _x_i4, _x_i5) ->
12641                       let o = o#loc _x in
12642                       let o = o#string _x_i1 in
12643                       let o = o#expr _x_i2 in
12644                       let o = o#expr _x_i3 in
12645                       let o = o#meta_bool _x_i4 in let o = o#expr _x_i5 in o
12646                   | ExFun (_x, _x_i1) ->
12647                       let o = o#loc _x in let o = o#match_case _x_i1 in o
12648                   | ExIfe (_x, _x_i1, _x_i2, _x_i3) ->
12649                       let o = o#loc _x in
12650                       let o = o#expr _x_i1 in
12651                       let o = o#expr _x_i2 in let o = o#expr _x_i3 in o
12652                   | ExInt (_x, _x_i1) ->
12653                       let o = o#loc _x in let o = o#string _x_i1 in o
12654                   | ExInt32 (_x, _x_i1) ->
12655                       let o = o#loc _x in let o = o#string _x_i1 in o
12656                   | ExInt64 (_x, _x_i1) ->
12657                       let o = o#loc _x in let o = o#string _x_i1 in o
12658                   | ExNativeInt (_x, _x_i1) ->
12659                       let o = o#loc _x in let o = o#string _x_i1 in o
12660                   | ExLab (_x, _x_i1, _x_i2) ->
12661                       let o = o#loc _x in
12662                       let o = o#string _x_i1 in let o = o#expr _x_i2 in o
12663                   | ExLaz (_x, _x_i1) ->
12664                       let o = o#loc _x in let o = o#expr _x_i1 in o
12665                   | ExLet (_x, _x_i1, _x_i2, _x_i3) ->
12666                       let o = o#loc _x in
12667                       let o = o#meta_bool _x_i1 in
12668                       let o = o#binding _x_i2 in let o = o#expr _x_i3 in o
12669                   | ExLmd (_x, _x_i1, _x_i2, _x_i3) ->
12670                       let o = o#loc _x in
12671                       let o = o#string _x_i1 in
12672                       let o = o#module_expr _x_i2 in
12673                       let o = o#expr _x_i3 in o
12674                   | ExMat (_x, _x_i1, _x_i2) ->
12675                       let o = o#loc _x in
12676                       let o = o#expr _x_i1 in let o = o#match_case _x_i2 in o
12677                   | ExNew (_x, _x_i1) ->
12678                       let o = o#loc _x in let o = o#ident _x_i1 in o
12679                   | ExObj (_x, _x_i1, _x_i2) ->
12680                       let o = o#loc _x in
12681                       let o = o#patt _x_i1 in
12682                       let o = o#class_str_item _x_i2 in o
12683                   | ExOlb (_x, _x_i1, _x_i2) ->
12684                       let o = o#loc _x in
12685                       let o = o#string _x_i1 in let o = o#expr _x_i2 in o
12686                   | ExOvr (_x, _x_i1) ->
12687                       let o = o#loc _x in let o = o#rec_binding _x_i1 in o
12688                   | ExRec (_x, _x_i1, _x_i2) ->
12689                       let o = o#loc _x in
12690                       let o = o#rec_binding _x_i1 in
12691                       let o = o#expr _x_i2 in o
12692                   | ExSeq (_x, _x_i1) ->
12693                       let o = o#loc _x in let o = o#expr _x_i1 in o
12694                   | ExSnd (_x, _x_i1, _x_i2) ->
12695                       let o = o#loc _x in
12696                       let o = o#expr _x_i1 in let o = o#string _x_i2 in o
12697                   | ExSte (_x, _x_i1, _x_i2) ->
12698                       let o = o#loc _x in
12699                       let o = o#expr _x_i1 in let o = o#expr _x_i2 in o
12700                   | ExStr (_x, _x_i1) ->
12701                       let o = o#loc _x in let o = o#string _x_i1 in o
12702                   | ExTry (_x, _x_i1, _x_i2) ->
12703                       let o = o#loc _x in
12704                       let o = o#expr _x_i1 in let o = o#match_case _x_i2 in o
12705                   | ExTup (_x, _x_i1) ->
12706                       let o = o#loc _x in let o = o#expr _x_i1 in o
12707                   | ExCom (_x, _x_i1, _x_i2) ->
12708                       let o = o#loc _x in
12709                       let o = o#expr _x_i1 in let o = o#expr _x_i2 in o
12710                   | ExTyc (_x, _x_i1, _x_i2) ->
12711                       let o = o#loc _x in
12712                       let o = o#expr _x_i1 in let o = o#ctyp _x_i2 in o
12713                   | ExVrn (_x, _x_i1) ->
12714                       let o = o#loc _x in let o = o#string _x_i1 in o
12715                   | ExWhi (_x, _x_i1, _x_i2) ->
12716                       let o = o#loc _x in
12717                       let o = o#expr _x_i1 in let o = o#expr _x_i2 in o
12718                   
12719                 method ctyp : ctyp -> 'self_type =
12720                   function
12721                   | TyNil _x -> let o = o#loc _x in o
12722                   | TyAli (_x, _x_i1, _x_i2) ->
12723                       let o = o#loc _x in
12724                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12725                   | TyAny _x -> let o = o#loc _x in o
12726                   | TyApp (_x, _x_i1, _x_i2) ->
12727                       let o = o#loc _x in
12728                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12729                   | TyArr (_x, _x_i1, _x_i2) ->
12730                       let o = o#loc _x in
12731                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12732                   | TyCls (_x, _x_i1) ->
12733                       let o = o#loc _x in let o = o#ident _x_i1 in o
12734                   | TyLab (_x, _x_i1, _x_i2) ->
12735                       let o = o#loc _x in
12736                       let o = o#string _x_i1 in let o = o#ctyp _x_i2 in o
12737                   | TyId (_x, _x_i1) ->
12738                       let o = o#loc _x in let o = o#ident _x_i1 in o
12739                   | TyMan (_x, _x_i1, _x_i2) ->
12740                       let o = o#loc _x in
12741                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12742                   | TyDcl (_x, _x_i1, _x_i2, _x_i3, _x_i4) ->
12743                       let o = o#loc _x in
12744                       let o = o#string _x_i1 in
12745                       let o = o#list (fun o -> o#ctyp) _x_i2 in
12746                       let o = o#ctyp _x_i3 in
12747                       let o =
12748                         o#list
12749                           (fun o (_x, _x_i1) ->
12750                              let o = o#ctyp _x in let o = o#ctyp _x_i1 in o)
12751                           _x_i4
12752                       in o
12753                   | TyObj (_x, _x_i1, _x_i2) ->
12754                       let o = o#loc _x in
12755                       let o = o#ctyp _x_i1 in let o = o#meta_bool _x_i2 in o
12756                   | TyOlb (_x, _x_i1, _x_i2) ->
12757                       let o = o#loc _x in
12758                       let o = o#string _x_i1 in let o = o#ctyp _x_i2 in o
12759                   | TyPol (_x, _x_i1, _x_i2) ->
12760                       let o = o#loc _x in
12761                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12762                   | TyQuo (_x, _x_i1) ->
12763                       let o = o#loc _x in let o = o#string _x_i1 in o
12764                   | TyQuP (_x, _x_i1) ->
12765                       let o = o#loc _x in let o = o#string _x_i1 in o
12766                   | TyQuM (_x, _x_i1) ->
12767                       let o = o#loc _x in let o = o#string _x_i1 in o
12768                   | TyVrn (_x, _x_i1) ->
12769                       let o = o#loc _x in let o = o#string _x_i1 in o
12770                   | TyRec (_x, _x_i1) ->
12771                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12772                   | TyCol (_x, _x_i1, _x_i2) ->
12773                       let o = o#loc _x in
12774                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12775                   | TySem (_x, _x_i1, _x_i2) ->
12776                       let o = o#loc _x in
12777                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12778                   | TyCom (_x, _x_i1, _x_i2) ->
12779                       let o = o#loc _x in
12780                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12781                   | TySum (_x, _x_i1) ->
12782                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12783                   | TyOf (_x, _x_i1, _x_i2) ->
12784                       let o = o#loc _x in
12785                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12786                   | TyAnd (_x, _x_i1, _x_i2) ->
12787                       let o = o#loc _x in
12788                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12789                   | TyOr (_x, _x_i1, _x_i2) ->
12790                       let o = o#loc _x in
12791                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12792                   | TyPrv (_x, _x_i1) ->
12793                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12794                   | TyMut (_x, _x_i1) ->
12795                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12796                   | TyTup (_x, _x_i1) ->
12797                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12798                   | TySta (_x, _x_i1, _x_i2) ->
12799                       let o = o#loc _x in
12800                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12801                   | TyVrnEq (_x, _x_i1) ->
12802                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12803                   | TyVrnSup (_x, _x_i1) ->
12804                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12805                   | TyVrnInf (_x, _x_i1) ->
12806                       let o = o#loc _x in let o = o#ctyp _x_i1 in o
12807                   | TyVrnInfSup (_x, _x_i1, _x_i2) ->
12808                       let o = o#loc _x in
12809                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12810                   | TyAmp (_x, _x_i1, _x_i2) ->
12811                       let o = o#loc _x in
12812                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12813                   | TyOfAmp (_x, _x_i1, _x_i2) ->
12814                       let o = o#loc _x in
12815                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12816                   | TyAnt (_x, _x_i1) ->
12817                       let o = o#loc _x in let o = o#string _x_i1 in o
12818                   
12819                 method class_type : class_type -> 'self_type =
12820                   function
12821                   | CtNil _x -> let o = o#loc _x in o
12822                   | CtCon (_x, _x_i1, _x_i2, _x_i3) ->
12823                       let o = o#loc _x in
12824                       let o = o#meta_bool _x_i1 in
12825                       let o = o#ident _x_i2 in let o = o#ctyp _x_i3 in o
12826                   | CtFun (_x, _x_i1, _x_i2) ->
12827                       let o = o#loc _x in
12828                       let o = o#ctyp _x_i1 in let o = o#class_type _x_i2 in o
12829                   | CtSig (_x, _x_i1, _x_i2) ->
12830                       let o = o#loc _x in
12831                       let o = o#ctyp _x_i1 in
12832                       let o = o#class_sig_item _x_i2 in o
12833                   | CtAnd (_x, _x_i1, _x_i2) ->
12834                       let o = o#loc _x in
12835                       let o = o#class_type _x_i1 in
12836                       let o = o#class_type _x_i2 in o
12837                   | CtCol (_x, _x_i1, _x_i2) ->
12838                       let o = o#loc _x in
12839                       let o = o#class_type _x_i1 in
12840                       let o = o#class_type _x_i2 in o
12841                   | CtEq (_x, _x_i1, _x_i2) ->
12842                       let o = o#loc _x in
12843                       let o = o#class_type _x_i1 in
12844                       let o = o#class_type _x_i2 in o
12845                   | CtAnt (_x, _x_i1) ->
12846                       let o = o#loc _x in let o = o#string _x_i1 in o
12847                   
12848                 method class_str_item : class_str_item -> 'self_type =
12849                   function
12850                   | CrNil _x -> let o = o#loc _x in o
12851                   | CrSem (_x, _x_i1, _x_i2) ->
12852                       let o = o#loc _x in
12853                       let o = o#class_str_item _x_i1 in
12854                       let o = o#class_str_item _x_i2 in o
12855                   | CrCtr (_x, _x_i1, _x_i2) ->
12856                       let o = o#loc _x in
12857                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12858                   | CrInh (_x, _x_i1, _x_i2) ->
12859                       let o = o#loc _x in
12860                       let o = o#class_expr _x_i1 in
12861                       let o = o#string _x_i2 in o
12862                   | CrIni (_x, _x_i1) ->
12863                       let o = o#loc _x in let o = o#expr _x_i1 in o
12864                   | CrMth (_x, _x_i1, _x_i2, _x_i3, _x_i4) ->
12865                       let o = o#loc _x in
12866                       let o = o#string _x_i1 in
12867                       let o = o#meta_bool _x_i2 in
12868                       let o = o#expr _x_i3 in let o = o#ctyp _x_i4 in o
12869                   | CrVal (_x, _x_i1, _x_i2, _x_i3) ->
12870                       let o = o#loc _x in
12871                       let o = o#string _x_i1 in
12872                       let o = o#meta_bool _x_i2 in let o = o#expr _x_i3 in o
12873                   | CrVir (_x, _x_i1, _x_i2, _x_i3) ->
12874                       let o = o#loc _x in
12875                       let o = o#string _x_i1 in
12876                       let o = o#meta_bool _x_i2 in let o = o#ctyp _x_i3 in o
12877                   | CrVvr (_x, _x_i1, _x_i2, _x_i3) ->
12878                       let o = o#loc _x in
12879                       let o = o#string _x_i1 in
12880                       let o = o#meta_bool _x_i2 in let o = o#ctyp _x_i3 in o
12881                   | CrAnt (_x, _x_i1) ->
12882                       let o = o#loc _x in let o = o#string _x_i1 in o
12883                   
12884                 method class_sig_item : class_sig_item -> 'self_type =
12885                   function
12886                   | CgNil _x -> let o = o#loc _x in o
12887                   | CgCtr (_x, _x_i1, _x_i2) ->
12888                       let o = o#loc _x in
12889                       let o = o#ctyp _x_i1 in let o = o#ctyp _x_i2 in o
12890                   | CgSem (_x, _x_i1, _x_i2) ->
12891                       let o = o#loc _x in
12892                       let o = o#class_sig_item _x_i1 in
12893                       let o = o#class_sig_item _x_i2 in o
12894                   | CgInh (_x, _x_i1) ->
12895                       let o = o#loc _x in let o = o#class_type _x_i1 in o
12896                   | CgMth (_x, _x_i1, _x_i2, _x_i3) ->
12897                       let o = o#loc _x in
12898                       let o = o#string _x_i1 in
12899                       let o = o#meta_bool _x_i2 in let o = o#ctyp _x_i3 in o
12900                   | CgVal (_x, _x_i1, _x_i2, _x_i3, _x_i4) ->
12901                       let o = o#loc _x in
12902                       let o = o#string _x_i1 in
12903                       let o = o#meta_bool _x_i2 in
12904                       let o = o#meta_bool _x_i3 in let o = o#ctyp _x_i4 in o
12905                   | CgVir (_x, _x_i1, _x_i2, _x_i3) ->
12906                       let o = o#loc _x in
12907                       let o = o#string _x_i1 in
12908                       let o = o#meta_bool _x_i2 in let o = o#ctyp _x_i3 in o
12909                   | CgAnt (_x, _x_i1) ->
12910                       let o = o#loc _x in let o = o#string _x_i1 in o
12911                   
12912                 method class_expr : class_expr -> 'self_type =
12913                   function
12914                   | CeNil _x -> let o = o#loc _x in o
12915                   | CeApp (_x, _x_i1, _x_i2) ->
12916                       let o = o#loc _x in
12917                       let o = o#class_expr _x_i1 in let o = o#expr _x_i2 in o
12918                   | CeCon (_x, _x_i1, _x_i2, _x_i3) ->
12919                       let o = o#loc _x in
12920                       let o = o#meta_bool _x_i1 in
12921                       let o = o#ident _x_i2 in let o = o#ctyp _x_i3 in o
12922                   | CeFun (_x, _x_i1, _x_i2) ->
12923                       let o = o#loc _x in
12924                       let o = o#patt _x_i1 in let o = o#class_expr _x_i2 in o
12925                   | CeLet (_x, _x_i1, _x_i2, _x_i3) ->
12926                       let o = o#loc _x in
12927                       let o = o#meta_bool _x_i1 in
12928                       let o = o#binding _x_i2 in
12929                       let o = o#class_expr _x_i3 in o
12930                   | CeStr (_x, _x_i1, _x_i2) ->
12931                       let o = o#loc _x in
12932                       let o = o#patt _x_i1 in
12933                       let o = o#class_str_item _x_i2 in o
12934                   | CeTyc (_x, _x_i1, _x_i2) ->
12935                       let o = o#loc _x in
12936                       let o = o#class_expr _x_i1 in
12937                       let o = o#class_type _x_i2 in o
12938                   | CeAnd (_x, _x_i1, _x_i2) ->
12939                       let o = o#loc _x in
12940                       let o = o#class_expr _x_i1 in
12941                       let o = o#class_expr _x_i2 in o
12942                   | CeEq (_x, _x_i1, _x_i2) ->
12943                       let o = o#loc _x in
12944                       let o = o#class_expr _x_i1 in
12945                       let o = o#class_expr _x_i2 in o
12946                   | CeAnt (_x, _x_i1) ->
12947                       let o = o#loc _x in let o = o#string _x_i1 in o
12948                   
12949                 method binding : binding -> 'self_type =
12950                   function
12951                   | BiNil _x -> let o = o#loc _x in o
12952                   | BiAnd (_x, _x_i1, _x_i2) ->
12953                       let o = o#loc _x in
12954                       let o = o#binding _x_i1 in let o = o#binding _x_i2 in o
12955                   | BiEq (_x, _x_i1, _x_i2) ->
12956                       let o = o#loc _x in
12957                       let o = o#patt _x_i1 in let o = o#expr _x_i2 in o
12958                   | BiAnt (_x, _x_i1) ->
12959                       let o = o#loc _x in let o = o#string _x_i1 in o
12960                   
12961                 method unknown : 'a. 'a -> 'self_type = fun _ -> o
12962                   
12963               end
12964               
12965             let map_expr f =
12966               object
12967                 inherit map as super
12968                   
12969                 method expr = fun x -> f (super#expr x)
12970                   
12971               end
12972               
12973             let map_patt f =
12974               object
12975                 inherit map as super
12976                   
12977                 method patt = fun x -> f (super#patt x)
12978                   
12979               end
12980               
12981             let map_ctyp f =
12982               object
12983                 inherit map as super
12984                   
12985                 method ctyp = fun x -> f (super#ctyp x)
12986                   
12987               end
12988               
12989             let map_str_item f =
12990               object
12991                 inherit map as super
12992                   
12993                 method str_item = fun x -> f (super#str_item x)
12994                   
12995               end
12996               
12997             let map_sig_item f =
12998               object
12999                 inherit map as super
13000                   
13001                 method sig_item = fun x -> f (super#sig_item x)
13002                   
13003               end
13004               
13005             let map_loc f =
13006               object
13007                 inherit map as super
13008                   
13009                 method loc = fun x -> f (super#loc x)
13010                   
13011               end
13012               
13013           end
13014           
13015       end
13016       
13017     module DynAst =
13018       struct
13019         module Make (Ast : Sig.Ast) : Sig.DynAst with module Ast = Ast =
13020           struct
13021             module Ast = Ast
13022               
13023             type 'a tag =
13024               | Tag_ctyp
13025               | Tag_patt
13026               | Tag_expr
13027               | Tag_module_type
13028               | Tag_sig_item
13029               | Tag_with_constr
13030               | Tag_module_expr
13031               | Tag_str_item
13032               | Tag_class_type
13033               | Tag_class_sig_item
13034               | Tag_class_expr
13035               | Tag_class_str_item
13036               | Tag_match_case
13037               | Tag_ident
13038               | Tag_binding
13039               | Tag_rec_binding
13040               | Tag_module_binding
13041             
13042             let string_of_tag =
13043               function
13044               | Tag_ctyp -> "ctyp"
13045               | Tag_patt -> "patt"
13046               | Tag_expr -> "expr"
13047               | Tag_module_type -> "module_type"
13048               | Tag_sig_item -> "sig_item"
13049               | Tag_with_constr -> "with_constr"
13050               | Tag_module_expr -> "module_expr"
13051               | Tag_str_item -> "str_item"
13052               | Tag_class_type -> "class_type"
13053               | Tag_class_sig_item -> "class_sig_item"
13054               | Tag_class_expr -> "class_expr"
13055               | Tag_class_str_item -> "class_str_item"
13056               | Tag_match_case -> "match_case"
13057               | Tag_ident -> "ident"
13058               | Tag_binding -> "binding"
13059               | Tag_rec_binding -> "rec_binding"
13060               | Tag_module_binding -> "module_binding"
13061               
13062             let ctyp_tag = Tag_ctyp
13063               
13064             let patt_tag = Tag_patt
13065               
13066             let expr_tag = Tag_expr
13067               
13068             let module_type_tag = Tag_module_type
13069               
13070             let sig_item_tag = Tag_sig_item
13071               
13072             let with_constr_tag = Tag_with_constr
13073               
13074             let module_expr_tag = Tag_module_expr
13075               
13076             let str_item_tag = Tag_str_item
13077               
13078             let class_type_tag = Tag_class_type
13079               
13080             let class_sig_item_tag = Tag_class_sig_item
13081               
13082             let class_expr_tag = Tag_class_expr
13083               
13084             let class_str_item_tag = Tag_class_str_item
13085               
13086             let match_case_tag = Tag_match_case
13087               
13088             let ident_tag = Tag_ident
13089               
13090             let binding_tag = Tag_binding
13091               
13092             let rec_binding_tag = Tag_rec_binding
13093               
13094             let module_binding_tag = Tag_module_binding
13095               
13096             type dyn
13097             
13098             external dyn_tag : 'a tag -> dyn tag = "%identity"
13099               
13100             module Pack (X : sig type 'a t
13101                                   end) =
13102               struct
13103                 type pack = ((dyn tag) * Obj.t)
13104                 
13105                 exception Pack_error
13106                   
13107                 let pack tag v = ((dyn_tag tag), (Obj.repr v))
13108                   
13109                 let unpack (tag : 'a tag) (tag', obj) =
13110                   if (dyn_tag tag) = tag'
13111                   then (Obj.obj obj : 'a X.t)
13112                   else raise Pack_error
13113                   
13114                 let print_tag f (tag, _) =
13115                   Format.pp_print_string f (string_of_tag tag)
13116                   
13117               end
13118               
13119           end
13120           
13121       end
13122       
13123     module Quotation =
13124       struct
13125         module Make (Ast : Sig.Camlp4Ast) :
13126           Sig.Quotation with module Ast = Ast =
13127           struct
13128             module Ast = Ast
13129               
13130             module DynAst = DynAst.Make(Ast)
13131               
13132             module Loc = Ast.Loc
13133               
13134             open Format
13135               
13136             open Sig
13137               
13138             type 'a expand_fun = Loc.t -> string option -> string -> 'a
13139             
13140             module Exp_key = DynAst.Pack(struct type 'a t = unit
13141                                                  end)
13142               
13143             module Exp_fun =
13144               DynAst.Pack(struct type 'a t = 'a expand_fun
13145                                   end)
13146               
13147             let expanders_table :
13148               (((string * Exp_key.pack) * Exp_fun.pack) list) ref = ref []
13149               
13150             let default = ref ""
13151               
13152             let translate = ref (fun x -> x)
13153               
13154             let expander_name name =
13155               match !translate name with | "" -> !default | name -> name
13156               
13157             let find name tag =
13158               let key = ((expander_name name), (Exp_key.pack tag ()))
13159               in Exp_fun.unpack tag (List.assoc key !expanders_table)
13160               
13161             let add name tag f =
13162               let elt = ((name, (Exp_key.pack tag ())), (Exp_fun.pack tag f))
13163               in expanders_table := elt :: !expanders_table
13164               
13165             let dump_file = ref None
13166               
13167             module Error =
13168               struct
13169                 type error =
13170                   | Finding
13171                   | Expanding
13172                   | ParsingResult of Loc.t * string
13173                   | Locating
13174                 
13175                 type t = (string * string * error * exn)
13176                 
13177                 exception E of t
13178                   
13179                 let print ppf (name, position, ctx, exn) =
13180                   let name = if name = "" then !default else name in
13181                   let pp x =
13182                     fprintf ppf "@?@[<2>While %s %S in a position of %S:" x
13183                       name position in
13184                   let () =
13185                     match ctx with
13186                     | Finding ->
13187                         (pp "finding quotation";
13188                          if !expanders_table = []
13189                          then
13190                            fprintf ppf
13191                              "@ There is no quotation expander available."
13192                          else
13193                            (fprintf ppf
13194                               "@ @[<hv2>Available quotation expanders are:@\n";
13195                             List.iter
13196                               (fun ((s, t), _) ->
13197                                  fprintf ppf
13198                                    "@[<2>%s@ (in@ a@ position@ of %a)@]@ " s
13199                                    Exp_key.print_tag t)
13200                               !expanders_table;
13201                             fprintf ppf "@]"))
13202                     | Expanding -> pp "expanding quotation"
13203                     | Locating -> pp "parsing"
13204                     | ParsingResult (loc, str) ->
13205                         let () = pp "parsing result of quotation"
13206                         in
13207                           (match !dump_file with
13208                            | Some dump_file ->
13209                                let () = fprintf ppf " dumping result...\n"
13210                                in
13211                                  (try
13212                                     let oc = open_out_bin dump_file
13213                                     in
13214                                       (output_string oc str;
13215                                        output_string oc "\n";
13216                                        flush oc;
13217                                        close_out oc;
13218                                        fprintf ppf "%a:" Loc.print
13219                                          (Loc.set_file_name dump_file loc))
13220                                   with
13221                                   | _ ->
13222                                       fprintf ppf
13223                                         "Error while dumping result in file %S; dump aborted"
13224                                         dump_file)
13225                            | None ->
13226                                fprintf ppf
13227                                  "\n(consider setting variable Quotation.dump_file, or using the -QD option)")
13228                   in fprintf ppf "@\n%a@]@." ErrorHandler.print exn
13229                   
13230                 let to_string x =
13231                   let b = Buffer.create 50 in
13232                   let () = bprintf b "%a" print x in Buffer.contents b
13233                   
13234               end
13235               
13236             let _ = let module M = ErrorHandler.Register(Error) in ()
13237               
13238             open Error
13239               
13240             let expand_quotation loc expander pos_tag quot =
13241               let loc_name_opt =
13242                 if quot.q_loc = "" then None else Some quot.q_loc
13243               in
13244                 try expander loc loc_name_opt quot.q_contents
13245                 with | (Loc.Exc_located (_, (Error.E _)) as exc) -> raise exc
13246                 | Loc.Exc_located (iloc, exc) ->
13247                     let exc1 =
13248                       Error.E (((quot.q_name), pos_tag, Expanding, exc))
13249                     in raise (Loc.Exc_located (iloc, exc1))
13250                 | exc ->
13251                     let exc1 =
13252                       Error.E (((quot.q_name), pos_tag, Expanding, exc))
13253                     in raise (Loc.Exc_located (loc, exc1))
13254               
13255             let parse_quotation_result parse loc quot pos_tag str =
13256               try parse loc str
13257               with
13258               | Loc.Exc_located (iloc,
13259                   (Error.E ((n, pos_tag, Expanding, exc)))) ->
13260                   let ctx = ParsingResult (iloc, quot.q_contents) in
13261                   let exc1 = Error.E ((n, pos_tag, ctx, exc))
13262                   in raise (Loc.Exc_located (iloc, exc1))
13263               | Loc.Exc_located (iloc, ((Error.E _ as exc))) ->
13264                   raise (Loc.Exc_located (iloc, exc))
13265               | Loc.Exc_located (iloc, exc) ->
13266                   let ctx = ParsingResult (iloc, quot.q_contents) in
13267                   let exc1 = Error.E (((quot.q_name), pos_tag, ctx, exc))
13268                   in raise (Loc.Exc_located (iloc, exc1))
13269               
13270             let expand loc quotation tag =
13271               let pos_tag = DynAst.string_of_tag tag in
13272               let name = quotation.q_name in
13273               let expander =
13274                 try find name tag
13275                 with | (Loc.Exc_located (_, (Error.E _)) as exc) -> raise exc
13276                 | Loc.Exc_located (qloc, exc) ->
13277                     raise
13278                       (Loc.Exc_located (qloc,
13279                          Error.E ((name, pos_tag, Finding, exc))))
13280                 | exc ->
13281                     raise
13282                       (Loc.Exc_located (loc,
13283                          Error.E ((name, pos_tag, Finding, exc)))) in
13284               let loc = Loc.join (Loc.move `start quotation.q_shift loc)
13285               in expand_quotation loc expander pos_tag quotation
13286               
13287           end
13288           
13289       end
13290       
13291     module AstFilters =
13292       struct
13293         module Make (Ast : Sig.Camlp4Ast) :
13294           Sig.AstFilters with module Ast = Ast =
13295           struct
13296             module Ast = Ast
13297               
13298             type 'a filter = 'a -> 'a
13299             
13300             let interf_filters = Queue.create ()
13301               
13302             let fold_interf_filters f i = Queue.fold f i interf_filters
13303               
13304             let implem_filters = Queue.create ()
13305               
13306             let fold_implem_filters f i = Queue.fold f i implem_filters
13307               
13308             let topphrase_filters = Queue.create ()
13309               
13310             let fold_topphrase_filters f i = Queue.fold f i topphrase_filters
13311               
13312             let register_sig_item_filter f = Queue.add f interf_filters
13313               
13314             let register_str_item_filter f = Queue.add f implem_filters
13315               
13316             let register_topphrase_filter f = Queue.add f topphrase_filters
13317               
13318           end
13319           
13320       end
13321       
13322     module Camlp4Ast2OCamlAst :
13323       sig
13324         module Make (Camlp4Ast : Sig.Camlp4Ast) :
13325           sig
13326             open Camlp4Ast
13327               
13328             val sig_item : sig_item -> Camlp4_import.Parsetree.signature
13329               
13330             val str_item : str_item -> Camlp4_import.Parsetree.structure
13331               
13332             val phrase : str_item -> Camlp4_import.Parsetree.toplevel_phrase
13333               
13334           end
13335           
13336       end =
13337       struct
13338         module Make (Ast : Sig.Camlp4Ast) =
13339           struct
13340             open Format
13341               
13342             open Camlp4_import.Parsetree
13343               
13344             open Camlp4_import.Longident
13345               
13346             open Camlp4_import.Asttypes
13347               
13348             open Ast
13349               
13350             let constructors_arity () = !Camlp4_config.constructors_arity
13351               
13352             let error loc str = Loc.raise loc (Failure str)
13353               
13354             let char_of_char_token loc s =
13355               try Token.Eval.char s
13356               with | (Failure _ as exn) -> Loc.raise loc exn
13357               
13358             let string_of_string_token loc s =
13359               try Token.Eval.string s
13360               with | (Failure _ as exn) -> Loc.raise loc exn
13361               
13362             let remove_underscores s =
13363               let l = String.length s in
13364               let rec remove src dst =
13365                 if src >= l
13366                 then if dst >= l then s else String.sub s 0 dst
13367                 else
13368                   (match s.[src] with
13369                    | '_' -> remove (src + 1) dst
13370                    | c -> (s.[dst] <- c; remove (src + 1) (dst + 1)))
13371               in remove 0 0
13372               
13373             let mkloc = Loc.to_ocaml_location
13374               
13375             let mkghloc loc = Loc.to_ocaml_location (Loc.ghostify loc)
13376               
13377             let mktyp loc d = { ptyp_desc = d; ptyp_loc = mkloc loc; }
13378               
13379             let mkpat loc d = { ppat_desc = d; ppat_loc = mkloc loc; }
13380               
13381             let mkghpat loc d = { ppat_desc = d; ppat_loc = mkghloc loc; }
13382               
13383             let mkexp loc d = { pexp_desc = d; pexp_loc = mkloc loc; }
13384               
13385             let mkmty loc d = { pmty_desc = d; pmty_loc = mkloc loc; }
13386               
13387             let mksig loc d = { psig_desc = d; psig_loc = mkloc loc; }
13388               
13389             let mkmod loc d = { pmod_desc = d; pmod_loc = mkloc loc; }
13390               
13391             let mkstr loc d = { pstr_desc = d; pstr_loc = mkloc loc; }
13392               
13393             let mkfield loc d = { pfield_desc = d; pfield_loc = mkloc loc; }
13394               
13395             let mkcty loc d = { pcty_desc = d; pcty_loc = mkloc loc; }
13396               
13397             let mkpcl loc d = { pcl_desc = d; pcl_loc = mkloc loc; }
13398               
13399             let mkpolytype t =
13400               match t.ptyp_desc with
13401               | Ptyp_poly (_, _) -> t
13402               | _ -> { (t) with ptyp_desc = Ptyp_poly ([], t); }
13403               
13404             let mb2b =
13405               function
13406               | Ast.BTrue -> true
13407               | Ast.BFalse -> false
13408               | Ast.BAnt _ -> assert false
13409               
13410             let mkvirtual m = if mb2b m then Virtual else Concrete
13411               
13412             let lident s = Lident s
13413               
13414             let ldot l s = Ldot (l, s)
13415               
13416             let lapply l s = Lapply (l, s)
13417               
13418             let conv_con =
13419               let t = Hashtbl.create 73
13420               in
13421                 (List.iter (fun (s, s') -> Hashtbl.add t s s')
13422                    [ ("True", "true"); ("False", "false"); (" True", "True");
13423                      (" False", "False") ];
13424                  fun s -> try Hashtbl.find t s with | Not_found -> s)
13425               
13426             let conv_lab =
13427               let t = Hashtbl.create 73
13428               in
13429                 (List.iter (fun (s, s') -> Hashtbl.add t s s')
13430                    [ ("val", "contents") ];
13431                  fun s -> try Hashtbl.find t s with | Not_found -> s)
13432               
13433             let array_function str name =
13434               ldot (lident str)
13435                 (if !Camlp4_config.unsafe then "unsafe_" ^ name else name)
13436               
13437             let mkrf =
13438               function
13439               | Ast.BTrue -> Recursive
13440               | Ast.BFalse -> Nonrecursive
13441               | Ast.BAnt _ -> assert false
13442               
13443             let mkli s =
13444               let rec loop f =
13445                 function | i :: il -> loop (ldot (f i)) il | [] -> f s
13446               in loop lident
13447               
13448             let rec ctyp_fa al =
13449               function
13450               | TyApp (_, f, a) -> ctyp_fa (a :: al) f
13451               | f -> (f, al)
13452               
13453             let ident_tag ?(conv_lid = fun x -> x) i =
13454               let rec self i acc =
13455                 match i with
13456                 | Ast.IdAcc (_, i1, i2) -> self i2 (Some (self i1 acc))
13457                 | Ast.IdApp (_, i1, i2) ->
13458                     let i' =
13459                       Lapply (fst (self i1 None), fst (self i2 None)) in
13460                     let x =
13461                       (match acc with
13462                        | None -> i'
13463                        | _ ->
13464                            error (loc_of_ident i) "invalid long identifier")
13465                     in (x, `app)
13466                 | Ast.IdUid (_, s) ->
13467                     let x =
13468                       (match acc with
13469                        | None -> lident s
13470                        | Some ((acc, (`uident | `app))) -> ldot acc s
13471                        | _ ->
13472                            error (loc_of_ident i) "invalid long identifier")
13473                     in (x, `uident)
13474                 | Ast.IdLid (_, s) ->
13475                     let x =
13476                       (match acc with
13477                        | None -> lident (conv_lid s)
13478                        | Some ((acc, (`uident | `app))) ->
13479                            ldot acc (conv_lid s)
13480                        | _ ->
13481                            error (loc_of_ident i) "invalid long identifier")
13482                     in (x, `lident)
13483                 | _ -> error (loc_of_ident i) "invalid long identifier"
13484               in self i None
13485               
13486             let ident ?conv_lid i = fst (ident_tag ?conv_lid i)
13487               
13488             let long_lident msg i =
13489               match ident_tag i with
13490               | (i, `lident) -> i
13491               | _ -> error (loc_of_ident i) msg
13492               
13493             let long_type_ident = long_lident "invalid long identifier type"
13494               
13495             let long_class_ident = long_lident "invalid class name"
13496               
13497             let long_uident ?(conv_con = fun x -> x) i =
13498               match ident_tag i with
13499               | (Ldot (i, s), `uident) -> ldot i (conv_con s)
13500               | (Lident s, `uident) -> lident (conv_con s)
13501               | (i, `app) -> i
13502               | _ -> error (loc_of_ident i) "uppercase identifier expected"
13503               
13504             let rec ctyp_long_id_prefix t =
13505               match t with
13506               | Ast.TyId (_, i) -> ident i
13507               | Ast.TyApp (_, m1, m2) ->
13508                   let li1 = ctyp_long_id_prefix m1 in
13509                   let li2 = ctyp_long_id_prefix m2 in Lapply (li1, li2)
13510               | t -> error (loc_of_ctyp t) "invalid module expression"
13511               
13512             let ctyp_long_id t =
13513               match t with
13514               | Ast.TyId (_, i) -> (false, (long_type_ident i))
13515               | TyApp (loc, _, _) -> error loc "invalid type name"
13516               | TyCls (_, i) -> (true, (ident i))
13517               | t -> error (loc_of_ctyp t) "invalid type"
13518               
13519             let rec ty_var_list_of_ctyp =
13520               function
13521               | Ast.TyApp (_, t1, t2) ->
13522                   (ty_var_list_of_ctyp t1) @ (ty_var_list_of_ctyp t2)
13523               | Ast.TyQuo (_, s) -> [ s ]
13524               | _ -> assert false
13525               
13526             let rec ctyp =
13527               function
13528               | TyId (loc, i) ->
13529                   let li = long_type_ident i
13530                   in mktyp loc (Ptyp_constr (li, []))
13531               | TyAli (loc, t1, t2) ->
13532                   let (t, i) =
13533                     (match (t1, t2) with
13534                      | (t, TyQuo (_, s)) -> (t, s)
13535                      | (TyQuo (_, s), t) -> (t, s)
13536                      | _ -> error loc "invalid alias type")
13537                   in mktyp loc (Ptyp_alias (ctyp t, i))
13538               | TyAny loc -> mktyp loc Ptyp_any
13539               | (TyApp (loc, _, _) as f) ->
13540                   let (f, al) = ctyp_fa [] f in
13541                   let (is_cls, li) = ctyp_long_id f
13542                   in
13543                     if is_cls
13544                     then mktyp loc (Ptyp_class (li, List.map ctyp al, []))
13545                     else mktyp loc (Ptyp_constr (li, List.map ctyp al))
13546               | TyArr (loc, (TyLab (_, lab, t1)), t2) ->
13547                   mktyp loc (Ptyp_arrow (lab, ctyp t1, ctyp t2))
13548               | TyArr (loc, (TyOlb (loc1, lab, t1)), t2) ->
13549                   let t1 =
13550                     TyApp (loc1, Ast.TyId (loc1, Ast.IdLid (loc1, "option")),
13551                       t1)
13552                   in mktyp loc (Ptyp_arrow ("?" ^ lab, ctyp t1, ctyp t2))
13553               | TyArr (loc, t1, t2) ->
13554                   mktyp loc (Ptyp_arrow ("", ctyp t1, ctyp t2))
13555               | Ast.TyObj (loc, fl, Ast.BFalse) ->
13556                   mktyp loc (Ptyp_object (meth_list fl []))
13557               | Ast.TyObj (loc, fl, Ast.BTrue) ->
13558                   mktyp loc
13559                     (Ptyp_object (meth_list fl [ mkfield loc Pfield_var ]))
13560               | TyCls (loc, id) -> mktyp loc (Ptyp_class (ident id, [], []))
13561               | TyLab (loc, _, _) ->
13562                   error loc "labelled type not allowed here"
13563               | TyMan (loc, _, _) ->
13564                   error loc "manifest type not allowed here"
13565               | TyOlb (loc, _, _) ->
13566                   error loc "labelled type not allowed here"
13567               | TyPol (loc, t1, t2) ->
13568                   mktyp loc (Ptyp_poly (ty_var_list_of_ctyp t1, ctyp t2))
13569               | TyQuo (loc, s) -> mktyp loc (Ptyp_var s)
13570               | TyRec (loc, _) -> error loc "record type not allowed here"
13571               | TySum (loc, _) -> error loc "sum type not allowed here"
13572               | TyPrv (loc, _) -> error loc "private type not allowed here"
13573               | TyMut (loc, _) -> error loc "mutable type not allowed here"
13574               | TyOr (loc, _, _) ->
13575                   error loc "type1 | type2 not allowed here"
13576               | TyAnd (loc, _, _) ->
13577                   error loc "type1 and type2 not allowed here"
13578               | TyOf (loc, _, _) ->
13579                   error loc "type1 of type2 not allowed here"
13580               | TyCol (loc, _, _) ->
13581                   error loc "type1 : type2 not allowed here"
13582               | TySem (loc, _, _) ->
13583                   error loc "type1 ; type2 not allowed here"
13584               | Ast.TyTup (loc, (Ast.TySta (_, t1, t2))) ->
13585                   mktyp loc
13586                     (Ptyp_tuple
13587                        (List.map ctyp (list_of_ctyp t1 (list_of_ctyp t2 []))))
13588               | Ast.TyVrnEq (loc, t) ->
13589                   mktyp loc (Ptyp_variant (row_field t, true, None))
13590               | Ast.TyVrnSup (loc, t) ->
13591                   mktyp loc (Ptyp_variant (row_field t, false, None))
13592               | Ast.TyVrnInf (loc, t) ->
13593                   mktyp loc (Ptyp_variant (row_field t, true, Some []))
13594               | Ast.TyVrnInfSup (loc, t, t') ->
13595                   mktyp loc
13596                     (Ptyp_variant (row_field t, true, Some (name_tags t')))
13597               | TyAnt (loc, _) -> error loc "antiquotation not allowed here"
13598               | TyOfAmp (_, _, _) | TyAmp (_, _, _) | TySta (_, _, _) |
13599                   TyCom (_, _, _) | TyVrn (_, _) | TyQuM (_, _) |
13600                   TyQuP (_, _) | TyDcl (_, _, _, _, _) |
13601                   TyObj (_, _, (BAnt _)) | TyNil _ | TyTup (_, _) ->
13602                   assert false
13603             and row_field =
13604               function
13605               | Ast.TyNil _ -> []
13606               | Ast.TyVrn (_, i) -> [ Rtag (i, true, []) ]
13607               | Ast.TyOfAmp (_, (Ast.TyVrn (_, i)), t) ->
13608                   [ Rtag (i, true, List.map ctyp (list_of_ctyp t [])) ]
13609               | Ast.TyOf (_, (Ast.TyVrn (_, i)), t) ->
13610                   [ Rtag (i, false, List.map ctyp (list_of_ctyp t [])) ]
13611               | Ast.TyOr (_, t1, t2) -> (row_field t1) @ (row_field t2)
13612               | t -> [ Rinherit (ctyp t) ]
13613             and name_tags =
13614               function
13615               | Ast.TyApp (_, t1, t2) -> (name_tags t1) @ (name_tags t2)
13616               | Ast.TyVrn (_, s) -> [ s ]
13617               | _ -> assert false
13618             and meth_list fl acc =
13619               match fl with
13620               | Ast.TyNil _ -> acc
13621               | Ast.TySem (_, t1, t2) -> meth_list t1 (meth_list t2 acc)
13622               | Ast.TyCol (loc, (Ast.TyId (_, (Ast.IdLid (_, lab)))), t) ->
13623                   (mkfield loc (Pfield (lab, mkpolytype (ctyp t)))) :: acc
13624               | _ -> assert false
13625               
13626             let mktype loc tl cl tk tp tm =
13627               let (params, variance) = List.split tl
13628               in
13629                 {
13630                   ptype_params = params;
13631                   ptype_cstrs = cl;
13632                   ptype_kind = tk;
13633                   ptype_private = tp;
13634                   ptype_manifest = tm;
13635                   ptype_loc = mkloc loc;
13636                   ptype_variance = variance;
13637                 }
13638               
13639             let mkprivate' m = if m then Private else Public
13640               
13641             let mkprivate m = mkprivate' (mb2b m)
13642               
13643             let mktrecord =
13644               function
13645               | Ast.TyCol (loc, (Ast.TyId (_, (Ast.IdLid (_, s)))),
13646                   (Ast.TyMut (_, t))) ->
13647                   (s, Mutable, (mkpolytype (ctyp t)), (mkloc loc))
13648               | Ast.TyCol (loc, (Ast.TyId (_, (Ast.IdLid (_, s)))), t) ->
13649                   (s, Immutable, (mkpolytype (ctyp t)), (mkloc loc))
13650               | _ -> assert false
13651               
13652             let mkvariant =
13653               function
13654               | Ast.TyId (loc, (Ast.IdUid (_, s))) ->
13655                   ((conv_con s), [], (mkloc loc))
13656               | Ast.TyOf (loc, (Ast.TyId (_, (Ast.IdUid (_, s)))), t) ->
13657                   ((conv_con s), (List.map ctyp (list_of_ctyp t [])),
13658                    (mkloc loc))
13659               | _ -> assert false
13660               
13661             let rec type_decl tl cl loc m pflag =
13662               function
13663               | Ast.TyMan (_, t1, t2) ->
13664                   type_decl tl cl loc (Some (ctyp t1)) pflag t2
13665               | Ast.TyPrv (_, t) -> type_decl tl cl loc m true t
13666               | Ast.TyRec (_, t) ->
13667                   mktype loc tl cl
13668                     (Ptype_record (List.map mktrecord (list_of_ctyp t [])))
13669                     (mkprivate' pflag) m
13670               | Ast.TySum (_, t) ->
13671                   mktype loc tl cl
13672                     (Ptype_variant (List.map mkvariant (list_of_ctyp t [])))
13673                     (mkprivate' pflag) m
13674               | t ->
13675                   if m <> None
13676                   then
13677                     error loc "only one manifest type allowed by definition"
13678                   else
13679                     (let m =
13680                        match t with
13681                        | Ast.TyNil _ -> None
13682                        | _ -> Some (ctyp t)
13683                      in mktype loc tl cl Ptype_abstract (mkprivate' pflag) m)
13684               
13685             let type_decl tl cl t =
13686               type_decl tl cl (loc_of_ctyp t) None false t
13687               
13688             let mkvalue_desc t p = { pval_type = ctyp t; pval_prim = p; }
13689               
13690             let rec list_of_meta_list =
13691               function
13692               | Ast.LNil -> []
13693               | Ast.LCons (x, xs) -> x :: (list_of_meta_list xs)
13694               | Ast.LAnt _ -> assert false
13695               
13696             let mkmutable m = if mb2b m then Mutable else Immutable
13697               
13698             let paolab lab p =
13699               match (lab, p) with
13700               | ("",
13701                  (Ast.PaId (_, (Ast.IdLid (_, i))) |
13702                     Ast.PaTyc (_, (Ast.PaId (_, (Ast.IdLid (_, i)))), _)))
13703                   -> i
13704               | ("", p) -> error (loc_of_patt p) "bad ast in label"
13705               | _ -> lab
13706               
13707             let opt_private_ctyp =
13708               function
13709               | Ast.TyPrv (_, t) -> (Ptype_abstract, Private, (ctyp t))
13710               | t -> (Ptype_abstract, Public, (ctyp t))
13711               
13712             let rec type_parameters t acc =
13713               match t with
13714               | Ast.TyApp (_, t1, t2) ->
13715                   type_parameters t1 (type_parameters t2 acc)
13716               | Ast.TyQuP (_, s) -> (s, (true, false)) :: acc
13717               | Ast.TyQuM (_, s) -> (s, (false, true)) :: acc
13718               | Ast.TyQuo (_, s) -> (s, (false, false)) :: acc
13719               | _ -> assert false
13720               
13721             let rec class_parameters t acc =
13722               match t with
13723               | Ast.TyCom (_, t1, t2) ->
13724                   class_parameters t1 (class_parameters t2 acc)
13725               | Ast.TyQuP (_, s) -> (s, (true, false)) :: acc
13726               | Ast.TyQuM (_, s) -> (s, (false, true)) :: acc
13727               | Ast.TyQuo (_, s) -> (s, (false, false)) :: acc
13728               | _ -> assert false
13729               
13730             let rec type_parameters_and_type_name t acc =
13731               match t with
13732               | Ast.TyApp (_, t1, t2) ->
13733                   type_parameters_and_type_name t1 (type_parameters t2 acc)
13734               | Ast.TyId (_, i) -> ((ident i), acc)
13735               | _ -> assert false
13736               
13737             let rec mkwithc wc acc =
13738               match wc with
13739               | WcNil _ -> acc
13740               | WcTyp (loc, id_tpl, ct) ->
13741                   let (id, tpl) = type_parameters_and_type_name id_tpl [] in
13742                   let (params, variance) = List.split tpl in
13743                   let (kind, priv, ct) = opt_private_ctyp ct
13744                   in
13745                     (id,
13746                      (Pwith_type
13747                         {
13748                           ptype_params = params;
13749                           ptype_cstrs = [];
13750                           ptype_kind = kind;
13751                           ptype_private = priv;
13752                           ptype_manifest = Some ct;
13753                           ptype_loc = mkloc loc;
13754                           ptype_variance = variance;
13755                         })) ::
13756                       acc
13757               | WcMod (_, i1, i2) ->
13758                   ((long_uident i1), (Pwith_module (long_uident i2))) :: acc
13759               | Ast.WcAnd (_, wc1, wc2) -> mkwithc wc1 (mkwithc wc2 acc)
13760               | Ast.WcAnt (loc, _) ->
13761                   error loc "bad with constraint (antiquotation)"
13762               
13763             let rec patt_fa al =
13764               function
13765               | PaApp (_, f, a) -> patt_fa (a :: al) f
13766               | f -> (f, al)
13767               
13768             let rec deep_mkrangepat loc c1 c2 =
13769               if c1 = c2
13770               then mkghpat loc (Ppat_constant (Const_char c1))
13771               else
13772                 mkghpat loc
13773                   (Ppat_or (mkghpat loc (Ppat_constant (Const_char c1)),
13774                      deep_mkrangepat loc (Char.chr ((Char.code c1) + 1)) c2))
13775               
13776             let rec mkrangepat loc c1 c2 =
13777               if c1 > c2
13778               then mkrangepat loc c2 c1
13779               else
13780                 if c1 = c2
13781                 then mkpat loc (Ppat_constant (Const_char c1))
13782                 else
13783                   mkpat loc
13784                     (Ppat_or (mkghpat loc (Ppat_constant (Const_char c1)),
13785                        deep_mkrangepat loc (Char.chr ((Char.code c1) + 1)) c2))
13786               
13787             let rec patt =
13788               function
13789               | Ast.PaId (loc, (Ast.IdLid (_, s))) -> mkpat loc (Ppat_var s)
13790               | Ast.PaId (loc, i) ->
13791                   let p =
13792                     Ppat_construct (long_uident ~conv_con i, None,
13793                       constructors_arity ())
13794                   in mkpat loc p
13795               | PaAli (loc, p1, p2) ->
13796                   let (p, i) =
13797                     (match (p1, p2) with
13798                      | (p, Ast.PaId (_, (Ast.IdLid (_, s)))) -> (p, s)
13799                      | (Ast.PaId (_, (Ast.IdLid (_, s))), p) -> (p, s)
13800                      | _ -> error loc "invalid alias pattern")
13801                   in mkpat loc (Ppat_alias (patt p, i))
13802               | PaAnt (loc, _) -> error loc "antiquotation not allowed here"
13803               | PaAny loc -> mkpat loc Ppat_any
13804               | Ast.PaApp (loc, (Ast.PaId (_, (Ast.IdUid (_, s)))),
13805                   (Ast.PaTup (_, (Ast.PaAny loc_any)))) ->
13806                   mkpat loc
13807                     (Ppat_construct (lident (conv_con s),
13808                        Some (mkpat loc_any Ppat_any), false))
13809               | (PaApp (loc, _, _) as f) ->
13810                   let (f, al) = patt_fa [] f in
13811                   let al = List.map patt al
13812                   in
13813                     (match (patt f).ppat_desc with
13814                      | Ppat_construct (li, None, _) ->
13815                          if constructors_arity ()
13816                          then
13817                            mkpat loc
13818                              (Ppat_construct (li,
13819                                 Some (mkpat loc (Ppat_tuple al)), true))
13820                          else
13821                            (let a =
13822                               match al with
13823                               | [ a ] -> a
13824                               | _ -> mkpat loc (Ppat_tuple al)
13825                             in mkpat loc (Ppat_construct (li, Some a, false)))
13826                      | Ppat_variant (s, None) ->
13827                          let a =
13828                            if constructors_arity ()
13829                            then mkpat loc (Ppat_tuple al)
13830                            else
13831                              (match al with
13832                               | [ a ] -> a
13833                               | _ -> mkpat loc (Ppat_tuple al))
13834                          in mkpat loc (Ppat_variant (s, Some a))
13835                      | _ ->
13836                          error (loc_of_patt f)
13837                            "this is not a constructor, it cannot be applied in a pattern")
13838               | PaArr (loc, p) ->
13839                   mkpat loc (Ppat_array (List.map patt (list_of_patt p [])))
13840               | PaChr (loc, s) ->
13841                   mkpat loc
13842                     (Ppat_constant (Const_char (char_of_char_token loc s)))
13843               | PaInt (loc, s) ->
13844                   let i =
13845                     (try int_of_string s
13846                      with
13847                      | Failure _ ->
13848                          error loc
13849                            "Integer literal exceeds the range of representable integers of type int")
13850                   in mkpat loc (Ppat_constant (Const_int i))
13851               | PaInt32 (loc, s) ->
13852                   let i32 =
13853                     (try Int32.of_string s
13854                      with
13855                      | Failure _ ->
13856                          error loc
13857                            "Integer literal exceeds the range of representable integers of type int32")
13858                   in mkpat loc (Ppat_constant (Const_int32 i32))
13859               | PaInt64 (loc, s) ->
13860                   let i64 =
13861                     (try Int64.of_string s
13862                      with
13863                      | Failure _ ->
13864                          error loc
13865                            "Integer literal exceeds the range of representable integers of type int64")
13866                   in mkpat loc (Ppat_constant (Const_int64 i64))
13867               | PaNativeInt (loc, s) ->
13868                   let nati =
13869                     (try Nativeint.of_string s
13870                      with
13871                      | Failure _ ->
13872                          error loc
13873                            "Integer literal exceeds the range of representable integers of type nativeint")
13874                   in mkpat loc (Ppat_constant (Const_nativeint nati))
13875               | PaFlo (loc, s) ->
13876                   mkpat loc
13877                     (Ppat_constant (Const_float (remove_underscores s)))
13878               | PaLab (loc, _, _) ->
13879                   error loc "labeled pattern not allowed here"
13880               | PaOlb (loc, _, _) | PaOlbi (loc, _, _, _) ->
13881                   error loc "labeled pattern not allowed here"
13882               | PaOrp (loc, p1, p2) -> mkpat loc (Ppat_or (patt p1, patt p2))
13883               | PaRng (loc, p1, p2) ->
13884                   (match (p1, p2) with
13885                    | (PaChr (loc1, c1), PaChr (loc2, c2)) ->
13886                        let c1 = char_of_char_token loc1 c1 in
13887                        let c2 = char_of_char_token loc2 c2
13888                        in mkrangepat loc c1 c2
13889                    | _ ->
13890                        error loc "range pattern allowed only for characters")
13891               | PaRec (loc, p) ->
13892                   mkpat loc
13893                     (Ppat_record (List.map mklabpat (list_of_patt p [])))
13894               | PaStr (loc, s) ->
13895                   mkpat loc
13896                     (Ppat_constant
13897                        (Const_string (string_of_string_token loc s)))
13898               | Ast.PaTup (loc, (Ast.PaCom (_, p1, p2))) ->
13899                   mkpat loc
13900                     (Ppat_tuple
13901                        (List.map patt (list_of_patt p1 (list_of_patt p2 []))))
13902               | Ast.PaTup (loc, _) -> error loc "singleton tuple pattern"
13903               | PaTyc (loc, p, t) ->
13904                   mkpat loc (Ppat_constraint (patt p, ctyp t))
13905               | PaTyp (loc, i) -> mkpat loc (Ppat_type (long_type_ident i))
13906               | PaVrn (loc, s) -> mkpat loc (Ppat_variant (s, None))
13907               | PaLaz (loc, p) -> mkpat loc (Ppat_lazy (patt p))
13908               | (PaEq (_, _, _) | PaSem (_, _, _) | PaCom (_, _, _) | PaNil _
13909                  as p) -> error (loc_of_patt p) "invalid pattern"
13910             and mklabpat =
13911               function
13912               | Ast.PaEq (_, i, p) ->
13913                   ((ident ~conv_lid: conv_lab i), (patt p))
13914               | p -> error (loc_of_patt p) "invalid pattern"
13915               
13916             let rec expr_fa al =
13917               function
13918               | ExApp (_, f, a) -> expr_fa (a :: al) f
13919               | f -> (f, al)
13920               
13921             let rec class_expr_fa al =
13922               function
13923               | CeApp (_, ce, a) -> class_expr_fa (a :: al) ce
13924               | ce -> (ce, al)
13925               
13926             let rec sep_expr_acc l =
13927               function
13928               | ExAcc (_, e1, e2) -> sep_expr_acc (sep_expr_acc l e2) e1
13929               | (Ast.ExId (loc, (Ast.IdUid (_, s))) as e) ->
13930                   (match l with
13931                    | [] -> [ (loc, [], e) ]
13932                    | (loc', sl, e) :: l ->
13933                        ((Loc.merge loc loc'), (s :: sl), e) :: l)
13934               | Ast.ExId (_, ((Ast.IdAcc (_, _, _) as i))) ->
13935                   let rec normalize_acc =
13936                     (function
13937                      | Ast.IdAcc (_loc, i1, i2) ->
13938                          Ast.ExAcc (_loc, normalize_acc i1, normalize_acc i2)
13939                      | Ast.IdApp (_loc, i1, i2) ->
13940                          Ast.ExApp (_loc, normalize_acc i1, normalize_acc i2)
13941                      | (Ast.IdAnt (_loc, _) | Ast.IdUid (_loc, _) |
13942                           Ast.IdLid (_loc, _)
13943                         as i) -> Ast.ExId (_loc, i))
13944                   in sep_expr_acc l (normalize_acc i)
13945               | e -> ((loc_of_expr e), [], e) :: l
13946               
13947             let list_of_opt_ctyp ot acc =
13948               match ot with | Ast.TyNil _ -> acc | t -> list_of_ctyp t acc
13949               
13950             let rec expr =
13951               function
13952               | Ast.ExAcc (loc, x, (Ast.ExId (_, (Ast.IdLid (_, "val"))))) ->
13953                   mkexp loc
13954                     (Pexp_apply (mkexp loc (Pexp_ident (Lident "!")),
13955                        [ ("", (expr x)) ]))
13956               | (ExAcc (loc, _, _) | Ast.ExId (loc, (Ast.IdAcc (_, _, _))) as
13957                  e) ->
13958                   let (e, l) =
13959                     (match sep_expr_acc [] e with
13960                      | (loc, ml, Ast.ExId (_, (Ast.IdUid (_, s)))) :: l ->
13961                          let ca = constructors_arity ()
13962                          in
13963                            ((mkexp loc
13964                                (Pexp_construct (mkli (conv_con s) ml, None,
13965                                   ca))),
13966                             l)
13967                      | (loc, ml, Ast.ExId (_, (Ast.IdLid (_, s)))) :: l ->
13968                          ((mkexp loc (Pexp_ident (mkli s ml))), l)
13969                      | (_, [], e) :: l -> ((expr e), l)
13970                      | _ -> error loc "bad ast in expression") in
13971                   let (_, e) =
13972                     List.fold_left
13973                       (fun (loc_bp, e1) (loc_ep, ml, e2) ->
13974                          match e2 with
13975                          | Ast.ExId (_, (Ast.IdLid (_, s))) ->
13976                              let loc = Loc.merge loc_bp loc_ep
13977                              in
13978                                (loc,
13979                                 (mkexp loc
13980                                    (Pexp_field (e1, mkli (conv_lab s) ml))))
13981                          | _ ->
13982                              error (loc_of_expr e2)
13983                                "lowercase identifier expected")
13984                       (loc, e) l
13985                   in e
13986               | ExAnt (loc, _) -> error loc "antiquotation not allowed here"
13987               | (ExApp (loc, _, _) as f) ->
13988                   let (f, al) = expr_fa [] f in
13989                   let al = List.map label_expr al
13990                   in
13991                     (match (expr f).pexp_desc with
13992                      | Pexp_construct (li, None, _) ->
13993                          let al = List.map snd al
13994                          in
13995                            if constructors_arity ()
13996                            then
13997                              mkexp loc
13998                                (Pexp_construct (li,
13999                                   Some (mkexp loc (Pexp_tuple al)), true))
14000                            else
14001                              (let a =
14002                                 match al with
14003                                 | [ a ] -> a
14004                                 | _ -> mkexp loc (Pexp_tuple al)
14005                               in
14006                                 mkexp loc
14007                                   (Pexp_construct (li, Some a, false)))
14008                      | Pexp_variant (s, None) ->
14009                          let al = List.map snd al in
14010                          let a =
14011                            if constructors_arity ()
14012                            then mkexp loc (Pexp_tuple al)
14013                            else
14014                              (match al with
14015                               | [ a ] -> a
14016                               | _ -> mkexp loc (Pexp_tuple al))
14017                          in mkexp loc (Pexp_variant (s, Some a))
14018                      | _ -> mkexp loc (Pexp_apply (expr f, al)))
14019               | ExAre (loc, e1, e2) ->
14020                   mkexp loc
14021                     (Pexp_apply
14022                        (mkexp loc (Pexp_ident (array_function "Array" "get")),
14023                        [ ("", (expr e1)); ("", (expr e2)) ]))
14024               | ExArr (loc, e) ->
14025                   mkexp loc (Pexp_array (List.map expr (list_of_expr e [])))
14026               | ExAsf loc -> mkexp loc Pexp_assertfalse
14027               | ExAss (loc, e, v) ->
14028                   let e =
14029                     (match e with
14030                      | Ast.ExAcc (loc, x,
14031                          (Ast.ExId (_, (Ast.IdLid (_, "val"))))) ->
14032                          Pexp_apply (mkexp loc (Pexp_ident (Lident ":=")),
14033                            [ ("", (expr x)); ("", (expr v)) ])
14034                      | ExAcc (loc, _, _) ->
14035                          (match (expr e).pexp_desc with
14036                           | Pexp_field (e, lab) ->
14037                               Pexp_setfield (e, lab, expr v)
14038                           | _ -> error loc "bad record access")
14039                      | ExAre (_, e1, e2) ->
14040                          Pexp_apply
14041                            (mkexp loc
14042                               (Pexp_ident (array_function "Array" "set")),
14043                            [ ("", (expr e1)); ("", (expr e2)); ("", (expr v)) ])
14044                      | Ast.ExId (_, (Ast.IdLid (_, lab))) ->
14045                          Pexp_setinstvar (lab, expr v)
14046                      | ExSte (_, e1, e2) ->
14047                          Pexp_apply
14048                            (mkexp loc
14049                               (Pexp_ident (array_function "String" "set")),
14050                            [ ("", (expr e1)); ("", (expr e2)); ("", (expr v)) ])
14051                      | _ -> error loc "bad left part of assignment")
14052                   in mkexp loc e
14053               | ExAsr (loc, e) -> mkexp loc (Pexp_assert (expr e))
14054               | ExChr (loc, s) ->
14055                   mkexp loc
14056                     (Pexp_constant (Const_char (char_of_char_token loc s)))
14057               | ExCoe (loc, e, t1, t2) ->
14058                   let t1 =
14059                     (match t1 with | Ast.TyNil _ -> None | t -> Some (ctyp t))
14060                   in mkexp loc (Pexp_constraint (expr e, t1, Some (ctyp t2)))
14061               | ExFlo (loc, s) ->
14062                   mkexp loc
14063                     (Pexp_constant (Const_float (remove_underscores s)))
14064               | ExFor (loc, i, e1, e2, df, el) ->
14065                   let e3 = ExSeq (loc, el) in
14066                   let df = if mb2b df then Upto else Downto
14067                   in mkexp loc (Pexp_for (i, expr e1, expr e2, df, expr e3))
14068               | Ast.ExFun (loc, (Ast.McArr (_, (PaLab (_, lab, po)), w, e)))
14069                   ->
14070                   mkexp loc
14071                     (Pexp_function (lab, None,
14072                        [ ((patt_of_lab loc lab po), (when_expr e w)) ]))
14073               | Ast.ExFun (loc,
14074                   (Ast.McArr (_, (PaOlbi (_, lab, p, e1)), w, e2))) ->
14075                   let lab = paolab lab p
14076                   in
14077                     mkexp loc
14078                       (Pexp_function ("?" ^ lab, Some (expr e1),
14079                          [ ((patt p), (when_expr e2 w)) ]))
14080               | Ast.ExFun (loc, (Ast.McArr (_, (PaOlb (_, lab, p)), w, e)))
14081                   ->
14082                   let lab = paolab lab p
14083                   in
14084                     mkexp loc
14085                       (Pexp_function ("?" ^ lab, None,
14086                          [ ((patt_of_lab loc lab p), (when_expr e w)) ]))
14087               | ExFun (loc, a) ->
14088                   mkexp loc (Pexp_function ("", None, match_case a []))
14089               | ExIfe (loc, e1, e2, e3) ->
14090                   mkexp loc
14091                     (Pexp_ifthenelse (expr e1, expr e2, Some (expr e3)))
14092               | ExInt (loc, s) ->
14093                   let i =
14094                     (try int_of_string s
14095                      with
14096                      | Failure _ ->
14097                          error loc
14098                            "Integer literal exceeds the range of representable integers of type int")
14099                   in mkexp loc (Pexp_constant (Const_int i))
14100               | ExInt32 (loc, s) ->
14101                   let i32 =
14102                     (try Int32.of_string s
14103                      with
14104                      | Failure _ ->
14105                          error loc
14106                            "Integer literal exceeds the range of representable integers of type int32")
14107                   in mkexp loc (Pexp_constant (Const_int32 i32))
14108               | ExInt64 (loc, s) ->
14109                   let i64 =
14110                     (try Int64.of_string s
14111                      with
14112                      | Failure _ ->
14113                          error loc
14114                            "Integer literal exceeds the range of representable integers of type int64")
14115                   in mkexp loc (Pexp_constant (Const_int64 i64))
14116               | ExNativeInt (loc, s) ->
14117                   let nati =
14118                     (try Nativeint.of_string s
14119                      with
14120                      | Failure _ ->
14121                          error loc
14122                            "Integer literal exceeds the range of representable integers of type nativeint")
14123                   in mkexp loc (Pexp_constant (Const_nativeint nati))
14124               | ExLab (loc, _, _) ->
14125                   error loc "labeled expression not allowed here"
14126               | ExLaz (loc, e) -> mkexp loc (Pexp_lazy (expr e))
14127               | ExLet (loc, rf, bi, e) ->
14128                   mkexp loc (Pexp_let (mkrf rf, binding bi [], expr e))
14129               | ExLmd (loc, i, me, e) ->
14130                   mkexp loc (Pexp_letmodule (i, module_expr me, expr e))
14131               | ExMat (loc, e, a) ->
14132                   mkexp loc (Pexp_match (expr e, match_case a []))
14133               | ExNew (loc, id) -> mkexp loc (Pexp_new (long_type_ident id))
14134               | ExObj (loc, po, cfl) ->
14135                   let p =
14136                     (match po with | Ast.PaNil _ -> Ast.PaAny loc | p -> p) in
14137                   let cil = class_str_item cfl []
14138                   in mkexp loc (Pexp_object (((patt p), cil)))
14139               | ExOlb (loc, _, _) ->
14140                   error loc "labeled expression not allowed here"
14141               | ExOvr (loc, iel) ->
14142                   mkexp loc (Pexp_override (mkideexp iel []))
14143               | ExRec (loc, lel, eo) ->
14144                   (match lel with
14145                    | Ast.RbNil _ -> error loc "empty record"
14146                    | _ ->
14147                        let eo =
14148                          (match eo with
14149                           | Ast.ExNil _ -> None
14150                           | e -> Some (expr e))
14151                        in mkexp loc (Pexp_record (mklabexp lel [], eo)))
14152               | ExSeq (_loc, e) ->
14153                   let rec loop =
14154                     (function
14155                      | [] -> expr (Ast.ExId (_loc, Ast.IdUid (_loc, "()")))
14156                      | [ e ] -> expr e
14157                      | e :: el ->
14158                          let _loc = Loc.merge (loc_of_expr e) _loc
14159                          in mkexp _loc (Pexp_sequence (expr e, loop el)))
14160                   in loop (list_of_expr e [])
14161               | ExSnd (loc, e, s) -> mkexp loc (Pexp_send (expr e, s))
14162               | ExSte (loc, e1, e2) ->
14163                   mkexp loc
14164                     (Pexp_apply
14165                        (mkexp loc
14166                           (Pexp_ident (array_function "String" "get")),
14167                        [ ("", (expr e1)); ("", (expr e2)) ]))
14168               | ExStr (loc, s) ->
14169                   mkexp loc
14170                     (Pexp_constant
14171                        (Const_string (string_of_string_token loc s)))
14172               | ExTry (loc, e, a) ->
14173                   mkexp loc (Pexp_try (expr e, match_case a []))
14174               | Ast.ExTup (loc, (Ast.ExCom (_, e1, e2))) ->
14175                   mkexp loc
14176                     (Pexp_tuple
14177                        (List.map expr (list_of_expr e1 (list_of_expr e2 []))))
14178               | Ast.ExTup (loc, _) -> error loc "singleton tuple"
14179               | ExTyc (loc, e, t) ->
14180                   mkexp loc (Pexp_constraint (expr e, Some (ctyp t), None))
14181               | Ast.ExId (loc, (Ast.IdUid (_, "()"))) ->
14182                   mkexp loc (Pexp_construct (lident "()", None, true))
14183               | Ast.ExId (loc, (Ast.IdLid (_, s))) ->
14184                   mkexp loc (Pexp_ident (lident s))
14185               | Ast.ExId (loc, (Ast.IdUid (_, s))) ->
14186                   mkexp loc
14187                     (Pexp_construct (lident (conv_con s), None, true))
14188               | ExVrn (loc, s) -> mkexp loc (Pexp_variant (s, None))
14189               | ExWhi (loc, e1, el) ->
14190                   let e2 = ExSeq (loc, el)
14191                   in mkexp loc (Pexp_while (expr e1, expr e2))
14192               | Ast.ExCom (loc, _, _) ->
14193                   error loc "expr, expr: not allowed here"
14194               | Ast.ExSem (loc, _, _) ->
14195                   error loc
14196                     "expr; expr: not allowed here, use do {...} or [|...|] to surround them"
14197               | (ExId (_, _) | ExNil _ as e) ->
14198                   error (loc_of_expr e) "invalid expr"
14199             and patt_of_lab _loc lab =
14200               function
14201               | Ast.PaNil _ -> patt (Ast.PaId (_loc, Ast.IdLid (_loc, lab)))
14202               | p -> patt p
14203             and expr_of_lab _loc lab =
14204               function
14205               | Ast.ExNil _ -> expr (Ast.ExId (_loc, Ast.IdLid (_loc, lab)))
14206               | e -> expr e
14207             and label_expr =
14208               function
14209               | ExLab (loc, lab, eo) -> (lab, (expr_of_lab loc lab eo))
14210               | ExOlb (loc, lab, eo) ->
14211                   (("?" ^ lab), (expr_of_lab loc lab eo))
14212               | e -> ("", (expr e))
14213             and binding x acc =
14214               match x with
14215               | Ast.BiAnd (_, x, y) -> binding x (binding y acc)
14216               | Ast.BiEq (_, p, e) -> ((patt p), (expr e)) :: acc
14217               | Ast.BiNil _ -> acc
14218               | _ -> assert false
14219             and match_case x acc =
14220               match x with
14221               | Ast.McOr (_, x, y) -> match_case x (match_case y acc)
14222               | Ast.McArr (_, p, w, e) -> ((patt p), (when_expr e w)) :: acc
14223               | Ast.McNil _ -> acc
14224               | _ -> assert false
14225             and when_expr e w =
14226               match w with
14227               | Ast.ExNil _ -> expr e
14228               | w -> mkexp (loc_of_expr w) (Pexp_when (expr w, expr e))
14229             and mklabexp x acc =
14230               match x with
14231               | Ast.RbSem (_, x, y) -> mklabexp x (mklabexp y acc)
14232               | Ast.RbEq (_, i, e) ->
14233                   ((ident ~conv_lid: conv_lab i), (expr e)) :: acc
14234               | _ -> assert false
14235             and mkideexp x acc =
14236               match x with
14237               | Ast.RbNil _ -> acc
14238               | Ast.RbSem (_, x, y) -> mkideexp x (mkideexp y acc)
14239               | Ast.RbEq (_, (Ast.IdLid (_, s)), e) -> (s, (expr e)) :: acc
14240               | _ -> assert false
14241             and mktype_decl x acc =
14242               match x with
14243               | Ast.TyAnd (_, x, y) -> mktype_decl x (mktype_decl y acc)
14244               | Ast.TyDcl (_, c, tl, td, cl) ->
14245                   let cl =
14246                     List.map
14247                       (fun (t1, t2) ->
14248                          let loc =
14249                            Loc.merge (loc_of_ctyp t1) (loc_of_ctyp t2)
14250                          in ((ctyp t1), (ctyp t2), (mkloc loc)))
14251                       cl
14252                   in
14253                     (c,
14254                      (type_decl (List.fold_right type_parameters tl []) cl td)) ::
14255                       acc
14256               | _ -> assert false
14257             and module_type =
14258               function
14259               | Ast.MtNil loc ->
14260                   error loc "abstract/nil module type not allowed here"
14261               | Ast.MtId (loc, i) -> mkmty loc (Pmty_ident (long_uident i))
14262               | Ast.MtFun (loc, n, nt, mt) ->
14263                   mkmty loc
14264                     (Pmty_functor (n, module_type nt, module_type mt))
14265               | Ast.MtQuo (loc, _) ->
14266                   error loc "module type variable not allowed here"
14267               | Ast.MtSig (loc, sl) ->
14268                   mkmty loc (Pmty_signature (sig_item sl []))
14269               | Ast.MtWit (loc, mt, wc) ->
14270                   mkmty loc (Pmty_with (module_type mt, mkwithc wc []))
14271               | Ast.MtAnt (_, _) -> assert false
14272             and sig_item s l =
14273               match s with
14274               | Ast.SgNil _ -> l
14275               | SgCls (loc, cd) ->
14276                   (mksig loc
14277                      (Psig_class
14278                         (List.map class_info_class_type
14279                            (list_of_class_type cd [])))) ::
14280                     l
14281               | SgClt (loc, ctd) ->
14282                   (mksig loc
14283                      (Psig_class_type
14284                         (List.map class_info_class_type
14285                            (list_of_class_type ctd [])))) ::
14286                     l
14287               | Ast.SgSem (_, sg1, sg2) -> sig_item sg1 (sig_item sg2 l)
14288               | SgDir (_, _, _) -> l
14289               | Ast.SgExc (loc, (Ast.TyId (_, (Ast.IdUid (_, s))))) ->
14290                   (mksig loc (Psig_exception (conv_con s, []))) :: l
14291               | Ast.SgExc (loc,
14292                   (Ast.TyOf (_, (Ast.TyId (_, (Ast.IdUid (_, s)))), t))) ->
14293                   (mksig loc
14294                      (Psig_exception (conv_con s,
14295                         List.map ctyp (list_of_ctyp t [])))) ::
14296                     l
14297               | SgExc (_, _) -> assert false
14298               | SgExt (loc, n, t, sl) ->
14299                   (mksig loc
14300                      (Psig_value (n, mkvalue_desc t (list_of_meta_list sl)))) ::
14301                     l
14302               | SgInc (loc, mt) ->
14303                   (mksig loc (Psig_include (module_type mt))) :: l
14304               | SgMod (loc, n, mt) ->
14305                   (mksig loc (Psig_module (n, module_type mt))) :: l
14306               | SgRecMod (loc, mb) ->
14307                   (mksig loc (Psig_recmodule (module_sig_binding mb []))) ::
14308                     l
14309               | SgMty (loc, n, mt) ->
14310                   let si =
14311                     (match mt with
14312                      | MtQuo (_, _) -> Pmodtype_abstract
14313                      | _ -> Pmodtype_manifest (module_type mt))
14314                   in (mksig loc (Psig_modtype (n, si))) :: l
14315               | SgOpn (loc, id) ->
14316                   (mksig loc (Psig_open (long_uident id))) :: l
14317               | SgTyp (loc, tdl) ->
14318                   (mksig loc (Psig_type (mktype_decl tdl []))) :: l
14319               | SgVal (loc, n, t) ->
14320                   (mksig loc (Psig_value (n, mkvalue_desc t []))) :: l
14321               | Ast.SgAnt (loc, _) -> error loc "antiquotation in sig_item"
14322             and module_sig_binding x acc =
14323               match x with
14324               | Ast.MbAnd (_, x, y) ->
14325                   module_sig_binding x (module_sig_binding y acc)
14326               | Ast.MbCol (_, s, mt) -> (s, (module_type mt)) :: acc
14327               | _ -> assert false
14328             and module_str_binding x acc =
14329               match x with
14330               | Ast.MbAnd (_, x, y) ->
14331                   module_str_binding x (module_str_binding y acc)
14332               | Ast.MbColEq (_, s, mt, me) ->
14333                   (s, (module_type mt), (module_expr me)) :: acc
14334               | _ -> assert false
14335             and module_expr =
14336               function
14337               | Ast.MeNil loc -> error loc "nil module expression"
14338               | Ast.MeId (loc, i) -> mkmod loc (Pmod_ident (long_uident i))
14339               | Ast.MeApp (loc, me1, me2) ->
14340                   mkmod loc (Pmod_apply (module_expr me1, module_expr me2))
14341               | Ast.MeFun (loc, n, mt, me) ->
14342                   mkmod loc
14343                     (Pmod_functor (n, module_type mt, module_expr me))
14344               | Ast.MeStr (loc, sl) ->
14345                   mkmod loc (Pmod_structure (str_item sl []))
14346               | Ast.MeTyc (loc, me, mt) ->
14347                   mkmod loc
14348                     (Pmod_constraint (module_expr me, module_type mt))
14349               | Ast.MeAnt (loc, _) ->
14350                   error loc "antiquotation in module_expr"
14351             and str_item s l =
14352               match s with
14353               | Ast.StNil _ -> l
14354               | StCls (loc, cd) ->
14355                   (mkstr loc
14356                      (Pstr_class
14357                         (List.map class_info_class_expr
14358                            (list_of_class_expr cd [])))) ::
14359                     l
14360               | StClt (loc, ctd) ->
14361                   (mkstr loc
14362                      (Pstr_class_type
14363                         (List.map class_info_class_type
14364                            (list_of_class_type ctd [])))) ::
14365                     l
14366               | Ast.StSem (_, st1, st2) -> str_item st1 (str_item st2 l)
14367               | StDir (_, _, _) -> l
14368               | Ast.StExc (loc, (Ast.TyId (_, (Ast.IdUid (_, s)))), Ast.
14369                   ONone) ->
14370                   (mkstr loc (Pstr_exception (conv_con s, []))) :: l
14371               | Ast.StExc (loc,
14372                   (Ast.TyOf (_, (Ast.TyId (_, (Ast.IdUid (_, s)))), t)), Ast.
14373                   ONone) ->
14374                   (mkstr loc
14375                      (Pstr_exception (conv_con s,
14376                         List.map ctyp (list_of_ctyp t [])))) ::
14377                     l
14378               | Ast.StExc (loc, (Ast.TyId (_, (Ast.IdUid (_, s)))),
14379                   (Ast.OSome i)) ->
14380                   (mkstr loc (Pstr_exn_rebind (conv_con s, ident i))) :: l
14381               | StExc (_, _, _) -> assert false
14382               | StExp (loc, e) -> (mkstr loc (Pstr_eval (expr e))) :: l
14383               | StExt (loc, n, t, sl) ->
14384                   (mkstr loc
14385                      (Pstr_primitive (n,
14386                         mkvalue_desc t (list_of_meta_list sl)))) ::
14387                     l
14388               | StInc (loc, me) ->
14389                   (mkstr loc (Pstr_include (module_expr me))) :: l
14390               | StMod (loc, n, me) ->
14391                   (mkstr loc (Pstr_module (n, module_expr me))) :: l
14392               | StRecMod (loc, mb) ->
14393                   (mkstr loc (Pstr_recmodule (module_str_binding mb []))) ::
14394                     l
14395               | StMty (loc, n, mt) ->
14396                   (mkstr loc (Pstr_modtype (n, module_type mt))) :: l
14397               | StOpn (loc, id) ->
14398                   (mkstr loc (Pstr_open (long_uident id))) :: l
14399               | StTyp (loc, tdl) ->
14400                   (mkstr loc (Pstr_type (mktype_decl tdl []))) :: l
14401               | StVal (loc, rf, bi) ->
14402                   (mkstr loc (Pstr_value (mkrf rf, binding bi []))) :: l
14403               | Ast.StAnt (loc, _) -> error loc "antiquotation in str_item"
14404             and class_type =
14405               function
14406               | CtCon (loc, Ast.BFalse, id, tl) ->
14407                   mkcty loc
14408                     (Pcty_constr (long_class_ident id,
14409                        List.map ctyp (list_of_opt_ctyp tl [])))
14410               | CtFun (loc, (TyLab (_, lab, t)), ct) ->
14411                   mkcty loc (Pcty_fun (lab, ctyp t, class_type ct))
14412               | CtFun (loc, (TyOlb (loc1, lab, t)), ct) ->
14413                   let t =
14414                     TyApp (loc1, Ast.TyId (loc1, Ast.IdLid (loc1, "option")),
14415                       t)
14416                   in mkcty loc (Pcty_fun ("?" ^ lab, ctyp t, class_type ct))
14417               | CtFun (loc, t, ct) ->
14418                   mkcty loc (Pcty_fun ("", ctyp t, class_type ct))
14419               | CtSig (loc, t_o, ctfl) ->
14420                   let t =
14421                     (match t_o with | Ast.TyNil _ -> Ast.TyAny loc | t -> t) in
14422                   let cil = class_sig_item ctfl []
14423                   in mkcty loc (Pcty_signature (((ctyp t), cil)))
14424               | CtCon (loc, _, _, _) ->
14425                   error loc "invalid virtual class inside a class type"
14426               | CtAnt (_, _) | CtEq (_, _, _) | CtCol (_, _, _) |
14427                   CtAnd (_, _, _) | CtNil _ -> assert false
14428             and class_info_class_expr ci =
14429               match ci with
14430               | CeEq (_, (CeCon (loc, vir, (IdLid (_, name)), params)), ce)
14431                   ->
14432                   let (loc_params, (params, variance)) =
14433                     (match params with
14434                      | Ast.TyNil _ -> (loc, ([], []))
14435                      | t ->
14436                          ((loc_of_ctyp t),
14437                           (List.split (class_parameters t []))))
14438                   in
14439                     {
14440                       pci_virt = if mb2b vir then Virtual else Concrete;
14441                       pci_params = (params, (mkloc loc_params));
14442                       pci_name = name;
14443                       pci_expr = class_expr ce;
14444                       pci_loc = mkloc loc;
14445                       pci_variance = variance;
14446                     }
14447               | ce -> error (loc_of_class_expr ce) "bad class definition"
14448             and class_info_class_type ci =
14449               match ci with
14450               | CtEq (_, (CtCon (loc, vir, (IdLid (_, name)), params)), ct) |
14451                   CtCol (_, (CtCon (loc, vir, (IdLid (_, name)), params)),
14452                     ct)
14453                   ->
14454                   let (loc_params, (params, variance)) =
14455                     (match params with
14456                      | Ast.TyNil _ -> (loc, ([], []))
14457                      | t ->
14458                          ((loc_of_ctyp t),
14459                           (List.split (class_parameters t []))))
14460                   in
14461                     {
14462                       pci_virt = if mb2b vir then Virtual else Concrete;
14463                       pci_params = (params, (mkloc loc_params));
14464                       pci_name = name;
14465                       pci_expr = class_type ct;
14466                       pci_loc = mkloc loc;
14467                       pci_variance = variance;
14468                     }
14469               | ct ->
14470                   error (loc_of_class_type ct)
14471                     "bad class/class type declaration/definition"
14472             and class_sig_item c l =
14473               match c with
14474               | Ast.CgNil _ -> l
14475               | CgCtr (loc, t1, t2) ->
14476                   (Pctf_cstr (((ctyp t1), (ctyp t2), (mkloc loc)))) :: l
14477               | Ast.CgSem (_, csg1, csg2) ->
14478                   class_sig_item csg1 (class_sig_item csg2 l)
14479               | CgInh (_, ct) -> (Pctf_inher (class_type ct)) :: l
14480               | CgMth (loc, s, pf, t) ->
14481                   (Pctf_meth
14482                      ((s, (mkprivate pf), (mkpolytype (ctyp t)), (mkloc loc)))) ::
14483                     l
14484               | CgVal (loc, s, b, v, t) ->
14485                   (Pctf_val
14486                      ((s, (mkmutable b), (mkvirtual v), (ctyp t),
14487                        (mkloc loc)))) ::
14488                     l
14489               | CgVir (loc, s, b, t) ->
14490                   (Pctf_virt
14491                      ((s, (mkprivate b), (mkpolytype (ctyp t)), (mkloc loc)))) ::
14492                     l
14493               | CgAnt (_, _) -> assert false
14494             and class_expr =
14495               function
14496               | (CeApp (loc, _, _) as c) ->
14497                   let (ce, el) = class_expr_fa [] c in
14498                   let el = List.map label_expr el
14499                   in mkpcl loc (Pcl_apply (class_expr ce, el))
14500               | CeCon (loc, Ast.BFalse, id, tl) ->
14501                   mkpcl loc
14502                     (Pcl_constr (long_class_ident id,
14503                        List.map ctyp (list_of_opt_ctyp tl [])))
14504               | CeFun (loc, (PaLab (_, lab, po)), ce) ->
14505                   mkpcl loc
14506                     (Pcl_fun (lab, None, patt_of_lab loc lab po,
14507                        class_expr ce))
14508               | CeFun (loc, (PaOlbi (_, lab, p, e)), ce) ->
14509                   let lab = paolab lab p
14510                   in
14511                     mkpcl loc
14512                       (Pcl_fun ("?" ^ lab, Some (expr e), patt p,
14513                          class_expr ce))
14514               | CeFun (loc, (PaOlb (_, lab, p)), ce) ->
14515                   let lab = paolab lab p
14516                   in
14517                     mkpcl loc
14518                       (Pcl_fun ("?" ^ lab, None, patt_of_lab loc lab p,
14519                          class_expr ce))
14520               | CeFun (loc, p, ce) ->
14521                   mkpcl loc (Pcl_fun ("", None, patt p, class_expr ce))
14522               | CeLet (loc, rf, bi, ce) ->
14523                   mkpcl loc (Pcl_let (mkrf rf, binding bi [], class_expr ce))
14524               | CeStr (loc, po, cfl) ->
14525                   let p =
14526                     (match po with | Ast.PaNil _ -> Ast.PaAny loc | p -> p) in
14527                   let cil = class_str_item cfl []
14528                   in mkpcl loc (Pcl_structure (((patt p), cil)))
14529               | CeTyc (loc, ce, ct) ->
14530                   mkpcl loc (Pcl_constraint (class_expr ce, class_type ct))
14531               | CeCon (loc, _, _, _) ->
14532                   error loc "invalid virtual class inside a class expression"
14533               | CeAnt (_, _) | CeEq (_, _, _) | CeAnd (_, _, _) | CeNil _ ->
14534                   assert false
14535             and class_str_item c l =
14536               match c with
14537               | CrNil _ -> l
14538               | CrCtr (loc, t1, t2) ->
14539                   (Pcf_cstr (((ctyp t1), (ctyp t2), (mkloc loc)))) :: l
14540               | Ast.CrSem (_, cst1, cst2) ->
14541                   class_str_item cst1 (class_str_item cst2 l)
14542               | CrInh (_, ce, "") -> (Pcf_inher (class_expr ce, None)) :: l
14543               | CrInh (_, ce, pb) ->
14544                   (Pcf_inher (class_expr ce, Some pb)) :: l
14545               | CrIni (_, e) -> (Pcf_init (expr e)) :: l
14546               | CrMth (loc, s, b, e, t) ->
14547                   let t =
14548                     (match t with
14549                      | Ast.TyNil _ -> None
14550                      | t -> Some (mkpolytype (ctyp t))) in
14551                   let e = mkexp loc (Pexp_poly (expr e, t))
14552                   in (Pcf_meth ((s, (mkprivate b), e, (mkloc loc)))) :: l
14553               | CrVal (loc, s, b, e) ->
14554                   (Pcf_val ((s, (mkmutable b), (expr e), (mkloc loc)))) :: l
14555               | CrVir (loc, s, b, t) ->
14556                   (Pcf_virt
14557                      ((s, (mkprivate b), (mkpolytype (ctyp t)), (mkloc loc)))) ::
14558                     l
14559               | CrVvr (loc, s, b, t) ->
14560                   (Pcf_valvirt ((s, (mkmutable b), (ctyp t), (mkloc loc)))) ::
14561                     l
14562               | CrAnt (_, _) -> assert false
14563               
14564             let sig_item ast = sig_item ast []
14565               
14566             let str_item ast = str_item ast []
14567               
14568             let directive =
14569               function
14570               | Ast.ExNil _ -> Pdir_none
14571               | ExStr (_, s) -> Pdir_string s
14572               | ExInt (_, i) -> Pdir_int (int_of_string i)
14573               | Ast.ExId (_, (Ast.IdUid (_, "True"))) -> Pdir_bool true
14574               | Ast.ExId (_, (Ast.IdUid (_, "False"))) -> Pdir_bool false
14575               | e -> Pdir_ident (ident (ident_of_expr e))
14576               
14577             let phrase =
14578               function
14579               | StDir (_, d, dp) -> Ptop_dir (d, directive dp)
14580               | si -> Ptop_def (str_item si)
14581               
14582           end
14583           
14584       end
14585       
14586     module CleanAst =
14587       struct
14588         module Make (Ast : Sig.Camlp4Ast) =
14589           struct
14590             class clean_ast =
14591               object inherit Ast.map as super
14592                        
14593                 method with_constr =
14594                   fun wc ->
14595                     match super#with_constr wc with
14596                     | Ast.WcAnd (_, (Ast.WcNil _), wc) |
14597                         Ast.WcAnd (_, wc, (Ast.WcNil _)) -> wc
14598                     | wc -> wc
14599                   
14600                 method expr =
14601                   fun e ->
14602                     match super#expr e with
14603                     | Ast.ExLet (_, _, (Ast.BiNil _), e) |
14604                         Ast.ExRec (_, (Ast.RbNil _), e) |
14605                         Ast.ExCom (_, (Ast.ExNil _), e) |
14606                         Ast.ExCom (_, e, (Ast.ExNil _)) |
14607                         Ast.ExSem (_, (Ast.ExNil _), e) |
14608                         Ast.ExSem (_, e, (Ast.ExNil _)) -> e
14609                     | e -> e
14610                   
14611                 method patt =
14612                   fun p ->
14613                     match super#patt p with
14614                     | Ast.PaAli (_, p, (Ast.PaNil _)) |
14615                         Ast.PaOrp (_, (Ast.PaNil _), p) |
14616                         Ast.PaOrp (_, p, (Ast.PaNil _)) |
14617                         Ast.PaCom (_, (Ast.PaNil _), p) |
14618                         Ast.PaCom (_, p, (Ast.PaNil _)) |
14619                         Ast.PaSem (_, (Ast.PaNil _), p) |
14620                         Ast.PaSem (_, p, (Ast.PaNil _)) -> p
14621                     | p -> p
14622                   
14623                 method match_case =
14624                   fun mc ->
14625                     match super#match_case mc with
14626                     | Ast.McOr (_, (Ast.McNil _), mc) |
14627                         Ast.McOr (_, mc, (Ast.McNil _)) -> mc
14628                     | mc -> mc
14629                   
14630                 method binding =
14631                   fun bi ->
14632                     match super#binding bi with
14633                     | Ast.BiAnd (_, (Ast.BiNil _), bi) |
14634                         Ast.BiAnd (_, bi, (Ast.BiNil _)) -> bi
14635                     | bi -> bi
14636                   
14637                 method rec_binding =
14638                   fun rb ->
14639                     match super#rec_binding rb with
14640                     | Ast.RbSem (_, (Ast.RbNil _), bi) |
14641                         Ast.RbSem (_, bi, (Ast.RbNil _)) -> bi
14642                     | bi -> bi
14643                   
14644                 method module_binding =
14645                   fun mb ->
14646                     match super#module_binding mb with
14647                     | Ast.MbAnd (_, (Ast.MbNil _), mb) |
14648                         Ast.MbAnd (_, mb, (Ast.MbNil _)) -> mb
14649                     | mb -> mb
14650                   
14651                 method ctyp =
14652                   fun t ->
14653                     match super#ctyp t with
14654                     | Ast.TyPol (_, (Ast.TyNil _), t) |
14655                         Ast.TyAli (_, (Ast.TyNil _), t) |
14656                         Ast.TyAli (_, t, (Ast.TyNil _)) |
14657                         Ast.TyArr (_, t, (Ast.TyNil _)) |
14658                         Ast.TyArr (_, (Ast.TyNil _), t) |
14659                         Ast.TyOr (_, (Ast.TyNil _), t) |
14660                         Ast.TyOr (_, t, (Ast.TyNil _)) |
14661                         Ast.TyOf (_, t, (Ast.TyNil _)) |
14662                         Ast.TyAnd (_, (Ast.TyNil _), t) |
14663                         Ast.TyAnd (_, t, (Ast.TyNil _)) |
14664                         Ast.TySem (_, t, (Ast.TyNil _)) |
14665                         Ast.TySem (_, (Ast.TyNil _), t) |
14666                         Ast.TyCom (_, (Ast.TyNil _), t) |
14667                         Ast.TyCom (_, t, (Ast.TyNil _)) |
14668                         Ast.TyAmp (_, t, (Ast.TyNil _)) |
14669                         Ast.TyAmp (_, (Ast.TyNil _), t) |
14670                         Ast.TySta (_, (Ast.TyNil _), t) |
14671                         Ast.TySta (_, t, (Ast.TyNil _)) -> t
14672                     | t -> t
14673                   
14674                 method sig_item =
14675                   fun sg ->
14676                     match super#sig_item sg with
14677                     | Ast.SgSem (_, (Ast.SgNil _), sg) |
14678                         Ast.SgSem (_, sg, (Ast.SgNil _)) -> sg
14679                     | Ast.SgTyp (loc, (Ast.TyNil _)) -> Ast.SgNil loc
14680                     | sg -> sg
14681                   
14682                 method str_item =
14683                   fun st ->
14684                     match super#str_item st with
14685                     | Ast.StSem (_, (Ast.StNil _), st) |
14686                         Ast.StSem (_, st, (Ast.StNil _)) -> st
14687                     | Ast.StTyp (loc, (Ast.TyNil _)) -> Ast.StNil loc
14688                     | Ast.StVal (loc, _, (Ast.BiNil _)) -> Ast.StNil loc
14689                     | st -> st
14690                   
14691                 method module_type =
14692                   fun mt ->
14693                     match super#module_type mt with
14694                     | Ast.MtWit (_, mt, (Ast.WcNil _)) -> mt
14695                     | mt -> mt
14696                   
14697                 method class_expr =
14698                   fun ce ->
14699                     match super#class_expr ce with
14700                     | Ast.CeAnd (_, (Ast.CeNil _), ce) |
14701                         Ast.CeAnd (_, ce, (Ast.CeNil _)) -> ce
14702                     | ce -> ce
14703                   
14704                 method class_type =
14705                   fun ct ->
14706                     match super#class_type ct with
14707                     | Ast.CtAnd (_, (Ast.CtNil _), ct) |
14708                         Ast.CtAnd (_, ct, (Ast.CtNil _)) -> ct
14709                     | ct -> ct
14710                   
14711                 method class_sig_item =
14712                   fun csg ->
14713                     match super#class_sig_item csg with
14714                     | Ast.CgSem (_, (Ast.CgNil _), csg) |
14715                         Ast.CgSem (_, csg, (Ast.CgNil _)) -> csg
14716                     | csg -> csg
14717                   
14718                 method class_str_item =
14719                   fun cst ->
14720                     match super#class_str_item cst with
14721                     | Ast.CrSem (_, (Ast.CrNil _), cst) |
14722                         Ast.CrSem (_, cst, (Ast.CrNil _)) -> cst
14723                     | cst -> cst
14724                   
14725               end
14726               
14727           end
14728           
14729       end
14730       
14731     module CommentFilter :
14732       sig
14733         module Make (Token : Sig.Camlp4Token) :
14734           sig
14735             open Token
14736               
14737             type t
14738             
14739             val mk : unit -> t
14740               
14741             val define : Token.Filter.t -> t -> unit
14742               
14743             val filter :
14744               t -> (Token.t * Loc.t) Stream.t -> (Token.t * Loc.t) Stream.t
14745               
14746             val take_list : t -> (string * Loc.t) list
14747               
14748             val take_stream : t -> (string * Loc.t) Stream.t
14749               
14750           end
14751           
14752       end =
14753       struct
14754         module Make (Token : Sig.Camlp4Token) =
14755           struct
14756             open Token
14757               
14758             type t =
14759               (((string * Loc.t) Stream.t) * ((string * Loc.t) Queue.t))
14760             
14761             let mk () =
14762               let q = Queue.create () in
14763               let f _ = try Some (Queue.take q) with | Queue.Empty -> None
14764               in ((Stream.from f), q)
14765               
14766             let filter (_, q) =
14767               let rec self (__strm : _ Stream.t) =
14768                 match Stream.peek __strm with
14769                 | Some ((Sig.COMMENT x, loc)) ->
14770                     (Stream.junk __strm;
14771                      let xs = __strm in (Queue.add (x, loc) q; self xs))
14772                 | Some x ->
14773                     (Stream.junk __strm;
14774                      let xs = __strm
14775                      in Stream.icons x (Stream.slazy (fun _ -> self xs)))
14776                 | _ -> Stream.sempty
14777               in self
14778               
14779             let take_list (_, q) =
14780               let rec self accu =
14781                 if Queue.is_empty q
14782                 then accu
14783                 else self ((Queue.take q) :: accu)
14784               in self []
14785               
14786             let take_stream = fst
14787               
14788             let define token_fiter comments_strm =
14789               Token.Filter.define_filter token_fiter
14790                 (fun previous strm -> previous (filter comments_strm strm))
14791               
14792           end
14793           
14794       end
14795       
14796     module DynLoader : sig include Sig.DynLoader
14797                               end =
14798       struct
14799         type t = string Queue.t
14800         
14801         exception Error of string * string
14802           
14803         let include_dir x y = Queue.add y x
14804           
14805         let fold_load_path x f acc = Queue.fold (fun x y -> f y x) acc x
14806           
14807         let mk ?(ocaml_stdlib = true) ?(camlp4_stdlib = true) () =
14808           let q = Queue.create ()
14809           in
14810             (if ocaml_stdlib
14811              then include_dir q Camlp4_config.ocaml_standard_library
14812              else ();
14813              if camlp4_stdlib
14814              then
14815                (include_dir q Camlp4_config.camlp4_standard_library;
14816                 include_dir q
14817                   (Filename.concat Camlp4_config.camlp4_standard_library
14818                      "Camlp4Parsers");
14819                 include_dir q
14820                   (Filename.concat Camlp4_config.camlp4_standard_library
14821                      "Camlp4Printers");
14822                 include_dir q
14823                   (Filename.concat Camlp4_config.camlp4_standard_library
14824                      "Camlp4Filters"))
14825              else ();
14826              include_dir q ".";
14827              q)
14828           
14829         let find_in_path x name =
14830           if not (Filename.is_implicit name)
14831           then if Sys.file_exists name then name else raise Not_found
14832           else
14833             (let res =
14834                fold_load_path x
14835                  (fun dir ->
14836                     function
14837                     | None ->
14838                         let fullname = Filename.concat dir name
14839                         in
14840                           if Sys.file_exists fullname
14841                           then Some fullname
14842                           else None
14843                     | x -> x)
14844                  None
14845              in match res with | None -> raise Not_found | Some x -> x)
14846           
14847         let load =
14848           let _initialized = ref false
14849           in
14850             fun _path file ->
14851               (if not !_initialized
14852                then
14853                  (try
14854                     (Dynlink.init ();
14855                      Dynlink.allow_unsafe_modules true;
14856                      _initialized := true)
14857                   with
14858                   | Dynlink.Error e ->
14859                       raise
14860                         (Error ("Camlp4's dynamic loader initialization",
14861                            Dynlink.error_message e)))
14862                else ();
14863                let fname =
14864                  try find_in_path _path file
14865                  with
14866                  | Not_found ->
14867                      raise (Error (file, "file not found in path"))
14868                in
14869                  try Dynlink.loadfile fname
14870                  with
14871                  | Dynlink.Error e ->
14872                      raise (Error (fname, Dynlink.error_message e)))
14873           
14874         let is_native = Dynlink.is_native
14875           
14876       end
14877       
14878     module EmptyError : sig include Sig.Error
14879                                end =
14880       struct
14881         type t = unit
14882         
14883         exception E of t
14884           
14885         let print _ = assert false
14886           
14887         let to_string _ = assert false
14888           
14889       end
14890       
14891     module EmptyPrinter :
14892       sig module Make (Ast : Sig.Ast) : Sig.Printer(Ast).S
14893              end =
14894       struct
14895         module Make (Ast : Sig.Ast) =
14896           struct
14897             let print_interf ?input_file:(_) ?output_file:(_) _ =
14898               failwith "No interface printer"
14899               
14900             let print_implem ?input_file:(_) ?output_file:(_) _ =
14901               failwith "No implementation printer"
14902               
14903           end
14904           
14905       end
14906       
14907     module FreeVars :
14908       sig
14909         module Make (Ast : Sig.Camlp4Ast) :
14910           sig
14911             module S : Set.S with type elt = string
14912               
14913             val fold_binding_vars :
14914               (string -> 'accu -> 'accu) -> Ast.binding -> 'accu -> 'accu
14915               
14916             class ['accu] c_fold_pattern_vars :
14917               (string -> 'accu -> 'accu) ->
14918                 'accu ->
14919                   object inherit Ast.fold
14920                             val acc : 'accu
14921                                method acc : 'accu
14922                                  
14923                   end
14924               
14925             val fold_pattern_vars :
14926               (string -> 'accu -> 'accu) -> Ast.patt -> 'accu -> 'accu
14927               
14928             class ['accu] fold_free_vars :
14929               (string -> 'accu -> 'accu) ->
14930                 ?env_init: S.t ->
14931                   'accu ->
14932                     object ('self_type)
14933                       inherit Ast.fold
14934                         
14935                       val free : 'accu
14936                         
14937                       val env : S.t
14938                         
14939                       method free : 'accu
14940                         
14941                       method set_env : S.t -> 'self_type
14942                         
14943                       method add_atom : string -> 'self_type
14944                         
14945                       method add_patt : Ast.patt -> 'self_type
14946                         
14947                       method add_binding : Ast.binding -> 'self_type
14948                         
14949                     end
14950               
14951             val free_vars : S.t -> Ast.expr -> S.t
14952               
14953           end
14954           
14955       end =
14956       struct
14957         module Make (Ast : Sig.Camlp4Ast) =
14958           struct
14959             module S = Set.Make(String)
14960               
14961             class ['accu] c_fold_pattern_vars f init =
14962               object inherit Ast.fold as super
14963                        
14964                 val acc = init
14965                   
14966                 method acc : 'accu = acc
14967                   
14968                 method patt =
14969                   function
14970                   | Ast.PaId (_, (Ast.IdLid (_, s))) |
14971                       Ast.PaLab (_, s, (Ast.PaNil _)) |
14972                       Ast.PaOlb (_, s, (Ast.PaNil _)) -> {< acc = f s acc; >}
14973                   | p -> super#patt p
14974                   
14975               end
14976               
14977             let fold_pattern_vars f p init =
14978               ((new c_fold_pattern_vars f init)#patt p)#acc
14979               
14980             let rec fold_binding_vars f bi acc =
14981               match bi with
14982               | Ast.BiAnd (_, bi1, bi2) ->
14983                   fold_binding_vars f bi1 (fold_binding_vars f bi2 acc)
14984               | Ast.BiEq (_, p, _) -> fold_pattern_vars f p acc
14985               | Ast.BiNil _ -> acc
14986               | Ast.BiAnt (_, _) -> assert false
14987               
14988             class ['accu] fold_free_vars (f : string -> 'accu -> 'accu)
14989                     ?(env_init = S.empty) free_init =
14990               object (o)
14991                 inherit Ast.fold as super
14992                   
14993                 val free = (free_init : 'accu)
14994                   
14995                 val env = (env_init : S.t)
14996                   
14997                 method free = free
14998                   
14999                 method set_env = fun env -> {< env = env; >}
15000                   
15001                 method add_atom = fun s -> {< env = S.add s env; >}
15002                   
15003                 method add_patt =
15004                   fun p -> {< env = fold_pattern_vars S.add p env; >}
15005                   
15006                 method add_binding =
15007                   fun bi -> {< env = fold_binding_vars S.add bi env; >}
15008                   
15009                 method expr =
15010                   function
15011                   | Ast.ExId (_, (Ast.IdLid (_, s))) |
15012                       Ast.ExLab (_, s, (Ast.ExNil _)) |
15013                       Ast.ExOlb (_, s, (Ast.ExNil _)) ->
15014                       if S.mem s env then o else {< free = f s free; >}
15015                   | Ast.ExLet (_, Ast.BFalse, bi, e) ->
15016                       (((o#add_binding bi)#expr e)#set_env env)#binding bi
15017                   | Ast.ExLet (_, Ast.BTrue, bi, e) ->
15018                       (((o#add_binding bi)#expr e)#binding bi)#set_env env
15019                   | Ast.ExFor (_, s, e1, e2, _, e3) ->
15020                       ((((o#expr e1)#expr e2)#add_atom s)#expr e3)#set_env
15021                         env
15022                   | Ast.ExId (_, _) | Ast.ExNew (_, _) -> o
15023                   | Ast.ExObj (_, p, cst) ->
15024                       ((o#add_patt p)#class_str_item cst)#set_env env
15025                   | e -> super#expr e
15026                   
15027                 method match_case =
15028                   function
15029                   | Ast.McArr (_, p, e1, e2) ->
15030                       (((o#add_patt p)#expr e1)#expr e2)#set_env env
15031                   | m -> super#match_case m
15032                   
15033                 method str_item =
15034                   function
15035                   | Ast.StExt (_, s, t, _) -> (o#ctyp t)#add_atom s
15036                   | Ast.StVal (_, Ast.BFalse, bi) ->
15037                       (o#binding bi)#add_binding bi
15038                   | Ast.StVal (_, Ast.BTrue, bi) ->
15039                       (o#add_binding bi)#binding bi
15040                   | st -> super#str_item st
15041                   
15042                 method class_expr =
15043                   function
15044                   | Ast.CeFun (_, p, ce) ->
15045                       ((o#add_patt p)#class_expr ce)#set_env env
15046                   | Ast.CeLet (_, Ast.BFalse, bi, ce) ->
15047                       (((o#binding bi)#add_binding bi)#class_expr ce)#set_env
15048                         env
15049                   | Ast.CeLet (_, Ast.BTrue, bi, ce) ->
15050                       (((o#add_binding bi)#binding bi)#class_expr ce)#set_env
15051                         env
15052                   | Ast.CeStr (_, p, cst) ->
15053                       ((o#add_patt p)#class_str_item cst)#set_env env
15054                   | ce -> super#class_expr ce
15055                   
15056                 method class_str_item =
15057                   function
15058                   | (Ast.CrInh (_, _, "") as cst) -> super#class_str_item cst
15059                   | Ast.CrInh (_, ce, s) -> (o#class_expr ce)#add_atom s
15060                   | Ast.CrVal (_, s, _, e) -> (o#expr e)#add_atom s
15061                   | Ast.CrVvr (_, s, _, t) -> (o#ctyp t)#add_atom s
15062                   | cst -> super#class_str_item cst
15063                   
15064                 method module_expr =
15065                   function
15066                   | Ast.MeStr (_, st) -> (o#str_item st)#set_env env
15067                   | me -> super#module_expr me
15068                   
15069               end
15070               
15071             let free_vars env_init e =
15072               let fold = new fold_free_vars S.add ~env_init S.empty
15073               in (fold#expr e)#free
15074               
15075           end
15076           
15077       end
15078       
15079     module Grammar =
15080       struct
15081         module Context =
15082           struct
15083             module type S =
15084               sig
15085                 module Token : Sig.Token
15086                   
15087                 open Token
15088                   
15089                 type t
15090                 
15091                 val call_with_ctx :
15092                   (Token.t * Loc.t) Stream.t -> (t -> 'a) -> 'a
15093                   
15094                 val loc_bp : t -> Loc.t
15095                   
15096                 val loc_ep : t -> Loc.t
15097                   
15098                 val stream : t -> (Token.t * Loc.t) Stream.t
15099                   
15100                 val peek_nth : t -> int -> (Token.t * Loc.t) option
15101                   
15102                 val njunk : t -> int -> unit
15103                   
15104                 val junk : (Token.t * Loc.t) Stream.t -> unit
15105                   
15106                 val bp : (Token.t * Loc.t) Stream.t -> Loc.t
15107                   
15108               end
15109               
15110             module Make (Token : Sig.Token) : S with module Token = Token =
15111               struct
15112                 module Token = Token
15113                   
15114                 open Token
15115                   
15116                 type t =
15117                   { mutable strm : (Token.t * Loc.t) Stream.t;
15118                     mutable loc : Loc.t
15119                   }
15120                 
15121                 let loc_bp c =
15122                   match Stream.peek c.strm with
15123                   | None -> Loc.ghost
15124                   | Some ((_, loc)) -> loc
15125                   
15126                 let loc_ep c = c.loc
15127                   
15128                 let set_loc c =
15129                   match Stream.peek c.strm with
15130                   | Some ((_, loc)) -> c.loc <- loc
15131                   | None -> ()
15132                   
15133                 let mk strm =
15134                   match Stream.peek strm with
15135                   | Some ((_, loc)) -> { strm = strm; loc = loc; }
15136                   | None -> { strm = strm; loc = Loc.ghost; }
15137                   
15138                 let stream c = c.strm
15139                   
15140                 let peek_nth c n =
15141                   let list = Stream.npeek n c.strm in
15142                   let rec loop list n =
15143                     match (list, n) with
15144                     | ((((_, loc) as x)) :: _, 1) -> (c.loc <- loc; Some x)
15145                     | (_ :: l, n) -> loop l (n - 1)
15146                     | ([], _) -> None
15147                   in loop list n
15148                   
15149                 let njunk c n =
15150                   (for i = 1 to n do Stream.junk c.strm done; set_loc c)
15151                   
15152                 let streams = ref []
15153                   
15154                 let mk strm =
15155                   let c = mk strm in
15156                   let () = streams := (strm, c) :: !streams in c
15157                   
15158                 let junk strm =
15159                   (set_loc (List.assq strm !streams); Stream.junk strm)
15160                   
15161                 let bp strm = loc_bp (List.assq strm !streams)
15162                   
15163                 let call_with_ctx strm f =
15164                   let streams_v = !streams in
15165                   let r =
15166                     try f (mk strm)
15167                     with | exc -> (streams := streams_v; raise exc)
15168                   in (streams := streams_v; r)
15169                   
15170               end
15171               
15172           end
15173           
15174         module Structure =
15175           struct
15176             open Sig.Grammar
15177               
15178             module type S =
15179               sig
15180                 module Loc : Sig.Loc
15181                   
15182                 module Token : Sig.Token with module Loc = Loc
15183                   
15184                 module Lexer : Sig.Lexer with module Loc = Loc
15185                   and module Token = Token
15186                   
15187                 module Context : Context.S with module Token = Token
15188                   
15189                 module Action : Sig.Grammar.Action
15190                   
15191                 type gram =
15192                   { gfilter : Token.Filter.t;
15193                     gkeywords : (string, int ref) Hashtbl.t;
15194                     glexer :
15195                       Loc.t -> char Stream.t -> (Token.t * Loc.t) Stream.t;
15196                     warning_verbose : bool ref; error_verbose : bool ref
15197                   }
15198                 
15199                 type efun =
15200                   Context.t -> (Token.t * Loc.t) Stream.t -> Action.t
15201                 
15202                 type token_pattern = ((Token.t -> bool) * string)
15203                 
15204                 type internal_entry =
15205                   { egram : gram; ename : string;
15206                     mutable estart : int -> efun;
15207                     mutable econtinue : int -> Loc.t -> Action.t -> efun;
15208                     mutable edesc : desc
15209                   }
15210                   and desc =
15211                   | Dlevels of level list
15212                   | Dparser of ((Token.t * Loc.t) Stream.t -> Action.t)
15213                   and level =
15214                   { assoc : assoc; lname : string option; lsuffix : tree;
15215                     lprefix : tree
15216                   }
15217                   and symbol =
15218                   | Smeta of string * symbol list * Action.t
15219                   | Snterm of internal_entry
15220                   | Snterml of internal_entry * string
15221                   | Slist0 of symbol
15222                   | Slist0sep of symbol * symbol
15223                   | Slist1 of symbol
15224                   | Slist1sep of symbol * symbol
15225                   | Sopt of symbol
15226                   | Sself
15227                   | Snext
15228                   | Stoken of token_pattern
15229                   | Skeyword of string
15230                   | Stree of tree
15231                   and tree =
15232                   | Node of node
15233                   | LocAct of Action.t * Action.t list
15234                   | DeadEnd
15235                   and node =
15236                   { node : symbol; son : tree; brother : tree
15237                   }
15238                 
15239                 type production_rule = ((symbol list) * Action.t)
15240                 
15241                 type single_extend_statment =
15242                   ((string option) * (assoc option) * (production_rule list))
15243                 
15244                 type extend_statment =
15245                   ((position option) * (single_extend_statment list))
15246                 
15247                 type delete_statment = symbol list
15248                 
15249                 type ('a, 'b, 'c) fold =
15250                   internal_entry ->
15251                     symbol list -> ('a Stream.t -> 'b) -> 'a Stream.t -> 'c
15252                 
15253                 type ('a, 'b, 'c) foldsep =
15254                   internal_entry ->
15255                     symbol list ->
15256                       ('a Stream.t -> 'b) ->
15257                         ('a Stream.t -> unit) -> 'a Stream.t -> 'c
15258                 
15259                 val get_filter : gram -> Token.Filter.t
15260                   
15261                 val using : gram -> string -> unit
15262                   
15263                 val removing : gram -> string -> unit
15264                   
15265               end
15266               
15267             module Make (Lexer : Sig.Lexer) =
15268               struct
15269                 module Loc = Lexer.Loc
15270                   
15271                 module Token = Lexer.Token
15272                   
15273                 module Action : Sig.Grammar.Action =
15274                   struct
15275                     type t = Obj.t
15276                     
15277                     let mk = Obj.repr
15278                       
15279                     let get = Obj.obj
15280                       
15281                     let getf = Obj.obj
15282                       
15283                     let getf2 = Obj.obj
15284                       
15285                   end
15286                   
15287                 module Lexer = Lexer
15288                   
15289                 type gram =
15290                   { gfilter : Token.Filter.t;
15291                     gkeywords : (string, int ref) Hashtbl.t;
15292                     glexer :
15293                       Loc.t -> char Stream.t -> (Token.t * Loc.t) Stream.t;
15294                     warning_verbose : bool ref; error_verbose : bool ref
15295                   }
15296                 
15297                 module Context = Context.Make(Token)
15298                   
15299                 type efun =
15300                   Context.t -> (Token.t * Loc.t) Stream.t -> Action.t
15301                 
15302                 type token_pattern = ((Token.t -> bool) * string)
15303                 
15304                 type internal_entry =
15305                   { egram : gram; ename : string;
15306                     mutable estart : int -> efun;
15307                     mutable econtinue : int -> Loc.t -> Action.t -> efun;
15308                     mutable edesc : desc
15309                   }
15310                   and desc =
15311                   | Dlevels of level list
15312                   | Dparser of ((Token.t * Loc.t) Stream.t -> Action.t)
15313                   and level =
15314                   { assoc : assoc; lname : string option; lsuffix : tree;
15315                     lprefix : tree
15316                   }
15317                   and symbol =
15318                   | Smeta of string * symbol list * Action.t
15319                   | Snterm of internal_entry
15320                   | Snterml of internal_entry * string
15321                   | Slist0 of symbol
15322                   | Slist0sep of symbol * symbol
15323                   | Slist1 of symbol
15324                   | Slist1sep of symbol * symbol
15325                   | Sopt of symbol
15326                   | Sself
15327                   | Snext
15328                   | Stoken of token_pattern
15329                   | Skeyword of string
15330                   | Stree of tree
15331                   and tree =
15332                   | Node of node
15333                   | LocAct of Action.t * Action.t list
15334                   | DeadEnd
15335                   and node =
15336                   { node : symbol; son : tree; brother : tree
15337                   }
15338                 
15339                 type production_rule = ((symbol list) * Action.t)
15340                 
15341                 type single_extend_statment =
15342                   ((string option) * (assoc option) * (production_rule list))
15343                 
15344                 type extend_statment =
15345                   ((position option) * (single_extend_statment list))
15346                 
15347                 type delete_statment = symbol list
15348                 
15349                 type ('a, 'b, 'c) fold =
15350                   internal_entry ->
15351                     symbol list -> ('a Stream.t -> 'b) -> 'a Stream.t -> 'c
15352                 
15353                 type ('a, 'b, 'c) foldsep =
15354                   internal_entry ->
15355                     symbol list ->
15356                       ('a Stream.t -> 'b) ->
15357                         ('a Stream.t -> unit) -> 'a Stream.t -> 'c
15358                 
15359                 let get_filter g = g.gfilter
15360                   
15361                 type 'a not_filtered = 'a
15362                 
15363                 let using { gkeywords = table; gfilter = filter } kwd =
15364                   let r =
15365                     try Hashtbl.find table kwd
15366                     with
15367                     | Not_found ->
15368                         let r = ref 0 in (Hashtbl.add table kwd r; r)
15369                   in (Token.Filter.keyword_added filter kwd (!r = 0); incr r)
15370                   
15371                 let removing { gkeywords = table; gfilter = filter } kwd =
15372                   let r = Hashtbl.find table kwd in
15373                   let () = decr r
15374                   in
15375                     if !r = 0
15376                     then
15377                       (Token.Filter.keyword_removed filter kwd;
15378                        Hashtbl.remove table kwd)
15379                     else ()
15380                   
15381               end
15382               
15383           end
15384           
15385         module Search =
15386           struct
15387             module Make (Structure : Structure.S) =
15388               struct
15389                 open Structure
15390                   
15391                 let tree_in_entry prev_symb tree =
15392                   function
15393                   | Dlevels levels ->
15394                       let rec search_levels =
15395                         (function
15396                          | [] -> tree
15397                          | level :: levels ->
15398                              (match search_level level with
15399                               | Some tree -> tree
15400                               | None -> search_levels levels))
15401                       and search_level level =
15402                         (match search_tree level.lsuffix with
15403                          | Some t ->
15404                              Some
15405                                (Node
15406                                   { node = Sself; son = t; brother = DeadEnd;
15407                                   })
15408                          | None -> search_tree level.lprefix)
15409                       and search_tree t =
15410                         if (tree <> DeadEnd) && (t == tree)
15411                         then Some t
15412                         else
15413                           (match t with
15414                            | Node n ->
15415                                (match search_symbol n.node with
15416                                 | Some symb ->
15417                                     Some
15418                                       (Node
15419                                          {
15420                                            node = symb;
15421                                            son = n.son;
15422                                            brother = DeadEnd;
15423                                          })
15424                                 | None ->
15425                                     (match search_tree n.son with
15426                                      | Some t ->
15427                                          Some
15428                                            (Node
15429                                               {
15430                                                 node = n.node;
15431                                                 son = t;
15432                                                 brother = DeadEnd;
15433                                               })
15434                                      | None -> search_tree n.brother))
15435                            | LocAct (_, _) | DeadEnd -> None)
15436                       and search_symbol symb =
15437                         (match symb with
15438                          | Snterm _ | Snterml (_, _) | Slist0 _ |
15439                              Slist0sep (_, _) | Slist1 _ | Slist1sep (_, _) |
15440                              Sopt _ | Stoken _ | Stree _ | Skeyword _ when
15441                              symb == prev_symb -> Some symb
15442                          | Slist0 symb ->
15443                              (match search_symbol symb with
15444                               | Some symb -> Some (Slist0 symb)
15445                               | None -> None)
15446                          | Slist0sep (symb, sep) ->
15447                              (match search_symbol symb with
15448                               | Some symb -> Some (Slist0sep (symb, sep))
15449                               | None ->
15450                                   (match search_symbol sep with
15451                                    | Some sep -> Some (Slist0sep (symb, sep))
15452                                    | None -> None))
15453                          | Slist1 symb ->
15454                              (match search_symbol symb with
15455                               | Some symb -> Some (Slist1 symb)
15456                               | None -> None)
15457                          | Slist1sep (symb, sep) ->
15458                              (match search_symbol symb with
15459                               | Some symb -> Some (Slist1sep (symb, sep))
15460                               | None ->
15461                                   (match search_symbol sep with
15462                                    | Some sep -> Some (Slist1sep (symb, sep))
15463                                    | None -> None))
15464                          | Sopt symb ->
15465                              (match search_symbol symb with
15466                               | Some symb -> Some (Sopt symb)
15467                               | None -> None)
15468                          | Stree t ->
15469                              (match search_tree t with
15470                               | Some t -> Some (Stree t)
15471                               | None -> None)
15472                          | _ -> None)
15473                       in search_levels levels
15474                   | Dparser _ -> tree
15475                   
15476               end
15477               
15478           end
15479           
15480         module Tools =
15481           struct
15482             module Make (Structure : Structure.S) =
15483               struct
15484                 open Structure
15485                   
15486                 let empty_entry ename _ _ _ =
15487                   raise (Stream.Error ("entry [" ^ (ename ^ "] is empty")))
15488                   
15489                 let is_level_labelled n lev =
15490                   match lev.lname with | Some n1 -> n = n1 | None -> false
15491                   
15492                 let warning_verbose = ref true
15493                   
15494                 let rec get_token_list entry tokl last_tok tree =
15495                   match tree with
15496                   | Node
15497                       {
15498                         node = (Stoken _ | Skeyword _ as tok);
15499                         son = son;
15500                         brother = DeadEnd
15501                       } -> get_token_list entry (last_tok :: tokl) tok son
15502                   | _ ->
15503                       if tokl = []
15504                       then None
15505                       else
15506                         Some
15507                           (((List.rev (last_tok :: tokl)), last_tok, tree))
15508                   
15509                 let is_antiquot s =
15510                   let len = String.length s in (len > 1) && (s.[0] = '$')
15511                   
15512                 let eq_Stoken_ids s1 s2 =
15513                   (not (is_antiquot s1)) &&
15514                     ((not (is_antiquot s2)) && (s1 = s2))
15515                   
15516                 let logically_eq_symbols entry =
15517                   let rec eq_symbols s1 s2 =
15518                     match (s1, s2) with
15519                     | (Snterm e1, Snterm e2) -> e1.ename = e2.ename
15520                     | (Snterm e1, Sself) -> e1.ename = entry.ename
15521                     | (Sself, Snterm e2) -> entry.ename = e2.ename
15522                     | (Snterml (e1, l1), Snterml (e2, l2)) ->
15523                         (e1.ename = e2.ename) && (l1 = l2)
15524                     | (Slist0 s1, Slist0 s2) -> eq_symbols s1 s2
15525                     | (Slist0sep (s1, sep1), Slist0sep (s2, sep2)) ->
15526                         (eq_symbols s1 s2) && (eq_symbols sep1 sep2)
15527                     | (Slist1 s1, Slist1 s2) -> eq_symbols s1 s2
15528                     | (Slist1sep (s1, sep1), Slist1sep (s2, sep2)) ->
15529                         (eq_symbols s1 s2) && (eq_symbols sep1 sep2)
15530                     | (Sopt s1, Sopt s2) -> eq_symbols s1 s2
15531                     | (Stree t1, Stree t2) -> eq_trees t1 t2
15532                     | (Stoken ((_, s1)), Stoken ((_, s2))) ->
15533                         eq_Stoken_ids s1 s2
15534                     | _ -> s1 = s2
15535                   and eq_trees t1 t2 =
15536                     match (t1, t2) with
15537                     | (Node n1, Node n2) ->
15538                         (eq_symbols n1.node n2.node) &&
15539                           ((eq_trees n1.son n2.son) &&
15540                              (eq_trees n1.brother n2.brother))
15541                     | ((LocAct (_, _) | DeadEnd), (LocAct (_, _) | DeadEnd))
15542                         -> true
15543                     | _ -> false
15544                   in eq_symbols
15545                   
15546                 let rec eq_symbol s1 s2 =
15547                   match (s1, s2) with
15548                   | (Snterm e1, Snterm e2) -> e1 == e2
15549                   | (Snterml (e1, l1), Snterml (e2, l2)) ->
15550                       (e1 == e2) && (l1 = l2)
15551                   | (Slist0 s1, Slist0 s2) -> eq_symbol s1 s2
15552                   | (Slist0sep (s1, sep1), Slist0sep (s2, sep2)) ->
15553                       (eq_symbol s1 s2) && (eq_symbol sep1 sep2)
15554                   | (Slist1 s1, Slist1 s2) -> eq_symbol s1 s2
15555                   | (Slist1sep (s1, sep1), Slist1sep (s2, sep2)) ->
15556                       (eq_symbol s1 s2) && (eq_symbol sep1 sep2)
15557                   | (Sopt s1, Sopt s2) -> eq_symbol s1 s2
15558                   | (Stree _, Stree _) -> false
15559                   | (Stoken ((_, s1)), Stoken ((_, s2))) ->
15560                       eq_Stoken_ids s1 s2
15561                   | _ -> s1 = s2
15562                   
15563               end
15564               
15565           end
15566           
15567         module Print :
15568           sig
15569             module Make (Structure : Structure.S) :
15570               sig
15571                 val flatten_tree :
15572                   Structure.tree -> (Structure.symbol list) list
15573                   
15574                 val print_symbol :
15575                   Format.formatter -> Structure.symbol -> unit
15576                   
15577                 val print_meta :
15578                   Format.formatter -> string -> Structure.symbol list -> unit
15579                   
15580                 val print_symbol1 :
15581                   Format.formatter -> Structure.symbol -> unit
15582                   
15583                 val print_rule :
15584                   Format.formatter -> Structure.symbol list -> unit
15585                   
15586                 val print_level :
15587                   Format.formatter ->
15588                     (Format.formatter -> unit -> unit) ->
15589                       (Structure.symbol list) list -> unit
15590                   
15591                 val levels : Format.formatter -> Structure.level list -> unit
15592                   
15593                 val entry :
15594                   Format.formatter -> Structure.internal_entry -> unit
15595                   
15596               end
15597               
15598             module MakeDump (Structure : Structure.S) :
15599               sig
15600                 val print_symbol :
15601                   Format.formatter -> Structure.symbol -> unit
15602                   
15603                 val print_meta :
15604                   Format.formatter -> string -> Structure.symbol list -> unit
15605                   
15606                 val print_symbol1 :
15607                   Format.formatter -> Structure.symbol -> unit
15608                   
15609                 val print_rule :
15610                   Format.formatter -> Structure.symbol list -> unit
15611                   
15612                 val print_level :
15613                   Format.formatter ->
15614                     (Format.formatter -> unit -> unit) ->
15615                       (Structure.symbol list) list -> unit
15616                   
15617                 val levels : Format.formatter -> Structure.level list -> unit
15618                   
15619                 val entry :
15620                   Format.formatter -> Structure.internal_entry -> unit
15621                   
15622               end
15623               
15624           end =
15625           struct
15626             module Make (Structure : Structure.S) =
15627               struct
15628                 open Structure
15629                   
15630                 open Format
15631                   
15632                 open Sig.Grammar
15633                   
15634                 let rec flatten_tree =
15635                   function
15636                   | DeadEnd -> []
15637                   | LocAct (_, _) -> [ [] ]
15638                   | Node { node = n; brother = b; son = s } ->
15639                       (List.map (fun l -> n :: l) (flatten_tree s)) @
15640                         (flatten_tree b)
15641                   
15642                 let rec print_symbol ppf =
15643                   function
15644                   | Smeta (n, sl, _) -> print_meta ppf n sl
15645                   | Slist0 s -> fprintf ppf "LIST0 %a" print_symbol1 s
15646                   | Slist0sep (s, t) ->
15647                       fprintf ppf "LIST0 %a SEP %a" print_symbol1 s
15648                         print_symbol1 t
15649                   | Slist1 s -> fprintf ppf "LIST1 %a" print_symbol1 s
15650                   | Slist1sep (s, t) ->
15651                       fprintf ppf "LIST1 %a SEP %a" print_symbol1 s
15652                         print_symbol1 t
15653                   | Sopt s -> fprintf ppf "OPT %a" print_symbol1 s
15654                   | Snterml (e, l) -> fprintf ppf "%s@ LEVEL@ %S" e.ename l
15655                   | (Snterm _ | Snext | Sself | Stree _ | Stoken _ |
15656                        Skeyword _
15657                      as s) -> print_symbol1 ppf s
15658                 and print_meta ppf n sl =
15659                   let rec loop i =
15660                     function
15661                     | [] -> ()
15662                     | s :: sl ->
15663                         let j =
15664                           (try String.index_from n i ' '
15665                            with | Not_found -> String.length n)
15666                         in
15667                           (fprintf ppf "%s %a" (String.sub n i (j - i))
15668                              print_symbol1 s;
15669                            if sl = []
15670                            then ()
15671                            else
15672                              (fprintf ppf " ";
15673                               loop (min (j + 1) (String.length n)) sl))
15674                   in loop 0 sl
15675                 and print_symbol1 ppf =
15676                   function
15677                   | Snterm e -> pp_print_string ppf e.ename
15678                   | Sself -> pp_print_string ppf "SELF"
15679                   | Snext -> pp_print_string ppf "NEXT"
15680                   | Stoken ((_, descr)) -> pp_print_string ppf descr
15681                   | Skeyword s -> fprintf ppf "%S" s
15682                   | Stree t ->
15683                       print_level ppf pp_print_space (flatten_tree t)
15684                   | (Smeta (_, _, _) | Snterml (_, _) | Slist0 _ |
15685                        Slist0sep (_, _) | Slist1 _ | Slist1sep (_, _) |
15686                        Sopt _
15687                      as s) -> fprintf ppf "(%a)" print_symbol s
15688                 and print_rule ppf symbols =
15689                   (fprintf ppf "@[<hov 0>";
15690                    let _ =
15691                      List.fold_left
15692                        (fun sep symbol ->
15693                           (fprintf ppf "%t%a" sep print_symbol symbol;
15694                            fun ppf -> fprintf ppf ";@ "))
15695                        (fun _ -> ()) symbols
15696                    in fprintf ppf "@]")
15697                 and print_level ppf pp_print_space rules =
15698                   (fprintf ppf "@[<hov 0>[ ";
15699                    let _ =
15700                      List.fold_left
15701                        (fun sep rule ->
15702                           (fprintf ppf "%t%a" sep print_rule rule;
15703                            fun ppf -> fprintf ppf "%a| " pp_print_space ()))
15704                        (fun _ -> ()) rules
15705                    in fprintf ppf " ]@]")
15706                   
15707                 let levels ppf elev =
15708                   let _ =
15709                     List.fold_left
15710                       (fun sep lev ->
15711                          let rules =
15712                            (List.map (fun t -> Sself :: t)
15713                               (flatten_tree lev.lsuffix))
15714                              @ (flatten_tree lev.lprefix)
15715                          in
15716                            (fprintf ppf "%t@[<hov 2>" sep;
15717                             (match lev.lname with
15718                              | Some n -> fprintf ppf "%S@;<1 2>" n
15719                              | None -> ());
15720                             (match lev.assoc with
15721                              | LeftA -> fprintf ppf "LEFTA"
15722                              | RightA -> fprintf ppf "RIGHTA"
15723                              | NonA -> fprintf ppf "NONA");
15724                             fprintf ppf "@]@;<1 2>";
15725                             print_level ppf pp_force_newline rules;
15726                             fun ppf -> fprintf ppf "@,| "))
15727                       (fun _ -> ()) elev
15728                   in ()
15729                   
15730                 let entry ppf e =
15731                   (fprintf ppf "@[<v 0>%s: [ " e.ename;
15732                    (match e.edesc with
15733                     | Dlevels elev -> levels ppf elev
15734                     | Dparser _ -> fprintf ppf "<parser>");
15735                    fprintf ppf " ]@]")
15736                   
15737               end
15738               
15739             module MakeDump (Structure : Structure.S) =
15740               struct
15741                 open Structure
15742                   
15743                 open Format
15744                   
15745                 open Sig.Grammar
15746                   
15747                 type brothers = | Bro of symbol * brothers list
15748                 
15749                 let rec print_tree ppf tree =
15750                   let rec get_brothers acc =
15751                     function
15752                     | DeadEnd -> List.rev acc
15753                     | LocAct (_, _) -> List.rev acc
15754                     | Node { node = n; brother = b; son = s } ->
15755                         get_brothers ((Bro (n, get_brothers [] s)) :: acc) b
15756                   and print_brothers ppf brothers =
15757                     if brothers = []
15758                     then fprintf ppf "@ []"
15759                     else
15760                       List.iter
15761                         (function
15762                          | Bro (n, xs) ->
15763                              (fprintf ppf "@ @[<hv2>- %a" print_symbol n;
15764                               (match xs with
15765                                | [] -> ()
15766                                | [ _ ] ->
15767                                    (try
15768                                       print_children ppf (get_children [] xs)
15769                                     with
15770                                     | Exit ->
15771                                         fprintf ppf ":%a" print_brothers xs)
15772                                | _ -> fprintf ppf ":%a" print_brothers xs);
15773                               fprintf ppf "@]"))
15774                         brothers
15775                   and print_children ppf =
15776                     List.iter (fprintf ppf ";@ %a" print_symbol)
15777                   and get_children acc =
15778                     function
15779                     | [] -> List.rev acc
15780                     | [ Bro (n, x) ] -> get_children (n :: acc) x
15781                     | _ -> raise Exit
15782                   in print_brothers ppf (get_brothers [] tree)
15783                 and print_symbol ppf =
15784                   function
15785                   | Smeta (n, sl, _) -> print_meta ppf n sl
15786                   | Slist0 s -> fprintf ppf "LIST0 %a" print_symbol1 s
15787                   | Slist0sep (s, t) ->
15788                       fprintf ppf "LIST0 %a SEP %a" print_symbol1 s
15789                         print_symbol1 t
15790                   | Slist1 s -> fprintf ppf "LIST1 %a" print_symbol1 s
15791                   | Slist1sep (s, t) ->
15792                       fprintf ppf "LIST1 %a SEP %a" print_symbol1 s
15793                         print_symbol1 t
15794                   | Sopt s -> fprintf ppf "OPT %a" print_symbol1 s
15795                   | Snterml (e, l) -> fprintf ppf "%s@ LEVEL@ %S" e.ename l
15796                   | (Snterm _ | Snext | Sself | Stree _ | Stoken _ |
15797                        Skeyword _
15798                      as s) -> print_symbol1 ppf s
15799                 and print_meta ppf n sl =
15800                   let rec loop i =
15801                     function
15802                     | [] -> ()
15803                     | s :: sl ->
15804                         let j =
15805                           (try String.index_from n i ' '
15806                            with | Not_found -> String.length n)
15807                         in
15808                           (fprintf ppf "%s %a" (String.sub n i (j - i))
15809                              print_symbol1 s;
15810                            if sl = []
15811                            then ()
15812                            else
15813                              (fprintf ppf " ";
15814                               loop (min (j + 1) (String.length n)) sl))
15815                   in loop 0 sl
15816                 and print_symbol1 ppf =
15817                   function
15818                   | Snterm e -> pp_print_string ppf e.ename
15819                   | Sself -> pp_print_string ppf "SELF"
15820                   | Snext -> pp_print_string ppf "NEXT"
15821                   | Stoken ((_, descr)) -> pp_print_string ppf descr
15822                   | Skeyword s -> fprintf ppf "%S" s
15823                   | Stree t -> print_tree ppf t
15824                   | (Smeta (_, _, _) | Snterml (_, _) | Slist0 _ |
15825                        Slist0sep (_, _) | Slist1 _ | Slist1sep (_, _) |
15826                        Sopt _
15827                      as s) -> fprintf ppf "(%a)" print_symbol s
15828                 and print_rule ppf symbols =
15829                   (fprintf ppf "@[<hov 0>";
15830                    let _ =
15831                      List.fold_left
15832                        (fun sep symbol ->
15833                           (fprintf ppf "%t%a" sep print_symbol symbol;
15834                            fun ppf -> fprintf ppf ";@ "))
15835                        (fun _ -> ()) symbols
15836                    in fprintf ppf "@]")
15837                 and print_level ppf pp_print_space rules =
15838                   (fprintf ppf "@[<hov 0>[ ";
15839                    let _ =
15840                      List.fold_left
15841                        (fun sep rule ->
15842                           (fprintf ppf "%t%a" sep print_rule rule;
15843                            fun ppf -> fprintf ppf "%a| " pp_print_space ()))
15844                        (fun _ -> ()) rules
15845                    in fprintf ppf " ]@]")
15846                   
15847                 let levels ppf elev =
15848                   let _ =
15849                     List.fold_left
15850                       (fun sep lev ->
15851                          (fprintf ppf "%t@[<v2>" sep;
15852                           (match lev.lname with
15853                            | Some n -> fprintf ppf "%S@;<1 2>" n
15854                            | None -> ());
15855                           (match lev.assoc with
15856                            | LeftA -> fprintf ppf "LEFTA"
15857                            | RightA -> fprintf ppf "RIGHTA"
15858                            | NonA -> fprintf ppf "NONA");
15859                           fprintf ppf "@]@;<1 2>";
15860                           fprintf ppf "@[<v2>suffix:@ ";
15861                           print_tree ppf lev.lsuffix;
15862                           fprintf ppf "@]@ @[<v2>prefix:@ ";
15863                           print_tree ppf lev.lprefix;
15864                           fprintf ppf "@]";
15865                           fun ppf -> fprintf ppf "@,| "))
15866                       (fun _ -> ()) elev
15867                   in ()
15868                   
15869                 let entry ppf e =
15870                   (fprintf ppf "@[<v 0>%s: [ " e.ename;
15871                    (match e.edesc with
15872                     | Dlevels elev -> levels ppf elev
15873                     | Dparser _ -> fprintf ppf "<parser>");
15874                    fprintf ppf " ]@]")
15875                   
15876               end
15877               
15878           end
15879           
15880         module Failed =
15881           struct
15882             module Make (Structure : Structure.S) =
15883               struct
15884                 module Tools = Tools.Make(Structure)
15885                   
15886                 module Search = Search.Make(Structure)
15887                   
15888                 module Print = Print.Make(Structure)
15889                   
15890                 open Structure
15891                   
15892                 open Format
15893                   
15894                 let rec name_of_symbol entry =
15895                   function
15896                   | Snterm e -> "[" ^ (e.ename ^ "]")
15897                   | Snterml (e, l) ->
15898                       "[" ^ (e.ename ^ (" level " ^ (l ^ "]")))
15899                   | Sself | Snext -> "[" ^ (entry.ename ^ "]")
15900                   | Stoken ((_, descr)) -> descr
15901                   | Skeyword kwd -> "\"" ^ (kwd ^ "\"")
15902                   | _ -> "???"
15903                   
15904                 let rec name_of_symbol_failed entry =
15905                   function
15906                   | Slist0 s -> name_of_symbol_failed entry s
15907                   | Slist0sep (s, _) -> name_of_symbol_failed entry s
15908                   | Slist1 s -> name_of_symbol_failed entry s
15909                   | Slist1sep (s, _) -> name_of_symbol_failed entry s
15910                   | Sopt s -> name_of_symbol_failed entry s
15911                   | Stree t -> name_of_tree_failed entry t
15912                   | s -> name_of_symbol entry s
15913                 and name_of_tree_failed entry =
15914                   function
15915                   | Node { node = s; brother = bro; son = son } ->
15916                       let tokl =
15917                         (match s with
15918                          | Stoken _ | Skeyword _ ->
15919                              Tools.get_token_list entry [] s son
15920                          | _ -> None)
15921                       in
15922                         (match tokl with
15923                          | None ->
15924                              let txt = name_of_symbol_failed entry s in
15925                              let txt =
15926                                (match (s, son) with
15927                                 | (Sopt _, Node _) ->
15928                                     txt ^
15929                                       (" or " ^
15930                                          (name_of_tree_failed entry son))
15931                                 | _ -> txt) in
15932                              let txt =
15933                                (match bro with
15934                                 | DeadEnd | LocAct (_, _) -> txt
15935                                 | Node _ ->
15936                                     txt ^
15937                                       (" or " ^
15938                                          (name_of_tree_failed entry bro)))
15939                              in txt
15940                          | Some ((tokl, _, _)) ->
15941                              List.fold_left
15942                                (fun s tok ->
15943                                   (if s = "" then "" else s ^ " then ") ^
15944                                     (match tok with
15945                                      | Stoken ((_, descr)) -> descr
15946                                      | Skeyword kwd -> kwd
15947                                      | _ -> assert false))
15948                                "" tokl)
15949                   | DeadEnd | LocAct (_, _) -> "???"
15950                   
15951                 let magic _s x = Obj.magic x
15952                   
15953                 let tree_failed entry prev_symb_result prev_symb tree =
15954                   let txt = name_of_tree_failed entry tree in
15955                   let txt =
15956                     match prev_symb with
15957                     | Slist0 s ->
15958                         let txt1 = name_of_symbol_failed entry s
15959                         in txt1 ^ (" or " ^ (txt ^ " expected"))
15960                     | Slist1 s ->
15961                         let txt1 = name_of_symbol_failed entry s
15962                         in txt1 ^ (" or " ^ (txt ^ " expected"))
15963                     | Slist0sep (s, sep) ->
15964                         (match magic "tree_failed: 'a -> list 'b"
15965                                  prev_symb_result
15966                          with
15967                          | [] ->
15968                              let txt1 = name_of_symbol_failed entry s
15969                              in txt1 ^ (" or " ^ (txt ^ " expected"))
15970                          | _ ->
15971                              let txt1 = name_of_symbol_failed entry sep
15972                              in txt1 ^ (" or " ^ (txt ^ " expected")))
15973                     | Slist1sep (s, sep) ->
15974                         (match magic "tree_failed: 'a -> list 'b"
15975                                  prev_symb_result
15976                          with
15977                          | [] ->
15978                              let txt1 = name_of_symbol_failed entry s
15979                              in txt1 ^ (" or " ^ (txt ^ " expected"))
15980                          | _ ->
15981                              let txt1 = name_of_symbol_failed entry sep
15982                              in txt1 ^ (" or " ^ (txt ^ " expected")))
15983                     | Sopt _ | Stree _ -> txt ^ " expected"
15984                     | _ ->
15985                         txt ^
15986                           (" expected after " ^
15987                              (name_of_symbol entry prev_symb))
15988                   in
15989                     (if !(entry.egram.error_verbose)
15990                      then
15991                        (let tree =
15992                           Search.tree_in_entry prev_symb tree entry.edesc in
15993                         let ppf = err_formatter
15994                         in
15995                           (fprintf ppf "@[<v 0>@,";
15996                            fprintf ppf "----------------------------------@,";
15997                            fprintf ppf
15998                              "Parse error in entry [%s], rule:@;<0 2>"
15999                              entry.ename;
16000                            fprintf ppf "@[";
16001                            Print.print_level ppf pp_force_newline
16002                              (Print.flatten_tree tree);
16003                            fprintf ppf "@]@,";
16004                            fprintf ppf "----------------------------------@,";
16005                            fprintf ppf "@]@."))
16006                      else ();
16007                      txt ^ (" (in [" ^ (entry.ename ^ "])")))
16008                   
16009                 let symb_failed entry prev_symb_result prev_symb symb =
16010                   let tree =
16011                     Node { node = symb; brother = DeadEnd; son = DeadEnd; }
16012                   in tree_failed entry prev_symb_result prev_symb tree
16013                   
16014                 let symb_failed_txt e s1 s2 = symb_failed e 0 s1 s2
16015                   
16016               end
16017               
16018           end
16019           
16020         module Parser =
16021           struct
16022             module Make (Structure : Structure.S) =
16023               struct
16024                 module Tools = Tools.Make(Structure)
16025                   
16026                 module Failed = Failed.Make(Structure)
16027                   
16028                 module Print = Print.Make(Structure)
16029                   
16030                 open Structure
16031                   
16032                 open Sig.Grammar
16033                   
16034                 module Stream =
16035                   struct
16036                     include Stream
16037                       
16038                     let junk strm = Context.junk strm
16039                       
16040                     let count strm = Context.bp strm
16041                       
16042                   end
16043                   
16044                 let add_loc c bp parse_fun strm =
16045                   let x = parse_fun c strm in
16046                   let ep = Context.loc_ep c in
16047                   let loc = Loc.merge bp ep in (x, loc)
16048                   
16049                 let level_number entry lab =
16050                   let rec lookup levn =
16051                     function
16052                     | [] -> failwith ("unknown level " ^ lab)
16053                     | lev :: levs ->
16054                         if Tools.is_level_labelled lab lev
16055                         then levn
16056                         else lookup (succ levn) levs
16057                   in
16058                     match entry.edesc with
16059                     | Dlevels elev -> lookup 0 elev
16060                     | Dparser _ -> raise Not_found
16061                   
16062                 let strict_parsing = ref false
16063                   
16064                 let strict_parsing_warning = ref false
16065                   
16066                 let rec top_symb entry =
16067                   function
16068                   | Sself | Snext -> Snterm entry
16069                   | Snterml (e, _) -> Snterm e
16070                   | Slist1sep (s, sep) -> Slist1sep (top_symb entry s, sep)
16071                   | _ -> raise Stream.Failure
16072                   
16073                 let top_tree entry =
16074                   function
16075                   | Node { node = s; brother = bro; son = son } ->
16076                       Node
16077                         { node = top_symb entry s; brother = bro; son = son;
16078                         }
16079                   | LocAct (_, _) | DeadEnd -> raise Stream.Failure
16080                   
16081                 let entry_of_symb entry =
16082                   function
16083                   | Sself | Snext -> entry
16084                   | Snterm e -> e
16085                   | Snterml (e, _) -> e
16086                   | _ -> raise Stream.Failure
16087                   
16088                 let continue entry loc a s c son p1 (__strm : _ Stream.t) =
16089                   let a =
16090                     (entry_of_symb entry s).econtinue 0 loc a c __strm in
16091                   let act =
16092                     try p1 __strm
16093                     with
16094                     | Stream.Failure ->
16095                         raise
16096                           (Stream.Error (Failed.tree_failed entry a s son))
16097                   in Action.mk (fun _ -> Action.getf act a)
16098                   
16099                 let skip_if_empty c bp _ =
16100                   if (Context.loc_bp c) = bp
16101                   then Action.mk (fun _ -> raise Stream.Failure)
16102                   else raise Stream.Failure
16103                   
16104                 let do_recover parser_of_tree entry nlevn alevn loc a s c son
16105                                (__strm : _ Stream.t) =
16106                   try
16107                     parser_of_tree entry nlevn alevn (top_tree entry son) c
16108                       __strm
16109                   with
16110                   | Stream.Failure ->
16111                       (try skip_if_empty c loc __strm
16112                        with
16113                        | Stream.Failure ->
16114                            continue entry loc a s c son
16115                              (parser_of_tree entry nlevn alevn son c) __strm)
16116                   
16117                 let recover parser_of_tree entry nlevn alevn loc a s c son
16118                             strm =
16119                   if !strict_parsing
16120                   then
16121                     raise (Stream.Error (Failed.tree_failed entry a s son))
16122                   else
16123                     (let _ =
16124                        if !strict_parsing_warning
16125                        then
16126                          (let msg = Failed.tree_failed entry a s son
16127                           in
16128                             (Format.eprintf
16129                                "Warning: trying to recover from syntax error";
16130                              if entry.ename <> ""
16131                              then Format.eprintf " in [%s]" entry.ename
16132                              else ();
16133                              Format.eprintf "\n%s%a@." msg Loc.print loc))
16134                        else ()
16135                      in
16136                        do_recover parser_of_tree entry nlevn alevn loc a s c
16137                          son strm)
16138                   
16139                 let rec parser_of_tree entry nlevn alevn =
16140                   function
16141                   | DeadEnd ->
16142                       (fun _ (__strm : _ Stream.t) -> raise Stream.Failure)
16143                   | LocAct (act, _) -> (fun _ (__strm : _ Stream.t) -> act)
16144                   | Node
16145                       {
16146                         node = Sself;
16147                         son = LocAct (act, _);
16148                         brother = DeadEnd
16149                       } ->
16150                       (fun c (__strm : _ Stream.t) ->
16151                          let a = entry.estart alevn c __strm
16152                          in Action.getf act a)
16153                   | Node { node = Sself; son = LocAct (act, _); brother = bro
16154                       } ->
16155                       let p2 = parser_of_tree entry nlevn alevn bro
16156                       in
16157                         (fun c (__strm : _ Stream.t) ->
16158                            match try Some (entry.estart alevn c __strm)
16159                                  with | Stream.Failure -> None
16160                            with
16161                            | Some a -> Action.getf act a
16162                            | _ -> p2 c __strm)
16163                   | Node { node = s; son = son; brother = DeadEnd } ->
16164                       let tokl =
16165                         (match s with
16166                          | Stoken _ | Skeyword _ ->
16167                              Tools.get_token_list entry [] s son
16168                          | _ -> None)
16169                       in
16170                         (match tokl with
16171                          | None ->
16172                              let ps = parser_of_symbol entry nlevn s in
16173                              let p1 = parser_of_tree entry nlevn alevn son in
16174                              let p1 = parser_cont p1 entry nlevn alevn s son
16175                              in
16176                                (fun c (__strm : _ Stream.t) ->
16177                                   let bp = Stream.count __strm in
16178                                   let a = ps c __strm in
16179                                   let act =
16180                                     try p1 c bp a __strm
16181                                     with
16182                                     | Stream.Failure ->
16183                                         raise (Stream.Error "")
16184                                   in Action.getf act a)
16185                          | Some ((tokl, last_tok, son)) ->
16186                              let p1 = parser_of_tree entry nlevn alevn son in
16187                              let p1 =
16188                                parser_cont p1 entry nlevn alevn last_tok son
16189                              in parser_of_token_list p1 tokl)
16190                   | Node { node = s; son = son; brother = bro } ->
16191                       let tokl =
16192                         (match s with
16193                          | Stoken _ | Skeyword _ ->
16194                              Tools.get_token_list entry [] s son
16195                          | _ -> None)
16196                       in
16197                         (match tokl with
16198                          | None ->
16199                              let ps = parser_of_symbol entry nlevn s in
16200                              let p1 = parser_of_tree entry nlevn alevn son in
16201                              let p1 =
16202                                parser_cont p1 entry nlevn alevn s son in
16203                              let p2 = parser_of_tree entry nlevn alevn bro
16204                              in
16205                                (fun c (__strm : _ Stream.t) ->
16206                                   let bp = Stream.count __strm
16207                                   in
16208                                     match try Some (ps c __strm)
16209                                           with | Stream.Failure -> None
16210                                     with
16211                                     | Some a ->
16212                                         let act =
16213                                           (try p1 c bp a __strm
16214                                            with
16215                                            | Stream.Failure ->
16216                                                raise (Stream.Error ""))
16217                                         in Action.getf act a
16218                                     | _ -> p2 c __strm)
16219                          | Some ((tokl, last_tok, son)) ->
16220                              let p1 = parser_of_tree entry nlevn alevn son in
16221                              let p1 =
16222                                parser_cont p1 entry nlevn alevn last_tok son in
16223                              let p1 = parser_of_token_list p1 tokl in
16224                              let p2 = parser_of_tree entry nlevn alevn bro
16225                              in
16226                                (fun c (__strm : _ Stream.t) ->
16227                                   try p1 c __strm
16228                                   with | Stream.Failure -> p2 c __strm))
16229                 and
16230                   parser_cont p1 entry nlevn alevn s son c loc a
16231                               (__strm : _ Stream.t) =
16232                   try p1 c __strm
16233                   with
16234                   | Stream.Failure ->
16235                       (try
16236                          recover parser_of_tree entry nlevn alevn loc a s c
16237                            son __strm
16238                        with
16239                        | Stream.Failure ->
16240                            raise
16241                              (Stream.Error (Failed.tree_failed entry a s son)))
16242                 and parser_of_token_list p1 tokl =
16243                   let rec loop n =
16244                     function
16245                     | Stoken ((tematch, _)) :: tokl ->
16246                         (match tokl with
16247                          | [] ->
16248                              let ps c _ =
16249                                (match Context.peek_nth c n with
16250                                 | Some ((tok, _)) when tematch tok ->
16251                                     (Context.njunk c n; Action.mk tok)
16252                                 | _ -> raise Stream.Failure)
16253                              in
16254                                (fun c (__strm : _ Stream.t) ->
16255                                   let bp = Stream.count __strm in
16256                                   let a = ps c __strm in
16257                                   let act =
16258                                     try p1 c bp a __strm
16259                                     with
16260                                     | Stream.Failure ->
16261                                         raise (Stream.Error "")
16262                                   in Action.getf act a)
16263                          | _ ->
16264                              let ps c _ =
16265                                (match Context.peek_nth c n with
16266                                 | Some ((tok, _)) when tematch tok -> tok
16267                                 | _ -> raise Stream.Failure) in
16268                              let p1 = loop (n + 1) tokl
16269                              in
16270                                (fun c (__strm : _ Stream.t) ->
16271                                   let tok = ps c __strm in
16272                                   let s = __strm in
16273                                   let act = p1 c s in Action.getf act tok))
16274                     | Skeyword kwd :: tokl ->
16275                         (match tokl with
16276                          | [] ->
16277                              let ps c _ =
16278                                (match Context.peek_nth c n with
16279                                 | Some ((tok, _)) when
16280                                     Token.match_keyword kwd tok ->
16281                                     (Context.njunk c n; Action.mk tok)
16282                                 | _ -> raise Stream.Failure)
16283                              in
16284                                (fun c (__strm : _ Stream.t) ->
16285                                   let bp = Stream.count __strm in
16286                                   let a = ps c __strm in
16287                                   let act =
16288                                     try p1 c bp a __strm
16289                                     with
16290                                     | Stream.Failure ->
16291                                         raise (Stream.Error "")
16292                                   in Action.getf act a)
16293                          | _ ->
16294                              let ps c _ =
16295                                (match Context.peek_nth c n with
16296                                 | Some ((tok, _)) when
16297                                     Token.match_keyword kwd tok -> tok
16298                                 | _ -> raise Stream.Failure) in
16299                              let p1 = loop (n + 1) tokl
16300                              in
16301                                (fun c (__strm : _ Stream.t) ->
16302                                   let tok = ps c __strm in
16303                                   let s = __strm in
16304                                   let act = p1 c s in Action.getf act tok))
16305                     | _ -> invalid_arg "parser_of_token_list"
16306                   in loop 1 tokl
16307                 and parser_of_symbol entry nlevn =
16308                   function
16309                   | Smeta (_, symbl, act) ->
16310                       let act = Obj.magic act entry symbl in
16311                       let pl = List.map (parser_of_symbol entry nlevn) symbl
16312                       in
16313                         (fun c ->
16314                            Obj.magic
16315                              (List.fold_left
16316                                 (fun act p -> Obj.magic act (p c)) act pl))
16317                   | Slist0 s ->
16318                       let ps = parser_of_symbol entry nlevn s in
16319                       let rec loop c al (__strm : _ Stream.t) =
16320                         (match try Some (ps c __strm)
16321                                with | Stream.Failure -> None
16322                          with
16323                          | Some a -> loop c (a :: al) __strm
16324                          | _ -> al)
16325                       in
16326                         (fun c (__strm : _ Stream.t) ->
16327                            let a = loop c [] __strm in Action.mk (List.rev a))
16328                   | Slist0sep (symb, sep) ->
16329                       let ps = parser_of_symbol entry nlevn symb in
16330                       let pt = parser_of_symbol entry nlevn sep in
16331                       let rec kont c al (__strm : _ Stream.t) =
16332                         (match try Some (pt c __strm)
16333                                with | Stream.Failure -> None
16334                          with
16335                          | Some v ->
16336                              let a =
16337                                (try ps c __strm
16338                                 with
16339                                 | Stream.Failure ->
16340                                     raise
16341                                       (Stream.Error
16342                                          (Failed.symb_failed entry v sep symb)))
16343                              in kont c (a :: al) __strm
16344                          | _ -> al)
16345                       in
16346                         (fun c (__strm : _ Stream.t) ->
16347                            match try Some (ps c __strm)
16348                                  with | Stream.Failure -> None
16349                            with
16350                            | Some a ->
16351                                let s = __strm
16352                                in Action.mk (List.rev (kont c [ a ] s))
16353                            | _ -> Action.mk [])
16354                   | Slist1 s ->
16355                       let ps = parser_of_symbol entry nlevn s in
16356                       let rec loop c al (__strm : _ Stream.t) =
16357                         (match try Some (ps c __strm)
16358                                with | Stream.Failure -> None
16359                          with
16360                          | Some a -> loop c (a :: al) __strm
16361                          | _ -> al)
16362                       in
16363                         (fun c (__strm : _ Stream.t) ->
16364                            let a = ps c __strm in
16365                            let s = __strm
16366                            in Action.mk (List.rev (loop c [ a ] s)))
16367                   | Slist1sep (symb, sep) ->
16368                       let ps = parser_of_symbol entry nlevn symb in
16369                       let pt = parser_of_symbol entry nlevn sep in
16370                       let rec kont c al (__strm : _ Stream.t) =
16371                         (match try Some (pt c __strm)
16372                                with | Stream.Failure -> None
16373                          with
16374                          | Some v ->
16375                              let a =
16376                                (try ps c __strm
16377                                 with
16378                                 | Stream.Failure ->
16379                                     (try parse_top_symb' entry symb c __strm
16380                                      with
16381                                      | Stream.Failure ->
16382                                          raise
16383                                            (Stream.Error
16384                                               (Failed.symb_failed entry v sep
16385                                                  symb))))
16386                              in kont c (a :: al) __strm
16387                          | _ -> al)
16388                       in
16389                         (fun c (__strm : _ Stream.t) ->
16390                            let a = ps c __strm in
16391                            let s = __strm
16392                            in Action.mk (List.rev (kont c [ a ] s)))
16393                   | Sopt s ->
16394                       let ps = parser_of_symbol entry nlevn s
16395                       in
16396                         (fun c (__strm : _ Stream.t) ->
16397                            match try Some (ps c __strm)
16398                                  with | Stream.Failure -> None
16399                            with
16400                            | Some a -> Action.mk (Some a)
16401                            | _ -> Action.mk None)
16402                   | Stree t ->
16403                       let pt = parser_of_tree entry 1 0 t
16404                       in
16405                         (fun c (__strm : _ Stream.t) ->
16406                            let bp = Stream.count __strm in
16407                            let (act, loc) = add_loc c bp pt __strm
16408                            in Action.getf act loc)
16409                   | Snterm e ->
16410                       (fun c (__strm : _ Stream.t) -> e.estart 0 c __strm)
16411                   | Snterml (e, l) ->
16412                       (fun c (__strm : _ Stream.t) ->
16413                          e.estart (level_number e l) c __strm)
16414                   | Sself ->
16415                       (fun c (__strm : _ Stream.t) -> entry.estart 0 c __strm)
16416                   | Snext ->
16417                       (fun c (__strm : _ Stream.t) ->
16418                          entry.estart nlevn c __strm)
16419                   | Skeyword kwd ->
16420                       (fun _ (__strm : _ Stream.t) ->
16421                          match Stream.peek __strm with
16422                          | Some ((tok, _)) when Token.match_keyword kwd tok
16423                              -> (Stream.junk __strm; Action.mk tok)
16424                          | _ -> raise Stream.Failure)
16425                   | Stoken ((f, _)) ->
16426                       (fun _ (__strm : _ Stream.t) ->
16427                          match Stream.peek __strm with
16428                          | Some ((tok, _)) when f tok ->
16429                              (Stream.junk __strm; Action.mk tok)
16430                          | _ -> raise Stream.Failure)
16431                 and parse_top_symb' entry symb c =
16432                   parser_of_symbol entry 0 (top_symb entry symb) c
16433                 and parse_top_symb entry symb strm =
16434                   Context.call_with_ctx strm
16435                     (fun c -> parse_top_symb' entry symb c (Context.stream c))
16436                   
16437                 let rec start_parser_of_levels entry clevn =
16438                   function
16439                   | [] ->
16440                       (fun _ _ (__strm : _ Stream.t) -> raise Stream.Failure)
16441                   | lev :: levs ->
16442                       let p1 = start_parser_of_levels entry (succ clevn) levs
16443                       in
16444                         (match lev.lprefix with
16445                          | DeadEnd -> p1
16446                          | tree ->
16447                              let alevn =
16448                                (match lev.assoc with
16449                                 | LeftA | NonA -> succ clevn
16450                                 | RightA -> clevn) in
16451                              let p2 =
16452                                parser_of_tree entry (succ clevn) alevn tree
16453                              in
16454                                (match levs with
16455                                 | [] ->
16456                                     (fun levn c (__strm : _ Stream.t) ->
16457                                        let bp = Stream.count __strm in
16458                                        let (act, loc) =
16459                                          add_loc c bp p2 __strm in
16460                                        let strm = __strm in
16461                                        let a = Action.getf act loc
16462                                        in entry.econtinue levn loc a c strm)
16463                                 | _ ->
16464                                     (fun levn c strm ->
16465                                        if levn > clevn
16466                                        then p1 levn c strm
16467                                        else
16468                                          (let (__strm : _ Stream.t) = strm in
16469                                           let bp = Stream.count __strm
16470                                           in
16471                                             match try
16472                                                     Some
16473                                                       (add_loc c bp p2 __strm)
16474                                                   with
16475                                                   | Stream.Failure -> None
16476                                             with
16477                                             | Some ((act, loc)) ->
16478                                                 let a = Action.getf act loc
16479                                                 in
16480                                                   entry.econtinue levn loc a
16481                                                     c strm
16482                                             | _ -> p1 levn c __strm))))
16483                   
16484                 let start_parser_of_entry entry =
16485                   match entry.edesc with
16486                   | Dlevels [] -> Tools.empty_entry entry.ename
16487                   | Dlevels elev -> start_parser_of_levels entry 0 elev
16488                   | Dparser p -> (fun _ _ strm -> p strm)
16489                   
16490                 let rec continue_parser_of_levels entry clevn =
16491                   function
16492                   | [] ->
16493                       (fun _ _ _ _ (__strm : _ Stream.t) ->
16494                          raise Stream.Failure)
16495                   | lev :: levs ->
16496                       let p1 =
16497                         continue_parser_of_levels entry (succ clevn) levs
16498                       in
16499                         (match lev.lsuffix with
16500                          | DeadEnd -> p1
16501                          | tree ->
16502                              let alevn =
16503                                (match lev.assoc with
16504                                 | LeftA | NonA -> succ clevn
16505                                 | RightA -> clevn) in
16506                              let p2 =
16507                                parser_of_tree entry (succ clevn) alevn tree
16508                              in
16509                                (fun c levn bp a strm ->
16510                                   if levn > clevn
16511                                   then p1 c levn bp a strm
16512                                   else
16513                                     (let (__strm : _ Stream.t) = strm
16514                                      in
16515                                        try p1 c levn bp a __strm
16516                                        with
16517                                        | Stream.Failure ->
16518                                            let (act, loc) =
16519                                              add_loc c bp p2 __strm in
16520                                            let a = Action.getf2 act a loc
16521                                            in
16522                                              entry.econtinue levn loc a c
16523                                                strm)))
16524                   
16525                 let continue_parser_of_entry entry =
16526                   match entry.edesc with
16527                   | Dlevels elev ->
16528                       let p = continue_parser_of_levels entry 0 elev
16529                       in
16530                         (fun levn bp a c (__strm : _ Stream.t) ->
16531                            try p c levn bp a __strm
16532                            with | Stream.Failure -> a)
16533                   | Dparser _ ->
16534                       (fun _ _ _ _ (__strm : _ Stream.t) ->
16535                          raise Stream.Failure)
16536                   
16537               end
16538               
16539           end
16540           
16541         module Insert =
16542           struct
16543             module Make (Structure : Structure.S) =
16544               struct
16545                 module Tools = Tools.Make(Structure)
16546                   
16547                 module Parser = Parser.Make(Structure)
16548                   
16549                 open Structure
16550                   
16551                 open Format
16552                   
16553                 open Sig.Grammar
16554                   
16555                 let is_before s1 s2 =
16556                   match (s1, s2) with
16557                   | ((Skeyword _ | Stoken _), (Skeyword _ | Stoken _)) ->
16558                       false
16559                   | ((Skeyword _ | Stoken _), _) -> true
16560                   | _ -> false
16561                   
16562                 let rec derive_eps =
16563                   function
16564                   | Slist0 _ -> true
16565                   | Slist0sep (_, _) -> true
16566                   | Sopt _ -> true
16567                   | Stree t -> tree_derive_eps t
16568                   | Smeta (_, _, _) | Slist1 _ | Slist1sep (_, _) | Snterm _
16569                       | Snterml (_, _) | Snext | Sself | Stoken _ |
16570                       Skeyword _ -> false
16571                 and tree_derive_eps =
16572                   function
16573                   | LocAct (_, _) -> true
16574                   | Node { node = s; brother = bro; son = son } ->
16575                       ((derive_eps s) && (tree_derive_eps son)) ||
16576                         (tree_derive_eps bro)
16577                   | DeadEnd -> false
16578                   
16579                 let empty_lev lname assoc =
16580                   let assoc = match assoc with | Some a -> a | None -> LeftA
16581                   in
16582                     {
16583                       assoc = assoc;
16584                       lname = lname;
16585                       lsuffix = DeadEnd;
16586                       lprefix = DeadEnd;
16587                     }
16588                   
16589                 let change_lev entry lev n lname assoc =
16590                   let a =
16591                     match assoc with
16592                     | None -> lev.assoc
16593                     | Some a ->
16594                         (if
16595                            (a <> lev.assoc) && !(entry.egram.warning_verbose)
16596                          then
16597                            (eprintf
16598                               "<W> Changing associativity of level \"%s\"\n"
16599                               n;
16600                             flush stderr)
16601                          else ();
16602                          a)
16603                   in
16604                     ((match lname with
16605                       | Some n ->
16606                           if
16607                             (lname <> lev.lname) &&
16608                               !(entry.egram.warning_verbose)
16609                           then
16610                             (eprintf "<W> Level label \"%s\" ignored\n" n;
16611                              flush stderr)
16612                           else ()
16613                       | None -> ());
16614                      {
16615                        assoc = a;
16616                        lname = lev.lname;
16617                        lsuffix = lev.lsuffix;
16618                        lprefix = lev.lprefix;
16619                      })
16620                   
16621                 let change_to_self entry =
16622                   function | Snterm e when e == entry -> Sself | x -> x
16623                   
16624                 let get_level entry position levs =
16625                   match position with
16626                   | Some First -> ([], empty_lev, levs)
16627                   | Some Last -> (levs, empty_lev, [])
16628                   | Some (Level n) ->
16629                       let rec get =
16630                         (function
16631                          | [] ->
16632                              (eprintf
16633                                 "No level labelled \"%s\" in entry \"%s\"\n"
16634                                 n entry.ename;
16635                               flush stderr;
16636                               failwith "Grammar.extend")
16637                          | lev :: levs ->
16638                              if Tools.is_level_labelled n lev
16639                              then ([], (change_lev entry lev n), levs)
16640                              else
16641                                (let (levs1, rlev, levs2) = get levs
16642                                 in ((lev :: levs1), rlev, levs2)))
16643                       in get levs
16644                   | Some (Before n) ->
16645                       let rec get =
16646                         (function
16647                          | [] ->
16648                              (eprintf
16649                                 "No level labelled \"%s\" in entry \"%s\"\n"
16650                                 n entry.ename;
16651                               flush stderr;
16652                               failwith "Grammar.extend")
16653                          | lev :: levs ->
16654                              if Tools.is_level_labelled n lev
16655                              then ([], empty_lev, (lev :: levs))
16656                              else
16657                                (let (levs1, rlev, levs2) = get levs
16658                                 in ((lev :: levs1), rlev, levs2)))
16659                       in get levs
16660                   | Some (After n) ->
16661                       let rec get =
16662                         (function
16663                          | [] ->
16664                              (eprintf
16665                                 "No level labelled \"%s\" in entry \"%s\"\n"
16666                                 n entry.ename;
16667                               flush stderr;
16668                               failwith "Grammar.extend")
16669                          | lev :: levs ->
16670                              if Tools.is_level_labelled n lev
16671                              then ([ lev ], empty_lev, levs)
16672                              else
16673                                (let (levs1, rlev, levs2) = get levs
16674                                 in ((lev :: levs1), rlev, levs2)))
16675                       in get levs
16676                   | None ->
16677                       (match levs with
16678                        | lev :: levs ->
16679                            ([], (change_lev entry lev "<top>"), levs)
16680                        | [] -> ([], empty_lev, []))
16681                   
16682                 let rec check_gram entry =
16683                   function
16684                   | Snterm e ->
16685                       if ( != ) e.egram entry.egram
16686                       then
16687                         (eprintf
16688                            "\
16689   Error: entries \"%s\" and \"%s\" do not belong to the same grammar.\n"
16690                            entry.ename e.ename;
16691                          flush stderr;
16692                          failwith "Grammar.extend error")
16693                       else ()
16694                   | Snterml (e, _) ->
16695                       if ( != ) e.egram entry.egram
16696                       then
16697                         (eprintf
16698                            "\
16699   Error: entries \"%s\" and \"%s\" do not belong to the same grammar.\n"
16700                            entry.ename e.ename;
16701                          flush stderr;
16702                          failwith "Grammar.extend error")
16703                       else ()
16704                   | Smeta (_, sl, _) -> List.iter (check_gram entry) sl
16705                   | Slist0sep (s, t) ->
16706                       (check_gram entry t; check_gram entry s)
16707                   | Slist1sep (s, t) ->
16708                       (check_gram entry t; check_gram entry s)
16709                   | Slist0 s -> check_gram entry s
16710                   | Slist1 s -> check_gram entry s
16711                   | Sopt s -> check_gram entry s
16712                   | Stree t -> tree_check_gram entry t
16713                   | Snext | Sself | Stoken _ | Skeyword _ -> ()
16714                 and tree_check_gram entry =
16715                   function
16716                   | Node { node = n; brother = bro; son = son } ->
16717                       (check_gram entry n;
16718                        tree_check_gram entry bro;
16719                        tree_check_gram entry son)
16720                   | LocAct (_, _) | DeadEnd -> ()
16721                   
16722                 let get_initial =
16723                   function
16724                   | Sself :: symbols -> (true, symbols)
16725                   | symbols -> (false, symbols)
16726                   
16727                 let insert_tokens gram symbols =
16728                   let rec insert =
16729                     function
16730                     | Smeta (_, sl, _) -> List.iter insert sl
16731                     | Slist0 s -> insert s
16732                     | Slist1 s -> insert s
16733                     | Slist0sep (s, t) -> (insert s; insert t)
16734                     | Slist1sep (s, t) -> (insert s; insert t)
16735                     | Sopt s -> insert s
16736                     | Stree t -> tinsert t
16737                     | Skeyword kwd -> using gram kwd
16738                     | Snterm _ | Snterml (_, _) | Snext | Sself | Stoken _ ->
16739                         ()
16740                   and tinsert =
16741                     function
16742                     | Node { node = s; brother = bro; son = son } ->
16743                         (insert s; tinsert bro; tinsert son)
16744                     | LocAct (_, _) | DeadEnd -> ()
16745                   in List.iter insert symbols
16746                   
16747                 let insert_tree entry gsymbols action tree =
16748                   let rec insert symbols tree =
16749                     match symbols with
16750                     | s :: sl -> insert_in_tree s sl tree
16751                     | [] ->
16752                         (match tree with
16753                          | Node { node = s; son = son; brother = bro } ->
16754                              Node
16755                                {
16756                                  node = s;
16757                                  son = son;
16758                                  brother = insert [] bro;
16759                                }
16760                          | LocAct (old_action, action_list) ->
16761                              let () =
16762                                if !(entry.egram.warning_verbose)
16763                                then
16764                                  eprintf
16765                                    "<W> Grammar extension: in [%s] some rule has been masked@."
16766                                    entry.ename
16767                                else ()
16768                              in LocAct (action, old_action :: action_list)
16769                          | DeadEnd -> LocAct (action, []))
16770                   and insert_in_tree s sl tree =
16771                     match try_insert s sl tree with
16772                     | Some t -> t
16773                     | None ->
16774                         Node
16775                           {
16776                             node = s;
16777                             son = insert sl DeadEnd;
16778                             brother = tree;
16779                           }
16780                   and try_insert s sl tree =
16781                     match tree with
16782                     | Node { node = s1; son = son; brother = bro } ->
16783                         if Tools.eq_symbol s s1
16784                         then
16785                           (let t =
16786                              Node
16787                                {
16788                                  node = s1;
16789                                  son = insert sl son;
16790                                  brother = bro;
16791                                }
16792                            in Some t)
16793                         else
16794                           if
16795                             (is_before s1 s) ||
16796                               ((derive_eps s) && (not (derive_eps s1)))
16797                           then
16798                             (let bro =
16799                                match try_insert s sl bro with
16800                                | Some bro -> bro
16801                                | None ->
16802                                    Node
16803                                      {
16804                                        node = s;
16805                                        son = insert sl DeadEnd;
16806                                        brother = bro;
16807                                      } in
16808                              let t =
16809                                Node { node = s1; son = son; brother = bro; }
16810                              in Some t)
16811                           else
16812                             (match try_insert s sl bro with
16813                              | Some bro ->
16814                                  let t =
16815                                    Node
16816                                      { node = s1; son = son; brother = bro; }
16817                                  in Some t
16818                              | None -> None)
16819                     | LocAct (_, _) | DeadEnd -> None
16820                   and insert_new =
16821                     function
16822                     | s :: sl ->
16823                         Node
16824                           { node = s; son = insert_new sl; brother = DeadEnd;
16825                           }
16826                     | [] -> LocAct (action, [])
16827                   in insert gsymbols tree
16828                   
16829                 let insert_level entry e1 symbols action slev =
16830                   match e1 with
16831                   | true ->
16832                       {
16833                         assoc = slev.assoc;
16834                         lname = slev.lname;
16835                         lsuffix =
16836                           insert_tree entry symbols action slev.lsuffix;
16837                         lprefix = slev.lprefix;
16838                       }
16839                   | false ->
16840                       {
16841                         assoc = slev.assoc;
16842                         lname = slev.lname;
16843                         lsuffix = slev.lsuffix;
16844                         lprefix =
16845                           insert_tree entry symbols action slev.lprefix;
16846                       }
16847                   
16848                 let levels_of_rules entry position rules =
16849                   let elev =
16850                     match entry.edesc with
16851                     | Dlevels elev -> elev
16852                     | Dparser _ ->
16853                         (eprintf "Error: entry not extensible: \"%s\"\n"
16854                            entry.ename;
16855                          flush stderr;
16856                          failwith "Grammar.extend")
16857                   in
16858                     if rules = []
16859                     then elev
16860                     else
16861                       (let (levs1, make_lev, levs2) =
16862                          get_level entry position elev in
16863                        let (levs, _) =
16864                          List.fold_left
16865                            (fun (levs, make_lev) (lname, assoc, level) ->
16866                               let lev = make_lev lname assoc in
16867                               let lev =
16868                                 List.fold_left
16869                                   (fun lev (symbols, action) ->
16870                                      let symbols =
16871                                        List.map (change_to_self entry)
16872                                          symbols
16873                                      in
16874                                        (List.iter (check_gram entry) symbols;
16875                                         let (e1, symbols) =
16876                                           get_initial symbols
16877                                         in
16878                                           (insert_tokens entry.egram symbols;
16879                                            insert_level entry e1 symbols
16880                                              action lev)))
16881                                   lev level
16882                               in ((lev :: levs), empty_lev))
16883                            ([], make_lev) rules
16884                        in levs1 @ ((List.rev levs) @ levs2))
16885                   
16886                 let extend entry (position, rules) =
16887                   let elev = levels_of_rules entry position rules
16888                   in
16889                     (entry.edesc <- Dlevels elev;
16890                      entry.estart <-
16891                        (fun lev c strm ->
16892                           let f = Parser.start_parser_of_entry entry
16893                           in (entry.estart <- f; f lev c strm));
16894                      entry.econtinue <-
16895                        fun lev bp a c strm ->
16896                          let f = Parser.continue_parser_of_entry entry
16897                          in (entry.econtinue <- f; f lev bp a c strm))
16898                   
16899               end
16900               
16901           end
16902           
16903         module Delete =
16904           struct
16905             module Make (Structure : Structure.S) =
16906               struct
16907                 module Tools = Tools.Make(Structure)
16908                   
16909                 module Parser = Parser.Make(Structure)
16910                   
16911                 open Structure
16912                   
16913                 let delete_rule_in_tree entry =
16914                   let rec delete_in_tree symbols tree =
16915                     match (symbols, tree) with
16916                     | (s :: sl, Node n) ->
16917                         if Tools.logically_eq_symbols entry s n.node
16918                         then delete_son sl n
16919                         else
16920                           (match delete_in_tree symbols n.brother with
16921                            | Some ((dsl, t)) ->
16922                                Some
16923                                  ((dsl,
16924                                    (Node
16925                                       {
16926                                         node = n.node;
16927                                         son = n.son;
16928                                         brother = t;
16929                                       })))
16930                            | None -> None)
16931                     | (_ :: _, _) -> None
16932                     | ([], Node n) ->
16933                         (match delete_in_tree [] n.brother with
16934                          | Some ((dsl, t)) ->
16935                              Some
16936                                ((dsl,
16937                                  (Node
16938                                     {
16939                                       node = n.node;
16940                                       son = n.son;
16941                                       brother = t;
16942                                     })))
16943                          | None -> None)
16944                     | ([], DeadEnd) -> None
16945                     | ([], LocAct (_, [])) -> Some (((Some []), DeadEnd))
16946                     | ([], LocAct (_, (action :: list))) ->
16947                         Some ((None, (LocAct (action, list))))
16948                   and delete_son sl n =
16949                     match delete_in_tree sl n.son with
16950                     | Some ((Some dsl, DeadEnd)) ->
16951                         Some (((Some (n.node :: dsl)), (n.brother)))
16952                     | Some ((Some dsl, t)) ->
16953                         let t =
16954                           Node
16955                             { node = n.node; son = t; brother = n.brother; }
16956                         in Some (((Some (n.node :: dsl)), t))
16957                     | Some ((None, t)) ->
16958                         let t =
16959                           Node
16960                             { node = n.node; son = t; brother = n.brother; }
16961                         in Some ((None, t))
16962                     | None -> None
16963                   in delete_in_tree
16964                   
16965                 let rec decr_keyw_use gram =
16966                   function
16967                   | Skeyword kwd -> removing gram kwd
16968                   | Smeta (_, sl, _) -> List.iter (decr_keyw_use gram) sl
16969                   | Slist0 s -> decr_keyw_use gram s
16970                   | Slist1 s -> decr_keyw_use gram s
16971                   | Slist0sep (s1, s2) ->
16972                       (decr_keyw_use gram s1; decr_keyw_use gram s2)
16973                   | Slist1sep (s1, s2) ->
16974                       (decr_keyw_use gram s1; decr_keyw_use gram s2)
16975                   | Sopt s -> decr_keyw_use gram s
16976                   | Stree t -> decr_keyw_use_in_tree gram t
16977                   | Sself | Snext | Snterm _ | Snterml (_, _) | Stoken _ ->
16978                       ()
16979                 and decr_keyw_use_in_tree gram =
16980                   function
16981                   | DeadEnd | LocAct (_, _) -> ()
16982                   | Node n ->
16983                       (decr_keyw_use gram n.node;
16984                        decr_keyw_use_in_tree gram n.son;
16985                        decr_keyw_use_in_tree gram n.brother)
16986                   
16987                 let rec delete_rule_in_suffix entry symbols =
16988                   function
16989                   | lev :: levs ->
16990                       (match delete_rule_in_tree entry symbols lev.lsuffix
16991                        with
16992                        | Some ((dsl, t)) ->
16993                            ((match dsl with
16994                              | Some dsl ->
16995                                  List.iter (decr_keyw_use entry.egram) dsl
16996                              | None -> ());
16997                             (match t with
16998                              | DeadEnd when lev.lprefix == DeadEnd -> levs
16999                              | _ ->
17000                                  let lev =
17001                                    {
17002                                      assoc = lev.assoc;
17003                                      lname = lev.lname;
17004                                      lsuffix = t;
17005                                      lprefix = lev.lprefix;
17006                                    }
17007                                  in lev :: levs))
17008                        | None ->
17009                            let levs =
17010                              delete_rule_in_suffix entry symbols levs
17011                            in lev :: levs)
17012                   | [] -> raise Not_found
17013                   
17014                 let rec delete_rule_in_prefix entry symbols =
17015                   function
17016                   | lev :: levs ->
17017                       (match delete_rule_in_tree entry symbols lev.lprefix
17018                        with
17019                        | Some ((dsl, t)) ->
17020                            ((match dsl with
17021                              | Some dsl ->
17022                                  List.iter (decr_keyw_use entry.egram) dsl
17023                              | None -> ());
17024                             (match t with
17025                              | DeadEnd when lev.lsuffix == DeadEnd -> levs
17026                              | _ ->
17027                                  let lev =
17028                                    {
17029                                      assoc = lev.assoc;
17030                                      lname = lev.lname;
17031                                      lsuffix = lev.lsuffix;
17032                                      lprefix = t;
17033                                    }
17034                                  in lev :: levs))
17035                        | None ->
17036                            let levs =
17037                              delete_rule_in_prefix entry symbols levs
17038                            in lev :: levs)
17039                   | [] -> raise Not_found
17040                   
17041                 let rec delete_rule_in_level_list entry symbols levs =
17042                   match symbols with
17043                   | Sself :: symbols ->
17044                       delete_rule_in_suffix entry symbols levs
17045                   | Snterm e :: symbols when e == entry ->
17046                       delete_rule_in_suffix entry symbols levs
17047                   | _ -> delete_rule_in_prefix entry symbols levs
17048                   
17049                 let delete_rule entry sl =
17050                   match entry.edesc with
17051                   | Dlevels levs ->
17052                       let levs = delete_rule_in_level_list entry sl levs
17053                       in
17054                         (entry.edesc <- Dlevels levs;
17055                          entry.estart <-
17056                            (fun lev c strm ->
17057                               let f = Parser.start_parser_of_entry entry
17058                               in (entry.estart <- f; f lev c strm));
17059                          entry.econtinue <-
17060                            (fun lev bp a c strm ->
17061                               let f = Parser.continue_parser_of_entry entry
17062                               in (entry.econtinue <- f; f lev bp a c strm)))
17063                   | Dparser _ -> ()
17064                   
17065               end
17066               
17067           end
17068           
17069         module Fold :
17070           sig
17071             module Make (Structure : Structure.S) :
17072               sig
17073                 open Structure
17074                   
17075                 val sfold0 : ('a -> 'b -> 'b) -> 'b -> (_, 'a, 'b) fold
17076                   
17077                 val sfold1 : ('a -> 'b -> 'b) -> 'b -> (_, 'a, 'b) fold
17078                   
17079                 val sfold0sep : ('a -> 'b -> 'b) -> 'b -> (_, 'a, 'b) foldsep
17080                   
17081               end
17082               
17083           end =
17084           struct
17085             module Make (Structure : Structure.S) =
17086               struct
17087                 open Structure
17088                   
17089                 open Format
17090                   
17091                 module Parse = Parser.Make(Structure)
17092                   
17093                 module Fail = Failed.Make(Structure)
17094                   
17095                 open Sig.Grammar
17096                   
17097                 module Stream =
17098                   struct
17099                     include Stream
17100                       
17101                     let junk strm = Context.junk strm
17102                       
17103                     let count strm = Context.bp strm
17104                       
17105                   end
17106                   
17107                 let sfold0 f e _entry _symbl psymb =
17108                   let rec fold accu (__strm : _ Stream.t) =
17109                     match try Some (psymb __strm)
17110                           with | Stream.Failure -> None
17111                     with
17112                     | Some a -> fold (f a accu) __strm
17113                     | _ -> accu
17114                   in fun (__strm : _ Stream.t) -> fold e __strm
17115                   
17116                 let sfold1 f e _entry _symbl psymb =
17117                   let rec fold accu (__strm : _ Stream.t) =
17118                     match try Some (psymb __strm)
17119                           with | Stream.Failure -> None
17120                     with
17121                     | Some a -> fold (f a accu) __strm
17122                     | _ -> accu
17123                   in
17124                     fun (__strm : _ Stream.t) ->
17125                       let a = psymb __strm
17126                       in
17127                         try fold (f a e) __strm
17128                         with | Stream.Failure -> raise (Stream.Error "")
17129                   
17130                 let sfold0sep f e entry symbl psymb psep =
17131                   let failed =
17132                     function
17133                     | [ symb; sep ] -> Fail.symb_failed_txt entry sep symb
17134                     | _ -> "failed" in
17135                   let rec kont accu (__strm : _ Stream.t) =
17136                     match try Some (psep __strm)
17137                           with | Stream.Failure -> None
17138                     with
17139                     | Some () ->
17140                         let a =
17141                           (try psymb __strm
17142                            with
17143                            | Stream.Failure ->
17144                                raise (Stream.Error (failed symbl)))
17145                         in kont (f a accu) __strm
17146                     | _ -> accu
17147                   in
17148                     fun (__strm : _ Stream.t) ->
17149                       match try Some (psymb __strm)
17150                             with | Stream.Failure -> None
17151                       with
17152                       | Some a -> kont (f a e) __strm
17153                       | _ -> e
17154                   
17155                 let sfold1sep f e entry symbl psymb psep =
17156                   let failed =
17157                     function
17158                     | [ symb; sep ] -> Fail.symb_failed_txt entry sep symb
17159                     | _ -> "failed" in
17160                   let parse_top =
17161                     function
17162                     | [ symb; _ ] -> Parse.parse_top_symb entry symb
17163                     | _ -> raise Stream.Failure in
17164                   let rec kont accu (__strm : _ Stream.t) =
17165                     match try Some (psep __strm)
17166                           with | Stream.Failure -> None
17167                     with
17168                     | Some () ->
17169                         let a =
17170                           (try
17171                              try psymb __strm
17172                              with
17173                              | Stream.Failure ->
17174                                  let a =
17175                                    (try parse_top symbl __strm
17176                                     with
17177                                     | Stream.Failure ->
17178                                         raise (Stream.Error (failed symbl)))
17179                                  in Obj.magic a
17180                            with | Stream.Failure -> raise (Stream.Error ""))
17181                         in kont (f a accu) __strm
17182                     | _ -> accu
17183                   in
17184                     fun (__strm : _ Stream.t) ->
17185                       let a = psymb __strm in kont (f a e) __strm
17186                   
17187               end
17188               
17189           end
17190           
17191         module Entry =
17192           struct
17193             module Make (Structure : Structure.S) =
17194               struct
17195                 module Dump = Print.MakeDump(Structure)
17196                   
17197                 module Print = Print.Make(Structure)
17198                   
17199                 module Tools = Tools.Make(Structure)
17200                   
17201                 open Format
17202                   
17203                 open Structure
17204                   
17205                 type 'a t = internal_entry
17206                 
17207                 let name e = e.ename
17208                   
17209                 let print ppf e = fprintf ppf "%a@\n" Print.entry e
17210                   
17211                 let dump ppf e = fprintf ppf "%a@\n" Dump.entry e
17212                   
17213                 let mk g n =
17214                   {
17215                     egram = g;
17216                     ename = n;
17217                     estart = Tools.empty_entry n;
17218                     econtinue =
17219                       (fun _ _ _ _ (__strm : _ Stream.t) ->
17220                          raise Stream.Failure);
17221                     edesc = Dlevels [];
17222                   }
17223                   
17224                 let action_parse entry ts : Action.t =
17225                   Context.call_with_ctx ts
17226                     (fun c ->
17227                        try entry.estart 0 c (Context.stream c)
17228                        with
17229                        | Stream.Failure ->
17230                            Loc.raise (Context.loc_ep c)
17231                              (Stream.Error
17232                                 ("illegal begin of " ^ entry.ename))
17233                        | (Loc.Exc_located (_, _) as exc) -> raise exc
17234                        | exc -> Loc.raise (Context.loc_ep c) exc)
17235                   
17236                 let lex entry loc cs = entry.egram.glexer loc cs
17237                   
17238                 let lex_string entry loc str =
17239                   lex entry loc (Stream.of_string str)
17240                   
17241                 let filter entry ts =
17242                   Token.Filter.filter (get_filter entry.egram) ts
17243                   
17244                 let parse_tokens_after_filter entry ts =
17245                   Action.get (action_parse entry ts)
17246                   
17247                 let parse_tokens_before_filter entry ts =
17248                   parse_tokens_after_filter entry (filter entry ts)
17249                   
17250                 let parse entry loc cs =
17251                   parse_tokens_before_filter entry (lex entry loc cs)
17252                   
17253                 let parse_string entry loc str =
17254                   parse_tokens_before_filter entry (lex_string entry loc str)
17255                   
17256                 let of_parser g n (p : (Token.t * Loc.t) Stream.t -> 'a) :
17257                   'a t =
17258                   {
17259                     egram = g;
17260                     ename = n;
17261                     estart = (fun _ _ ts -> Action.mk (p ts));
17262                     econtinue =
17263                       (fun _ _ _ _ (__strm : _ Stream.t) ->
17264                          raise Stream.Failure);
17265                     edesc = Dparser (fun ts -> Action.mk (p ts));
17266                   }
17267                   
17268                 let setup_parser e (p : (Token.t * Loc.t) Stream.t -> 'a) =
17269                   let f ts = Action.mk (p ts)
17270                   in
17271                     (e.estart <- (fun _ _ -> f);
17272                      e.econtinue <-
17273                        (fun _ _ _ _ (__strm : _ Stream.t) ->
17274                           raise Stream.Failure);
17275                      e.edesc <- Dparser f)
17276                   
17277                 let clear e =
17278                   (e.estart <-
17279                      (fun _ _ (__strm : _ Stream.t) -> raise Stream.Failure);
17280                    e.econtinue <-
17281                      (fun _ _ _ _ (__strm : _ Stream.t) ->
17282                         raise Stream.Failure);
17283                    e.edesc <- Dlevels [])
17284                   
17285                 let obj x = x
17286                   
17287               end
17288               
17289           end
17290           
17291         module Static =
17292           struct
17293             let uncurry f (x, y) = f x y
17294               
17295             let flip f x y = f y x
17296               
17297             module Make (Lexer : Sig.Lexer) :
17298               Sig.Grammar.Static with module Loc = Lexer.Loc
17299               and module Token = Lexer.Token =
17300               struct
17301                 module Structure = Structure.Make(Lexer)
17302                   
17303                 module Delete = Delete.Make(Structure)
17304                   
17305                 module Insert = Insert.Make(Structure)
17306                   
17307                 module Fold = Fold.Make(Structure)
17308                   
17309                 include Structure
17310                   
17311                 let gram =
17312                   let gkeywords = Hashtbl.create 301
17313                   in
17314                     {
17315                       gkeywords = gkeywords;
17316                       gfilter = Token.Filter.mk (Hashtbl.mem gkeywords);
17317                       glexer = Lexer.mk ();
17318                       warning_verbose = ref true;
17319                       error_verbose = Camlp4_config.verbose;
17320                     }
17321                   
17322                 module Entry =
17323                   struct
17324                     module E = Entry.Make(Structure)
17325                       
17326                     type 'a t = 'a E.t
17327                     
17328                     let mk = E.mk gram
17329                       
17330                     let of_parser name strm = E.of_parser gram name strm
17331                       
17332                     let setup_parser = E.setup_parser
17333                       
17334                     let name = E.name
17335                       
17336                     let print = E.print
17337                       
17338                     let clear = E.clear
17339                       
17340                     let dump = E.dump
17341                       
17342                     let obj x = x
17343                       
17344                   end
17345                   
17346                 let get_filter () = gram.gfilter
17347                   
17348                 let lex loc cs = gram.glexer loc cs
17349                   
17350                 let lex_string loc str = lex loc (Stream.of_string str)
17351                   
17352                 let filter ts = Token.Filter.filter gram.gfilter ts
17353                   
17354                 let parse_tokens_after_filter entry ts =
17355                   Entry.E.parse_tokens_after_filter entry ts
17356                   
17357                 let parse_tokens_before_filter entry ts =
17358                   parse_tokens_after_filter entry (filter ts)
17359                   
17360                 let parse entry loc cs =
17361                   parse_tokens_before_filter entry (lex loc cs)
17362                   
17363                 let parse_string entry loc str =
17364                   parse_tokens_before_filter entry (lex_string loc str)
17365                   
17366                 let delete_rule = Delete.delete_rule
17367                   
17368                 let srules e rl =
17369                   Stree
17370                     (List.fold_left (flip (uncurry (Insert.insert_tree e)))
17371                        DeadEnd rl)
17372                   
17373                 let sfold0 = Fold.sfold0
17374                   
17375                 let sfold1 = Fold.sfold1
17376                   
17377                 let sfold0sep = Fold.sfold0sep
17378                   
17379                 let extend = Insert.extend
17380                   
17381               end
17382               
17383           end
17384           
17385         module Dynamic =
17386           struct
17387             module Make (Lexer : Sig.Lexer) :
17388               Sig.Grammar.Dynamic with module Loc = Lexer.Loc
17389               and module Token = Lexer.Token =
17390               struct
17391                 module Structure = Structure.Make(Lexer)
17392                   
17393                 module Delete = Delete.Make(Structure)
17394                   
17395                 module Insert = Insert.Make(Structure)
17396                   
17397                 module Entry = Entry.Make(Structure)
17398                   
17399                 module Fold = Fold.Make(Structure)
17400                   
17401                 include Structure
17402                   
17403                 let mk () =
17404                   let gkeywords = Hashtbl.create 301
17405                   in
17406                     {
17407                       gkeywords = gkeywords;
17408                       gfilter = Token.Filter.mk (Hashtbl.mem gkeywords);
17409                       glexer = Lexer.mk ();
17410                       warning_verbose = ref true;
17411                       error_verbose = Camlp4_config.verbose;
17412                     }
17413                   
17414                 let get_filter g = g.gfilter
17415                   
17416                 let lex g loc cs = g.glexer loc cs
17417                   
17418                 let lex_string g loc str = lex g loc (Stream.of_string str)
17419                   
17420                 let filter g ts = Token.Filter.filter g.gfilter ts
17421                   
17422                 let parse_tokens_after_filter entry ts =
17423                   Entry.parse_tokens_after_filter entry ts
17424                   
17425                 let parse_tokens_before_filter entry ts =
17426                   parse_tokens_after_filter entry (filter entry.egram ts)
17427                   
17428                 let parse entry loc cs =
17429                   parse_tokens_before_filter entry (lex entry.egram loc cs)
17430                   
17431                 let parse_string entry loc str =
17432                   parse_tokens_before_filter entry
17433                     (lex_string entry.egram loc str)
17434                   
17435                 let delete_rule = Delete.delete_rule
17436                   
17437                 let srules e rl =
17438                   let t =
17439                     List.fold_left
17440                       (fun tree (symbols, action) ->
17441                          Insert.insert_tree e symbols action tree)
17442                       DeadEnd rl
17443                   in Stree t
17444                   
17445                 let sfold0 = Fold.sfold0
17446                   
17447                 let sfold1 = Fold.sfold1
17448                   
17449                 let sfold0sep = Fold.sfold0sep
17450                   
17451                 let extend = Insert.extend
17452                   
17453               end
17454               
17455           end
17456           
17457       end
17458       
17459   end
17460   
17461 module Printers =
17462   struct
17463     module DumpCamlp4Ast :
17464       sig
17465         module Id : Sig.Id
17466           
17467         module Make (Syntax : Sig.Syntax) : Sig.Printer(Syntax.Ast).S
17468           
17469       end =
17470       struct
17471         module Id =
17472           struct
17473             let name = "Camlp4Printers.DumpCamlp4Ast"
17474               
17475             let version = Sys.ocaml_version
17476               
17477           end
17478           
17479         module Make (Syntax : Sig.Syntax) : Sig.Printer(Syntax.Ast).S =
17480           struct
17481             include Syntax
17482               
17483             let with_open_out_file x f =
17484               match x with
17485               | Some file ->
17486                   let oc = open_out_bin file
17487                   in (f oc; flush oc; close_out oc)
17488               | None ->
17489                   (set_binary_mode_out stdout true; f stdout; flush stdout)
17490               
17491             let dump_ast magic ast oc =
17492               (output_string oc magic; output_value oc ast)
17493               
17494             let print_interf ?input_file:(_) ?output_file ast =
17495               with_open_out_file output_file
17496                 (dump_ast Camlp4_config.camlp4_ast_intf_magic_number ast)
17497               
17498             let print_implem ?input_file:(_) ?output_file ast =
17499               with_open_out_file output_file
17500                 (dump_ast Camlp4_config.camlp4_ast_impl_magic_number ast)
17501               
17502           end
17503           
17504       end
17505       
17506     module DumpOCamlAst :
17507       sig
17508         module Id : Sig.Id
17509           
17510         module Make (Syntax : Sig.Camlp4Syntax) : Sig.Printer(Syntax.Ast).S
17511           
17512       end =
17513       struct
17514         module Id : Sig.Id =
17515           struct
17516             let name = "Camlp4Printers.DumpOCamlAst"
17517               
17518             let version = Sys.ocaml_version
17519               
17520           end
17521           
17522         module Make (Syntax : Sig.Camlp4Syntax) : Sig.Printer(Syntax.Ast).S =
17523           struct
17524             include Syntax
17525               
17526             module Ast2pt = Struct.Camlp4Ast2OCamlAst.Make(Ast)
17527               
17528             let with_open_out_file x f =
17529               match x with
17530               | Some file ->
17531                   let oc = open_out_bin file
17532                   in (f oc; flush oc; close_out oc)
17533               | None ->
17534                   (set_binary_mode_out stdout true; f stdout; flush stdout)
17535               
17536             let dump_pt magic fname pt oc =
17537               (output_string oc magic;
17538                output_value oc (if fname = "-" then "" else fname);
17539                output_value oc pt)
17540               
17541             let print_interf ?(input_file = "-") ?output_file ast =
17542               let pt = Ast2pt.sig_item ast
17543               in
17544                 with_open_out_file output_file
17545                   (dump_pt Camlp4_config.ocaml_ast_intf_magic_number
17546                      input_file pt)
17547               
17548             let print_implem ?(input_file = "-") ?output_file ast =
17549               let pt = Ast2pt.str_item ast
17550               in
17551                 with_open_out_file output_file
17552                   (dump_pt Camlp4_config.ocaml_ast_impl_magic_number
17553                      input_file pt)
17554               
17555           end
17556           
17557       end
17558       
17559     module Null :
17560       sig
17561         module Id : Sig.Id
17562           
17563         module Make (Syntax : Sig.Syntax) : Sig.Printer(Syntax.Ast).S
17564           
17565       end =
17566       struct
17567         module Id =
17568           struct
17569             let name = "Camlp4.Printers.Null"
17570               
17571             let version = Sys.ocaml_version
17572               
17573           end
17574           
17575         module Make (Syntax : Sig.Syntax) =
17576           struct
17577             include Syntax
17578               
17579             let print_interf ?input_file:(_) ?output_file:(_) _ = ()
17580               
17581             let print_implem ?input_file:(_) ?output_file:(_) _ = ()
17582               
17583           end
17584           
17585       end
17586       
17587     module OCaml :
17588       sig
17589         module Id : Sig.Id
17590           
17591         module Make (Syntax : Sig.Camlp4Syntax) :
17592           sig
17593             open Format
17594               
17595             include Sig.Camlp4Syntax with module Loc = Syntax.Loc
17596               and module Token = Syntax.Token and module Ast = Syntax.Ast
17597               and module Gram = Syntax.Gram
17598               
17599             type sep = (unit, formatter, unit) format
17600             
17601             val list' :
17602               (formatter -> 'a -> unit) ->
17603                 ('b, formatter, unit) format ->
17604                   (unit, formatter, unit) format ->
17605                     formatter -> 'a list -> unit
17606               
17607             val list :
17608               (formatter -> 'a -> unit) ->
17609                 ('b, formatter, unit) format -> formatter -> 'a list -> unit
17610               
17611             val lex_string : string -> Token.t
17612               
17613             val is_infix : string -> bool
17614               
17615             val is_keyword : string -> bool
17616               
17617             val ocaml_char : string -> string
17618               
17619             val get_expr_args :
17620               Ast.expr -> Ast.expr list -> (Ast.expr * (Ast.expr list))
17621               
17622             val get_patt_args :
17623               Ast.patt -> Ast.patt list -> (Ast.patt * (Ast.patt list))
17624               
17625             val get_ctyp_args :
17626               Ast.ctyp -> Ast.ctyp list -> (Ast.ctyp * (Ast.ctyp list))
17627               
17628             val expr_fun_args : Ast.expr -> ((Ast.patt list) * Ast.expr)
17629               
17630             class printer :
17631               ?curry_constr: bool ->
17632                 ?comments: bool ->
17633                   unit ->
17634                     object ('a)
17635                       method interf : formatter -> Ast.sig_item -> unit
17636                         
17637                       method implem : formatter -> Ast.str_item -> unit
17638                         
17639                       method sig_item : formatter -> Ast.sig_item -> unit
17640                         
17641                       method str_item : formatter -> Ast.str_item -> unit
17642                         
17643                       val pipe : bool
17644                         
17645                       val semi : bool
17646                         
17647                       val semisep : sep
17648                         
17649                       val value_val : string
17650                         
17651                       val value_let : string
17652                         
17653                       method anti : formatter -> string -> unit
17654                         
17655                       method class_declaration :
17656                         formatter -> Ast.class_expr -> unit
17657                         
17658                       method class_expr : formatter -> Ast.class_expr -> unit
17659                         
17660                       method class_sig_item :
17661                         formatter -> Ast.class_sig_item -> unit
17662                         
17663                       method class_str_item :
17664                         formatter -> Ast.class_str_item -> unit
17665                         
17666                       method class_type : formatter -> Ast.class_type -> unit
17667                         
17668                       method constrain :
17669                         formatter -> (Ast.ctyp * Ast.ctyp) -> unit
17670                         
17671                       method ctyp : formatter -> Ast.ctyp -> unit
17672                         
17673                       method ctyp1 : formatter -> Ast.ctyp -> unit
17674                         
17675                       method constructor_type : formatter -> Ast.ctyp -> unit
17676                         
17677                       method dot_expr : formatter -> Ast.expr -> unit
17678                         
17679                       method apply_expr : formatter -> Ast.expr -> unit
17680                         
17681                       method expr : formatter -> Ast.expr -> unit
17682                         
17683                       method expr_list : formatter -> Ast.expr list -> unit
17684                         
17685                       method expr_list_cons :
17686                         bool -> formatter -> Ast.expr -> unit
17687                         
17688                       method functor_arg :
17689                         formatter -> (string * Ast.module_type) -> unit
17690                         
17691                       method functor_args :
17692                         formatter -> (string * Ast.module_type) list -> unit
17693                         
17694                       method ident : formatter -> Ast.ident -> unit
17695                         
17696                       method numeric : formatter -> string -> string -> unit
17697                         
17698                       method binding : formatter -> Ast.binding -> unit
17699                         
17700                       method record_binding :
17701                         formatter -> Ast.rec_binding -> unit
17702                         
17703                       method match_case : formatter -> Ast.match_case -> unit
17704                         
17705                       method match_case_aux :
17706                         formatter -> Ast.match_case -> unit
17707                         
17708                       method mk_expr_list :
17709                         Ast.expr -> ((Ast.expr list) * (Ast.expr option))
17710                         
17711                       method mk_patt_list :
17712                         Ast.patt -> ((Ast.patt list) * (Ast.patt option))
17713                         
17714                       method simple_module_expr :
17715                         formatter -> Ast.module_expr -> unit
17716                         
17717                       method module_expr :
17718                         formatter -> Ast.module_expr -> unit
17719                         
17720                       method module_expr_get_functor_args :
17721                         (string * Ast.module_type) list ->
17722                           Ast.module_expr ->
17723                             (((string * Ast.module_type) list) * Ast.
17724                              module_expr * (Ast.module_type option))
17725                         
17726                       method module_rec_binding :
17727                         formatter -> Ast.module_binding -> unit
17728                         
17729                       method module_type :
17730                         formatter -> Ast.module_type -> unit
17731                         
17732                       method mutable_flag :
17733                         formatter -> Ast.meta_bool -> unit
17734                         
17735                       method direction_flag :
17736                         formatter -> Ast.meta_bool -> unit
17737                         
17738                       method rec_flag : formatter -> Ast.meta_bool -> unit
17739                         
17740                       method flag :
17741                         formatter -> Ast.meta_bool -> string -> unit
17742                         
17743                       method node : formatter -> 'b -> ('b -> Loc.t) -> unit
17744                         
17745                       method patt : formatter -> Ast.patt -> unit
17746                         
17747                       method patt1 : formatter -> Ast.patt -> unit
17748                         
17749                       method patt2 : formatter -> Ast.patt -> unit
17750                         
17751                       method patt3 : formatter -> Ast.patt -> unit
17752                         
17753                       method patt4 : formatter -> Ast.patt -> unit
17754                         
17755                       method patt5 : formatter -> Ast.patt -> unit
17756                         
17757                       method patt_tycon : formatter -> Ast.patt -> unit
17758                         
17759                       method patt_expr_fun_args :
17760                         formatter -> (Ast.patt * Ast.expr) -> unit
17761                         
17762                       method patt_class_expr_fun_args :
17763                         formatter -> (Ast.patt * Ast.class_expr) -> unit
17764                         
17765                       method print_comments_before :
17766                         Loc.t -> formatter -> unit
17767                         
17768                       method private_flag :
17769                         formatter -> Ast.meta_bool -> unit
17770                         
17771                       method virtual_flag :
17772                         formatter -> Ast.meta_bool -> unit
17773                         
17774                       method quoted_string : formatter -> string -> unit
17775                         
17776                       method raise_match_failure : formatter -> Loc.t -> unit
17777                         
17778                       method reset : 'a
17779                         
17780                       method reset_semi : 'a
17781                         
17782                       method semisep : sep
17783                         
17784                       method set_comments : bool -> 'a
17785                         
17786                       method set_curry_constr : bool -> 'a
17787                         
17788                       method set_loc_and_comments : 'a
17789                         
17790                       method set_semisep : sep -> 'a
17791                         
17792                       method simple_ctyp : formatter -> Ast.ctyp -> unit
17793                         
17794                       method simple_expr : formatter -> Ast.expr -> unit
17795                         
17796                       method simple_patt : formatter -> Ast.patt -> unit
17797                         
17798                       method seq : formatter -> Ast.expr -> unit
17799                         
17800                       method string : formatter -> string -> unit
17801                         
17802                       method sum_type : formatter -> Ast.ctyp -> unit
17803                         
17804                       method type_params : formatter -> Ast.ctyp list -> unit
17805                         
17806                       method class_params : formatter -> Ast.ctyp -> unit
17807                         
17808                       method under_pipe : 'a
17809                         
17810                       method under_semi : 'a
17811                         
17812                       method var : formatter -> string -> unit
17813                         
17814                       method with_constraint :
17815                         formatter -> Ast.with_constr -> unit
17816                         
17817                     end
17818               
17819             val with_outfile :
17820               string option -> (formatter -> 'a -> unit) -> 'a -> unit
17821               
17822             val print :
17823               string option ->
17824                 (printer -> formatter -> 'a -> unit) -> 'a -> unit
17825               
17826           end
17827           
17828         module MakeMore (Syntax : Sig.Camlp4Syntax) : Sig.Printer(Syntax.
17829           Ast).S
17830           
17831       end =
17832       struct
17833         open Format
17834           
17835         module Id =
17836           struct
17837             let name = "Camlp4.Printers.OCaml"
17838               
17839             let version = Sys.ocaml_version
17840               
17841           end
17842           
17843         module Make (Syntax : Sig.Camlp4Syntax) =
17844           struct
17845             include Syntax
17846               
17847             type sep = (unit, formatter, unit) format
17848             
17849             let pp = fprintf
17850               
17851             let cut f = fprintf f "@ "
17852               
17853             let list' elt sep sep' f =
17854               let rec loop =
17855                 function
17856                 | [] -> ()
17857                 | x :: xs -> (pp f sep; elt f x; pp f sep'; loop xs)
17858               in
17859                 function
17860                 | [] -> ()
17861                 | [ x ] -> (elt f x; pp f sep')
17862                 | x :: xs -> (elt f x; pp f sep'; loop xs)
17863               
17864             let list elt sep f =
17865               let rec loop =
17866                 function | [] -> () | x :: xs -> (pp f sep; elt f x; loop xs)
17867               in
17868                 function
17869                 | [] -> ()
17870                 | [ x ] -> elt f x
17871                 | x :: xs -> (elt f x; loop xs)
17872               
17873             let rec list_of_meta_list =
17874               function
17875               | Ast.LNil -> []
17876               | Ast.LCons (x, xs) -> x :: (list_of_meta_list xs)
17877               | Ast.LAnt x -> assert false
17878               
17879             let meta_list elt sep f mxs =
17880               let xs = list_of_meta_list mxs in list elt sep f xs
17881               
17882             module CommentFilter = Struct.CommentFilter.Make(Token)
17883               
17884             let comment_filter = CommentFilter.mk ()
17885               
17886             let _ = CommentFilter.define (Gram.get_filter ()) comment_filter
17887               
17888             module StringSet = Set.Make(String)
17889               
17890             let infix_lidents =
17891               [ "asr"; "land"; "lor"; "lsl"; "lsr"; "lxor"; "mod"; "or" ]
17892               
17893             let is_infix =
17894               let first_chars =
17895                 [ '='; '<'; '>'; '|'; '&'; '$'; '@'; '^'; '+'; '-'; '*'; '/';
17896                   '%'; '\\' ]
17897               and infixes =
17898                 List.fold_right StringSet.add infix_lidents StringSet.empty
17899               in
17900                 fun s ->
17901                   (StringSet.mem s infixes) ||
17902                     ((s <> "") && (List.mem s.[0] first_chars))
17903               
17904             let is_keyword =
17905               let keywords =
17906                 List.fold_right StringSet.add
17907                   [ "and"; "as"; "assert"; "begin"; "class"; "constraint";
17908                     "do"; "done"; "downto"; "else"; "end"; "exception";
17909                     "external"; "false"; "for"; "fun"; "function"; "functor";
17910                     "if"; "in"; "include"; "inherit"; "initializer"; "lazy";
17911                     "let"; "match"; "method"; "module"; "mutable"; "new";
17912                     "object"; "of"; "open"; "parser"; "private"; "rec";
17913                     "sig"; "struct"; "then"; "to"; "true"; "try"; "type";
17914                     "val"; "virtual"; "when"; "while"; "with" ]
17915                   StringSet.empty
17916               in fun s -> StringSet.mem s keywords
17917               
17918             module Lexer = Struct.Lexer.Make(Token)
17919               
17920             let _ = let module M = ErrorHandler.Register(Lexer.Error) in ()
17921               
17922             open Sig
17923               
17924             let lexer s =
17925               Lexer.from_string ~quotations: !Camlp4_config.quotations Loc.
17926                 ghost s
17927               
17928             let lex_string str =
17929               try
17930                 let (__strm : _ Stream.t) = lexer str
17931                 in
17932                   match Stream.peek __strm with
17933                   | Some ((tok, _)) ->
17934                       (Stream.junk __strm;
17935                        (match Stream.peek __strm with
17936                         | Some ((EOI, _)) -> (Stream.junk __strm; tok)
17937                         | _ -> raise (Stream.Error "")))
17938                   | _ -> raise Stream.Failure
17939               with
17940               | Stream.Failure | Stream.Error _ ->
17941                   failwith
17942                     (sprintf
17943                        "Cannot print %S this string contains more than one token"
17944                        str)
17945               | Lexer.Error.E exn ->
17946                   failwith
17947                     (sprintf
17948                        "Cannot print %S this identifier does not respect OCaml lexing rules (%s)"
17949                        str (Lexer.Error.to_string exn))
17950               
17951             let ocaml_char = function | "'" -> "\\'" | c -> c
17952               
17953             let rec get_expr_args a al =
17954               match a with
17955               | Ast.ExApp (_, a1, a2) -> get_expr_args a1 (a2 :: al)
17956               | _ -> (a, al)
17957               
17958             let rec get_patt_args a al =
17959               match a with
17960               | Ast.PaApp (_, a1, a2) -> get_patt_args a1 (a2 :: al)
17961               | _ -> (a, al)
17962               
17963             let rec get_ctyp_args a al =
17964               match a with
17965               | Ast.TyApp (_, a1, a2) -> get_ctyp_args a1 (a2 :: al)
17966               | _ -> (a, al)
17967               
17968             let is_irrefut_patt = Ast.is_irrefut_patt
17969               
17970             let rec expr_fun_args =
17971               function
17972               | (Ast.ExFun (_, (Ast.McArr (_, p, (Ast.ExNil _), e))) as ge)
17973                   ->
17974                   if is_irrefut_patt p
17975                   then (let (pl, e) = expr_fun_args e in ((p :: pl), e))
17976                   else ([], ge)
17977               | ge -> ([], ge)
17978               
17979             let rec class_expr_fun_args =
17980               function
17981               | (Ast.CeFun (_, p, ce) as ge) ->
17982                   if is_irrefut_patt p
17983                   then
17984                     (let (pl, ce) = class_expr_fun_args ce in ((p :: pl), ce))
17985                   else ([], ge)
17986               | ge -> ([], ge)
17987               
17988             let rec do_print_comments_before loc f (__strm : _ Stream.t) =
17989               match Stream.peek __strm with
17990               | Some ((comm, comm_loc)) when Loc.strictly_before comm_loc loc
17991                   ->
17992                   (Stream.junk __strm;
17993                    let s = __strm in
17994                    let () = f comm comm_loc
17995                    in do_print_comments_before loc f s)
17996               | _ -> ()
17997               
17998             class printer ?curry_constr:(init_curry_constr = false)
17999                     ?(comments = true) () =
18000               object (o)
18001                 val pipe = false
18002                   
18003                 val semi = false
18004                   
18005                 method under_pipe = {< pipe = true; >}
18006                   
18007                 method under_semi = {< semi = true; >}
18008                   
18009                 method reset_semi = {< semi = false; >}
18010                   
18011                 method reset = {< pipe = false; semi = false; >}
18012                   
18013                 val semisep = (";;" : sep)
18014                   
18015                 val andsep = ("@]@ @[<2>and@ " : sep)
18016                   
18017                 val value_val = "val"
18018                   
18019                 val value_let = "let"
18020                   
18021                 val mode = if comments then `comments else `no_comments
18022                   
18023                 val curry_constr = init_curry_constr
18024                   
18025                 val var_conversion = false
18026                   
18027                 method semisep = semisep
18028                   
18029                 method set_semisep = fun s -> {< semisep = s; >}
18030                   
18031                 method set_comments =
18032                   fun b ->
18033                     {< mode = if b then `comments else `no_comments; >}
18034                   
18035                 method set_loc_and_comments = {< mode = `loc_and_comments; >}
18036                   
18037                 method set_curry_constr = fun b -> {< curry_constr = b; >}
18038                   
18039                 method print_comments_before =
18040                   fun loc f ->
18041                     match mode with
18042                     | `comments ->
18043                         do_print_comments_before loc
18044                           (fun c _ -> pp f "%s@ " c)
18045                           (CommentFilter.take_stream comment_filter)
18046                     | `loc_and_comments ->
18047                         let () = pp f "(*loc: %a*)@ " Loc.dump loc
18048                         in
18049                           do_print_comments_before loc
18050                             (fun s -> pp f "%s(*comm_loc: %a*)@ " s Loc.dump)
18051                             (CommentFilter.take_stream comment_filter)
18052                     | _ -> ()
18053                   
18054                 method var =
18055                   fun f ->
18056                     function
18057                     | "" -> pp f "$lid:\"\"$"
18058                     | "[]" -> pp f "[]"
18059                     | "()" -> pp f "()"
18060                     | " True" -> pp f "True"
18061                     | " False" -> pp f "False"
18062                     | v ->
18063                         (match (var_conversion, v) with
18064                          | (true, "val") -> pp f "contents"
18065                          | (true, "True") -> pp f "true"
18066                          | (true, "False") -> pp f "false"
18067                          | _ ->
18068                              (match lex_string v with
18069                               | LIDENT s | UIDENT s | ESCAPED_IDENT s when
18070                                   is_keyword s -> pp f "%s__" s
18071                               | LIDENT s | ESCAPED_IDENT s when
18072                                   List.mem s infix_lidents -> pp f "( %s )" s
18073                               | SYMBOL s -> pp f "( %s )" s
18074                               | LIDENT s | UIDENT s | ESCAPED_IDENT s ->
18075                                   pp_print_string f s
18076                               | tok ->
18077                                   failwith
18078                                     (sprintf
18079                                        "Bad token used as an identifier: %s"
18080                                        (Token.to_string tok))))
18081                   
18082                 method type_params =
18083                   fun f ->
18084                     function
18085                     | [] -> ()
18086                     | [ x ] -> pp f "%a@ " o#ctyp x
18087                     | l -> pp f "@[<1>(%a)@]@ " (list o#ctyp ",@ ") l
18088                   
18089                 method class_params =
18090                   fun f ->
18091                     function
18092                     | Ast.TyCom (_, t1, t2) ->
18093                         pp f "@[<1>%a,@ %a@]" o#class_params t1
18094                           o#class_params t2
18095                     | x -> o#ctyp f x
18096                   
18097                 method mutable_flag = fun f b -> o#flag f b "mutable"
18098                   
18099                 method rec_flag = fun f b -> o#flag f b "rec"
18100                   
18101                 method virtual_flag = fun f b -> o#flag f b "virtual"
18102                   
18103                 method private_flag = fun f b -> o#flag f b "private"
18104                   
18105                 method flag =
18106                   fun f b n ->
18107                     match b with
18108                     | Ast.BTrue -> (pp_print_string f n; pp f "@ ")
18109                     | Ast.BFalse -> ()
18110                     | Ast.BAnt s -> o#anti f s
18111                   
18112                 method anti = fun f s -> pp f "$%s$" s
18113                   
18114                 method seq =
18115                   fun f ->
18116                     function
18117                     | Ast.ExSem (_, e1, e2) ->
18118                         pp f "%a;@ %a" o#under_semi#seq e1 o#seq e2
18119                     | Ast.ExSeq (_, e) -> o#seq f e
18120                     | e -> o#expr f e
18121                   
18122                 method match_case =
18123                   fun f ->
18124                     function
18125                     | Ast.McNil _loc ->
18126                         pp f "@[<2>@ _ ->@ %a@]" o#raise_match_failure _loc
18127                     | a -> o#match_case_aux f a
18128                   
18129                 method match_case_aux =
18130                   fun f ->
18131                     function
18132                     | Ast.McNil _ -> ()
18133                     | Ast.McAnt (_, s) -> o#anti f s
18134                     | Ast.McOr (_, a1, a2) ->
18135                         pp f "%a%a" o#match_case_aux a1 o#match_case_aux a2
18136                     | Ast.McArr (_, p, (Ast.ExNil _), e) ->
18137                         pp f "@ | @[<2>%a@ ->@ %a@]" o#patt p
18138                           o#under_pipe#expr e
18139                     | Ast.McArr (_, p, w, e) ->
18140                         pp f "@ | @[<2>%a@ when@ %a@ ->@ %a@]" o#patt p
18141                           o#under_pipe#expr w o#under_pipe#expr e
18142                   
18143                 method binding =
18144                   fun f bi ->
18145                     let () = o#node f bi Ast.loc_of_binding
18146                     in
18147                       match bi with
18148                       | Ast.BiNil _ -> ()
18149                       | Ast.BiAnd (_, b1, b2) ->
18150                           (o#binding f b1; pp f andsep; o#binding f b2)
18151                       | Ast.BiEq (_, p, e) ->
18152                           let (pl, e) =
18153                             (match p with
18154                              | Ast.PaTyc (_, _, _) -> ([], e)
18155                              | _ -> expr_fun_args e)
18156                           in
18157                             (match (p, e) with
18158                              | (Ast.PaId (_, (Ast.IdLid (_, _))),
18159                                 Ast.ExTyc (_, e, t)) ->
18160                                  pp f "%a :@ %a =@ %a"
18161                                    (list o#simple_patt "@ ") (p :: pl) 
18162                                    o#ctyp t o#expr e
18163                              | _ ->
18164                                  pp f "%a @[<0>%a=@]@ %a" o#simple_patt p
18165                                    (list' o#simple_patt "" "@ ") pl o#expr e)
18166                       | Ast.BiAnt (_, s) -> o#anti f s
18167                   
18168                 method record_binding =
18169                   fun f bi ->
18170                     let () = o#node f bi Ast.loc_of_rec_binding
18171                     in
18172                       match bi with
18173                       | Ast.RbNil _ -> ()
18174                       | Ast.RbEq (_, i, e) ->
18175                           pp f "@ @[<2>%a =@ %a@];" o#var_ident i o#expr e
18176                       | Ast.RbSem (_, b1, b2) ->
18177                           (o#under_semi#record_binding f b1;
18178                            o#under_semi#record_binding f b2)
18179                       | Ast.RbAnt (_, s) -> o#anti f s
18180                   
18181                 method mk_patt_list =
18182                   function
18183                   | Ast.PaApp (_,
18184                       (Ast.PaApp (_, (Ast.PaId (_, (Ast.IdUid (_, "::")))),
18185                          p1)),
18186                       p2) ->
18187                       let (pl, c) = o#mk_patt_list p2 in ((p1 :: pl), c)
18188                   | Ast.PaId (_, (Ast.IdUid (_, "[]"))) -> ([], None)
18189                   | p -> ([], (Some p))
18190                   
18191                 method mk_expr_list =
18192                   function
18193                   | Ast.ExApp (_,
18194                       (Ast.ExApp (_, (Ast.ExId (_, (Ast.IdUid (_, "::")))),
18195                          e1)),
18196                       e2) ->
18197                       let (el, c) = o#mk_expr_list e2 in ((e1 :: el), c)
18198                   | Ast.ExId (_, (Ast.IdUid (_, "[]"))) -> ([], None)
18199                   | e -> ([], (Some e))
18200                   
18201                 method expr_list =
18202                   fun f ->
18203                     function
18204                     | [] -> pp f "[]"
18205                     | [ e ] -> pp f "[ %a ]" o#under_semi#expr e
18206                     | el ->
18207                         pp f "@[<2>[ %a@] ]" (list o#under_semi#expr ";@ ")
18208                           el
18209                   
18210                 method expr_list_cons =
18211                   fun simple f e ->
18212                     let (el, c) = o#mk_expr_list e
18213                     in
18214                       match c with
18215                       | None -> o#expr_list f el
18216                       | Some x ->
18217                           (if simple
18218                            then pp f "@[<2>(%a)@]"
18219                            else pp f "@[<2>%a@]")
18220                             (list o#under_semi#dot_expr " ::@ ") (el @ [ x ])
18221                   
18222                 method patt_expr_fun_args =
18223                   fun f (p, e) ->
18224                     let (pl, e) = expr_fun_args e
18225                     in
18226                       pp f "%a@ ->@ %a" (list o#simple_patt "@ ") (p :: pl)
18227                         o#expr e
18228                   
18229                 method patt_class_expr_fun_args =
18230                   fun f (p, ce) ->
18231                     let (pl, ce) = class_expr_fun_args ce
18232                     in
18233                       pp f "%a =@]@ %a" (list o#simple_patt "@ ") (p :: pl)
18234                         o#class_expr ce
18235                   
18236                 method constrain =
18237                   fun f (t1, t2) ->
18238                     pp f "@[<2>constraint@ %a =@ %a@]" o#ctyp t1 o#ctyp t2
18239                   
18240                 method sum_type =
18241                   fun f t ->
18242                     match Ast.list_of_ctyp t [] with
18243                     | [] -> ()
18244                     | ts -> pp f "@[<hv0>| %a@]" (list o#ctyp "@ | ") ts
18245                   
18246                 method string = fun f -> pp f "%s"
18247                   
18248                 method quoted_string = fun f -> pp f "%S"
18249                   
18250                 method numeric =
18251                   fun f num suff ->
18252                     if num.[0] = '-'
18253                     then pp f "(%s%s)" num suff
18254                     else pp f "%s%s" num suff
18255                   
18256                 method module_expr_get_functor_args =
18257                   fun accu ->
18258                     function
18259                     | Ast.MeFun (_, s, mt, me) ->
18260                         o#module_expr_get_functor_args ((s, mt) :: accu) me
18261                     | Ast.MeTyc (_, me, mt) ->
18262                         ((List.rev accu), me, (Some mt))
18263                     | me -> ((List.rev accu), me, None)
18264                   
18265                 method functor_args = fun f -> list o#functor_arg "@ " f
18266                   
18267                 method functor_arg =
18268                   fun f (s, mt) ->
18269                     pp f "@[<2>(%a :@ %a)@]" o#var s o#module_type mt
18270                   
18271                 method module_rec_binding =
18272                   fun f ->
18273                     function
18274                     | Ast.MbNil _ -> ()
18275                     | Ast.MbColEq (_, s, mt, me) ->
18276                         pp f "@[<2>%a :@ %a =@ %a@]" o#var s o#module_type mt
18277                           o#module_expr me
18278                     | Ast.MbCol (_, s, mt) ->
18279                         pp f "@[<2>%a :@ %a@]" o#var s o#module_type mt
18280                     | Ast.MbAnd (_, mb1, mb2) ->
18281                         (o#module_rec_binding f mb1;
18282                          pp f andsep;
18283                          o#module_rec_binding f mb2)
18284                     | Ast.MbAnt (_, s) -> o#anti f s
18285                   
18286                 method class_declaration =
18287                   fun f ->
18288                     function
18289                     | Ast.CeTyc (_, ce, ct) ->
18290                         pp f "%a :@ %a" o#class_expr ce o#class_type ct
18291                     | ce -> o#class_expr f ce
18292                   
18293                 method raise_match_failure =
18294                   fun f _loc ->
18295                     let n = Loc.file_name _loc in
18296                     let l = Loc.start_line _loc in
18297                     let c = (Loc.start_off _loc) - (Loc.start_bol _loc)
18298                     in
18299                       o#expr f
18300                         (Ast.ExApp (_loc,
18301                            Ast.ExId (_loc, Ast.IdLid (_loc, "raise")),
18302                            Ast.ExApp (_loc,
18303                              Ast.ExApp (_loc,
18304                                Ast.ExApp (_loc,
18305                                  Ast.ExId (_loc,
18306                                    Ast.IdUid (_loc, "Match_failure")),
18307                                  Ast.ExStr (_loc, Ast.safe_string_escaped n)),
18308                                Ast.ExInt (_loc, string_of_int l)),
18309                              Ast.ExInt (_loc, string_of_int c))))
18310                   
18311                 method node : 'a. formatter -> 'a -> ('a -> Loc.t) -> unit =
18312                   fun f node loc_of_node ->
18313                     o#print_comments_before (loc_of_node node) f
18314                   
18315                 method ident =
18316                   fun f i ->
18317                     let () = o#node f i Ast.loc_of_ident
18318                     in
18319                       match i with
18320                       | Ast.IdAcc (_, i1, i2) ->
18321                           pp f "%a.@,%a" o#ident i1 o#ident i2
18322                       | Ast.IdApp (_, i1, i2) ->
18323                           pp f "%a@,(%a)" o#ident i1 o#ident i2
18324                       | Ast.IdAnt (_, s) -> o#anti f s
18325                       | Ast.IdLid (_, s) | Ast.IdUid (_, s) -> o#var f s
18326                   
18327                 method private var_ident = {< var_conversion = true; >}#ident
18328                   
18329                 method expr =
18330                   fun f e ->
18331                     let () = o#node f e Ast.loc_of_expr
18332                     in
18333                       match e with
18334                       | (Ast.ExLet (_, _, _, _) | Ast.ExLmd (_, _, _, _) as
18335                          e) when semi -> pp f "(%a)" o#reset#expr e
18336                       | (Ast.ExMat (_, _, _) | Ast.ExTry (_, _, _) |
18337                            Ast.ExFun (_, _)
18338                          as e) when pipe || semi ->
18339                           pp f "(%a)" o#reset#expr e
18340                       | Ast.ExApp (_, (Ast.ExId (_, (Ast.IdLid (_, "~-")))),
18341                           x) -> pp f "@[<2>-@ %a@]" o#dot_expr x
18342                       | Ast.ExApp (_, (Ast.ExId (_, (Ast.IdLid (_, "~-.")))),
18343                           x) -> pp f "@[<2>-.@ %a@]" o#dot_expr x
18344                       | Ast.ExApp (_,
18345                           (Ast.ExApp (_,
18346                              (Ast.ExId (_, (Ast.IdUid (_, "::")))), _)),
18347                           _) -> o#expr_list_cons false f e
18348                       | Ast.ExApp (_loc,
18349                           (Ast.ExApp (_, (Ast.ExId (_, (Ast.IdLid (_, n)))),
18350                              x)),
18351                           y) when is_infix n ->
18352                           pp f "@[<2>%a@ %s@ %a@]" o#apply_expr x n
18353                             o#apply_expr y
18354                       | Ast.ExApp (_, x, y) ->
18355                           let (a, al) = get_expr_args x [ y ]
18356                           in
18357                             if
18358                               (not curry_constr) &&
18359                                 (Ast.is_expr_constructor a)
18360                             then
18361                               (match al with
18362                                | [ Ast.ExTup (_, _) ] ->
18363                                    pp f "@[<2>%a@ (%a)@]" o#apply_expr x
18364                                      o#expr y
18365                                | [ _ ] ->
18366                                    pp f "@[<2>%a@ %a@]" o#apply_expr x
18367                                      o#apply_expr y
18368                                | al ->
18369                                    pp f "@[<2>%a@ (%a)@]" o#apply_expr a
18370                                      (list o#under_pipe#expr ",@ ") al)
18371                             else
18372                               pp f "@[<2>%a@]" (list o#apply_expr "@ ")
18373                                 (a :: al)
18374                       | Ast.ExAss (_,
18375                           (Ast.ExAcc (_, e1,
18376                              (Ast.ExId (_, (Ast.IdLid (_, "val")))))),
18377                           e2) ->
18378                           pp f "@[<2>%a :=@ %a@]" o#dot_expr e1 o#expr e2
18379                       | Ast.ExAss (_, e1, e2) ->
18380                           pp f "@[<2>%a@ <-@ %a@]" o#dot_expr e1 o#expr e2
18381                       | Ast.ExFun (loc, (Ast.McNil _)) ->
18382                           pp f "@[<2>fun@ _@ ->@ %a@]" o#raise_match_failure
18383                             loc
18384                       | Ast.ExFun (_, (Ast.McArr (_, p, (Ast.ExNil _), e)))
18385                           when is_irrefut_patt p ->
18386                           pp f "@[<2>fun@ %a@]" o#patt_expr_fun_args (p, e)
18387                       | Ast.ExFun (_, a) ->
18388                           pp f "@[<hv0>function%a@]" o#match_case a
18389                       | Ast.ExIfe (_, e1, e2, e3) ->
18390                           pp f
18391                             "@[<hv0>@[<2>if@ %a@]@ @[<2>then@ %a@]@ @[<2>else@ %a@]@]"
18392                             o#expr e1 o#under_semi#expr e2 o#under_semi#expr
18393                             e3
18394                       | Ast.ExLaz (_, e) ->
18395                           pp f "@[<2>lazy@ %a@]" o#simple_expr e
18396                       | Ast.ExLet (_, r, bi, e) ->
18397                           (match e with
18398                            | Ast.ExLet (_, _, _, _) ->
18399                                pp f "@[<0>@[<2>let %a%a in@]@ %a@]"
18400                                  o#rec_flag r o#binding bi o#reset_semi#expr
18401                                  e
18402                            | _ ->
18403                                pp f
18404                                  "@[<hv0>@[<2>let %a%a@]@ @[<hv2>in@ %a@]@]"
18405                                  o#rec_flag r o#binding bi o#reset_semi#expr
18406                                  e)
18407                       | Ast.ExMat (_, e, a) ->
18408                           pp f "@[<hv0>@[<hv0>@[<2>match %a@]@ with@]%a@]"
18409                             o#expr e o#match_case a
18410                       | Ast.ExTry (_, e, a) ->
18411                           pp f "@[<0>@[<hv2>try@ %a@]@ @[<0>with%a@]@]"
18412                             o#expr e o#match_case a
18413                       | Ast.ExAsf _ -> pp f "@[<2>assert@ false@]"
18414                       | Ast.ExAsr (_, e) ->
18415                           pp f "@[<2>assert@ %a@]" o#dot_expr e
18416                       | Ast.ExLmd (_, s, me, e) ->
18417                           pp f "@[<2>let module %a =@ %a@]@ @[<2>in@ %a@]"
18418                             o#var s o#module_expr me o#reset_semi#expr e
18419                       | Ast.ExObj (_, (Ast.PaNil _), cst) ->
18420                           pp f "@[<hv0>@[<hv2>object@ %a@]@ end@]"
18421                             o#class_str_item cst
18422                       | Ast.ExObj (_, (Ast.PaTyc (_, p, t)), cst) ->
18423                           pp f
18424                             "@[<hv0>@[<hv2>object @[<1>(%a :@ %a)@]@ %a@]@ end@]"
18425                             o#patt p o#ctyp t o#class_str_item cst
18426                       | Ast.ExObj (_, p, cst) ->
18427                           pp f
18428                             "@[<hv0>@[<hv2>object @[<2>(%a)@]@ %a@]@ end@]"
18429                             o#patt p o#class_str_item cst
18430                       | e -> o#apply_expr f e
18431                   
18432                 method apply_expr =
18433                   fun f e ->
18434                     let () = o#node f e Ast.loc_of_expr
18435                     in
18436                       match e with
18437                       | Ast.ExNew (_, i) -> pp f "@[<2>new@ %a@]" o#ident i
18438                       | e -> o#dot_expr f e
18439                   
18440                 method dot_expr =
18441                   fun f e ->
18442                     let () = o#node f e Ast.loc_of_expr
18443                     in
18444                       match e with
18445                       | Ast.ExAcc (_, e,
18446                           (Ast.ExId (_, (Ast.IdLid (_, "val"))))) ->
18447                           pp f "@[<2>!@,%a@]" o#simple_expr e
18448                       | Ast.ExAcc (_, e1, e2) ->
18449                           pp f "@[<2>%a.@,%a@]" o#dot_expr e1 o#dot_expr e2
18450                       | Ast.ExAre (_, e1, e2) ->
18451                           pp f "@[<2>%a.@,(%a)@]" o#dot_expr e1 o#expr e2
18452                       | Ast.ExSte (_, e1, e2) ->
18453                           pp f "%a.@[<1>[@,%a@]@,]" o#dot_expr e1 o#expr e2
18454                       | Ast.ExSnd (_, e, s) ->
18455                           pp f "@[<2>%a#@,%s@]" o#dot_expr e s
18456                       | e -> o#simple_expr f e
18457                   
18458                 method simple_expr =
18459                   fun f e ->
18460                     let () = o#node f e Ast.loc_of_expr
18461                     in
18462                       match e with
18463                       | Ast.ExNil _ -> ()
18464                       | Ast.ExSeq (_, e) -> pp f "@[<hv1>(%a)@]" o#seq e
18465                       | Ast.ExApp (_,
18466                           (Ast.ExApp (_,
18467                              (Ast.ExId (_, (Ast.IdUid (_, "::")))), _)),
18468                           _) -> o#expr_list_cons true f e
18469                       | Ast.ExTup (_, e) -> pp f "@[<1>(%a)@]" o#expr e
18470                       | Ast.ExArr (_, e) ->
18471                           pp f "@[<0>@[<2>[|@ %a@]@ |]@]" o#under_semi#expr e
18472                       | Ast.ExCoe (_, e, (Ast.TyNil _), t) ->
18473                           pp f "@[<2>(%a :>@ %a)@]" o#expr e o#ctyp t
18474                       | Ast.ExCoe (_, e, t1, t2) ->
18475                           pp f "@[<2>(%a :@ %a :>@ %a)@]" o#expr e o#ctyp t1
18476                             o#ctyp t2
18477                       | Ast.ExTyc (_, e, t) ->
18478                           pp f "@[<2>(%a :@ %a)@]" o#expr e o#ctyp t
18479                       | Ast.ExAnt (_, s) -> o#anti f s
18480                       | Ast.ExFor (_, s, e1, e2, df, e3) ->
18481                           pp f
18482                             "@[<hv0>@[<hv2>@[<2>for %a =@ %a@ %a@ %a@ do@]@ %a@]@ done@]"
18483                             o#var s o#expr e1 o#direction_flag df o#expr e2
18484                             o#seq e3
18485                       | Ast.ExInt (_, s) -> o#numeric f s ""
18486                       | Ast.ExNativeInt (_, s) -> o#numeric f s "n"
18487                       | Ast.ExInt64 (_, s) -> o#numeric f s "L"
18488                       | Ast.ExInt32 (_, s) -> o#numeric f s "l"
18489                       | Ast.ExFlo (_, s) -> o#numeric f s ""
18490                       | Ast.ExChr (_, s) -> pp f "'%s'" (ocaml_char s)
18491                       | Ast.ExId (_, i) -> o#var_ident f i
18492                       | Ast.ExRec (_, b, (Ast.ExNil _)) ->
18493                           pp f "@[<hv0>@[<hv2>{%a@]@ }@]" o#record_binding b
18494                       | Ast.ExRec (_, b, e) ->
18495                           pp f "@[<hv0>@[<hv2>{@ (%a)@ with%a@]@ }@]" 
18496                             o#expr e o#record_binding b
18497                       | Ast.ExStr (_, s) -> pp f "\"%s\"" s
18498                       | Ast.ExWhi (_, e1, e2) ->
18499                           pp f "@[<2>while@ %a@ do@ %a@ done@]" o#expr e1
18500                             o#seq e2
18501                       | Ast.ExLab (_, s, (Ast.ExNil _)) -> pp f "~%s" s
18502                       | Ast.ExLab (_, s, e) ->
18503                           pp f "@[<2>~%s:@ %a@]" s o#dot_expr e
18504                       | Ast.ExOlb (_, s, (Ast.ExNil _)) -> pp f "?%s" s
18505                       | Ast.ExOlb (_, s, e) ->
18506                           pp f "@[<2>?%s:@ %a@]" s o#dot_expr e
18507                       | Ast.ExVrn (_, s) -> pp f "`%a" o#var s
18508                       | Ast.ExOvr (_, b) ->
18509                           pp f "@[<hv0>@[<hv2>{<%a@]@ >}@]" o#record_binding
18510                             b
18511                       | Ast.ExCom (_, e1, e2) ->
18512                           pp f "%a,@ %a" o#simple_expr e1 o#simple_expr e2
18513                       | Ast.ExSem (_, e1, e2) ->
18514                           pp f "%a;@ %a" o#under_semi#expr e1 o#expr e2
18515                       | Ast.ExApp (_, _, _) | Ast.ExAcc (_, _, _) |
18516                           Ast.ExAre (_, _, _) | Ast.ExSte (_, _, _) |
18517                           Ast.ExAss (_, _, _) | Ast.ExSnd (_, _, _) |
18518                           Ast.ExFun (_, _) | Ast.ExMat (_, _, _) |
18519                           Ast.ExTry (_, _, _) | Ast.ExIfe (_, _, _, _) |
18520                           Ast.ExLet (_, _, _, _) | Ast.ExLmd (_, _, _, _) |
18521                           Ast.ExAsr (_, _) | Ast.ExAsf _ | Ast.ExLaz (_, _) |
18522                           Ast.ExNew (_, _) | Ast.ExObj (_, _, _) ->
18523                           pp f "(%a)" o#reset#expr e
18524                   
18525                 method direction_flag =
18526                   fun f b ->
18527                     match b with
18528                     | Ast.BTrue -> pp_print_string f "to"
18529                     | Ast.BFalse -> pp_print_string f "downto"
18530                     | Ast.BAnt s -> o#anti f s
18531                   
18532                 method patt =
18533                   fun f p ->
18534                     let () = o#node f p Ast.loc_of_patt
18535                     in
18536                       match p with
18537                       | Ast.PaAli (_, p1, p2) ->
18538                           pp f "@[<1>(%a@ as@ %a)@]" o#patt p1 o#patt p2
18539                       | Ast.PaEq (_, i, p) ->
18540                           pp f "@[<2>%a =@ %a@]" o#var_ident i o#patt p
18541                       | Ast.PaSem (_, p1, p2) ->
18542                           pp f "%a;@ %a" o#patt p1 o#patt p2
18543                       | p -> o#patt1 f p
18544                   
18545                 method patt1 =
18546                   fun f ->
18547                     function
18548                     | Ast.PaOrp (_, p1, p2) ->
18549                         pp f "@[<2>%a@ |@ %a@]" o#patt1 p1 o#patt2 p2
18550                     | p -> o#patt2 f p
18551                   
18552                 method patt2 = fun f p -> o#patt3 f p
18553                   
18554                 method patt3 =
18555                   fun f ->
18556                     function
18557                     | Ast.PaRng (_, p1, p2) ->
18558                         pp f "@[<2>%a@ ..@ %a@]" o#patt3 p1 o#patt4 p2
18559                     | Ast.PaCom (_, p1, p2) ->
18560                         pp f "%a,@ %a" o#patt3 p1 o#patt3 p2
18561                     | p -> o#patt4 f p
18562                   
18563                 method patt4 =
18564                   fun f ->
18565                     function
18566                     | (Ast.PaApp (_,
18567                          (Ast.PaApp (_,
18568                             (Ast.PaId (_, (Ast.IdUid (_, "::")))), _)),
18569                          _)
18570                        as p) ->
18571                         let (pl, c) = o#mk_patt_list p
18572                         in
18573                           (match c with
18574                            | None ->
18575                                pp f "@[<2>[@ %a@]@ ]" (list o#patt ";@ ") pl
18576                            | Some x ->
18577                                pp f "@[<2>%a@]" (list o#patt5 " ::@ ")
18578                                  (pl @ [ x ]))
18579                     | p -> o#patt5 f p
18580                   
18581                 method patt5 =
18582                   fun f ->
18583                     function
18584                     | (Ast.PaApp (_,
18585                          (Ast.PaApp (_,
18586                             (Ast.PaId (_, (Ast.IdUid (_, "::")))), _)),
18587                          _)
18588                        as p) -> o#simple_patt f p
18589                     | Ast.PaLaz (_, p) ->
18590                         pp f "@[<2>lazy %a@]" o#simple_patt p
18591                     | Ast.PaApp (_, x, y) ->
18592                         let (a, al) = get_patt_args x [ y ]
18593                         in
18594                           if not (Ast.is_patt_constructor a)
18595                           then
18596                             Format.eprintf
18597                               "WARNING: strange pattern application of a non constructor@."
18598                           else
18599                             if curry_constr
18600                             then
18601                               pp f "@[<2>%a@]" (list o#simple_patt "@ ")
18602                                 (a :: al)
18603                             else
18604                               (match al with
18605                                | [ Ast.PaTup (_, _) ] ->
18606                                    pp f "@[<2>%a@ (%a)@]" o#simple_patt x
18607                                      o#patt y
18608                                | [ _ ] ->
18609                                    pp f "@[<2>%a@ %a@]" o#patt5 x
18610                                      o#simple_patt y
18611                                | al ->
18612                                    pp f "@[<2>%a@ (%a)@]" o#patt5 a
18613                                      (list o#simple_patt ",@ ") al)
18614                     | p -> o#simple_patt f p
18615                   
18616                 method simple_patt =
18617                   fun f p ->
18618                     let () = o#node f p Ast.loc_of_patt
18619                     in
18620                       match p with
18621                       | Ast.PaNil _ -> ()
18622                       | Ast.PaId (_, i) -> o#var_ident f i
18623                       | Ast.PaAnt (_, s) -> o#anti f s
18624                       | Ast.PaAny _ -> pp f "_"
18625                       | Ast.PaTup (_, p) -> pp f "@[<1>(%a)@]" o#patt3 p
18626                       | Ast.PaRec (_, p) -> pp f "@[<hv2>{@ %a@]@ }" o#patt p
18627                       | Ast.PaStr (_, s) -> pp f "\"%s\"" s
18628                       | Ast.PaTyc (_, p, t) ->
18629                           pp f "@[<1>(%a :@ %a)@]" o#patt p o#ctyp t
18630                       | Ast.PaNativeInt (_, s) -> o#numeric f s "n"
18631                       | Ast.PaInt64 (_, s) -> o#numeric f s "L"
18632                       | Ast.PaInt32 (_, s) -> o#numeric f s "l"
18633                       | Ast.PaInt (_, s) -> o#numeric f s ""
18634                       | Ast.PaFlo (_, s) -> o#numeric f s ""
18635                       | Ast.PaChr (_, s) -> pp f "'%s'" (ocaml_char s)
18636                       | Ast.PaLab (_, s, (Ast.PaNil _)) -> pp f "~%s" s
18637                       | Ast.PaVrn (_, s) -> pp f "`%a" o#var s
18638                       | Ast.PaTyp (_, i) -> pp f "@[<2>#%a@]" o#ident i
18639                       | Ast.PaArr (_, p) -> pp f "@[<2>[|@ %a@]@ |]" o#patt p
18640                       | Ast.PaLab (_, s, p) ->
18641                           pp f "@[<2>~%s:@ (%a)@]" s o#patt p
18642                       | Ast.PaOlb (_, s, (Ast.PaNil _)) -> pp f "?%s" s
18643                       | Ast.PaOlb (_, "", p) ->
18644                           pp f "@[<2>?(%a)@]" o#patt_tycon p
18645                       | Ast.PaOlb (_, s, p) ->
18646                           pp f "@[<2>?%s:@,@[<1>(%a)@]@]" s o#patt_tycon p
18647                       | Ast.PaOlbi (_, "", p, e) ->
18648                           pp f "@[<2>?(%a =@ %a)@]" o#patt_tycon p o#expr e
18649                       | Ast.PaOlbi (_, s, p, e) ->
18650                           pp f "@[<2>?%s:@,@[<1>(%a =@ %a)@]@]" s
18651                             o#patt_tycon p o#expr e
18652                       | (Ast.PaApp (_, _, _) | Ast.PaAli (_, _, _) |
18653                            Ast.PaOrp (_, _, _) | Ast.PaRng (_, _, _) |
18654                            Ast.PaCom (_, _, _) | Ast.PaSem (_, _, _) |
18655                            Ast.PaEq (_, _, _) | Ast.PaLaz (_, _)
18656                          as p) -> pp f "@[<1>(%a)@]" o#patt p
18657                   
18658                 method patt_tycon =
18659                   fun f ->
18660                     function
18661                     | Ast.PaTyc (_, p, t) ->
18662                         pp f "%a :@ %a" o#patt p o#ctyp t
18663                     | p -> o#patt f p
18664                   
18665                 method simple_ctyp =
18666                   fun f t ->
18667                     let () = o#node f t Ast.loc_of_ctyp
18668                     in
18669                       match t with
18670                       | Ast.TyId (_, i) -> o#ident f i
18671                       | Ast.TyAnt (_, s) -> o#anti f s
18672                       | Ast.TyAny _ -> pp f "_"
18673                       | Ast.TyLab (_, s, t) ->
18674                           pp f "@[<2>%s:@ %a@]" s o#simple_ctyp t
18675                       | Ast.TyOlb (_, s, t) ->
18676                           pp f "@[<2>?%s:@ %a@]" s o#simple_ctyp t
18677                       | Ast.TyObj (_, (Ast.TyNil _), Ast.BFalse) ->
18678                           pp f "< >"
18679                       | Ast.TyObj (_, (Ast.TyNil _), Ast.BTrue) ->
18680                           pp f "< .. >"
18681                       | Ast.TyObj (_, t, Ast.BTrue) ->
18682                           pp f "@[<0>@[<2><@ %a;@ ..@]@ >@]" o#ctyp t
18683                       | Ast.TyObj (_, t, Ast.BFalse) ->
18684                           pp f "@[<0>@[<2><@ %a@]@ >@]" o#ctyp t
18685                       | Ast.TyQuo (_, s) -> pp f "'%a" o#var s
18686                       | Ast.TyRec (_, t) -> pp f "@[<2>{@ %a@]@ }" o#ctyp t
18687                       | Ast.TySum (_, t) -> pp f "@[<0>%a@]" o#sum_type t
18688                       | Ast.TyTup (_, t) -> pp f "@[<1>(%a)@]" o#ctyp t
18689                       | Ast.TyVrnEq (_, t) ->
18690                           pp f "@[<2>[@ %a@]@ ]" o#sum_type t
18691                       | Ast.TyVrnInf (_, t) ->
18692                           pp f "@[<2>[<@ %a@]@,]" o#sum_type t
18693                       | Ast.TyVrnInfSup (_, t1, t2) ->
18694                           let (a, al) = get_ctyp_args t2 []
18695                           in
18696                             pp f "@[<2>[<@ %a@ >@ %a@]@ ]" o#sum_type t1
18697                               (list o#simple_ctyp "@ ") (a :: al)
18698                       | Ast.TyVrnSup (_, t) ->
18699                           pp f "@[<2>[>@ %a@]@,]" o#sum_type t
18700                       | Ast.TyCls (_, i) -> pp f "@[<2>#%a@]" o#ident i
18701                       | Ast.TyMan (_, t1, t2) ->
18702                           pp f "@[<2>%a =@ %a@]" o#simple_ctyp t1
18703                             o#simple_ctyp t2
18704                       | Ast.TyVrn (_, s) -> pp f "`%a" o#var s
18705                       | Ast.TySta (_, t1, t2) ->
18706                           pp f "%a *@ %a" o#simple_ctyp t1 o#simple_ctyp t2
18707                       | Ast.TyNil _ -> assert false
18708                       | t -> pp f "@[<1>(%a)@]" o#ctyp t
18709                   
18710                 method ctyp =
18711                   fun f t ->
18712                     let () = o#node f t Ast.loc_of_ctyp
18713                     in
18714                       match t with
18715                       | Ast.TyAli (_, t1, t2) ->
18716                           pp f "@[<2>%a@ as@ %a@]" o#simple_ctyp t1
18717                             o#simple_ctyp t2
18718                       | Ast.TyArr (_, t1, t2) ->
18719                           pp f "@[<2>%a@ ->@ %a@]" o#ctyp1 t1 o#ctyp t2
18720                       | Ast.TyQuP (_, s) -> pp f "+'%a" o#var s
18721                       | Ast.TyQuM (_, s) -> pp f "-'%a" o#var s
18722                       | Ast.TyOr (_, t1, t2) ->
18723                           pp f "%a@ | %a" o#ctyp t1 o#ctyp t2
18724                       | Ast.TyCol (_, t1, (Ast.TyMut (_, t2))) ->
18725                           pp f "@[mutable@ %a :@ %a@]" o#ctyp t1 o#ctyp t2
18726                       | Ast.TyCol (_, t1, t2) ->
18727                           pp f "@[<2>%a :@ %a@]" o#ctyp t1 o#ctyp t2
18728                       | Ast.TySem (_, t1, t2) ->
18729                           pp f "%a;@ %a" o#ctyp t1 o#ctyp t2
18730                       | Ast.TyOf (_, t, (Ast.TyNil _)) -> o#ctyp f t
18731                       | Ast.TyOf (_, t1, t2) ->
18732                           pp f "@[<h>%a@ @[<3>of@ %a@]@]" o#ctyp t1
18733                             o#constructor_type t2
18734                       | Ast.TyOfAmp (_, t1, t2) ->
18735                           pp f "@[<h>%a@ @[<3>of &@ %a@]@]" o#ctyp t1
18736                             o#constructor_type t2
18737                       | Ast.TyAnd (_, t1, t2) ->
18738                           pp f "%a@ and %a" o#ctyp t1 o#ctyp t2
18739                       | Ast.TyMut (_, t) ->
18740                           pp f "@[<2>mutable@ %a@]" o#ctyp t
18741                       | Ast.TyAmp (_, t1, t2) ->
18742                           pp f "%a@ &@ %a" o#ctyp t1 o#ctyp t2
18743                       | Ast.TyDcl (_, tn, tp, te, cl) ->
18744                           (pp f "@[<2>%a%a@]" o#type_params tp o#var tn;
18745                            (match te with
18746                             | Ast.TyNil _ -> ()
18747                             | _ -> pp f " =@ %a" o#ctyp te);
18748                            if cl <> []
18749                            then pp f "@ %a" (list o#constrain "@ ") cl
18750                            else ())
18751                       | t -> o#ctyp1 f t
18752                   
18753                 method ctyp1 =
18754                   fun f ->
18755                     function
18756                     | Ast.TyApp (_, t1, t2) ->
18757                         (match get_ctyp_args t1 [ t2 ] with
18758                          | (_, [ _ ]) ->
18759                              pp f "@[<2>%a@ %a@]" o#simple_ctyp t2
18760                                o#simple_ctyp t1
18761                          | (a, al) ->
18762                              pp f "@[<2>(%a)@ %a@]" (list o#ctyp ",@ ") al
18763                                o#simple_ctyp a)
18764                     | Ast.TyPol (_, t1, t2) ->
18765                         let (a, al) = get_ctyp_args t1 []
18766                         in
18767                           pp f "@[<2>%a.@ %a@]" (list o#ctyp "@ ") (a :: al)
18768                             o#ctyp t2
18769                     | Ast.TyPrv (_, t) ->
18770                         pp f "@[private@ %a@]" o#simple_ctyp t
18771                     | t -> o#simple_ctyp f t
18772                   
18773                 method constructor_type =
18774                   fun f t ->
18775                     match t with
18776                     | Ast.TyAnd (loc, t1, t2) ->
18777                         let () = o#node f t (fun _ -> loc)
18778                         in
18779                           pp f "%a@ * %a" o#constructor_type t1
18780                             o#constructor_type t2
18781                     | Ast.TyArr (_, _, _) -> pp f "(%a)" o#ctyp t
18782                     | t -> o#ctyp f t
18783                   
18784                 method sig_item =
18785                   fun f sg ->
18786                     let () = o#node f sg Ast.loc_of_sig_item
18787                     in
18788                       match sg with
18789                       | Ast.SgNil _ -> ()
18790                       | Ast.SgSem (_, sg, (Ast.SgNil _)) |
18791                           Ast.SgSem (_, (Ast.SgNil _), sg) -> o#sig_item f sg
18792                       | Ast.SgSem (_, sg1, sg2) ->
18793                           (o#sig_item f sg1; cut f; o#sig_item f sg2)
18794                       | Ast.SgExc (_, t) ->
18795                           pp f "@[<2>exception@ %a%(%)@]" o#ctyp t semisep
18796                       | Ast.SgExt (_, s, t, sl) ->
18797                           pp f "@[<2>external@ %a :@ %a =@ %a%(%)@]" 
18798                             o#var s o#ctyp t (meta_list o#quoted_string "@ ")
18799                             sl semisep
18800                       | Ast.SgMod (_, s1, (Ast.MtFun (_, s2, mt1, mt2))) ->
18801                           let rec loop accu =
18802                             (function
18803                              | Ast.MtFun (_, s, mt1, mt2) ->
18804                                  loop ((s, mt1) :: accu) mt2
18805                              | mt -> ((List.rev accu), mt)) in
18806                           let (al, mt) = loop [ (s2, mt1) ] mt2
18807                           in
18808                             pp f "@[<2>module %a@ @[<0>%a@] :@ %a%(%)@]"
18809                               o#var s1 o#functor_args al o#module_type mt
18810                               semisep
18811                       | Ast.SgMod (_, s, mt) ->
18812                           pp f "@[<2>module %a :@ %a%(%)@]" o#var s
18813                             o#module_type mt semisep
18814                       | Ast.SgMty (_, s, (Ast.MtNil _)) ->
18815                           pp f "@[<2>module type %a%(%)@]" o#var s semisep
18816                       | Ast.SgMty (_, s, mt) ->
18817                           pp f "@[<2>module type %a =@ %a%(%)@]" o#var s
18818                             o#module_type mt semisep
18819                       | Ast.SgOpn (_, sl) ->
18820                           pp f "@[<2>open@ %a%(%)@]" o#ident sl semisep
18821                       | Ast.SgTyp (_, t) ->
18822                           pp f "@[<hv0>@[<hv2>type %a@]%(%)@]" o#ctyp t
18823                             semisep
18824                       | Ast.SgVal (_, s, t) ->
18825                           pp f "@[<2>%s %a :@ %a%(%)@]" value_val o#var s
18826                             o#ctyp t semisep
18827                       | Ast.SgInc (_, mt) ->
18828                           pp f "@[<2>include@ %a%(%)@]" o#module_type mt
18829                             semisep
18830                       | Ast.SgClt (_, ct) ->
18831                           pp f "@[<2>class type %a%(%)@]" o#class_type ct
18832                             semisep
18833                       | Ast.SgCls (_, ce) ->
18834                           pp f "@[<2>class %a%(%)@]" o#class_type ce semisep
18835                       | Ast.SgRecMod (_, mb) ->
18836                           pp f "@[<2>module rec %a%(%)@]"
18837                             o#module_rec_binding mb semisep
18838                       | Ast.SgDir (_, _, _) -> ()
18839                       | Ast.SgAnt (_, s) -> pp f "%a%(%)" o#anti s semisep
18840                   
18841                 method str_item =
18842                   fun f st ->
18843                     let () = o#node f st Ast.loc_of_str_item
18844                     in
18845                       match st with
18846                       | Ast.StNil _ -> ()
18847                       | Ast.StSem (_, st, (Ast.StNil _)) |
18848                           Ast.StSem (_, (Ast.StNil _), st) -> o#str_item f st
18849                       | Ast.StSem (_, st1, st2) ->
18850                           (o#str_item f st1; cut f; o#str_item f st2)
18851                       | Ast.StExc (_, t, Ast.ONone) ->
18852                           pp f "@[<2>exception@ %a%(%)@]" o#ctyp t semisep
18853                       | Ast.StExc (_, t, (Ast.OSome sl)) ->
18854                           pp f "@[<2>exception@ %a =@ %a%(%)@]" o#ctyp t
18855                             o#ident sl semisep
18856                       | Ast.StExt (_, s, t, sl) ->
18857                           pp f "@[<2>external@ %a :@ %a =@ %a%(%)@]" 
18858                             o#var s o#ctyp t (meta_list o#quoted_string "@ ")
18859                             sl semisep
18860                       | Ast.StMod (_, s1, (Ast.MeFun (_, s2, mt1, me))) ->
18861                           (match o#module_expr_get_functor_args [ (s2, mt1) ]
18862                                    me
18863                            with
18864                            | (al, me, Some mt2) ->
18865                                pp f
18866                                  "@[<2>module %a@ @[<0>%a@] :@ %a =@ %a%(%)@]"
18867                                  o#var s1 o#functor_args al o#module_type mt2
18868                                  o#module_expr me semisep
18869                            | (al, me, _) ->
18870                                pp f "@[<2>module %a@ @[<0>%a@] =@ %a%(%)@]"
18871                                  o#var s1 o#functor_args al o#module_expr me
18872                                  semisep)
18873                       | Ast.StMod (_, s, (Ast.MeTyc (_, me, mt))) ->
18874                           pp f "@[<2>module %a :@ %a =@ %a%(%)@]" o#var s
18875                             o#module_type mt o#module_expr me semisep
18876                       | Ast.StMod (_, s, me) ->
18877                           pp f "@[<2>module %a =@ %a%(%)@]" o#var s
18878                             o#module_expr me semisep
18879                       | Ast.StMty (_, s, mt) ->
18880                           pp f "@[<2>module type %a =@ %a%(%)@]" o#var s
18881                             o#module_type mt semisep
18882                       | Ast.StOpn (_, sl) ->
18883                           pp f "@[<2>open@ %a%(%)@]" o#ident sl semisep
18884                       | Ast.StTyp (_, t) ->
18885                           pp f "@[<hv0>@[<hv2>type %a@]%(%)@]" o#ctyp t
18886                             semisep
18887                       | Ast.StVal (_, r, bi) ->
18888                           pp f "@[<2>%s %a%a%(%)@]" value_let o#rec_flag r
18889                             o#binding bi semisep
18890                       | Ast.StExp (_, e) ->
18891                           pp f "@[<2>let _ =@ %a%(%)@]" o#expr e semisep
18892                       | Ast.StInc (_, me) ->
18893                           pp f "@[<2>include@ %a%(%)@]" o#simple_module_expr
18894                             me semisep
18895                       | Ast.StClt (_, ct) ->
18896                           pp f "@[<2>class type %a%(%)@]" o#class_type ct
18897                             semisep
18898                       | Ast.StCls (_, ce) ->
18899                           pp f "@[<hv2>class %a%(%)@]" o#class_declaration ce
18900                             semisep
18901                       | Ast.StRecMod (_, mb) ->
18902                           pp f "@[<2>module rec %a%(%)@]"
18903                             o#module_rec_binding mb semisep
18904                       | Ast.StDir (_, _, _) -> ()
18905                       | Ast.StAnt (_, s) -> pp f "%a%(%)" o#anti s semisep
18906                       | Ast.StExc (_, _, (Ast.OAnt _)) -> assert false
18907                   
18908                 method module_type =
18909                   fun f mt ->
18910                     let () = o#node f mt Ast.loc_of_module_type
18911                     in
18912                       match mt with
18913                       | Ast.MtNil _ -> assert false
18914                       | Ast.MtId (_, i) -> o#ident f i
18915                       | Ast.MtAnt (_, s) -> o#anti f s
18916                       | Ast.MtFun (_, s, mt1, mt2) ->
18917                           pp f "@[<2>functor@ @[<1>(%a :@ %a)@]@ ->@ %a@]"
18918                             o#var s o#module_type mt1 o#module_type mt2
18919                       | Ast.MtQuo (_, s) -> pp f "'%a" o#var s
18920                       | Ast.MtSig (_, sg) ->
18921                           pp f "@[<hv0>@[<hv2>sig@ %a@]@ end@]" o#sig_item sg
18922                       | Ast.MtWit (_, mt, wc) ->
18923                           pp f "@[<2>%a@ with@ %a@]" o#module_type mt
18924                             o#with_constraint wc
18925                   
18926                 method with_constraint =
18927                   fun f wc ->
18928                     let () = o#node f wc Ast.loc_of_with_constr
18929                     in
18930                       match wc with
18931                       | Ast.WcNil _ -> ()
18932                       | Ast.WcTyp (_, t1, t2) ->
18933                           pp f "@[<2>type@ %a =@ %a@]" o#ctyp t1 o#ctyp t2
18934                       | Ast.WcMod (_, i1, i2) ->
18935                           pp f "@[<2>module@ %a =@ %a@]" o#ident i1 o#ident
18936                             i2
18937                       | Ast.WcAnd (_, wc1, wc2) ->
18938                           (o#with_constraint f wc1;
18939                            pp f andsep;
18940                            o#with_constraint f wc2)
18941                       | Ast.WcAnt (_, s) -> o#anti f s
18942                   
18943                 method module_expr =
18944                   fun f me ->
18945                     let () = o#node f me Ast.loc_of_module_expr
18946                     in
18947                       match me with
18948                       | Ast.MeNil _ -> assert false
18949                       | Ast.MeTyc (_, (Ast.MeStr (_, st)),
18950                           (Ast.MtSig (_, sg))) ->
18951                           pp f
18952                             "@[<2>@[<hv2>struct@ %a@]@ end :@ @[<hv2>sig@ %a@]@ end@]"
18953                             o#str_item st o#sig_item sg
18954                       | _ -> o#simple_module_expr f me
18955                   
18956                 method simple_module_expr =
18957                   fun f me ->
18958                     let () = o#node f me Ast.loc_of_module_expr
18959                     in
18960                       match me with
18961                       | Ast.MeNil _ -> assert false
18962                       | Ast.MeId (_, i) -> o#ident f i
18963                       | Ast.MeAnt (_, s) -> o#anti f s
18964                       | Ast.MeApp (_, me1, me2) ->
18965                           pp f "@[<2>%a@,(%a)@]" o#module_expr me1
18966                             o#module_expr me2
18967                       | Ast.MeFun (_, s, mt, me) ->
18968                           pp f "@[<2>functor@ @[<1>(%a :@ %a)@]@ ->@ %a@]"
18969                             o#var s o#module_type mt o#module_expr me
18970                       | Ast.MeStr (_, st) ->
18971                           pp f "@[<hv0>@[<hv2>struct@ %a@]@ end@]" o#str_item
18972                             st
18973                       | Ast.MeTyc (_, me, mt) ->
18974                           pp f "@[<1>(%a :@ %a)@]" o#module_expr me
18975                             o#module_type mt
18976                   
18977                 method class_expr =
18978                   fun f ce ->
18979                     let () = o#node f ce Ast.loc_of_class_expr
18980                     in
18981                       match ce with
18982                       | Ast.CeApp (_, ce, e) ->
18983                           pp f "@[<2>%a@ %a@]" o#class_expr ce o#expr e
18984                       | Ast.CeCon (_, Ast.BFalse, i, (Ast.TyNil _)) ->
18985                           pp f "@[<2>%a@]" o#ident i
18986                       | Ast.CeCon (_, Ast.BFalse, i, t) ->
18987                           pp f "@[<2>@[<1>[%a]@]@ %a@]" o#class_params t
18988                             o#ident i
18989                       | Ast.CeCon (_, Ast.BTrue, (Ast.IdLid (_, i)),
18990                           (Ast.TyNil _)) -> pp f "@[<2>virtual@ %a@]" o#var i
18991                       | Ast.CeCon (_, Ast.BTrue, (Ast.IdLid (_, i)), t) ->
18992                           pp f "@[<2>virtual@ @[<1>[%a]@]@ %a@]"
18993                             o#class_params t o#var i
18994                       | Ast.CeFun (_, p, ce) ->
18995                           pp f "@[<2>fun@ %a@ ->@ %a@]" o#simple_patt p
18996                             o#class_expr ce
18997                       | Ast.CeLet (_, r, bi, ce) ->
18998                           pp f "@[<2>let %a%a@]@ @[<2>in@ %a@]" o#rec_flag r
18999                             o#binding bi o#class_expr ce
19000                       | Ast.CeStr (_, (Ast.PaNil _), cst) ->
19001                           pp f "@[<hv0>@[<hv2>object %a@]@ end@]"
19002                             o#class_str_item cst
19003                       | Ast.CeStr (_, p, cst) ->
19004                           pp f
19005                             "@[<hv0>@[<hv2>object @[<1>(%a)@]@ %a@]@ end@]"
19006                             o#patt p o#class_str_item cst
19007                       | Ast.CeTyc (_, ce, ct) ->
19008                           pp f "@[<1>(%a :@ %a)@]" o#class_expr ce
19009                             o#class_type ct
19010                       | Ast.CeAnt (_, s) -> o#anti f s
19011                       | Ast.CeAnd (_, ce1, ce2) ->
19012                           (o#class_expr f ce1;
19013                            pp f andsep;
19014                            o#class_expr f ce2)
19015                       | Ast.CeEq (_, ce1, (Ast.CeFun (_, p, ce2))) when
19016                           is_irrefut_patt p ->
19017                           pp f "@[<2>%a@ %a" o#class_expr ce1
19018                             o#patt_class_expr_fun_args (p, ce2)
19019                       | Ast.CeEq (_, ce1, ce2) ->
19020                           pp f "@[<2>%a =@]@ %a" o#class_expr ce1
19021                             o#class_expr ce2
19022                       | _ -> assert false
19023                   
19024                 method class_type =
19025                   fun f ct ->
19026                     let () = o#node f ct Ast.loc_of_class_type
19027                     in
19028                       match ct with
19029                       | Ast.CtCon (_, Ast.BFalse, i, (Ast.TyNil _)) ->
19030                           pp f "@[<2>%a@]" o#ident i
19031                       | Ast.CtCon (_, Ast.BFalse, i, t) ->
19032                           pp f "@[<2>[@,%a@]@,]@ %a" o#class_params t 
19033                             o#ident i
19034                       | Ast.CtCon (_, Ast.BTrue, (Ast.IdLid (_, i)),
19035                           (Ast.TyNil _)) -> pp f "@[<2>virtual@ %a@]" o#var i
19036                       | Ast.CtCon (_, Ast.BTrue, (Ast.IdLid (_, i)), t) ->
19037                           pp f "@[<2>virtual@ [@,%a@]@,]@ %a" o#class_params
19038                             t o#var i
19039                       | Ast.CtFun (_, t, ct) ->
19040                           pp f "@[<2>%a@ ->@ %a@]" o#simple_ctyp t
19041                             o#class_type ct
19042                       | Ast.CtSig (_, (Ast.TyNil _), csg) ->
19043                           pp f "@[<hv0>@[<hv2>object@ %a@]@ end@]"
19044                             o#class_sig_item csg
19045                       | Ast.CtSig (_, t, csg) ->
19046                           pp f
19047                             "@[<hv0>@[<hv2>object @[<1>(%a)@]@ %a@]@ end@]"
19048                             o#ctyp t o#class_sig_item csg
19049                       | Ast.CtAnt (_, s) -> o#anti f s
19050                       | Ast.CtAnd (_, ct1, ct2) ->
19051                           (o#class_type f ct1;
19052                            pp f andsep;
19053                            o#class_type f ct2)
19054                       | Ast.CtCol (_, ct1, ct2) ->
19055                           pp f "%a :@ %a" o#class_type ct1 o#class_type ct2
19056                       | Ast.CtEq (_, ct1, ct2) ->
19057                           pp f "%a =@ %a" o#class_type ct1 o#class_type ct2
19058                       | _ -> assert false
19059                   
19060                 method class_sig_item =
19061                   fun f csg ->
19062                     let () = o#node f csg Ast.loc_of_class_sig_item
19063                     in
19064                       match csg with
19065                       | Ast.CgNil _ -> ()
19066                       | Ast.CgSem (_, csg, (Ast.CgNil _)) |
19067                           Ast.CgSem (_, (Ast.CgNil _), csg) ->
19068                           o#class_sig_item f csg
19069                       | Ast.CgSem (_, csg1, csg2) ->
19070                           (o#class_sig_item f csg1;
19071                            cut f;
19072                            o#class_sig_item f csg2)
19073                       | Ast.CgCtr (_, t1, t2) ->
19074                           pp f "@[<2>constraint@ %a =@ %a%(%)@]" o#ctyp t1
19075                             o#ctyp t2 semisep
19076                       | Ast.CgInh (_, ct) ->
19077                           pp f "@[<2>inherit@ %a%(%)@]" o#class_type ct
19078                             semisep
19079                       | Ast.CgMth (_, s, pr, t) ->
19080                           pp f "@[<2>method %a%a :@ %a%(%)@]" o#private_flag
19081                             pr o#var s o#ctyp t semisep
19082                       | Ast.CgVir (_, s, pr, t) ->
19083                           pp f "@[<2>method virtual %a%a :@ %a%(%)@]"
19084                             o#private_flag pr o#var s o#ctyp t semisep
19085                       | Ast.CgVal (_, s, mu, vi, t) ->
19086                           pp f "@[<2>%s %a%a%a :@ %a%(%)@]" value_val
19087                             o#mutable_flag mu o#virtual_flag vi o#var s
19088                             o#ctyp t semisep
19089                       | Ast.CgAnt (_, s) -> pp f "%a%(%)" o#anti s semisep
19090                   
19091                 method class_str_item =
19092                   fun f cst ->
19093                     let () = o#node f cst Ast.loc_of_class_str_item
19094                     in
19095                       match cst with
19096                       | Ast.CrNil _ -> ()
19097                       | Ast.CrSem (_, cst, (Ast.CrNil _)) |
19098                           Ast.CrSem (_, (Ast.CrNil _), cst) ->
19099                           o#class_str_item f cst
19100                       | Ast.CrSem (_, cst1, cst2) ->
19101                           (o#class_str_item f cst1;
19102                            cut f;
19103                            o#class_str_item f cst2)
19104                       | Ast.CrCtr (_, t1, t2) ->
19105                           pp f "@[<2>constraint %a =@ %a%(%)@]" o#ctyp t1
19106                             o#ctyp t2 semisep
19107                       | Ast.CrInh (_, ce, "") ->
19108                           pp f "@[<2>inherit@ %a%(%)@]" o#class_expr ce
19109                             semisep
19110                       | Ast.CrInh (_, ce, s) ->
19111                           pp f "@[<2>inherit@ %a as@ %a%(%)@]" o#class_expr
19112                             ce o#var s semisep
19113                       | Ast.CrIni (_, e) ->
19114                           pp f "@[<2>initializer@ %a%(%)@]" o#expr e semisep
19115                       | Ast.CrMth (_, s, pr, e, (Ast.TyNil _)) ->
19116                           pp f "@[<2>method %a%a =@ %a%(%)@]" o#private_flag
19117                             pr o#var s o#expr e semisep
19118                       | Ast.CrMth (_, s, pr, e, t) ->
19119                           pp f "@[<2>method %a%a :@ %a =@ %a%(%)@]"
19120                             o#private_flag pr o#var s o#ctyp t o#expr e
19121                             semisep
19122                       | Ast.CrVir (_, s, pr, t) ->
19123                           pp f "@[<2>method virtual@ %a%a :@ %a%(%)@]"
19124                             o#private_flag pr o#var s o#ctyp t semisep
19125                       | Ast.CrVvr (_, s, mu, t) ->
19126                           pp f "@[<2>%s virtual %a%a :@ %a%(%)@]" value_val
19127                             o#mutable_flag mu o#var s o#ctyp t semisep
19128                       | Ast.CrVal (_, s, mu, e) ->
19129                           pp f "@[<2>%s %a%a =@ %a%(%)@]" value_val
19130                             o#mutable_flag mu o#var s o#expr e semisep
19131                       | Ast.CrAnt (_, s) -> pp f "%a%(%)" o#anti s semisep
19132                   
19133                 method implem =
19134                   fun f st ->
19135                     match st with
19136                     | Ast.StExp (_, e) ->
19137                         pp f "@[<0>%a%(%)@]@." o#expr e semisep
19138                     | st -> pp f "@[<v0>%a@]@." o#str_item st
19139                   
19140                 method interf = fun f sg -> pp f "@[<v0>%a@]@." o#sig_item sg
19141                   
19142               end
19143               
19144             let with_outfile output_file fct arg =
19145               let call close f =
19146                 ((try fct f arg with | exn -> (close (); raise exn));
19147                  close ())
19148               in
19149                 match output_file with
19150                 | None -> call (fun () -> ()) std_formatter
19151                 | Some s ->
19152                     let oc = open_out s in
19153                     let f = formatter_of_out_channel oc
19154                     in call (fun () -> close_out oc) f
19155               
19156             let print output_file fct =
19157               let o = new printer () in with_outfile output_file (fct o)
19158               
19159             let print_interf ?input_file:(_) ?output_file sg =
19160               print output_file (fun o -> o#interf) sg
19161               
19162             let print_implem ?input_file:(_) ?output_file st =
19163               print output_file (fun o -> o#implem) st
19164               
19165           end
19166           
19167         module MakeMore (Syntax : Sig.Camlp4Syntax) : Sig.Printer(Syntax.
19168           Ast).S =
19169           struct
19170             include Make(Syntax)
19171               
19172             let semisep : sep ref = ref ("@\n" : sep)
19173               
19174             let margin = ref 78
19175               
19176             let comments = ref true
19177               
19178             let locations = ref false
19179               
19180             let curry_constr = ref false
19181               
19182             let print output_file fct =
19183               let o =
19184                 new printer ~comments: !comments ~curry_constr: !curry_constr
19185                   () in
19186               let o = o#set_semisep !semisep in
19187               let o = if !locations then o#set_loc_and_comments else o
19188               in
19189                 with_outfile output_file
19190                   (fun f ->
19191                      let () = Format.pp_set_margin f !margin
19192                      in Format.fprintf f "@[<v0>%a@]@." (fct o))
19193               
19194             let print_interf ?input_file:(_) ?output_file sg =
19195               print output_file (fun o -> o#interf) sg
19196               
19197             let print_implem ?input_file:(_) ?output_file st =
19198               print output_file (fun o -> o#implem) st
19199               
19200             let check_sep s =
19201               if String.contains s '%'
19202               then failwith "-sep Format error, % found in string"
19203               else (Obj.magic (Struct.Token.Eval.string s : string) : sep)
19204               
19205             let _ =
19206               Options.add "-l" (Arg.Int (fun i -> margin := i))
19207                 "<length> line length for pretty printing."
19208               
19209             let _ =
19210               Options.add "-ss" (Arg.Unit (fun () -> semisep := ";;"))
19211                 " Print double semicolons."
19212               
19213             let _ =
19214               Options.add "-no_ss" (Arg.Unit (fun () -> semisep := ""))
19215                 " Do not print double semicolons (default)."
19216               
19217             let _ =
19218               Options.add "-sep"
19219                 (Arg.String (fun s -> semisep := check_sep s))
19220                 " Use this string between phrases."
19221               
19222             let _ =
19223               Options.add "-curry-constr" (Arg.Set curry_constr)
19224                 "Use currified constructors."
19225               
19226             let _ =
19227               Options.add "-no_comments" (Arg.Clear comments)
19228                 "Do not add comments."
19229               
19230             let _ =
19231               Options.add "-add_locations" (Arg.Set locations)
19232                 "Add locations as comment."
19233               
19234           end
19235           
19236       end
19237       
19238     module OCamlr :
19239       sig
19240         module Id : Sig.Id
19241           
19242         module Make (Syntax : Sig.Camlp4Syntax) :
19243           sig
19244             open Format
19245               
19246             include Sig.Camlp4Syntax with module Loc = Syntax.Loc
19247               and module Token = Syntax.Token and module Ast = Syntax.Ast
19248               and module Gram = Syntax.Gram
19249               
19250             class printer :
19251               ?curry_constr: bool ->
19252                 ?comments: bool ->
19253                   unit -> object ('a) inherit OCaml.Make(Syntax).printer
19254                                          end
19255               
19256             val with_outfile :
19257               string option -> (formatter -> 'a -> unit) -> 'a -> unit
19258               
19259             val print :
19260               string option ->
19261                 (printer -> formatter -> 'a -> unit) -> 'a -> unit
19262               
19263           end
19264           
19265         module MakeMore (Syntax : Sig.Camlp4Syntax) : Sig.Printer(Syntax.
19266           Ast).S
19267           
19268       end =
19269       struct
19270         open Format
19271           
19272         module Id =
19273           struct
19274             let name = "Camlp4.Printers.OCamlr"
19275               
19276             let version = Sys.ocaml_version
19277               
19278           end
19279           
19280         module Make (Syntax : Sig.Camlp4Syntax) =
19281           struct
19282             include Syntax
19283               
19284             open Sig
19285               
19286             module PP_o = OCaml.Make(Syntax)
19287               
19288             open PP_o
19289               
19290             let pp = fprintf
19291               
19292             let is_keyword =
19293               let keywords = [ "where" ]
19294               and not_keywords = [ "false"; "function"; "true"; "val" ]
19295               in
19296                 fun s ->
19297                   (not (List.mem s not_keywords)) &&
19298                     ((is_keyword s) || (List.mem s keywords))
19299               
19300             class printer ?curry_constr:(init_curry_constr = true)
19301                     ?(comments = true) () =
19302               object (o)
19303                 inherit
19304                   PP_o.printer ~curry_constr: init_curry_constr ~comments () as
19305                   super
19306                   
19307                 val semisep = (";" : sep)
19308                   
19309                 val andsep = ("@]@ @[<2>and@ " : sep)
19310                   
19311                 val value_val = "value"
19312                   
19313                 val value_let = "value"
19314                   
19315                 val mode = if comments then `comments else `no_comments
19316                   
19317                 val curry_constr = init_curry_constr
19318                   
19319                 val first_match_case = true
19320                   
19321                 method under_pipe = o
19322                   
19323                 method under_semi = o
19324                   
19325                 method reset_semi = o
19326                   
19327                 method reset = o
19328                   
19329                 method private unset_first_match_case =
19330                   {< first_match_case = false; >}
19331                   
19332                 method private set_first_match_case =
19333                   {< first_match_case = true; >}
19334                   
19335                 method seq =
19336                   fun f e ->
19337                     let rec self right f e =
19338                       let go_right = self right
19339                       and go_left = self false
19340                       in
19341                         match e with
19342                         | Ast.ExLet (_, r, bi, e1) ->
19343                             if right
19344                             then
19345                               pp f "@[<2>let %a%a@];@ %a" o#rec_flag r
19346                                 o#binding bi go_right e1
19347                             else pp f "(%a)" o#expr e
19348                         | Ast.ExSeq (_, e) -> go_right f e
19349                         | Ast.ExSem (_, e1, e2) ->
19350                             (pp f "%a;@ " go_left e1;
19351                              (match (right, e2) with
19352                               | (true, Ast.ExLet (_, r, bi, e3)) ->
19353                                   pp f "@[<2>let %a%a@];@ %a" o#rec_flag r
19354                                     o#binding bi go_right e3
19355                               | _ -> go_right f e2))
19356                         | e -> o#expr f e
19357                     in self true f e
19358                   
19359                 method var =
19360                   fun f ->
19361                     function
19362                     | "" -> pp f "$lid:\"\"$"
19363                     | "[]" -> pp f "[]"
19364                     | "()" -> pp f "()"
19365                     | " True" -> pp f "True"
19366                     | " False" -> pp f "False"
19367                     | v ->
19368                         (match lex_string v with
19369                          | LIDENT s | UIDENT s | ESCAPED_IDENT s when
19370                              is_keyword s -> pp f "%s__" s
19371                          | SYMBOL s -> pp f "( %s )" s
19372                          | LIDENT s | UIDENT s | ESCAPED_IDENT s ->
19373                              pp_print_string f s
19374                          | tok ->
19375                              failwith
19376                                (sprintf "Bad token used as an identifier: %s"
19377                                   (Token.to_string tok)))
19378                   
19379                 method type_params =
19380                   fun f ->
19381                     function
19382                     | [] -> ()
19383                     | [ x ] -> pp f "@ %a" o#ctyp x
19384                     | l -> pp f "@ @[<1>%a@]" (list o#ctyp "@ ") l
19385                   
19386                 method match_case =
19387                   fun f ->
19388                     function
19389                     | Ast.McNil _ -> pp f "@ []"
19390                     | m ->
19391                         pp f "@ [ %a ]" o#set_first_match_case#match_case_aux
19392                           m
19393                   
19394                 method match_case_aux =
19395                   fun f ->
19396                     function
19397                     | Ast.McNil _ -> ()
19398                     | Ast.McAnt (_, s) -> o#anti f s
19399                     | Ast.McOr (_, a1, a2) ->
19400                         pp f "%a%a" o#match_case_aux a1
19401                           o#unset_first_match_case#match_case_aux a2
19402                     | Ast.McArr (_, p, (Ast.ExNil _), e) ->
19403                         let () = if first_match_case then () else pp f "@ | "
19404                         in
19405                           pp f "@[<2>%a@ ->@ %a@]" o#patt p o#under_pipe#expr
19406                             e
19407                     | Ast.McArr (_, p, w, e) ->
19408                         let () = if first_match_case then () else pp f "@ | "
19409                         in
19410                           pp f "@[<2>%a@ when@ %a@ ->@ %a@]" o#patt p
19411                             o#under_pipe#expr w o#under_pipe#expr e
19412                   
19413                 method sum_type = fun f t -> pp f "@[<hv0>[ %a ]@]" o#ctyp t
19414                   
19415                 method ident =
19416                   fun f i ->
19417                     let () = o#node f i Ast.loc_of_ident
19418                     in
19419                       match i with
19420                       | Ast.IdApp (_, i1, i2) ->
19421                           pp f "%a@ %a" o#dot_ident i1 o#dot_ident i2
19422                       | i -> o#dot_ident f i
19423                   
19424                 method private dot_ident =
19425                   fun f i ->
19426                     let () = o#node f i Ast.loc_of_ident
19427                     in
19428                       match i with
19429                       | Ast.IdAcc (_, i1, i2) ->
19430                           pp f "%a.@,%a" o#dot_ident i1 o#dot_ident i2
19431                       | Ast.IdAnt (_, s) -> o#anti f s
19432                       | Ast.IdLid (_, s) | Ast.IdUid (_, s) -> o#var f s
19433                       | i -> pp f "(%a)" o#ident i
19434                   
19435                 method patt4 =
19436                   fun f ->
19437                     function
19438                     | (Ast.PaApp (_,
19439                          (Ast.PaApp (_,
19440                             (Ast.PaId (_, (Ast.IdUid (_, "::")))), _)),
19441                          _)
19442                        as p) ->
19443                         let (pl, c) = o#mk_patt_list p
19444                         in
19445                           (match c with
19446                            | None ->
19447                                pp f "@[<2>[@ %a@]@ ]" (list o#patt ";@ ") pl
19448                            | Some x ->
19449                                pp f "@[<2>[ %a ::@ %a ]@]"
19450                                  (list o#patt ";@ ") pl o#patt x)
19451                     | p -> super#patt4 f p
19452                   
19453                 method expr_list_cons =
19454                   fun _ f e ->
19455                     let (el, c) = o#mk_expr_list e
19456                     in
19457                       match c with
19458                       | None -> o#expr_list f el
19459                       | Some x ->
19460                           pp f "@[<2>[ %a ::@ %a ]@]" (list o#expr ";@ ") el
19461                             o#expr x
19462                   
19463                 method expr =
19464                   fun f e ->
19465                     let () = o#node f e Ast.loc_of_expr
19466                     in
19467                       match e with
19468                       | Ast.ExAss (_, e1, e2) ->
19469                           pp f "@[<2>%a@ :=@ %a@]" o#dot_expr e1 o#expr e2
19470                       | Ast.ExFun (_, (Ast.McArr (_, p, (Ast.ExNil _), e)))
19471                           when Ast.is_irrefut_patt p ->
19472                           pp f "@[<2>fun@ %a@]" o#patt_expr_fun_args (p, e)
19473                       | Ast.ExFun (_, a) ->
19474                           pp f "@[<hv0>fun%a@]" o#match_case a
19475                       | Ast.ExAsf _ -> pp f "@[<2>assert@ False@]"
19476                       | e -> super#expr f e
19477                   
19478                 method dot_expr =
19479                   fun f e ->
19480                     let () = o#node f e Ast.loc_of_expr
19481                     in
19482                       match e with
19483                       | Ast.ExAcc (_, e,
19484                           (Ast.ExId (_, (Ast.IdLid (_, "val"))))) ->
19485                           pp f "@[<2>%a.@,val@]" o#simple_expr e
19486                       | e -> super#dot_expr f e
19487                   
19488                 method ctyp =
19489                   fun f t ->
19490                     let () = o#node f t Ast.loc_of_ctyp
19491                     in
19492                       match t with
19493                       | Ast.TyDcl (_, tn, tp, te, cl) ->
19494                           (pp f "@[<2>%a%a@]" o#var tn o#type_params tp;
19495                            (match te with
19496                             | Ast.TyNil _ -> ()
19497                             | _ -> pp f " =@ %a" o#ctyp te);
19498                            if cl <> []
19499                            then pp f "@ %a" (list o#constrain "@ ") cl
19500                            else ())
19501                       | Ast.TyCol (_, t1, (Ast.TyMut (_, t2))) ->
19502                           pp f "@[%a :@ mutable %a@]" o#ctyp t1 o#ctyp t2
19503                       | t -> super#ctyp f t
19504                   
19505                 method simple_ctyp =
19506                   fun f t ->
19507                     let () = o#node f t Ast.loc_of_ctyp
19508                     in
19509                       match t with
19510                       | Ast.TyVrnEq (_, t) ->
19511                           pp f "@[<2>[ =@ %a@]@ ]" o#ctyp t
19512                       | Ast.TyVrnInf (_, t) ->
19513                           pp f "@[<2>[ <@ %a@]@,]" o#ctyp t
19514                       | Ast.TyVrnInfSup (_, t1, t2) ->
19515                           pp f "@[<2>[ <@ %a@ >@ %a@]@ ]" o#ctyp t1 o#ctyp t2
19516                       | Ast.TyVrnSup (_, t) ->
19517                           pp f "@[<2>[ >@ %a@]@,]" o#ctyp t
19518                       | Ast.TyMan (_, t1, t2) ->
19519                           pp f "@[<2>%a@ ==@ %a@]" o#simple_ctyp t1
19520                             o#simple_ctyp t2
19521                       | Ast.TyLab (_, s, t) ->
19522                           pp f "@[<2>~%s:@ %a@]" s o#simple_ctyp t
19523                       | t -> super#simple_ctyp f t
19524                   
19525                 method ctyp1 =
19526                   fun f ->
19527                     function
19528                     | Ast.TyApp (_, t1, t2) ->
19529                         (match get_ctyp_args t1 [ t2 ] with
19530                          | (_, [ _ ]) ->
19531                              pp f "@[<2>%a@ %a@]" o#simple_ctyp t1
19532                                o#simple_ctyp t2
19533                          | (a, al) ->
19534                              pp f "@[<2>%a@]" (list o#simple_ctyp "@ ")
19535                                (a :: al))
19536                     | Ast.TyPol (_, t1, t2) ->
19537                         let (a, al) = get_ctyp_args t1 []
19538                         in
19539                           pp f "@[<2>! %a.@ %a@]" (list o#ctyp "@ ")
19540                             (a :: al) o#ctyp t2
19541                     | t -> super#ctyp1 f t
19542                   
19543                 method constructor_type =
19544                   fun f t ->
19545                     match t with
19546                     | Ast.TyAnd (loc, t1, t2) ->
19547                         let () = o#node f t (fun _ -> loc)
19548                         in
19549                           pp f "%a@ and %a" o#constructor_type t1
19550                             o#constructor_type t2
19551                     | t -> o#ctyp f t
19552                   
19553                 method str_item =
19554                   fun f st ->
19555                     match st with
19556                     | Ast.StExp (_, e) ->
19557                         pp f "@[<2>%a%(%)@]" o#expr e semisep
19558                     | st -> super#str_item f st
19559                   
19560                 method module_expr =
19561                   fun f me ->
19562                     let () = o#node f me Ast.loc_of_module_expr
19563                     in
19564                       match me with
19565                       | Ast.MeApp (_, me1, me2) ->
19566                           pp f "@[<2>%a@ %a@]" o#module_expr me1
19567                             o#simple_module_expr me2
19568                       | me -> super#module_expr f me
19569                   
19570                 method simple_module_expr =
19571                   fun f me ->
19572                     let () = o#node f me Ast.loc_of_module_expr
19573                     in
19574                       match me with
19575                       | Ast.MeApp (_, _, _) -> pp f "(%a)" o#module_expr me
19576                       | _ -> super#simple_module_expr f me
19577                   
19578                 method implem = fun f st -> pp f "@[<v0>%a@]@." o#str_item st
19579                   
19580                 method class_type =
19581                   fun f ct ->
19582                     let () = o#node f ct Ast.loc_of_class_type
19583                     in
19584                       match ct with
19585                       | Ast.CtFun (_, t, ct) ->
19586                           pp f "@[<2>[ %a ] ->@ %a@]" o#simple_ctyp t
19587                             o#class_type ct
19588                       | Ast.CtCon (_, Ast.BFalse, i, (Ast.TyNil _)) ->
19589                           pp f "@[<2>%a@]" o#ident i
19590                       | Ast.CtCon (_, Ast.BFalse, i, t) ->
19591                           pp f "@[<2>%a [@,%a@]@,]" o#ident i o#class_params
19592                             t
19593                       | Ast.CtCon (_, Ast.BTrue, (Ast.IdLid (_, i)),
19594                           (Ast.TyNil _)) -> pp f "@[<2>virtual@ %a@]" o#var i
19595                       | Ast.CtCon (_, Ast.BTrue, (Ast.IdLid (_, i)), t) ->
19596                           pp f "@[<2>virtual@ %a@ [@,%a@]@,]" o#var i
19597                             o#class_params t
19598                       | ct -> super#class_type f ct
19599                   
19600                 method class_expr =
19601                   fun f ce ->
19602                     let () = o#node f ce Ast.loc_of_class_expr
19603                     in
19604                       match ce with
19605                       | Ast.CeCon (_, Ast.BFalse, i, (Ast.TyNil _)) ->
19606                           pp f "@[<2>%a@]" o#ident i
19607                       | Ast.CeCon (_, Ast.BFalse, i, t) ->
19608                           pp f "@[<2>%a@ @[<1>[%a]@]@]" o#ident i
19609                             o#class_params t
19610                       | Ast.CeCon (_, Ast.BTrue, (Ast.IdLid (_, i)),
19611                           (Ast.TyNil _)) -> pp f "@[<2>virtual@ %a@]" o#var i
19612                       | Ast.CeCon (_, Ast.BTrue, (Ast.IdLid (_, i)), t) ->
19613                           pp f "@[<2>virtual@ %a@ @[<1>[%a]@]@]" o#var i
19614                             o#ctyp t
19615                       | ce -> super#class_expr f ce
19616                   
19617               end
19618               
19619             let with_outfile = with_outfile
19620               
19621             let print = print
19622               
19623             let print_interf = print_interf
19624               
19625             let print_implem = print_implem
19626               
19627           end
19628           
19629         module MakeMore (Syntax : Sig.Camlp4Syntax) : Sig.Printer(Syntax.
19630           Ast).S =
19631           struct
19632             include Make(Syntax)
19633               
19634             let margin = ref 78
19635               
19636             let comments = ref true
19637               
19638             let locations = ref false
19639               
19640             let curry_constr = ref true
19641               
19642             let print output_file fct =
19643               let o =
19644                 new printer ~comments: !comments ~curry_constr: !curry_constr
19645                   () in
19646               let o = if !locations then o#set_loc_and_comments else o
19647               in
19648                 with_outfile output_file
19649                   (fun f ->
19650                      let () = Format.pp_set_margin f !margin
19651                      in Format.fprintf f "@[<v0>%a@]@." (fct o))
19652               
19653             let print_interf ?input_file:(_) ?output_file sg =
19654               print output_file (fun o -> o#interf) sg
19655               
19656             let print_implem ?input_file:(_) ?output_file st =
19657               print output_file (fun o -> o#implem) st
19658               
19659             let _ =
19660               Options.add "-l" (Arg.Int (fun i -> margin := i))
19661                 "<length> line length for pretty printing."
19662               
19663             let _ =
19664               Options.add "-no_comments" (Arg.Clear comments)
19665                 "Do not add comments."
19666               
19667             let _ =
19668               Options.add "-add_locations" (Arg.Set locations)
19669                 "Add locations as comment."
19670               
19671           end
19672           
19673       end
19674       
19675   end
19676   
19677 module OCamlInitSyntax =
19678   struct
19679     module Make
19680       (Ast : Sig.Camlp4Ast)
19681       (Gram :
19682         Sig.Grammar.Static with module Loc = Ast.Loc with
19683           type Token.t = Sig.camlp4_token)
19684       (Quotation : Sig.Quotation with module Ast = Sig.Camlp4AstToAst(Ast)) :
19685       Sig.Camlp4Syntax with module Loc = Ast.Loc and module Ast = Ast
19686       and module Token = Gram.Token and module Gram = Gram
19687       and module Quotation = Quotation =
19688       struct
19689         module Loc = Ast.Loc
19690           
19691         module Ast = Ast
19692           
19693         module Gram = Gram
19694           
19695         module Token = Gram.Token
19696           
19697         open Sig
19698           
19699         type warning = Loc.t -> string -> unit
19700         
19701         let default_warning loc txt =
19702           Format.eprintf "<W> %a: %s@." Loc.print loc txt
19703           
19704         let current_warning = ref default_warning
19705           
19706         let print_warning loc txt = !current_warning loc txt
19707           
19708         let a_CHAR = Gram.Entry.mk "a_CHAR"
19709           
19710         let a_FLOAT = Gram.Entry.mk "a_FLOAT"
19711           
19712         let a_INT = Gram.Entry.mk "a_INT"
19713           
19714         let a_INT32 = Gram.Entry.mk "a_INT32"
19715           
19716         let a_INT64 = Gram.Entry.mk "a_INT64"
19717           
19718         let a_LABEL = Gram.Entry.mk "a_LABEL"
19719           
19720         let a_LIDENT = Gram.Entry.mk "a_LIDENT"
19721           
19722         let a_NATIVEINT = Gram.Entry.mk "a_NATIVEINT"
19723           
19724         let a_OPTLABEL = Gram.Entry.mk "a_OPTLABEL"
19725           
19726         let a_STRING = Gram.Entry.mk "a_STRING"
19727           
19728         let a_UIDENT = Gram.Entry.mk "a_UIDENT"
19729           
19730         let a_ident = Gram.Entry.mk "a_ident"
19731           
19732         let amp_ctyp = Gram.Entry.mk "amp_ctyp"
19733           
19734         let and_ctyp = Gram.Entry.mk "and_ctyp"
19735           
19736         let match_case = Gram.Entry.mk "match_case"
19737           
19738         let match_case0 = Gram.Entry.mk "match_case0"
19739           
19740         let binding = Gram.Entry.mk "binding"
19741           
19742         let class_declaration = Gram.Entry.mk "class_declaration"
19743           
19744         let class_description = Gram.Entry.mk "class_description"
19745           
19746         let class_expr = Gram.Entry.mk "class_expr"
19747           
19748         let class_fun_binding = Gram.Entry.mk "class_fun_binding"
19749           
19750         let class_fun_def = Gram.Entry.mk "class_fun_def"
19751           
19752         let class_info_for_class_expr =
19753           Gram.Entry.mk "class_info_for_class_expr"
19754           
19755         let class_info_for_class_type =
19756           Gram.Entry.mk "class_info_for_class_type"
19757           
19758         let class_longident = Gram.Entry.mk "class_longident"
19759           
19760         let class_longident_and_param =
19761           Gram.Entry.mk "class_longident_and_param"
19762           
19763         let class_name_and_param = Gram.Entry.mk "class_name_and_param"
19764           
19765         let class_sig_item = Gram.Entry.mk "class_sig_item"
19766           
19767         let class_signature = Gram.Entry.mk "class_signature"
19768           
19769         let class_str_item = Gram.Entry.mk "class_str_item"
19770           
19771         let class_structure = Gram.Entry.mk "class_structure"
19772           
19773         let class_type = Gram.Entry.mk "class_type"
19774           
19775         let class_type_declaration = Gram.Entry.mk "class_type_declaration"
19776           
19777         let class_type_longident = Gram.Entry.mk "class_type_longident"
19778           
19779         let class_type_longident_and_param =
19780           Gram.Entry.mk "class_type_longident_and_param"
19781           
19782         let class_type_plus = Gram.Entry.mk "class_type_plus"
19783           
19784         let comma_ctyp = Gram.Entry.mk "comma_ctyp"
19785           
19786         let comma_expr = Gram.Entry.mk "comma_expr"
19787           
19788         let comma_ipatt = Gram.Entry.mk "comma_ipatt"
19789           
19790         let comma_patt = Gram.Entry.mk "comma_patt"
19791           
19792         let comma_type_parameter = Gram.Entry.mk "comma_type_parameter"
19793           
19794         let constrain = Gram.Entry.mk "constrain"
19795           
19796         let constructor_arg_list = Gram.Entry.mk "constructor_arg_list"
19797           
19798         let constructor_declaration = Gram.Entry.mk "constructor_declaration"
19799           
19800         let constructor_declarations =
19801           Gram.Entry.mk "constructor_declarations"
19802           
19803         let ctyp = Gram.Entry.mk "ctyp"
19804           
19805         let cvalue_binding = Gram.Entry.mk "cvalue_binding"
19806           
19807         let direction_flag = Gram.Entry.mk "direction_flag"
19808           
19809         let dummy = Gram.Entry.mk "dummy"
19810           
19811         let entry_eoi = Gram.Entry.mk "entry_eoi"
19812           
19813         let eq_expr = Gram.Entry.mk "eq_expr"
19814           
19815         let expr = Gram.Entry.mk "expr"
19816           
19817         let expr_eoi = Gram.Entry.mk "expr_eoi"
19818           
19819         let field_expr = Gram.Entry.mk "field_expr"
19820           
19821         let field_expr_list = Gram.Entry.mk "field_expr_list"
19822           
19823         let fun_binding = Gram.Entry.mk "fun_binding"
19824           
19825         let fun_def = Gram.Entry.mk "fun_def"
19826           
19827         let ident = Gram.Entry.mk "ident"
19828           
19829         let implem = Gram.Entry.mk "implem"
19830           
19831         let interf = Gram.Entry.mk "interf"
19832           
19833         let ipatt = Gram.Entry.mk "ipatt"
19834           
19835         let ipatt_tcon = Gram.Entry.mk "ipatt_tcon"
19836           
19837         let label = Gram.Entry.mk "label"
19838           
19839         let label_declaration = Gram.Entry.mk "label_declaration"
19840           
19841         let label_declaration_list = Gram.Entry.mk "label_declaration_list"
19842           
19843         let label_expr = Gram.Entry.mk "label_expr"
19844           
19845         let label_expr_list = Gram.Entry.mk "label_expr_list"
19846           
19847         let label_ipatt = Gram.Entry.mk "label_ipatt"
19848           
19849         let label_ipatt_list = Gram.Entry.mk "label_ipatt_list"
19850           
19851         let label_longident = Gram.Entry.mk "label_longident"
19852           
19853         let label_patt = Gram.Entry.mk "label_patt"
19854           
19855         let label_patt_list = Gram.Entry.mk "label_patt_list"
19856           
19857         let labeled_ipatt = Gram.Entry.mk "labeled_ipatt"
19858           
19859         let let_binding = Gram.Entry.mk "let_binding"
19860           
19861         let meth_list = Gram.Entry.mk "meth_list"
19862           
19863         let meth_decl = Gram.Entry.mk "meth_decl"
19864           
19865         let module_binding = Gram.Entry.mk "module_binding"
19866           
19867         let module_binding0 = Gram.Entry.mk "module_binding0"
19868           
19869         let module_declaration = Gram.Entry.mk "module_declaration"
19870           
19871         let module_expr = Gram.Entry.mk "module_expr"
19872           
19873         let module_longident = Gram.Entry.mk "module_longident"
19874           
19875         let module_longident_with_app =
19876           Gram.Entry.mk "module_longident_with_app"
19877           
19878         let module_rec_declaration = Gram.Entry.mk "module_rec_declaration"
19879           
19880         let module_type = Gram.Entry.mk "module_type"
19881           
19882         let more_ctyp = Gram.Entry.mk "more_ctyp"
19883           
19884         let name_tags = Gram.Entry.mk "name_tags"
19885           
19886         let opt_as_lident = Gram.Entry.mk "opt_as_lident"
19887           
19888         let opt_class_self_patt = Gram.Entry.mk "opt_class_self_patt"
19889           
19890         let opt_class_self_type = Gram.Entry.mk "opt_class_self_type"
19891           
19892         let opt_class_signature = Gram.Entry.mk "opt_class_signature"
19893           
19894         let opt_class_structure = Gram.Entry.mk "opt_class_structure"
19895           
19896         let opt_comma_ctyp = Gram.Entry.mk "opt_comma_ctyp"
19897           
19898         let opt_dot_dot = Gram.Entry.mk "opt_dot_dot"
19899           
19900         let opt_eq_ctyp = Gram.Entry.mk "opt_eq_ctyp"
19901           
19902         let opt_expr = Gram.Entry.mk "opt_expr"
19903           
19904         let opt_meth_list = Gram.Entry.mk "opt_meth_list"
19905           
19906         let opt_mutable = Gram.Entry.mk "opt_mutable"
19907           
19908         let opt_polyt = Gram.Entry.mk "opt_polyt"
19909           
19910         let opt_private = Gram.Entry.mk "opt_private"
19911           
19912         let opt_rec = Gram.Entry.mk "opt_rec"
19913           
19914         let opt_sig_items = Gram.Entry.mk "opt_sig_items"
19915           
19916         let opt_str_items = Gram.Entry.mk "opt_str_items"
19917           
19918         let opt_virtual = Gram.Entry.mk "opt_virtual"
19919           
19920         let opt_when_expr = Gram.Entry.mk "opt_when_expr"
19921           
19922         let patt = Gram.Entry.mk "patt"
19923           
19924         let patt_as_patt_opt = Gram.Entry.mk "patt_as_patt_opt"
19925           
19926         let patt_eoi = Gram.Entry.mk "patt_eoi"
19927           
19928         let patt_tcon = Gram.Entry.mk "patt_tcon"
19929           
19930         let phrase = Gram.Entry.mk "phrase"
19931           
19932         let poly_type = Gram.Entry.mk "poly_type"
19933           
19934         let row_field = Gram.Entry.mk "row_field"
19935           
19936         let sem_expr = Gram.Entry.mk "sem_expr"
19937           
19938         let sem_expr_for_list = Gram.Entry.mk "sem_expr_for_list"
19939           
19940         let sem_patt = Gram.Entry.mk "sem_patt"
19941           
19942         let sem_patt_for_list = Gram.Entry.mk "sem_patt_for_list"
19943           
19944         let semi = Gram.Entry.mk "semi"
19945           
19946         let sequence = Gram.Entry.mk "sequence"
19947           
19948         let do_sequence = Gram.Entry.mk "do_sequence"
19949           
19950         let sig_item = Gram.Entry.mk "sig_item"
19951           
19952         let sig_items = Gram.Entry.mk "sig_items"
19953           
19954         let star_ctyp = Gram.Entry.mk "star_ctyp"
19955           
19956         let str_item = Gram.Entry.mk "str_item"
19957           
19958         let str_items = Gram.Entry.mk "str_items"
19959           
19960         let top_phrase = Gram.Entry.mk "top_phrase"
19961           
19962         let type_constraint = Gram.Entry.mk "type_constraint"
19963           
19964         let type_declaration = Gram.Entry.mk "type_declaration"
19965           
19966         let type_ident_and_parameters =
19967           Gram.Entry.mk "type_ident_and_parameters"
19968           
19969         let type_kind = Gram.Entry.mk "type_kind"
19970           
19971         let type_longident = Gram.Entry.mk "type_longident"
19972           
19973         let type_longident_and_parameters =
19974           Gram.Entry.mk "type_longident_and_parameters"
19975           
19976         let type_parameter = Gram.Entry.mk "type_parameter"
19977           
19978         let type_parameters = Gram.Entry.mk "type_parameters"
19979           
19980         let typevars = Gram.Entry.mk "typevars"
19981           
19982         let use_file = Gram.Entry.mk "use_file"
19983           
19984         let val_longident = Gram.Entry.mk "val_longident"
19985           
19986         let value_let = Gram.Entry.mk "value_let"
19987           
19988         let value_val = Gram.Entry.mk "value_val"
19989           
19990         let with_constr = Gram.Entry.mk "with_constr"
19991           
19992         let expr_quot = Gram.Entry.mk "quotation of expression"
19993           
19994         let patt_quot = Gram.Entry.mk "quotation of pattern"
19995           
19996         let ctyp_quot = Gram.Entry.mk "quotation of type"
19997           
19998         let str_item_quot = Gram.Entry.mk "quotation of structure item"
19999           
20000         let sig_item_quot = Gram.Entry.mk "quotation of signature item"
20001           
20002         let class_str_item_quot =
20003           Gram.Entry.mk "quotation of class structure item"
20004           
20005         let class_sig_item_quot =
20006           Gram.Entry.mk "quotation of class signature item"
20007           
20008         let module_expr_quot = Gram.Entry.mk "quotation of module expression"
20009           
20010         let module_type_quot = Gram.Entry.mk "quotation of module type"
20011           
20012         let class_type_quot = Gram.Entry.mk "quotation of class type"
20013           
20014         let class_expr_quot = Gram.Entry.mk "quotation of class expression"
20015           
20016         let with_constr_quot = Gram.Entry.mk "quotation of with constraint"
20017           
20018         let binding_quot = Gram.Entry.mk "quotation of binding"
20019           
20020         let rec_binding_quot = Gram.Entry.mk "quotation of record binding"
20021           
20022         let match_case_quot =
20023           Gram.Entry.mk "quotation of match_case (try/match/function case)"
20024           
20025         let module_binding_quot =
20026           Gram.Entry.mk "quotation of module rec binding"
20027           
20028         let ident_quot = Gram.Entry.mk "quotation of identifier"
20029           
20030         let prefixop =
20031           Gram.Entry.mk "prefix operator (start with '!', '?', '~')"
20032           
20033         let infixop0 =
20034           Gram.Entry.mk
20035             "infix operator (level 0) (comparison operators, and some others)"
20036           
20037         let infixop1 =
20038           Gram.Entry.mk "infix operator (level 1) (start with '^', '@')"
20039           
20040         let infixop2 =
20041           Gram.Entry.mk "infix operator (level 2) (start with '+', '-')"
20042           
20043         let infixop3 =
20044           Gram.Entry.mk "infix operator (level 3) (start with '*', '/', '%')"
20045           
20046         let infixop4 =
20047           Gram.Entry.mk
20048             "infix operator (level 4) (start with \"**\") (right assoc)"
20049           
20050         let _ =
20051           Gram.extend (top_phrase : 'top_phrase Gram.Entry.t)
20052             ((fun () ->
20053                 (None,
20054                  [ (None, None,
20055                     [ ([ Gram.Stoken
20056                            (((function | EOI -> true | _ -> false), "EOI")) ],
20057                        (Gram.Action.mk
20058                           (fun (__camlp4_0 : Gram.Token.t)
20059                              (_loc : Gram.Loc.t) ->
20060                              match __camlp4_0 with
20061                              | EOI -> (None : 'top_phrase)
20062                              | _ -> assert false))) ]) ]))
20063                ())
20064           
20065         module AntiquotSyntax =
20066           struct
20067             module Loc = Ast.Loc
20068               
20069             module Ast = Sig.Camlp4AstToAst(Ast)
20070               
20071             module Gram = Gram
20072               
20073             let antiquot_expr = Gram.Entry.mk "antiquot_expr"
20074               
20075             let antiquot_patt = Gram.Entry.mk "antiquot_patt"
20076               
20077             let _ =
20078               (Gram.extend (antiquot_expr : 'antiquot_expr Gram.Entry.t)
20079                  ((fun () ->
20080                      (None,
20081                       [ (None, None,
20082                          [ ([ Gram.Snterm
20083                                 (Gram.Entry.obj (expr : 'expr Gram.Entry.t));
20084                               Gram.Stoken
20085                                 (((function | EOI -> true | _ -> false),
20086                                   "EOI")) ],
20087                             (Gram.Action.mk
20088                                (fun (__camlp4_0 : Gram.Token.t) (x : 'expr)
20089                                   (_loc : Gram.Loc.t) ->
20090                                   match __camlp4_0 with
20091                                   | EOI -> (x : 'antiquot_expr)
20092                                   | _ -> assert false))) ]) ]))
20093                     ());
20094                Gram.extend (antiquot_patt : 'antiquot_patt Gram.Entry.t)
20095                  ((fun () ->
20096                      (None,
20097                       [ (None, None,
20098                          [ ([ Gram.Snterm
20099                                 (Gram.Entry.obj (patt : 'patt Gram.Entry.t));
20100                               Gram.Stoken
20101                                 (((function | EOI -> true | _ -> false),
20102                                   "EOI")) ],
20103                             (Gram.Action.mk
20104                                (fun (__camlp4_0 : Gram.Token.t) (x : 'patt)
20105                                   (_loc : Gram.Loc.t) ->
20106                                   match __camlp4_0 with
20107                                   | EOI -> (x : 'antiquot_patt)
20108                                   | _ -> assert false))) ]) ]))
20109                     ()))
20110               
20111             let parse_expr loc str = Gram.parse_string antiquot_expr loc str
20112               
20113             let parse_patt loc str = Gram.parse_string antiquot_patt loc str
20114               
20115           end
20116           
20117         module Quotation = Quotation
20118           
20119         let wrap directive_handler pa init_loc cs =
20120           let rec loop loc =
20121             let (pl, stopped_at_directive) = pa loc cs
20122             in
20123               match stopped_at_directive with
20124               | Some new_loc ->
20125                   let pl =
20126                     (match List.rev pl with
20127                      | [] -> assert false
20128                      | x :: xs ->
20129                          (match directive_handler x with
20130                           | None -> xs
20131                           | Some x -> x :: xs))
20132                   in (List.rev pl) @ (loop new_loc)
20133               | None -> pl
20134           in loop init_loc
20135           
20136         let parse_implem ?(directive_handler = fun _ -> None) _loc cs =
20137           let l = wrap directive_handler (Gram.parse implem) _loc cs
20138           in Ast.stSem_of_list l
20139           
20140         let parse_interf ?(directive_handler = fun _ -> None) _loc cs =
20141           let l = wrap directive_handler (Gram.parse interf) _loc cs
20142           in Ast.sgSem_of_list l
20143           
20144         let print_interf ?input_file:(_) ?output_file:(_) _ =
20145           failwith "No interface printer"
20146           
20147         let print_implem ?input_file:(_) ?output_file:(_) _ =
20148           failwith "No implementation printer"
20149           
20150       end
20151       
20152   end
20153   
20154 module PreCast :
20155   sig
20156     type camlp4_token =
20157       Sig.camlp4_token =
20158         | KEYWORD of string
20159         | SYMBOL of string
20160         | LIDENT of string
20161         | UIDENT of string
20162         | ESCAPED_IDENT of string
20163         | INT of int * string
20164         | INT32 of int32 * string
20165         | INT64 of int64 * string
20166         | NATIVEINT of nativeint * string
20167         | FLOAT of float * string
20168         | CHAR of char * string
20169         | STRING of string * string
20170         | LABEL of string
20171         | OPTLABEL of string
20172         | QUOTATION of Sig.quotation
20173         | ANTIQUOT of string * string
20174         | COMMENT of string
20175         | BLANKS of string
20176         | NEWLINE
20177         | LINE_DIRECTIVE of int * string option
20178         | EOI
20179     
20180     module Id : Sig.Id
20181       
20182     module Loc : Sig.Loc
20183       
20184     module Ast : Sig.Camlp4Ast with module Loc = Loc
20185       
20186     module Token : Sig.Token with module Loc = Loc and type t = camlp4_token
20187       
20188     module Lexer : Sig.Lexer with module Loc = Loc and module Token = Token
20189       
20190     module Gram : Sig.Grammar.Static with module Loc = Loc
20191       and module Token = Token
20192       
20193     module Quotation :
20194       Sig.Quotation with module Ast = Sig.Camlp4AstToAst(Ast)
20195       
20196     module DynLoader : Sig.DynLoader
20197       
20198     module AstFilters : Sig.AstFilters with module Ast = Ast
20199       
20200     module Syntax : Sig.Camlp4Syntax with module Loc = Loc
20201       and module Token = Token and module Ast = Ast and module Gram = Gram
20202       and module Quotation = Quotation
20203       
20204     module Printers :
20205       sig
20206         module OCaml : Sig.Printer(Ast).S
20207           
20208         module OCamlr : Sig.Printer(Ast).S
20209           
20210         module DumpOCamlAst : Sig.Printer(Ast).S
20211           
20212         module DumpCamlp4Ast : Sig.Printer(Ast).S
20213           
20214         module Null : Sig.Printer(Ast).S
20215           
20216       end
20217       
20218     module MakeGram (Lexer : Sig.Lexer with module Loc = Loc) :
20219       Sig.Grammar.Static with module Loc = Loc and module Token = Lexer.Token
20220       
20221     module MakeSyntax (U : sig  end) : Sig.Syntax
20222       
20223   end =
20224   struct
20225     module Id =
20226       struct let name = "Camlp4.PreCast"
20227                 let version = Sys.ocaml_version
20228                    end
20229       
20230     type camlp4_token =
20231       Sig.camlp4_token =
20232         | KEYWORD of string
20233         | SYMBOL of string
20234         | LIDENT of string
20235         | UIDENT of string
20236         | ESCAPED_IDENT of string
20237         | INT of int * string
20238         | INT32 of int32 * string
20239         | INT64 of int64 * string
20240         | NATIVEINT of nativeint * string
20241         | FLOAT of float * string
20242         | CHAR of char * string
20243         | STRING of string * string
20244         | LABEL of string
20245         | OPTLABEL of string
20246         | QUOTATION of Sig.quotation
20247         | ANTIQUOT of string * string
20248         | COMMENT of string
20249         | BLANKS of string
20250         | NEWLINE
20251         | LINE_DIRECTIVE of int * string option
20252         | EOI
20253     
20254     module Loc = Struct.Loc
20255       
20256     module Ast = Struct.Camlp4Ast.Make(Loc)
20257       
20258     module Token = Struct.Token.Make(Loc)
20259       
20260     module Lexer = Struct.Lexer.Make(Token)
20261       
20262     module Gram = Struct.Grammar.Static.Make(Lexer)
20263       
20264     module DynLoader = Struct.DynLoader
20265       
20266     module Quotation = Struct.Quotation.Make(Ast)
20267       
20268     module MakeSyntax (U : sig  end) =
20269       OCamlInitSyntax.Make(Ast)(Gram)(Quotation)
20270       
20271     module Syntax = MakeSyntax(struct  end)
20272       
20273     module AstFilters = Struct.AstFilters.Make(Ast)
20274       
20275     module MakeGram = Struct.Grammar.Static.Make
20276       
20277     module Printers =
20278       struct
20279         module OCaml = Printers.OCaml.Make(Syntax)
20280           
20281         module OCamlr = Printers.OCamlr.Make(Syntax)
20282           
20283         module DumpOCamlAst = Printers.DumpOCamlAst.Make(Syntax)
20284           
20285         module DumpCamlp4Ast = Printers.DumpCamlp4Ast.Make(Syntax)
20286           
20287         module Null = Printers.Null.Make(Syntax)
20288           
20289       end
20290       
20291   end
20292   
20293 module Register :
20294   sig
20295     module Plugin
20296       (Id : Sig.Id) (Plugin : functor (Unit : sig  end) -> sig  end) :
20297       sig  end
20298       
20299     module SyntaxPlugin
20300       (Id : Sig.Id) (SyntaxPlugin : functor (Syn : Sig.Syntax) -> sig  end) :
20301       sig  end
20302       
20303     module SyntaxExtension
20304       (Id : Sig.Id) (SyntaxExtension : Sig.SyntaxExtension) : sig  end
20305       
20306     module OCamlSyntaxExtension
20307       (Id : Sig.Id)
20308       (SyntaxExtension :
20309         functor (Syntax : Sig.Camlp4Syntax) -> Sig.Camlp4Syntax) :
20310       sig  end
20311       
20312     type 'a parser_fun =
20313       ?directive_handler: ('a -> 'a option) ->
20314         PreCast.Loc.t -> char Stream.t -> 'a
20315     
20316     val register_str_item_parser : PreCast.Ast.str_item parser_fun -> unit
20317       
20318     val register_sig_item_parser : PreCast.Ast.sig_item parser_fun -> unit
20319       
20320     val register_parser :
20321       PreCast.Ast.str_item parser_fun ->
20322         PreCast.Ast.sig_item parser_fun -> unit
20323       
20324     module Parser
20325       (Id : Sig.Id) (Maker : functor (Ast : Sig.Ast) -> Sig.Parser(Ast).S) :
20326       sig  end
20327       
20328     module OCamlParser
20329       (Id : Sig.Id)
20330       (Maker : functor (Ast : Sig.Camlp4Ast) -> Sig.Parser(Ast).S) : 
20331       sig  end
20332       
20333     module OCamlPreCastParser
20334       (Id : Sig.Id) (Parser : Sig.Parser(PreCast.Ast).S) : sig  end
20335       
20336     type 'a printer_fun =
20337       ?input_file: string -> ?output_file: string -> 'a -> unit
20338     
20339     val register_str_item_printer : PreCast.Ast.str_item printer_fun -> unit
20340       
20341     val register_sig_item_printer : PreCast.Ast.sig_item printer_fun -> unit
20342       
20343     val register_printer :
20344       PreCast.Ast.str_item printer_fun ->
20345         PreCast.Ast.sig_item printer_fun -> unit
20346       
20347     module Printer
20348       (Id : Sig.Id)
20349       (Maker : functor (Syn : Sig.Syntax) -> Sig.Printer(Syn.Ast).S) :
20350       sig  end
20351       
20352     module OCamlPrinter
20353       (Id : Sig.Id)
20354       (Maker : functor (Syn : Sig.Camlp4Syntax) -> Sig.Printer(Syn.Ast).S) :
20355       sig  end
20356       
20357     module OCamlPreCastPrinter
20358       (Id : Sig.Id) (Printer : Sig.Printer(PreCast.Ast).S) : sig  end
20359       
20360     module AstFilter
20361       (Id : Sig.Id) (Maker : functor (F : Sig.AstFilters) -> sig  end) :
20362       sig  end
20363       
20364     val declare_dyn_module : string -> (unit -> unit) -> unit
20365       
20366     val iter_and_take_callbacks : ((string * (unit -> unit)) -> unit) -> unit
20367       
20368     val loaded_modules : (string list) ref
20369       
20370     module CurrentParser : Sig.Parser(PreCast.Ast).S
20371       
20372     module CurrentPrinter : Sig.Printer(PreCast.Ast).S
20373       
20374     val enable_ocaml_printer : unit -> unit
20375       
20376     val enable_ocamlr_printer : unit -> unit
20377       
20378     val enable_null_printer : unit -> unit
20379       
20380     val enable_dump_ocaml_ast_printer : unit -> unit
20381       
20382     val enable_dump_camlp4_ast_printer : unit -> unit
20383       
20384   end =
20385   struct
20386     module PP = Printers
20387       
20388     open PreCast
20389       
20390     type 'a parser_fun =
20391       ?directive_handler: ('a -> 'a option) ->
20392         PreCast.Loc.t -> char Stream.t -> 'a
20393     
20394     type 'a printer_fun =
20395       ?input_file: string -> ?output_file: string -> 'a -> unit
20396     
20397     let sig_item_parser =
20398       ref (fun ?directive_handler:(_) _ _ -> failwith "No interface parser")
20399       
20400     let str_item_parser =
20401       ref
20402         (fun ?directive_handler:(_) _ _ ->
20403            failwith "No implementation parser")
20404       
20405     let sig_item_printer =
20406       ref
20407         (fun ?input_file:(_) ?output_file:(_) _ ->
20408            failwith "No interface printer")
20409       
20410     let str_item_printer =
20411       ref
20412         (fun ?input_file:(_) ?output_file:(_) _ ->
20413            failwith "No implementation printer")
20414       
20415     let callbacks = Queue.create ()
20416       
20417     let loaded_modules = ref []
20418       
20419     let iter_and_take_callbacks f =
20420       let rec loop () = loop (f (Queue.take callbacks))
20421       in try loop () with | Queue.Empty -> ()
20422       
20423     let declare_dyn_module m f =
20424       (loaded_modules := m :: !loaded_modules; Queue.add (m, f) callbacks)
20425       
20426     let register_str_item_parser f = str_item_parser := f
20427       
20428     let register_sig_item_parser f = sig_item_parser := f
20429       
20430     let register_parser f g = (str_item_parser := f; sig_item_parser := g)
20431       
20432     let register_str_item_printer f = str_item_printer := f
20433       
20434     let register_sig_item_printer f = sig_item_printer := f
20435       
20436     let register_printer f g = (str_item_printer := f; sig_item_printer := g)
20437       
20438     module Plugin
20439       (Id : Sig.Id) (Maker : functor (Unit : sig  end) -> sig  end) =
20440       struct
20441         let _ =
20442           declare_dyn_module Id.name
20443             (fun _ -> let module M = Maker(struct  end) in ())
20444           
20445       end
20446       
20447     module SyntaxExtension (Id : Sig.Id) (Maker : Sig.SyntaxExtension) =
20448       struct
20449         let _ =
20450           declare_dyn_module Id.name
20451             (fun _ -> let module M = Maker(Syntax) in ())
20452           
20453       end
20454       
20455     module OCamlSyntaxExtension
20456       (Id : Sig.Id)
20457       (Maker : functor (Syn : Sig.Camlp4Syntax) -> Sig.Camlp4Syntax) =
20458       struct
20459         let _ =
20460           declare_dyn_module Id.name
20461             (fun _ -> let module M = Maker(Syntax) in ())
20462           
20463       end
20464       
20465     module SyntaxPlugin
20466       (Id : Sig.Id) (Maker : functor (Syn : Sig.Syntax) -> sig  end) =
20467       struct
20468         let _ =
20469           declare_dyn_module Id.name
20470             (fun _ -> let module M = Maker(Syntax) in ())
20471           
20472       end
20473       
20474     module Printer
20475       (Id : Sig.Id)
20476       (Maker : functor (Syn : Sig.Syntax) -> Sig.Printer(Syn.Ast).S) =
20477       struct
20478         let _ =
20479           declare_dyn_module Id.name
20480             (fun _ -> let module M = Maker(Syntax)
20481                in register_printer M.print_implem M.print_interf)
20482           
20483       end
20484       
20485     module OCamlPrinter
20486       (Id : Sig.Id)
20487       (Maker : functor (Syn : Sig.Camlp4Syntax) -> Sig.Printer(Syn.Ast).S) =
20488       struct
20489         let _ =
20490           declare_dyn_module Id.name
20491             (fun _ -> let module M = Maker(Syntax)
20492                in register_printer M.print_implem M.print_interf)
20493           
20494       end
20495       
20496     module OCamlPreCastPrinter
20497       (Id : Sig.Id) (P : Sig.Printer(PreCast.Ast).S) =
20498       struct
20499         let _ =
20500           declare_dyn_module Id.name
20501             (fun _ -> register_printer P.print_implem P.print_interf)
20502           
20503       end
20504       
20505     module Parser
20506       (Id : Sig.Id) (Maker : functor (Ast : Sig.Ast) -> Sig.Parser(Ast).S) =
20507       struct
20508         let _ =
20509           declare_dyn_module Id.name
20510             (fun _ -> let module M = Maker(PreCast.Ast)
20511                in register_parser M.parse_implem M.parse_interf)
20512           
20513       end
20514       
20515     module OCamlParser
20516       (Id : Sig.Id)
20517       (Maker : functor (Ast : Sig.Camlp4Ast) -> Sig.Parser(Ast).S) =
20518       struct
20519         let _ =
20520           declare_dyn_module Id.name
20521             (fun _ -> let module M = Maker(PreCast.Ast)
20522                in register_parser M.parse_implem M.parse_interf)
20523           
20524       end
20525       
20526     module OCamlPreCastParser (Id : Sig.Id) (P : Sig.Parser(PreCast.Ast).S) =
20527       struct
20528         let _ =
20529           declare_dyn_module Id.name
20530             (fun _ -> register_parser P.parse_implem P.parse_interf)
20531           
20532       end
20533       
20534     module AstFilter
20535       (Id : Sig.Id) (Maker : functor (F : Sig.AstFilters) -> sig  end) =
20536       struct
20537         let _ =
20538           declare_dyn_module Id.name
20539             (fun _ -> let module M = Maker(AstFilters) in ())
20540           
20541       end
20542       
20543     let _ = sig_item_parser := Syntax.parse_interf
20544       
20545     let _ = str_item_parser := Syntax.parse_implem
20546       
20547     module CurrentParser =
20548       struct
20549         module Ast = Ast
20550           
20551         let parse_interf ?directive_handler loc strm =
20552           !sig_item_parser ?directive_handler loc strm
20553           
20554         let parse_implem ?directive_handler loc strm =
20555           !str_item_parser ?directive_handler loc strm
20556           
20557       end
20558       
20559     module CurrentPrinter =
20560       struct
20561         module Ast = Ast
20562           
20563         let print_interf ?input_file ?output_file ast =
20564           !sig_item_printer ?input_file ?output_file ast
20565           
20566         let print_implem ?input_file ?output_file ast =
20567           !str_item_printer ?input_file ?output_file ast
20568           
20569       end
20570       
20571     let enable_ocaml_printer () =
20572       let module M = OCamlPrinter(PP.OCaml.Id)(PP.OCaml.MakeMore) in ()
20573       
20574     let enable_ocamlr_printer () =
20575       let module M = OCamlPrinter(PP.OCamlr.Id)(PP.OCamlr.MakeMore) in ()
20576       
20577     let enable_dump_ocaml_ast_printer () =
20578       let module M = OCamlPrinter(PP.DumpOCamlAst.Id)(PP.DumpOCamlAst.Make)
20579       in ()
20580       
20581     let enable_dump_camlp4_ast_printer () =
20582       let module M = Printer(PP.DumpCamlp4Ast.Id)(PP.DumpCamlp4Ast.Make)
20583       in ()
20584       
20585     let enable_null_printer () =
20586       let module M = Printer(PP.Null.Id)(PP.Null.Make) in ()
20587       
20588   end
20589   
20590