Re: parallel foreach stuck on 8 workUnitSize

2022-01-08 Thread Ali Çehreli via Digitalmars-d-learn
On 1/8/22 7:18 PM, Booster wrote: > https://dlang.org/library/std/parallelism/task_pool.parallel.html#workUnitSize > > > Basically have no difference than the above but when I change the > workUnitSize to 1, 4, whatever it is always running 8 parallel loops. > > Either a bug or workUnitSize

parallel foreach stuck on 8 workUnitSize

2022-01-08 Thread Booster via Digitalmars-d-learn
https://dlang.org/library/std/parallelism/task_pool.parallel.html#workUnitSize Basically have no difference than the above but when I change the workUnitSize to 1, 4, whatever it is always running 8 parallel loops. Either a bug or workUnitSize is not what I think it is. I simply want to

Re: srand in D

2022-01-08 Thread Ali Çehreli via Digitalmars-d-learn
On 1/8/22 4:17 PM, kdevel wrote: > enum immutable (char) [] allowed_chars = [ >'c', 'f', 'g', 'h', 'j', 'k', 'l', 'm', 'n', 'p', 'r', 't', 'v', >'w', 'x', 'y', 'z', '1', '2', '3', '4', '5', '6', '7', '8', '9' > ]; > > char q = uniform!allowed_chars; > writeln (q);

Re: srand in D

2022-01-08 Thread kdevel via Digitalmars-d-learn
On Saturday, 8 January 2022 at 23:34:17 UTC, Ali Çehreli wrote: [...] Apparently, the programmer wanted uniformly distributed randomness that is reproducible. That's why they use a generator that is seeded with 42 there. It does produce random results but the first Fruit happens to be

Re: srand in D

2022-01-08 Thread Ali Çehreli via Digitalmars-d-learn
On 1/8/22 12:27 PM, kdevel wrote: On Sunday, 31 October 2021 at 17:02:00 UTC, Ali Çehreli wrote: Just comment that line out. :) D's pseudo-random generators start randomized by default: [...]   https://dlang.org/phobos/std_random.html Klicking at "Run" always delivers "mango":

Re: Module without object file?

2022-01-08 Thread kdevel via Digitalmars-d-learn
On Friday, 7 January 2022 at 09:18:29 UTC, frame wrote: On Thursday, 6 January 2022 at 22:54:59 UTC, kdevel wrote: In my setup make decides which file to (re)compile. Just found that dmd has the option -makedeps which resembles gcc's -M but theres no -MM to excluded dependencies from system

Re: srand in D

2022-01-08 Thread kdevel via Digitalmars-d-learn
On Sunday, 31 October 2021 at 17:02:00 UTC, Ali Çehreli wrote: Just comment that line out. :) D's pseudo-random generators start randomized by default: [...] https://dlang.org/phobos/std_random.html Klicking at "Run" always delivers "mango":

Re: Windows link trouble

2022-01-08 Thread mesni via Digitalmars-d-learn
On Saturday, 8 January 2022 at 13:25:25 UTC, mesni wrote: On Saturday, 8 January 2022 at 13:21:15 UTC, mesni wrote: On Friday, 7 January 2022 at 22:41:01 UTC, Adam D Ruppe wrote: On Friday, 7 January 2022 at 20:48:17 UTC, mesni wrote: Windows: when creating dll file, ClassInfo and ModuleInfo

Re: Windows link trouble

2022-01-08 Thread mesni via Digitalmars-d-learn
On Friday, 7 January 2022 at 20:48:17 UTC, mesni wrote: Windows: when creating dll file, ClassInfo and ModuleInfo are not exported? The linker swears specifically at *__Class or *__ModuleInfo symbols. But `export module` does not work

Re: Windows link trouble

2022-01-08 Thread mesni via Digitalmars-d-learn
On Saturday, 8 January 2022 at 13:21:15 UTC, mesni wrote: On Friday, 7 January 2022 at 22:41:01 UTC, Adam D Ruppe wrote: On Friday, 7 January 2022 at 20:48:17 UTC, mesni wrote: Windows: when creating dll file, ClassInfo and ModuleInfo are not exported? The linker swears specifically at

Re: Windows link trouble

2022-01-08 Thread mesni via Digitalmars-d-learn
On Friday, 7 January 2022 at 22:41:01 UTC, Adam D Ruppe wrote: On Friday, 7 January 2022 at 20:48:17 UTC, mesni wrote: Windows: when creating dll file, ClassInfo and ModuleInfo are not exported? The linker swears specifically at *__Class or *__ModuleInfo symbols. nothing is exported unless

Re: Windows link trouble

2022-01-08 Thread mesni via Digitalmars-d-learn
On Friday, 7 January 2022 at 22:41:01 UTC, Adam D Ruppe wrote: On Friday, 7 January 2022 at 20:48:17 UTC, mesni wrote: Windows: when creating dll file, ClassInfo and ModuleInfo are not exported? The linker swears specifically at *__Class or *__ModuleInfo symbols. nothing is exported unless