Add offset of members to assetstructtests

This commit is contained in:
Jan
2021-03-04 09:04:25 +01:00
parent a10b3b7d3c
commit 29b962e949
4 changed files with 24 additions and 3 deletions

View File

@ -4,6 +4,7 @@ Variable::Variable(std::string name, std::unique_ptr<TypeDeclaration> typeDeclar
: m_name(std::move(name)),
m_has_alignment_override(false),
m_alignment_override(0),
m_offset(0),
m_type_declaration(std::move(typeDeclaration))
{
}

View File

@ -3,6 +3,7 @@
#include <memory>
#include <string>
#include "Utils/ClassUtils.h"
#include "TypeDeclaration.h"
class Variable
@ -11,10 +12,11 @@ public:
std::string m_name;
bool m_has_alignment_override;
unsigned m_alignment_override;
unsigned m_offset;
std::unique_ptr<TypeDeclaration> m_type_declaration;
Variable(std::string name, std::unique_ptr<TypeDeclaration> typeDeclaration);
unsigned GetAlignment() const;
bool GetForceAlignment() const;
_NODISCARD unsigned GetAlignment() const;
_NODISCARD bool GetForceAlignment() const;
};