in reply to Re^2: Dynamically inspecting Regex OP-Codes at runtime?
in thread Dynamically inspecting Regex OP-Codes at runtime?

I'm still hoping to find something simpler w/o needing to compile XS-modules, preferably within the core.

Pipe dream if you ask me, look at http://perl5.git.perl.org/perl.git/blob#l14597 and http://perl5.git.perl.org/perl.git/blob?f=regcomp.h#l778

I imagine you might be able to peek at a regex structure using B, but you can't get at the debug messages, they're not stored, and you can't hook DEBUG_COMPILE macros

  • Comment on Re^3: Dynamically inspecting Regex OP-Codes at runtime?

Replies are listed 'Best First'.
Re^4: Dynamically inspecting Regex OP-Codes at runtime?
by LanX (Saint) on Jan 30, 2013 at 16:09 UTC
    Thx for the links but thats Chinese for me.

    I'm not a versatile C programmer and AFAIK even C gurus get depressed when diving into perlguts.

    (BTW: the first link is defunc)

    > I imagine you might be able to peek at a regex structure using B,

    that would be nice...

    > but you can't get at the debug messages, they're not stored, and you can't hook DEBUG_COMPILE macros

    What exactly do you mean with "debug messages"? The token tree with commands like OPEN1?

    Or just message like

    anchored "1234" at 0 (checking anchored) minlen 4 Freeing REx: "(?<C>1)(?<D>2)(3)(?<A>4)"

    The latter I don't need! =)

    Cheers Rolf

Re^4: Dynamically inspecting Regex OP-Codes at runtime?
by Anonymous Monk on Jan 30, 2013 at 12:09 UTC
    forgot the :)