Skip to content

Commit

Permalink
Fix C++11 build (again)
Browse files Browse the repository at this point in the history
  • Loading branch information
Edd12321 committed Sep 2, 2023
1 parent 667ff73 commit e57d2a0
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,18 @@
k = 0; \
} while (0)

namespace std
{
#ifndef __cpp_lib_string_view
namespace std
{
typedef std::string const& string_view;
};
#endif
#ifndef __cpp_lib_make_unique
// Thanks, stackoverflow!
template<typename T, typename... Var> std::unique_ptr<T>
make_unique(Var&&... v)
{ return std::unique_ptr<T>(new T(std::forward<Var>(v)...)); }
#endif
};

class Array;
class WordList;
Expand Down

0 comments on commit e57d2a0

Please sign in to comment.