
operator overloading - cppreference.com
Feb 5, 2025 · Since the built-in operator ! performs contextual conversion to bool, user-defined classes that are intended to be used in boolean contexts could provide only operator bool and …
Other operators - cppreference.com
Mar 5, 2025 · The function call operator provides function semantics for any object. The conditional operator (colloquially referred to as ternary conditional ) checks the boolean …
Member access operators - cppreference.com
Jun 11, 2024 · The resulting function call expression is called pseudo destructor call. It takes no arguments, returns void, evaluates E1, and ends the lifetime of its result object.
Overload resolution - cppreference.com
Apr 26, 2025 · The argument list for the purpose of overload resolution consists of the operands of the operator except for operator->, where the second operand is not an argument for the …
Increment/decrement operators - cppreference.com
Jan 20, 2025 · Standard library Increment and decrement operators are overloaded for many standard library types. In particular, every LegacyIterator overloads operator++ and every …
Logical operators - cppreference.com
Jun 5, 2024 · For the built-in logical OR operator, the result is true if either the first or the second operand (or both) is true. This operator is short-circuiting: if the first operand is true, the …
Assignment operators - cppreference.com
Jan 20, 2025 · Built-in compound assignment operator The behavior of every built-in compound-assignment expression target-exprop=new-value is exactly the same as the behavior of the …
User-defined conversion function - cppreference.com
Aug 14, 2024 · When making an explicit call to the conversion function, conversion-type-id is greedy: it is the longest sequence of tokens that could possibly form a conversion-type …
Functions - cppreference.com
Oct 2, 2023 · When a function is invoked, e.g. in a function-call expression, the parameters are initialized from the arguments (either provided at the place of call or defaulted) and the …
Lambda expressions (since C++11) - cppreference.com
Mar 2, 2025 · If a lambda expression (or a specialization of a generic lambda's function call operator)(since C++14) ODR-uses *this or any variable with automatic storage duration, it …