Skip to content

Commit 5736fd6

Browse files
committed
Fix issue
1 parent 1f30b32 commit 5736fd6

2 files changed

Lines changed: 20 additions & 0 deletions

File tree

‎Distribution/LuaBridge/LuaBridge.h‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3368,6 +3368,16 @@ struct TypeResult
33683368
return std::move(m_value.value());
33693369
}
33703370

3371+
T* operator->()
3372+
{
3373+
return &m_value.value();
3374+
}
3375+
3376+
const T* operator->() const
3377+
{
3378+
return &m_value.value();
3379+
}
3380+
33713381
template <class U>
33723382
T valueOr(U&& defaultValue) const&
33733383
{

‎Source/LuaBridge/detail/Result.h‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,16 @@ struct TypeResult
120120
return std::move(m_value.value());
121121
}
122122

123+
T* operator->()
124+
{
125+
return &m_value.value();
126+
}
127+
128+
const T* operator->() const
129+
{
130+
return &m_value.value();
131+
}
132+
123133
template <class U>
124134
T valueOr(U&& defaultValue) const&
125135
{

0 commit comments

Comments
 (0)