On Friday, 25 April 2025 at 16:59:16 UTC, monkyyy wrote:
its extremely unclear what your trying to do my best geuss:

I want to use a mixin template to generate a top-level function. Like, is there a variant of the following which makes a function named "foo1" available?

Andy

```d
mixin template Foo(alias fn) {
    int fn() { return 1; }
}

mixin Foo!foo1;

void main() {
    import std.stdio : writeln;

    writeln(foo1());
}
```

Reply via email to