Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix compiler warnings for -Wenum-float-conversion (#1284)
無名列挙型の値がdobule型の変数と算術演算しているとコンパイラーの警告で 指摘されたためconstexpr定数に変更して修正します。 clang-17のレポート ``` src/image/imageadmin.cpp:978:41: warning: compound assignment of floating-point type 'double' from enumeration type '(unnamed enum at ../src/global.h:10:1)' [-Wenum-float-conversion] 978 | if( scroll == SCROLL_LEFT ) pos -= ICON_SIZE; | ~~~ ^ ~~~~~~~~~ src/image/imageadmin.cpp:979:18: warning: compound assignment of floating-point type 'double' from enumeration type '(unnamed enum at ../src/global.h:10:1)' [-Wenum-float-conversion] 979 | else pos += ICON_SIZE; | ~~~ ^ ~~~~~~~~~ src/article/drawareabase.cpp:2305:47: warning: arithmetic between enumeration type '(unnamed enum at /home/ma8ma/var/repos/JDim/weverythingclang17-unity/../src/article/drawareabase.cpp:57:1)' and floating-point type 'double' [-Wenum-float-conversion] 2305 | constexpr const double r = AUTOSCR_CIRCLE / 2.0; | ~~~~~~~~~~~~~~ ^ ~~~ ```
- Loading branch information