Open RedBeard0531 opened 6 years ago
type Node[T] = object val: T proc genericProc(s: Node; key: s.T) = discard # body doesn't matter proc explicitGenericProc[T](s: Node[T]; key: T) = discard # body doesn't matter proc concreteProc(s: Node[cstring]; key: s.T) = discard # body doesn't matter var strs: Node[cstring] concreteProc(strs, "string") # string converts to cstring explicitGenericProc(strs, "string") # still converts genericProc(strs, "string") # doesn't convert: COMPILE ERROR
Works in 2.2, likely same fix as #7006