From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id E8183BB81 for ; Sat, 25 Feb 2006 13:17:15 +0100 (CET) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id k1PCHFtM014284 for ; Sat, 25 Feb 2006 13:17:15 +0100 Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id NAA19254 for ; Sat, 25 Feb 2006 13:17:14 +0100 (MET) Received: from einhorn.in-berlin.de (einhorn.in-berlin.de [192.109.42.8]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id k1PCHDBl014279 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL) for ; Sat, 25 Feb 2006 13:17:14 +0100 X-Envelope-From: oliver@first.in-berlin.de X-Envelope-To: Received: from first.in-berlin.de (e178033193.adsl.alicedsl.de [85.178.33.193]) (authenticated bits=0) by einhorn.in-berlin.de (8.12.10/8.12.10/Debian-4) with ESMTP id k1PCHC6r024884 for ; Sat, 25 Feb 2006 13:17:13 +0100 Received: by first.in-berlin.de (Postfix, from userid 501) id 2C5FA2217A1; Sat, 25 Feb 2006 13:16:28 +0100 (CET) Date: Sat, 25 Feb 2006 13:16:28 +0100 From: Oliver Bandel To: caml-list@inria.fr Subject: Re: [Caml-list] multiple inheritance, bug or feature ? Message-ID: <20060225121628.GA533@first.in-berlin.de> References: <440038EC.5060302@yahoo.fr> <20060225114859.GA460@first.in-berlin.de> <44004903.5050104@yahoo.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <44004903.5050104@yahoo.fr> User-Agent: Mutt/1.5.6i X-Scanned-By: MIMEDefang_at_IN-Berlin_e.V. on 192.109.42.8 X-Miltered: at concorde with ID 44004ACB.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at concorde with ID 44004AC9.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; oliver:01 bandel:01 oliver:01 in-berlin:01 caml-list:01 bug:01 bandel:01 'x':01 wrote:01 wrote:01 behaviour:01 behaviour:01 warnings:02 inheritance:03 ecrit:04 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.1 required=5.0 tests=FORGED_RCVD_HELO autolearn=disabled version=3.0.3 On Sat, Feb 25, 2006 at 01:09:39PM +0100, sejourne_kevin wrote: > Oliver Bandel a écrit : > > >>When I wrote this program I expect this behavior but > >>according to the warnings M the result should be 3. > > > > > >Why do you think the expected behaviour should be > >printing the 3? > > > >Your method prints the old value, not the new value. > > > I know that. That is not the problem. The problem is that > there is two references on two differents values. > set_x_a' set_x_a are not using the same 'x'. Yes. As you called one of your internal states "y", not "x" I would expect the behaviour that your implementation shows. But I changes then in class b the "y" to "x" and it showed the same behaviour. Well, this is what I didn't expected... and the error messages, on which I now looked in more detail, well, are strange... (also in your case...) ?! Ciao, Oliver