comparison dmd/EqualExp.d @ 72:2e2a5c3f943a

reduced warnings by adding override to the methods think this also normalizes different line endings used all over the place
author Trass3r
date Sat, 28 Aug 2010 16:19:48 +0200
parents cab4c37afb89
children 43073c7c7769
comparison
equal deleted inserted replaced
71:8e24ef1dd139 72:2e2a5c3f943a
37 { 37 {
38 super(loc, op, EqualExp.sizeof, e1, e2); 38 super(loc, op, EqualExp.sizeof, e1, e2);
39 assert(op == TOK.TOKequal || op == TOK.TOKnotequal); 39 assert(op == TOK.TOKequal || op == TOK.TOKnotequal);
40 } 40 }
41 41
42 Expression semantic(Scope sc) 42 override Expression semantic(Scope sc)
43 { 43 {
44 Expression e; 44 Expression e;
45 Type t1; 45 Type t1;
46 Type t2; 46 Type t2;
47 47
111 } 111 }
112 112
113 return e; 113 return e;
114 } 114 }
115 115
116 Expression optimize(int result) 116 override Expression optimize(int result)
117 { 117 {
118 Expression e; 118 Expression e;
119 119
120 //printf("EqualExp::optimize(result = %x) %s\n", result, toChars()); 120 //printf("EqualExp::optimize(result = %x) %s\n", result, toChars());
121 e1 = e1.optimize(WANTvalue | (result & WANTinterpret)); 121 e1 = e1.optimize(WANTvalue | (result & WANTinterpret));
129 if (e is EXP_CANT_INTERPRET) 129 if (e is EXP_CANT_INTERPRET)
130 e = this; 130 e = this;
131 return e; 131 return e;
132 } 132 }
133 133
134 Expression interpret(InterState istate) 134 override Expression interpret(InterState istate)
135 { 135 {
136 assert(false); 136 assert(false);
137 } 137 }
138 138
139 int isBit() 139 override int isBit()
140 { 140 {
141 assert(false); 141 assert(false);
142 } 142 }
143 143
144 bool isCommutative() 144 override bool isCommutative()
145 { 145 {
146 return true; 146 return true;
147 } 147 }
148 148
149 Identifier opId() 149 override Identifier opId()
150 { 150 {
151 return Id.eq; 151 return Id.eq;
152 } 152 }
153 153
154 elem* toElem(IRState* irs) 154 override elem* toElem(IRState* irs)
155 { 155 {
156 //printf("EqualExp::toElem() %s\n", toChars()); 156 //printf("EqualExp::toElem() %s\n", toChars());
157 elem* e; 157 elem* e;
158 OPER eop; 158 OPER eop;
159 Type t1 = e1.type.toBasetype(); 159 Type t1 = e1.type.toBasetype();