On 08/05/2023 9:07 AM, realhet wrote:
I just don't understand why the int array fails -> [1, 2, 3....] It would look so nice.

It doesn't.

```d
import std, core.simd;

void main()
{
     enum ubyte16
         good1 = mixin([1, 2, 3, 4]),
         bad = [1, 2, 3, 4];

     static immutable ubyte16
         good2 = mixin([1, 2, 3, 4]),
         crash = [1, 2, 3, 4];

    writeln(good1);
    writeln(bad);
    writeln(good2);
    writeln(crash);
}
```

```
[1, 2, 3, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
[1, 2, 3, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
[1, 2, 3, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
[1, 2, 3, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
```

Its a bug with ``pragma(msg)`` by the looks.
  • core.simd ubyte1... realhet via Digitalmars-d-learn
    • Re: core.si... Richard (Rikki) Andrew Cattermole via Digitalmars-d-learn
      • Re: cor... realhet via Digitalmars-d-learn
        • Re:... Richard (Rikki) Andrew Cattermole via Digitalmars-d-learn
          • ... realhet via Digitalmars-d-learn

Reply via email to