clang-tidy : add cppcoreguidelines-init-variables - #3011
Conversation
WalkthroughThe Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: Repository UI Review profile: ASSERTIVE Plan: Pro 📒 Files selected for processing (1)
🧰 Additional context used🧠 Learnings (1)📓 Common learnings⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
🔇 Additional comments (2)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
cvvergara
left a comment
There was a problem hiding this comment.
I compiled locally using:
CXX=clang++ CC=clang cmake -DUSE_CLANG_TIDY=ON -DBUILD_HTML=OFF -DPOSTGRESQL_BIN=${PGBIN} ..
and these are some of the many warnings I get that are not fixed,
[ 20%] Building CXX object src/trsp/CMakeFiles/trsp.dir/trsp_driver.cpp.o
/home/vicky/pgrouting/pgrouting/cvvergara/include/contraction/contractionGraph.hpp:185:15: warning: variable 'inserted' is not initialized [cppcoreguidelines-init-variables]
185 | bool inserted;
| ^
| = false
/home/vicky/pgrouting/pgrouting/cvvergara/include/contraction/contractionGraph.hpp:398:14: warning: variable 'found_e' is not initialized [cppcoreguidelines-init-variables]
398 | bool found_e;
| ^
| = false
/home/vicky/pgrouting/pgrouting/cvvergara/include/contraction/contractionGraph.hpp:426:18: warning: variable 'inserted' is not initialized [cppcoreguidelines-init-variables]
426 | bool inserted;
| ^
| = false
/home/vicky/pgrouting/pgrouting/cvvergara/include/contraction/contractionGraph.hpp:437:17: warning: variable 'p_max' is not initialized [cppcoreguidelines-init-variables]
437 | int64_t p_max;
| ^
| = 0
/home/vicky/pgrouting/pgrouting/cvvergara/include/contraction/contractionGraph.hpp:439:14: warning: variable 'found_e' is not initialized [cppcoreguidelines-init-variables]
439 | bool found_e;
| ^
| = false
Please fix
the files under contraction directory
|
Since this cppcoreguidelines, was used multiple times, I am completing the task-4 using another cppcoreguidline, kindly review the other PR, |
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.