# HG changeset patch # User Paul Boddie # Date 1488903556 -3600 # Node ID 374ccaa7be71efc510fca4dd22a48edb1c0d1719 # Parent 932a6b2491990c7e80352c95c478a22a54b836ee Make debugging override optimisation correctly. Note that optimisation currently breaks the range and set tests. diff -r 932a6b249199 -r 374ccaa7be71 generator.py --- a/generator.py Tue Mar 07 17:13:46 2017 +0100 +++ b/generator.py Tue Mar 07 17:19:16 2017 +0100 @@ -441,6 +441,8 @@ try: if debug: print >>f_options, "CFLAGS = -g" + else: + print >>f_options, "CFLAGS = -O2" if gc_sections: print >>f_options, "include gc_sections.mk" diff -r 932a6b249199 -r 374ccaa7be71 templates/Makefile --- a/templates/Makefile Tue Mar 07 17:13:46 2017 +0100 +++ b/templates/Makefile Tue Mar 07 17:19:16 2017 +0100 @@ -4,7 +4,7 @@ SRC += exceptions.c main.c ops.c progops.c progtypes.c OBJ = $(SRC:.c=.o) -CFLAGS += -Wall -I. -finput-charset=UTF-8 -O2 +CFLAGS += -Wall -I. -finput-charset=UTF-8 LDFLAGS += -lm -lgc ifdef ARCH