mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-18 20:32:43 +00:00
97f2a2213e
* Move some code outside dbms/src folder * Fix paths
23 lines
468 B
C++
23 lines
468 B
C++
#include <IO/ReadBufferFromFileDescriptor.h>
|
|
#include <IO/WriteBufferFromFileDescriptor.h>
|
|
#include <IO/Operators.h>
|
|
#include <common/StringRef.h>
|
|
|
|
|
|
/** Calculates StringRefHash from stdin. For debugging.
|
|
*/
|
|
|
|
int main(int, char **)
|
|
{
|
|
using namespace DB;
|
|
|
|
ReadBufferFromFileDescriptor in(STDIN_FILENO);
|
|
WriteBufferFromFileDescriptor out(STDOUT_FILENO);
|
|
|
|
String s;
|
|
readStringUntilEOF(s, in);
|
|
out << StringRefHash()(s) << '\n';
|
|
|
|
return 0;
|
|
}
|