Lint, Linting and Linter are words you may have heard where talking about static code analysis tools to flag and fix programming errors, bugs, find unused variables and enforce coding standards and styles, but where do these terms come from?
The history of linters
While working at Bell Labs in 1978, a computer scientist, Stephen C Johnson had been developing Yacc (Yet Another Compiler-Compiler) in C and was dealing with portability issues from Unix to 32-bit machine, when he decided to develop a program he called lint (Not us) to help with debugging.
Lint like tools were added to optimising compilers to help generate faster code, with Johnson saying in an 1978 paper that it allowed programmers to “concentrate at one stage of the programming process solely on the algorithms, data structures, and correctness of the program, and then later retrofit, with the aid of lint, the desirable properties of universality and portability”
As linters have evolved alongside compilers, many have included lint’s historical functionality and added an even wider variety of checks. These checks include syntax errors, deprecated function, formatting conventions, dangerous language features, use of undeclared variables etc
Origin of the term “Lint”
It is thought that the term “Lint” is thought to have come from the common term for the accumulation of textile fibres and other materials found on or around clothing. Which is then collected and removed or “Linted”.