Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at ocaml.org.

Browse thread
class virtual vs class type?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2002-05-02 (21:42)
From: bwv211mail <bwv211mail@y...>
Subject: Re: "ocaml_beginners"::[] class virtual vs class type?
Thanks for the reply. Just as a followup, is there an internal
difference (more memory use, etc) between:

class foo () = ...
class bar ... = object ... inherit foo () ... end

and

class foo = ...
class bar ... = object ... inherit foo ... end

In other words, does using the unit parameter make it "cons" a new
object instead of reusing a constant object?