Mangle a conversion function's target type once - #433
Open
philipcraig wants to merge 1 commit into
Open
philipcraig wants to merge 1 commit into
philipcraig wants to merge 1 commit into
Conversation
A conversion function's name atom is cv<type>, so appending the return type repeated the target. Omit the return type for conversion functions, as Itanium does. Other functions keep it. Reword the unsupported-type error, which also fires for a conversion target and not only for a parameter.
philipcraig
marked this pull request as ready for review
September 18, 2026 22:27
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #433 +/- ##
==========================================
+ Coverage 81.21% 81.23% +0.01%
==========================================
Files 16 16
Lines 1299 1300 +1
Branches 214 214
==========================================
+ Hits 1055 1056 +1
Misses 45 45
Partials 199 199
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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.
Closes #429.
mangle()no longer appends the return type for a conversion function, whosecv<type>atom already carries it, as in Itanium.operator bool() constbecomesfn_NKcvbE(wasfn_NKcvbEb), and astd::stringtarget is mangled once.Other functions keep their return type. The header documents it as what keeps
get() conston two interfaces apart when they differ only in return type, andDistinguishesMembersDifferingOnlyByReturnTypepins that, so dropping it everywhere is a separate decision.The "unsupported parameter type" error becomes "unsupported type", since it also fires for a conversion target.