Is it possible without using custom macros, to get the type of a proc argument?
proc inc(a: int): int = a + 1
template typeArg(p): type = ???
# typeArg(inc) = int
You should just be able to use type, no?
Also, the type of the proc is the proc signature (proc (a: int): int{.noSideEffect, gcsafe, locks: 0.}). Did you want the return type? If so, you'll need a macro.
import typetraits
proc incr(a: int): int = a + 1 # need to rename to incr so that it doesn't conflict with built in `inc`
echo type(incr)
# prints `proc (a: int): int{.noSideEffect, gcsafe, locks: 0.}`