You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-07-29 08:21:15 +03:00
C++20 fixes
This commit is contained in:
@ -25,27 +25,19 @@
|
||||
#include <string>
|
||||
#include <iostream>
|
||||
#include <stack>
|
||||
#ifdef _MSC_VER
|
||||
#include <unordered_map>
|
||||
#else
|
||||
#include <tr1/unordered_map>
|
||||
#endif
|
||||
#include <fstream>
|
||||
#include <sstream>
|
||||
#include <cerrno>
|
||||
#include <cstring>
|
||||
#ifdef _MSC_VER
|
||||
#include <unordered_set>
|
||||
#else
|
||||
#include <regex>
|
||||
#include <tr1/unordered_set>
|
||||
#endif
|
||||
#include <utility>
|
||||
#include <cassert>
|
||||
using namespace std;
|
||||
|
||||
#include <boost/shared_ptr.hpp>
|
||||
#include <boost/algorithm/string/case_conv.hpp>
|
||||
#include <boost/regex.hpp>
|
||||
#include <boost/tokenizer.hpp>
|
||||
using namespace boost;
|
||||
|
||||
@ -142,16 +134,16 @@ CalpontSystemCatalog::ColDataType convertDataType(const ddlpackage::ColumnType&
|
||||
|
||||
int parseCompressionComment(std::string comment)
|
||||
{
|
||||
algorithm::to_upper(comment);
|
||||
regex compat("[[:space:]]*COMPRESSION[[:space:]]*=[[:space:]]*", regex_constants::extended);
|
||||
boost::algorithm::to_upper(comment);
|
||||
std::regex compat("[[:space:]]*COMPRESSION[[:space:]]*=[[:space:]]*", std::regex_constants::extended);
|
||||
int compressiontype = 0;
|
||||
boost::match_results<std::string::const_iterator> what;
|
||||
std::match_results<std::string::const_iterator> what;
|
||||
std::string::const_iterator start, end;
|
||||
start = comment.begin();
|
||||
end = comment.end();
|
||||
boost::match_flag_type flags = boost::match_default;
|
||||
std::regex_constants::match_flag_type flags = std::regex_constants::match_default;
|
||||
|
||||
if (boost::regex_search(start, end, what, compat, flags))
|
||||
if (std::regex_search(start, end, what, compat, flags))
|
||||
{
|
||||
// Find the pattern, now get the compression type
|
||||
string compType(&(*(what[0].second)));
|
||||
@ -1389,10 +1381,10 @@ int ProcessDDLStatement(string& ddlStatement, string& schema, const string& tabl
|
||||
if (comment.length() > 0)
|
||||
{
|
||||
//@Bug 3782 This is for synchronization after calonlinealter to use
|
||||
algorithm::to_upper(comment);
|
||||
regex pat("[[:space:]]*SCHEMA[[:space:]]+SYNC[[:space:]]+ONLY", regex_constants::extended);
|
||||
boost::algorithm::to_upper(comment);
|
||||
std::regex pat("[[:space:]]*SCHEMA[[:space:]]+SYNC[[:space:]]+ONLY", std::regex_constants::extended);
|
||||
|
||||
if (regex_search(comment, pat))
|
||||
if (std::regex_search(comment, pat))
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
@ -2358,14 +2350,14 @@ int ha_mcs_impl_create_(const char* name, TABLE* table_arg, HA_CREATE_INFO* crea
|
||||
bool schemaSyncOnly = false;
|
||||
bool isCreate = true;
|
||||
|
||||
regex pat("[[:space:]]*SCHEMA[[:space:]]+SYNC[[:space:]]+ONLY", regex_constants::extended);
|
||||
std::regex pat("[[:space:]]*SCHEMA[[:space:]]+SYNC[[:space:]]+ONLY", std::regex_constants::extended);
|
||||
|
||||
if (regex_search(tablecomment, pat))
|
||||
if (std::regex_search(tablecomment, pat))
|
||||
{
|
||||
schemaSyncOnly = true;
|
||||
pat = createpatstr;
|
||||
|
||||
if (!regex_search(stmt, pat))
|
||||
if (!std::regex_search(stmt, pat))
|
||||
{
|
||||
isCreate = false;
|
||||
}
|
||||
@ -2395,7 +2387,7 @@ int ha_mcs_impl_create_(const char* name, TABLE* table_arg, HA_CREATE_INFO* crea
|
||||
|
||||
pat = alterpatstr;
|
||||
|
||||
if (regex_search(stmt, pat))
|
||||
if (std::regex_search(stmt, pat))
|
||||
{
|
||||
ci.isAlter = true;
|
||||
ci.alterTableState = cal_connection_info::ALTER_FIRST_RENAME;
|
||||
|
Reference in New Issue
Block a user