😀

So the problem is that the structure is not in the inter-module space

On Monday, 25 April 2022 at 16:11:47 UTC, rassoc wrote:

This works:

```d
import std;

void main() {
    struct Foo { string s; }
    Foo[] arr = ["abc", "def", "ghi"].map!Foo.array;
    arr.writeln; // => [Foo("abc"), Foo("def"), Foo("ghi")]
}
```

If ```sruct Foo {}``` is not taken outside of ```main()``` it will fail for many possibilities!

**For example:**
Error: cannot access frame pointer of `source.main.Foo`

SDB@79

Reply via email to