import macros,sugar,strformat #macro to take a nested tuple and return a type #e.g. (int,(int,int))=>(string,(string,string)) proc intstr(n: NimNode): NimNode = if n.kind == nnkSym: return ident("string") result = nnkPar.newNimNode() for i in 1..