Skip to content
ontologydriven
Sign out

Dictionary

Words, grammatical forms and meanings linked to the ontology.

duck typing en · NOUN

Etymology

From the so-called duck test: “if it looks like a duck, swims like a duck, and quacks like a duck, then it probably is a duck.”

Meanings

  1. (uncountable) A style of dynamic typing in which an object's current set of methods and properties determines the valid semantics, rather than its inheritance from a particular class or implementation of a specific interface.
    • Ruby proponents call this duck typing::^([sic]) if the variable responds to a message that asks it to quack like a duck and it quacks, it must be a duck. This is clearly different from the way that Java (and other strongly typed languages) work, […] 2006, Neal Ford, Scott Davis, No Fluff, Just Stuff Anthology: The 2006 Edition, page 16:

Hypernyms

typing · dynamic typing

Relateds

typology

Translations (4)

pl duck typing (Translations) · fi ankkatyypitys (Translations) · de Duck-Typing (Translations) · fr duck typing (Translations)