forked from VimPlug/jedi
splitlines and source_to_unicode are utils of parso.
This commit is contained in:
@@ -4,13 +4,14 @@ Helpers for the API
|
||||
import re
|
||||
from collections import namedtuple
|
||||
|
||||
from jedi._compatibility import u
|
||||
from jedi.evaluate.helpers import evaluate_call_of_leaf
|
||||
from parso.python.parser import Parser
|
||||
from parso.python import tree
|
||||
from parso import tokenize
|
||||
from parso.utils import splitlines
|
||||
|
||||
from jedi._compatibility import u
|
||||
from jedi.evaluate.helpers import evaluate_call_of_leaf
|
||||
from jedi.cache import time_cache
|
||||
from jedi import common
|
||||
|
||||
|
||||
CompletionParts = namedtuple('CompletionParts', ['path', 'has_dot', 'name'])
|
||||
@@ -52,7 +53,7 @@ class OnErrorLeaf(Exception):
|
||||
|
||||
|
||||
def _is_on_comment(leaf, position):
|
||||
comment_lines = common.splitlines(leaf.prefix)
|
||||
comment_lines = splitlines(leaf.prefix)
|
||||
difference = leaf.start_pos[0] - position[0]
|
||||
prefix_start_pos = leaf.get_start_pos_of_prefix()
|
||||
if difference == 0:
|
||||
|
||||
Reference in New Issue
Block a user