From 419fe72bcb3b1ee3517d87f772d0160f6955a31c Mon Sep 17 00:00:00 2001 From: Xottab-DUTY Date: Tue, 23 Jul 2024 00:08:18 +0500 Subject: [PATCH] Fix build Addition to 43ad080655b194fff0f0ee07328d9914e2e4ddb5 --- src/xrCore/xr_ini.h | 2 +- src/xrServerEntities/script_ini_file_script.cpp | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/xrCore/xr_ini.h b/src/xrCore/xr_ini.h index b97c8c8642e..cbfcbdaa2e2 100644 --- a/src/xrCore/xr_ini.h +++ b/src/xrCore/xr_ini.h @@ -84,7 +84,7 @@ class XRCORE_API CInifile void save_at_end(bool b) noexcept { m_flags.set(eSaveAtEnd, b); } void set_readonly(bool b) noexcept { m_flags.set(eReadOnly, b); } void set_override_names(bool b) noexcept { m_flags.set(eOverrideNames, b); } - pcstr fname() const /*noexcept*/ { return m_file_name; }; + pcstr fname() const noexcept { return m_file_name; } Sect& r_section(pcstr S) const; Sect& r_section(const shared_str& S) const; bool line_exist(pcstr S, pcstr L)const; diff --git a/src/xrServerEntities/script_ini_file_script.cpp b/src/xrServerEntities/script_ini_file_script.cpp index 1aa2a17e777..0f2e9bbabf1 100644 --- a/src/xrServerEntities/script_ini_file_script.cpp +++ b/src/xrServerEntities/script_ini_file_script.cpp @@ -99,9 +99,9 @@ static void CScriptIniFile_Export(lua_State* luaState) .def("w_u64", &CScriptIniFile::w_u64) .def("w_u8", &CScriptIniFile::w_u8) .def("save_as", &CScriptIniFile::save_as) - .def("save_at_end", &CInifile::save_at_end) + .def("save_at_end", +[](CScriptIniFile* self, bool value) { self->save_at_end(value); }) .def("remove_line", &CScriptIniFile::remove_line) - .def("set_override_names", &CInifile::set_override_names) + .def("set_override_names", +[](CScriptIniFile* self, bool value) { self->set_override_names(value); }) .def("section_count", &CScriptIniFile::section_count) .def("section_for_each", +[](CScriptIniFile* self, const luabind::functor& functor) { @@ -113,9 +113,9 @@ static void CScriptIniFile_Export(lua_State* luaState) functor(section->Name.c_str()); } }) - .def("set_readonly", &CInifile::set_readonly) + .def("set_readonly", +[](CScriptIniFile* self, bool value) { self->set_readonly(value); }) //Alundaio: END - .def("fname", &CScriptIniFile::fname) + .def("fname", +[](const CScriptIniFile* self) { return self->fname(); }) .def("section_exist", (bool (CScriptIniFile::*)(pcstr) const)&CScriptIniFile::section_exist) .def("line_exist", (bool (CScriptIniFile::*)(pcstr, pcstr) const)&CScriptIniFile::line_exist) .def("r_clsid", &CScriptIniFile::r_clsid)