summaryrefslogtreecommitdiffstats
path: root/modules/mono/mono_gd/gd_mono_utils.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2020-02-28 00:26:01 +0100
committerGitHub <noreply@github.com>2020-02-28 00:26:01 +0100
commitb7b39786840a41a057f531ed13b64e26366befac (patch)
treeb78a2e0bc0b3f49e82e148e8edb741930ff0ce55 /modules/mono/mono_gd/gd_mono_utils.cpp
parente66d519286693a03bf59eaba0a5f29c1c9b15d64 (diff)
parent18fbdbb456c07a56b358bea2e392765fbcbb3283 (diff)
downloadredot-engine-b7b39786840a41a057f531ed13b64e26366befac.tar.gz
Merge pull request #36556 from RandomShaper/rework_mutex
Reimplement `Mutex` with C++'s `<mutex>` (plus more)
Diffstat (limited to 'modules/mono/mono_gd/gd_mono_utils.cpp')
-rw-r--r--modules/mono/mono_gd/gd_mono_utils.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/mono/mono_gd/gd_mono_utils.cpp b/modules/mono/mono_gd/gd_mono_utils.cpp
index ae6625a6c6..41f49d8ac9 100644
--- a/modules/mono/mono_gd/gd_mono_utils.cpp
+++ b/modules/mono/mono_gd/gd_mono_utils.cpp
@@ -33,6 +33,7 @@
#include <mono/metadata/exception.h>
#include "core/os/dir_access.h"
+#include "core/os/mutex.h"
#include "core/os/os.h"
#include "core/project_settings.h"
#include "core/reference.h"
@@ -43,7 +44,6 @@
#include "../csharp_script.h"
#include "../utils/macros.h"
-#include "../utils/mutex_utils.h"
#include "gd_mono.h"
#include "gd_mono_cache.h"
#include "gd_mono_class.h"
@@ -74,7 +74,7 @@ MonoObject *unmanaged_get_managed(Object *unmanaged) {
CSharpScriptBinding &script_binding = ((Map<Object *, CSharpScriptBinding>::Element *)data)->value();
if (!script_binding.inited) {
- SCOPED_MUTEX_LOCK(CSharpLanguage::get_singleton()->get_language_bind_mutex());
+ MutexLock lock(CSharpLanguage::get_singleton()->get_language_bind_mutex());
if (!script_binding.inited) { // Other thread may have set it up
// Already had a binding that needs to be setup