Browse Source

* fixed low(set)/high(set) after previous changes + test

git-svn-id: trunk@9371 -
Jonas Maebe 17 years ago
parent
commit
5196db1ac3
3 changed files with 10 additions and 1 deletions
  1. 1 0
      .gitattributes
  2. 2 1
      compiler/ninl.pas
  3. 7 0
      tests/tbs/tb205.pp

+ 1 - 0
.gitattributes

@@ -6578,6 +6578,7 @@ tests/tbs/tb0539.pp svneol=native#text/plain
 tests/tbs/tb0540.pp svneol=native#text/x-pascal
 tests/tbs/tb0540.pp svneol=native#text/x-pascal
 tests/tbs/tb0541.pp svneol=native#text/plain
 tests/tbs/tb0541.pp svneol=native#text/plain
 tests/tbs/tb0542.pp svneol=native#text/plain
 tests/tbs/tb0542.pp svneol=native#text/plain
+tests/tbs/tb205.pp svneol=native#text/plain
 tests/tbs/ub0060.pp svneol=native#text/plain
 tests/tbs/ub0060.pp svneol=native#text/plain
 tests/tbs/ub0069.pp svneol=native#text/plain
 tests/tbs/ub0069.pp svneol=native#text/plain
 tests/tbs/ub0119.pp svneol=native#text/plain
 tests/tbs/ub0119.pp svneol=native#text/plain

+ 2 - 1
compiler/ninl.pas

@@ -2271,7 +2271,8 @@ implementation
                 begin
                 begin
                   case left.resultdef.typ of
                   case left.resultdef.typ of
                     orddef,
                     orddef,
-                    enumdef:
+                    enumdef,
+                    setdef:
                       ;
                       ;
                     arraydef:
                     arraydef:
                       begin
                       begin

+ 7 - 0
tests/tbs/tb205.pp

@@ -0,0 +1,7 @@
+var
+  s: set of 3..40;
+begin
+  if (low(s)<>3) or
+     (high(s)<>40) then
+    halt(1);
+end.