mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-08 06:44:46 +08:00
REPL completion is working again partially. There's some progress at least.
This commit is contained in:
@@ -7,8 +7,7 @@ import inspect
|
||||
from jedi import common
|
||||
from jedi.parser.fast import FastParser
|
||||
from jedi.evaluate import compiled
|
||||
from jedi.cache import underscore_memoization, memoize_method
|
||||
from jedi.evaluate.cache import memoize_default
|
||||
from jedi.cache import underscore_memoization
|
||||
|
||||
|
||||
class MixedObject(object):
|
||||
@@ -38,6 +37,15 @@ class MixedObject(object):
|
||||
assert search_global is False
|
||||
return [LazyMixedNamesDict(self._evaluator, self, is_instance=False)]
|
||||
|
||||
def api_type(self):
|
||||
mappings = {
|
||||
'expr_stmt': 'statement',
|
||||
'classdef': 'class',
|
||||
'funcdef': 'function',
|
||||
'file_input': 'module',
|
||||
}
|
||||
return mappings[self._definition.type]
|
||||
|
||||
def __repr__(self):
|
||||
return '<%s: %s>' % (type(self).__name__, repr(self.obj))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user