summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/decorator.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/decorator.py b/src/decorator.py
index 44303ee..dceca03 100644
--- a/src/decorator.py
+++ b/src/decorator.py
@@ -173,7 +173,8 @@ class FunctionMaker(object):
# Ensure each generated function has a unique filename for profilers
# (such as cProfile) that depend on the tuple of (<filename>,
# <definition line>, <function name>) being unique.
- filename = '<decorator-gen-%d>' % (next(self._compile_count),)
+ filename = '<%s:decorator-gen-%d>' % (
+ __file__, next(self._compile_count))
try:
code = compile(src, filename, 'single')
exec(code, evaldict)