Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: Re: PadWalker and Safe - getting the lexicals

by shushu (Scribe)
on Oct 13, 2002 at 15:33 UTC ( [id://204902]=note: print w/replies, xml ) Need Help??


in reply to Re: PadWalker and Safe - getting the lexicals
in thread PadWalker and Safe - getting the lexicals

Hi (all and robin),
Well, we had a good "fight", but now we are sure that in order to get the lexical information we do need to get into perlguts.
The question now is - how to do it ?
From where do we start ?
Unfortunately we don't have the time to play around, and we need to understand fast whether it will take us 2 days or 2 weeks. Too many deadlines...

- Do we need to get into Perl code, or do we need only PadWalker code ?
- Where do we get PadWalker code ?
- Does a standard RH 7.3 installation is enough, or should we get some other development environment ?

TIA,
shushu

Replies are listed 'Best First'.
Re^3: PadWalker and Safe - getting the lexicals
by diotalevi (Canon) on Oct 13, 2002 at 15:46 UTC

    I haven't been motivated enough to see what the inside of a Safe::Hole->reval looks like but now that you've decided to go perlguts your first thing to do is to look at the B module. In my sig you'll notice an example of a script getting the current CV via B::svref_2object(sub {} )->OUTSIDE. I would initially recommend you read Gisle Aas' Illustrated PerlGuts, then Simon Cozens' internals tutorial and if that isn't enough descend into perlguts and perlhack. The key here is you're just walking structures. You aren't going to have to alter stuff so the documentation is to guide you in using B to walk all over.

    __SIG__ printf "You are here %08x\n", unpack "L!", unpack "P4", pack "L!", B:: +svref_2object(sub{})->OUTSIDE

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://204902]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (7)
As of 2024-03-28 11:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found