summaryrefslogtreecommitdiff
path: root/tests/headers/iso646.c
blob: 258b8fcc41467d7b37df9766c336eee9cd29162e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
// https://pubs.opengroup.org/onlinepubs/9799919799/basedefs/iso646.h.html

#include "core.h"

#include <iso646.h>

#define STRINGIFY_(x) #x
#define STRINGIFY(x)  STRINGIFY_(x)

TEST(iso646_h)
{
	MACRO_VALUE_STRING(STRINGIFY(and), "&&");
	MACRO_VALUE_STRING(STRINGIFY(and_eq), "&=");
	MACRO_VALUE_STRING(STRINGIFY(bitand), "&");
	MACRO_VALUE_STRING(STRINGIFY(bitor), "|");
	MACRO_VALUE_STRING(STRINGIFY(compl), "~");
	MACRO_VALUE_STRING(STRINGIFY(not), "!");
	MACRO_VALUE_STRING(STRINGIFY(not_eq), "!=");
	MACRO_VALUE_STRING(STRINGIFY(or), "||");
	MACRO_VALUE_STRING(STRINGIFY(or_eq), "|=");
	MACRO_VALUE_STRING(STRINGIFY(xor), "^");
	MACRO_VALUE_STRING(STRINGIFY(xor_eq), "^=");
}