Error: cannot return non-void from void function
ketmar via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Thu Nov 27 13:21:52 PST 2014
On Thu, 27 Nov 2014 21:14:57 +0000
Daniel Kozak via Digitalmars-d-learn
<digitalmars-d-learn at puremagic.com> wrote:
> import core.runtime;
> import std.c.process;
> writeln("Can't find input file with list of links.");
> Runtime.terminate();
> exit(1);
please-please-please don't teach people that! using such features
requiring deep understanding of how D runtime works, and how it
interacts with C runtime, with GC, with stack objects and so on.
it's better to now show people bad samples instead of telling them
"don't do what i just wrote". ;-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <http://lists.puremagic.com/pipermail/digitalmars-d-learn/attachments/20141127/5a9d8e64/attachment.sig>
More information about the Digitalmars-d-learn
mailing list