Skip to content

Commit

Permalink
v1.2.0 xmlシリアライズ対応 Issue #41
Browse files Browse the repository at this point in the history
  [skip ci]

MinGWにおけるSharedLibrary不具合に対処
  msvcとは異なる対処が必要だったのを忘れていた。
  https://qiita.com/Chironian/items/3fb61cffa2a20dbee5c2#%EF%BC%92%EF%BC%94%E3%81%95%E3%81%A6%E5%95%8F%E9%A1%8C%E3%81%A7%E3%81%99

------ auto generated message by Theolizer
TheolizerDriver  : c73353f6e351f02bef571977b3556724
TheolizerLibrary : e81c54dafab40aefd1581b30b1b3d545
Library's Header : 32dc5749d9e1f2110199f1267f787ef0
------ end of message
  • Loading branch information
yossi-tahara committed Sep 29, 2017
1 parent e9cd8c0 commit fff0cf2
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 16 deletions.
6 changes: 3 additions & 3 deletions build_tools/linux.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -139,10 +139,10 @@ set(ENV{LC_ALL} "C")
output_title("****** StaticWithBoost ******")
build_by_gcc(gcc540 64 StaticWithBoost TRUE TRUE "39 1" "11 1")

output_title("****** Static ******")
build_by_gcc(gcc540 64 Static FALSE FALSE "38 1" "11 1")

output_title("****** Shared ******")
build_by_gcc(gcc540 64 Shared FALSE FALSE "38 1" "11 1")

output_title("****** Static ******")
build_by_gcc(gcc540 64 Static FALSE FALSE "38 1" "11 1")

output_summary()
12 changes: 6 additions & 6 deletions build_tools/windows.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -142,16 +142,16 @@ build_by_msvc(msvc2017 32 StaticWithBoost TRUE TRUE "39 11 1 1")
build_by_gcc( mingw710 64 StaticWithBoost TRUE TRUE "39 1" "11 1")
build_by_gcc( mingw710 32 StaticWithBoost TRUE TRUE "39 1" "11 1")

output_title("****** Static ******")
build_by_msvc(msvc2017 64 Static FALSE FALSE "38 11 1 1")
build_by_msvc(msvc2017 32 Static FALSE FALSE "38 11 1 1")
build_by_gcc( mingw710 64 Static FALSE FALSE "38 1" "11 1")
build_by_gcc( mingw710 32 Static FALSE FALSE "38 1" "11 1")

output_title("****** Shared ******")
build_by_msvc(msvc2017 64 Shared FALSE FALSE "38 11 1 1")
build_by_msvc(msvc2017 32 Shared FALSE FALSE "38 11 1 1")
build_by_gcc( mingw710 64 Shared FALSE FALSE "38 1" "11 1")
build_by_gcc( mingw710 32 Shared FALSE FALSE "38 1" "11 1")

output_title("****** Static ******")
build_by_msvc(msvc2017 64 Static FALSE FALSE "38 11 1 1")
build_by_msvc(msvc2017 32 Static FALSE FALSE "38 11 1 1")
build_by_gcc( mingw710 64 Static FALSE FALSE "38 1" "11 1")
build_by_gcc( mingw710 32 Static FALSE FALSE "38 1" "11 1")

output_summary()
17 changes: 17 additions & 0 deletions source/library/theolizer/internal/core_type_info.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,5 +121,22 @@ return aTypeInfoListImpl[iTypeIndex]->getLastVersionNoV();
return std::vector<unsigned>::at(iTypeIndex);
}

// ***************************************************************************
// プリミティブ管理クラス(シングルトン)
// プリミティブ型を型リストへ登録する
// ***************************************************************************

template<typename tPrimitiveType>
PrimitiveTypeInfo<tPrimitiveType>& PrimitiveTypeInfo<tPrimitiveType>::getInstance()
{
static PrimitiveTypeInfo<tPrimitiveType> instance;
return instance;
}

// 明示的実体化
#define THEOLIZER_INTERNAL_DEF_PRIMITIVE(dType, dSymbol) \
template class PrimitiveTypeInfo<dType>;
#include "primitive.inc"

} // namespace internal
} // namespace theolizer
6 changes: 1 addition & 5 deletions source/library/theolizer/internal/core_type_info.h
Original file line number Diff line number Diff line change
Expand Up @@ -1022,11 +1022,7 @@ class THEOLIZER_INTERNAL_DLL PrimitiveTypeInfo : public BaseTypeInfo
// コンストラクタ/デストラクタ
PrimitiveTypeInfo() : BaseTypeInfo(etcPrimitiveType) { }
public:
static PrimitiveTypeInfo& getInstance()
{
static PrimitiveTypeInfo instance;
return instance;
}
static PrimitiveTypeInfo& getInstance();

// コピー/ムーブ禁止(仮想関数があるのでis_trivially_copyableにならない)
PrimitiveTypeInfo(const PrimitiveTypeInfo&) = delete;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -306,9 +306,7 @@ std::cout << "TestISerializerNormal(" << iFileName << ", "
THEOLIZER_EQUAL(aString, "Test");

NonIntrusiveDrived aNonIntrusiveDrived;
std::cout << "pre NonIntrusiveDrived ------\n";
THEOLIZER_PROCESS(aSerializer, aNonIntrusiveDrived);
std::cout << "post NonIntrusiveDrived ------\n";
THEOLIZER_EQUAL(aNonIntrusiveDrived.mLong, -100);
THEOLIZER_EQUAL(aNonIntrusiveDrived.mInt, -101);

Expand Down

0 comments on commit fff0cf2

Please sign in to comment.