summaryrefslogtreecommitdiff
path: root/astroid/objects.py
diff options
context:
space:
mode:
authorCeridwen <ceridwenv@gmail.com>2015-09-21 16:33:32 -0400
committerCeridwen <ceridwenv@gmail.com>2015-09-21 16:33:32 -0400
commit18fc67e6f514daf584137e20857ebd4ef22aa3ad (patch)
tree4a58c7d4c2abb965f0d66559247065ffe89441ae /astroid/objects.py
parenta1dcb2d18a65be6034459832c91bc5eacbee3c1e (diff)
downloadastroid-git-18fc67e6f514daf584137e20857ebd4ef22aa3ad.tar.gz
Add helper function for reraising exceptions
Diffstat (limited to 'astroid/objects.py')
-rw-r--r--astroid/objects.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/astroid/objects.py b/astroid/objects.py
index 8c0365ef..02fecef8 100644
--- a/astroid/objects.py
+++ b/astroid/objects.py
@@ -26,8 +26,6 @@ leads to an inferred FrozenSet:
"""
-import sys
-
import six
from astroid import bases
@@ -36,6 +34,7 @@ from astroid import exceptions
from astroid import MANAGER
from astroid import node_classes
from astroid import scoped_nodes
+from astroid import util
BUILTINS = six.moves.builtins.__name__
@@ -143,9 +142,7 @@ class Super(bases.NodeNG):
except (exceptions.MroError, exceptions.SuperError) as exc:
# Don't let invalid MROs or invalid super calls
# to leak out as is from this function.
- six.reraise(exceptions.NotFoundError,
- exceptions.NotFoundError(*exc.args),
- sys.exc_info()[2])
+ util.reraise(exceptions.NotFoundError(*exc.args))
found = False
for cls in mro: