Re:Nim Programming Language v0.15.0 released
by qwertyuiop924 on Saturday October 01, 2016 @07:05AM
(#12617367)
It's not so much that it allows it to be ignored, it's that if you want it to be ignored, you have to use that keyword. It means that there's syntactic noise in cases where you don't care about the return value of a function that has one, and thus discourages you from writing functions like that.
[ Parent
| on HN ]
Re:Nim Programming Language v0.15.0 released
by dom96 on Saturday October 01, 2016 @07:33AM
(#12617434)
The idea behind this feature is to ensure that you don't lose important data, not to discourage you from writing functions which return values. For cases where a functions return value is truly optional, you can use the {.discardable.} pragma.
Re:Nim Programming Language v0.15.0 released
by qwertyuiop924 on Saturday October 01, 2016 @08:02AM
(#12617511)
Huh. Interesting idea. I suppose that could work. I'm still not wholly convinced that Nim is for me, but you've definitely alleviated some of my biggest concerns.