summaryrefslogtreecommitdiff
path: root/src/environment.h
diff options
context:
space:
mode:
authorLoïc Blot <nerzhul@users.noreply.github.com>2017-06-10 13:49:15 +0200
committerGitHub <noreply@github.com>2017-06-10 13:49:15 +0200
commitab128e03ff555a8fc292352b0b21fc1075a4c008 (patch)
tree41c610f0168cf67abd93d63df7f80e7e9df8d4ba /src/environment.h
parent9c497aa71f4678f7a8adcfedd37b73c5391d97ec (diff)
downloadminetest-ab128e03ff555a8fc292352b0b21fc1075a4c008.tar.gz
minetest-ab128e03ff555a8fc292352b0b21fc1075a4c008.tar.bz2
minetest-ab128e03ff555a8fc292352b0b21fc1075a4c008.zip
C++11 patchset 6: forbid object copy using assigment/copy function deleters (#5945)
C++11 implement function deleting, it's generally used to prevent some object copy In script API use this function removal on ScriptApiBase instead of ScriptApiClient/Server/MainMenu, this affect all ScriptApis Move DISABLE_CLASS_COPY with constructor, the deleted function permit to replace function in its original place
Diffstat (limited to 'src/environment.h')
-rw-r--r--src/environment.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/environment.h b/src/environment.h
index 4c00ef9e8..55fc4707c 100644
--- a/src/environment.h
+++ b/src/environment.h
@@ -49,6 +49,7 @@ public:
// Environment will delete the map passed to the constructor
Environment(IGameDef *gamedef);
virtual ~Environment();
+ DISABLE_CLASS_COPY(Environment);
/*
Step everything in environment.
@@ -121,8 +122,6 @@ protected:
private:
std::mutex m_time_lock;
-
- DISABLE_CLASS_COPY(Environment);
};
#endif