NAME

Parrot::Pmc2c::PMC::PrintTree

DESCRIPTION

This class inherits from Parrot::Pmc2c::Pmc2cMain and adds one method, print_tree(). print_tree() is called within tools/dev/pmctree.pl.

METHODS

print_tree()

    $self->print_tree( {
        depth   => 0,
        files   => [ @files_to_be_printed ],    # optional
    } );

Purpose: Print the inheritance tree for each of the files, using the given directories to search for all of correct PMCs.

Arguments: Reference to hash holding key-value pairs.

Return Values: 1 upon successful printing.

Comment: print_tree() was formerly found within Parrot::Pmc2c::Pmc2cMain. However, since the primary purpose of that class is to provide methods for a different program, tools/build/pmc2c.pl, which is invoked repeatedly by make, it was felt better to extract this method into a class of its own.

Comment: In earlier version of pmc2c.pl, this subroutine returned undef upon success. This was changed to more Perl-ish 1.