Softpanorama
(slightly skeptical) Open Source Software Educational Society

May the source be with you, but remember the KISS principle ;-)

Softpanorama Search

Perl Xref

Old News
;-)

See also

Recommended Books Recommended Links

Perl for Unix System Administrators

Reference

Perl Language

Perl Xref Debugging regular expressions Perlrun man page Perl Style Regular expressions Perl Programming Environment Pipes
Debugging Software Testing Program understanding Pretty Printing Perl Tips Humor Etc

The most useful option the cross referencer has is to save the report to a separate file.  For instance, to save the report on myperlprogram  to the file report:

         $ perl -MO=Xref,-oreport myperlprogram
 

The cross referencing back end (B::Xref) produces a report on your program, breaking down declarations and uses of subroutines and  variables (and formats) by file and subroutine.  For instance, here's   part of the report from the pod2man program that comes with Perl:

         Subroutine clear_noremap
           Package (lexical)
             $ready_to_print   i1069, 1079
           Package main
             $&                1086
             $.                1086
             $0                1086
             $1                1087
             $2                1085, 1085
             $3                1085, 1085
             $ARGV             1086
             %HTML_Escapes     1085, 1085

       This shows the variables used in the subroutine "clear_noremap".  The
       variable $ready_to_print is a my() (lexical) variable, introduced
       (first declared with my()) on line 1069, and used on line 1079.  The
       variable $& from the main package is used on 1086, and so on.

       A line number may be prefixed by a single letter:

       i   Lexical variable introduced (declared with my()) for the first
           time.

       &   Subroutine or method call.

       s   Subroutine defined.

       r   Format defined.
 


Notes:
  • This is a Spartan WHYFF (We Help You For Free) site written by people for whom English is not a native language. Some amount of grammar and spelling errors should be expected.
  • The site contain some broken links as it develops like a living tree... Please try to use Google, Open directory, etc. to find a replacement link (see HOWTO search the WEB for details). We would appreciate if you can mail us a correct link.
Google Search
Open directory

Research Index


Recommended Links

BXref - Generates cross reference reports for Perl programs

CPANXR

Perl Cross-Reference Tool

 



Copyright © 1996-2009 by Dr. Nikolai Bezroukov. www.softpanorama.org was created as a service to the UN Sustainable Development Networking Programme (SDNP) in the author free time. Submit comments This document is an industrial compilation designed and created exclusively for educational use and is placed under the copyright of the Open Content License(OPL). Site uses AdSense so you need to be aware of Google privacy policy. Original materials copyright belong to respective owners. Quotes are made for educational purposes only in compliance with the fair use doctrine.

Disclaimer:

Last updated: August 15, 2009