mirror of
https://github.com/simh/simh.git
synced 2026-01-31 13:53:10 +00:00
Give preference with HELP dev SHOW and HELP dev SET for unit modifiers to be displayed with a unit number as an example (unless the device has only one unit).
This commit is contained in:
4
scp.c
4
scp.c
@@ -1105,6 +1105,8 @@ if (dptr->modifiers) {
|
||||
for (mptr = dptr->modifiers; mptr->mask != 0; mptr++) {
|
||||
if (!MODMASK(mptr,MTAB_VDV) && MODMASK(mptr,MTAB_VUN))
|
||||
continue; /* skip unit only modifiers */
|
||||
if ((dptr->numunits != 1) && !(mptr->mask & MTAB_XTD))
|
||||
continue;
|
||||
if (mptr->mstring) {
|
||||
sprintf (buf, "set %s %s%s", sim_dname (dptr), mptr->mstring, (strchr(mptr->mstring, '=')) ? "" : (MODMASK(mptr,MTAB_VALR) ? "=val" : (MODMASK(mptr,MTAB_VALO) ? "{=val}" : "")));
|
||||
fprintf (st, "%-30s\t%s\n", buf, (strchr(mptr->mstring, '=')) ? "" : (mptr->help ? mptr->help : ""));
|
||||
@@ -1161,6 +1163,8 @@ if (dptr->modifiers) {
|
||||
continue; /* skip unit only modifiers */
|
||||
if ((!mptr->disp) || (!mptr->pstring) || !(*mptr->pstring))
|
||||
continue;
|
||||
if ((dptr->numunits != 1) && !(mptr->mask & MTAB_XTD))
|
||||
continue;
|
||||
sprintf (buf, "show %s %s%s", sim_dname (dptr), mptr->pstring, MODMASK(mptr,MTAB_SHP) ? "=arg" : "");
|
||||
fprintf (st, "%-30s\t%s\n", buf, mptr->help ? mptr->help : "");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user