jessevdk / cldoc

clang based documentation generator for C and C++
GNU General Public License v2.0
552 stars 58 forks source link

ValueError: Unknown cursor kind 601 on macOS #121

Closed xgdgsc closed 7 years ago

xgdgsc commented 7 years ago

I get following error with cldoc on macOS sierra:

Traceback (most recent call last):
  File "/usr/local/bin/cldoc", line 9, in <module>
    load_entry_point('cldoc==1.9', 'console_scripts', 'cldoc')()
  File "/usr/local/lib/python2.7/site-packages/cldoc/__init__.py", line 57, in run
    run_generate(rest)
  File "/usr/local/lib/python2.7/site-packages/cldoc/__init__.py", line 27, in run_generate
    cmdgenerate.run(args)
  File "/usr/local/lib/python2.7/site-packages/cldoc/cmdgenerate.py", line 125, in run
    t.process()
  File "/usr/local/lib/python2.7/site-packages/cldoc/tree.py", line 212, in process
    self.visit(tu.cursor.get_children())
  File "/usr/local/lib/python2.7/site-packages/cldoc/tree.py", line 517, in visit
    self.visit(item.get_children(), node)
  File "/usr/local/lib/python2.7/site-packages/cldoc/tree.py", line 483, in visit
    if item.kind == cindex.CursorKind.UNEXPOSED_DECL:
  File "/usr/local/lib/python2.7/site-packages/cldoc/clang/cindex.py", line 1189, in kind
    return CursorKind.from_id(self._kind_id)
  File "/usr/local/lib/python2.7/site-packages/cldoc/clang/cindex.py", line 553, in from_id
    raise ValueError,'Unknown cursor kind %d' % id
ValueError: Unknown cursor kind 601

Any clue on how I could fix this? The python is python2 installed from brew.

refi64 commented 7 years ago

What files are you generating docs for?

xgdgsc commented 7 years ago

My hpp and cpp files.

xgdgsc commented 7 years ago

Same error with the same files on manjaro linux:

Processing common_headers.hpp
Traceback (most recent call last):
  File "/home/gsc/anaconda2/bin/cldoc", line 11, in <module>
    sys.exit(run())
  File "/home/gsc/anaconda2/lib/python2.7/site-packages/cldoc/__init__.py", line 57, in run
    run_generate(rest)
  File "/home/gsc/anaconda2/lib/python2.7/site-packages/cldoc/__init__.py", line 27, in run_generate
    cmdgenerate.run(args)
  File "/home/gsc/anaconda2/lib/python2.7/site-packages/cldoc/cmdgenerate.py", line 125, in run
    t.process()
  File "/home/gsc/anaconda2/lib/python2.7/site-packages/cldoc/tree.py", line 212, in process
    self.visit(tu.cursor.get_children())
  File "/home/gsc/anaconda2/lib/python2.7/site-packages/cldoc/tree.py", line 517, in visit
    self.visit(item.get_children(), node)
  File "/home/gsc/anaconda2/lib/python2.7/site-packages/cldoc/tree.py", line 483, in visit
    if item.kind == cindex.CursorKind.UNEXPOSED_DECL:
  File "/home/gsc/anaconda2/lib/python2.7/site-packages/cldoc/clang/cindex.py", line 1189, in kind
    return CursorKind.from_id(self._kind_id)
  File "/home/gsc/anaconda2/lib/python2.7/site-packages/cldoc/clang/cindex.py", line 553, in from_id
    raise ValueError,'Unknown cursor kind %d' % id
ValueError: Unknown cursor kind 601

It happens after processing a very simple common header file that includes common headers and declares classes in namespaces, a very similar one to trading_robot_2/headers.h at master · bytefury/trading_robot_2.