Dear Eli,

Can you please take a look at: https://bitbucket.org/tkadm30/libuwsgictl/raw/048978bf2b51b1185302da98c5063978061293df/tests/cwrap/error

I'm playing around with cwrap: https://github.com/geggo/cwrap

Looks like this *gem* can generate Cython pxd files from C headers using libclang. :)

Traceback (most recent call last):
  File "/usr/local/bin/cwrap", line 46, in <module>
    ast_items = clang_parser.parse([('input.h', inputfile)], include_dirs, '')
  File 
"/usr/local/lib/python2.7/dist-packages/cwrap/frontends/clang/clang_parser.py", 
line 889, in parse
    parser.parse(cfile[0][0], include_dirs, language, unsaved_files=cfile)
  File 
"/usr/local/lib/python2.7/dist-packages/cwrap/frontends/clang/clang_parser.py", 
line 123, in parse
    self.parse_element(tu.cursor)
  File 
"/usr/local/lib/python2.7/dist-packages/cwrap/frontends/clang/clang_parser.py", 
line 306, in parse_element
    child = self.parse_element(c, level+1)
  File 
"/usr/local/lib/python2.7/dist-packages/cwrap/frontends/clang/clang_parser.py", 
line 259, in parse_element
    result = mth(cursor, level)
  File 
"/usr/local/lib/python2.7/dist-packages/cwrap/frontends/clang/clang_parser.py", 
line 496, in visit_VAR_DECL
    typ, id_ = self.type_to_c_ast_type(cursor.type, level)
  File 
"/usr/local/lib/python2.7/dist-packages/cwrap/frontends/clang/clang_parser.py", 
line 167, in type_to_c_ast_type
    level.show( 'in type to c_ast:', 'kind:', t.kind, 
repr(t.get_declaration().spelling))
  File 
"/usr/local/lib/python2.7/dist-packages/cwrap/frontends/clang/clang/cindex.py", 
line 1467, in kind
    return TypeKind.from_id(self._kind_id)
  File 
"/usr/local/lib/python2.7/dist-packages/cwrap/frontends/clang/clang/cindex.py", 
line 1407, in from_id
    raise ValueError,'Unknown type kind %d' % id
ValueError: Unknown type kind 114


What do you think about this error?

I ran: $ cwrap -i . -i /usr/lib/llvm-3.8/lib/clang/3.8.1/include uwsgi.h libuwsgi.pxd

Cheers,

Etienne

--
Etienne Robillard
tkad...@yandex.com
https://www.isotopesoftware.ca/

--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to