summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--astroid/scoped_nodes.py2
-rw-r--r--astroid/tests/unittest_scoped_nodes.py2
-rw-r--r--astroid/tests/unittest_transforms.py2
3 files changed, 3 insertions, 3 deletions
diff --git a/astroid/scoped_nodes.py b/astroid/scoped_nodes.py
index 144cd83b..dba9a8e7 100644
--- a/astroid/scoped_nodes.py
+++ b/astroid/scoped_nodes.py
@@ -1526,7 +1526,7 @@ class FunctionDef(node_classes.Statement, Lambda):
return next(self.nodes_of_class(yield_nodes,
skip_klass=(FunctionDef, Lambda)), False)
- def infer_call_result(self, caller, context=None):
+ def infer_call_result(self, caller=None, context=None):
"""Infer what the function returns when called.
:returns: What the function returns.
diff --git a/astroid/tests/unittest_scoped_nodes.py b/astroid/tests/unittest_scoped_nodes.py
index dcbc1274..b8682461 100644
--- a/astroid/tests/unittest_scoped_nodes.py
+++ b/astroid/tests/unittest_scoped_nodes.py
@@ -1517,7 +1517,7 @@ class ClassNodeTest(ModuleLoader, unittest.TestCase):
def test(): #@
yield
""")
- result = next(func.infer_call_result(func))
+ result = next(func.infer_call_result())
self.assertIsInstance(result, Generator)
self.assertEqual(result.parent, func)
diff --git a/astroid/tests/unittest_transforms.py b/astroid/tests/unittest_transforms.py
index b6b7c9d8..cca47130 100644
--- a/astroid/tests/unittest_transforms.py
+++ b/astroid/tests/unittest_transforms.py
@@ -146,7 +146,7 @@ class TestTransforms(unittest.TestCase):
for decorator in node.decorators.nodes:
inferred = next(decorator.infer())
if inferred.qname() == 'abc.abstractmethod':
- return next(node.infer_call_result(node))
+ return next(node.infer_call_result())
return None
manager = builder.MANAGER