MCPcopy Create free account
hub / github.com/davidgiven/fluxengine / reflect

Function reflect

lib/core/crc.cc:6–16  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4
5template <class T>
6T reflect(T bin, unsigned width = sizeof(T) * 8)
7{
8 T bout = 0;
9 while (width--)
10 {
11 bout <<= 1;
12 bout |= (bin & 1);
13 bin >>= 1;
14 }
15 return bout;
16}
17
18uint64_t generic_crc(const struct crcspec& spec, const Bytes& bytes)
19{

Callers 1

generic_crcFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected