Browse Source

+ test for double usage of units

Jonas Maebe 22 years ago
parent
commit
f35267db01
3 changed files with 24 additions and 0 deletions
  1. 4 0
      tests/tbf/tb0158.pp
  2. 13 0
      tests/tbf/ub0158a.pp
  3. 7 0
      tests/tbf/ub0158b.pp

+ 4 - 0
tests/tbf/tb0158.pp

@@ -0,0 +1,4 @@
+uses ub0158a;
+
+begin
+end.

+ 13 - 0
tests/tbf/ub0158a.pp

@@ -0,0 +1,13 @@
+unit ub0158a;
+
+interface
+
+uses ub0158b;
+
+implementation
+
+{ should give "duplicate identifier error", because already used in the }
+{ interface                                                             }
+uses ub0158b;
+
+end.

+ 7 - 0
tests/tbf/ub0158b.pp

@@ -0,0 +1,7 @@
+unit ub0158b;
+
+interface
+
+implementation
+
+end.