diff options
author | Zachary Turner <zturner@google.com> | 2015-11-03 21:01:45 +0000 |
---|---|---|
committer | Zachary Turner <zturner@google.com> | 2015-11-03 21:01:45 +0000 |
commit | 9618980a19d4234d93dd69f92f6b875e72b89a1b (patch) | |
tree | 4a3bc6082b7355a4ed6f4a929f28f32ec852e961 /lldb/third_party | |
parent | c8a7913f23460112182b5216fa2cde084886cad4 (diff) | |
download | bcm5719-llvm-9618980a19d4234d93dd69f92f6b875e72b89a1b.tar.gz bcm5719-llvm-9618980a19d4234d93dd69f92f6b875e72b89a1b.zip |
Python 3: Modernize exception raising syntax.
Old-style: `raise foo, bar`
New-style: `raise foo(bar)`
These two statements are equivalent, but the former is an error in
Python 3.
llvm-svn: 251977
Diffstat (limited to 'lldb/third_party')
-rw-r--r-- | lldb/third_party/Python/module/unittest2/unittest2/case.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lldb/third_party/Python/module/unittest2/unittest2/case.py b/lldb/third_party/Python/module/unittest2/unittest2/case.py index 29103c8b700..485cef09c22 100644 --- a/lldb/third_party/Python/module/unittest2/unittest2/case.py +++ b/lldb/third_party/Python/module/unittest2/unittest2/case.py @@ -510,7 +510,7 @@ class TestCase(unittest.TestCase): excName = excClass.__name__ else: excName = str(excClass) - raise self.failureException, "%s not raised" % excName + raise self.failureException("%s not raised" % excName) def _getAssertEqualityFunc(self, first, second): """Get a detailed comparison function for the types of the two args. @@ -1028,7 +1028,7 @@ class TestCase(unittest.TestCase): excName = expected_exception.__name__ else: excName = str(expected_exception) - raise self.failureException, "%s not raised" % excName + raise self.failureException("%s not raised" % excName) def assertRegexpMatches(self, text, expected_regexp, msg=None): |