1
0
forked from VimPlug/jedi

create an is_callable method for all representation objects, to determine if something is callable or not

This commit is contained in:
Dave Halter
2014-04-02 09:42:15 +02:00
parent d1a6dd1098
commit 305b593f3b
5 changed files with 35 additions and 9 deletions

View File

@@ -118,6 +118,13 @@ class Base(object):
scope = scope.parent
return scope
def is_callable(self):
"""
By default parser objects are not callable, we make them callable by
the ``evaluate.representation`` objects.
"""
return False
def space(self, from_pos, to_pos):
"""Return the space between two tokens"""
linecount = to_pos[0] - from_pos[0]