mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-07 22:44:27 +08:00
Fix a TODO
This commit is contained in:
@@ -93,7 +93,7 @@ def _add_strings(context, nodes, add_slash=False):
|
|||||||
return None
|
return None
|
||||||
if not first and add_slash:
|
if not first and add_slash:
|
||||||
string += os.path.sep
|
string += os.path.sep
|
||||||
string += str(s, errors='replace')
|
string += s
|
||||||
first = False
|
first = False
|
||||||
return string
|
return string
|
||||||
|
|
||||||
|
|||||||
@@ -144,7 +144,7 @@ def get_int_or_none(value):
|
|||||||
|
|
||||||
|
|
||||||
def get_str_or_none(value):
|
def get_str_or_none(value):
|
||||||
return _get_safe_value_or_none(value, (bytes, unicode))
|
return _get_safe_value_or_none(value, str)
|
||||||
|
|
||||||
|
|
||||||
def is_number(value):
|
def is_number(value):
|
||||||
|
|||||||
@@ -244,9 +244,7 @@ current_dirname = os.path.basename(dirname(dirname(dirname(__file__))))
|
|||||||
('example.py', 'x = f("te" + "st"', 16, [s]),
|
('example.py', 'x = f("te" + "st"', 16, [s]),
|
||||||
('example.py', 'x = f("te" + "st")', 16, [s]),
|
('example.py', 'x = f("te" + "st")', 16, [s]),
|
||||||
('example.py', 'x = f("t" + "est")', 16, [s]),
|
('example.py', 'x = f("t" + "est")', 16, [s]),
|
||||||
# This is actually not correct, but for now leave it here, because of
|
('example.py', 'x = f(b"t" + "est")', 17, []),
|
||||||
# Python 2.
|
|
||||||
('example.py', 'x = f(b"t" + "est")', 17, [s]),
|
|
||||||
('example.py', '"test" + "', None, [s]),
|
('example.py', '"test" + "', None, [s]),
|
||||||
|
|
||||||
# __file__
|
# __file__
|
||||||
|
|||||||
Reference in New Issue
Block a user