MCPcopy Create free account
hub / github.com/clMathLibraries/clBLAS / Accumulator

Class Accumulator

src/client/statisticalTimer.cpp:35–40  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

33// Functor object to help with accumulating values in vectors
34template< typename T >
35struct Accumulator: public std::unary_function< T, void >
36{
37 T acc;
38
39 Accumulator( ): acc( 0 ) {}
40 void operator( )(T x) { acc += x; }
41};
42
43// Unary predicate used for remove_if() algorithm

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected