From 85d32e329daf4efbd64c583e38e92e5cae6bd7da Mon Sep 17 00:00:00 2001 From: Ulf Magnusson Date: Sat, 6 Jun 2015 03:47:26 +0200 Subject: Use 'raise A(b)' instead of 'raise A, b'. Bit neater, and Python 3-friendly. --- kconfiglib.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'kconfiglib.py') diff --git a/kconfiglib.py b/kconfiglib.py index 0e8830c..81659ca 100644 --- a/kconfiglib.py +++ b/kconfiglib.py @@ -3667,14 +3667,14 @@ class Internal_Error(Exception): def _tokenization_error(s, filename, linenr): loc = "" if filename is None else "{0}:{1}: ".format(filename, linenr) - raise Kconfig_Syntax_Error, "{0}Couldn't tokenize '{1}'" \ - .format(loc, s.strip()) + raise Kconfig_Syntax_Error("{0}Couldn't tokenize '{1}'" + .format(loc, s.strip())) def _parse_error(s, msg, filename, linenr): loc = "" if filename is None else "{0}:{1}: ".format(filename, linenr) - raise Kconfig_Syntax_Error, "{0}Couldn't parse '{1}'{2}" \ - .format(loc, s.strip(), - "." if msg is None else ": " + msg) + raise Kconfig_Syntax_Error("{0}Couldn't parse '{1}'{2}" + .format(loc, s.strip(), + "." if msg is None else ": " + msg)) def _internal_error(msg): raise Internal_Error, msg + \ -- cgit v1.2.3