Earlier quoted context omitted.
Even though it's not according to the styleguide, you can just use snake_case whenever and wherever you want, consumers of your libraries or other way around will never notice!
Then you end up with an ecosystem with mixed conventions. Not good IMO.
Nim 2.0 thoughts
61–70 of 150 posts
Re: Nim 2.0 thoughts
#62I started using Nim recently and have been very impressed. It feels like a better Rust than Rust, and a better Go than Go. Why doesn’t Nim get more attention?
How's Nim faring with regards to easy programming for multicores? (I think that's the main selling point of Go).
For multiprocessing (like Python's module of that name), you can roll your own little system in probably 100 lines of code or use something like this [1] with an example program [2]. For me, that toy program runs 1.5-2x faster than ripgrep on the same (admittedly limited) problem on Linux. { I suspect this perf diff is due to mmap IO being faster than syscall IO due to SIMD register use as discussed here [3], but this deserves deeper investigation than I have time for right now. If my hunch is right, that may constitute further argumentative support for not leaping to threads even if the programming language "makes them 'easy'", though. }
As for threads/parallelism with shared memory in Nim..Honestly, there is probably too much to recap. Weave [4] would be a good place to start reading, though, or searching the Nim Forum.
[1] https://github.com/c-blake/cligen/blob/master/cligen/procpool.nim
[2] https://github.com/c-blake/cligen/blob/master/examples/grl.nim
[3] https://news.ycombinator.com/item?id=24842648
[4] https://github.com/mratsim/weaveRe: Nim 2.0 thoughts
#63I started using Nim recently and have been very impressed. It feels like a better Rust than Rust, and a better Go than Go. Why doesn’t Nim get more attention?
How is the compiler, speed wise? One thing I really like about Go and really don't like about Rust are their relative compiler speeds. I think it makes a big different for the language and Nim has a chance to get this right as they didn't make the mistake of using LLVM and it's bad compiler UX.
Re: Nim 2.0 thoughts
#64Earlier quoted context omitted.
I love python as well, and I literally just started exploring Nim yesterday, so this is very timely. The one thing that stuck out to me like a sore thumb is the camelCase convention. I know it's a minor thing (and a personal preference), but I'm a bit biased against languages that use camelCase (Java, JavaScript, etc). There's something uneasy about it IMHO.
Nim is partially case-insensitive: https://nim-lang.github.io/Nim/manual.html#lexical-analysis-... my_foo, myfoo, and myFoo are interchangeable. MyFoo is different because the first letter is capitalized. If it's not clear, what I mean is that if you've imported a module that exports myFoo, you can refer to it in your code as my_foo, if you prefer. Some people love this aspect of Nim, others loathe it. I don't have s…
God, that's horrible.
Re: Nim 2.0 thoughts
#65Man nim is such a cool language it just need some more community and better docs to get some hype.
What's the main use case of Nim, would you say? Is it good for personal project/automation, for desktop or web apps? Etc.
Re: Nim 2.0 thoughts
#66I started using Nim recently and have been very impressed. It feels like a better Rust than Rust, and a better Go than Go. Why doesn’t Nim get more attention?
It may be better than Go but I don't see how it is comparable to Rust. Rust's biggest selling point is compilation-checked memory and thread safety guarantee without garbage collection. Nim instead uses a garbage collector, or a reference counter similar (but deterministic) to Swift which can cause memory leaks, or manual memory management.
https://nim-lang.org/blog/2020/10/15/introduction-to-arc-orc...
Re: Nim 2.0 thoughts
#67I started using Nim recently and have been very impressed. It feels like a better Rust than Rust, and a better Go than Go. Why doesn’t Nim get more attention?
It may be better than Go but I don't see how it is comparable to Rust. Rust's biggest selling point is compilation-checked memory and thread safety guarantee without garbage collection. Nim instead uses a garbage collector, or a reference counter similar (but deterministic) to Swift which can cause memory leaks, or manual memory management.
> to Swift which can cause memory leaks
The Nim compiler can detect cycles and warn you. And --gc:orc collects them successfully at runtime. Orc is going to be the default.
Re: Nim 2.0 thoughts
#68I started using Nim recently and have been very impressed. It feels like a better Rust than Rust, and a better Go than Go. Why doesn’t Nim get more attention?
Re: Nim 2.0 thoughts
#69I started using Nim recently and have been very impressed. It feels like a better Rust than Rust, and a better Go than Go. Why doesn’t Nim get more attention?
If those two things had been present I would pick Nim over Go, it’s just a nice language for some like me, who have mostly done Python.
I’m not sure if this was a bug in a third party module, but I also struggled a little with unicode support.
Re: Nim 2.0 thoughts
#70I started using Nim recently and have been very impressed. It feels like a better Rust than Rust, and a better Go than Go. Why doesn’t Nim get more attention?
Nim has a garbage-collector right? In that case I don't see how you can compare Nim and Rust. The Go comparison makes more sense.