scc

Simple C99 Compiler
Log | Files | Refs | README | LICENSE

commit 5e2de268e633d028c222d3c2bd18a1b3f947502b
parent 8a71476cce84016b86892eeae18341232a5f612c
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date:   Mon, 24 Aug 2015 21:56:28 +0200

Use more logical values for & operator in the IR

Take address of a lvalue was using the letter 'a', and the
logical and was using y, but this value was also used by
the return statement. This change makes logical and 'a'
and take address '\'' (it will like to lisper)

Diffstat:
cc1/code.c | 4++--
cc1/tests/test001.c | 2+-
2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/cc1/code.c b/cc1/code.c @@ -46,10 +46,10 @@ char *optxt[] = { [OA_AND] = ":&", [OA_XOR] = ":^", [OA_OR] = ":|", - [OADDR] = "a", + [OADDR] = "'", [ONEG] = "_", [OCPL] = "~", - [OAND] = "y", + [OAND] = "a", [OOR] = "o", [OASK] = "?", [OCOMMA] = ",", diff --git a/cc1/tests/test001.c b/cc1/tests/test001.c @@ -8,7 +8,7 @@ F1 G2 F1 main { - - X1 "68656C6C6F20776F726C640A aP pP cI + X1 "68656C6C6F20776F726C640A 'P pP cI yI #I0 } */