Skip to content

Conversation

mosra
Copy link
Owner

@mosra mosra commented Dec 29, 2022

In addition to the implicit conversion. Desired use case is for types where we still want to have a conversion for convenience purposes, but the conversion is potentially dangerous (such as Magnum's Vector3i -> Size3D).

Fails to compile on MSVC 2019 and earlier due to the compiler thinking the two constructors / conversion operators are the same. 2022 works; all other compilers including GCC 4.8 work as well. The seemingly-conflicting overload is based on the answers in https://stackoverflow.com/questions/14600201/why-should-i-avoid-stdenable-if-in-function-signatures, there isn't any indication of MSVC being the odd one out.

In addition to the implicit conversion. Desired use case is for types
where we still want to have a conversion for convenience purposes, but
the conversion is potentially dangerous (such as Magnum's Vector3i ->
Size3D).
Copy link

codecov bot commented Jul 17, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.97%. Comparing base (90e0d7d) to head (4d7fa4e).
Report is 831 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #162   +/-   ##
=======================================
  Coverage   97.97%   97.97%           
=======================================
  Files         136      136           
  Lines       11086    11089    +3     
=======================================
+ Hits        10861    10864    +3     
  Misses        225      225           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: TODO
Development

Successfully merging this pull request may close these issues.

1 participant