summary refs log tree commit diff stats
path: root/nim/charsets.pas
blob: a5f14450fde66a36fbb48614a8e80103e1acbc00 (plain) (blame)
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
//
//
//           The Nimrod Compiler
//        (c) Copyright 2008 Andreas Rumpf
//
//    See the file "copying.txt", included in this
//    distribution, for details about the copyright.
//

unit charsets;

interface

const
  CharSize = SizeOf(Char);
  Lrz = ' ';
  Apo = '''';
  Tabulator = #9;
  ESC = #27;
  CR = #13;
  FF = #12;
  LF = #10;
  BEL = #7;
  BACKSPACE = #8;
  VT = #11;
{$ifdef macos}
  DirSep = ':';
  NL = CR + '';
  FirstNLchar = CR;
  PathSep = ';'; // XXX: is this correct?
{$else}
  {$ifdef unix}
  DirSep = '/';
  NL = LF + '';
  FirstNLchar = LF;
  PathSep = ':';
  {$else} // windows, dos
  DirSep = '\';
  NL = CR + LF;
  FirstNLchar = CR;
  DriveSeparator = ':';
  PathSep = ';';
  {$endif}
{$endif}
  UpLetters   = ['A'..'Z', #192..#222];
  DownLetters = ['a'..'z', #223..#255];
  Numbers     = ['0'..'9'];
  Letters     = UpLetters + DownLetters;

type
  TCharSet = set of Char;
  PCharSet = ^TCharSet;

implementation

end.