From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by sympa.inria.fr (Postfix) with ESMTPS id D0CF08239C for ; Sun, 11 Mar 2018 16:51:22 +0100 (CET) Authentication-Results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=mail@matej-kosik.net; spf=SoftFail smtp.mailfrom=mail@matej-kosik.net; spf=SoftFail smtp.helo=postmaster@matej-kosik.net Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of mail@matej-kosik.net) identity=pra; client-ip=145.239.83.105; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="mail@matej-kosik.net"; x-sender="mail@matej-kosik.net"; x-conformance=sidf_compatible Received-SPF: SoftFail (mail2-smtp-roc.national.inria.fr: domain of mail@matej-kosik.net is inclined to not designate 145.239.83.105 as permitted sender) identity=mailfrom; client-ip=145.239.83.105; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="mail@matej-kosik.net"; x-sender="mail@matej-kosik.net"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: SoftFail (mail2-smtp-roc.national.inria.fr: domain of postmaster@matej-kosik.net is inclined to not designate 145.239.83.105 as permitted sender) identity=helo; client-ip=145.239.83.105; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="mail@matej-kosik.net"; x-sender="postmaster@matej-kosik.net"; x-conformance=sidf_compatible; x-record-type="v=spf1" IronPort-PHdr: =?us-ascii?q?9a23=3AZ5mBpxbW2zhiMNW+LnCGXMj/LSx+4OfEezUN459i?= =?us-ascii?q?sYplN5qZoMS+bnLW6fgltlLVR4KTs6sC17KN9fi4EUU7or+5+EgYd5JNUxJXwe?= =?us-ascii?q?43pCcHRPC/NEvgMfTxZDY7FskRHHVs/nW8LFQHUJ2mPw6arXK99yMdFQviPgRp?= =?us-ascii?q?OOv1BpTSj8Oq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RfDn3QXRGQVYYGy/Cu?= =?us-ascii?q?dlvmliWdCWSLzbT4Xou4SvmSKyH5lYfGdDUw/eFH70eofBWPAXaSHUJMJ9wGdd?= =?us-ascii?q?CeqRDrQ53BTrjzfUjqJ9J7OLqCgRqZ/hkdty/OzQ0xc/6W4sVpnP4yS2V2hx21?= =?us-ascii?q?gwaXo20aR4+BMvz16f3Ko9gPtDFN8V4f5VAFw3?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0C+CAB1T6Va/2lT75FdGwEBAQEDAQEBC?= =?us-ascii?q?QEBAYNQaWyDeIsSjkwLKYEWlkeFLwKDEB0JBS4VAQIBAQEBAQEBAQFqJ4I4JAG?= =?us-ascii?q?CRwEFIw8BOQoDEAsYAgImAgJXBg0IAQGFGKoXgiaEb4NDJ4IagQ2EKIMCgxEMg?= =?us-ascii?q?nmIKYJiBJM5hx0JiVOHCYkShVaSdDQigVJ7CjqCRIRHjQQBAQE?= X-IPAS-Result: =?us-ascii?q?A0C+CAB1T6Va/2lT75FdGwEBAQEDAQEBCQEBAYNQaWyDeIs?= =?us-ascii?q?SjkwLKYEWlkeFLwKDEB0JBS4VAQIBAQEBAQEBAQFqJ4I4JAGCRwEFIw8BOQoDE?= =?us-ascii?q?AsYAgImAgJXBg0IAQGFGKoXgiaEb4NDJ4IagQ2EKIMCgxEMgnmIKYJiBJM5hx0?= =?us-ascii?q?JiVOHCYkShVaSdDQigVJ7CjqCRIRHjQQBAQE?= X-IronPort-AV: E=Sophos;i="5.47,455,1515452400"; d="scan'208";a="317398810" Received: from 105.ip-145-239-83.eu (HELO matej-kosik.net) ([145.239.83.105]) by mail2-smtp-roc.national.inria.fr with ESMTP; 11 Mar 2018 16:51:22 +0100 Received: from [192.168.1.11] (bband-dyn63.178-40-202.t-com.sk [178.40.202.63]) by matej-kosik.net (Postfix) with ESMTPSA id 4647B226E1; Sun, 11 Mar 2018 16:51:21 +0100 (CET) To: =?UTF-8?Q?Nicol=c3=a1s_Ojeda_B=c3=a4r?= Cc: OCaml Mailing List References: <97fc418b-c016-7a7f-77ae-3823bf4b8a12@matej-kosik.net> From: =?UTF-8?B?TWF0ZWogS2/FocOtaw==?= Openpgp: id=1CD41D0A52319DC7ABC1B79F50AFFA128CE48649; url=http://matej-kosik.net/doc/kosik.asc Message-ID: <81818a99-0a21-f5b3-8708-7a4c99d13935@matej-kosik.net> Date: Sun, 11 Mar 2018 16:51:20 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [Caml-list] a question about Ocaml toplevel behavior Hi Nicolás, Thank you for the reply. On 03/11/18 16:06, Nicolás Ojeda Bär wrote: > Hello Matej, > > My understanding is that the compiler will delay opening a .cmi file > until absolutely necessary.> Since it does not need to look into Location in order to compile the > given phrase, the .cmi is not opened and the type Location.t remains > abstract. But if you give the compiler an excuse to open location.cmi > then the definition of the type Location.t will become known to the > compiler and the toplevel will be able to print the values concretely. I see some of the disadvantages of this behavior: (0) I have lost time wondering why things are printed as "" instead of the real thing. (1) "" may (confusingly) mean something else than "a value of an abstract type". It may mean that "toplevel has find an excuse not to load a relevant *.cmi file some so it does not know (yet) how to print a given value. (this is very unintuitive) (2) #install_printer directive may have no effect if toplevel has find an excuse not to load relevant *.cmi file. (this is very unintuitive) Was this done on purpose? What do we gain from this behavior? (considering that computer time (as opposed to human time) has ~zero value).