Explorar o código

* unreachable code warning

peter %!s(int64=20) %!d(string=hai) anos
pai
achega
3a9740ab12
Modificáronse 1 ficheiros con 23 adicións e 0 borrados
  1. 23 0
      tests/webtbf/tw3553.pp

+ 23 - 0
tests/webtbf/tw3553.pp

@@ -0,0 +1,23 @@
+{ %fail }
+{ %opt=-Sew }
+
+{ Source provided for Free Pascal Bug Report 3553 }
+{ Submitted by "Naj Kejah" on  2005-01-15 }
+{ e-mail: [email protected] }
+
+var K : integer;
+
+BEGIN
+  while FALSE do
+    K:=2;{ NO warning "unreachable code" from User.txt  }
+
+  if FALSE then
+    K:=2
+  else
+    K:=3;
+
+  if TRUE then
+    K:=2
+  else
+    K:=3;
+END.