Topics /

Software Engineering

The most popular blog posts about software engineering on Hacker News. 1,517 posts.

2021
1053

OpenBSD's Pledge and Unveil from Python

Years ago, OpenBSD gained two new security system calls, pledge(2) (originally tame(2) ) and unveil . In both, an application surrenders capabilities at run-time. The idea is to perform initialization like usual, then drop capabilities before handling untrusted input, limiting unwanted side effects. This feature is…

1062

Let's write a compiler, part 3: A parser

Tokenizing the source code input is a great start for our compiler. Now let's turn our attention to parsing the PL/0 grammar. Once we have finished with the parser, the front end of our compiler will be finished and we will have a PL/0 validator. This is a program that can read in PL/0 source code and inform the user…

1068

Tiny ELF Files: Revisited in 2021

Quick edit: While I work on a proper update, I'll note here that several posters on reddit and hackernews have pointed out ways to bring the total size of the program down to 105 bytes while still printing the full "Hello, world!" Much credit goes to Josh Triplett , who produced the 105-byte version which you can find…

1074

C++20 Modules with GCC11

Introduction One of the headline changes of the C++20 standard is the inclusion of modules. Modules promise to significantly change the structure of C++ codebases and possibly signal headers’ ultimate demise (but probably not in my lifetime). It also opens the door to potentially have a unified build system and…

1076

The Elements of Git

This is not a tutorial. If you're looking for a quick, easy, "how to use git" kind of post, look elsewhere.The goal of this post is to give you just enough understanding of the git internals that you can build up a correct intuition of what various git commands actually do under the hood.

1080

Modern C++ for C Programmers (2018)

Welcome to part 1 of Modern C++ for C Programmers, please see the introduction for the goals and context of this series. In this part we start with C++ features that you can use to spice up your code ’line by line’, without immediately having to use all 1400 pages of ‘The C++ Programming Language’. Various code…