Merge pull request #8 from Timerix22/pull_network_without_network
Pull network without network
This commit is contained in:
commit
11c5b57856
@ -32,16 +32,13 @@
|
||||
<ClCompile Include="src\HashFunctions\hash.c" />
|
||||
<ClCompile Include="src\Hashtable\Hashtable.c" />
|
||||
<ClCompile Include="src\Hashtable\KeyValuePair.c" />
|
||||
<ClCompile Include="src\Network\knSocket.c" />
|
||||
<ClCompile Include="src\SearchTree\SearchTree.c" />
|
||||
<ClCompile Include="src\String\string.c" />
|
||||
<ClCompile Include="src\String\StringBuilder.c" />
|
||||
<ClCompile Include="tests\main.cpp" />
|
||||
<ClCompile Include="tests\test_autoarr.c" />
|
||||
<ClCompile Include="tests\test_autoarr2.cpp" />
|
||||
<ClCompile Include="tests\test_dtsod.c" />
|
||||
<ClCompile Include="tests\test_hashtable.c" />
|
||||
<ClCompile Include="tests\test_hashtable2.cpp" />
|
||||
<ClCompile Include="tests\test_hash_functions.c" />
|
||||
<ClCompile Include="tests\test_marshalling.c" />
|
||||
<ClCompile Include="tests\test_safethrow.c" />
|
||||
@ -49,7 +46,6 @@
|
||||
<ClCompile Include="tests\test_string.c" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="src\Autoarr2\Autoarr2.hpp" />
|
||||
<ClInclude Include="src\Autoarr\Autoarr.h" />
|
||||
<ClInclude Include="src\Autoarr\Autoarr_declare.h" />
|
||||
<ClInclude Include="src\Autoarr\Autoarr_define.h" />
|
||||
@ -61,10 +57,8 @@
|
||||
<ClInclude Include="src\base\types.h" />
|
||||
<ClInclude Include="src\DtsodParser\DtsodV24.h" />
|
||||
<ClInclude Include="src\HashFunctions\hash.h" />
|
||||
<ClInclude Include="src\Hashtable2\Hashtable2.hpp" />
|
||||
<ClInclude Include="src\Hashtable\Hashtable.h" />
|
||||
<ClInclude Include="src\Hashtable\KeyValuePair.h" />
|
||||
<ClInclude Include="src\Network\network.h" />
|
||||
<ClInclude Include="src\SearchTree\SearchTree.h" />
|
||||
<ClInclude Include="src\String\string.h" />
|
||||
<ClInclude Include="src\String\StringBuilder.h" />
|
||||
@ -75,7 +69,7 @@
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<ProjectGuid>{52f0bd29-a3cb-47ce-b25d-ceaf5dfb2d73}</ProjectGuid>
|
||||
<RootNamespace>kerep</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0.18362.0</WindowsTargetPlatformVersion>
|
||||
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
@ -162,9 +156,9 @@
|
||||
<LanguageStandard_C>stdc17</LanguageStandard_C>
|
||||
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
|
||||
<PrecompiledHeaderOutputFile />
|
||||
<AdditionalOptions>/Zc:twoPhase- /MP %(AdditionalOptions)</AdditionalOptions>
|
||||
<AdditionalOptions>/Zc:twoPhase- /MP -fms-compatibility-version=14 %(AdditionalOptions)</AdditionalOptions>
|
||||
<CompileAs>Default</CompileAs>
|
||||
<LanguageStandard>stdcpp20</LanguageStandard>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
<DebugInformationFormat>None</DebugInformationFormat>
|
||||
<Optimization>Disabled</Optimization>
|
||||
</ClCompile>
|
||||
@ -188,10 +182,10 @@
|
||||
<LanguageStandard_C>stdc17</LanguageStandard_C>
|
||||
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
|
||||
<PrecompiledHeaderOutputFile />
|
||||
<AdditionalOptions>/Zc:twoPhase- /MP %(AdditionalOptions)</AdditionalOptions>
|
||||
<AdditionalOptions>/Zc:twoPhase- /MP -fms-compatibility-version=14 %(AdditionalOptions)</AdditionalOptions>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<CompileAs>Default</CompileAs>
|
||||
<LanguageStandard>stdcpp20</LanguageStandard>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
<DebugInformationFormat>None</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
@ -214,10 +208,12 @@
|
||||
<LanguageStandard_C>stdc17</LanguageStandard_C>
|
||||
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
|
||||
<PrecompiledHeaderOutputFile />
|
||||
<AdditionalOptions>/Zc:twoPhase- /MP %(AdditionalOptions)</AdditionalOptions>
|
||||
<AdditionalOptions>/Zc:twoPhase- /MP -fms-compatibility-version=14 %(AdditionalOptions)</AdditionalOptions>
|
||||
<CompileAs>Default</CompileAs>
|
||||
<LanguageStandard>stdcpp20</LanguageStandard>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
<DebugInformationFormat>None</DebugInformationFormat>
|
||||
<TreatAngleIncludeAsExternal>true</TreatAngleIncludeAsExternal>
|
||||
<DisableAnalyzeExternal>true</DisableAnalyzeExternal>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
@ -239,10 +235,10 @@
|
||||
<LanguageStandard_C>stdc17</LanguageStandard_C>
|
||||
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
|
||||
<PrecompiledHeaderOutputFile />
|
||||
<AdditionalOptions>/Zc:twoPhase- /MP %(AdditionalOptions)</AdditionalOptions>
|
||||
<AdditionalOptions>/Zc:twoPhase- /MP -fms-compatibility-version=14 %(AdditionalOptions)</AdditionalOptions>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<CompileAs>Default</CompileAs>
|
||||
<LanguageStandard>stdcpp20</LanguageStandard>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
<DebugInformationFormat>None</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
@ -256,4 +252,4 @@
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
</Project>
|
||||
|
||||
@ -1,9 +1,9 @@
|
||||
#include "Autoarr.h"
|
||||
|
||||
Autoarr_define(uint8)
|
||||
Autoarr_define(int8)
|
||||
Autoarr_define(uint16)
|
||||
Autoarr_define(int16)
|
||||
Autoarr_define(uint8);
|
||||
Autoarr_define(int8);
|
||||
Autoarr_define(uint16);
|
||||
Autoarr_define(int16);
|
||||
Autoarr_define(uint32);
|
||||
Autoarr_define(int32);
|
||||
Autoarr_define(uint64);
|
||||
|
||||
@ -35,6 +35,7 @@ extern "C" {
|
||||
#pragma GCC error "unknown compiler"
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#define IFWIN(YES, NO) YES
|
||||
#define IFMSC(YES, NO) YES
|
||||
@ -48,9 +49,6 @@ extern "C" {
|
||||
#pragma GCC error "unknown compiler"
|
||||
#endif
|
||||
|
||||
#ifndef NULL
|
||||
#define NULL ((void*)0)
|
||||
#endif
|
||||
|
||||
#if __cplusplus
|
||||
}
|
||||
|
||||
@ -24,9 +24,9 @@ typedef enum __attribute__((__packed__)) my_type {
|
||||
UniversalType,
|
||||
AutoarrInt8Ptr, AutoarrUInt8Ptr, AutoarrInt16Ptr, AutoarrUInt16Ptr,
|
||||
AutoarrInt32Ptr, AutoarrUInt32Ptr, AutoarrInt64Ptr, AutoarrUInt64Ptr,
|
||||
AutoarrUnitypePtr, AutoarrKVPairPtr
|
||||
AutoarrUnitypePtr, AutoarrKVPairPtr, knSocketPtr
|
||||
} my_type;
|
||||
#define my_type_last AutoarrKVPairPtr
|
||||
#define my_type_last knSocketPtr
|
||||
|
||||
const char* my_type_name(my_type t);
|
||||
|
||||
|
||||
@ -33,7 +33,7 @@ void print_dtsod(Hashtable* dtsod){
|
||||
}
|
||||
|
||||
void test_dtsod(){
|
||||
//optime(__func__,1,({
|
||||
optime(__func__,1,({
|
||||
printf("\e[96m-------------[test_dtsod]-------------\n");
|
||||
Hashtable* dtsod;
|
||||
char* s;
|
||||
@ -61,5 +61,5 @@ void test_dtsod(){
|
||||
}));
|
||||
|
||||
free(s);
|
||||
//}));
|
||||
}));
|
||||
}
|
||||
@ -63,7 +63,7 @@ Unitype gett(Hashtable* ht){
|
||||
|
||||
void test_hashtable(){
|
||||
optime("test_hashtable",1,({
|
||||
printf("\e[96m-----------[test_hashtable]------------\n");
|
||||
printf("\e[96m-----------[test_hashtable]-----------\n");
|
||||
Hashtable* ht=Hashtable_create();
|
||||
printf("\e[92mhashtable created\n");
|
||||
print_hashtable(ht);
|
||||
|
||||
@ -7,7 +7,7 @@ void printstnode(STNode* node){
|
||||
"\n address: %p\n value: ",sizeof(STNode),node);
|
||||
printuni(node->value);
|
||||
// prints pointers to all existing branches
|
||||
printf("\n branches: %p\n", node->branches);
|
||||
/* printf("\n branches: %p\n", node->branches);
|
||||
if(node->branches) for(uint8 i=0;i<8;i++){
|
||||
printf(" \e[90m[%u]=%p\n",i,node->branches[i]);
|
||||
if(node->branches[i])
|
||||
@ -18,12 +18,12 @@ void printstnode(STNode* node){
|
||||
printf(" \e[90m[%u]=%p\n",iii,node->branches[i][ii][iii]);
|
||||
}
|
||||
|
||||
}
|
||||
} */
|
||||
}
|
||||
|
||||
void test_searchtree(){
|
||||
optime("test_searchtree",1,({
|
||||
printf("\e[96m-----------[test_searchtree]-----------\n");
|
||||
printf("\e[96m-----------[test_searchtree]----------\n");
|
||||
STNode* node=STNode_create();
|
||||
printf("\e[92mnode created\n");
|
||||
printf("push:\e[94m\n ");
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
|
||||
void test_string(){
|
||||
optime(__func__,1,({
|
||||
printf("\e[96m-------------[test_string]-------------\n");
|
||||
printf("\e[96m-------------[test_string]------------\n");
|
||||
char c[]="0123456789abcdef";
|
||||
string s={.ptr=c, .length=cptr_length(c)};
|
||||
if(s.length!=sizeof(c)-1) throw("string created with incorrect length");
|
||||
|
||||
@ -14,6 +14,8 @@ void test_hash_functions();
|
||||
void test_hashtable();
|
||||
void test_dtsod();
|
||||
|
||||
#define PRINT_SIZEOF(T) printf("\e[94m" #T " size: \e[96m" IFWIN("%llu", "%lu") "\n", sizeof(T))
|
||||
|
||||
#if __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
||||
Loading…
Reference in New Issue
Block a user