mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
[clang-tidy] Use const reference instead of initializing string
Found with performance-unnecessary-copy-initialization Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
parent
e3ceda9ce1
commit
ab170e34df
1 changed files with 1 additions and 1 deletions
|
@ -242,7 +242,7 @@ static bool sort_compare (int left, int right)
|
|||
// UDAs.
|
||||
else if ((column = Context::getContext ().columns[field]) != nullptr)
|
||||
{
|
||||
std::string type = column->type ();
|
||||
const std::string& type = column->type ();
|
||||
if (type == "numeric")
|
||||
{
|
||||
auto left_real = strtof (((*global_data)[left].get_ref (field)).c_str (), nullptr);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue