Been back at coding in Nim after some time doing a job in C#.

And the whole unfriendly documentation just frustrates me more and more...

Example: Google "nim split string".

Page Result: 
[http://nim-lang.org/docs/strutils.html](http://forum.nim-lang.org///nim-lang.org/docs/strutils.html)

First of all its a massive documentation dump page. Why load all this 
information when you are looking for a specific function.

Find the "split" in the nav bar:

Page Result: 
[http://nim-lang.org/docs/strutils.html#split,string,set[char],int](http://forum.nim-lang.org///nim-lang.org/docs/strutils.html#split,string,set\[char\],int)
    
    
     split(s: string; seps: set[char] = Whitespace; maxsplit: int = - 1): 
seq[string] {.
        noSideEffect, gcsafe, extern: "nsuSplitCharSet", raises: [], tags: [].}
    The same as the split iterator, but is a proc that returns a sequence of 
substrings.
    
    proc split(s: string; sep: char; maxsplit: int = - 1): seq[string] 
{.noSideEffect,
        gcsafe, extern: "nsuSplitChar", raises: [], tags: [].}
    The same as the split iterator, but is a proc that returns a sequence of 
substrings.
    
    proc split(s: string; sep: string; maxsplit: int = - 1): seq[string] 
{.noSideEffect,
        gcsafe, extern: "nsuSplitString", raises: [], tags: [].}
    Splits the string s into substrings using a string separator.
    
    Substrings are separated by the string sep. This is a wrapper around the 
split iterator.

This is the resulting information set.

Lets compare that with lets say PHP ...
    
    
    Description ¶
    
    array explode ( string $delimiter , string $string [, int $limit = 
PHP_INT_MAX ] )
    Returns an array of strings, each of which is a substring of string formed 
by splitting it on boundaries formed by the string delimiter.
    
    Parameters ¶
    
    delimiter
    The boundary string.
    
    string
    The input string.
    
    limit
    If limit is set and positive, the returned array will contain a maximum of 
limit elements with the last element containing the rest of string.
    
    If the limit parameter is negative, all components except the last -limit 
are returned.
    
    If the limit parameter is zero, then this is treated as 1.
    
    Note:
    Although implode() can, for historical reasons, accept its parameters in 
either order, explode() cannot. You must ensure that the delimiter argument 
comes before the string argument.
    Return Values ¶
    
    Returns an array of strings created by splitting the string parameter on 
boundaries formed by the delimiter.
    
    If delimiter is an empty string (""), explode() will return FALSE. If 
delimiter contains a value that is not contained in string and a negative limit 
is used, then an empty array will be returned, otherwise an array containing 
string will be returned.
    
    Examples: .......
    

The same stuff in Golang:
    
    
    func Split
    
    func Split(s, sep string) []string
    Split slices s into all substrings separated by sep and returns a slice of 
the substrings between those separators. If sep is empty, Split splits after 
each UTF-8 sequence. It is equivalent to SplitN with a count of -1.
    
    ▹ Example
    
    func SplitAfter
    
    func SplitAfter(s, sep string) []string
    SplitAfter slices s into all substrings after each instance of sep and 
returns a slice of those substrings. If sep is empty, SplitAfter splits after 
each UTF-8 sequence. It is equivalent to SplitAfterN with a count of -1.
    
    ▹ Example
    
    func SplitAfterN
    
    func SplitAfterN(s, sep string, n int) []string
    SplitAfterN slices s into substrings after each instance of sep and returns 
a slice of those substrings. If sep is empty, SplitAfterN splits after each 
UTF-8 sequence. The count determines the number of substrings to return:
    
    n > 0: at most n substrings; the last substring will be the unsplit 
remainder.
    n == 0: the result is nil (zero substrings)
    n < 0: all substrings
    ▹ Example
    
    func SplitN
    
    func SplitN(s, sep string, n int) []string
    SplitN slices s into substrings separated by sep and returns a slice of the 
substrings between those separators. If sep is empty, SplitN splits after each 
UTF-8 sequence. The count determines the number of substrings to return:
    
    n > 0: at most n substrings; the last substring will be the unsplit 
remainder.
    n == 0: the result is nil (zero substrings)
    n < 0: all substrings
    ▹ Example
    

Please tell me what is more readable? Newbie friendly? Examples? Everything in 
the {} needs not even be listed and only frustrates a person there eyes.

My frustration level just keeps going up after a while. More & more i run into 
simple but stupid documentation that is just not intuitive and is simply a 
source documentation dump.

Maybe plenty of other people are geniuses that instantly understand the 
language and have loads of time. But for me when i switch between projects, 
there is no "learn everything by head" going on. And it frustrates the hell out 
of me.

Too much is simply based upon single comments and figure it out yourself. Just 
venting my frustration that something so simple is so unreadable in the 
documentation. I run into them again and again ... Frankly, thinking about 
going back to GoLang just because there documentation is better and its way 
more easy to find examples ( even with some of the disadvantages ).

I said it months ago that the project is too much elitist & not newbie 
friendly. And so far not a darn thing has changed. _/Frustrated_

Reply via email to