Fabcoin Core  0.16.2
P2P Digital Currency
Utils.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <cstdint>
4 #include <iostream>
5 
6 namespace dev {
7 namespace evmjit {
8 
9 void keccak(uint8_t const *_data, uint64_t _size, uint8_t *o_hash);
10 
11 // The same as assert, but expression is always evaluated and result returned
12 #define CHECK(expr) (assert(expr), expr)
13 
14 #if !defined(NDEBUG) // Debug
15 
16 std::ostream &getLogStream(char const *_channel);
17 
18 #define DLOG(CHANNEL) ::dev::evmjit::getLogStream(#CHANNEL)
19 
20 #else // Release
21 
22 struct Voider
23 {
24  void operator=(std::ostream const&) {}
25 };
26 
27 #define DLOG(CHANNEL) true ? (void)0 : ::dev::evmjit::Voider{} = std::cerr
28 
29 #endif
30 
31 }
32 }
Adapted from code found on http://stackoverflow.com/questions/180947/base64-decode-snippet-in-c Origi...
Definition: Arith256.cpp:15
void keccak(uint8_t const *_data, uint64_t _size, uint8_t *o_hash)
Definition: Utils.cpp:178
std::ostream & getLogStream(char const *_channel)
Definition: Utils.cpp:16