Perl Programming Language

How to list all the nested modules

How to list all the nested modules, similar to dependency in C-compiler (gcc -M)?

For example,

use Net::SSH::Perl::Packet; use Net::SSH::Perl::Buffer; use Net::SSH::Perl::Config; use Net::SSH::Perl::Constants qw( :protocol :compat :hosts ); use Net::SSH::Perl::Cipher; use Net::SSH::Perl::Util qw( :hosts _read_yes_or_no ); use IO::Socket; use IO::Select; use Socket; use Fcntl; use Symbol; use Errno qw(EAGAIN EWOULDBLOCK); use Carp qw(croak); use Sys::Hostname;