*DECK NP$SHRK
*IF,DEF,XFR
USETEXT NX$ACBF
USETEXT AIPDEF
USETEXT HEADER
USETEXT NP$STAT
USETEXT NP$DB
USETEXT NP$NWL
USETEXT NP$MODE
USETEXT NP$GETS
USETEXT NX$ACBX
PROC NP$SHRK(CHKENTRY);
BEGIN
#
**
* 1. PROC NAME AUTHOR DATE
*
* NP$SHRK Y. C. YIP 02/16/1984
*
* 2. FUNCTIONAL DESCRIPTION.
*
* NP$SHRK SHRINKS THE CHECKMARK TABLE UP TO AND INCLUDING
* THE ENTRY INDICATED BY CHKENTRY.
*
* 3. METHOD USED.
*
* NP$SHRK TAKES THE VALUE OF THE CHK$IDX AND ELIMINATES
* THE INTERMEDISTE ENTRIES BETWEEN THE ENTRY NPCHKENTRY
* AND THE FIRST ENTRY. THE ENTRY NPCHKENTRY IS RETAINED.
*
* 4. ENTRY CONDITIONS:
*
* NPCHKENTRY = CHECK MARK TO BE ELIMINATED.
*
*
* 5. EXIT CONDITIONS:
*
* NPCHKENTRY IS NOT CHANGED.
* CHK$IDX IS UPDATED TO REFLECT THE NEW TABLE SIZE.
#
#
****
#
ITEM CHKENTRY; # ENTRY TO BE SHRUNK UP TO #
ITEM ITEMP; # INDEX #
ITEM INDEX; # LOOP INDEX #
ITEM CONT B; # CONTINUATION FLAG #
CONTROL EJECT;
#
************************************************************************
* *
* CODE OF PROC NP$SHRK BEGINS HERE *
* *
************************************************************************
#
P<CHK> = FTTCKTBL[FTTINDEX]; # PULL TEMPLATE TO FTT CHECKMARK #
# TABLE ADDRESS #
CONT = TRUE; # SET CONTINUATION FLAG TO TRUE #
ITEMP = CHKENTRY; # INITILIZE ENTRY AT SHRINK POINT #
FOR INDEX = CHK$START STEP 1 WHILE CONT
DO
BEGIN
CHK$WRD1[INDEX] = CHK$WRD1[ITEMP]; # COPY WORD ONE OF ENTRY #
CHK$WRD2[INDEX] = CHK$WRD2[ITEMP]; # COPY WORD TWO OF ENTRY #
ITEMP = ITEMP + 1;
IF ITEMP GR CHK$IDX[0] # CHECK FOR LAST ENTRY MOVED #
THEN
BEGIN
CONT = FALSE; # SET FLAG TO FALSE #
END
END
CHK$IDX[0] = CHK$IDX[0] - (CHKENTRY - CHK$START);
RETURN; # RETURN TO CALLER #
END # END OF PROC NP$SHRK #
TERM
*ENDIF