ubyte[1000] foo() nothrow @safe {
typeof(return) data;
// some code here.
return data;
}
void main() nothrow {
immutable data = foo();
}
Bye,
bearophile
Is it possible and a good idea to change the D ABI to make code
like this avoid an array copy in 100% of the cases (without
inlining)?
- Returning fixed size arrays bearophile via Digitalmars-d-learn
- Re: Returning fixed size arra... bearophile via Digitalmars-d-learn
- Re: Returning fixed size ... John Colvin via Digitalmars-d-learn
- Re: Returning fixed s... bearophile via Digitalmars-d-learn
- Re: Returning fix... John Colvin via Digitalmars-d-learn
- Re: Returnin... bearophile via Digitalmars-d-learn
- Re: Returning fixed size arra... Tobias Pankrath via Digitalmars-d-learn
- Re: Returning fixed size ... bearophile via Digitalmars-d-learn
