changeset 813:c4c154735ebb

Walter <walter@digitalmars.com> 2006-01-29 mail:000c01c62513$82617830$0400a8c0@colossus
author thomask
date Sun, 05 Feb 2006 09:58:54 +0000
parents eaf0a0d20b60
children 0be84fe21292
files nocompile/s/static_if_01_A.d nocompile/s/static_if_01_B.d run/s/static_if_01_A.d run/s/static_if_01_B.d
diffstat 4 files changed, 39 insertions(+), 19 deletions(-) [+]
line wrap: on
line diff
--- a/nocompile/s/static_if_01_A.d	Sun Feb 05 09:58:23 2006 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,10 +0,0 @@
-// $HeadURL$
-// $Date$
-// $Author$
-
-// __DSTRESS_ELINE__ 9
-
-module dstress.nocompile.s.static_if_01_A;
-
-static if (1)
-	int i;
\ No newline at end of file
--- a/nocompile/s/static_if_01_B.d	Sun Feb 05 09:58:23 2006 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,9 +0,0 @@
-// $HeadURL$
-// $Date$
-// $Author$
-
-// __DSTRESS_ELINE__ 9
-
-module dstress.nocompile.s.static_if_01_B;
-
-static if (1)
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/run/s/static_if_01_A.d	Sun Feb 05 09:58:54 2006 +0000
@@ -0,0 +1,19 @@
+// $HeadURL$
+// $Date$
+// $Author$
+
+module dstress.run.s.static_if_01_A;
+
+static if (1){
+	int i = 9;
+}else{
+	static assert(0);
+}
+
+int main(){
+	if(i == 9){
+		return 0;
+	}
+}
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/run/s/static_if_01_B.d	Sun Feb 05 09:58:54 2006 +0000
@@ -0,0 +1,20 @@
+// $HeadURL$
+// $Date$
+// $Author$
+
+module dstress.run.s.static_if_01_B;
+
+const int a = 2;
+const int b = 3;
+
+static if (a == b - 1){
+	const int c = a + b;
+}else{
+	static assert(0);
+}
+
+int main(){
+	if(c == 5){
+		return 0;
+	}
+}