Functional style in C++: Closures, late binding, and lambda abstractions

Research output: Chapter in Book/Report/Conference proceedingChapter

6 Citations (Scopus)

Abstract

C++ permits definition of a local class, within a function, method or block rather than in the global space. This feature makes nested functions and closures possible. Returning an object as the result of a function inevitably involves deep-copying of the object to and from temporaries, which may be expensive for big objects. Lazy construction, a late binding, is a simple and a very useful alternative. In this method, matrices themselves are never returned from functions; a function may however yield a recipe for how to make an object. In a code snippet, the first argument is the title of a test case and the second argument is a test's body itself, specified as an anonymous function, a genuine abstraction.

Original languageEnglish
Title of host publicationProceedings of the ACM SIGPLAN International Conference on Functional Programming, ICFP
PublisherAssociation for Computing Machinery
Pages337
Number of pages1
Publication statusPublished - 1998
Externally publishedYes
EventProceedings of the 1998 3rd ACM SIGPLAN International Conference on Functional Programming, ICFP-98 - Baltimore, MD, USA
Duration: 1998 Sep 271998 Sep 29

Other

OtherProceedings of the 1998 3rd ACM SIGPLAN International Conference on Functional Programming, ICFP-98
CityBaltimore, MD, USA
Period98/9/2798/9/29

ASJC Scopus subject areas

  • Computer Science(all)

Fingerprint Dive into the research topics of 'Functional style in C++: Closures, late binding, and lambda abstractions'. Together they form a unique fingerprint.

Cite this