summaryrefslogtreecommitdiff
path: root/tests/webtbs/tw26403.pp
diff options
context:
space:
mode:
authorjonas <jonas@3ad0048d-3df7-0310-abae-a5850022a9f2>2015-01-21 23:28:34 +0000
committerjonas <jonas@3ad0048d-3df7-0310-abae-a5850022a9f2>2015-01-21 23:28:34 +0000
commit1903b037de2fb3e75826406b46f055acb70963fa (patch)
tree604cd8b790fe14e5fbe441d4cd647c80d2a36a9a /tests/webtbs/tw26403.pp
parentad1141d52f8353457053b925cd674fe1d5c4eafc (diff)
parent953d907e4d6c3a5c2f8aaee6e5e4f73c55ce5985 (diff)
downloadfpc-1903b037de2fb3e75826406b46f055acb70963fa.tar.gz
* synchronised with trunk till r29513blocks
git-svn-id: http://svn.freepascal.org/svn/fpc/branches/blocks@29516 3ad0048d-3df7-0310-abae-a5850022a9f2
Diffstat (limited to 'tests/webtbs/tw26403.pp')
-rw-r--r--tests/webtbs/tw26403.pp23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/webtbs/tw26403.pp b/tests/webtbs/tw26403.pp
new file mode 100644
index 0000000000..9dee0fb10b
--- /dev/null
+++ b/tests/webtbs/tw26403.pp
@@ -0,0 +1,23 @@
+{ %OPT=-Sew }
+{$OPTIMIZATION DFA}
+{$HINTS ON}
+program test;
+
+type
+ TIntArray = array of Integer;
+
+procedure Reset(var Foo: TIntArray);
+begin
+ SetLength(Foo, 0);
+end;
+
+procedure Foo(var Bar: TIntArray);
+begin
+ Reset(Bar); // Hint: Local variable "Bar" does not seem to be initialized
+end;
+
+var
+ Baz: TIntArray;
+begin
+ Foo(Baz); // Hint: Local variable "Baz" does not seem to be initialized
+end.