Fixes issue #6446 - approx_adv broken and unused in Lazy_exact_nt#9352
Open
RajdeepKushwaha5 wants to merge 1 commit intoCGAL:mainfrom
Open
Fixes issue #6446 - approx_adv broken and unused in Lazy_exact_nt#9352RajdeepKushwaha5 wants to merge 1 commit intoCGAL:mainfrom
approx_adv broken and unused in Lazy_exact_nt#9352RajdeepKushwaha5 wants to merge 1 commit intoCGAL:mainfrom
Conversation
Fixes CGAL#6446. �pprox_adv() accessed his->ptr() which was declared private, causing a compile error. The method is not documented, not tested, and has no callers anywhere in the codebase. Remove it entirely. The intended functionality (obtaining an Interval_nt<false> / Interval_nt_advanced from a Lazy_exact_nt) can be obtained via the existing public �pprox() member inherited from the Lazy base class.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes issue #6446 by removing the broken and unused approx_adv() method from Lazy_exact_nt. The method was never callable due to accessing the private ptr() member of the Lazy base class, was completely undocumented, and had zero callers across the entire codebase.
Changes:
- Removes the uncompilable
approx_adv()method fromLazy_exact_nt(the same functionality is already available via the publicapprox()method inherited fromLazy, which also returnsInterval_nt<false>)
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue #6446 -
approx_advbroken and unused inLazy_exact_ntIssue: #6446
Problem:
Lazy_exact_nt<ET>::approx_adv()(lines 546-547 ofNumber_types/include/CGAL/Lazy_exact_nt.h) accessedthis->ptr()which is a private member of theLazybase class, causing a compile error under any instantiation. The function is not documented, has no tests, and has zero callers across the entire codebase.Fix: Removed the
approx_adv()method entirely. Users who need anInterval_nt_advanced(Interval_nt<false>) from aLazy_exact_ntcan use the existing publicapprox()method inherited from theLazybase class.Files changed:
Number_types/include/CGAL/Lazy_exact_nt.h(-3 lines)