[PATCH 6/8] pre-define __unix__ and friends

[email protected]
Newsgroups org.kernel.vger.smatch
Message-ID <[email protected]>
From: John Levon <[email protected]>

GCC defines these, so should we.

Signed-off-by: John Levon <[email protected]>
Signed-off-by: Luc Van Oostenryck <[email protected]>
---
 lib.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/lib.c b/lib.c
index c85ce247..40e81ae2 100644
--- a/lib.c
+++ b/lib.c
@@ -1394,6 +1394,13 @@ static void predefined_macros(void)
 		break;
 	}
 
+#if defined(__unix__)
+	predefine("__unix__", 1, "1");
+	predefine("__unix", 1, "1");
+	predefine_nostd("unix");
+#endif
+
+
 #if defined(__sun__) || defined(__sun)
 	predefine("__sun__", 1, "1");
 	predefine("__sun", 1, "1");
-- 
2.23.0
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.