//
// std::runtime_error::~runtime_error from 0x981e98 to 0x981ed8 (64 bytes)
//
// 7 xrefs:
// > fmt::SystemError::init @ 0x81f212
// > std::__ndk1::system_error::~system_error @ 0x97e838
// > std::__ndk1::system_error::~system_error @ 0x97e840
// > std::runtime_error::~runtime_error @ 0x981ee0
// > std::range_error::~range_error @ 0x981f34
// > std::overflow_error::~overflow_error @ 0x981f44
// > std::underflow_error::~underflow_error @ 0x981f54
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 12:06:08 +0000
//
// Alternative name is '_ZNSt14overflow_errorD1Ev'
// Alternative name is '_ZNSt13runtime_errorD2Ev'
// Alternative name is '_ZNSt11range_errorD2Ev'
// Alternative name is '_ZNSt11range_errorD1Ev'
// Alternative name is '_ZNSt14overflow_errorD2Ev'
// Alternative name is '_ZNSt15underflow_errorD2Ev'
// Alternative name is '_ZNSt15underflow_errorD1Ev'
void __fastcall std::runtime_error::~runtime_error(std::runtime_error *this)
{
int v2; // r0
unsigned int *v3; // r1
unsigned int v4; // r2
signed int v5; // r2
*(_DWORD *)this = &off_D1540C;
v2 = *((_DWORD *)this + 1);
__dmb(0xBu);
v3 = (unsigned int *)(v2 - 4);
do
{
v4 = __ldrex(v3);
v5 = v4 - 1;
}
while ( __strex(v5, v3) );
__dmb(0xBu);
if ( v5 <= -1 )
operator delete((void *)(v2 - 12));
std::exception::~exception(this);
}