std.string.translate using initializing twice?

2010-08-09 Thread simendsjo
translate does this: bool[256] deltab; // this would make all values of deltab false as bool.init == false, right? deltab[] = false; Isn't this just initializing all values of deltab to false twice..? And my Is this more readable? Original: string translate(string s, in string

Re: std.string.translate using initializing twice?

2010-08-09 Thread Jonathan M Davis
On Monday, August 09, 2010 17:45:07 simendsjo wrote: translate does this: bool[256] deltab; // this would make all values of deltab false as bool.init == false, right? deltab[] = false; Isn't this just initializing all values of deltab to false twice..? I believe that you are

Re: std.string.translate using initializing twice?

2010-08-09 Thread Jonathan M Davis
On Monday, August 09, 2010 18:03:48 simendsjo wrote: Yeah. Don't remember when, don't remember where, but I too have read that preincrement is faster (PS: I don't know any assembler!). As long as I don't use it in an expression, I always use post-increment as it shouldn't make a difference.