File: tchar.h

package info (click to toggle)
nsis 3.04-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 12,076 kB
  • sloc: cpp: 36,735; ansic: 26,691; python: 1,282; asm: 712; xml: 511; pascal: 215; makefile: 205
file content (34 lines) | stat: -rwxr-xr-x 823 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
// Added for Unicode support by Jim Park -- 08/29/2007
#pragma once
#include <string>
#include <sstream>

#ifdef _UNICODE
#  define tout        wcout
#  define terr        wcerr
#  define __T(x)      L ## x
#  define _T(x)       __T(x)
#  define _tmain      wmain
#  define _tunlink    _wunlink
#  define FOPEN _wfopen

   typedef std::wstring        tstring;
   typedef std::wistringstream tistringstream;

   typedef wchar_t      TCHAR;
#else
#  define tout        cout
#  define terr        cerr
#  define _T(x)       x
#  define _tmain      main
#  ifdef _WIN32
#  define _tunlink    _unlink
#  else
#  define _tunlink    unlink
#  endif
#  define FOPEN fopen

   typedef std::string         tstring;
   typedef std::istringstream  tistringstream;
   typedef char        TCHAR;
#endif