[Issue 16224] -cov marks the last line of do/while(0); as uncovered

2022-12-17 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16224 Iain Buclaw changed: What|Removed |Added Priority|P1 |P4 --

[Issue 16224] -cov marks the last line of do/while(0); as uncovered

2016-07-01 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16224 --- Comment #7 from Andrei Alexandrescu --- (In reply to Johan Engelen from comment #6) > > The coverage analyzer marks the line with "while (0);" as uncovered, > > although that is an useless tidbit. > > I don't think it is useless. In the OP exa

[Issue 16224] -cov marks the last line of do/while(0); as uncovered

2016-07-01 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16224 --- Comment #6 from Johan Engelen --- > The coverage analyzer marks the line with "while (0);" as uncovered, > although that is an useless tidbit. I don't think it is useless. In the OP example, while(0) is uncovered because there is never a "fall

[Issue 16224] -cov marks the last line of do/while(0); as uncovered

2016-07-01 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16224 --- Comment #5 from Andrei Alexandrescu --- (In reply to Steven Schveighoffer from comment #4) > I don't see why while(true) is any worse. > > Essentially: > > while(true) > { > ... > break; > } > > Is the same as the do...while(0) Yah, switch is

[Issue 16224] -cov marks the last line of do/while(0); as uncovered

2016-07-01 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16224 Steven Schveighoffer changed: What|Removed |Added CC||schvei...@yahoo.com --- Comment #4 fr

[Issue 16224] -cov marks the last line of do/while(0); as uncovered

2016-07-01 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16224 --- Comment #3 from Andrei Alexandrescu --- For clarity, I'll paste the code (fixed to do something useful, i.e. compute the cube of an int) and the listing: int cube(int x) { do { if (x == 0) break; if (x == 1)

[Issue 16224] -cov marks the last line of do/while(0); as uncovered

2016-07-01 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16224 --- Comment #2 from hst...@quickfur.ath.cx --- Nevermind, I get it now. Sorry for the noise. --

[Issue 16224] -cov marks the last line of do/while(0); as uncovered

2016-07-01 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16224 hst...@quickfur.ath.cx changed: What|Removed |Added CC||hst...@quickfur.ath.cx --- Comment #