mercredi 28 juillet 2021

Get the size of the biggest derived class from a language server

I've got the problem that I need to know the size of the biggest derived class of a base class. At the moment I'm using the -D option of the compiler to specify the size, this is the easiest option I could think of, but you always have to update the size manually.

Since this would be nearly impossible to do in c++ itself, I thought maybe could get the information from a language server and then generate a header that contains the information.

Note that I have no experience in this, but the language server should have all the information that I need right?

How difficult would it be to implement this in python? (doesn't have to be python but I would prefer it)

For the language server I could provide a CMakeLists.txt.

Aucun commentaire:

Enregistrer un commentaire