Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

Conditionally define __unused.

Fixes compiler warning '"__unused" redefined' on OS X.

Reported by Saúl Ibarra Corretgé.
  • Loading branch information...
bnoordhuis committed Mar 30, 2012
1 parent 4360018 commit 1ab8f5a3c5697013c8cf00bfefa896e005f38aff
Showing with 6 additions and 4 deletions.
  1. +6 −4 include/uv-private/tree.h
@@ -26,10 +26,12 @@
#ifndef UV_TREE_H_
#define UV_TREE_H_

#if __GNUC__
# define __unused __attribute__((unused))
#else
# define __unused
#ifndef __unused
# if __GNUC__
# define __unused __attribute__((unused))
# else
# define __unused
# endif
#endif

/*

0 comments on commit 1ab8f5a

Please sign in to comment.
You can’t perform that action at this time.