From d7cb0b3acc0621aa69061d0d1199ac33c664e58f Mon Sep 17 00:00:00 2001 From: Peter LaFosse Date: Thu, 25 May 2017 19:51:45 -0400 Subject: Modify how structures are created in the type system, expose additional structure APIs --- type.cpp | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'type.cpp') diff --git a/type.cpp b/type.cpp index 5dd00cbd..6e55bb69 100644 --- a/type.cpp +++ b/type.cpp @@ -784,9 +784,9 @@ Structure::Structure() } -Structure::Structure(BNStructureType type, bool isUnion, bool packed) +Structure::Structure(BNStructureType type, bool packed) { - m_object = BNCreateStructureWithOptions(type, isUnion, packed); + m_object = BNCreateStructureWithOptions(type, packed); } @@ -858,9 +858,15 @@ bool Structure::IsUnion() const } -void Structure::SetUnion(bool u) +void Structure::SetStructureType(BNStructureType t) { - BNSetStructureUnion(m_object, u); + BNSetStructureType(m_object, t); +} + + +BNStructureType Structure::GetStructureType() const +{ + return BNGetStructureType(m_object); } -- cgit v1.3.1