Don't forget to check out our docs for more details on the updated functionality!
Please welcome two new contributors, @Rangi42 and @dannye! Rangi did more than half of the work on this release—our biggest one yet!
Deprecated:
_PIwasn't useful, so it's deprecated nowPRINTT,PRINTV,PRINTFandPRINTIare obsoleted by the newPRINT/PRINTLNandSTRFMT
Known issues:
- An
ELIFcondition right after a takenIF/ELIFblock is still evaluated (#764) - Regression: Expanding
recurse EQUS "recurse"hangs rgbasm (#696)
Added:
- New
MACRO <name>syntax for defining macros! The old syntax will still be supported for a couple versions, but will eventually be phased out. - RGBFIX can now be used in pipelines! Example:
rgblink -o - obj/header.o obj/game.o | rgbfix -v -p0xFF >bin/dinos_with_lasers.gb {symbol}interpolation outside of strings, similar to macro args (differs from the pre-0.4.2 behavior!!)- More complex format specifiers are now allowed in symbol interpolations
- Anonymous labels
- Environment var
SOURCE_DATE_EPOCHcan be used for reproducible builds - Underscores can be used in numeric literals (e.g.
%1101_1110_1010_1101) - New string functions
STRRIN,STRRPLandSTRFMT \#to get all of a macro's arguments"""Multi-line string literals"""FORblocks!BREAKexitsREPTandFORearlyPOWandLOGfixed-point functions**exponent operator (for integers)REDEFto redefineEQUSmuch more convenientlyRLhas been reintroduced alongsideRBandRWLOAD UNIONandLOAD FRAGMENT
Changed:
- Syntax errors will now be more verbose! Be careful that YMMV depending on the Bison version that RGBASM was compiled with.
- Syntax errors are no longer fatal! If a line contains a syntax error, RGBASM will discard it and attempt to continue with the next line.
- RGBFIX's
-mnow accepts MBC names - More symbols will be available in the
.symand.mapfiles - Slack totals are now included in the
.mapfiles - Interaction of quotes and macro args should be more intuitive
dscan now repeat patterns, not just a single byte- Global labels can now be indented, not just local ones
- Trailing commas are allowed for most "list" directives, such as
db STRCATcan now concat any amount of stringsLOADblocks cannot create ROM sections anymore (#576)ROUND,FLOORandCEILfixed-point builtins were present but undocumented- Macro arguments can now be shifted by a negative amount, "un-shifting" them
- Macro args can now be empty, though this causes a warning
Removed:
GLOBALandXDEFkeywords (deprecated aliases ofEXPORT)- Colon-less global labels
*-commentsrgbasm -vno longer prints the elapsed time (usetimefor that)
Fixed:
- Enabled several optimizations that should improve performance, especially RGBASM
SECTION FRAGMENTs now respect their constraints at their respective beginnings, not as a whole- Line numbers could be incorrect on Windows
- RGBASM will explicitly reject more than one input file, rather than silently ignore them
- Macro args weren't ignored in block comments
- Fixed a rare crash with unterminated
REPT/FORblocks - Fixed incorrect handling of text after
MACRO,ENDMandENDRtokens - Can't start a new section if another with the same name has been
PUSHS'd ds N, @could produce incorrect resultsELIFandELSEwere allowed afterELSE.was treated as a label- Performance of
gbdiff.bashimproved significantly - Defining an
EQUSafter referencing it is now an error - Passing
-tand-Oto RGBLINK generated an output too large
Attention downstream packagers
The yacc dependency has been changed to GNU Bison! Our Makefile relies on bison -V to conditionally enable some features (src/check_bison_ver.sh) and our CMakeLists on the Bison CMake package, so both should be compatible with many versions, at least 3.0 (3.0.4 successfully tested). Please report breakage in our issue tracker.