shithub: rgbds

Download patch

ref: 44124319a6f303893dd3c41f31d2c9f6ffaee3e0
parent: 462fd7539cf4a24897571738e0b453e65bdfc8c1
author: ISSOtm <eldredhabert0@gmail.com>
date: Wed Dec 9 11:00:22 EST 2020

Work around old Bison versions not forward-declaring `yyparse`

Notably, macOS still ships 2.3 (from 2008)...
Should fix #214

--- a/src/asm/main.c
+++ b/src/asm/main.c
@@ -34,6 +34,10 @@
 #include "helpers.h"
 #include "version.h"
 
+// Old Bison versions (confirmed for 2.3) do not forward-declare `yyparse` in the generated header
+// Unfortunately, macOS still ships 2.3, which is from 2008...
+int yyparse(void);
+
 size_t cldefines_index;
 size_t cldefines_numindices;
 size_t cldefines_bufsize;