commit 2025-08-24 11:07 edit a bit ZCppMain/ZMainHead.H etc

This commit is contained in:
2025-08-24 11:07:13 +09:00
parent 949c731b87
commit a8b73f68de
5 changed files with 72 additions and 14 deletions

View File

@ -3112,7 +3112,18 @@ namespace ZNsMain
HANDLE mh_Mutex; HANDLE mh_Mutex;
public : public :
void Lock() throw(ZCExceptSmallLock&) /*/////////////////////////////////////////////////////////
Administrator@q381-2673 UCRT64 /e/my_CPP/ZCpp/ZCppMainTest
# g++.exe -o ZtCArray_000_mw.exe ZtCArray_000.cpp -I../
In file included from ../ZCppMain/ZtCArray.H:7,
from ZtCArray_000.cpp:4:
../ZCppMain/ZMainHead.H:3115:21: error: ISO C++17 does not allow dynamic exception specifications
3115 | void Lock() throw(ZCExceptSmallLock&)
/////////////////////////////////////////////////////////*/
void Lock() /*throw(ZCExceptSmallLock&)*/
{ {
long VL_ErrCode=0; long VL_ErrCode=0;
@ -3122,7 +3133,7 @@ namespace ZNsMain
}/* }/*
if((VL_ErrCode = ::WaitForSingleObject(mh_Mutex, INFINITE))==WAIT_ABANDONED)*/ if((VL_ErrCode = ::WaitForSingleObject(mh_Mutex, INFINITE))==WAIT_ABANDONED)*/
}/* }/*
void Lock() throw(ZCExceptSmallLock&)*/ void Lock() /*throw(ZCExceptSmallLock&)*/
void UnLock() void UnLock()
{ {

View File

@ -680,19 +680,19 @@ namespace ZNsMain
#if defined(_WIN) && defined(_REENTRANT) #if defined(_WIN) && defined(_REENTRANT)
static CMutexSmallInit& GetCMutexSmallInit() static ZCMutexSmallInit& GetCMutexSmallInit()
{ {
static CMutexSmallInit SO_CMutexSmallInit; return SO_CMutexSmallInit; static ZCMutexSmallInit SO_CMutexSmallInit; return SO_CMutexSmallInit;
}/* }/*
static CMutexSmallInit& GetCMutexSmallInit()*/ static ZCMutexSmallInit& GetCMutexSmallInit()*/
#endif //defined(_WIN) && defined(_REENTRANT) #endif //defined(_WIN) && defined(_REENTRANT)
static bool SetLocalTimeObj(time_t AL_TimeSec,struct tm& ARR_StTime) static bool SetLocalTimeObj(time_t AL_TimeSec, struct tm& ARR_StTime)
{ {
#ifdef _REENTRANT #ifdef _REENTRANT
#ifdef _WIN #ifdef _WIN
ZNsMain::CMutexSmallLock VO_CMutexSmallLock(GetCMutexSmallInit()); ZNsMain::ZCMutexSmallLock VO_CMutexSmallLock(GetCMutexSmallInit());
struct tm* VP_StTime = ::localtime(&AL_TimeSec); struct tm* VP_StTime = ::localtime(&AL_TimeSec);
@ -722,7 +722,7 @@ namespace ZNsMain
{ {
#if defined(_REENTRANT) #if defined(_REENTRANT)
#ifdef _WIN #ifdef _WIN
ZNsMain::CMutexSmallLock ZNsMain::ZCMutexSmallLock
VO_CMutexSmallLock( GetCMutexSmallInit() ); VO_CMutexSmallLock( GetCMutexSmallInit() );
struct tm* VP_StTime = ::gmtime(&AL_TimeSec); struct tm* VP_StTime = ::gmtime(&AL_TimeSec);

View File

@ -195,8 +195,24 @@ int main(int AR_ArgCnt, char* APP_ArgVal[])*/
■ mingw 컴파일 ■ mingw 컴파일
// /usr/local/mingw/bin/g++.exe -o ZtCArray_000.exe ZtCArray_000.cpp -I../../my_CPP/CPP_Main/ -I../../my_CPP/CPP_Std/ -D__CYGWIN32__ -D__VISUAL_CPP_VER__=200300 g++.exe -o ZtCArray_000_mw.exe ZtCArray_000.cpp -I../
// /usr/local/mingw/bin/g++.exe -o ZtCArray_000_D.exe ZtCArray_000.cpp -I../../my_CPP/CPP_Main/ -I../../my_CPP/CPP_Std/ -D__CYGWIN32__ -D__VISUAL_CPP_VER__=200300 -D_DEBUG g++.exe -o ZtCArray_000_mw_D.exe ZtCArray_000.cpp -I../ -D_DEBUG
./ZtCArray_000_mw.exe
./ZtCArray_000_mw_D.exe
Administrator@q381-2673 UCRT64 /e/my_CPP/ZCpp/ZCppMainTest
# date
Sun Aug 24 10:47:09 KST 2025
Administrator@q381-2673 UCRT64 /e/my_CPP/ZCpp/ZCppMainTest
# g++ --version
g++.exe (Rev2, Built by MSYS2 project) 13.2.0
Copyright (C) 2023 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
■ Linux 컴파일 ■ Linux 컴파일

View File

@ -166,8 +166,23 @@ int main(int AR_ArgCnt, char* APP_ArgVal[])*/
■ mingw 컴파일 ■ mingw 컴파일
// /usr/local/mingw/bin/g++.exe -o ZtCLoadXml_000.exe ZtCLoadXml_000.cpp -I../../my_CPP/CPP_Main/ -I../../my_CPP/CPP_Std/ -D__CYGWIN32__ -D__VISUAL_CPP_VER__=200300 g++.exe -o ZtCLoadXml_000_mw.exe ZtCLoadXml_000.cpp -I../ -lWs2_32
// /usr/local/mingw/bin/g++.exe -o ZtCLoadXml_000_D.exe ZtCLoadXml_000.cpp -I../../my_CPP/CPP_Main/ -I../../my_CPP/CPP_Std/ -D__CYGWIN32__ -D__VISUAL_CPP_VER__=200300 -D_DEBUG g++.exe -o ZtCLoadXml_000_mw_D.exe ZtCLoadXml_000.cpp -I../ -lWs2_32 -D_DEBUG
./ZtCLoadXml_000_mw.exe
./ZtCLoadXml_000_mw_D.exe
Administrator@q381-2673 UCRT64 /e/my_CPP/ZCpp/ZCppMainTest
# date
Sun Aug 24 10:47:09 KST 2025
Administrator@q381-2673 UCRT64 /e/my_CPP/ZCpp/ZCppMainTest
# g++ --version
g++.exe (Rev2, Built by MSYS2 project) 13.2.0
Copyright (C) 2023 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
■ Linux 컴파일 ■ Linux 컴파일

View File

@ -72,8 +72,24 @@ int main(int AR_ArgCnt, char* APP_ArgVal[])*/
■ mingw 컴파일 ■ mingw 컴파일
// /usr/local/mingw/bin/g++.exe -o ZtCObjAVL_000.exe ZtCObjAVL_000.cpp -I../../my_CPP/CPP_Main/ -I../../my_CPP/CPP_Std/ -D__CYGWIN32__ -D__VISUAL_CPP_VER__=200300 g++.exe -o ZtCObjAVL_000_mw.exe ZtCObjAVL_000.cpp -I../
// /usr/local/mingw/bin/g++.exe -o ZtCObjAVL_000_D.exe ZtCObjAVL_000.cpp -I../../my_CPP/CPP_Main/ -I../../my_CPP/CPP_Std/ -D__CYGWIN32__ -D__VISUAL_CPP_VER__=200300 -D_DEBUG g++.exe -o ZtCObjAVL_000_mw_D.exe ZtCObjAVL_000.cpp -I../ -D_DEBUG
./ZtCObjAVL_000_mw.exe
./ZtCObjAVL_000_mw_D.exe
Administrator@q381-2673 UCRT64 /e/my_CPP/ZCpp/ZCppMainTest
# date
Sun Aug 24 10:47:09 KST 2025
Administrator@q381-2673 UCRT64 /e/my_CPP/ZCpp/ZCppMainTest
# g++ --version
g++.exe (Rev2, Built by MSYS2 project) 13.2.0
Copyright (C) 2023 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
■ Linux 컴파일 ■ Linux 컴파일