The following template works for non-release-compilation, but no special flags are needed apparently.
You can add a flag-variable wispbo (in my suffix-lingo) or customize the style. Also i dont know if the basename-split-off is cross-platform? Maybe use Path and offical approach instead.. Thanks for tips! template wisp*(wordsq: varargs[string, `$`]) = # works only for non-release-compilation; thats ok var filepathst, filenamest, modulest, procnamest: string pathsq: seq[string] let tob = getStackTraceEntries() # a proc from the system-module if tob.len > 0: # needed for release-compilation when it is empty? filepathst = $tob[tob.len - 1].filename pathsq = filepathst.split("/") filenamest = pathsq[pathsq.len - 1] modulest = filenamest[0..filenamest.len - 5] procnamest = $tob[tob.len - 1].procname echo "==> ", modulest, "_", procnamest, " echos: ", wordsq Run