[PATCH] Initial pass at API design for DebugInfo/PDB
zturner at google.com
Tue Feb 3 15:11:34 PST 2015
Comment at: include/llvm/DebugInfo/PDB/IPDBRawSymbol.h:193
@@ +192,3 @@
+ virtual bool isVirtualInheritance() const = 0;
+ virtual bool isVolatileType() const = 0;
> How're these functions going to communicate failure?
Undefined in theory, probably false in practice. You shouldn't call methods on the raw interface unless you know it's a valid method.
For the purposes of a dumper who wanted to detect unknown / unexpected fields, that knowledge could all be encapsulated in the implementation of the raw interface. For example, you could have PDBSymbol::dump() which calls RawSymbol->dump(), and that particular implementation can go to the native API instead of calling the friendly accessors.
More information about the llvm-commits