mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-24 16:42:05 +00:00
571d0d541c
* common/Types.h → common/types.h Also split Core/Defines.h and merge with common/likely.h * Improve cctz contrib * Fix ALWAYS_INLINE and unbundled build * Update Dockerfile from master * Fix test for unbundled library
17 lines
377 B
C++
17 lines
377 B
C++
#pragma once
|
|
|
|
#include <common/types.h>
|
|
|
|
/** Almost the same as x = x * exp10(exponent), but gives more accurate result.
|
|
* Example:
|
|
* 5 * 1e-11 = 4.9999999999999995e-11
|
|
* !=
|
|
* 5e-11 = shift10(5.0, -11)
|
|
*/
|
|
|
|
double shift10(double x, int exponent);
|
|
float shift10(float x, int exponent);
|
|
|
|
double shift10(UInt64 x, int exponent);
|
|
double shift10(Int64 x, int exponent);
|