You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2023/01/09 11:01:15 UTC
[GitHub] [doris] zclllyybb opened a new pull request, #15741: According to [namespace.std] and many practices, reopening namespace …
zclllyybb opened a new pull request, #15741:
URL: https://github.com/apache/doris/pull/15741
According to [namespace.std] and many practices(like [CppCoreGuidelines](https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#sf7-dont-write-using-namespace-at-global-scope-in-a-header-file) and [Don’t reopen namespace std](https://quuxplusone.github.io/blog/2021/10/27/dont-reopen-namespace-std/)), reopening `namespace std` or `using namespace std` is UB or very dangerous. Fixed them.
# Proposed changes
Issue Number: close #xxx
## Problem Summary
Describe your changes.
## Checklist(Required)
1. Does it affect the original behavior:
- [ ] Yes
- [x] No
- [ ] I don't know
2. Has unit tests been added:
- [ ] Yes
- [x] No
- [ ] No Need
3. Has the document been added or modified:
- [ ] Yes
- [x] No
- [ ] No Need
4. Does it need to update dependencies:
- [ ] Yes
- [x] No
5. Are there any changes that cannot be rolled back:
- [ ] Yes (If Yes, please explain WHY)
- [x] No
## Further comments
Still some similar behavior stays in some code-generators.
If this is a relatively large or complex change, kick off the discussion at [dev@doris.apache.org](mailto:dev@doris.apache.org) by explaining why you chose the solution you did and what alternatives you considered, etc...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] HappenLee commented on a diff in pull request #15741: [fix]fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
HappenLee commented on code in PR #15741:
URL: https://github.com/apache/doris/pull/15741#discussion_r1064635655
##########
be/src/olap/aggregate_func.cpp:
##########
@@ -17,11 +17,10 @@
#include "olap/aggregate_func.h"
-namespace std {
-namespace {
-// algorithm from boost: http://www.boost.org/doc/libs/1_61_0/doc/html/hash/reference.html#boost.hash_combine
+/// algorithm from boost: http://www.boost.org/doc/libs/1_61_0/doc/html/hash/reference.html#boost.hash_combine
Review Comment:
keep the origin comment “//” not "///"
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] github-actions[bot] commented on pull request #15741: [fix]fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15741:
URL: https://github.com/apache/doris/pull/15741#issuecomment-1376757885
PR approved by at least one committer and no changes requested.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] github-actions[bot] commented on pull request #15741: [fix]fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15741:
URL: https://github.com/apache/doris/pull/15741#issuecomment-1376652034
clang-tidy review says "All clean, LGTM! :+1:"
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] github-actions[bot] commented on pull request #15741: [fix]fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15741:
URL: https://github.com/apache/doris/pull/15741#issuecomment-1375588180
PR approved by anyone and no changes requested.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] HappenLee commented on pull request #15741: fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
HappenLee commented on PR #15741:
URL: https://github.com/apache/doris/pull/15741#issuecomment-1375569276
Hello,Thanks for your PR。 Please modify the PR titile for the check
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] HappenLee merged pull request #15741: [fix]fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
HappenLee merged PR #15741:
URL: https://github.com/apache/doris/pull/15741
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] zclllyybb commented on a diff in pull request #15741: [fix]fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
zclllyybb commented on code in PR #15741:
URL: https://github.com/apache/doris/pull/15741#discussion_r1065285437
##########
be/src/util/cityhash102/city.cc:
##########
@@ -33,8 +33,7 @@
#include <algorithm>
#include <string.h> // for memcpy and memset
-using namespace std;
-
+//using namespace std;
Review Comment:
thx for the reminder. fixed them.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] hello-stephen commented on pull request #15741: [fix]fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
hello-stephen commented on PR #15741:
URL: https://github.com/apache/doris/pull/15741#issuecomment-1375686693
TeamCity pipeline, clickbench performance test result:
the sum of best hot time: 36.83 seconds
load time: 488 seconds
storage size: 17122049659 Bytes
https://doris-community-test-1308700295.cos.ap-hongkong.myqcloud.com/tmp/20230109141425_clickbench_pr_76191.html
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] zclllyybb commented on pull request #15741: fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
zclllyybb commented on PR #15741:
URL: https://github.com/apache/doris/pull/15741#issuecomment-1375445383
您好,您的邮件我已收到。
这是我的自动回复。
***@***.***
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] github-actions[bot] commented on pull request #15741: fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15741:
URL: https://github.com/apache/doris/pull/15741#issuecomment-1375444841
clang-tidy review says "All clean, LGTM! :+1:"
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] HappenLee commented on a diff in pull request #15741: [fix]fixed dangerous usage of namespace std
Posted by GitBox <gi...@apache.org>.
HappenLee commented on code in PR #15741:
URL: https://github.com/apache/doris/pull/15741#discussion_r1064636152
##########
be/src/util/cityhash102/city.cc:
##########
@@ -33,8 +33,7 @@
#include <algorithm>
#include <string.h> // for memcpy and memset
-using namespace std;
-
+//using namespace std;
Review Comment:
just del the useless code, do not comment
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org