[gambit-list] Question about |##still-copy| and a |##still?| typechecker

Phillip Suero philsuero at gmail.com
Mon Oct 12 09:01:08 EDT 2020

Dear Marc,

I am sending over an u8vector from the Scheme world to the C world.
Of course the u8vector must be still, so that its heap allocated object's
memory address is not moved by Gambit's memory system.
To get clear on this topic, I have three quick questions for you:

(1) I see there's the function |##still-copy| in Gambit's runtime.
Browsing its code I don't see the keyword ___STILL mentioned anywhere in
it. How does it get the ___STILL property, is that an implicit argument to
___alloc_scmobj ?

(2) Is |##still-copy| a "universal copier" of any heap allocated object,
into an equivalent of itself that is ___STILL, so I can use it for, say,
u32vector, floating point number, complex number, string, Scheme struct?

(3) Is there any checker in Gambit's runtime, e.g. a |##still?|, whereby I
can check if a heap allocated object is ___STILL already?

Your clarification is much appreciated, thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.iro.umontreal.ca/pipermail/gambit-list/attachments/20201012/ec64c7b3/attachment.htm>

More information about the Gambit-list mailing list