Fix special build

This commit is contained in:
avogar 2024-05-15 22:37:33 +00:00
parent 047dd03f43
commit f19615788b
4 changed files with 6 additions and 6 deletions

View File

@ -227,7 +227,7 @@ void ColumnDynamic::insertFrom(const DB::IColumn & src_, size_t n)
auto & variant_col = assert_cast<ColumnVariant &>(*variant_column);
/// If variants are different, we need to extend our variant with new variants.
if (auto global_discriminators_mapping = combineVariants(dynamic_src.variant_info))
if (auto * global_discriminators_mapping = combineVariants(dynamic_src.variant_info))
{
variant_col.insertFrom(*dynamic_src.variant_column, n, *global_discriminators_mapping);
return;
@ -281,7 +281,7 @@ void ColumnDynamic::insertRangeFrom(const DB::IColumn & src_, size_t start, size
auto & variant_col = assert_cast<ColumnVariant &>(*variant_column);
/// If variants are different, we need to extend our variant with new variants.
if (auto global_discriminators_mapping = combineVariants(dynamic_src.variant_info))
if (auto * global_discriminators_mapping = combineVariants(dynamic_src.variant_info))
{
variant_col.insertRangeFrom(*dynamic_src.variant_column, start, length, *global_discriminators_mapping);
return;
@ -443,7 +443,7 @@ void ColumnDynamic::insertManyFrom(const DB::IColumn & src_, size_t position, si
auto & variant_col = assert_cast<ColumnVariant &>(*variant_column);
/// If variants are different, we need to extend our variant with new variants.
if (auto global_discriminators_mapping = combineVariants(dynamic_src.variant_info))
if (auto * global_discriminators_mapping = combineVariants(dynamic_src.variant_info))
{
variant_col.insertManyFrom(*dynamic_src.variant_column, position, length, *global_discriminators_mapping);
return;

View File

@ -67,7 +67,7 @@ static DataTypePtr create(const ASTPtr & arguments)
if (identifier_name != "max_types")
throw Exception(ErrorCodes::UNEXPECTED_AST_STRUCTURE, "Unexpected identifier: {}. Dynamic data type argument should be in a form 'max_types=N'", identifier_name);
auto literal = argument->arguments->children[1]->as<ASTLiteral>();
auto * literal = argument->arguments->children[1]->as<ASTLiteral>();
if (!literal || literal->value.getType() != Field::Types::UInt64 || literal->value.get<UInt64>() == 0 || literal->value.get<UInt64>() > 255)
throw Exception(ErrorCodes::UNEXPECTED_AST_STRUCTURE, "'max_types' argument for Dynamic type should be a positive integer between 1 and 255");

View File

@ -11,7 +11,7 @@ class SerializationDynamicElement;
class SerializationDynamic : public ISerialization
{
public:
SerializationDynamic(size_t max_dynamic_types_) : max_dynamic_types(max_dynamic_types_)
explicit SerializationDynamic(size_t max_dynamic_types_) : max_dynamic_types(max_dynamic_types_)
{
}

View File

@ -55,7 +55,7 @@ private:
class ParserDataTypeArgument : public IParserBase
{
public:
ParserDataTypeArgument(std::string_view type_name_) : type_name(type_name_)
explicit ParserDataTypeArgument(std::string_view type_name_) : type_name(type_name_)
{
}