Skip to content

Commit

Permalink
fix: undefine nil macro to prevent conflicting name
Browse files Browse the repository at this point in the history
  • Loading branch information
threeal committed Jan 4, 2024
1 parent 25c18ca commit 1a28ac5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion include/errors/error.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
#include <string_view>
#include <utility>

// Prevent conflicting name with nil macros in Objective-C.
// See: https://github.com/threeal/errors-cpp/issues/128
#undef nil

namespace errors {

/**
Expand Down Expand Up @@ -78,7 +82,6 @@ class [[nodiscard]] Error {
*/
Error make(std::string_view msg);


/**
* @brief Gets a constant reference of an empty error.
* @return A constant reference of an empty error.
Expand Down

0 comments on commit 1a28ac5

Please # to comment.