Faking Go generics with Unicode, and watching compiler sanity unravel
Why is this Languages meme funny?
Level 1: We Stray Further
Imagine you’re playing a card game with friends, and the game has a rule: there’s no special wildcard card in this version of the game. But one very crafty friend really wants that wildcard feature, so they make their own fake card out of paper that looks almost exactly like the real thing. At first glance, everyone thinks it’s an official card, but it’s actually something sneaky they cooked up at home. When the others realize what happened, they all groan and laugh — it’s clever, sure, but also kind of outrageous. It’s like saying, “You weren’t supposed to do that, but wow, you found a loophole!”
That’s basically what happened here with code. The programming language Go said “you can’t use generics” (kind of like “no wildcard card allowed”). One programmer found a sneaky way around it: they used some look-alike characters (from another alphabet!) and a little script to pretend Go had generics. It’s as if they drew their own wildcard card to use in the game. The result did work, but it was also so cheeky that everyone who saw it had a mix of admiration and “oh no, that’s cursed” feeling. The picture of the odd-looking duck with the caption “Every day, we stray further from god” is a funny way of saying, “This is so wrong it’s almost sinful!” 😅 In simple terms, the meme is laughing about a coder who bent the rules of the language in a super creative (but kind of crazy) way, and how the rest of us are equal parts impressed and horrified by what they did.
Level 2: No Generics? No Problem!
For those newer to Go or programming, let’s break down what’s going on. Generics are a language feature that let you write a function or data structure that can work with any type (like a list that can hold either numbers or strings using the same code). Think of it like writing a recipe where you say “fruit” instead of specifically “apple” or “banana” – one recipe works for any fruit you plug in. Up until Go version 1.18, GoLang did not support generics at all. If you wanted a list of integers and a list of strings, you either had to write two separate list implementations (one for each type) or use a one-size-fits-all type like interface{} (which lets anything in, but then you’re on your own checking types at runtime). This was a well-known quirk of Go; many newcomers were surprised by it (“Wait, Go doesn’t have generics?!” is a common reaction, a classic LanguageGotcha).
Now, developers are resourceful. If a language lacks a feature, people often come up with workarounds. The meme highlights one such workaround that is both clever and a bit crazy. A programmer wanted to avoid writing the same code over and over for different types, so they effectively made their own mini-generic system using a template and a script. They wrote a Go source file as a template with a fake type parameter named ElementT. In the code, it looked something like this:
// This looks like a generic type, but it's actually a single identifier with sneaky characters
type ImmutableTreeListᐸElementTᐳ struct {
// ... imagine fields or methods using ElementT ...
}
Notice those funny symbols around ElementT? They might look like < and > to you, but they aren’t the normal angle-bracket characters at all! They are characters from the Canadian Aboriginal Syllabics Unicode block. In plain terms, Unicode is a standard that includes characters from languages all over the world (letters, symbols, etc.). Go (like many modern languages) allows Unicode letters in names, meaning you can use non-English letters in your variable and type names. Here, the developer took advantage of that by using two Unicode characters that look a lot like < and >. Because they’re valid letters for an identifier, the Go compiler treats ImmutableTreeListᐸElementTᐳ as one big name (no special generic magic, just a funky name). To the compiler, there's nothing “parametric” about it – it’s as if we named a type ImmutableTreeListElementT or MyCrazyTypeName. But to a human reader, it tricks the eye into seeing a pattern like a generic type parameter.
After writing this pseudo-generic template file, the next step was template codegen: using an automated find-and-replace to swap out ElementT for whatever real type was needed and save that as a new Go file. For example, if they needed an ImmutableTreeList for int and one for string, they’d run a script (maybe triggered by a go generate command or a simple script) to replace ElementT with int in one copy of the file, and with string in another. This would generate something like immutabletreelist_int.go containing type ImmutableTreeListᐸintᐳ struct { ... }, and immutabletreelist_string.go with type ImmutableTreeListᐸstringᐳ struct { ... }. Each of those is now a real, concrete type definition specialized to a certain type. In fancy terms, these are the monomorphized_go_files – separate versions of the code for each type, created from the template. “Monomorphized” just means we’ve gone from one generic blueprint to multiple specific copies (one per type). It’s the same approach a C++ or Rust compiler would take with generics, but here it’s done manually with a bit of scripting.
Does this trick work? Yes, technically it gets the job done. The code compiles, and you get type-specific implementations without hand-writing each one. But is it good practice? Ehhhh, not really! This is where CodeQuality concerns come in. Sure, you avoided duplication, but you did it by making the code rather strange to anyone reading it. It’s a CodeReadability nightmare: if someone not “in the know” opens this code, they’ll probably scratch their head or believe Go somehow had a secret generics feature. It’s also easy to make mistakes — what if you forget to run the generator after updating the template, or if your search-and-replace accidentally misses something? Maintaining such a setup is part of CodeMaintainability hell. In fact, using weird Unicode characters in names is a form of CodeObfuscation (hiding intent), even if it wasn’t done maliciously here.
The phrase on the meme’s bottom picture, “Every day, we stray further from god.”, is Internet-slang humor for “this is so wrong or unnatural that even a higher power would disapprove.” It’s exaggeration, of course, meant to be tongue-in-cheek. People in the Go community (and programmers at large) find this funny because it showcases just how far someone went to bend the rules and simulate a feature Go didn’t have at the time. Nowadays, as of Go 1.18+, the language does have proper generics, so thankfully you wouldn’t need to do something this extreme. This meme is like a time capsule of programmer creativity: when faced with a limitation, rather than giving up, one programmer said “No generics? No problem, I’ll make my own!” — and did so in the wildest way imaginable. It’s a memorable example of developer problem-solving, equal parts impressive and absurd, and that’s exactly why it makes us laugh.
Level 3: Angle Bracket Impostors
In practice, seasoned Go developers see this and immediately recognize a notorious workaround from the era when Go had no generics. The meme’s top half – a Reddit comment screenshot – serves as a hall-of-fame moment for creative hacking. A confused user asks, “I thought Go doesn’t have generics. What’s type ImmutableTreeList<ElementT> struct { ... } doing here?” It’s a fair question: prior to Go 1.18, seeing Something<T> in Go code should be impossible. That snippet looks like a C++ or Java generic type with angle brackets. The punchline comes in the reply: the author reveals it’s not a real generic at all, but a go_no_generics_workaround involving a fake template. They literally wrote a Go source file with what appears to be a parameterized type, except those angle bracket characters are actually sneaky Unicode symbols from the Canadian Aboriginal Syllabics block. In other words, ImmutableTreeListᐸElementTᐳ is one continuous identifier. To Go’s compiler, it’s as mundane as if you named a type ImmutableTreeListElementT – nothing unusual in terms of the language rules, even though it looks unusual to us. But to a human reading the code, it looks like ImmutableTreeList<ElementT> – a clever visual deception!
Why do this? Well, before official generics, Go devs often faced repetitive boilerplate when dealing with multiple data types. If you wanted, say, a list of int and a list of string, you had a few painful options: write two almost identical versions by hand (tedious and error-prone), use interface{} and lose compile-time type safety (trading clarity for flexibility), or adopt some code generation trick. This meme showcases one of the most creative yet unholy solutions: treating source code as a find-and-replace template. The developer wrote a single "generic-looking" file using a placeholder type name ElementT inside those fake angle brackets, and then ran a script (perhaps a simple sed command or Go’s own go generate) to produce real Go files for each needed concrete type. In the comment, they mention generating “three monomorphized .go files” – which means they ended up with three specialized versions of the code (maybe one for ints, one for strings, etc.), each as if a different type parameter had been filled in. This process is essentially manual template_codegen. It’s like they built generics out of duct tape and Unicode, doing themselves what a generics-capable compiler would normally do for you.
For veteran programmers, the humor (tinged with horror) comes from both the ingenuity and the absurdity. It’s a classic piece of DeveloperHumor where we laugh because we recognize the underlying pain that led to such a stunt. The bottom image with the bizarre bird and the caption “Every day, we stray further from god.” is meme-speak for “this is an abomination (even if it’s clever).” In terms of CodeQuality, this hack is a double-edged sword. Technically it works, but it’s a CodeReadability nightmare and a minefield for CodeMaintainability. Imagine inheriting this code and trying to figure out why there are seemingly angle brackets in a Go type name! It’s the kind of trick that makes you do a double-take in a code review and maybe reach for a stress ball. The phrase “stray further from god” perfectly captures that mix of amused disbelief and disapproval: the code might function, but it feels like it violates some natural order of clean coding.
Historically, this meme hits home because it reflects Go’s evolution. The language designers long resisted adding generics, arguing that many problems could be solved without them. Meanwhile, the community’s need for reusable, type-safe containers and functions only grew. So what did folks do? They got creative. Some wrote code generators or used tools like genny or text/template to auto-produce typesafe code. Others accepted a bit of duplication. But a few intrepid souls, like the one in this Reddit thread, took it to another level — exemplifying a LanguageQuirk taken to the extreme. It’s both a parody and a tribute to developer inventiveness. The top panel’s Reddit Q&A grounds the joke in reality (yes, someone actually did this!), and the bottom panel’s dramatic caption voices what we’re all thinking: “Sure, it works… but was it worth losing a piece of our soul?” The humor clicks with those of us who have seen or written questionable code in the name of getting things done. This specific combo of Unicode trickery and code generation is an outrageous case of a LanguageGotcha that leaves even seasoned engineers shaking their heads in amused disbelief.
Level 4: Lexical Loopholes
In the depths of language design, this meme exposes a bizarre exploitation of Go’s lexical rules. Under the hood, a compiler treats program text according to grammar and Unicode categories. In GoLang (prior to generics in 1.18), an identifier can include letters from many languages' alphabets (thanks to Unicode support). The cunning trick here is that the code uses Canadian Aboriginal Syllabics characters that look like < and > but are actually considered letters, not punctuation. This sly use of homoglyphs is a unicode_identifiers_abuse: the characters ᐸ and ᐳ come from the Canadian Aboriginal Syllabics block, where they count as valid letters in identifiers. That means the compiler sees ImmutableTreeListᐸElementTᐳ as a single giant name (one token). There's no special generic syntax recognized — no <ElementT> tokenization — just an extended identifier.
From a theoretical perspective, this is a warping of parametric polymorphism into a manual process. Generics, in languages that support them, allow one to write type-general code which the compiler then monomorphizes behind the scenes (creating specific instances per type). In absence of built-in generics, this developer essentially performed monomorphization manually via code generation. It’s reminiscent of how C++ templates or Rust generics work: the compiler duplicates code for each type usage. However, here the duplication isn’t done by the compiler’s fancy logic but by a search-and-replace script external to the language’s semantic understanding. It’s like implementing a mini pre-processor: the template code is processed to produce concrete specialized code, after which the Go compiler just sees normal, non-generic code.
This approach plays on a language spec loophole. Formally, the Go spec allowed those Unicode letters, inadvertently enabling a visual illusion: code that appears to have a generic parameter due to angle-bracket lookalikes. It’s a fascinating case of how a programming language’s grammar (the tokens allowed for identifiers) can be bent for purposes far beyond its designers’ intentions. In compiler terms, the parser’s sanity isn’t really unraveling – it’s dutifully following the rules – but the human reading the code experiences cognitive dissonance. This highlights the gap between how code looks and what it truly is under the hood. It’s a reminder of the fine line between creative metaprogramming and CodeObfuscation: an ingenious trick that flirts with the realm of obscurity. There’s deep irony here: by strictly adhering to the formal rules of the language, the developer achieved something the language informally forbade. This illustrates how missing LanguageFeatures can lead to almost perverse ingenuity – bending a type system’s limitations using only lexical trickery and external tooling.
Description
Meme split in two halves: top is a Reddit thread screenshot titled "Parallelizing Enjarify in Go and Rust" with a highlighted comment asking, “can you please explain this go syntax to me? type ImmutableTreeList<ElementT> struct { I thought go doesn’t have generics.” The reply explains that Go lacks generics, the angle-bracket look-alikes are actually Canadian Aboriginal Syllabics Unicode characters, and a search-and-replace template later monomorphizes three concrete files. Bottom panel shows a blurry, taxidermy-looking bird with teal head and caption "Every day. We stray further from god." in white text. The humor lands for seasoned engineers who remember pre-1.18 Go hacks: abusing permissive identifier rules, generating code instead of proper generics, and the inevitable readability debt such tricks incur. Visual colors are standard Reddit whites and yellows, with the lower image dark and slightly pixelated, emphasizing existential dread at this kind of code ‘creativity’
Comments
10Comment deleted
Nothing like sneaking entire Unicode planes past the parser - because who needs type parameters when your identifier can contain its own character set?
This is what happens when you've been writing Go for so long that you start seeing Canadian Aboriginal Syllabics as a perfectly reasonable solution to the lack of generics - next thing you know, you'll be implementing inheritance using emoji and wondering why your PR got rejected with just a crying face reaction
Ah yes, the classic pre-Go-1.18 era: when developers were so desperate for generics they resorted to Unicode character exploitation and template files. Using Canadian Aboriginal Syllabics as angle brackets is the kind of 'technically correct' solution that makes you simultaneously admire the ingenuity and question every life choice that led to this moment. It's the programming equivalent of discovering your colleague has been using reflection and code generation to simulate features the language intentionally doesn't support - brilliant, horrifying, and absolutely unmaintainable. At least now with actual generics in Go, we can look back at these archaeological artifacts and appreciate how far we've come from the dark ages of `interface{}` everywhere and Unicode character shenanigans
Pre - Go-1.18 ‘generics’ delivered via Unicode and sed - compilers cope, but grep, linters, and future-you file the postmortem
Go's fix for generics: weld them into one unpronounceable identifier. Maintainability? That's your problem now
Pre‑1.18 Go: want generics? Use Unicode confusables and a sed pipeline - one identifier to the compiler, one resignation letter to the on‑call
Could be worse Comment deleted
Oh wait, no it couldn't Comment deleted
Build your own C preprocessor with Ctrl+F and Ctrl+V Comment deleted
Language: py Code: # mom can we have Java # No. We have Java at home # Java at home: newㅤHashMapᐸStringᐳ=lambda *int:{*int} HashMapᐸStringᐳㅤmap = newㅤHashMapᐸStringᐳ(7,8,9); print(HashMapᐸStringᐳㅤmap); Output: {8, 9, 7} Comment deleted