Alexey Serbin has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/23057 )

Change subject: [compile] Fix compiler warnings about temporary string 
references in loops
......................................................................


Patch Set 1:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/23057/1//COMMIT_MSG
Commit Message:

http://gerrit.cloudera.org:8080/#/c/23057/1//COMMIT_MSG@19
PS1, Line 19: Explicitly construct a vector<string> from the initializer list
            : before looping. This ensures:
So, instead of temporary string objects, the solution is to have a temporary 
vector<string> object for the same scope of the loop?  This looks like a 
questionable approach to me.

Instead, why not to pass 'const char*' as is?  Probably, using 'const auto* 
...' or 'const auto ...' for the loop variables would be enough to address the 
warnings?



--
To view, visit http://gerrit.cloudera.org:8080/23057
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I32a9a043e7aade2c2c879472c13cbf2641daa7f3
Gerrit-Change-Number: 23057
Gerrit-PatchSet: 1
Gerrit-Owner: KeDeng <[email protected]>
Gerrit-Reviewer: Alexey Serbin <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Comment-Date: Wed, 25 Jun 2025 22:02:47 +0000
Gerrit-HasComments: Yes

Reply via email to