Live data from Hacker News

Nim Programming Language 0.14.0 released

nim-lang.org

1–10 of 58 posts

Re: Nim Programming Language 0.14.0 released

#2
Very excited for v1.0 -- the solidification of "Concepts" will be quite exciting. The bug fixes and new features in v0.14 are super welcome, definitely looking forward to leveraging the generic type classes fixes: My Either[T] implementation should now work! Exciting stuff.

We've got two internal tools that are written entirely in Nim, and it's been brilliant pretty much all the way through. The rough edges of previous versions are steadily sanded away, and our code becomes more expressive with each version. The biggest thing I'm looking forward to (once v1.0 rolls round) is having the "not nil" specifier be the default for all types. That's going to bring it in line with the other static typing checker we use regularly (Flow) which will be a boon to those of us (mainly me) that live in both worlds most days heh.

Re: Nim Programming Language 0.14.0 released

#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.

Re: Nim Programming Language 0.14.0 released

#5
post #3

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

GDB and Valgrind work quite well, see for example:

- https://hookrace.net/blog/what-makes-nim-practical/#debuggin...

- https://hookrace.net/blog/writing-an-async-logger-in-nim/#op...

Edit: You can of course also change the program itself, using echo and writeStackTrace to figure out what's going on.

Re: Nim Programming Language 0.14.0 released

#6
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.

Yup, the source code still appears in GDB and with a bit of tab completion, inspecting variables ain't that hard, either. I've had worse experiences with C code that abused the preprocessor.

Re: Nim Programming Language 0.14.0 released

#7
post #3

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

How do you debug ANY compiled language? Every compiler compiles to another language. ;)

https://en.wikipedia.org/wiki/Compiler "A compiler is a computer program (or a set of programs) that transforms source code written in a programming language (the source language) into another computer language (the target language), with the latter often having a binary form known as object code."

Re: Nim Programming Language 0.14.0 released

#10
post #2

Very excited for v1.0 -- the solidification of "Concepts" will be quite exciting. The bug fixes and new features in v0.14 are super welcome, definitely looking forward to leveraging the generic type classes fixes: My Either[T] implementation should now work! Exciting stuff. We've got two internal tools that are written entirely in Nim, and it's been brilliant pretty much all the way through. The rough edges of previo…

It's interesting that the non-null-able stuff is getting into languages just right now.

When using stuff like JS, the possible nulls are a bigger problem than a wrong type in general (still a problem, but IMO not as significant) still systems like TypeScript started without it.

Post reply on HN