Skip to content
HomeVideosBooksBlogs
AllTop postsTopics
Podcasts
HistoryListsWatch laterLiked videosFollowing

The videos, books, blogs and podcasts Hacker News keeps recommending, all in one place.

VideosBooksBlogsPodcastsAboutPrivacySettings

Data from Hacker News, HackerTube, HackerBooks, HackerBlogs and Open Library. Credits · Not affiliated with Y Combinator.

HomeVideosBooksBlogsPodcasts
Ctrl K
    H

    HookRace

    hookrace.net · Personal blog · on HN since 2015

    HookRace is a blog by a Nim developer on Nim's features, metaprogramming, game development, and shrinking binary size.

    Visit blogRSSHN submissions
    Languages & CompilersProgrammingGames
    What HN says

    Commenters recommend it to Nim fans, and one praises Nim's syntax, type system, macros, and performance.

    Stats for nerds
    46HN people shared it
    49linked in comments
    4Kstory points
    Mar 2025last shared
    2015people per year2025

    Top posts on HN

    1. 1
      Time.gif
      3 people · 782 points · first shared 2017 · 104 comments on HN
    2. 2
      Linux Desktop Setup
      1 person · 443 points · first shared 2019 · 226 comments on HN
    3. 3
      macOS Setup after 15 Years of Linux
      1 person · 349 points · first shared 2021 · 395 comments on HN
    4. 4
      One year of cycling to work
      2 people · 295 points · first shared 2018 · 395 comments on HN
    5. 5
      Turning Down a Blockchain Job Offer
      1 person · 285 points · first shared 2018 · 225 comments on HN
    6. 6
      What is special about Nim?
      9 people · 269 points · first shared 2015 · 84 comments on HN
    7. 7
      Overview of Running an Online Game for 3 Years
      2 people · 198 points · first shared 2016 · 35 comments on HN
    8. 8
      DoS attacks against my online game
      1 person · 171 points · first shared 2021 · 95 comments on HN
    9. 9
      A Taste of Haskell
      1 person · 162 points · first shared 2016 · 116 comments on HN
    10. 10
      Porting a NES Emulator from Go to Nim
      2 people · 158 points · first shared 2015 · 81 comments on HN

    What HN people wrote when they linked it

    • mratsimSep 2019

      I'm from Status, Nim's main sponsor and a blockchain company that is doing Ethereum 2.0 research and implementation in Nim.

      Nim had the following appeal for us:

      - Ethereum research is done in Python, we actually started our code with a tool called py2nim to convert a 50k lines Python codebase to Nim in less than a month (and remove cruft for 3 months but that's another story).

      - Nim allows us to use a single language for research and production: the Python syntax, and the fast compilation speed are very helpful. In particular researchers found the Nim codebase easy to debug as the overhead vs the Python spec was quite low (and the Python spec is using types with mypy)

      - Nim has a easy C FFI and is one of the rare languages that can directly use C++ libraries, including header-only template heavy libraries.

      - Nim allows tight control over memory allocation, stack vs heap objects, has support for Android and iOS and very low-memory devices as well.

      - Nim also can be very high-level

      - Nim is as fast as C and can resort to inline C, inline C++ or inline assembly when needed. (inline javascript or Objective C are possible as well)

      - You can produce WASM code via clang, emscripten, binaryen, there is even a Nes emulator demo from 2015 running in Nim compiled to WASM here: https://hookrace.net/nimes/

      - Nim has a strong type-system, including generics and type-level integers, boolean and enums.

      - Nim has probably the best compile-time capabilities of all languages. I'm…

    • dlrkJun 2016

      For example, You can drop into c types using e.g. cstring and cint. Turn off or direct the gc. Manage memory for individual vars using the {.untracked.} pragma, c_malloc and c_free; easy integration of c libraries for obvious reasons; get pointers to things if you need them with ptr.

      Have a look at some of these in the manual. Gc stuff is in the standard library somewhere.

      This is an example I used recently:
      http://forum.nim-lang.org/t/567

      Don't think it counts as low level but templates and macros are also pretty powerful if you need them. http://hookrace.net/blog/introduction-to-metaprogramming-in-nim/

      I was drawn to it because it is high level, expressive and safe, but you can turn all this off when you need to and keep those bits contained. I'm using it with opencl.

      Can't really comment on rust and have limited exposure to go.

    • rchDec 2016

      A non-trivial number of people seem to want this, but why does it need to be called Python? Keep the syntax and C extension compatibility, but ditch the name. One could even work out a means of selectively bringing in ideas from elsewhere:

      - Concurrency from Erlang (http://queue.acm.org/detail.cfm?id=1454463)

      - String handling from Go (https://blog.golang.org/strings)

      - Lightweight data classes (https://kotlinlang.org/docs/reference/data-classes.html)

      - Syntactic macros from Nim (https://hookrace.net/blog/introduction-to-metaprogramming-in-nim/)

      - more from Lua, Julia, Scala, and Haskell (within reason)

      There are already plenty of examples of Python modules that implement significant modifications (e.g. Cython, Rpy2, Dask), so I don't think it would really feel all that different from typical Python programming.

    • beagle3Jan 2017

      Nim.

      Main: http://nim-lang.org

      NES emulator (compiled to JavaScript, runs in the browser): https://hookrace.net/nimes/

      Simple 2D game: https://hookrace.net/blog/writing-a-2d-platform-game-in-nim-with-sdl2/

      More examples: https://nim-by-example.github.io/

      Nim has pythonesque syntax, with Pascal/Delphi roots, fast compile times, portability (compiles down to C, JavaScript, LLVM), strong metaprogramming support, seamless FFI, optional GC, and a lot more.

      It doesn't have Rust's ultimate safety, although it has quite a bit -- e.g., it can track which thread accesses what for concurrency (in a limited but extremely useful way).

      I'm a fan; It looks like the fun of Python but the speed of C/C++. I haven't had a chance to start a project in Nim - hopefully, in 2017.

    • johncolanduoniOct 2015

      > Optimisers are like garbage collectors—they give you better ergonomics than, and equal average performance to the manual alternative, if you’re willing to relinquish predictability and a non-voodoo mental model of your code’s performance.

      This is why I'd like to see optimizers become less opaque. It would be great if we could not only suggest optimizations to the compiler (and more sophisticated ones that just inlining), but actually see the process which our code went through.

      One language that has some interesting things going on in this area is Nim, which lets you write your own domain-specific optimizations[1].

      [1]: http://hookrace.net/blog/what-is-special-about-nim/#add-your-own-optimizations-to-the-compiler

    • atemerevSep 2019

      Nim is a thing of beauty. It has a well-thought syntax (some consider it to be similar to Python, but it removes many Python idiosyncrasies), state of the art type system with generics, beyond state of the art macro system, excellent performance (comparable to Rust or C), and it can work as a low-level or a high-level language. It is pragmatic: you can write functional or imperative code, neither is imposed on you. There are so many beautiful hacks I enjoy (e.g. unit tests are supposed to be included in each file, all files are compiled as executables, and you can run them to run the tests).

      Here is a taste of what's possible: https://hookrace.net/blog/what-is-special-about-nim/

    Related

    Nim Blognim-lang.org404 people

    Nim 1.0

    Nim Blog
    Company · last shared 2026
    Peter Mepeterme.net15 people

    Is Nim a Transpiler?

    Peter Me
    Personal · last shared 2026
    GNOME Blogsblogs.gnome.org490 people

    AirPods fast connect security vulnerability

    GNOME Blogs
    Company · last shared 2026
    Joe Damatotimetobleed.com39 people

    American Express fails miserably at basic security

    Joe Damato
    Personal · last shared 2022
    Bluish Coderbluishcoder.co.nz77 people

    Using Freenet

    Bluish Coder
    Personal · last shared 2025
    Smash Companysmashcompany.com44 people

    One-on-one meetings are underrated, whereas group meetings waste time

    Smash Company
    Personal · last shared 2024
    fasterthanli.mefasterthanli.me236 people

    A half-hour to learn Rust

    fasterthanli.me
    Personal · last shared 2026
    NVIDIA Technical Blogdevblogs.nvidia.com177 people

    Volta: Advanced Data Center GPU

    NVIDIA Technical Blog
    Company · last shared 2025