Skip to content

Commit 43f8dc4

Browse files
committed
Marked certain APIs deprecated
1 parent 004da77 commit 43f8dc4

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ PROJECT (CLICKHOUSE-CLIENT)
2323
ENDIF ()
2424
SET (CMAKE_EXE_LINKER_FLAGS, "${CMAKE_EXE_LINKER_FLAGS} -lpthread")
2525
# -Wpedantic makes int128 support somewhat harder and less performant (by not allowing builtin __int128)
26-
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Werror")
26+
# -Wno-deprecated-declarations to produce less cluttered output when building library itself (`deprecated` attributes are for library users)
27+
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Werror -Wno-deprecated-declarations")
2728
ENDIF ()
2829

2930
INCLUDE_DIRECTORIES (.)

clickhouse/base/string_utils.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
namespace clickhouse {
99

1010
template <typename T>
11+
[[deprecated("Not used by clickhosue-cpp itself, and will be removed in next major release (3.0) ")]]
1112
inline T FromString(const std::string& s) {
1213
std::istringstream iss(s);
1314
T result;
@@ -16,6 +17,7 @@ inline T FromString(const std::string& s) {
1617
}
1718

1819
template <typename T>
20+
[[deprecated("Not used by clickhosue-cpp itself, and will be removed in next major release (3.0) ")]]
1921
inline T FromString(const StringView& s) {
2022
std::istringstream iss((std::string(s)));
2123
T result;

clickhouse/client.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,13 +90,13 @@ struct ClientOptions {
9090
DECLARE_FIELD(connection_recv_timeout, std::chrono::seconds, SetConnectionRecvTimeout, std::chrono::seconds(0));
9191
DECLARE_FIELD(connection_send_timeout, std::chrono::seconds, SetConnectionSendTimeout, std::chrono::seconds(0));
9292

93-
// TODO deprecate setting
9493
/** It helps to ease migration of the old codebases, which can't afford to switch
9594
* to using ColumnLowCardinalityT or ColumnLowCardinality directly,
9695
* but still want to benefit from smaller on-wire LowCardinality bandwidth footprint.
9796
*
9897
* @see LowCardinalitySerializationAdaptor, CreateColumnByType
9998
*/
99+
[[deprecated("Makes implementation of LC(X) harder and code uglier. Will be removed in next major release (3.0) ")]]
100100
DECLARE_FIELD(backward_compatibility_lowcardinality_as_wrapped_column, bool, SetBakcwardCompatibilityFeatureLowCardinalityAsWrappedColumn, true);
101101

102102
/** Set max size data to compress if compression enabled.

0 commit comments

Comments
 (0)