Hi,
I need to spawn threads that return a string. When I use the deprecated threadpool library, I end up having some sort of arbitrary memory leak when reusing flowvar objects for sequential spawn->sync operations and changing to taskpools does not seem to work at all:
import taskpools
var pool = Taskpool.new(num_threads = 4)
var flow = pool.spawn dostuff()
stack trace: (most recent call last)
Is there a simple way to spawn procs that strings?
Have you tried malebolgia?
https://www.youtube.com/watch?v=MIITSTQok-4
using the => operator?
I get the same problem with taskpools on nim-2.2.4. If my spawned proc returns a number it works, but trying to return a string draws the same error: "Channel is not garbage-collection-safe".
Any ideas on how to fix this?