From 27e77f6ca6872c8d332c2e153773ca226d69fb64 Mon Sep 17 00:00:00 2001 From: Michael Forney Date: Sun, 17 Feb 2019 17:03:01 -0800 Subject: Make enum types compatible with their corresponding integer type (int) --- tests/compatible-enum-types.c | 3 +++ tests/compatible-enum-types.qbe | 1 + 2 files changed, 4 insertions(+) create mode 100644 tests/compatible-enum-types.c create mode 100644 tests/compatible-enum-types.qbe (limited to 'tests') diff --git a/tests/compatible-enum-types.c b/tests/compatible-enum-types.c new file mode 100644 index 0000000..e320966 --- /dev/null +++ b/tests/compatible-enum-types.c @@ -0,0 +1,3 @@ +enum E {A = -1, B}; +enum E x; +int x; diff --git a/tests/compatible-enum-types.qbe b/tests/compatible-enum-types.qbe new file mode 100644 index 0000000..7cf0e40 --- /dev/null +++ b/tests/compatible-enum-types.qbe @@ -0,0 +1 @@ +export data $x = align 4 { z 4 } -- cgit v1.2.3