Skip to content

Commit

Permalink
Merge pull request #11 from leapmotion/bug-badoverload
Browse files Browse the repository at this point in the history
Cannot overload nullptr_t with int, looser throw specification
  • Loading branch information
gtremper committed Jul 31, 2014
2 parents b83755d + 7c6f539 commit 888203c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions contrib/json11/json11.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -242,11 +242,11 @@ const Json & static_null() {
* Constructors
*/

Json::Json() JSON11_NOEXCEPT : m_ptr(statics().null) {}
Json::Json(std::nullptr_t) JSON11_NOEXCEPT : m_ptr(statics().null) {}
Json::Json() JSON11_NOEXCEPT : m_ptr(statics().null) {}
Json::Json(std::nullptr_t) : m_ptr(statics().null) {}
Json::Json(double value) : m_ptr(make_shared<JsonDouble>(value)) {}
Json::Json(int value) : m_ptr(make_shared<JsonInt>(value)) {}
Json::Json(bool value) : m_ptr(value ? statics().t : statics().f) {}
Json::Json(bool value) JSON11_NOEXCEPT : m_ptr(value ? statics().t : statics().f) {}
Json::Json(const string &value) : m_ptr(make_shared<JsonString>(value)) {}
Json::Json(string &&value) : m_ptr(make_shared<JsonString>(move(value))) {}
Json::Json(const char * value) : m_ptr(make_shared<JsonString>(value)) {}
Expand Down
6 changes: 3 additions & 3 deletions contrib/json11/json11.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,11 @@ class Json final {
typedef std::map<std::string, Json> object;

// Constructors for the various types of JSON value.
Json() JSON11_NOEXCEPT; // NUL
Json(std::nullptr_t) JSON11_NOEXCEPT; // NUL
Json() JSON11_NOEXCEPT; // NUL
Json(std::nullptr_t); // NUL
Json(double value); // NUMBER
Json(int value); // NUMBER
Json(bool value); // BOOL
Json(bool value) JSON11_NOEXCEPT; // BOOL
Json(const std::string &value); // STRING
Json(std::string &&value); // STRING
Json(const char * value); // STRING
Expand Down

0 comments on commit 888203c

Please sign in to comment.