diff tests/mini/forwdecl1.d @ 656:a15ccbf7451d

Support structs that are merely a forward reference. See mini/forwdecl1.d
author Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
date Mon, 06 Oct 2008 14:06:55 +0200
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/mini/forwdecl1.d	Mon Oct 06 14:06:55 2008 +0200
@@ -0,0 +1,12 @@
+struct Foo;
+
+Foo* foo()
+{
+    return null;
+}
+
+void main()
+{
+    Foo* f = foo();
+    assert(f is null);
+}