comparison lwasm/pseudo.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 999ae00d0919
children c33b4abff860
comparison
equal deleted inserted replaced
473:8181ddd707f1 474:74d0c394666e
1100 1100
1101 PARSEFUNC(pseudo_parse_ifp1) 1101 PARSEFUNC(pseudo_parse_ifp1)
1102 { 1102 {
1103 l -> len = 0; 1103 l -> len = 0;
1104 l -> hideline = 1; 1104 l -> hideline = 1;
1105 1105 l -> hidecond = 1;
1106
1106 if (as -> skipcond && !(as -> skipmacro)) 1107 if (as -> skipcond && !(as -> skipmacro))
1107 { 1108 {
1108 as -> skipcount++; 1109 as -> skipcount++;
1109 skip_operand(p); 1110 skip_operand(p);
1110 return; 1111 return;
1115 1116
1116 PARSEFUNC(pseudo_parse_ifp2) 1117 PARSEFUNC(pseudo_parse_ifp2)
1117 { 1118 {
1118 l -> len = 0; 1119 l -> len = 0;
1119 l -> hideline = 1; 1120 l -> hideline = 1;
1121 l -> hidecond = 1;
1120 1122
1121 if (as -> skipcond && !(as -> skipmacro)) 1123 if (as -> skipcond && !(as -> skipmacro))
1122 { 1124 {
1123 as -> skipcount++; 1125 as -> skipcount++;
1124 skip_operand(p); 1126 skip_operand(p);
1132 { 1134 {
1133 lw_expr_t e; 1135 lw_expr_t e;
1134 1136
1135 l -> len = 0; 1137 l -> len = 0;
1136 l -> hideline = 1; 1138 l -> hideline = 1;
1139 l -> hidecond = 1;
1137 1140
1138 if (as -> skipcond && !(as -> skipmacro)) 1141 if (as -> skipcond && !(as -> skipmacro))
1139 { 1142 {
1140 as -> skipcount++; 1143 as -> skipcount++;
1141 skip_operand(p); 1144 skip_operand(p);
1156 { 1159 {
1157 lw_expr_t e; 1160 lw_expr_t e;
1158 1161
1159 l -> len = 0; 1162 l -> len = 0;
1160 l -> hideline = 1; 1163 l -> hideline = 1;
1164 l -> hidecond = 1;
1161 1165
1162 if (as -> skipcond && !(as -> skipmacro)) 1166 if (as -> skipcond && !(as -> skipmacro))
1163 { 1167 {
1164 as -> skipcount++; 1168 as -> skipcount++;
1165 skip_operand(p); 1169 skip_operand(p);
1181 { 1185 {
1182 lw_expr_t e; 1186 lw_expr_t e;
1183 1187
1184 l -> len = 0; 1188 l -> len = 0;
1185 l -> hideline = 1; 1189 l -> hideline = 1;
1190 l -> hidecond = 1;
1186 1191
1187 if (as -> skipcond && !(as -> skipmacro)) 1192 if (as -> skipcond && !(as -> skipmacro))
1188 { 1193 {
1189 as -> skipcount++; 1194 as -> skipcount++;
1190 skip_operand(p); 1195 skip_operand(p);
1205 { 1210 {
1206 lw_expr_t e; 1211 lw_expr_t e;
1207 1212
1208 l -> len = 0; 1213 l -> len = 0;
1209 l -> hideline = 1; 1214 l -> hideline = 1;
1215 l -> hidecond = 1;
1210 1216
1211 if (as -> skipcond && !(as -> skipmacro)) 1217 if (as -> skipcond && !(as -> skipmacro))
1212 { 1218 {
1213 as -> skipcount++; 1219 as -> skipcount++;
1214 skip_operand(p); 1220 skip_operand(p);
1229 { 1235 {
1230 lw_expr_t e; 1236 lw_expr_t e;
1231 1237
1232 l -> len = 0; 1238 l -> len = 0;
1233 l -> hideline = 1; 1239 l -> hideline = 1;
1240 l -> hidecond = 1;
1234 1241
1235 if (as -> skipcond && !(as -> skipmacro)) 1242 if (as -> skipcond && !(as -> skipmacro))
1236 { 1243 {
1237 as -> skipcount++; 1244 as -> skipcount++;
1238 skip_operand(p); 1245 skip_operand(p);
1252 PARSEFUNC(pseudo_parse_ifle) 1259 PARSEFUNC(pseudo_parse_ifle)
1253 { 1260 {
1254 lw_expr_t e; 1261 lw_expr_t e;
1255 1262
1256 l -> hideline = 1; 1263 l -> hideline = 1;
1264 l -> hidecond = 1;
1265
1257 l -> len = 0; 1266 l -> len = 0;
1258 1267
1259 if (as -> skipcond && !(as -> skipmacro)) 1268 if (as -> skipcond && !(as -> skipmacro))
1260 { 1269 {
1261 as -> skipcount++; 1270 as -> skipcount++;
1274 } 1283 }
1275 1284
1276 PARSEFUNC(pseudo_parse_endc) 1285 PARSEFUNC(pseudo_parse_endc)
1277 { 1286 {
1278 l -> hideline = 1; 1287 l -> hideline = 1;
1288 l -> hidecond = 1;
1289
1279 l -> len = 0; 1290 l -> len = 0;
1280 skip_operand(p); 1291 skip_operand(p);
1281 if (as -> skipcond && !(as -> skipmacro)) 1292 if (as -> skipcond && !(as -> skipmacro))
1282 { 1293 {
1283 as -> skipcount--; 1294 as -> skipcount--;
1287 } 1298 }
1288 1299
1289 PARSEFUNC(pseudo_parse_else) 1300 PARSEFUNC(pseudo_parse_else)
1290 { 1301 {
1291 l -> len = 0; 1302 l -> len = 0;
1303 l -> hidecond = 1;
1292 l -> hideline = 1; 1304 l -> hideline = 1;
1293 skip_operand(p); 1305 skip_operand(p);
1294 1306
1295 if (as -> skipmacro) 1307 if (as -> skipmacro)
1296 return; 1308 return;
1314 int i; 1326 int i;
1315 struct symtabe *s; 1327 struct symtabe *s;
1316 1328
1317 l -> len = 0; 1329 l -> len = 0;
1318 l -> hideline = 1; 1330 l -> hideline = 1;
1331 l -> hidecond = 1;
1319 1332
1320 if (as -> skipcond && !(as -> skipmacro)) 1333 if (as -> skipcond && !(as -> skipmacro))
1321 { 1334 {
1322 as -> skipcount++; 1335 as -> skipcount++;
1323 skip_operand(p); 1336 skip_operand(p);
1354 int i; 1367 int i;
1355 struct symtabe *s; 1368 struct symtabe *s;
1356 1369
1357 l -> len = 0; 1370 l -> len = 0;
1358 l -> hideline = 1; 1371 l -> hideline = 1;
1372 l -> hidecond = 1;
1359 1373
1360 if (as -> skipcond && !(as -> skipmacro)) 1374 if (as -> skipcond && !(as -> skipmacro))
1361 { 1375 {
1362 as -> skipcount++; 1376 as -> skipcount++;
1363 skip_operand(p); 1377 skip_operand(p);
1388 int pragma; 1402 int pragma;
1389 int compare; 1403 int compare;
1390 1404
1391 l -> len = 0; 1405 l -> len = 0;
1392 l -> hideline = 1; 1406 l -> hideline = 1;
1407 l -> hidecond = 1;
1393 1408
1394 if (as -> skipcond && !(as -> skipmacro)) 1409 if (as -> skipcond && !(as -> skipmacro))
1395 { 1410 {
1396 as -> skipcount++; 1411 as -> skipcount++;
1397 skip_operand(p); 1412 skip_operand(p);