changeset 661:1885fd593bb0

zwang <nehzgnaw@gmail.com> 2005-09-09 news:dfsni3$2jst$1@digitaldaemon.com
author thomask
date Sat, 10 Sep 2005 06:28:12 +0000
parents 2474750465ff
children 5e5f8438dd86
files run/i/inline_14_A.d run/i/inline_14_B.d run/i/inline_14_C.d
diffstat 3 files changed, 100 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/run/i/inline_14_A.d	Sat Sep 10 06:28:12 2005 +0000
@@ -0,0 +1,32 @@
+// $HeadURL$
+// $Date$
+// $Author$
+
+// @author@	zwang <nehzgnaw@gmail.com>
+// @date@	2005-09-09
+// @uri@	news:dfsni3$2jst$1@digitaldaemon.com
+
+module dstress.run.i.inline_14_A;
+
+int a = 0;
+int b = 0;
+
+class A{
+        void f(){
+                a++;
+        }
+}
+
+final class B : A{
+        void f(){
+                b++;
+                super.f();
+        }
+}
+
+int main(){
+        (new B).f();
+        assert(a==1);
+        assert(b==1);
+        return 0;
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/run/i/inline_14_B.d	Sat Sep 10 06:28:12 2005 +0000
@@ -0,0 +1,34 @@
+// $HeadURL$
+// $Date$
+// $Author$
+
+// @author@	zwang <nehzgnaw@gmail.com>
+// @date@	2005-09-09
+// @uri@	news:dfsni3$2jst$1@digitaldaemon.com
+
+// __DSTRESS_DFLAGS__ -inline
+
+module dstress.run.i.inline_14_B;
+
+int a = 0;
+int b = 0;
+
+class A{
+        void f(){
+                a++;
+        }
+}
+
+final class B : A{
+        void f(){
+                b++;
+                super.f();
+        }
+}
+
+int main(){
+        (new B).f();
+        assert(a==1);
+        assert(b==1);
+        return 0;
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/run/i/inline_14_C.d	Sat Sep 10 06:28:12 2005 +0000
@@ -0,0 +1,34 @@
+// $HeadURL$
+// $Date$
+// $Author$
+
+// @author@	zwang <nehzgnaw@gmail.com>
+// @date@	2005-09-09
+// @uri@	news:dfsni3$2jst$1@digitaldaemon.com
+
+// __DSTRESS_DFLAGS__ -inline
+
+module dstress.run.i.inline_14_C;
+
+int a = 0;
+int b = 0;
+
+class A{
+        void f(){
+                a++;
+        }
+}
+
+class B : A{
+        void f(){
+                b++;
+                super.f();
+        }
+}
+
+int main(){
+        (new B).f();
+        assert(a==1);
+        assert(b==1);
+        return 0;
+}
\ No newline at end of file