changeset 288:568fa9d15b60

calling static function of a super class Carlos Santander B. <csantander619@gmail.com> 2005-02-15 news:cutof5$1e68$1@digitaldaemon.com nntp://news.digitalmars.com/D.gnu/1039
author thomask
date Fri, 18 Feb 2005 23:07:46 +0000
parents a19d5847a8b9
children 92afe4ae392b
files run/static_29.d
diffstat 1 files changed, 28 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/run/static_29.d	Fri Feb 18 23:07:46 2005 +0000
@@ -0,0 +1,28 @@
+// $HeadURL$
+// $Date$
+// $Author$
+
+// @author@	Carlos Santander B. <csantander619@gmail.com>
+// @date@	2005-02-15
+// @uri@	news:cutof5$1e68$1@digitaldaemon.com
+// @url@	nntp://news.digitalmars.com/D.gnu/1039
+
+module dstress.run.static_29;
+
+class A{
+	static int test(){
+		return 5;
+	}
+}
+
+class B:A{
+        int check(){
+        	return A.test+1;
+        }
+}
+
+int main(){
+	B b = new B();
+	assert(b.check()==6);
+	return 0;
+}
\ No newline at end of file