[Issue 17771] foreach over const input range fails

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

[Issue 17771] foreach over const input range fails

2022-02-23 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 Paul Backus changed: What|Removed |Added CC||elpenguin...@gmail.com --- Comment #13 from

[Issue 17771] foreach over const input range fails

2017-08-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 Jonathan M Davis changed: What|Removed |Added CC|

[Issue 17771] foreach over const input range fails

2017-08-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 ag0ae...@gmail.com changed: What|Removed |Added CC||ag0ae...@gmail.com --- Comment #11 from

[Issue 17771] foreach over const input range fails

2017-08-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 --- Comment #10 from Steven Schveighoffer --- It's actually counter-intuitive for the D compiler to strip qualifiers automatically, it almost never happens. The only place I'm aware of is IFTI for arrays and pointers. I feel

[Issue 17771] foreach over const input range fails

2017-08-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 --- Comment #9 from Alex Goltman --- Asking the user to use a converter makes sense when the user understands there's a reason to convert. Here it's counter-intuitive - the error stating foreach doesn't work with a const

[Issue 17771] foreach over const input range fails

2017-08-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 --- Comment #8 from Steven Schveighoffer --- (In reply to Alex Goltman from comment #7) > Actually map does works on const NumRange, since it's declared as: > > auto map(Range)(Range r) if (isInputRange!(Unqual!Range))

[Issue 17771] foreach over const input range fails

2017-08-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 Alex Goltman changed: What|Removed |Added Status|RESOLVED|REOPENED

[Issue 17771] foreach over const input range fails

2017-08-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 --- Comment #6 from Steven Schveighoffer --- (In reply to Eyal from comment #4) > * Pointers are dereferenced in some contexts but not others Not sure about this one. Perhaps an example can explain better? > * Integers have

[Issue 17771] foreach over const input range fails

2017-08-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 --- Comment #5 from Steven Schveighoffer --- But the problem is that almost all range code is templated, so you are going to test with something that works, and then it will fail with something that doesn't. Subtle

[Issue 17771] foreach over const input range fails

2017-08-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 Eyal changed: What|Removed |Added CC||e...@weka.io --- Comment #4 from Eyal

[Issue 17771] foreach over const input range fails

2017-08-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 Steven Schveighoffer changed: What|Removed |Added Status|REOPENED|RESOLVED

[Issue 17771] foreach over const input range fails

2017-08-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 Alex Goltman changed: What|Removed |Added Status|RESOLVED|REOPENED

[Issue 17771] foreach over const input range fails

2017-08-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17771 Steven Schveighoffer changed: What|Removed |Added Status|NEW |RESOLVED