From a6b94ebba240d9263b2e328a13abc9d800bde660 Mon Sep 17 00:00:00 2001 From: Kugel Fuhr <98353208+kugelfuhr@users.noreply.github.com> Date: Thu, 12 Jun 2025 21:50:20 +0200 Subject: [PATCH] Implement -dD, -dM and -dN command line switches to output macro definitions. --- doc/cc65.sgml | 23 +++++++++++ src/cc65/compile.c | 11 +++++ src/cc65/global.c | 5 ++- src/cc65/global.h | 5 ++- src/cc65/macrotab.c | 99 ++++++++++++++++++++++++++++++++++++++++++--- src/cc65/macrotab.h | 16 ++++++-- src/cc65/main.c | 31 +++++++++++++- src/cc65/preproc.c | 2 +- 8 files changed, 179 insertions(+), 13 deletions(-) diff --git a/doc/cc65.sgml b/doc/cc65.sgml index 55b84ed5c..b53007e46 100644 --- a/doc/cc65.sgml +++ b/doc/cc65.sgml @@ -63,6 +63,9 @@ Short options: -V Print the compiler version number -W [-+]warning[,...] Control warnings ('-' disables, '+' enables) -d Debug mode + -dD Output all macro definitions (needs -E) + -dM Output user defined macros (needs -E) + -dN Output user defined macro names (needs -E) -g Add debug info to object file -h Help (this text) -j Default characters are signed @@ -199,6 +202,26 @@ Here is a description of all the command line options: Enables debug mode, for debugging the behavior of cc65. +