diff --git a/Demo/main.cpp b/Demo/main.cpp index 00a8ad8..f0322ad 100644 --- a/Demo/main.cpp +++ b/Demo/main.cpp @@ -1,6 +1,9 @@ #include #include + +#if defined(WIN32) || defined(_WIN32) || defined(__WIN32) && !defined(__CYGWIN__) #include +#endif #include "../QRCodeLibrary/QRCode.hpp" diff --git a/QRCodeLibrary/Encoder.hpp b/QRCodeLibrary/Encoder.hpp index 44c59c2..7ebda8a 100644 --- a/QRCodeLibrary/Encoder.hpp +++ b/QRCodeLibrary/Encoder.hpp @@ -56,9 +56,9 @@ private: BitArray e; }; -template +template constexpr unsigned upper_index(const array arr, T val) { - unsigned count = arr.size(), s = 0, e, step; + unsigned count = arr.size(), s = 0, e = 0, step = 0; while (count > 0) { step = count / 2; diff --git a/QRCodeLibrary/Method.cpp b/QRCodeLibrary/Method.cpp index 14fbc96..42ece72 100644 --- a/QRCodeLibrary/Method.cpp +++ b/QRCodeLibrary/Method.cpp @@ -1,5 +1,7 @@ #include "pch.h" +#include + #include "Method.hpp" #include "Tables.hpp" diff --git a/QRCodeLibrary/method.hpp b/QRCodeLibrary/Method.hpp similarity index 100% rename from QRCodeLibrary/method.hpp rename to QRCodeLibrary/Method.hpp