On Friday, 21 June 2019 at 15:54:35 UTC, Adam D. Ruppe wrote:
On Friday, 21 June 2019 at 15:42:56 UTC, Emmanuelle wrote:
[...]
This sounds very similar to something I hacked together a while
ago and recently wrote about making cleaner code:
https://forum.dlang.org/post/ekbyseslunvmudkhl...@
On Friday, 21 June 2019 at 15:42:56 UTC, Emmanuelle wrote:
Yeah, I want to be able to basically use mixin templates but
with expressions instead, with the code being executed on the
scope of the caller, not the callee; but it seems that's
impossible without passing strings
This sounds very si
On Thursday, 20 June 2019 at 20:38:48 UTC, Dennis wrote:
On Thursday, 20 June 2019 at 19:09:11 UTC, Emmanuelle wrote:
Is there any trait or Phobos function for transforming a
function/delegate/lambda/whatever's body into a string
suitable for `mixin(...)`? For example:
See:
https://forum.dlan
On Thursday, 20 June 2019 at 19:09:11 UTC, Emmanuelle wrote:
Is there any trait or Phobos function for transforming a
function/delegate/lambda/whatever's body into a string suitable
for `mixin(...)`? For example:
See:
https://forum.dlang.org/post/kozwskltzidfnatbp...@forum.dlang.org
If not,
On Thursday, 20 June 2019 at 19:09:11 UTC, Emmanuelle wrote:
Hello!
Is there any trait or Phobos function for transforming a
function/delegate/lambda/whatever's body into a string suitable
for `mixin(...)`? For example:
---
__traits(getBody, (int a, int b) => a + b); // returns "(int a,
int
Hello!
Is there any trait or Phobos function for transforming a
function/delegate/lambda/whatever's body into a string suitable
for `mixin(...)`? For example:
---
__traits(getBody, (int a, int b) => a + b); // returns "(int a,
int b) => a + b"
// o