find_classdecl firstly search for the class match the name we input, then strips all methods and fields except public method and public field, then strips the implementation details of the method, prints only stub implementation of public methods, also prints the declaration of public fields.
At least in MFC headers, public fields are not always documented, and many could be considered implementation details. It's not obvious where that line should be drawn. And sometimes the headers contain inline function implementations, which are effectively part of the ABI.
For projects where "public" means things that are intended to be part of the API, maybe this could work, but I'm not aware of any that we need to replace.
Is this about any library in particular?