From 4e9af85b897c9f1f16ce7db4f2b3d3a6370929a5 Mon Sep 17 00:00:00 2001 From: DarkSharpness <2040703891@qq.com> Date: Tue, 23 Jul 2024 16:05:05 +0800 Subject: [PATCH] fix(register): force to sync since the _M_assigned may not be available --- include/register.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/include/register.h b/include/register.h index 760fa3a..0b79264 100644 --- a/include/register.h +++ b/include/register.h @@ -19,10 +19,8 @@ struct Register { debug::DebugValue _M_assigned; void sync() { - if (this->_M_assigned) { - this->_M_assigned = false; - this->_M_old = this->_M_new; - } + this->_M_assigned = false; + this->_M_old = this->_M_new; } public: