Loading ...
Sorry, an error occurred while loading the content.

18215Re: what's the module that dumps all the code in a script?

Expand Messages
  • Paul Archer
    Mar 4, 2004
      I hate answering my own post, but since I finally found the answer, I
      thought I'd save someone else from having to deal with my addled brain.
      The answer (drumroll please) is B::Deparse.
      For example:

      [run this]
      perl -MO=Deparse,-p -e 'foreach (qw/a b c d e/){ print "$_\n"}'

      [and get this output]
      foreach $_ (('a', 'b', 'c', 'd', 'e')) {
      -e syntax OK

      Bartles "Thank you for your support" N. James

      2:13pm, Paul Archer wrote:

      > I really hate this, but I've got a complete block on the name of the module,
      > that when invoked, takes all the bytecode from a script and recreates the
      > script. I know I've seen an example where a 'for' loop is invoked with
      > 'foreach' and vice versa, and it shows that Perl does the right thing(TM)...
      > TIA,
      > Paul
      > --------------------------------------------------
      > I got an announcement recently for a conference on
      > massively parallel computing systems.
      > They sent me 600 copies.
      > --------------------------------------------------

      "We Americans, we're a simple people...
      but piss us off, and we'll bomb your cities."
      --------------Robin Williams------------------
    • Show all 2 messages in this topic