author | Oleksandr Gavenko <gavenkoa@gmail.com> |
Mon, 22 Feb 2016 12:41:52 +0200 | |
changeset 1903 | 901e7394849f |
parent 1480 | c8f7a7a5c5f8 |
child 1905 | fba288d59662 |
permissions | -rw-r--r-- |
1479
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
1 |
.. -*- coding: utf-8; -*- |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
2 |
.. include:: HEADER.rst |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
3 |
|
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
4 |
======= |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
5 |
Perl. |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
6 |
======= |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
7 |
.. contents:: |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
8 |
|
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
9 |
Print stack trace in Perl. |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
10 |
========================== |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
11 |
:: |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
12 |
|
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
13 |
use Devel::StackTrace; |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
14 |
my $trace = Devel::StackTrace->new; |
446235725c2b
Print stack trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff
changeset
|
15 |
print $trace->as_string; # like carp |
1480
c8f7a7a5c5f8
Print execution trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1479
diff
changeset
|
16 |
|
c8f7a7a5c5f8
Print execution trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1479
diff
changeset
|
17 |
Print execution trace in Perl. |
c8f7a7a5c5f8
Print execution trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1479
diff
changeset
|
18 |
============================== |
c8f7a7a5c5f8
Print execution trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1479
diff
changeset
|
19 |
|
c8f7a7a5c5f8
Print execution trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1479
diff
changeset
|
20 |
``Devel::Trace`` print out each line before it is executed (like ``sh -x``). |
c8f7a7a5c5f8
Print execution trace in Perl.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1479
diff
changeset
|
21 |