Mercurial > projects > ddmd
diff dmd/ArrayLengthExp.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 | e28b18c23469 |
line wrap: on
line diff
--- a/dmd/ArrayLengthExp.d Sat Aug 28 16:14:07 2010 +0200 +++ b/dmd/ArrayLengthExp.d Sat Aug 28 16:19:48 2010 +0200 @@ -1,14 +1,14 @@ -module dmd.ArrayLengthExp; - -import dmd.Expression; -import dmd.backend.elem; -import dmd.UnaExp; -import dmd.InterState; -import dmd.OutBuffer; -import dmd.Loc; -import dmd.Scope; -import dmd.IRState; -import dmd.HdrGenState; +module dmd.ArrayLengthExp; + +import dmd.Expression; +import dmd.backend.elem; +import dmd.UnaExp; +import dmd.InterState; +import dmd.OutBuffer; +import dmd.Loc; +import dmd.Scope; +import dmd.IRState; +import dmd.HdrGenState; import dmd.TOK; import dmd.Type; import dmd.WANT; @@ -16,8 +16,8 @@ import dmd.expression.ArrayLength; import dmd.backend.Util; -import dmd.backend.OPER; - +import dmd.backend.OPER; + class ArrayLengthExp : UnaExp { this(Loc loc, Expression e1) @@ -25,7 +25,7 @@ super(loc, TOK.TOKarraylength, ArrayLengthExp.sizeof, e1); } - Expression semantic(Scope sc) + override Expression semantic(Scope sc) { Expression e; @@ -42,7 +42,7 @@ return this; } - Expression optimize(int result) + override Expression optimize(int result) { //printf("ArrayLengthExp::optimize(result = %d) %s\n", result, toChars()); e1 = e1.optimize(WANTvalue | (result & WANTinterpret)); @@ -54,17 +54,17 @@ return e; } - Expression interpret(InterState istate) + override Expression interpret(InterState istate) { assert(false); } - void toCBuffer(OutBuffer buf, HdrGenState* hgs) + override void toCBuffer(OutBuffer buf, HdrGenState* hgs) { assert(false); } - elem* toElem(IRState* irs) + override elem* toElem(IRState* irs) { elem *e = e1.toElem(irs); e = el_una(OP64_32, type.totym(), e);