At 10:17 PM +0530 11/21/02, Gopal V wrote:
If memory serves me right, Dan Sugalski wrote:Currently open is the situation of flags and such from more complex calls. (Like what we do if we get back a pointer that's getting stuffed into a PMC--do we set the type, if so what type, and what do we set the flags to?)So is it totally type unsafe ? ... (as you know I'm obsessed with type safety) ...
Oh, absolutely! 100% guaranteed type unsafe.
I do actually like it. I was shooting for simplicity with the assumption that, since we were calling out to non-parrot-aware code, all bets were off with respect to type safety. If you load in libgtk.so and call functions dynamically there's not much we can do with respect to proper security."pMYPMC;pp" Does this appeal to anybody .... [Disclaimer: idea borrowed totally from JVM signatures "Ljava/lang/String;(Ljava/lang/String;i)"... Where the Long 'L' was later on modified to carry type info of the pointer...]
Having said that, now I'm getting that XML feeling. (You know the one--"It seemed like a good idea until I thought about it" :)
The question, then, is how do we embed typesafe info into the call PMC such that we can check reasonably efficiently?
Oh, that was for other things entirely. I have this vague feeling that we should be as close to totally introspective as we can manage. I'm not sure if it should be everything-read/some-write or everything-read/everything-write, but...> I'm thinking, as part of this, that more introspection on buffers andPMCs is in order, so we can have bytecode manipulate their flags and types properly.Well that does not totally satisfy me .... I might be expecting a XPMC when the pointer is stuffed into a YPMC and my program blows up in the middle .... (of course throwing an exception is not technically blowing up, it's damage control)..
No problem with that. I think you're not going to get it by default, since my big thing's speed, but it does mean we need to reevaluate things, since we need typechecking in safe code.But well ... I should admit , I'm just trying to make the C# to parrot compilation as safe as IL .... (PInvoke and stuff...)
--
Dan
--------------------------------------"it's like this"-------------------
Dan Sugalski even samurai
[EMAIL PROTECTED] have teddy bears and even
teddy bears get drunk