summaryrefslogtreecommitdiff
path: root/fpcsrc/tests/webtbs/tw15377.pp
blob: 386bfffe2c2a9bfec978febb7e1b0b9186f79b6c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
program test;

uses typinfo;

Type
  E1 = (en1,en2,en3,en4,en5);
  E2 = en3..en5;
begin
  if (GetEnumName(TypeInfo(E1),Ord(High(E1))) <> 'en5') then
    halt(1);
  if (GetEnumName(TypeInfo(E2),Ord(High(E2))) <> 'en5') then
    halt(1);
end.