Andrei Alexandrescu
Template:Short description Script error: No such module "Unsubst". Script error: No such module "Unsubst".
Script error: No such module "Template wrapper".Script error: No such module "Check for clobbered parameters".
Tudor Andrei Cristian Alexandrescu[1] (born 1969) is a Romanian-American programmer and author specializing in the programming languages C++ and D.[2] He is especially known for his pioneering work on policy-based design implemented via template metaprogramming. These ideas are articulated in his book Modern C++ Design and were first implemented in his programming library, Loki. He also implemented the move constructors concept in his library MOJO.[3] He contributed to the C/C++ Users Journal under the byline "Generic<Programming>".
He became an American citizen in August 2014.[4]
Education and career
Alexandrescu received a Bachelor of Science (B.S.) degree in Electrical Engineering from Polytechnic University of Bucharest (Universitatea Politehnica din București) in July 1994.[5][6]
In September 1998, his first article was published in the C/C++ Users Journal. From April 1999 until February 2000, he was a program manager for Netzip, Inc. When the company was acquired by RealNetworks, Inc., he served there as a development manager from February 2000 through September 2001.[5]
In 2001, Alexandrescu released the book Modern C++ Design, reviewed as one of the five most important C++ books by C++ expert Scott Meyers.[7]
In 2003, Alexandrescu earned a Master of Science (M.S.), and in 2009, a Doctor of Philosophy (Ph.D.) in computer science from the University of Washington.[8][9][10]
In 2006, Alexandrescu began assisting Walter Bright in developing the D programming language.[11] In May 2010, he released a book titled The D Programming Language.
From 2010–2014, Alexandrescu, Herb Sutter, and Scott Meyers ran a small annual technical conference named C++ and Beyond.
Alexandrescu worked as a research scientist at Facebook for over 5 years, before leaving the firm in August 2015 to focus on developing the D language.[12]
In January 2022, Alexandrescu began working at Nvidia as a Principal Research Scientist.[13]
Contributions
The D programming language
Along with Walter Bright, Alexandrescu has been one of the two main designers of the D language, and the main maintainer of the standard library Phobos from 2007–2019. He is the founder of the D Language Foundation. His contributions include the module ranges. He is the author of The D Programming Language book.
Expected
Expected is a template class for C++ which is on the C++ Standards track.[14][15] Alexandrescu proposes[16] Expected<T> as a class for use as a return value which contains either a T or the exception preventing its creation, which is an improvement over use of either return codes or exceptions exclusively. Expected can be thought of as a restriction of sum (union) types or algebraic data types in various languages, e.g., Hope, or the more recent Haskell and Gallina; or of the error handling mechanism of Google's Go, or the Result type in Rust.
He explains the benefits of Expected<T> as:
- Associates errors with computational goals
- Naturally allows multiple exceptions in flight
- Switch between "error handling" and "exception throwing" styles
- Teleportation possible across thread boundaries, across nothrow subsystem boundaries and across time (save now, throw later)
- Collect, group, combine exceptions
Example
For example, instead of any of the following common function prototypes:
int parseInt(const string&); // Returns 0 on error and sets errno.
or
int parseInt(const string&); // Throws invalid_input or overflow
he proposes the following:
Expected<int> parseInt(const string&); // Returns an expected int: either an int or an exception
Scope guard
From 2000[17] onwards, Alexandrescu has advocated and popularized the scope guard idiom. He has introduced it as a language construct in D.[18] It has been implemented by others in many other languages.[19][20]
Bibliography
- Script error: No such module "citation/CS1".
- Script error: No such module "citation/CS1".
- Script error: No such module "citation/CS1".
References
<templatestyles src="Reflist/styles.css" />
- ↑ Script error: No such module "citation/CS1".
- ↑ Cite error: Script error: No such module "Namespace detect".Script error: No such module "Namespace detect".
- ↑ Script error: No such module "Citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ a b Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Computer Science & Engineering, Recent Ph.D. Graduates (Summer 2009). mark University of Washington.
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "Citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
- ↑ Script error: No such module "citation/CS1".
Script error: No such module "Check for unknown parameters".
External links
- Script error: No such module "Official website".Script error: No such module "Check for unknown parameters".
- Older website – Has links to downloadable Loki libraries for various compilers
- Template:In lang Interviu MONEY.ro: Facebook face angajări în România, 1 March 2010
Script error: No such module "Navbox". Script error: No such module "Authority control".
- Pages with script errors
- Pages with reference errors
- Romanian computer scientists
- C++ people
- Politehnica University of Bucharest alumni
- University of Washington alumni
- Living people
- Scientists from Bucharest
- Facebook employees
- 1969 births
- Romanian emigrants to the United States
- Programming language designers
- Articles with example C++ code