are mixin string templates with functions removed?
Dicebot
public at dicebot.lv
Thu Aug 1 16:15:44 PDT 2013
On Thursday, 1 August 2013 at 22:59:14 UTC, Dicebot wrote:
> ...
To further clarify this, I have used your simplified example:
-------------
// test.d
string generator(int x)
{
if (x > 0)
{
asm
{
mov EAX, 0xDEAD;
}
}
return "return 42;";
}
int main()
{
mixin(generator(0));
}
-------------
$ dmd -release -inline -O test.d
-------------
$ objdump -d test | grep dead
417705: b8 ad de 00 00 mov $0xdead,%eax
More information about the Digitalmars-d-learn
mailing list