Skip to content

Avoid warning in launder_cast#62

Merged
igaztanaga merged 1 commit intoboostorg:developfrom
Flamefire:patch-1
Nov 2, 2025
Merged

Avoid warning in launder_cast#62
igaztanaga merged 1 commit intoboostorg:developfrom
Flamefire:patch-1

Conversation

@Flamefire
Copy link
Contributor

This fixes a warning for launder_cast<char*>(ptr) as it adds const in the argument and then C-casts it away which triggers -Wcast-qual

I just got a report from a user running into this warning.

I'm using the approach from #61 which looks sane

This fixes a warning for `launder_cast<char*>(ptr)` as it adds `const` in the argument and then C-casts it away which triggers `-Wcast-qual`
@igaztanaga igaztanaga merged commit f0dbbd6 into boostorg:develop Nov 2, 2025
46 checks passed
@igaztanaga
Copy link
Member

Many thanks!

@Flamefire Flamefire deleted the patch-1 branch November 2, 2025 21: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.

launder_cast triggers warning about dropping const and volatile qualifiers

2 participants