libiop学习笔记(一周目)

编译方面:

  _tmain为mian的别名。win32下#include "stdafx.h"里#include <tchar.h>可找到#define _tmain main。

  通常是这么写。

  #ifdef WIN32
  #include "stdafx.h"
  #else
  typedef char _TCHAR;
  #define _tmain main
  #endif

 

 

  extern "c"{  },表示块里的内容用c来编译,而不是c++。通常可以这么写。

  #ifdef __cplusplus
  extern "C" {
  #endif

 

  #ifdef __cplusplus
  }
  #endif

posted on 2017-07-17 14:05  cheer_s  阅读(236)  评论(0编辑  收藏  举报