Did this:
nim c --cpu:i386 --os:linux --compileOnly --genScript hello_world.nim
Run
Got "operation successful". But the only file I got is "hello_world.deps".
There are no compile scripts or C-files produced.
The publisher has to maintain the list of subscribers.
It's easy to implement if all the subscribers are of the same type (or of the
multiple pre-defined types).
But is it possible to do not specify all possible types of subscribers?
Unfortunately this won't work - GDB doesn't work on Mac since 10.14 Mojave
Is there a way to get human readable strings and booleans in VSCode debugging?
Debugging successfully stops at breakpoints. Ints, floats, arrays are human
readable in the debug panel.
But string values look like 0x00010012c048 and booleans look like 'x01'.
I use mac, native debug and lldb
I can do this but it's not convenient to have all the subscribers be of the
same class
Thank you! Works great:
import tables
type EventEmitter = ref object
eventsMap: Table[string, seq[proc(event: string)]]
proc subscribe(emitter: EventEmitter, event: string, callback: proc(event:
string)) =
if not emitter.eventsMap.hasKey(event):