Open nmattia opened 5 months ago
Hi @nmattia I see the issue. We will try to fix it! Just suppressing the warning is not great. The issue lies in the fact that NilType is instantiated with enum
an then not used anyway. We have a more systematic solution using SFINAE in mind. Thank you for pointing this out!
No worries! I have very little C++ experience but let me know if I can help!
Thank you @lukasmatena & @SachCZ !
We had to revert the fix.
We had to revert the fix.
Hi, can you explain why you had to revert it ? Were there some unexpected side effects ?
Hello @Salamandar, yes. I thought the repair commit should not change any runtime behavior, but for some currently unknown reason, it broke the "scale" default values of SLA print objectes in platter. There are multiple possible explanations. Most probably the commit actually broke some runtime behavior without me understanding how. Other less probable possibility is that there is already some UB, but it is currently masked/mitigated somehow.
Description of the bug
I'm getting build errors:
This seems to be related to this template which uses the enum's underlying type's max value for "nil", which the compiler does not like:
I am building with this version of clang:
The issue can be worked around by suppressing the warning:
See also the discussion on the clang tracker, which plans on making this a hard error: https://github.com/llvm/llvm-project/issues/59036
I'm happy to do some testing and submit a PR, but not sure what the best way to fix this is! Thoughts?
Version of PrusaSlicer
Commit: https://github.com/prusa3d/PrusaSlicer/commit/cfbbd443b15a96c2e9bf9cd4670b4dbfe37ec04d
Operating system
macOS 14.4