C++Fold Expressions

Download C++ for free

Remarks

Fold Expressions are supported for the following operators

            
+-*/%&|<<>>
+=-=*=/=%=\ˆ=&=|=<<=>>==
==!=<><=>=&&||,.*->*

When folding over an empty sequence, a fold expression is ill-formed, except for the following three operators:

OperatorValue when parameter pack is empty
&&true
||false
,void()

Related Examples

Binary Folds