Nim is a statically typed compiled systems programming language. It combines successful concepts from mature languages like Python, Ada and Modula. Its design focuses on efficiency, expressiveness, and elegance (in that order of priority).
how can one use a static param of type seq? (note: I don't want to use an array as that would tie default value to be of same length as the param, which is useless for example when default value is @[])
following code fails:
Error: type mismatch: got <static[array[0..-1, empty]]([])> but expected 'static[seq[string]]'
macro foo(a: static seq[string] = @[]): untyped = discard
how can one use a static param of type seq? (note: I don't want to use an array as that would tie default value to be of same length as the param, which is useless for example when default value is
@[]
)following code fails:
this affects https://github.com/c-blake/cligen/issues/66#issuecomment-444310617