Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] Is there a compact syntax for masking methods in an inherit
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Jacques Garrigue <garrigue@k...>
Subject: Re: [Caml-list] Is there a compact syntax for masking methods in an inherit
From: "Ryan R. Newton" <newton@MIT.EDU>
> 
> > >    class c =
> > >    object
> > >      inherit a
> >        method virtual g : int
> > >      inherit b  
> > >      method h = 99
> > >    end
> 
> > Would this avoid your problem?
> > Other solutions would imply new syntax, for something that is no more
> > than a warning.
> 
> Yes, that would be super cool.  That solution provides exactly what I
> wanted, which was an explicit articulation *in the code* of which
> methods are being overridden, for readabilities' sake.  (So I think I'll
> start doing that regardless of whether it disables the warnings.)

OK, I've commited the change, and the warning is now effectively
disabled in this case. Only the warning behaviour is changed.

This will be in 3.07, except if somebody has a good reason against it.

Jacques Garrigue

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners