comparison dmd/GotoCaseStatement.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 4290d870944a
children e28b18c23469
comparison
equal deleted inserted replaced
71:8e24ef1dd139 72:2e2a5c3f943a
22 super(loc); 22 super(loc);
23 cs = null; 23 cs = null;
24 this.exp = exp; 24 this.exp = exp;
25 } 25 }
26 26
27 Statement syntaxCopy() 27 override Statement syntaxCopy()
28 { 28 {
29 Expression e = exp ? exp.syntaxCopy() : null; 29 Expression e = exp ? exp.syntaxCopy() : null;
30 GotoCaseStatement s = new GotoCaseStatement(loc, e); 30 GotoCaseStatement s = new GotoCaseStatement(loc, e);
31 return s; 31 return s;
32 } 32 }
33 33
34 Statement semantic(Scope sc) 34 override Statement semantic(Scope sc)
35 { 35 {
36 if (exp) 36 if (exp)
37 exp = exp.semantic(sc); 37 exp = exp.semantic(sc);
38 38
39 if (!sc.sw) 39 if (!sc.sw)
48 } 48 }
49 } 49 }
50 return this; 50 return this;
51 } 51 }
52 52
53 Expression interpret(InterState istate) 53 override Expression interpret(InterState istate)
54 { 54 {
55 assert(false); 55 assert(false);
56 } 56 }
57 57
58 BE blockExit() 58 override BE blockExit()
59 { 59 {
60 return BEgoto; 60 return BEgoto;
61 } 61 }
62 62
63 void toCBuffer(OutBuffer buf, HdrGenState* hgs) 63 override void toCBuffer(OutBuffer buf, HdrGenState* hgs)
64 { 64 {
65 buf.writestring("goto case"); 65 buf.writestring("goto case");
66 if (exp) 66 if (exp)
67 { 67 {
68 buf.writebyte(' '); 68 buf.writebyte(' ');
70 } 70 }
71 buf.writebyte(';'); 71 buf.writebyte(';');
72 buf.writenl(); 72 buf.writenl();
73 } 73 }
74 74
75 void toIR(IRState* irs) 75 override void toIR(IRState* irs)
76 { 76 {
77 assert(false); 77 assert(false);
78 } 78 }
79 } 79 }