ENGLISH
REFERENCE

type inference

compound.
C2 Proficiency Programming
Definition

compound. a feature in some computer programming languages where the computer automatically figures out the data type of a value. This means you do not have to write out every detail yourself because the system can guess it from the context.

compound. the automatic deduction of the data type of an expression in a programming language. This process allows for static typing without requiring explicit type declarations by the programmer, as the compiler or interpreter derives the type from the surrounding code.


SIMPLE

Type inference makes the code much shorter and easier to read.

CONTEXTUAL

Because the language supports type inference, the compiler knows that a variable assigned a whole number is an integer without being told.

COMPLEX

Advanced type inference algorithms, such as Hindley-Milner, allow for robust type safety in functional programming languages while maintaining the syntactic brevity typically associated with dynamic languages.

Origin

A compound of the noun type, from the Latin typus, and the noun inference, from the Latin inferre. The term emerged in the mid-20th century within the field of mathematical logic and formal semantics.

Etymology adapted from Wiktionary, available under CC BY-SA 4.0.

Usage

Commonly used in the context of statically typed programming languages like Swift, Kotlin, or Haskell.

Related words

Last updated July 22, 2026