Here's a Nim playground of (probably non-idiomatic) Nim using concepts.
https://play.nim-lang.org/#ix=3rsV
Line 45 gives a "Error: no tuple type for constructor" error which I'm struggling to understand given the previous type and function declarations in that snippet. Can anyone advise?
Ta,
Stu
Well, it boils down to :
type XConcept* = concept x
check(x) is int
proc check[T](x : T) : int = 1
proc reif*(u : XConcept): bool =
true
# This is okay.
assert reif(2.2)
# This is not.
assert reif((2.2, 3.3))