Jump to content

Pyramid of doom (programming)

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Maury Markowitz (talk | contribs) at 19:09, 18 June 2015 (new article). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
(diff) ← Previous revision | Latest revision (diff) | Newer revision → (diff)

In computer programming, the pyramid of doom is a common problem that arrises when a program uses many levels of nested indentation to control access to a function. It is commonly seen when checking for null pointers or handling callbacks. Two examples of the term are used to a particular programming style in JavaScript,[1] and the nesting of if statements that occurs in dot notation languages when one of the objects may be a null pointer.[2]

References

  1. ^ "The Pyramid of Doom: A javaScript Style Trap". 27 November 2012.
  2. ^ Eberhardt, Colin (8 December 2014). "Tearing Down Swift's Optional Pyramid Of Doom".