From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id p7RKLbFr007258 for ; Sat, 27 Aug 2011 22:21:37 +0200 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AqoAAF1QWU7RVdo2mGdsb2JhbABCqAgIFAEBAQEBCAkNBxQlgUABAQEBAxICLAEbHQEDDAYFCwMKLiIBEQEFARwGEyKjVwqMO4JVhBA7iG0CAwaGRgSHZIs7jGE8hAc X-IronPort-AV: E=Sophos;i="4.68,290,1312149600"; d="scan'208";a="106831573" Received: from mail-yi0-f54.google.com ([209.85.218.54]) by mail4-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 27 Aug 2011 22:21:33 +0200 Received: by yib19 with SMTP id 19so3690268yib.27 for ; Sat, 27 Aug 2011 13:21:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=wc8nTT+mHXUUntYPKbpCnSGWsWzNAAvkULZk3HUV4fo=; b=j/pxfflexZn3NoHQ8V8fL6D5KMFOXdcBkCybJfdsb9NjFcwxri9Ay9nfybMHy2D71E u76fMTY1w3bullmaMUn4b+5YudaPxaESu534XmIqQHCxCta6+sIi9WKkNoIETsNnXWsT reFpAE0GGurSwblAzqHqItwxbib+kg35+jII0= MIME-Version: 1.0 Received: by 10.42.29.193 with SMTP id s1mr2668190icc.439.1314476492556; Sat, 27 Aug 2011 13:21:32 -0700 (PDT) Received: by 10.42.167.69 with HTTP; Sat, 27 Aug 2011 13:21:32 -0700 (PDT) In-Reply-To: <1314473840.3496.132.camel@thinkpad> References: <4E58CCC3.4040901@gmail.com> <1314457588.3496.86.camel@thinkpad> <1314473840.3496.132.camel@thinkpad> Date: Sat, 27 Aug 2011 13:21:32 -0700 Message-ID: From: Jeff Meister To: Gerd Stolpmann Cc: david.baelde@ens-lyon.org, Chris Yocum , caml-list@inria.fr Content-Type: text/plain; charset=ISO-8859-1 Subject: Re: [Caml-list] Ocaml and the Fragile Base Class Problem I don't understand this part. You can easily hide a public method of an object by coercing it to an object type which does not have that method. Modules also provide excellent information hiding: if you don't want anyone else calling your method, make at least one of its input types abstract in the interface, and don't provide any values of that type. On Sat, Aug 27, 2011 at 12:37 PM, Gerd Stolpmann wrote: > I guess the biggest problem is that structural > typing does not offer much for getting information hiding - once a > method is public, it is fully public. This is, in some sense, against > the mindset of the typical OCaml programmer.