Thread overview
New update fix
Mar 02
user1234
March 02

SLM,

What exactly did this patch with the new update fix?

  uint x = 255;
  auto data = cast(ubyte[])[x];

  assert(data[0] == 255);   // ok
  assert(data.length == 4); // error

Should it give an assertion error above with this update? Be open with wouldn't it be nice to be able to do a binary sum example without needing extra code?


  enum p1 = 131071;
  enum p2 = 524287;

void main()
{
  import std.stdio;
  foreach(p; [p1, p2, p1 + p2])
  {
    write("[ ");
    //auto d = [p];
    foreach_reverse(b; cast(ubyte[])[p])
    {
      b.writef!"%08b ";
    }
    writeln("]");
  }
} /* Expected:
[ 00000000 00000001 11111111 11111111 ]
[ 00000000 00000111 11111111 11111111 ]
[ 00000000 00001001 11111111 11111110 ]
*/

SDB@79

March 02

On Saturday, 2 March 2024 at 08:41:40 UTC, Salih Dincer wrote:

>

SLM,

What exactly did this patch with the new update fix?

Nothing, it looks like what happened is that the issue was wrongly referenced by a dlang.org PR (https://github.com/dlang/dlang.org/pull/3701/commits/4e8db30f0bf3c330c3431e83fe8a75f843b40857).

March 04

On Saturday, 2 March 2024 at 09:18:58 UTC, user1234 wrote:

>

On Saturday, 2 March 2024 at 08:41:40 UTC, Salih Dincer wrote:

>

SLM,

What exactly did this patch with the new update fix?

Nothing, it looks like what happened is that the issue was wrongly referenced by a dlang.org PR (https://github.com/dlang/dlang.org/pull/3701/commits/4e8db30f0bf3c330c3431e83fe8a75f843b40857).

Not wrongly referenced. The pr changed the spec to be clearer about the behavior. The behavior did not change.

The bug was closed as “fixed” incorrectly. I switched it to “wontfix”

The change log generator must have picked it up because of that.

-Steve