From: "Michael Wohlwend" <micha-1@fantasymail.de>
To: caml-list@inria.fr
Subject: memory handling with native code
Date: Thu, 24 Aug 2006 10:59:34 +0200 [thread overview]
Message-ID: <20060824085934.198440@gmx.net> (raw)
I'm trying to make an interface to a c++ lib of a friend of me, it's getting better, but questions about the memory management came up:
Say there is a c++ class widget, which I want to mirror on the ocaml side. So I implemented a c++ widget-adapter, which inherits from widget and forwards events to the ocaml widget class. This works fine, but how to delete the widget adapter? In the case the ocaml class gets destroyed by the gc the adapter on the native side is still there.
Should I wrap the pointer in a custom object?
cheers,
Michael
--
"Feel free" – 10 GB Mailbox, 100 FreeSMS/Monat ...
Jetzt GMX TopMail testen: http://www.gmx.net/de/go/topmail
next reply other threads:[~2006-08-24 14:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-24 8:59 Michael Wohlwend [this message]
2006-08-24 15:46 ` [Caml-list] " skaller
2006-08-24 16:47 ` Bardur Arantsson
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=20060824085934.198440@gmx.net \
--to=micha-1@fantasymail.de \
--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