I'm messing around with templates and can't get passed this template/generic instantiation of 'test' from here. What is wrong with this code? let val = 10 template test(val: typed) = case val: of low(int)..<5: echo "under 5" else: echo "5 or above" test(val) Run
I'm trying to get to something like this: template test(stuff: untyped): untyped = stuff let val = 10 test: case val: of low(int)..<5: echo "under 5" else: echo "5 or above" Run I'm not sure what this error means and why this code won't work. Any help is appreciated