This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// lambda 고찰 #1 | |
// generic lambda의 타입은 어떻게 되는가? | |
void test1() | |
{ | |
auto f = [](auto x, auto y) // c++14: generic lambda | |
{ static int count = 0; printf("(%s) count:%d\n", __func__, count++); | |
return x + y; | |
}; | |
auto v = f(5, 1.5); // count:0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void foo(unsigned char c) | |
{ | |
printf("void test( unsigned char c ): %d\n", c); | |
} | |
void foo(signed char c) | |
{ | |
printf("void test( signed char c ): %d\n", c ); | |
} | |
void test() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using namespace T_ms_db; | |
/**************************************************************************** | |
* main server | |
*/ | |
class MS_ClientSession : public ITDBToTMSHandler { // 생성된 handler class에서 상속 | |
/*...*/ | |
template < typename T > | |
void QueueSend(const T&) {} // 테스트 코드용 dummy Send | |
int On_DM_GetAccountRes(const Recv_DM_GetAccountRes *packet) override; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// generated by SQL COMPILER | |
// time : 2015-05-27 01:02:42.811 | |
// do not modify | |
// contact: icedac@gmail.com | |
#pragma once | |
#pragma warning(push) | |
#pragma warning(disable: 4100) // unreferenced formal parameter | |
namespace test_db { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<xml> | |
<config> | |
<db name="test_db" version="9"/> <!-- increment version if backward compatibility broken --> | |
<output type="cpp" code="GameDB.h"/> | |
<output type="MySQL" code="GameDB_MySQL.sql"/> | |
</config> | |
<error> | |
<code value="0" name="SUCCESS" desc="success"/> | |
<code value="1" name="ERR_NOT_IMPLEMENTED"/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Timesync.cpp : time resync from NTP server | |
// ref: http://www.abnormal.com/~thogard/ntp/ | |
// ref: http://stackoverflow.com/a/19815921 | |
#include <winsock2.h> | |
#include <time.h> | |
#include <strsafe.h> | |
#pragma comment( lib, "ws2_32.lib" ) |