Way to make embedded C modules visible?

I would love to have the IDE not constantly angry at me. I have a C application that embeds Python and creates modules in code and makes the modules accessible to the interpreter internally. Is there anyway to make these available for the IDE (CLion or PyCharm)? The only way I can think of (due to lack of imagination) is simply creating Python modules that are just empty documented stubs which sounds painful.

2 comments
Comment actions Permalink

Hi, 

Creating stubs is widely used and accepted way to allow code inspection and type checker of the IDE to understand the module's functions/methods and types, when the functionality of the module is implemented in C/C++.

As far as I know, stubgen tool can be used to generate stubs for C extensions automatically.

0
Comment actions Permalink

Thanks, unfortunately it isn't an extension but an application so the stubgen tool probably won't work. I will save the link for later if I do need it for extensions. It looks like I will need to create them all manually. :) 

0

Please sign in to leave a comment.