mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-10 01:25:21 +00:00
dbms, contrib: Clang 3.8 build fixes. [#METR-21516]
This commit is contained in:
parent
23a511f1cf
commit
39c2c0f5a5
@ -22,6 +22,7 @@
|
|||||||
#define Crypto_Crypto_INCLUDED
|
#define Crypto_Crypto_INCLUDED
|
||||||
|
|
||||||
|
|
||||||
|
#pragma GCC diagnostic push
|
||||||
#if defined(__APPLE__)
|
#if defined(__APPLE__)
|
||||||
// OS X 10.7 deprecates some OpenSSL functions
|
// OS X 10.7 deprecates some OpenSSL functions
|
||||||
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||||
@ -115,5 +116,6 @@ void Crypto_API uninitializeCrypto();
|
|||||||
|
|
||||||
} } // namespace Poco::Crypto
|
} } // namespace Poco::Crypto
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
|
||||||
#endif // Crypto_Crypto_INCLUDED
|
#endif // Crypto_Crypto_INCLUDED
|
||||||
|
@ -34,6 +34,10 @@
|
|||||||
#include <map>
|
#include <map>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#ifdef __clang__
|
||||||
|
#pragma GCC diagnostic ignored "-Wunused-local-typedef"
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace Poco {
|
namespace Poco {
|
||||||
namespace Data {
|
namespace Data {
|
||||||
@ -1495,4 +1499,6 @@ inline AbstractBinding::Ptr bind(T t)
|
|||||||
} } // namespace Poco::Data
|
} } // namespace Poco::Data
|
||||||
|
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
|
||||||
#endif // Data_Binding_INCLUDED
|
#endif // Data_Binding_INCLUDED
|
||||||
|
@ -44,6 +44,11 @@
|
|||||||
#include <limits>
|
#include <limits>
|
||||||
|
|
||||||
|
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#ifdef __clang__
|
||||||
|
#pragma GCC diagnostic ignored "-Wunused-local-typedef"
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace Poco {
|
namespace Poco {
|
||||||
namespace Dynamic {
|
namespace Dynamic {
|
||||||
|
|
||||||
@ -3550,5 +3555,6 @@ typedef Vector Array;
|
|||||||
|
|
||||||
} } // namespace Poco::Dynamic
|
} } // namespace Poco::Dynamic
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
|
||||||
#endif // Foundation_VarHolder_INCLUDED
|
#endif // Foundation_VarHolder_INCLUDED
|
||||||
|
@ -22,6 +22,7 @@
|
|||||||
#include "Poco/String.h"
|
#include "Poco/String.h"
|
||||||
#include "Poco/Types.h"
|
#include "Poco/Types.h"
|
||||||
|
|
||||||
|
#pragma GCC diagnostic push
|
||||||
#if __GNUC__ > 5
|
#if __GNUC__ > 5
|
||||||
#pragma GCC diagnostic ignored "-Wmisleading-indentation"
|
#pragma GCC diagnostic ignored "-Wmisleading-indentation"
|
||||||
#endif
|
#endif
|
||||||
@ -811,3 +812,5 @@ bool IPv6AddressImpl::operator != (const IPv6AddressImpl& addr) const
|
|||||||
|
|
||||||
|
|
||||||
} } } // namespace Poco::Net::Impl
|
} } } // namespace Poco::Net::Impl
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
@ -14,6 +14,7 @@
|
|||||||
//
|
//
|
||||||
|
|
||||||
|
|
||||||
|
#pragma GCC diagnostic push
|
||||||
#if defined(__APPLE__)
|
#if defined(__APPLE__)
|
||||||
// Some OpenSSL functions are deprecated in OS X 10.7
|
// Some OpenSSL functions are deprecated in OS X 10.7
|
||||||
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||||
@ -40,3 +41,5 @@ Session::~Session()
|
|||||||
|
|
||||||
|
|
||||||
} } // namespace Poco::Net
|
} } // namespace Poco::Net
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
@ -54,6 +54,9 @@
|
|||||||
|
|
||||||
#define VERSYM_VERSION 0x7fff
|
#define VERSYM_VERSION 0x7fff
|
||||||
|
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#pragma GCC diagnostic ignored "-Wunused-const-variable"
|
||||||
|
|
||||||
namespace base {
|
namespace base {
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
@ -431,4 +434,6 @@ void ElfMemImage::SymbolIterator::Update(int increment) {
|
|||||||
|
|
||||||
} // namespace base
|
} // namespace base
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
|
||||||
#endif // HAVE_ELF_MEM_IMAGE
|
#endif // HAVE_ELF_MEM_IMAGE
|
||||||
|
@ -97,6 +97,12 @@
|
|||||||
# define MAP_ANONYMOUS MAP_ANON
|
# define MAP_ANONYMOUS MAP_ANON
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#ifdef __clang__
|
||||||
|
#pragma GCC diagnostic ignored "-Wunused-private-field"
|
||||||
|
#pragma GCC diagnostic ignored "-Wgnu-alignof-expression"
|
||||||
|
#endif
|
||||||
|
|
||||||
// ========================================================================= //
|
// ========================================================================= //
|
||||||
|
|
||||||
DEFINE_bool(malloctrace,
|
DEFINE_bool(malloctrace,
|
||||||
@ -1488,3 +1494,5 @@ extern "C" PERFTOOLS_DLL_DECL void* tc_malloc_skip_new_handler(size_t size) PERF
|
|||||||
MallocHook::InvokeNewHook(result, size);
|
MallocHook::InvokeNewHook(result, size);
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
@ -56,9 +56,8 @@
|
|||||||
#include "common.h"
|
#include "common.h"
|
||||||
#include "internal_logging.h"
|
#include "internal_logging.h"
|
||||||
|
|
||||||
#ifdef __GNUC__
|
#pragma GCC diagnostic push
|
||||||
#pragma GCC diagnostic ignored "-Wunused-function"
|
#pragma GCC diagnostic ignored "-Wunused-function"
|
||||||
#endif
|
|
||||||
|
|
||||||
// On systems (like freebsd) that don't define MAP_ANONYMOUS, use the old
|
// On systems (like freebsd) that don't define MAP_ANONYMOUS, use the old
|
||||||
// form of the name instead.
|
// form of the name instead.
|
||||||
@ -564,3 +563,5 @@ void TCMalloc_SystemCommit(void* start, size_t length) {
|
|||||||
// such that they need to be re-committed before they can be used by the
|
// such that they need to be re-committed before they can be used by the
|
||||||
// application.
|
// application.
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
@ -155,6 +155,9 @@ using STL_NAMESPACE::vector;
|
|||||||
|
|
||||||
#include "libc_override.h"
|
#include "libc_override.h"
|
||||||
|
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#pragma GCC diagnostic ignored "-Wunused-function"
|
||||||
|
|
||||||
using tcmalloc::AlignmentForSize;
|
using tcmalloc::AlignmentForSize;
|
||||||
using tcmalloc::kLog;
|
using tcmalloc::kLog;
|
||||||
using tcmalloc::kCrash;
|
using tcmalloc::kCrash;
|
||||||
@ -1834,4 +1837,6 @@ extern "C" PERFTOOLS_DLL_DECL void* tc_malloc_skip_new_handler(size_t size) PER
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
|
||||||
#endif // TCMALLOC_USING_DEBUGALLOCATION
|
#endif // TCMALLOC_USING_DEBUGALLOCATION
|
||||||
|
@ -172,7 +172,7 @@ public:
|
|||||||
converted = std::make_unique<PaddedPODArray<TResult> >(array.size());
|
converted = std::make_unique<PaddedPODArray<TResult> >(array.size());
|
||||||
size_t size = array.size();
|
size_t size = array.size();
|
||||||
for (size_t i = 0; i < size; ++i)
|
for (size_t i = 0; i < size; ++i)
|
||||||
(*converted)[i] = array[i].get<typename NearestFieldType<TType>::Type>();
|
(*converted)[i] = array[i].template get<typename NearestFieldType<TType>::Type>();
|
||||||
}
|
}
|
||||||
|
|
||||||
return {converted->data(), converted->size()};
|
return {converted->data(), converted->size()};
|
||||||
|
@ -58,7 +58,7 @@ namespace
|
|||||||
ErrorCodes::INCORRECT_FILE_NAME
|
ErrorCodes::INCORRECT_FILE_NAME
|
||||||
};
|
};
|
||||||
|
|
||||||
const auto user = unescapeForFileName({address.data(), has_pw ? colon : user_pw_end});
|
const auto user = unescapeForFileName({address.data(), has_pw ? static_cast<const char *>(colon) : user_pw_end});
|
||||||
const auto password = has_pw ? unescapeForFileName({colon + 1, user_pw_end}) : std::string{};
|
const auto password = has_pw ? unescapeForFileName({colon + 1, user_pw_end}) : std::string{};
|
||||||
const auto host = unescapeForFileName({user_pw_end + 1, host_end});
|
const auto host = unescapeForFileName({user_pw_end + 1, host_end});
|
||||||
const auto port = parse<UInt16>(host_end + 1);
|
const auto port = parse<UInt16>(host_end + 1);
|
||||||
|
@ -46,7 +46,7 @@ public:
|
|||||||
const InterserverIOEndpointLocation & to_location);
|
const InterserverIOEndpointLocation & to_location);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Logger * log = &Logger::get("RemotePartChecker::Client");
|
// Logger * log = &Logger::get("RemotePartChecker::Client");
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -230,7 +230,7 @@ public:
|
|||||||
return it->first;
|
return it->first;
|
||||||
}
|
}
|
||||||
|
|
||||||
StoragePtr & table() const
|
StoragePtr & table() const override
|
||||||
{
|
{
|
||||||
return it->second;
|
return it->second;
|
||||||
}
|
}
|
||||||
|
@ -45,7 +45,7 @@ std::string dumpArgTypes(const DataTypes & args)
|
|||||||
|
|
||||||
/// Forward declarations.
|
/// Forward declarations.
|
||||||
template <typename TResult, typename TType>
|
template <typename TResult, typename TType>
|
||||||
struct ResultDataTypeDeducer;
|
class ResultDataTypeDeducer;
|
||||||
|
|
||||||
/// Internal class used by ResultDataTypeDeducer. Calls ResultDataTypeDeducer
|
/// Internal class used by ResultDataTypeDeducer. Calls ResultDataTypeDeducer
|
||||||
/// for the next branch to be processed.
|
/// for the next branch to be processed.
|
||||||
|
@ -184,12 +184,12 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t getDataSize() const
|
size_t getDataSize() const override
|
||||||
{
|
{
|
||||||
return data_size;
|
return data_size;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t getStringOffsetsSize() const
|
size_t getStringOffsetsSize() const override
|
||||||
{
|
{
|
||||||
return data.size();
|
return data.size();
|
||||||
}
|
}
|
||||||
|
@ -143,7 +143,7 @@ public:
|
|||||||
return chunk;
|
return chunk;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline size_t getSize() const
|
inline size_t getSize() const override
|
||||||
{
|
{
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
|
@ -37,7 +37,7 @@ std::string dumpArgTypes(const DataTypes & args)
|
|||||||
|
|
||||||
/// Forward declarations.
|
/// Forward declarations.
|
||||||
template <typename TResult, typename TType>
|
template <typename TResult, typename TType>
|
||||||
struct ResultDataTypeDeducer;
|
class ResultDataTypeDeducer;
|
||||||
|
|
||||||
/// Internal class used by ResultDataTypeDeducer. Calls ResultDataTypeDeducer
|
/// Internal class used by ResultDataTypeDeducer. Calls ResultDataTypeDeducer
|
||||||
/// for the next element to be processed.
|
/// for the next element to be processed.
|
||||||
|
@ -13,9 +13,8 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/// В этом тесте намеренно ссылаемся за пределы массива.
|
/// В этом тесте намеренно ссылаемся за пределы массива.
|
||||||
#ifdef __GNUC__
|
#pragma GCC diagnostic push
|
||||||
#pragma GCC diagnostic ignored "-Warray-bounds"
|
#pragma GCC diagnostic ignored "-Warray-bounds"
|
||||||
#endif
|
|
||||||
|
|
||||||
using size_t = unsigned long;
|
using size_t = unsigned long;
|
||||||
|
|
||||||
@ -161,3 +160,5 @@ void f()
|
|||||||
{
|
{
|
||||||
parse("123");
|
parse("123");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
Loading…
Reference in New Issue
Block a user