sigmoid.social is one of the many independent Mastodon servers you can use to participate in the fediverse.
A social space for people researching, working with, or just interested in AI!

Server stats:

588
active users

#zig

4 posts4 participants0 posts today

Memory management in #zig is an absolute disaster. You need to pull in a specific allocator after which you need to instantiate it, then call it. The same with releasing memory, if the allocator isn't in scope.
pedropark99.github.io/zig-book
Whatever happened to simple things in programming. Allocating a block of memory is such a vital thing, it should be extremely compact and efficient to write. [1/2]

pedropark99.github.ioIntroduction to Zig - 3  Memory and Allocators
Replied in thread

@ellisgl
1) would be functional
2) would compile to machine code
3) would come with decent dependency management (see #golang or #zig)
4) would have manual memory management with tool assistance to make it safe-ish
5) would use tabs for indentation (as an 8 space guy, I do actually care because I don't want to inflict this on others)

But since my brain is merely about average, this will likely remain a pipe dream.

Sharing this quite basic Bencode library in Guile:
github.com/4zv4l/guile-bencode

I am making this in case I decide myself to write a BitTorrent cli/daemon in Guile (one that could easily be used with Guix/Shepherd).

I originally wanted to write one in Zig but since it's going under heavy change, I could do a first try with Guile.

Bencode library for GNU Guile. Contribute to 4zv4l/guile-bencode development by creating an account on GitHub.
GitHubGitHub - 4zv4l/guile-bencode: Bencode library for GNU GuileBencode library for GNU Guile. Contribute to 4zv4l/guile-bencode development by creating an account on GitHub.
#guile#zig#guix

I looked at the Zig programming language this afternoon. None of the two different "hello world" snippets on their site compiled. These are old snippets and the language has evolved since. But their website never got updated. So, yeah. First impressions matter.

@andrewrk Just letting you know that #Zig is now saving my company several hundreds of thousands, and that amount is consistently growing.

Let me know if you want to know more about how we're using it.

Thanks a lot!