summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWilliam Deegan <bill@baddogconsulting.com>2015-12-08 21:01:37 (GMT)
committerWilliam Deegan <bill@baddogconsulting.com>2015-12-08 21:01:37 (GMT)
commit78fb1b6ef0e42954feb668efb84de59173221374 (patch)
tree805192ab89744d9efee6b7438ccb7566dd3e8c4f
parent647154f4cc4c3a515927de11229a95d666d8b4d6 (diff)
parentebc3286289111b5134032f03c29cb8a0ef7d5d34 (diff)
downloadSCons-78fb1b6ef0e42954feb668efb84de59173221374.zip
SCons-78fb1b6ef0e42954feb668efb84de59173221374.tar.gz
SCons-78fb1b6ef0e42954feb668efb84de59173221374.tar.bz2
Merged in techtonik/scons (pull request #271)
-rw-r--r--src/engine/SCons/Debug.py11
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()