forked from VimPlug/jedi
escape text within regex, fixes pydoc problems in windows, thanks to @musicx -> fixes #72
This commit is contained in:
@@ -302,7 +302,7 @@ class Module(Scope):
|
|||||||
if self.path is None:
|
if self.path is None:
|
||||||
string = '' # no path -> empty name
|
string = '' # no path -> empty name
|
||||||
else:
|
else:
|
||||||
sep = (os.path.sep,) * 2
|
sep = (re.escape(os.path.sep),) * 2
|
||||||
r = re.search(r'([^%s]*?)(%s__init__)?(\.py|\.so)?$' % sep,
|
r = re.search(r'([^%s]*?)(%s__init__)?(\.py|\.so)?$' % sep,
|
||||||
self.path)
|
self.path)
|
||||||
string = r.group(1)
|
string = r.group(1)
|
||||||
|
|||||||
Reference in New Issue
Block a user