From aa96b78f4833c577e43d7a127da92148a62ba29e Mon Sep 17 00:00:00 2001 From: doomtube Date: Sun, 11 Jan 2026 17:23:40 -0500 Subject: [PATCH] Fix linker error: use constexpr for static class constants static const int members need explicit definitions when ODR-used, but static constexpr int are implicitly inline in C++17. Co-Authored-By: Claude Opus 4.5 --- backend/src/controllers/PyramidController.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/src/controllers/PyramidController.h b/backend/src/controllers/PyramidController.h index 93d22a3..410767b 100644 --- a/backend/src/controllers/PyramidController.h +++ b/backend/src/controllers/PyramidController.h @@ -57,8 +57,8 @@ public: const std::string &y); private: - static const int DAILY_PIXEL_LIMIT = 1000; - static const int FACE_SIZE = 200; + static constexpr int DAILY_PIXEL_LIMIT = 1000; + static constexpr int FACE_SIZE = 200; bool isValidPixelPosition(int faceId, int x, int y); bool isValidColor(const std::string &color);