Ignore privacy

We need to exclude STL or other template io_src code being created with they use
a protected/private enumerations, just like classes.  Also remove a check for
a static bitfield, because you can't have a static bitfield.

refs #218
This commit is contained in:
Alex Lin
2016-04-15 14:10:37 -05:00
parent f2dd53f0b5
commit d6e01ee1c4
3 changed files with 10 additions and 7 deletions

View File

@ -75,11 +75,6 @@ void PrintFileContentsBase::print_close_extern_c(std::ofstream & outfile) {
bool PrintFileContentsBase::determinePrintAttr( ClassValues * c , FieldDescription * fdes ) {
if ( fdes->getTypeName().compare("void") and fdes->getIO() != 0 and fdes->getEnumString().compare("TRICK_VOID")) {
if ( fdes->isStatic() ) {
// Cannot take the address of a bitfield, attributes need the address of static variables.
// return false if we have a static bitfield
if ( fdes->isBitField() ) {
return false ;
}
if ( fdes->isInherited() ) {
return ((c->getHasInitAttrFriend() && fdes->getAccess() == clang::AS_protected)
|| (fdes->getAccess() == clang::AS_public)) ;