writeln() sometimes double prints from main() if I run a thread checking for input?
Ivan Kazmenko via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Wed Aug 30 03:44:43 PDT 2017
On Wednesday, 30 August 2017 at 10:13:57 UTC, Timothy Foster
wrote:
> I'm not sure if this is a known issue, or if I just don't
> understand how to use threads, but I've got writeln statements
> sometimes printing out twice in some areas of my code.
> <...>
> Does anyone know what is causing this or how I can fix it?
Difficult to say by what you posted.
You may want to provide a complete example so that others may try
to reproduce it. Additionally, as you gradually simplify your
code until it is small enough to post here, or on DPaste, you may
find the cause faster yourself.
Ivan Kazmenko.
More information about the Digitalmars-d-learn
mailing list