Live data from Hacker News

Nim Programming Language 0.14.0 released

nim-lang.org

21–30 of 58 posts

Re: Nim Programming Language 0.14.0 released

#21
post #3

I still don't understand how can you (efficiently) debug something like this that compiles to another language?

So many circular answers. Maybe someone could give some pointers to @Keyframe1 about best practices in nim, I'm sure he knew gdb worked with nim.

Re: Nim Programming Language 0.14.0 released

#22

There are several languages similar to Nim these days, and they're all very exciting. For example, Nim, Rust, D, Go, and probably others I'm forgetting. Does anyone know of some chart that compares them based on their features and priorities? Maybe something in the spirit of https://mobile.twitter.com/nixcraft/status/73938379662612889... but with more areas of comparison and less trying to be funny?

I've been leaning on Go lately because it has a large module community already. Nim, D, Rust are all on my radar to use once library maturity happens. For example, I need solid AWS, Azure, GEngine SDK support.

Re: Nim Programming Language 0.14.0 released

#24

There are several languages similar to Nim these days, and they're all very exciting. For example, Nim, Rust, D, Go, and probably others I'm forgetting. Does anyone know of some chart that compares them based on their features and priorities? Maybe something in the spirit of https://mobile.twitter.com/nixcraft/status/73938379662612889... but with more areas of comparison and less trying to be funny?

I'll try to give it a go for Rust, Nim, and Go. Rust: Wants to replace C++ as an expressive systems programming language. Syntax derived from C++. Emphasis on const correctness. Makes use of some functional programming concepts. Extensive metaprogramming. No garbage collection by default. Interface based polymorphism. The type system tracks memory ownership helping to prevent some classes of error at the cost of more…

On that spectrum, I'd put D between your definition of Rust and Nim. Currently it does use a GC by default, but you can easily work above it when needed. Soon(tm) you will be able to specify what kind of GC to use (eg. provide your own) and the stdlib will adapt to it.

Re: Nim Programming Language 0.14.0 released

#25
post #23
post #15

https://github.com/nim-lang/Nim/issues/936 still open :-(

It's marked High Priority so hopefully won't be much longer before it's fixed.

Last post in that discussion is from Februari 2015 so it looks like progress has stalled.

Re: Nim Programming Language 0.14.0 released

#26
post #3

I still don't understand how can you (efficiently) debug something like this that compiles to another language?

So many circular answers. Maybe someone could give some pointers to @Keyframe1 about best practices in nim, I'm sure he knew gdb worked with nim.

I agree. I don't get it. It seems no one has actually tried it. What I'm asking is what's the idiomatic approach to debugging this. If I code in Nim and produce C code and then compile and link that... I'm debugging produced C code, which is below Nim in the chain. I have to somehow then see what's up with exact Nim code that produced said C code which got compiled and linked. It's two steps remove with a magic, unexplained, step between Nim and C which I'm asking about how to debug.

Re: Nim Programming Language 0.14.0 released

#27

There are several languages similar to Nim these days, and they're all very exciting. For example, Nim, Rust, D, Go, and probably others I'm forgetting. Does anyone know of some chart that compares them based on their features and priorities? Maybe something in the spirit of https://mobile.twitter.com/nixcraft/status/73938379662612889... but with more areas of comparison and less trying to be funny?

You've got a couple of really good answers, but there's another really important dimension: popularity. Choosing a popular language allows you to work with others, to hire people, to pass your project on, to allow your github repos to get popular, et cetera.

For that reason, I don't believe that Nim & D offer enough advantages and differences over Rust & Go that it outweighs their lack of popularity and hipness.

Of course others will say the same thing about Rust & Go: C, C++ and Java are much more popular and do currently fill basically the same niches as Rust & Go. You have to draw the line somewhere. It just happens that my line is drawn above Nim & D, but below Rust & Go.

Nim & D look like really awesome languages, though. They're just one killer project away from being popular, the way that Rails made Ruby popular. I would not be particularly upset if the situation reversed, if Nim & D got popular while Rust & Go got unpopular.

Re: Nim Programming Language 0.14.0 released

#28

Earlier quoted context omitted.

So many circular answers. Maybe someone could give some pointers to @Keyframe1 about best practices in nim, I'm sure he knew gdb worked with nim.

I agree. I don't get it. It seems no one has actually tried it. What I'm asking is what's the idiomatic approach to debugging this. If I code in Nim and produce C code and then compile and link that... I'm debugging produced C code, which is below Nim in the chain. I have to somehow then see what's up with exact Nim code that produced said C code which got compiled and linked. It's two steps remove with a magic, unex…

Javascript targetting languages have source maps to link back errors at the lower level back to the pre-compiled source. Clojure dealt with the dual nature of errors (clojure exception from java exception) by partitioning messages in sub-groups to facilitates reading.

Re: Nim Programming Language 0.14.0 released

#29
post #4
post #3

I still don't understand how can you (efficiently) debug something like this that compiles to another language?

Pretty much the same way you can any other language. GDB/LLDB works fairly well with Nim, but personally I just use a couple `echo` statements when I need to debug anything.

`printf` debugging is still often the easiest way to go.

Re: Nim Programming Language 0.14.0 released

#30

There are several languages similar to Nim these days, and they're all very exciting. For example, Nim, Rust, D, Go, and probably others I'm forgetting. Does anyone know of some chart that compares them based on their features and priorities? Maybe something in the spirit of https://mobile.twitter.com/nixcraft/status/73938379662612889... but with more areas of comparison and less trying to be funny?

I'll try to give it a go for Rust, Nim, and Go. Rust: Wants to replace C++ as an expressive systems programming language. Syntax derived from C++. Emphasis on const correctness. Makes use of some functional programming concepts. Extensive metaprogramming. No garbage collection by default. Interface based polymorphism. The type system tracks memory ownership helping to prevent some classes of error at the cost of more…

Nim feels higher level to me than Go; can you educate me on how you drew the opposite conclusion? Maybe I'm looking at something wrong.
Post reply on HN