Prometheus Blogs

How Wadler's Law Hurts Us


Computer scientist Philip Wadler proposed this law in 1992 (and refined it in 1996):

In any language design, the total time spent discussing a feature in this list is proportional to two raised to the power of its position minus one1.

  1. Semantics
  2. Syntax
  3. Lexical syntax
  4. Lexical syntax of comments

Dr. Wadler’s wry observation was based in his experience in computer language design, and it’s just as applicable to information transfer standards.

The bottom line is that the least important aspects of language design receive the most scrutiny. Wadler’s law is therefore a more concrete application of Parkinson’s law of triviality2, also referred to as the bikeshed effect:

Parkinson shows how you can go in to the board of directors and get approval for building a multi-million or even billion dollar atomic power plant, but if you want to build a bike shed you will be tangled up in endless discussions.

Parkinson explains that this is because an atomic plant is so vast, so expensive and so complicated that people cannot grasp it, and rather than try, they fall back on the assumption that somebody else checked all the details before it got this far. Richard P. Feynmann gives a couple of interesting, and very much to the point, examples relating to Los Alamos in his books.

A bike shed on the other hand. Anyone can build one of those over a weekend, and still have time to watch the game on TV. So no matter how well prepared, no matter how reasonable you are with your proposal, somebody will seize the chance to show that he is doing his job, that he is paying attention, that he is here.

Semantics is concerned with meaning, while syntax is concerned with sentence structure.

Syntax is defined by a grammar that defines how words (tokens) are assembled into a grammatically correct sentence. Grammars are usually defined by production rules, such as various flavors of Backus–Naur form.

Lexical syntax, on the other hand, defines how a stream of characters is broken into words. It defines the structure of words. Lexical syntax is usually specified by regular expressions3.

So how does Wadler’s observation of human nature hurt us? Among other ways, excessive focus on relatively unimportant aspects of standards results in lower quality, which incurs immense (and usually overlooked) costs4.

  1. Wadler’s formulation used zero-based numbering. I switched it to one-based to suit our rendering pipeline.

  2. Parkinson’s Law, and Other Studies in Administration by Cyril Northcote Parkinson

  3. Mastering Regular Expressions 3rd Edition by Jeffrey E. F. Friedl

  4. Poor-Quality Cost, by James Harrington

Reader Comments
Leave a Comment