TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Nim (formerly Nimrod) 0.10.2 released

199 点作者 def-超过 10 年前

14 条评论

themartorana超过 10 年前
All the hype on HN seems to be towards Rust and Go (with Go having its share of haters), but Nim sounds particularly interesting as a side-step from Python that runs faster than both Go and Rust.<p>Can anyone give me some insight as to why it&#x27;s not as hyped, if at all? I&#x27;m rather unfamiliar with Nim, and it&#x27;s seems to have a smaller community, but it feels like it should be getting all sorts of love considering its speed of execution.<p>Thanks in advance for the help!
评论 #8809746 未加载
评论 #8810049 未加载
评论 #8809658 未加载
评论 #8809541 未加载
评论 #8809553 未加载
评论 #8810558 未加载
评论 #8809549 未加载
评论 #8809718 未加载
评论 #8809527 未加载
评论 #8810325 未加载
def-超过 10 年前
The release is happening today, so I posted a bit early. Some parts, like the binaries, are not online yet.<p>There are tutorials for newcomers: <a href="http://nim-lang.org/tut1.html" rel="nofollow">http:&#x2F;&#x2F;nim-lang.org&#x2F;tut1.html</a> <a href="https://nim-by-example.github.io/" rel="nofollow">https:&#x2F;&#x2F;nim-by-example.github.io&#x2F;</a><p>Edit: Fixed tutorial link
评论 #8809449 未加载
评论 #8809396 未加载
logicchains超过 10 年前
Something I find quite interesting about Nim is write tracking: <a href="http://nim-lang.org/blog/writetracking.html" rel="nofollow">http:&#x2F;&#x2F;nim-lang.org&#x2F;blog&#x2F;writetracking.html</a>. It uses the language&#x27;s effect system, and allows not only specifying for instance that a function is referentially transparent, but also specifying how an impure function accesses or modifies global state.<p>An example from the above link:<p><pre><code> var gId = 0 proc genId(): natural {.writes: [gId].} = gId += 1 return gId </code></pre> To quote the article: &quot;Here the effect systems shows its strength: Imagine there was a genId2 that writes to some other global variable; then genId and genId2 can be executed in parallel even though they are not free of side effects!&quot;<p>The effect system can also be used for exception tracking, specifying what kind of exceptions are function may throw. It can moreover be extended to work with user-defined effects.
评论 #8809585 未加载
评论 #8809596 未加载
audunw超过 10 年前
Nim is very exciting to me. For a long time I&#x27;ve wanted to develop a viable HDL as an internal DSL in a modern imperative compiled language. Until I found Nim I couldn&#x27;t find anything beyond C++ that would work (Julia might actually, I haven&#x27;t tried yet), but Nim is just absolutely perfect. The custom operators, static params (a weak form of dependent typing), and the macros in particular makes Nim a perfect match. It also helps that the compiler is itself written in Nim and pretty easy to work with. It&#x27;s exciting when a language allows you to solve a whole new problem that was just not feasible before.
fithisux超过 10 年前
Hopefully one day the freepascal backend gets updated. There is a lot of Pascal&#x2F;Delphi code out there that can benefit (rewritten and call legacy pascal) from Nim&#x27;s improvements.
评论 #8810246 未加载
JasonFruit超过 10 年前
So far, Nim has passed the most basic test for me: it installs according to instructions and compiles its own example code. I&#x27;m always baffled by the number of language releases that don&#x27;t reliably do that.<p>Nim looks like a worthwhile language, and I&#x27;m looking forward to learning it.
评论 #8810005 未加载
ldlework超过 10 年前
As a long time Python programmer who has struggled to cross the gap from dynamic scripting languages to modern statically typed languages Nim is by far the most frictionless language I have tried. Before I found Nim I longed for a language like C# where the generics &quot;just work&quot; and overall the language just feels like it designed at-once rather than piecemeal overtime. Everything just seem really &quot;nice&quot; in C# and I am able to transfer my Python experience over to it. But being locked up to .NET&#x2F;Mono I never really used it outside of Unity3D.<p>I tried Golang, because it was sold to me as something I would love since I am a long time Python developer. I strongly dislike Golang. It doesn&#x27;t have much in the way of letting me model my programs like I am used to. I am told &quot;that&#x27;s wrong, do it the Go way&quot;. This is too much friction. Once I am done thinking how to solve my problem algorithmically, I do not want to then figure out how to rethink my algorithm just for the sake of the maintainer&#x27;s of Golang.<p>I tried Rust. I think Rust is beautiful (mostly). However, Rust has a far too fundamentalist view on memory safety. And that&#x27;s not to downplay the importance of memory safety. But there&#x27;s just too much friction. I want to sit down an implement my algorithm. I don&#x27;t want to stop and spend just as much time thinking about the particulars that Rust demands.<p>When I found Nim I almost couldn&#x27;t believe it. The core language was simple, clean and immediately absorbable. I was able to start writing basic Nim programs after just perusing the language docs for a few minutes while the compiler compiled. I read that Nim had powerful meta-programming facilities and this started to turn me off. I had heard that macros were generally a negative force in the world but only knew them from Lisp. Then I learned that Nim&#x27;s macros are just functions that take and AST tree, perform modifications to that AST and return an AST tree. Wow that&#x27;s pretty simple. Oh hey the generics &quot;just work&quot; like in C#. Woah, Nim even supports inheritance!<p>Nim is definitely the next language for me. In thinking about it, I find that I agree with one of Jonathon Blow&#x27;s sentiments that we have been seeing a number of new up and coming languages but they are all Big Idea languages. Big Idea languages who&#x27;s ideas have yet to be vetted and proved out over the course of a decade or two. They all incur too much <i>friction</i>.<p>Nim seems like a competent, low-level systems language with a helpful repertoire of well-implemented modern tunings to features that are all mostly established in the field. It doesn&#x27;t try to revolutionize systems languages. It tries to bring us a modern refinement by bringing us a highly performant yet relentlessly productive take on what has already been shown to work.<p>Please don&#x27;t be offended if you see me around evangelizing its existence.
评论 #8811490 未加载
评论 #8823767 未加载
Koziolek超过 10 年前
LOL... net-filters in my job mark this site as porn...
评论 #8809425 未加载
emmanueloga_超过 10 年前
Is the JavaScript back-end receiving any updates? Last time I looked at it it <i>looked like</i> it was lagging behind (emphasis in &quot;looked like&quot;, I did not spend too much time with it).
copx超过 10 年前
&gt;The unpopular &quot;T&quot; and &quot;P&quot; prefixes on types have been deprecated<p>I really like that change. Those always looked so archaic to me.
bsaul超过 10 年前
Anyone knows what kind of project would nim be a good choice for at the moment ? I mean both the language feature as well as available libs. I think i&#x27;ve read somewhere that web server coding isn&#x27;t a target yet (at least regarding websockets use, which was my primary concern at the time i looked).
评论 #8810171 未加载
评论 #8809878 未加载
waterlesscloud超过 10 年前
Why did they change the name?
评论 #8809546 未加载
评论 #8809537 未加载
评论 #8809613 未加载
评论 #8811299 未加载
infinite8s超过 10 年前
Can someone give a succinct description of the difference between Nim and Rust?
评论 #8810121 未加载
ebbv超过 10 年前
Maybe it&#x27;s just me but I find this language pretty ugly. And regardless of any technical advantages it may offer, that&#x27;s enough reason to not use it. There&#x27;s too many languages out there to come out with a new one where the code isn&#x27;t clean and nice.
评论 #8809739 未加载
评论 #8809681 未加载