Routine ID: M410 | |
---|---|
Author(s): J. Zoll | Library: KERNLIB |
Submitter: C. Letertre | Submitted: 04.09.1972 |
Language: FORTRAN or Assembler | Revised: 15.09.1978 |
OBSOLETE
Please note that this routine has been obsoleted in CNL 219. Users are
advised not to use it any longer and to replace it in older programs.
No maintenance for it will take place and it will eventually disappear.
Suggested replacement: CHPACK (M432)
A1MANI manipulates and interprets BCD-strings in A1 representation.
Structure:
SUBROUTINE and FUNCTION subprograms
User Entry Names: ULEFT, URIGHT, USET,
IUFNBL, IULOOK, IUFORW, IUBACK,
IUEND
External References: IUCOMP (V304), UBUNCH (M409)
COMMON Block Names and Lengths: /SLATE/ 40
Usage:
Let the vector CH contain BCD characters in A1 format with blank padding. CH(J) is called the j-th character. A section of this vector is specified by (JL,JR) where CH(JL) is the first or left-most, and CH(JR) the last or right-most character.
The COMMON block /SLATE/ ND,NE,... holds certain search parameter, which are set by some of these routines. These parameters can also be accessed with , but this is not a recommended procedure.
CALL ULEFT(CH,JL,JR)left-justifies the section (JL,JR).
CALL URIGHT(CH,JL,JR)right-justifies the section (JL,JR).
CALL USET(INT,CH,JL,JR)writes the positive integer INT into the area (JL,JR) right-justified. If this integer is too large, the most significant characters are lost. Unused positions are not cleared to blank.
J=IUFNBL(CH,JL,JR)returns in J the address of the first non-blank character in the area (JL,JR), or JR+1 if none.
INTEXT=IULOOK(N,CH,JL,JR)takes the first N (at most) non-blank characters in the section (JL,JR) and returns them as the function value. N must not exceed the BCD-capacity of one computer word.
I=IUFORW(CH,JL,JR)reads the unsigned integer whose BCD-representation starts at CH(JL) and stops on the first non-numeric character or at CH(JR). Blanks are ignored.
I=IUBACK(CH,JL,JR)reads the integer whose BCD-representation starts just after the last non-numeric character in the field and stops at CH(JR). Blanks are ignored.