Ignore privacy

Changed the storage of offsets from bytes to bits to better handle bitfields.
Added code to track classes that are defined within other classes and are
private/protected.  These classes cannot be used in templates because our
io_src code declares variables outside of the class that would try and use
these private/protected variables.  When a template is found to use a
private/protected class it is skipped.

refs #218
This commit is contained in:
Alex Lin
2016-04-12 15:53:39 -05:00
parent 314e962edf
commit f63f44d876
10 changed files with 158 additions and 91 deletions

View File

@ -247,9 +247,6 @@ void FieldDescription::setContainerClass(std::string in_name ) {
void FieldDescription::setFieldOffset(unsigned int in_offset) {
field_offset = in_offset ;
if ( is_bitfield ) {
calcBitfieldOffset() ;
}
}
unsigned int FieldDescription::getFieldOffset() {
@ -331,17 +328,8 @@ clang::AccessSpecifier FieldDescription::getAccess() {
return access ;
}
void FieldDescription::calcBitfieldOffset() {
unsigned int field_offset_bits = field_offset * 8 ;
bitfield_start_bit = 32 - (field_offset_bits % 32) - bitfield_width ;
bitfield_word_offset = (field_offset_bits / 32) * 4 ;
}
void FieldDescription::addOffset( unsigned int offset ) {
field_offset += offset ;
if ( is_bitfield ) {
calcBitfieldOffset() ;
}
}
void FieldDescription::setEnumString(std::string in_str) {