Removed throw_stub_exception, not used anymore, use nullptr in some p…#2403
Conversation
…laces
* TAO/orbsvcs/orbsvcs/HTIOP/HTIOP_Connector_Impl.h:
* TAO/tao/CDR.cpp:
* TAO/tao/CDR.h:
* TAO/tao/Connector_Impl.h:
WalkthroughThe changes update default pointer and boolean parameter values in several constructors and methods from legacy zero literals ( Changes
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms (20)
✨ Finishing Touches
🧪 Generate Unit Tests
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (1)
TAO/tao/CDR.h (1)
355-410: Mixed use of0vs.nullptr– please unify for readabilityWithin the same
TAO_InputCDRclass, some constructors now usenullptr(👍 lines 355, 365, 374, 401-405, 408-410) while the earlier ones (e.g. lines 326-340 & 343-346, unchanged in this diff) still default to literal0.Keeping two styles side-by-side hampers grep-ability and invites accidental re-introductions of
0elsewhere. Recommend converting the remaining pointer defaults as well (and, ideally, doing the same pass for theTAO_OutputCDRconstructors that still use0).Example patch for the first two untouched ctors:
- TAO_InputCDR (const char* buf, - size_t bufsiz, - int byte_order = ACE_CDR_BYTE_ORDER, - ACE_CDR::Octet major_version = TAO_DEF_GIOP_MAJOR, - ACE_CDR::Octet minor_version = TAO_DEF_GIOP_MINOR, - TAO_ORB_Core* orb_core = 0); + TAO_InputCDR (const char* buf, + size_t bufsiz, + int byte_order = ACE_CDR_BYTE_ORDER, + ACE_CDR::Octet major_version = TAO_DEF_GIOP_MAJOR, + ACE_CDR::Octet minor_version = TAO_DEF_GIOP_MINOR, + TAO_ORB_Core* orb_core = nullptr); - TAO_InputCDR (size_t bufsiz, - int byte_order = ACE_CDR_BYTE_ORDER, - ACE_CDR::Octet major_version = TAO_DEF_GIOP_MAJOR, - ACE_CDR::Octet minor_version = TAO_DEF_GIOP_MINOR, - TAO_ORB_Core* orb_core = 0); + TAO_InputCDR (size_t bufsiz, + int byte_order = ACE_CDR_BYTE_ORDER, + ACE_CDR::Octet major_version = TAO_DEF_GIOP_MAJOR, + ACE_CDR::Octet minor_version = TAO_DEF_GIOP_MINOR, + TAO_ORB_Core* orb_core = nullptr);Applying the same pattern throughout keeps the header internally consistent and future-proof.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (4)
TAO/orbsvcs/orbsvcs/HTIOP/HTIOP_Connector_Impl.h(1 hunks)TAO/tao/CDR.cpp(0 hunks)TAO/tao/CDR.h(6 hunks)TAO/tao/Connector_Impl.h(1 hunks)
💤 Files with no reviewable changes (1)
- TAO/tao/CDR.cpp
⏰ Context from checks skipped due to timeout of 90000ms (21)
- GitHub Check: Codacy Static Code Analysis
- GitHub Check: ubuntu-24.04 clang++-14
- GitHub Check: ubuntu-24.04 g++
- GitHub Check: ubuntu-24.04 g++-13
- GitHub Check: ubuntu-22.04 g++-9
- GitHub Check: ubuntu-24.04 g++-11
- GitHub Check: ubuntu-24.04 g++-12
- GitHub Check: VS2022Debug64Cxx20
- GitHub Check: VS2022WChar
- GitHub Check: VS2022Debug32
- GitHub Check: VS2022Debug64Cxx17
- GitHub Check: VS2022Release64
- GitHub Check: VS2022WChar
- GitHub Check: VS2022Debug64
- GitHub Check: VS2022Release32
- GitHub Check: MINGW64-gcc
- GitHub Check: alpine-3.18
- GitHub Check: macos-13-C++
- GitHub Check: ubuntu-22.04 g++-12
- GitHub Check: macos-14-C++
- GitHub Check: windows-2022 vs2022
🔇 Additional comments (3)
TAO/tao/Connector_Impl.h (1)
48-49: Consistent use ofnullptris a welcome modernizationSwitching the default pointer arguments from the legacy literal
0to the C++11‐stylenullptrimproves clarity and removes implicit integer-to-pointer conversions. No other issues spotted here.TAO/orbsvcs/orbsvcs/HTIOP/HTIOP_Connector_Impl.h (1)
55-58: Good move to explicitnullptr/falsedefaultsThe updated defaults remove the old “magic zero” idiom for both pointers and boolean flags, making call-sites less error-prone. Looks correct and fully backwards compatible.
TAO/tao/CDR.h (1)
421-421: Minor nit – function signature wrap
clr_mb_flags()is now on a single line; no behavioural change, and the compact form improves readability.
* TAO/tao/CDR.h:
…laces
Summary by CodeRabbit
Refactor
nullptrandfalseinstead of0).Bug Fixes