summaryrefslogtreecommitdiff
path: root/igor.py
diff options
context:
space:
mode:
Diffstat (limited to 'igor.py')
-rw-r--r--igor.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/igor.py b/igor.py
index 9dadf595..4ea65fad 100644
--- a/igor.py
+++ b/igor.py
@@ -313,8 +313,11 @@ def analyze_args(function):
star(boolean): Does `function` accept *args?
num_args(int): How many positional arguments does `function` have?
"""
- with ignore_warnings():
- argspec = inspect.getargspec(function)
+ try:
+ getargspec = inspect.getfullargspec
+ except AttributeError:
+ getargspec = inspect.getargspec
+ argspec = getargspec(function)
return bool(argspec[1]), len(argspec[0])