Project

General

Profile

« Previous | Next » 

Revision 81d69074

Added by LĂ©lio Brun 10 months ago

fix bug where singleton tuples were generated

View differences:

src/typing.ml
644 644
        let touts = type_appl env in_main expr.expr_loc const id args_list in
645 645
        let targs =
646 646
          new_ty
647
            (Ttuple
648
               (List.map (fun a -> Expr_type_hub.import a.expr_type) args_list))
647
            (match args_list with
648
             | [a] -> (Expr_type_hub.import a.expr_type).tdesc
649
             | _ ->
650
               Ttuple
651
                 (List.map (fun a -> Expr_type_hub.import a.expr_type) args_list))
649 652
        in
650 653
        args.expr_type <- Expr_type_hub.export targs;
651 654
        expr.expr_type <- Expr_type_hub.export touts;

Also available in: Unified diff