shithub: rgbds

Download patch

ref: fb5e768142f85cfef6591627b217d49bb1af903b
parent: ecf44c784c27928457e740b80096a03bc4e2ec86
author: ISSOtm <[email protected]>
date: Fri Mar 20 12:37:10 EDT 2020

Prevent using `LOAD` blocks outide code sections

--- a/src/asm/section.c
+++ b/src/asm/section.c
@@ -206,6 +206,8 @@
 void out_SetLoadSection(char const *name, uint32_t type, int32_t org,
 			struct SectionSpec const *attributes)
 {
+	checkcodesection();
+
 	if (currentLoadSection)
 		fatalerror("`LOAD` blocks cannot be nested");