mirror of
https://github.com/pybind/pybind11.git
synced 2026-04-19 22:39:09 +00:00
Avoid decoding already-decoded strings from cindex.
Recent versions of clang.cindex include [code][1] that converts the internal byte strings to python str for you. [1]: https://github.com/llvm-mirror/clang/blob/master/bindings/python/clang/cindex.py#L72
This commit is contained in:
@@ -59,7 +59,7 @@ job_semaphore = Semaphore(job_count)
|
||||
output = []
|
||||
|
||||
def d(s):
|
||||
return s.decode('utf8')
|
||||
return s if isinstance(s, str) else s.decode('utf8')
|
||||
|
||||
|
||||
def sanitize_name(name):
|
||||
|
||||
Reference in New Issue
Block a user