Better HN
topnewbestaskshowjobs
Log inSign up

program

998 karma · joined Oct 22, 2010 (16y ago) · 236 submissions

Submissions

1.

How well do you know JavaScript's Date class?(jsdate.wtf ↗)

2 points · by program · 6d ago · discuss

2.

Mojibake library v0.8, added Rust and Elixir support(zaerl.com ↗)

2 points · by program · 6d ago · discuss

comment 1w ago · link · parent

> Errors you cannot ignore

It's okay for me to declare a macro with `__attribute__((warn_unused_result))` for GCC and Clang, and `[[nodiscard]]` when the C code is later compiled with C++ (or nothing).

comment 2w ago · link · parent

I was laid off a couple of weeks ago, so I have some time for myself and my projects.

I'm porting my Unicode library to Rust https://crates.io/crates/mojibake-rs.

I'm also writing a puzzle game with a door that has one million locks. It's real-time multiplayer; some locks have opening combos, and others can be opened only by > 2 players. I'm writing it to practice with PostgreSQL. I only have an HTML prototype to test it. https://6251.s3.eu-west-1.amazonaws.com/hn-door-screenshot.p.... If you are interested, I can publish the code.

comment 3w ago · link · parent

Location: Italy

Remote: Yes

Willing to relocate: No

Technologies: TypeScript, Python, PHP, C, C++, React.js, PostgreSQL, Redis, Node.js, Docker, AI/LLMs

Résumé/CV: https://zaerl.com/cv/

Email: hn@zaerl.com

I'm a full-stack engineer with nearly 20 years of experience. Outside of work, I write C and C++. I maintain Mojibake, a Unicode library in C99, and Attractor, a unit testing framework in C11. These projects keep me focused on correctness, performance, low-level programming, and turning complex problems into easy-to-use code.

Full-time / contract / EOR. Open to equity. I've been an international contractor in recent years. Available now.

6.

Parsing Unicode graphemes is not easy(zaerl.com ↗)

1 points · by program · 4w ago · discuss

comment 2mo ago · link · parent

I saw an interesting article posted here on HN about Go's Swiss Tables implementation. I'm writing a small C library to use them for fun, so you can use any byte array as a key. Either a C string, a number, a bool, etc.

comment 3mo ago · link · parent

I really like this. I think the possibilities are multiple. I will try it to test the generic POSIX compliance of my main hobby project.

What is the main plus you have over other similar projects or tools like JSLinux?

Which preprocessor directives can I expect to have if I need to write custom code when my executable is compiled for Kandelo?

What is the reason for choosing GPL instead of MIT or similar?

comment 3mo ago · link · parent

I don’t use Windows, but I like it. What are the characteristics that distinguish this from the other popular solutions that already exist?

comment 3mo ago · link · parent

I tried my personal blog that has this kind of sitemap https://zaerl.com/sitemap.xml, like all other blogs found on wordpress.com. Do this tool support sitemapindex nodes?

comment 3mo ago · link · parent

> A producer making thousands of wheels annually is therefore sitting on an enormous and steadily growing asset that generates no cash whatsoever, while facing continuous bills.

Once a company enters a steady flow, usually after the first 2-3 years, this is not a problem because it has the income of previous years. The only thing that changes is the difference in the company's turnover.

This type of loan is not new, it has existed for more than 70 years. There’s something similar for wine, prosciutto, oil and other types of cheese.

comment 4mo ago · link · parent

Feel free to do it. You can find the amalgamation appended to GitHub releases.

comment 4mo ago · link · parent

Keep in mind that I appreciated your comment. My library has a very narrow target

There is an MJB_FEATURE_CHARACTER_NAMES option you can set to zero if you don't want to have a function that returns the name of a codepoint, such as "LATIN SMALL LETTER E WITH ACUTE". This is something that probably most people do not need at all. This shrinks "Hello World" macOS ARM executable from 937KB to 663KB.

I should probably offer other runtime options so users can literally strip away everything they don't need. For example, as you suggested, measuring whether a string is less than 80 columns is something you don't do every day.

comment 4mo ago · link · parent

(Author here) Dealing with encodings is already a big step when you aim to handle multiple ones and multiple OSes. You can see what I am talking about in the tests/ folder.

With Mojibake, I wanted to help people handle text by providing the smallest possible C/C++ library, without requiring them to use a +20MB library just to normalize a string, handle a flag emoji, or perform similar tasks.

See the CONFORMANCE_REQUIREMENTS.md file if you are interested in what the +17 versions of the Unicode standard have introduced.

comment 4mo ago · link · parent

Mojibake is a C library, not Python, so comparing the two isn't ideal. You can see the performance in the GitHub workflows results. At the end of the logs, there is an "execution time" line.

comment 4mo ago · link · parent

Mojibake is a Japanese term, and yes, it's used there when a page displays a lot of gibberish text. I chose it for fun.

comment 4mo ago · link · parent

Thank you very much. I've also started writing a smaller C++ wrapper so the user can use std::string_view for this, but I'm not the best C++ guy out there.

comment 4mo ago · link · parent

Mojibake handle UTF-8, UTF-16, UTF-16LE, UTF-16BE, UTF-32, UTF-32LE, UTF-32BE in input and output. Can be used as a simple file and handle a wider number of algorithms, such as the "confusable" one.

comment 4mo ago · link · parent

Yes, I'm the author. I began writing this library because I needed something to handle Unicode for another project of mine (that I didn't finish), and I didn't like ICU4C or the other libraries I found.

It's a hobby project I wrote because I find the Unicode standard (sometimes unnecessary) complexity fascinating. And for other people to use, if needed.

The HTML page is static and generated at compile time. Every function has a little form to test the WASM function.

20.

Show HN: Mojibake – A low-level Unicode library written in C(mojibake.zaerl.com ↗)

78 points · by program · 4mo ago · 22 comments

comment 10mo ago · link · parent

I am working on Mojibake, a small C library to handle Unicode data. I don't like the other libraries, so I’m building one myself. https://github.com/zaerl/mojibake

22.

WordPress Playground: 2025 Year in Review(make.wordpress.org ↗)

4 points · by program · 11mo ago · discuss

23.

The Mysterious Realm of JavaScriptCore (2021)(cyberark.com ↗)

35 points · by program · 11mo ago · 6 comments

24.

Maintaining the Fastest CDN at Netflix on FreeBSD(freebsdfoundation.org ↗)

13 points · by program · 1y ago · discuss

25.

Why should I care what color the bikeshed is? (1999)(bikeshed.com ↗)

95 points · by program · 1y ago · 82 comments

26.

Diagnosing a Linux Performance Regression(automattic.com ↗)

49 points · by program · 1y ago · 4 comments

comment 1y ago · link · parent

Thanks for fixing the title of this post! [U+1F642 slightly smiling face emoji] (I wrote the post)

28.

GPS Week Number Rollover(en.wikipedia.org ↗)

3 points · by program · 1y ago · discuss

12345
8