> @didlybom The names follow 
> [https://nim-lang.org/docs/apis.html](https://nim-lang.org/docs/apis.html) (a 
> document that is not well known). initT is used for value-based types, newT 
> for pointer-based types. newSeq and newString depart from it because they 
> were created early on.

Thanks for the explanation @araq. The problem is that seqs and strings are 
likely to be the very first kind of thing that a new user is going to create. 
The fact that those two deviate from the general rule makes the rule hard to 
understand, IMHO. What good is a rule that is not applicable to the most common 
use case?

Wouldn't it make sense to define "initSeq" and "initString" procedures? It 
those were then used in the tutorials and the documentation it would help new 
users learn the rule you mentioned. Ideally the existing newSeq and newString 
could be marked as deprecated as well, but I do not know if that would be 
feasible given that it would basically make almost 
_[all](https://forum.nim-lang.org/postActivity.xml#all) existing nim code 
deprecated. 

Reply via email to