Hide
Scraps
RSS
Showing all entries tagged with: Guide

Asynchronous programming in Nim

3rd September 2021

In the previous article we got a small primer on various kinds of multi-tasking, in this article we'll have a look at possibly the simplest form of this. Namely asynchronous execution. As discussed in the last article asynchronous execution is a way for our programs to tell the hardware to do something, and then do something else while waiting for it to complete the operation. This is great when we want to for example…


Multitasking in Nim

3rd September 2021

This is a series of articles about a topic in the Nim ecosystem that has so far been written fairly little about. Namely threading, asynchronous operation, and communication.

To begin we first need to have a good grasp of the concepts we're going to discuss. There is quite a bit of confusion around all the terms in this space, so let's start with some simple definitions. To put them in context let's first consider how a…


Fixing a broken Firefox session

27th April 2021

In order to stifle my tab-hoarding habits I have recently set my Firefox install to not recover sessions when I restart the browser. This means that every time I turn my computer off for the day it will delete all the random documenation pages and weird links people have sent me over the course of the day so they don't slowly add up. My habit was so bad that I could easily amass some 100-200…


Creating condensed shared libraries (Embedding NimScript pt. 3)

23rd June 2020

In the first part of this article series we looked at why we would potentially want to be able to run NimScript embedded into our Nim programs. In part two we dove a bit deeper and looked at how we could do this embedding, and how we could pass data from the scripts to our native code. In this final article (for now) we’ll look at how we can distribute a program that embeds NimScript,…


How to embed NimScript into a Nim program (Embedding NimScript pt. 2)

31st May 2020

In the first part of this three part article series we looked at why we would want to embed NimScript into our Nim applications. Particularly why we would want to use it for configuration. Whether or not that is your goal, this article will explain how this can be achieved. When I started looking into this I started in the obvious place, Nimble. For those of you not very well versed in the Nim ecosystem,…