Global Information Lookup Global Information

Generic programming information


Generic programming is a style of computer programming in which algorithms are written in terms of data types to-be-specified-later that are then instantiated when needed for specific types provided as parameters. This approach, pioneered by the ML programming language in 1973,[1][2] permits writing common functions or types that differ only in the set of types on which they operate when used, thus reducing duplicate code.

Generic programming was introduced to the mainstream with Ada in 1977. With templates in C++, generic programming became part of the repertoire of professional library design. The techniques were further improved and parameterized types were introduced in the influential 1994 book Design Patterns.[3]

New techniques were introduced by Andrei Alexandrescu in his 2001 book Modern C++ Design: Generic Programming and Design Patterns Applied. Subsequently, D implemented the same ideas.

Such software entities are known as generics in Ada, C#, Delphi, Eiffel, F#, Java, Nim, Python, Go, Rust, Swift, TypeScript, and Visual Basic .NET. They are known as parametric polymorphism in ML, Scala, Julia, and Haskell. (Haskell terminology also uses the term "generic" for a related but somewhat different concept.)

The term generic programming was originally coined by David Musser and Alexander Stepanov[4] in a more specific sense than the above, to describe a programming paradigm in which fundamental requirements on data types are abstracted from across concrete examples of algorithms and data structures and formalized as concepts, with generic functions implemented in terms of these concepts, typically using language genericity mechanisms as described above.

  1. ^ Lee, Kent D. (15 December 2008). Programming Languages: An Active Learning Approach. Springer Science & Business Media. pp. 9–10. ISBN 978-0-387-79422-8.
  2. ^ Milner, R.; Morris, L.; Newey, M. (1975). "A Logic for Computable Functions with Reflexive and Polymorphic Types". Proceedings of the Conference on Proving and Improving Programs.
  3. ^ Gamma, Erich; Helm, Richard; Johnson, Ralph; Vlissides, John (1994). Design Patterns. Addison-Wesley. ISBN 0-201-63361-2.
  4. ^ Musser & Stepanov 1989.

and 18 Related for: Generic programming information

Request time (Page generated in 0.8516 seconds.)

Generic programming

Last Update:

Generic programming is a style of computer programming in which algorithms are written in terms of data types to-be-specified-later that are then instantiated...

Word Count : 7708

Generics in Java

Last Update:

Generics are a facility of generic programming that were added to the Java programming language in 2004 within version J2SE 5.0. They were designed to...

Word Count : 2786

Generic

Last Update:

brand name Generic function, a computer programming entity made up of all methods having the same name Generic programming, a computer programming paradigm...

Word Count : 351

Generic function

Last Update:

computer programming, a generic function is a function defined for polymorphism. In statically typed languages (such as C++ and Java), the term generic functions...

Word Count : 628

Alexander Stepanov

Last Update:

Russian-American computer programmer, best known as an advocate of generic programming and as the primary designer and implementer of the C++ Standard Template...

Word Count : 567

List of generic and genericized trademarks

Last Update:

three lists of generic and genericized trademarks are: marks which were originally legally protected trademarks, but have been genericized and have lost...

Word Count : 5167

Static dispatch

Last Update:

a method or function to use. Examples are templates in C++, and generic programming in Fortran and other languages, in conjunction with function overloading...

Word Count : 240

Metaprogramming

Last Update:

enables developers to write programs and develop code that falls under the generic programming paradigm. Having the programming language itself as a first-class...

Word Count : 1432

Template

Last Update:

text common to each page of a document Template (C++), a tool for generic programming in the C++ language Template (file format), a standardized, non-executable...

Word Count : 329

Commodity checkoff program

Last Update:

organizations must promote their commodity in a generic way without reference to a particular producer. Checkoff programs attempt to improve the market position...

Word Count : 1179

International Conference on Functional Programming

Last Update:

Working Group 2.8 (Functional Programming). The conference focuses on functional programming and related areas of programming languages, logic, compilers...

Word Count : 299

Fortran

Last Update:

programming, array programming, modular programming, generic programming (Fortran 90), parallel computing (Fortran 95), object-oriented programming (Fortran...

Word Count : 10510

Subtyping

Last Update:

techniques of parametric polymorphism would be considered generic programming. Functional programming languages often allow the subtyping of records. Consequently...

Word Count : 3590

Parametric polymorphism

Last Update:

In programming languages and type theory, parametric polymorphism allows a single piece of code to be given a "generic" type, using variables in place...

Word Count : 2058

Template metaprogramming

Last Update:

from the programming language it is used with, it has practical uses. Some common reasons to use templates are to implement generic programming (avoiding...

Word Count : 3113

Dependent type

Last Update:

of the array. (Note that this is different from polymorphism and generic programming, both of which include the type as an argument.) A dependent pair...

Word Count : 2442

Computer programming

Last Update:

procedures, by writing code in one or more programming languages. Programmers typically use high-level programming languages that are more easily intelligible...

Word Count : 3333

History of programming languages

Last Update:

history of programming languages spans from documentation of early mechanical computers to modern tools for software development. Early programming languages...

Word Count : 3584

PDF Search Engine © AllGlobal.net