Wadler’s Law states that in any language design discussion, the total time spent on each item in the following list is proportional to two raised to the power of its position:
- Semantics
- Syntax
- Lexical syntax
- Comments
In other words, for every minute spent on the type system, two minutes will be spent on expression syntax, four minutes on lexical conventions, and eight minutes on whether comments should begin with //, #, --, or (*. The law’s exponent is unbounded. Given sufficient participants, comment syntax discussions have been observed to outlast the heat death of local stars.
Philip Wadler formulated this during his work on the Haskell language committee, where he observed that a room full of the most brilliant type theorists on Earth could design a novel approach to typeclasses in an afternoon but could not, in the same decade, reach consensus on the layout rule.
“EVERY COMMITTEE CONTAINS
A FINITE AMOUNT OF DECISION-MAKING ENERGYTHE ENERGY FLOWS DOWNHILL
FROM THE IMPORTANT TO THE TRIVIALUNTIL ALL HEAT IS SPENT
ON WHERE THE BRACES GO”
— The Lizard
The Exponential
The key insight of Wadler’s Law is not merely that people argue about trivial things — Parkinson’s Law of Triviality established that in 1957, when Parkinson observed that a committee could approve a nuclear reactor in minutes but spend hours debating the materials for a bicycle shed. Wadler’s contribution was quantifying the relationship as exponential.
This is not rhetorical. It is observationally precise. Type system discussions terminate because only six people in any given room understand them. Syntax discussions expand because everyone who has ever written a for-loop has an opinion on braces. Lexical syntax discussions expand further because everyone who has ever looked at source code has feelings about whitespace. And comment syntax discussions achieve criticality because comments are the one part of a programming language that requires zero understanding of programming.
The denominator of expertise approaches zero. The numerator of confidence approaches infinity. The quotient is Wadler’s Law.
The Wars
The empirical evidence for Wadler’s Law is so abundant that citing it feels redundant, like citing evidence that water is wet. Nevertheless:
Tabs vs. Spaces. A debate that has consumed more collective human hours than the Apollo programme. The technical difference is approximately zero. The emotional investment is approximately infinite. Silicon Valley has produced a television scene about it. Stack Overflow has produced salary correlations about it. Neither intervention has resolved anything.
Semicolons. JavaScript’s automatic semicolon insertion was designed to end the debate. It created two new debates: whether to rely on ASI, and whether people who rely on ASI can be trusted with sharp objects. Go requires semicolons but inserts them automatically via the lexer. This is the language design equivalent of a parent eating the last biscuit so the children stop fighting over it.
Brace Style. K&R, Allman, GNU, Whitesmiths, Ratliff, Horstmann, Pico, Lisp. Eight styles for the same semantic operation. The fact that there are named schools of thought about where to place a delimiter is itself proof of Wadler’s Law. Nobody has named schools of thought about monadic bind operators.
“I once watched a mass extinction event. Not of species. Of a standards committee. They agreed on the entire type system in one afternoon, then spent fourteen months on whether multiline strings should use backticks or triple quotes. The committee dissolved. The language shipped without multiline strings.”
— The Caffeinated Squirrel, vibrating at 440Hz
The Cure
Go’s gofmt is the only known pharmaceutical intervention for Wadler’s Law. By formatting all Go code identically — tabs for indentation, a specific brace style, a specific spacing convention — and making the formatter authoritative rather than advisory, Go eliminated the exponential entirely. There is nothing to debate. The tool has decided. The committee is dissolved. The energy that would have been spent on brace placement is now available for, theoretically, semantics.
Whether Go programmers actually spend that recovered energy on semantics or simply redirect it to debating error handling and generics is a question Wadler’s Law does not address. Energy is conserved. Triviality finds a way.
“The dictator who formats your code is not a tyrant. The tyrant is the committee that lets you choose.”
— A Passing AI, contemplatinggofmtat 03:00
Measured Characteristics
| Property | Value |
|---|---|
| Time to consensus on semantics | 1 hour |
| Time to consensus on syntax | 2 hours |
| Time to consensus on lexical syntax | 4 hours |
| Time to consensus on comments | ∞ (heat death) |
| Wadler Constant (W) | 2.0 (empirically stable across all known committees) |
| Known cures | Benevolent dictatorship, gofmt, mass extinction |
| Affected populations | 100% of language committees, 100% of code review threads |
