At 05:04 PM 11/21/00 +0000, Nicholas Clark wrote: >(I'm not sure if I've missed all the fun here before I subscribed, but >I can't anything on the RFC list that mentions the following) > >perl5 has a tangle of SvPV macros to allow C code to get a pointer >to the scalar. (or the "private", with or without the length, and >more relating to utf8 that don't even appear to be documented) > >Has any thought yet been given to the API to get scalars? Yup. The internal details will be hidden from the extension writer--if you do a get_string(PMC, UTF_8) you get back the UTF-8 encoded version of the scalar that PMC represents, regardless of any internal format. That way if some scalar function writer has some need to do odd things they can without having to worry about telling extension writers. It also means that an extension doesn't have to care that a PMC represents, say, a complex number--they ask for it in UTF-8 format and get back "4 + 3i" and that's fine. This isolation will also reduce cross-version breakage. While I'd like to eliminate that, I doubt it's entirely feasable. It'll be possible to get the gory details if you want them, but then you'll have to go a step lower in the API and, well, the docs say "Here there be dragons". Or they will, at least. One of the things we need to hammer out on the extension API list is exactly what sorts of things need to be generally exposed to extensions and what don't. Dan --------------------------------------"it's like this"------------------- Dan Sugalski even samurai [EMAIL PROTECTED] have teddy bears and even teddy bears get drunk