const challenge
Sergey Gromov
snake.scaly at gmail.com
Fri Feb 1 14:47:46 PST 2008
Janice Caron Wrote:
> > So the only way to return a unique result from a function is to dup
> > or new or inline-construct directly within its return statement. Other
> > return values are illegal.
>
> Good point. It should have been
>
> return cast(unique)s;
The possibility to cast should still be there for complex cases where you
can't/don't want to put data allocation into return statement but can
guarantee its uniqueness.
SnakE
More information about the Digitalmars-d
mailing list