* 'open' on objects?
@ 2008-09-02 19:03 Chris Clearwater
2008-09-02 20:25 ` [Caml-list] " Peng Zang
0 siblings, 1 reply; 2+ messages in thread
From: Chris Clearwater @ 2008-09-02 19:03 UTC (permalink / raw)
To: caml-list
Is it possible to create an object by extending another object?
I'd like to do something like this:
...
object
open (an_object:class_type)
...
end
...
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Caml-list] 'open' on objects?
2008-09-02 19:03 'open' on objects? Chris Clearwater
@ 2008-09-02 20:25 ` Peng Zang
0 siblings, 0 replies; 2+ messages in thread
From: Peng Zang @ 2008-09-02 20:25 UTC (permalink / raw)
To: caml-list; +Cc: Chris Clearwater
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Tuesday 02 September 2008 03:03:28 pm Chris Clearwater wrote:
> Is it possible to create an object by extending another object?
>
> I'd like to do something like this:
>
> ...
> object
> open (an_object:class_type)
> ...
> end
> ...
The short answer is I think you can only extend classes (through inheritance).
I don't think you can extend an object (eg. add methods to an object).
Peng
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.7 (GNU/Linux)
iD8DBQFIvaFZfIRcEFL/JewRAvcSAKDOTE2+niYho6tTHbhI4h7h3L5K0wCfdXti
LM7dnZLJTrGnCcQoh5M6tCU=
=KBtf
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-09-02 20:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-09-02 19:03 'open' on objects? Chris Clearwater
2008-09-02 20:25 ` [Caml-list] " Peng Zang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox