Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
3d15e3c0
Commit
3d15e3c0
authored
Jun 29, 2021
by
Marko Mäkelä
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-22640 fixup: clang -Winconsistent-missing-override
parent
98c7916f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
31 deletions
+29
-31
sql/item_jsonfunc.h
sql/item_jsonfunc.h
+29
-31
No files found.
sql/item_jsonfunc.h
View file @
3d15e3c0
#ifndef ITEM_JSONFUNC_INCLUDED
#define ITEM_JSONFUNC_INCLUDED
/* Copyright (c) 2016, MariaDB
/* Copyright (c) 2016,
2021,
MariaDB
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
...
...
@@ -123,8 +123,8 @@ class Item_json_func: public Item_str_func
:
Item_str_func
(
thd
,
a
,
b
)
{
}
Item_json_func
(
THD
*
thd
,
List
<
Item
>
&
list
)
:
Item_str_func
(
thd
,
list
)
{
}
bool
is_json_type
()
{
return
true
;
}
void
make_send_field
(
THD
*
thd
,
Send_field
*
tmp_field
)
bool
is_json_type
()
override
{
return
true
;
}
void
make_send_field
(
THD
*
thd
,
Send_field
*
tmp_field
)
override
{
Item_str_func
::
make_send_field
(
thd
,
tmp_field
);
static
const
Lex_cstring
fmt
(
STRING_WITH_LEN
(
"json"
));
...
...
@@ -544,12 +544,12 @@ class Item_func_json_arrayagg : public Item_func_group_concat
Overrides Item_func_group_concat::skip_nulls()
NULL-s should be added to the result as JSON null value.
*/
bool
skip_nulls
()
const
{
return
false
;
}
String
*
get_str_from_item
(
Item
*
i
,
String
*
tmp
);
bool
skip_nulls
()
const
override
{
return
false
;
}
String
*
get_str_from_item
(
Item
*
i
,
String
*
tmp
)
override
;
String
*
get_str_from_field
(
Item
*
i
,
Field
*
f
,
String
*
tmp
,
const
uchar
*
key
,
size_t
offset
);
const
uchar
*
key
,
size_t
offset
)
override
;
void
cut_max_length
(
String
*
result
,
uint
old_length
,
uint
max_length
)
const
;
uint
old_length
,
uint
max_length
)
const
override
;
public:
String
m_tmp_json
;
/* Used in get_str_from_*.. */
Item_func_json_arrayagg
(
THD
*
thd
,
Name_resolution_context
*
context_arg
,
...
...
@@ -562,10 +562,10 @@ class Item_func_json_arrayagg : public Item_func_group_concat
}
Item_func_json_arrayagg
(
THD
*
thd
,
Item_func_json_arrayagg
*
item
)
:
Item_func_group_concat
(
thd
,
item
)
{}
bool
is_json_type
()
{
return
true
;
}
bool
is_json_type
()
override
{
return
true
;
}
const
char
*
func_name
()
const
{
return
"json_arrayagg("
;
}
enum
Sumfunctype
sum_func
()
const
{
return
JSON_ARRAYAGG_FUNC
;
}
const
char
*
func_name
()
const
override
{
return
"json_arrayagg("
;
}
enum
Sumfunctype
sum_func
()
const
override
{
return
JSON_ARRAYAGG_FUNC
;
}
String
*
val_str
(
String
*
str
)
override
;
...
...
@@ -587,40 +587,38 @@ class Item_func_json_objectagg : public Item_sum
}
Item_func_json_objectagg
(
THD
*
thd
,
Item_func_json_objectagg
*
item
);
bool
is_json_type
()
{
return
true
;
}
void
cleanup
();
bool
is_json_type
()
override
{
return
true
;
}
void
cleanup
()
override
;
enum
Sumfunctype
sum_func
()
const
{
return
JSON_OBJECTAGG_FUNC
;}
const
char
*
func_name
()
const
{
return
"json_objectagg"
;
}
const
Type_handler
*
type_handler
()
const
enum
Sumfunctype
sum_func
()
const
override
{
return
JSON_OBJECTAGG_FUNC
;}
const
char
*
func_name
()
const
override
{
return
"json_objectagg"
;
}
const
Type_handler
*
type_handler
()
const
override
{
if
(
too_big_for_varchar
())
return
&
type_handler_blob
;
return
&
type_handler_varchar
;
}
void
clear
();
bool
add
();
void
reset_field
()
{
DBUG_ASSERT
(
0
);
}
// not used
void
update_field
()
{
DBUG_ASSERT
(
0
);
}
// not used
bool
fix_fields
(
THD
*
,
Item
**
);
double
val_real
()
{
return
0.0
;
}
longlong
val_int
()
{
return
0
;
}
my_decimal
*
val_decimal
(
my_decimal
*
decimal_value
)
void
clear
()
override
;
bool
add
()
override
;
void
reset_field
()
override
{
DBUG_ASSERT
(
0
);
}
// not used
void
update_field
()
override
{
DBUG_ASSERT
(
0
);
}
// not used
bool
fix_fields
(
THD
*
,
Item
**
)
override
;
double
val_real
()
override
{
return
0.0
;
}
longlong
val_int
()
override
{
return
0
;
}
my_decimal
*
val_decimal
(
my_decimal
*
decimal_value
)
override
{
my_decimal_set_zero
(
decimal_value
);
return
decimal_value
;
}
bool
get_date
(
THD
*
thd
,
MYSQL_TIME
*
ltime
,
date_mode_t
fuzzydate
)
bool
get_date
(
THD
*
thd
,
MYSQL_TIME
*
ltime
,
date_mode_t
fuzzydate
)
override
{
return
get_date_from_string
(
thd
,
ltime
,
fuzzydate
);
}
String
*
val_str
(
String
*
str
);
Item
*
copy_or_same
(
THD
*
thd
);
void
no_rows_in_result
()
{}
Item
*
get_copy
(
THD
*
thd
)
String
*
val_str
(
String
*
str
)
override
;
Item
*
copy_or_same
(
THD
*
thd
)
override
;
void
no_rows_in_result
()
override
{}
Item
*
get_copy
(
THD
*
thd
)
override
{
return
get_item_copy
<
Item_func_json_objectagg
>
(
thd
,
this
);
}
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment