diff lwasm/list.c @ 474:74d0c394666e

Add "noexpandcond" pragma (cleans up listings) This pragma will suppress listing of conditionals and any statements that appear within a false conditional block.
author William Astle <lost@l-w.ca>
date Fri, 02 Nov 2018 21:07:50 -0600
parents 7d6eacd87370
children 40c32a0af8c8
line wrap: on
line diff
--- a/lwasm/list.c	Thu Nov 01 23:07:03 2018 -0600
+++ b/lwasm/list.c	Fri Nov 02 21:07:50 2018 -0600
@@ -136,6 +136,8 @@
 				memmove(obytes, cl -> output, cl -> outputl);
 			}
 		}
+		if (cl -> hidecond && CURPRAGMA(cl, PRAGMA_NOEXPANDCOND))
+			continue;
 		if ((cl -> len < 1 && cl -> dlen < 1) && obytelen < 1 && (cl -> symset == 1 || cl -> sym == NULL) )
 		{
 			if (cl -> soff >= 0)