flyx wrote:

> And yes, something between array and seq would be nice. But currently, Nim's 
> type system does not allow a type with a runtime-calculated length parameter. 
> Allowing it would be a hack similar to C VLAs.

No hack involved here. The length parameter can be part of the object like seq 
rather than part of the type like array. openarray-accepting procs should not 
care since they can receive seqs anyway with run-time variable everything or 
arrays with compile-time fixed everything.

One might argue that I/others could just do their own concept which is true. 
The standard lib has lots of openarray-accepting routines that would work fine 
with post-init-fixed seq-like objects, though. So, not having such a type in 
the standard lib that's part of openarray feels unnecessarily inflexible, but 
on this I think we agree since you said it would be nice. It may just be easier 
than first imagined. :)

Reply via email to