Skip to content

Commit 1a28ac5

Browse files
committed
fix: undefine nil macro to prevent conflicting name
1 parent 25c18ca commit 1a28ac5

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

include/errors/error.hpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@
66
#include <string_view>
77
#include <utility>
88

9+
// Prevent conflicting name with nil macros in Objective-C.
10+
// See: https://github.com/threeal/errors-cpp/issues/128
11+
#undef nil
12+
913
namespace errors {
1014

1115
/**
@@ -78,7 +82,6 @@ class [[nodiscard]] Error {
7882
*/
7983
Error make(std::string_view msg);
8084

81-
8285
/**
8386
* @brief Gets a constant reference of an empty error.
8487
* @return A constant reference of an empty error.

0 commit comments

Comments
 (0)