mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 10:12:06 +00:00
Implement INCLUDE_ONCE directive (#1481)
Identify files by (device, inode), not by path, so that symlinks, relative paths, case-insensitive paths, or other edge cases do not result in double includes.
This commit is contained in:
12
man/rgbasm.5
12
man/rgbasm.5
@@ -2158,7 +2158,17 @@ calls infinitely (or until you run out of memory, whichever comes first).
|
||||
INCLUDE "irq.inc"
|
||||
.Ed
|
||||
.Pp
|
||||
You may also implicitly
|
||||
You may also ensure a file only gets included once by using
|
||||
.Ic INCLUDE_ONCE
|
||||
instead of
|
||||
.Ic INCLUDE .
|
||||
This will skip including a file if it has already been included before (with
|
||||
.Ic INCLUDE ,
|
||||
.Ic INCLUDE_ONCE ,
|
||||
or
|
||||
.Fl P ) .
|
||||
.Pp
|
||||
You can implicitly
|
||||
.Ic INCLUDE
|
||||
a file before the source file with the
|
||||
.Fl P
|
||||
|
||||
Reference in New Issue
Block a user