summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/flake8/processor.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/flake8/processor.py b/src/flake8/processor.py
index 1d0e3a4..2a4014e 100644
--- a/src/flake8/processor.py
+++ b/src/flake8/processor.py
@@ -247,7 +247,7 @@ class FileProcessor(object):
# course, I'm going to be unsurprised to be proven wrong at a later
# date.
except tokenize.TokenError as exc:
- raise exceptions.InvalidSyntax(exc.message, exception=exc)
+ raise exceptions.InvalidSyntax(str(exc), exception=exc)
def line_for(self, line_number):
"""Retrieve the physical line at the specified line number."""