diff options
-rw-r--r-- | include/djinterop/optional.hpp | 7 | ||||
-rw-r--r-- | src/djinterop/enginelibrary/el_database_impl.cpp | 2 |
2 files changed, 6 insertions, 3 deletions
diff --git a/include/djinterop/optional.hpp b/include/djinterop/optional.hpp index 6795913..baf4773 100644 --- a/include/djinterop/optional.hpp +++ b/include/djinterop/optional.hpp @@ -21,7 +21,7 @@ #include <djinterop/config.hpp> -#ifdef DJINTEROP_STD_OPTIONAL +#if defined DJINTEROP_STD_OPTIONAL #include <optional> @@ -39,7 +39,8 @@ using std::optional; } // namespace stdx } // namespace djinterop -#elif DJINTEROP_STD_EXPERIMENTAL_OPTIONAL +#elif defined DJINTEROP_STD_EXPERIMENTAL_OPTIONAL + #include <experimental/optional> namespace djinterop @@ -57,7 +58,9 @@ using std::experimental::optional; } // namespace djinterop #else + #error This library requires support for optional<T>, but none was found + #endif #endif // DJINTEROP_OPTIONAL_HPP diff --git a/src/djinterop/enginelibrary/el_database_impl.cpp b/src/djinterop/enginelibrary/el_database_impl.cpp index ac723d9..bb82e24 100644 --- a/src/djinterop/enginelibrary/el_database_impl.cpp +++ b/src/djinterop/enginelibrary/el_database_impl.cpp @@ -178,7 +178,7 @@ track el_database_impl::create_track(std::string relative_path) case 15: case 16: // Always 1 to our knowledge - text = "1"; + text = std::string{"1"}; break; } metadata_str_inserter << id << type << text; |