Minimal support for inlined records (displayed as {...}) for the latex backend.
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/constructors_with_record5@15552 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02master
parent
ba91d29558
commit
6513ec9dd8
|
@ -600,18 +600,17 @@ class latex =
|
|||
p fmt2 "@[<h 6> | %s" constr.vc_name ;
|
||||
begin match constr.vc_args, constr.vc_ret with
|
||||
| Cstr_tuple [], None -> ()
|
||||
| Cstr_tuple l, None ->
|
||||
| l, None ->
|
||||
p fmt2 " of@ %s"
|
||||
(self#normal_type_list ~par: false mod_name " * " l)
|
||||
(self#normal_cstr_args ~par: false mod_name l)
|
||||
| Cstr_tuple [], Some r ->
|
||||
p fmt2 " :@ %s"
|
||||
(self#normal_type mod_name r)
|
||||
| Cstr_tuple l, Some r ->
|
||||
| l, Some r ->
|
||||
p fmt2 " :@ %s@ %s@ %s"
|
||||
(self#normal_type_list ~par: false mod_name " * " l)
|
||||
(self#normal_cstr_args ~par: false mod_name l)
|
||||
"->"
|
||||
(self#normal_type mod_name r)
|
||||
| Cstr_record _, _ -> assert false
|
||||
end ;
|
||||
flush2 ()
|
||||
in
|
||||
|
|
|
@ -233,7 +233,7 @@ class virtual to_text =
|
|||
|
||||
method normal_cstr_args ?par m_name = function
|
||||
| Cstr_tuple l -> self#normal_type_list ?par m_name " * " l
|
||||
| Cstr_record _ -> assert false
|
||||
| Cstr_record _ -> "{...}" (* TODO *)
|
||||
|
||||
(** Get a string for a list of class or class type type parameters
|
||||
where all idents are relative. *)
|
||||
|
|
Loading…
Reference in New Issue