Skip to content

Comments

Foundation Classes, CSLib - Migrate local variables from TColStd_Array1OfReal to math_Vector#54

Open
dpasukhi wants to merge 3 commits intomasterfrom
claude/migrate-tcolstd-to-math-vector-011CUztM1PygNaUq4xjUPUda
Open

Foundation Classes, CSLib - Migrate local variables from TColStd_Array1OfReal to math_Vector#54
dpasukhi wants to merge 3 commits intomasterfrom
claude/migrate-tcolstd-to-math-vector-011CUztM1PygNaUq4xjUPUda

Conversation

@dpasukhi
Copy link
Owner

This commit migrates local variables in CSLib.cxx from TColStd_Array1OfReal to math_Vector:

  • Ratio array (local variable in Normal function)
  • Sol0 array (local variable in Normal function)

Both variables are strictly local and not returned outside their scope, making the migration safe. Member variables in CSLib_Class2d and CSLib_NormalPolyDef remain unchanged as per requirements.

Updated includes:

  • Added: math_Vector.hxx
  • Removed: TColStd_Array1OfReal.hxx (no longer needed in this file)

…y1OfReal to math_Vector

This commit migrates local variables in CSLib.cxx from TColStd_Array1OfReal to math_Vector:
- Ratio array (local variable in Normal function)
- Sol0 array (local variable in Normal function)

Both variables are strictly local and not returned outside their scope,
making the migration safe. Member variables in CSLib_Class2d and
CSLib_NormalPolyDef remain unchanged as per requirements.

Updated includes:
- Added: math_Vector.hxx
- Removed: TColStd_Array1OfReal.hxx (no longer needed in this file)
…OfReal to math_Vector

This commit migrates CSLib_NormalPolyDef to use math_Vector instead of
TColStd_Array1OfReal. This migration was necessary because the class is
instantiated in CSLib.cxx with a math_Vector parameter (after previous migration).

Changes:
- Constructor parameter: const TColStd_Array1OfReal& -> const math_Vector&
- Member variable myTABli: TColStd_Array1OfReal -> math_Vector
- Updated includes: replaced TColStd_Array1OfReal.hxx with math_Vector.hxx

The member variable is private and never exposed outside the class,
making the migration safe. The constructor is only called once in CSLib.cxx.
@coderabbitai
Copy link

coderabbitai bot commented Nov 10, 2025

Warning

Rate limit exceeded

@dpasukhi has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 4 minutes and 20 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📥 Commits

Reviewing files that changed from the base of the PR and between c4e23d0 and 9318485.

📒 Files selected for processing (2)
  • src/FoundationClasses/TKMath/CSLib/CSLib_Class2d.cxx (1 hunks)
  • src/FoundationClasses/TKMath/CSLib/CSLib_Class2d.hxx (2 hunks)

Walkthrough

The PR replaces TColStd_Array1OfReal with math_Vector across CSLib sources. It updates includes and type usages, changes CSLib_NormalPolyDef constructor signature and its private member myTABli to math_Vector, and converts local/handled array variables (e.g., in CSLib.cxx and CSLib_Class2d.*) to math_Vector. Control flow and error handling are unchanged.

Pre-merge checks

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: migrating local variables in CSLib from TColStd_Array1OfReal to math_Vector, which aligns with the changeset.
Description check ✅ Passed The description is directly related to the changeset, explaining the migration of local variables and the include changes made.

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

… to math_Vector

This commit migrates CSLib_Class2d to use math_Vector instead of
TColStd_Array1OfReal for its internal coordinate storage.

Changes:
- Member variables MyPnts2dX, MyPnts2dY: NCollection_Handle<TColStd_Array1OfReal> -> NCollection_Handle<math_Vector>
- Allocation in Init(): new TColStd_Array1OfReal -> new math_Vector
- Updated includes: replaced TColStd_Array1OfReal.hxx with math_Vector.hxx

The member variables are private and never exposed through the public interface.
All public methods work with gp_Pnt2d and return Standard_Integer, making this
migration completely safe and transparent to users of the class.

With this commit, CSLib directory is now completely migrated - all
TColStd_Array1OfReal usage has been replaced with math_Vector.
@dpasukhi dpasukhi force-pushed the claude/migrate-tcolstd-to-math-vector-011CUztM1PygNaUq4xjUPUda branch from c4e23d0 to 9318485 Compare November 10, 2025 22:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants