caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: William Chesters <williamc@dai.ed.ac.uk>
To: caml-list@inria.fr
Subject: Very very short question on objects
Date: Mon, 25 Oct 1999 20:31:55 +0100	[thread overview]
Message-ID: <199910251931.UAA11747@toy.william.bogus> (raw)
In-Reply-To: <19991025114616.B226@jones.int-evry.fr>

Christian RINDERKNECHT writes:
 > Method [f] is not private... Shouldn't be this an error?

It's deliberate: from node3.html#ss:private-methods in the html docs:

    Private methods can be made public in a subclass.  [...]  One
    could think that a private method should remain private in a
    subclass.  However, it since the method is visible in a subclass,
    it is always possible pick it's code and define a method of the
    same name that run that code, [...]

In other words, ocaml's `private' is more like Java's `protected', and
afair Java's behaviour here agrees with ocaml's.




  reply	other threads:[~1999-10-26  6:44 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-10-25  9:46 Christian RINDERKNECHT
1999-10-25 19:31 ` William Chesters [this message]
1999-10-25 20:33 ` Emmanuel CHAILLOUX

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=199910251931.UAA11747@toy.william.bogus \
    --to=williamc@dai.ed.ac.uk \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).