Thread overview
[Issue 11305] Operations with array length cannot be used as a condition
Jun 30, 2019
Basile-z
Mar 21, 2020
Basile-z
Dec 17, 2022
Iain Buclaw
Feb 11, 2023
Basile-z
June 30, 2019
https://issues.dlang.org/show_bug.cgi?id=11305

Basile-z <b2.temp@gmx.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |b2.temp@gmx.com

--- Comment #1 from Basile-z <b2.temp@gmx.com> ---
This is because the preincrement expression is lowered.

   ++arr.length

is rewritten

    arr.length = arr.length + 1LU

which  is not allowed as IfCondition, to prevent the "=" vs "==" error.

--
March 21, 2020
https://issues.dlang.org/show_bug.cgi?id=11305

Basile-z <b2.temp@gmx.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|b2.temp@gmx.com             |

--
December 17, 2022
https://issues.dlang.org/show_bug.cgi?id=11305

Iain Buclaw <ibuclaw@gdcproject.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P2                          |P3

--
February 11, 2023
https://issues.dlang.org/show_bug.cgi?id=11305

Basile-z <b2.temp@gmx.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |b2.temp@gmx.com
         Resolution|---                         |WORKSFORME

--- Comment #2 from Basile-z <b2.temp@gmx.com> ---
works since 2.088

--