diff options
author | anatoly techtonik <techtonik@gmail.com> | 2015-11-11 18:44:46 (GMT) |
---|---|---|
committer | anatoly techtonik <techtonik@gmail.com> | 2015-11-11 18:44:46 (GMT) |
commit | ebc3286289111b5134032f03c29cb8a0ef7d5d34 (patch) | |
tree | 006439d45f16347b3bfbc873e710ec654710aada /src/engine | |
parent | 2d6ae148c1a3c49fb8400f7de0787e1179aab53c (diff) | |
download | SCons-ebc3286289111b5134032f03c29cb8a0ef7d5d34.zip SCons-ebc3286289111b5134032f03c29cb8a0ef7d5d34.tar.gz SCons-ebc3286289111b5134032f03c29cb8a0ef7d5d34.tar.bz2 |
Document SCons.Debug.caller_trace() behavior
Diffstat (limited to 'src/engine')
-rw-r--r-- | src/engine/SCons/Debug.py | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/engine/SCons/Debug.py b/src/engine/SCons/Debug.py index b47c24c..9e520ff 100644 --- a/src/engine/SCons/Debug.py +++ b/src/engine/SCons/Debug.py @@ -1,7 +1,10 @@ """SCons.Debug Code for debugging SCons internal things. Shouldn't be -needed by most users. +needed by most users. Quick shortcuts: + +from SCons.Debug import caller_trace +caller_trace() """ @@ -137,8 +140,12 @@ def caller_stack(): caller_bases = {} caller_dicts = {} -# trace a caller's stack def caller_trace(back=0): + """ + Trace caller stack and save info into global dicts, which + are printed automatically at the end of SCons execution. + """ + global caller_bases, caller_dicts import traceback tb = traceback.extract_stack(limit=3+back) tb.reverse() |