FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00001 CSIGO,CSIGO=CSIGO 00001 00000 C;+ 00002 00000 C.ENTRY CSIGO 00003 00000 C - C S I G O 00004 00000 C****NAME: SUBROUTINE CSIGO 00005 00000 C IDENT: /870714/ 00006 00000 C FILE: CSIGO.FLX 00007 00000 C 00008 00000 C****PURPOSE: Scans the input line and returns indicies, switch 00009 00000 C statuses and switch values found. 00010 00000 C 00011 00000 C****RESTRICTIONS: CSI must be called before this routine. 00012 00000 C Also if there are any switches in the line 00013 00000 C CSISW must be called before it and if any switch 00014 00000 C values are given CSIVAL must be called before it. 00015 00000 C Certain arguments in other CSI routines 00016 00000 C must be VOLATILE or in COMMON; see those routines. 00017 00000 C 00018 00000 C SYSTEM: VAX/VMS 3.1 00019 00000 C LANGUAGE: FLECS/F77 00020 00000 C AUTHOR: M. OOTHOUDT 00021 00000 C DATE: 13-AUG-79 00022 00000 C;- 00023 00000 C REVISIONS: 00024 00000 C 31-AUG-79 (MAO) FIX ERROR FOR "TI:/SW" GIVING NONZERO TIM_FILIND 00025 00000 C 02-SEP-79 (MAO) ALLOW DEVICES OF FORM TTCN: 00026 00000 C 03/14/83 GTA Allow VMS directory syntax as well as UIC syntax. 00027 00000 C 04/22/83 GTA Fix error causing access violation when argument 00028 00000 C TYPE was not given. 00029 00000 C 11/04/83 GTA Code could not identify whether a comma was within 00030 00000 C a UIC or between filespecs containing VMS directories. 00031 00000 C 850327mao Document the need to VOLATIZE some variables. 00032 00000 C 850812mao Use LIB$MOVCx instead of CSIMACSUB. Allow full VAX file 00033 00000 C specifications. Use .IMP NONE & .INCL. 00034 00000 C 851015mao Check optional variables were given before rturning values. 00035 00000 C 861031mao Handle: nodename; hex integers; %D, %X, %O in integer value; 00036 00000 C I*1, I*4, R*4, R*8 values. 00037 00000 C 870714mao Allow underscore in directory name. 00038 00000 C;+ 00039 00000 C 00040 00000 C****CALLING SEQUENCE: CALL CSIGO (LINE,LENGTH, [TYPE] [,ERROR]) 00041 00000 C 00042 00000 C INPUT: 00043 00000 C 00044 00000 C LENGTH=(I*2) Number of bytes in LINE. 00045 00000 C TYPE =(L*1) Used to tell if an input or output specifier is to be 00046 00000 C processed. If TYPE='I' is given CSIGO tries to process 00047 00000 C a specifier to the right of an equal sign. If 00048 00000 C TYPE='O' CSIGO tries to process a specifier to the left 00049 00000 C of or in absence of an equal sign. If this argument 00050 00000 C is not given, 'O' is assumed. 00051 00000 C 00052 00000 C MODIFIED: 00053 00000 C 00054 00000 C LINE =(LENGTH L*1) On input, byte array LENGTH bytes long to be 00055 00000 C processed. FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00002 CSIGO,CSIGO=CSIGO 00056 00000 C On output, extraneous blanks and tabs have been 00057 00000 C compressed out. 00058 00000 C 00059 00000 C OUTPUT: 00060 00000 C 00061 00000 C ERROR =(L*2) Set to .TRUE. if an error is detected while processing 00062 00000 C LINE (an error message is also written on TI:). If 00063 00000 C no errors are detected, set=.FALSE. 00064 00000 C 00065 00000 C Also values are returned for NODIND, DEVIND, UICIND, FILIND, MORE, 00066 00000 C WILD,EQUAL, the switch states and the switch value buffers. Note that 00067 00000 C if these variables were given in calls to CSI, CSISW, and/or CSIVAL 00068 00000 C they must either be declared VOLATILE or be put into a COMMON block. 00069 00000 C See those routines for details. 00070 00000 C 00071 00000 C CMN BLOCK I/O: /CSI_DATA_BASE__/ 00072 00000 C 00073 00000 C RESOURCES: 00074 00000 C LIBRARIES: QLIB:ARGS, RTL:LIB$MOVC3:LIB$MOVC5 00075 00000 C OTHER SUBR: NONE 00076 00000 C DISK FILES: NONE 00077 00000 C DEVICES: NONE 00078 00000 C SGAS: NONE 00079 00000 C EVENT FLAGS: NONE 00080 00000 C SYSTEM DIR: NONE 00081 00000 C 00082 00000 C****NOTES: 00083 00000 C 1. The routine CSIGO may be called whenever you have a new 00084 00000 C LINE to process without calling any of the other CSI routines. The 00085 00000 C other CSI routines need to be called again only if you wish 00086 00000 C to change the definitions of the switches or their values. 00087 00000 C 00088 00000 C 2. Below is a complete example of how to set up for and 00089 00000 C process an input line. It is assumed that the input LINE may have 00090 00000 C any number of specifiers to the left or right of the equal sign and 00091 00000 C that the only switch is /PU:N where N is a numeric octal value. The 00092 00000 C routine "USER" is a user supplied subroutine to actually process 00093 00000 C the results of the CSIGO call. 00094 00000 C 00095 00000 C PROGRAM CSITST 00096 00000 C 00097 00000 C LOGICAL*2 MORE,WILD,EQUAL,PUSTAT,ERROR 00098 00000 C BYTE LINE(80) 00099 00000 C INTEGER*2 DEVIND(2),UICIND(2),FILIND(2),LENGTH 00100 00000 C COMMON/CSIVAR/DEVIND,UICIND,FILIND,MORE,WILD,EQUAL,PUSTAT,N 00101 00000 C 00102 00000 C CALL CSI(DEVIND,UICIND,FILIND,MORE,WILD,EQUAL) 00103 00000 C CALL CSISW('PU',PUSTAT,2) !SET UP SWITCH 00104 00000 C CALL CSIVAL('PU',N,,1) !OCTAL VALUE 00105 00000 C 00106 00000 C READ(5,1)LENGTH,LINE !GET LENGTH OF LINE AND LINE ITSELF 00107 00000 C 1 FORMAT(Q,80A1) 00108 00000 C 100 CALL CSIGO(LINE,LENGTH,'O',ERROR) 00109 00000 C IF(ERROR)GO TO 9999 !QUIT IF ERROR IN LINE 00110 00000 C CALL USER(DEVIND,UICIND,FILIND,MORE,WILD,EQUAL,PUSTAT,N) FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00003 CSIGO,CSIGO=CSIGO 00111 00000 C IF(MORE)GO TO 100 00112 00000 C IF(.NOT.EQUAL)GO TO 9999 !IF NO EQUAL SIGN QUIT 00113 00000 C 200 CALL CSIGO(LINE,LENGTH,'I',ERROR) 00114 00000 C IF(ERROR)GO TO 9999 !QUIT IF ERROR IN LINE 00115 00000 C CALL USER(DEVIND,UICIND,FILIND,MORE,WILD,EQUAL,PUSTAT,N) 00116 00000 C IF(MORE)GO TO 200 00117 00000 C 9999 STOP !ALL DONE 00118 00000 C END 00119 00000 C;- FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00004 CSIGO,CSIGO=CSIGO 00120 00000 .PAGE 00121 00001 SUBROUTINE CSIGO (LINE,LENGTH,TYPE,ERROR) 00122 00001 C 00123 00001 C GLOBAL CSI DECLARATIONS 00124 00001 C 00125 00003 .IMPLICIT NONE 00126 00003 .INCLUDE CSICOM.INC *00127 00003 C *00128 00003 C CSICOM.INC *00129 00003 C *00130 00003 C THIS FILE IS USED BY CSI ROUTINES VIA AN INCLUDE STATEMENT. *00131 00003 C *00132 00003 C *****NEVER DELETE THIS FILE ******** *00133 00003 C *00134 00003 C REVISIONS: *00135 00003 C 2-FEB-84 (JFA) - INCREASE MAX NO SWITCH VALUES FROM 30 TO 100 *00136 00003 C 850809mao Put file into standard format; convert L*1 variables to I*2. *00137 00003 C 861031mao Add NODIND_ADDR variable. *00138 00003 C *00139 00004 INTEGER*2 MAX_NUM_SW *00140 00005 INTEGER*2 MAX_NUM_VAL *00141 00005 *00142 00006 PARAMETER (MAX_NUM_SW=20) !Max number of switches *00143 00007 PARAMETER (MAX_NUM_VAL=100) !Max number of switch values *00144 00007 C *00145 00008 INTEGER*4 DEVIND_ADDR !Address to return device indicies *00146 00009 INTEGER*4 EQUAL_ADDR !Address to return equal status *00147 00010 INTEGER*4 FILIND_ADDR !Address to return file spec indicies *00148 00011 INTEGER*2 LINE_POINTER(2) !Position in input line after last *00149 00011 C ! CSIGO call; one pointer *00150 00011 C ! for each side of equal sign. *00151 00012 INTEGER*4 MORE_ADDR !Address to return more status *00152 00013 INTEGER*4 NODIND_ADDR !Address to return Node indicies!861031 *00153 00014 INTEGER*2 NUM_SW_DFN !Number of switches defined *00154 00015 INTEGER*2 NUM_SW_VAL_DFN !Number of switch values defined *00155 00016 BYTE SW_NAME(2,MAX_NUM_SW) !ASCII switch names *00156 00017 INTEGER*4 SW_STATE_ADDR(MAX_NUM_SW) !Addr to return sw status *00157 00018 INTEGER*2 SW_STATE_DFLT(MAX_NUM_SW) !Default for sw status *00158 00019 INTEGER*4 SW_VALUE_ADDR(MAX_NUM_VAL) !Addr to return sw value *00159 00020 INTEGER*2 SW_VALUE_CHAIN(2,MAX_NUM_SW) !Pointers to 1st & last sw *00160 00020 C value for a given sw in *00161 00020 C arrays. =(0,0) if no values *00162 00020 C for sw. *00163 00021 INTEGER*2 SW_VALUE_LENGTH(MAX_NUM_VAL) *00164 00021 C >0-->ASCII string, it's max length in bytes *00165 00021 C =0-->Decimal I*2 *00166 00021 C =-1-->Octal I*2 *00167 00021 C =-2-->Hex I*2 *00168 00021 C =-10-->Decimal I*1 *00169 00021 C =-11-->Octal I*1 *00170 00021 C =-12-->Hex I*1 *00171 00021 C =-20-->Decimal I*4 *00172 00021 C =-21-->Octal I*4 *00173 00021 C =-22-->Hex I*4 *00174 00021 C =-30-->Real*4 (F floating) FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00005 CSIGO,CSIGO=CSIGO *00175 00021 C =-40-->Real*8 (D floating) *00176 00022 INTEGER*4 UICIND_ADDR !Address to return directory indicies *00177 00023 INTEGER*4 WILD_ADDR !Address to return WILD status *00178 00023 C *00179 00024 COMMON/CSI_DATA_BASE__/LINE_POINTER, *00180 00025 1 NUM_SW_DFN,NUM_SW_VAL_DFN,NODIND_ADDR,DEVIND_ADDR,UICIND_ADDR, *00181 00026 2 FILIND_ADDR,MORE_ADDR,WILD_ADDR,EQUAL_ADDR,SW_NAME, *00182 00027 3 SW_STATE_ADDR,SW_STATE_DFLT,SW_VALUE_ADDR,SW_VALUE_LENGTH, *00183 00028 4 SW_VALUE_CHAIN *00184 00028 C *00185 00028 C END OF FILE 00186 00028 C 00187 00028 C LOCAL DECLARATIONS 00188 00028 C 00189 00029 BYTE LINE(80),TYPE,SEARCH_CHAR,BLANK,TAB,EQUAL,COMMA, 00190 00030 1 RIGHT_BRACKET,SLASH,COLON,MINUS,ASTERIC,NAM(2),PERIOD, 00191 00031 2 LEFT_BRACKET,SEMICOLON 00192 00032 LOGICAL*1 CONT,SW_NEG,TST 00193 00033 LOGICAL*2 ERROR 00194 00034 LOGICAL*2 ITYP !Added only to make a FLECS line short enough 00195 00035 LOGICAL*2 OCTAL !Added only to make a FLECS line short enough 00196 00036 LOGICAL*2 STAR !Added only to make a FLECS line short enough 00197 00037 INTEGER*2 LENGTH,I,IDX,NARGS,MAP,LOC_ERROR,ICHAR,LEND,IEQUAL, 00198 00038 1 INAM,INAME(MAX_NUM_SW) 00199 00039 INTEGER*4 J !scratch !861031 00200 00040 REAL*8 RR !scratch !861031 00201 00041 EQUIVALENCE(NAM(1),INAM),(SW_NAME(1,1),INAME(1)) 00202 00041 C 00203 00041 C THE VARIABLES BELOW ARE USED BY CSIGO TO KEEP TRACK OF THE LINE 00204 00041 C PARSING. 00205 00041 C 00206 00042 INTEGER*2 TMP_SW_STATE(MAX_NUM_SW) !Internal storage for sw status 00207 00043 INTEGER*4 TMP_SW_VALUE(2,MAX_NUM_VAL) !Internal storage for sw 00208 00043 C values. For ASCII string, these are pointers to start a 00209 00043 C stop of string in array line; if value is not given, th 00210 00043 C pointers are 0. For numeric values, value is contained 00211 00043 C in 1st element of pair except for reals. 00212 00044 REAL*8 TMP_SW_VALUE_RR(MAX_NUM_VAL) !EQUIV to TMP_SW_VALUE 00213 00045 INTEGER*2 TMP_NODIND(2) !Internal storage for pntrs to node string 00214 00046 INTEGER*2 TMP_DEVIND(2) !INTERNAL STORAGE FOR PNTRS TO DEVICE STRI 00215 00047 INTEGER*2 TMP_UICIND(2) !INTERNAL STORAGE FOR PNTRS TO DIR STRING 00216 00048 INTEGER*2 TMP_FILIND(2) !INTERNAL STORAGE FOR PNTRS TO FILENAME ST 00217 00049 LOGICAL*2 TMP_MORE !INTERNAL STORAGE FOR MORE FLAG 00218 00050 LOGICAL*2 TMP_WILD !INTERNAL STORAGE FOR WILD CARD FLAG 00219 00051 LOGICAL*2 TMP_EQUAL !INTERNAL STORAGE FOR EQUAL FLAG 00220 00052 INTEGER*2 LEN_CMPRS !LENGTH OF LINE AFTER SQUEEZING OUT 00221 00053 !BLANKS AND TABS 00222 00054 INTEGER*2 LEN_SUBSTRING !LENGTH OF SUBSTRING BEING PROCESSED 00223 00055 INTEGER*2 ISTRNG_STRT !1ST CHAR IN CURRENT SUBSTRING 00224 00056 INTEGER*2 ISTRNG_END !LAST CHAR IN CURRENT SUBSTRING 00225 00057 INTEGER*2 LOCATION !CURRENT LOCATION IN LINE FOR PARSING 00226 00058 INTEGER*2 LOC_SLASH !LOCATION OF NEXT (OR 1ST) SLASH (SWITCH) 00227 00059 INTEGER*2 LOC_COLON !LOC OF NEXT (OR 1ST) COLON FOR SW VALUE 00228 00060 INTEGER*2 I_STRT_SW !1ST CHARACTER IN SW STRING 00229 00061 INTEGER*2 I_END_SW !LAST CHARACTER IN SW STRING FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00006 CSIGO,CSIGO=CSIGO 00230 00062 INTEGER*2 NSW !LOCATION OF SW IN SW_NAME ARRAY 00231 00063 INTEGER*2 I_STRT_VAL !1ST CHARACTER IN A SW VALUE 00232 00064 INTEGER*2 I_END_VAL !LAST CHARACTER IN A SW VALUE 00233 00065 INTEGER*2 NVAL !NUMBER OF VALUES FOUND FOR A SW 00234 00066 LOGICAL*2 QUOTE !.T.==>we are between "s 00235 00066 C 00236 00067 EQUIVALENCE (TMP_SW_VALUE(1,1),TMP_SW_VALUE_RR(1)) 00237 00067 C 00238 00068 DATA BLANK/"40/,TAB/"11/,EQUAL/1H=/,COMMA/1H,/,LEFT_BRACKET/1H[/, 00239 00069 1 RIGHT_BRACKET/1H]/,SLASH/1H//,COLON/1H:/,ASTERIC/1H*/, 00240 00070 2 MINUS/1H-/,PERIOD/1H./,SEMICOLON/1H;/ FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00007 CSIGO,CSIGO=CSIGO 00241 00070 .PAGE 00242 00071 CONT=.TRUE. 00243 00072 CALL ARGS(NARGS,MAP) 00244 00072 C 00245 00074 SET-INTERNAL-VALUES-TO-DEFAULTS 00246 00074 C 00247 00075 IF(LENGTH.GT.0) 00248 00075 . 00249 00077 . PROCESS-MORE 00250 00078 . IF(I.EQ.0) 00251 00080 . . COMPRESS-LINE 00252 00082 . . CHECK-FOR-EQUAL-SIGN 00253 00083 . . LINE_POINTER(1)=0 !START OF OUTPUT SPECS-1 00254 00084 . . LINE_POINTER(2)=IEQUAL !START OF INPUT SPECS-1 00255 00084 . ...FIN 00256 00085 C . 00257 00086 . IF(CONT.AND.LEN_CMPRS.GT.0) 00258 00088 . . GET-NEXT-SUBSTRING 00259 00088 C . . 00260 00089 . . IF(LEN_SUBSTRING.GT.0) 00261 00090 . . . LOCATION=ISTRNG_STRT 00262 00092 . . . FIND-A-SLASH 00263 00097 . . . IF(LOC_SLASH.NE.ISTRNG_STRT)EXTRACT-FILE-SPEC 00264 00102 . . . IF(CONT)CHECK-SYNTAX 00265 00107 . . . IF(LOC_SLASH.NE.0.AND.CONT)EXTRACT-SWS-AND-VALUES 00266 00107 . . ...FIN 00267 00108 . ...FIN 00268 00109 ...FIN 00269 00110 C 00270 00111 IF(CONT) 00271 00113 . RETURN-FILE-SPEC-POINTERS 00272 00118 . IF(NUM_SW_DFN.GT.0)RETURN-SW-STATUS-AND-VALUES 00273 00120 . RETURN-FLAGS 00274 00120 ...FIN 00275 00122 C 00276 00123 IF(NARGS.GE.4.AND.((MAP.AND."10).NE.0))ERROR=.NOT.CONT 00277 00124 RETURN FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00008 CSIGO,CSIGO=CSIGO 00278 00124 .PAGE ---------------------------------------- 00279 00125 TO SET-INTERNAL-VALUES-TO-DEFAULTS 00280 00125 C . 00281 00125 C . SET FILE SPEC DEFAULTS 00282 00125 C . 00283 00126 . DO (I=1,2) 00284 00127 . . TMP_NODIND(I)=0 !861031 00285 00128 . . TMP_DEVIND(I)=0 00286 00129 . . TMP_UICIND(I)=0 00287 00130 . . TMP_FILIND(I)=0 00288 00130 . ...FIN 00289 00131 C . 00290 00131 C . SET SW STATUS AND VALUE DEFAULTS 00291 00131 C . 00292 00134 . DO (I=1,NUM_SW_DFN) TMP_SW_STATE(I)=SW_STATE_DFLT(I) 00293 00135 . DO (I=1,NUM_SW_VAL_DFN) 00294 00136 . . TMP_SW_VALUE(1,I)=0 00295 00137 . . TMP_SW_VALUE(2,I)=0 00296 00137 . ...FIN 00297 00138 C . 00298 00138 C . SET FLAGS--NOTE TMP_EQUAL MUST NOT BE RESET HERE! 00299 00138 C . 00300 00139 . TMP_MORE=.FALSE. 00301 00140 . TMP_WILD=.FALSE. 00302 00140 C . 00303 00140 C Set TYPE to default of 'O' if not given in call. 00304 00140 C . 00305 00141 . IF (NARGS.LT.3 .OR. ((MAP.AND.'7'O).EQ.0)) TYPE = 'O' 00306 00141 ...FIN FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00009 CSIGO,CSIGO=CSIGO 00307 00142 .PAGE ---------------------------------------- 00308 00143 TO PROCESS-MORE 00309 00143 C . 00310 00143 C . IF USER NOT WATCHING MORE OR MORE=.F., MUST ASSUME INPUT LINE 00311 00143 C . SCAN REQUIRES INITIALIZING--PDP11 CSIGO FEATURE. 00312 00143 C . 00313 00144 . I=0 !assume MORE_ADDR=0 or MORE=.F. 00314 00144 . 00315 00145 . IF (MORE_ADDR.NE.0) 00316 00146 . . CALL LIB$MOVC3(1,%VAL(MORE_ADDR),TST) !get value of user's MOR 00317 00147 . . IF (TST) I=1 00318 00147 . ...FIN!if 00319 00148 ...FIN!to process-more FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00010 CSIGO,CSIGO=CSIGO 00320 00149 .PAGE ---------------------------------------- 00321 00150 TO COMPRESS-LINE 00322 00150 C . 00323 00150 C . REMOVE ALL BLANKS AND TABS; BLANK FILL END OF LINE--for PDP11 00324 00150 C . compatability. However, leave them in between quotes. 00325 00150 C . 00326 00151 . LEN_CMPRS=0 00327 00152 . QUOTE = .FALSE. !NO " yet !861031 00328 00153 . DO (I=1,LENGTH) 00329 00154 . . IF (QUOTE .OR. (LINE(I).NE.BLANK.AND.LINE(I).NE.TAB)) !861031 00330 00155 . . . LEN_CMPRS=LEN_CMPRS+1 00331 00156 . . . LINE(LEN_CMPRS)=LINE(I) 00332 00156 . . ...FIN 00333 00158 . . IF (LINE(I).EQ.1H") QUOTE=.NOT.QUOTE !861031 00334 00158 . ...FIN 00335 00160 . IF(LEN_CMPRS.LT.LENGTH) 00336 00163 . . DO (I=LEN_CMPRS+1,LENGTH)LINE(I)=BLANK 00337 00163 . ...FIN 00338 00164 ...FIN ---------------------------------------- 00339 00166 TO CHECK-FOR-EQUAL-SIGN 00340 00166 C . 00341 00166 C . DOES LINE CONTAIN AN EQUAL SIGN? 00342 00166 C . 00343 00167 . SEARCH_CHAR=EQUAL 00344 00168 . ICHAR=1 00345 00169 . LEND=LEN_CMPRS 00346 00171 . LOOK-FOR-CHAR 00347 00172 . IEQUAL=ICHAR 00348 00174 . WHEN(ICHAR.EQ.0)TMP_EQUAL=.FALSE. 00349 00175 . ELSE 00350 00176 . . TMP_EQUAL=.TRUE. 00351 00176 C . . 00352 00176 C . . BUT IS THERE MORE THAN ONE EQUAL SIGN IN LINE? 00353 00176 C . . 00354 00177 . . ICHAR=ICHAR+1 00355 00179 . . LOOK-FOR-CHAR 00356 00180 . . IF(ICHAR.NE.0) 00357 00181 . . . LOC_ERROR=ICHAR 00358 00183 . . . REPORT-SYNTAX-ERROR 00359 00183 . . ...FIN 00360 00185 . ...FIN 00361 00186 ...FIN ---------------------------------------- 00362 00188 TO LOOK-FOR-CHAR 00363 00188 C . 00364 00188 C . LOOK FOR CHARACTER CONTAINED IN SEARCH_CHAR IN ARRAY LINE 00365 00188 C . SEARCHING FROM POSITION ICHAR TO POSITION LEND. FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00011 CSIGO,CSIGO=CSIGO 00366 00188 C . WHEN (MATCH) ICHAR=MATCHING POSITION 00367 00188 C . ELSE ICHAR=0 00368 00188 C . 00369 00191 . UNTIL(ICHAR.GT.LEND.OR.LINE(ICHAR).EQ.SEARCH_CHAR)ICHAR=ICHAR+1 00370 00192 . IF(ICHAR.GT.LEND)ICHAR=0 00371 00192 ...FIN ---------------------------------------- 00372 00194 TO REPORT-SYNTAX-ERROR 00373 00194 C . 00374 00194 C . REPORT SYNTAX ERROR; ASSUMES POSITION OF ERROR IS IN LOC_ERROR 00375 00194 C . 00376 00195 . TYPE 1,(LINE(I),I=1,LOC_ERROR) 00377 00196 1 . FORMAT(' CSIGO--SYNTAX ERROR:',/,(1X,70A1)) 00378 00197 . CONT=.FALSE. 00379 00197 ...FIN ---------------------------------------- 00380 00199 TO GET-NEXT-SUBSTRING 00381 00199 C . 00382 00199 C . FIND LIMITS OF NEXT SUBSTRING TO PROCESS. 1ST IS IT 'I' OR 'O'? 00383 00199 C . 00384 00201 . WHEN (TYPE.EQ.'I') ITYP = .TRUE. 00385 00204 . ELSE ITYP = .FALSE. 00386 00205 . WHEN (NARGS.GE.3.AND.((MAP.AND."4).NE.0).AND.ITYP) 00387 00206 . . J=2 00388 00206 . ...FIN !WHEN 00389 00209 . ELSE J=1 00390 00209 C . 00391 00209 C . FIND START AND END OF SUBSTRING 00392 00209 C . 00393 00210 . WHEN(J.EQ.2.AND..NOT.TMP_EQUAL) 00394 00211 . . LEN_SUBSTRING=0 00395 00211 . ...FIN 00396 00212 . ELSE 00397 00213 . . ISTRNG_STRT=LINE_POINTER(J)+1 !START IS EASY 00398 00214 . . SEARCH_CHAR=COMMA !END IS AT COMMA OR END OF SCAN 00399 00215 . . ICHAR=ISTRNG_STRT 00400 00217 . . WHEN(J.EQ.2.OR.IEQUAL.EQ.0)LEND=LEN_CMPRS 00401 00220 . . ELSE LEND=IEQUAL-1 00402 00222 . . LOOK-FOR-CHAR 00403 00223 . . WHEN(ICHAR.EQ.0) 00404 00223 C . . . 00405 00223 C . . . NO COMMA; USE REST OF SCAN 00406 00223 C . . . 00407 00224 . . . ISTRNG_END=LEND 00408 00225 . . . TMP_MORE=.FALSE. 00409 00225 . . ...FIN 00410 00226 . . ELSE 00411 00226 C . . . 00412 00226 C . . . COMMA, BUT COULD IT BE IN A UIC? 00413 00226 C . . . 00414 00227 . . . LOCATION=ICHAR FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00012 CSIGO,CSIGO=CSIGO 00415 00228 . . . ICHAR=ISTRNG_STRT 00416 00229 . . . SEARCH_CHAR=LEFT_BRACKET 00417 00231 . . . LOOK-FOR-CHAR 00418 00232 . . . WHEN(ICHAR.EQ.0.OR.ICHAR.GT.LOCATION) 00419 00232 C . . . . 00420 00232 C . . . . COMMA NOT PART OF A UIC AND THUS IS END OF SUBSTRING 00421 00232 C . . . . 00422 00233 . . . . ISTRNG_END=LOCATION-1 00423 00234 . . . . TMP_MORE=.TRUE. 00424 00234 . . . ...FIN 00425 00235 . . . ELSE 00426 00235 C . . . . 00427 00235 C . . . . COMMA MAY BE IN UIC; FIND RIGHT BRACKET 00428 00235 C . . . . 00429 00236 . . . . SEARCH_CHAR = RIGHT_BRACKET 00430 00237 . . . . ICHAR = ICHAR + 1 00431 00239 . . . . LOOK-FOR-CHAR 00432 00240 . . . . WHEN (ICHAR.NE.0 .AND. ICHAR.LT.LOCATION) 00433 00240 C . . . . . 00434 00240 C . . . . . COMMA IS NOT PART OF UIC AND THUS IS END OF SUBSTRING 00435 00240 C . . . . . 00436 00241 . . . . . ISTRNG_END = LOCATION -1 00437 00242 . . . . . TMP_MORE = .TRUE. 00438 00242 . . . . ...FIN !when 00439 00243 . . . . ELSE 00440 00243 C . . . . . 00441 00243 C . . . . . COMMA IS IN UIC; FIND NEXT COMMA 00442 00243 C . . . . . 00443 00244 . . . . . ICHAR=LOCATION+1 00444 00245 . . . . . SEARCH_CHAR=COMMA 00445 00247 . . . . . LOOK-FOR-CHAR 00446 00248 . . . . . WHEN(ICHAR.EQ.0) 00447 00248 C . . . . . . 00448 00248 C . . . . . . NO COMMA; USE REST OF STRING 00449 00248 C . . . . . . 00450 00249 . . . . . . ISTRNG_END=LEND 00451 00250 . . . . . . TMP_MORE=.FALSE. 00452 00250 . . . . . ...FIN 00453 00251 . . . . . ELSE 00454 00251 C . . . . . . 00455 00251 C . . . . . . GOT A COMMA; ASSUME SYNTAX OK AND THUS THIS IS END OF SUBSTRING 00456 00251 C . . . . . . 00457 00252 . . . . . . ISTRNG_END=ICHAR-1 00458 00253 . . . . . . TMP_MORE=.TRUE. 00459 00253 . . . . . ...FIN 00460 00254 . . . . ...FIN 00461 00255 . . . ...FIN !else 00462 00256 . . ...FIN 00463 00258 . . LEN_SUBSTRING=ISTRNG_END-ISTRNG_STRT+1 00464 00259 . . LINE_POINTER(J)=ISTRNG_END+1 00465 00259 . ...FIN 00466 00260 ...FIN ---------------------------------------- FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00013 CSIGO,CSIGO=CSIGO 00467 00262 TO FIND-A-SLASH 00468 00262 C . 00469 00262 C . FIND A SLASH IN SUBSTRING, IE. START OF A SW. 00470 00262 C . SCAN STARTS AT LOCATION AND ENDS AT ISTRNG_END 00471 00262 C . 00472 00263 . SEARCH_CHAR=SLASH 00473 00264 . ICHAR=LOCATION 00474 00265 . LEND=ISTRNG_END 00475 00267 . LOOK-FOR-CHAR 00476 00268 . LOC_SLASH=ICHAR 00477 00268 ...FIN ---------------------------------------- 00478 00270 TO EXTRACT-FILE-SPEC 00479 00270 C . 00480 00270 C . First try to find a node name string 00481 00270 C . 00482 00271 . SEARCH_CHAR=COLON !861031 00483 00272 . ICHAR=LOCATION !861031 00484 00274 . WHEN(LOC_SLASH.EQ.0)LEND=ISTRNG_END !861031 00485 00277 . ELSE LEND=LOC_SLASH-1 !861031 00486 00279 . LOOK-FOR-CHAR !861031 00487 00280 . IF(ICHAR.NE.0) !861031 00488 00281 . . IF((ICHAR+1).LE.LEND .AND. LINE(ICHAR+1).EQ.COLON) !861031 00489 00282 . . . TMP_NODIND(1)=ISTRNG_STRT !861031 00490 00283 . . . TMP_NODIND(2)=ICHAR-1 !exclude :: !861031 00491 00284 . . . LOCATION=ICHAR+2 !skip over :: !861031 00492 00284 . . ...FIN !861031 00493 00285 . ...FIN !861031 00494 00286 C . 00495 00286 C . NEXT TRY TO FIND A DEVICE OR LOGICAL NAME 00496 00286 C . 00497 00287 . SEARCH_CHAR=COLON 00498 00288 . ICHAR=LOCATION 00499 00290 . LOOK-FOR-CHAR 00500 00291 . IF(ICHAR.NE.0) 00501 00292 . . TMP_DEVIND(1)=LOCATION !861031 00502 00293 . . TMP_DEVIND(2)=ICHAR-1 !PDP11 CSIGO EXCLUDES COLON TOO 00503 00294 . . LOCATION=ICHAR+1 00504 00294 . ...FIN 00505 00295 C . 00506 00295 C . NEXT LOOK FOR UIC OR DIRECTORY 00507 00295 C . 00508 00296 . SEARCH_CHAR=LEFT_BRACKET 00509 00297 . ICHAR=LOCATION 00510 00299 . LOOK-FOR-CHAR 00511 00300 . IF(ICHAR.NE.0) 00512 00301 . . TMP_UICIND(1)=ICHAR 00513 00302 . . SEARCH_CHAR=RIGHT_BRACKET 00514 00303 . . ICHAR=TMP_UICIND(1)+1 00515 00305 . . LOOK-FOR-CHAR 00516 00306 . . WHEN(ICHAR.EQ.0) 00517 00308 . . . WHEN(LOC_SLASH.EQ.0)LOC_ERROR=ISTRNG_END 00518 00311 . . . ELSE LOC_ERROR=LOC_SLASH FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00014 CSIGO,CSIGO=CSIGO 00519 00313 . . . REPORT-SYNTAX-ERROR 00520 00313 . . ...FIN 00521 00315 . . ELSE 00522 00316 . . . TMP_UICIND(2)=ICHAR 00523 00317 . . . LOCATION=ICHAR+1 00524 00317 . . ...FIN 00525 00318 . ...FIN 00526 00320 . IF(CONT) 00527 00320 C . . 00528 00320 C . . FILE NAME GIVEN? 00529 00320 C . . 00530 00322 . . WHEN(LOC_SLASH.EQ.0)I=ISTRNG_END 00531 00325 . . ELSE I=LOC_SLASH-1 00532 00326 . . IF(I-LOCATION.GE.0) 00533 00327 . . . TMP_FILIND(1)=LOCATION 00534 00328 . . . TMP_FILIND(2)=I 00535 00328 . . ...FIN 00536 00329 . ...FIN 00537 00330 ...FIN ---------------------------------------- 00538 00332 TO CHECK-SYNTAX 00539 00332 C . 00540 00332 C . A FEW SYNTAX CHECKS HAVE ALREADY BEEN DONE IN THE 00541 00332 C . PROCEDURES CHECK-FOR-EQUAL-SIGN, GET-NEXT-SUBSTRING AND 00542 00332 C . EXTRACT-FILE-SPEC. HERE WE DO THE REST OF THE SYNTAX CHECKING 00543 00332 C . DONE IN THE PDP11 CSI VIA A CALL TO THE SYSTEM LIBRARY ROUTINE 00544 00332 C . .CSI1. 00545 00332 C . 00546 00337 . IF (TMP_NODIND(1).NE.0) CHECK-NODE-SYNTAX !861031 00547 00342 . IF(CONT.AND.TMP_DEVIND(1).NE.0)CHECK-DEVICE-SYNTAX 00548 00347 . IF(CONT.AND.TMP_UICIND(1).NE.0)CHECK-UIC-SYNTAX 00549 00352 . IF(CONT.AND.TMP_FILIND(1).NE.0)CHECK-FILE-SYNTAX 00550 00357 . IF(CONT.AND.LOC_SLASH.NE.0)CHECK-SWITCH-SYNTAX 00551 00357 ...FIN ---------------------------------------- 00552 00359 TO CHECK-NODE-SYNTAX !861031 00553 00359 C . 00554 00359 C . Not much to check for 00555 00359 C . 00556 00359 C . Following the node must be device or directory (if no device 00557 00359 C . given) or filename (if no device or directory given) 00558 00359 C . or switch (if no device or directory or file name) or end of 00559 00359 C . substring. Note: 00560 00359 C . TMP_NODIND(2) doesn't include the two colons in the node name! 00561 00359 C . 00562 00360 . I=TMP_NODIND(2)+3 !861031 00563 00360 . CONDITIONAL !861031 00564 00361 . . (NODIND_ADDR.EQ.0) !Node name given, but no NODIND !861031 00565 00362 . . . LOC_ERROR = I-1 ! (for compat with old CSI) !861031 00566 00364 . . . REPORT-SYNTAX-ERROR !861031 00567 00364 . . ...FIN !861031 FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00015 CSIGO,CSIGO=CSIGO 00568 00366 . . (TMP_DEVIND(1).NE.0.AND.TMP_DEVIND(1).EQ.I) !861031 00569 00367 . . . CONTINUE !OK !861031 00570 00367 . . ...FIN !861031 00571 00368 . . (TMP_UICIND(1).NE.0.AND.TMP_UICIND(1).EQ.I) !861031 00572 00369 . . . CONTINUE !OK !861031 00573 00369 . . ...FIN !861031 00574 00370 . . (TMP_FILIND(1).NE.0.AND.TMP_FILIND(1).EQ.I) !861031 00575 00371 . . . CONTINUE !OK !861031 00576 00371 . . ...FIN !861031 00577 00372 . . (LOC_SLASH.NE.0.AND.LOC_SLASH.EQ.I) !861031 00578 00373 . . . CONTINUE !OK !861031 00579 00373 . . ...FIN !861031 00580 00374 . . (LOC_SLASH.EQ.0.AND.ISTRNG_END.EQ.I-1) !861031 00581 00375 . . . CONTINUE !OK !861031 00582 00375 . . ...FIN !861031 00583 00376 . . (OTHERWISE) !861031 00584 00377 . . . LOC_ERROR=I !861031 00585 00379 . . . REPORT-SYNTAX-ERROR !861031 00586 00379 . . ...FIN !861031 00587 00381 . ...FIN !861031 00588 00381 ...FIN !861031 ---------------------------------------- 00589 00383 TO CHECK-DEVICE-SYNTAX 00590 00383 C . 00591 00383 C . Might be device or logical name; not much to check for 00592 00383 C . 00593 00383 C . FOLLOWING THE DEVICE MUST BE UIC OR FILENAME (IF NO UIC GIVEN) 00594 00383 C . OR SWITCH (IF NO UIC OR FILE NAME) OR END OF SUBSTRING. NOTE: 00595 00383 C . TMP_DEVIND(2) DOESN'T INCLUDE THE COLON IN THE DEVICE NAME! 00596 00383 C . 00597 00384 . I=TMP_DEVIND(2)+2 00598 00384 . CONDITIONAL 00599 00385 . . (TMP_UICIND(1).NE.0.AND.TMP_UICIND(1).EQ.I) 00600 00386 . . . CONTINUE !OK 00601 00386 . . ...FIN 00602 00387 . . (TMP_FILIND(1).NE.0.AND.TMP_FILIND(1).EQ.I) 00603 00388 . . . CONTINUE !OK 00604 00388 . . ...FIN 00605 00389 . . (LOC_SLASH.NE.0.AND.LOC_SLASH.EQ.I) 00606 00390 . . . CONTINUE !OK 00607 00390 . . ...FIN 00608 00391 . . (LOC_SLASH.EQ.0.AND.ISTRNG_END.EQ.I-1) 00609 00392 . . . CONTINUE !OK 00610 00392 . . ...FIN 00611 00393 . . (OTHERWISE) 00612 00394 . . . LOC_ERROR=I 00613 00396 . . . REPORT-SYNTAX-ERROR 00614 00396 . . ...FIN 00615 00398 . ...FIN 00616 00398 ...FIN ---------------------------------------- FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00016 CSIGO,CSIGO=CSIGO 00617 00400 TO CHECK-UIC-SYNTAX 00618 00400 C . 00619 00400 C If we have UIC syntax, there must be a comma in field. 00620 00400 C . 00621 00401 . SEARCH_CHAR=COMMA 00622 00402 . ICHAR=TMP_UICIND(1)+1 00623 00403 . LEND=TMP_UICIND(2)-1 00624 00405 . LOOK-FOR-CHAR 00625 00406 . WHEN (ICHAR.NE.0) !have UIC syntax 00626 00406 C . . 00627 00406 C . . TO LEFT OF COMMA MUST BE AN OCTAL #, 0-"377 OR * 00628 00406 C . . 00629 00407 . . I=ICHAR-TMP_UICIND(1)-1 00630 00407 . . CONDITIONAL 00631 00408 . . . (I.EQ.1.AND.LINE(TMP_UICIND(1)+1).EQ.ASTERIC) 00632 00409 . . . . TMP_WILD=.TRUE. 00633 00409 . . . ...FIN 00634 00410 . . . (I.GT.0.AND.I.LT.4) 00635 00411 . . . . DECODE(I,5,LINE(TMP_UICIND(1)+1),ERR=1500)J 00636 00412 5 . . . . FORMAT(O3) 00637 00413 . . . . IF(J.LT.0.OR.J.GT."377)GO TO 1500 00638 00413 . . . ...FIN 00639 00414 . . . (OTHERWISE) 00640 00415 1500 . . . . LOC_ERROR=ICHAR 00641 00417 . . . . REPORT-SYNTAX-ERROR 00642 00417 . . . ...FIN !OTHERWISE 00643 00419 . . ...FIN !CONDITIONAL 00644 00420 . . IF(CONT) 00645 00420 C . . . 00646 00420 C . . . TO RIGHT OF COMMA MUST BE AN OCTAL #, 0-"377 OR *. 00647 00420 C . . . 00648 00421 . . . I=TMP_UICIND(2)-ICHAR-1 00649 00421 . . . CONDITIONAL 00650 00422 . . . . (I.EQ.1.AND.LINE(ICHAR+1).EQ.ASTERIC) 00651 00423 . . . . . TMP_WILD=.TRUE. 00652 00423 . . . . ...FIN 00653 00424 . . . . (I.GT.0.AND.I.LT.4) 00654 00425 . . . . . DECODE(I,5,LINE(ICHAR+1),ERR=1600)J 00655 00426 . . . . . IF(J.LT.0.OR.J.GT."377)GO TO 1600 00656 00426 . . . . ...FIN 00657 00427 . . . . (OTHERWISE) 00658 00428 1600 . . . . . LOC_ERROR=TMP_UICIND(2) 00659 00430 . . . . . REPORT-SYNTAX-ERROR 00660 00430 . . . . ...FIN !OTHERWISE 00661 00432 . . . ...FIN !CONDITIONAL 00662 00432 . . ...FIN !IF CONT 00663 00433 . ...FIN !WHEN 00664 00434 . ELSE !must have directory syntax 00665 00434 C . . 00666 00434 C All characters must be alphanumeric or '.' or '_' 00667 00434 C . . 00668 00435 . . IDX = TMP_UICIND(1) + 1 00669 00436 . . WHILE (IDX.LE.TMP_UICIND(2)-1 .AND. CONT) 00670 00436 . . . CONDITIONAL 00671 00438 . . . . (LINE(IDX).EQ.'_') CONTINUE !870714 FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00017 CSIGO,CSIGO=CSIGO 00672 00439 . . . . (LINE(IDX).EQ.'.') CONTINUE 00673 00440 . . . . (LINE(IDX).GE.'0' .AND. LINE(IDX).LE.'9') CONTINUE 00674 00441 . . . . (LINE(IDX).GE.'A' .AND. LINE(IDX).LE.'Z') CONTINUE 00675 00442 . . . . (OTHERWISE) 00676 00443 . . . . . LOC_ERROR = TMP_UICIND(1) + IDX 00677 00445 . . . . . REPORT-SYNTAX-ERROR 00678 00445 . . . . ...FIN !OTHERWISE 00679 00447 . . . ...FIN !CONDITIONAL 00680 00448 . . . IDX = IDX + 1 00681 00448 . . ...FIN !WHILE 00682 00449 . ...FIN !ELSE 00683 00451 . IF(CONT) 00684 00451 C . . 00685 00451 C . . FOLLOWING THE UIC MUST BE FILENAME OR SW (IF NO FILENAME) 00686 00451 C . . OR END OF SUBSTRING (IF NO FILENAME OR SW) 00687 00451 C . . 00688 00452 . . I=TMP_UICIND(2)+1 00689 00452 . . CONDITIONAL 00690 00453 . . . (TMP_FILIND(1).NE.0.AND.TMP_FILIND(1).EQ.I) 00691 00454 . . . . CONTINUE !OK 00692 00454 . . . ...FIN 00693 00455 . . . (LOC_SLASH.NE.0.AND.LOC_SLASH.EQ.I) 00694 00456 . . . . CONTINUE !OK 00695 00456 . . . ...FIN 00696 00457 . . . (LOC_SLASH.EQ.0.AND.ISTRNG_END.EQ.I-1) 00697 00458 . . . . CONTINUE !OK 00698 00458 . . . ...FIN 00699 00459 . . . (OTHERWISE) 00700 00460 . . . . LOC_ERROR=I 00701 00462 . . . . REPORT-SYNTAX-ERROR 00702 00462 . . . ...FIN 00703 00464 . . ...FIN 00704 00464 . ...FIN 00705 00465 ...FIN ---------------------------------------- 00706 00467 TO CHECK-FILE-SYNTAX 00707 00467 C . 00708 00467 C . FIND PERIOD AND SEMICOLON IN FILE 00709 00467 C . 00710 00468 . SEARCH_CHAR=PERIOD 00711 00469 . ICHAR=TMP_FILIND(1) 00712 00470 . LEND=TMP_FILIND(2) 00713 00472 . LOOK-FOR-CHAR 00714 00473 . I=ICHAR 00715 00474 . SEARCH_CHAR=SEMICOLON 00716 00475 . ICHAR=TMP_FILIND(1) 00717 00477 . LOOK-FOR-CHAR 00718 00478 . J=ICHAR 00719 00479 . IF(J.NE.0.AND.J.LT.I) 00720 00480 . . LOC_ERROR=I 00721 00482 . . REPORT-SYNTAX-ERROR 00722 00482 . ...FIN 00723 00485 . IF(CONT) FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00018 CSIGO,CSIGO=CSIGO 00724 00485 C . . 00725 00485 C . . AT MOST 39 CHARACTERS IN FILENAME; NOTE "FILE" OR "FILE." OR 00726 00485 C . . "FILE;" ARE LEGAL ON PDP11 AND THUS MUST BE LEGAL HERE. 00727 00485 C . . 00728 00485 . . CONDITIONAL 00729 00487 . . . (I.NE.0)ICHAR=I-1 00730 00489 . . . (J.NE.0)ICHAR=J-1 00731 00491 . . . (OTHERWISE)ICHAR=TMP_FILIND(2) 00732 00492 . . ...FIN 00733 00493 . . IF(ICHAR-TMP_FILIND(1).GT.38) 00734 00494 . . . LOC_ERROR=ICHAR 00735 00496 . . . REPORT-SYNTAX-ERROR 00736 00496 . . ...FIN 00737 00498 . ...FIN 00738 00500 . IF(CONT) 00739 00500 C . . 00740 00500 C . . FILE NAME CAN CONTAIN ONLY A-Z, a-z, 0-9, _, AND $ OR BE *. 00741 00500 C . . 00742 00502 . . WHEN (LINE(ICHAR).EQ.ASTERIC) STAR = .TRUE. 00743 00505 . . ELSE STAR = .FALSE. 00744 00506 . . WHEN (ICHAR.EQ.TMP_FILIND(1) .AND. STAR) 00745 00507 . . . TMP_WILD=.TRUE. 00746 00507 . . ...FIN 00747 00508 . . ELSE 00748 00509 . . . LEND=TMP_FILIND(1) 00749 00510 . . . WHILE(LEND.LE.ICHAR.AND.CONT) 00750 00510 . . . . CONDITIONAL 00751 00511 . . . . . (LINE(LEND).GE.1HA.AND.LINE(LEND).LE.1HZ) 00752 00512 . . . . . . CONTINUE !OK, A-Z 00753 00512 . . . . . ...FIN 00754 00513 . . . . . (LINE(LEND).GE.1Ha.AND.LINE(LEND).LE.1Hz) 00755 00514 . . . . . . CONTINUE !OK, a-z 00756 00514 . . . . . ...FIN 00757 00515 . . . . . (LINE(LEND).GE.1H0.AND.LINE(LEND).LE.1H9) 00758 00516 . . . . . . CONTINUE !OK, 1-9 00759 00516 . . . . . ...FIN 00760 00517 . . . . . (LINE(LEND).EQ.1H_) 00761 00518 . . . . . . CONTINUE !OK, _ 00762 00518 . . . . . ...FIN 00763 00519 . . . . . (LINE(LEND).EQ.1H$) 00764 00520 . . . . . . CONTINUE !OK, $ 00765 00520 . . . . . ...FIN 00766 00521 . . . . . (OTHERWISE) 00767 00522 . . . . . . LOC_ERROR=LEND 00768 00524 . . . . . . REPORT-SYNTAX-ERROR 00769 00524 . . . . . ...FIN 00770 00526 . . . . ...FIN 00771 00527 . . . . LEND=LEND+1 00772 00527 . . . ...FIN 00773 00528 . . ...FIN 00774 00529 . ...FIN 00775 00531 . IF(CONT.AND.I.NE.0) 00776 00531 C . . 00777 00531 C . . EXTENSION MUST HAVE AT MOST 39 CHARACTERS 00778 00531 C . . FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00019 CSIGO,CSIGO=CSIGO 00779 00533 . . WHEN(J.NE.0)ICHAR=J-1 00780 00536 . . ELSE ICHAR=TMP_FILIND(2) 00781 00537 . . IF(ICHAR-I.GT.39) 00782 00538 . . . LOC_ERROR=ICHAR 00783 00540 . . . REPORT-SYNTAX-ERROR 00784 00540 . . ...FIN 00785 00543 . . IF(CONT) 00786 00543 C . . . 00787 00543 C . . . EXTENSION CAN ONLY CONTAIN A-Z, a-z, 0-9, _, AND $ OR BE *. 00788 00543 C . . . 00789 00544 . . . WHEN(ICHAR.EQ.I+1.AND.LINE(ICHAR).EQ.ASTERIC) 00790 00545 . . . . TMP_WILD=.TRUE. 00791 00545 . . . ...FIN 00792 00546 . . . ELSE 00793 00547 . . . . LEND=I+1 00794 00548 . . . . WHILE(LEND.LE.ICHAR.AND.CONT) 00795 00548 . . . . . CONDITIONAL 00796 00549 . . . . . . (LINE(LEND).GE.1HA.AND.LINE(LEND).LE.1HZ) 00797 00550 . . . . . . . CONTINUE !OK, A-Z 00798 00550 . . . . . . ...FIN 00799 00551 . . . . . . (LINE(LEND).GE.1Ha.AND.LINE(LEND).LE.1Hz) 00800 00552 . . . . . . . CONTINUE !OK, a-z 00801 00552 . . . . . . ...FIN 00802 00553 . . . . . . (LINE(LEND).GE.1H0.AND.LINE(LEND).LE.1H9) 00803 00554 . . . . . . . CONTINUE !OK, 1-9 00804 00554 . . . . . . ...FIN 00805 00555 . . . . . . (LINE(LEND).EQ.1H_) 00806 00556 . . . . . . . CONTINUE !OK, _ 00807 00556 . . . . . . ...FIN 00808 00557 . . . . . . (LINE(LEND).EQ.1H$) 00809 00558 . . . . . . . CONTINUE !OK, $ 00810 00558 . . . . . . ...FIN 00811 00559 . . . . . . (OTHERWISE) 00812 00560 . . . . . . . LOC_ERROR=LEND 00813 00562 . . . . . . . REPORT-SYNTAX-ERROR 00814 00562 . . . . . . ...FIN 00815 00564 . . . . . ...FIN 00816 00565 . . . . . LEND=LEND+1 00817 00565 . . . . ...FIN 00818 00566 . . . ...FIN 00819 00567 . . ...FIN 00820 00568 . ...FIN 00821 00570 . IF(CONT.AND.J.NE.0) 00822 00570 C . . 00823 00570 C . . VERSION # MUST BE IN RANGE 1 THROUGH +32767 OR BE *. 00824 00570 C . . 00825 00571 . . I=TMP_FILIND(2)-J 00826 00571 . . CONDITIONAL 00827 00572 . . . (I.EQ.1.AND.LINE(J+1).EQ.ASTERIC) 00828 00573 . . . . TMP_WILD=.TRUE. 00829 00573 . . . ...FIN 00830 00574 . . . (I.GT.0) 00831 00575 . . . . DECODE(I,6,LINE(J+1),ERR=1700)J 00832 00576 6 . . . . FORMAT(I10) 00833 00577 . . . . IF(J.LT.1) GO TO 1700 FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00020 CSIGO,CSIGO=CSIGO 00834 00577 . . . ...FIN 00835 00578 . . . (OTHERWISE) 00836 00579 1700 . . . . LOC_ERROR=TMP_FILIND(2) 00837 00581 . . . . REPORT-SYNTAX-ERROR 00838 00581 . . . ...FIN 00839 00583 . . ...FIN 00840 00583 . ...FIN 00841 00585 . IF(CONT) 00842 00585 C . . 00843 00585 C . . FOLLOWING FILENAME MUST BE SW OR END OF SUBSTRING 00844 00585 C . . 00845 00586 . . I=TMP_FILIND(2)+1 00846 00586 . . CONDITIONAL 00847 00587 . . . (LOC_SLASH.NE.0.AND.LOC_SLASH.EQ.I) 00848 00588 . . . . CONTINUE !OK 00849 00588 . . . ...FIN 00850 00589 . . . (LOC_SLASH.EQ.0.AND.ISTRNG_END.EQ.I-1) 00851 00590 . . . . CONTINUE !OK 00852 00590 . . . ...FIN 00853 00591 . . . (OTHERWISE) 00854 00592 . . . . LOC_ERROR=I 00855 00594 . . . . REPORT-SYNTAX-ERROR 00856 00594 . . . ...FIN 00857 00596 . . ...FIN 00858 00596 . ...FIN 00859 00597 ...FIN ---------------------------------------- 00860 00599 TO CHECK-SWITCH-SYNTAX 00861 00599 C . 00862 00599 C . THE 3 CHARACTERS ] [ AND ; MUST NOT APPEAR IN SWITCH VALUES 00863 00599 C . 00864 00600 . I=LOC_SLASH+1 00865 00601 . WHILE(I.LE.ISTRNG_END.AND.CONT) 00866 00602 . . TST=LINE(I).EQ.LEFT_BRACKET.OR.LINE(I).EQ.RIGHT_BRACKET.OR. 00867 00603 1. . LINE(I).EQ.SEMICOLON 00868 00604 . . IF(TST) 00869 00605 . . . LOC_ERROR=I 00870 00607 . . . REPORT-SYNTAX-ERROR 00871 00607 . . ...FIN 00872 00610 . . I=I+1 00873 00610 . ...FIN 00874 00611 ...FIN ---------------------------------------- 00875 00613 TO EXTRACT-SWS-AND-VALUES 00876 00613 C . 00877 00613 C . WE HAVE AT LEAST ONE SW 00878 00613 C . 00879 00614 . WHILE(LOC_SLASH.NE.0.AND.CONT) 00880 00614 C . . 00881 00614 C . . FIND END OF THIS SW+VALUES 00882 00614 C . . FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00021 CSIGO,CSIGO=CSIGO 00883 00615 . . I_STRT_SW=LOC_SLASH+1 00884 00616 . . LOCATION=LOC_SLASH+1 00885 00618 . . FIND-A-SLASH 00886 00620 . . WHEN(LOC_SLASH.EQ.0)I_END_SW=ISTRNG_END 00887 00623 . . ELSE I_END_SW=LOC_SLASH-1 00888 00625 . . GET-SWITCH-NAME 00889 00630 . . IF(CONT.AND.LOC_COLON.NE.0)GET-SWITCH-VALUES 00890 00630 . ...FIN 00891 00631 ...FIN ---------------------------------------- 00892 00633 TO GET-SWITCH-NAME 00893 00633 C . 00894 00633 C . FIND END OF NAME=COLON OR END OF SW STRING 00895 00633 C . 00896 00634 . ICHAR=I_STRT_SW 00897 00635 . LEND=I_END_SW 00898 00636 . SEARCH_CHAR=COLON 00899 00638 . LOOK-FOR-CHAR 00900 00639 . LOC_COLON=ICHAR 00901 00641 . WHEN(ICHAR.EQ.0)I=I_END_SW 00902 00644 . ELSE I=ICHAR-1 00903 00645 . WHEN(LINE(I_STRT_SW).EQ.MINUS) 00904 00646 . . SW_NEG=.TRUE. 00905 00647 . . I_STRT_SW=I_STRT_SW+1 00906 00647 . ...FIN 00907 00650 . ELSE SW_NEG=.FALSE. 00908 00651 . J=I-I_STRT_SW+1 00909 00651 . CONDITIONAL 00910 00652 . . (J.LE.0) 00911 00653 . . . LOC_ERROR=I 00912 00655 . . . REPORT-SEMANTIC-ERROR 00913 00655 . . ...FIN 00914 00657 . . (J.EQ.1) 00915 00658 . . . NAM(1)=LINE(I_STRT_SW) 00916 00659 . . . NAM(2)=0 00917 00659 . . ...FIN 00918 00660 . . (OTHERWISE) 00919 00661 . . . NAM(1)=LINE(I_STRT_SW) 00920 00662 . . . NAM(2)=LINE(I_STRT_SW+1) 00921 00662 . . ...FIN 00922 00663 . ...FIN 00923 00664 . IF(CONT) 00924 00664 C . . 00925 00664 C . . IS SW IN SW TABLE? (NOTE EQUIV(NAM(1),INAM)) 00926 00664 C . . 00927 00665 . . J=1 00928 00668 . . UNTIL(J.GT.MAX_NUM_SW.OR.INAM.EQ.INAME(J))J=J+1 00929 00669 . . WHEN(J.GT.MAX_NUM_SW) 00930 00670 . . . LOC_ERROR=I_END_SW 00931 00672 . . . REPORT-SEMANTIC-ERROR 00932 00672 . . ...FIN 00933 00674 . . ELSE 00934 00675 . . . NSW=J FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00022 CSIGO,CSIGO=CSIGO 00935 00676 . . . TMP_SW_STATE(NSW)=.NOT.SW_NEG 00936 00676 . . ...FIN 00937 00677 . ...FIN 00938 00678 ...FIN ---------------------------------------- 00939 00680 TO REPORT-SEMANTIC-ERROR 00940 00680 C . 00941 00680 C . REPORT SEMANTIC ERROR; ASSUMES POSITION OF ERROR IS IN LOC_ERROR 00942 00680 C . 00943 00681 . TYPE 2,(LINE(I),I=1,LOC_ERROR) 00944 00682 2 . FORMAT(' CSIGO--INVALID OR IMPROPERLY SPECIFIED SW OR VALUE:',/, 00945 00683 1. (1X,70A1)) 00946 00684 . CONT=.FALSE. 00947 00684 ...FIN ---------------------------------------- 00948 00686 TO GET-SWITCH-VALUES 00949 00686 C . 00950 00686 C . LOC_COLON SHOULD BE POINTING TO COLON BEFORE 1ST VALUE 00951 00686 C . 00952 00687 . NVAL=0 00953 00688 . WHILE(LOC_COLON.NE.0.AND.CONT) 00954 00689 . . NVAL=NVAL+1 00955 00689 C . . 00956 00689 C . . TOO MANY SW VALUES GIVEN? 00957 00689 C . . 00958 00690 . . TST=SW_VALUE_CHAIN(1,NSW).EQ.0.OR. 00959 00691 1. . (NVAL.GT.SW_VALUE_CHAIN(2,NSW)-SW_VALUE_CHAIN(1,NSW)+1) 00960 00692 . . WHEN(TST) 00961 00693 . . . LOC_ERROR=LOC_COLON 00962 00695 . . . REPORT-SEMANTIC-ERROR 00963 00695 . . ...FIN 00964 00697 . . ELSE 00965 00697 C . . . 00966 00697 C . . . OK, FIND END OF THIS VALUE=COLON OR END OF SW STRING 00967 00697 C . . . 00968 00698 . . . I_STRT_VAL=LOC_COLON+1 00969 00699 . . . ICHAR=I_STRT_VAL 00970 00700 . . . LEND=I_END_SW 00971 00701 . . . SEARCH_CHAR=COLON 00972 00703 . . . LOOK-FOR-CHAR 00973 00704 . . . LOC_COLON=ICHAR 00974 00706 . . . WHEN(ICHAR.EQ.0)I_END_VAL=I_END_SW 00975 00709 . . . ELSE I_END_VAL=ICHAR-1 00976 00709 C . . . 00977 00709 C . . . I = data type for the sw value. 00978 00709 C . . . 00979 00710 . . . I=SW_VALUE_LENGTH(SW_VALUE_CHAIN(1,NSW)+NVAL-1) 00980 00710 . . . 00981 00711 . . . IF (I.LT.1.AND.I.GT.-30) THEN !861031 00982 00711 . . . . 00983 00711 C . . . . For integer values, see if radix override given=%D, %O, %X FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00023 CSIGO,CSIGO=CSIGO 00984 00711 . . . . 00985 00712 . . . . IF (LINE(I_STRT_VAL).EQ.1H%) THEN !861031 00986 00712 . . . . . 00987 00713 . . . . . TST = LINE(I_STRT_VAL+1) !radix type !861031 00988 00714 . . . . . IF (TST.EQ.1HD .OR. TST.EQ.1Hd) THEN !861031 00989 00715 . . . . . . I=I/10*10 !set to decimal I*2, 1 or 4 !861031 00990 00716 . . . . . . I_STRT_VAL = I_STRT_VAL+2 !861031 00991 00717 . . . . . ELSEIF (TST.EQ.1HO .OR. TST.EQ.1Ho) THEN !861031 00992 00718 . . . . . . I=I/10*10-1 !set to octal I*2, 1 or 4 !861031 00993 00719 . . . . . . I_STRT_VAL = I_STRT_VAL+2 !861031 00994 00720 . . . . . ELSEIF (TST.EQ.1HX .OR. TST.EQ.1Hx) THEN !861031 00995 00721 . . . . . . I=I/10*10-2 !set to hex I*2, 1 or 4 !861031 00996 00722 . . . . . . I_STRT_VAL = I_STRT_VAL+2 !861031 00997 00723 . . . . . ELSE !861031 00998 00724 . . . . . . I_END_VAL = I_STRT_VAL+1 !illegal radix !861031 00999 00725 . . . . . . GOTO 1000 !861031 01000 00726 . . . . . ENDIF !861031 01001 00727 . . . . ENDIF !861031 01002 00728 . . . ENDIF !861031 01003 00728 . . . 01004 00728 . . . CONDITIONAL 01005 00729 . . . . (I_END_VAL-I_STRT_VAL.LT.0) 01006 00730 . . . . . CONTINUE !NULL STRING REQUIRES NO ACTION, DEFAULT ALREADY SET 01007 00730 . . . . ...FIN 01008 00731 . . . . (I.GT.0) 01009 00731 C . . . . . 01010 00731 C . . . . . ASCII STRING 01011 00731 C . . . . . 01012 00732 . . . . . IF(I.LT.I_END_VAL-I_STRT_VAL+1)I_END_VAL=I_STRT_VAL+I-1 01013 00733 . . . . . TMP_SW_VALUE(1,SW_VALUE_CHAIN(1,NSW)+NVAL-1)=I_STRT_VAL 01014 00734 . . . . . TMP_SW_VALUE(2,SW_VALUE_CHAIN(1,NSW)+NVAL-1)=I_END_VAL 01015 00734 . . . . ...FIN 01016 00735 . . . . (I.EQ.0 .OR. I.EQ.-10 .OR. I.EQ.-20) !861031 01017 00735 C . . . . . 01018 00735 C . . . . . DECIMAL INTEGER*2, *1 or *4 01019 00735 C . . . . . 01020 00736 . . . . . DECODE(I_END_VAL-I_STRT_VAL+1,3,LINE(I_STRT_VAL),ERR=1000)J 01021 00737 3 . . . . . FORMAT(I20) !861031 01022 00737 . . . . . 01023 00737 C . . . . . Most negative number is illegal; also check if in range 01024 00737 . . . . . 01025 00738 . . . . . IF (I.EQ.0) THEN !861031 01026 00739 . . . . . . IF (J.LT.-32767 .OR. J.GT.32767) GOTO 1000 !861031 01027 00739 . . . . . . 01028 00740 . . . . . ELSEIF (I.EQ.-10) THEN !861031 01029 00741 . . . . . . IF (J.LT.-127 .OR. J.GT.127) GOTO 1000 !861031 01030 00741 . . . . . . 01031 00742 . . . . . ELSE !861031 01032 00743 . . . . . . IF (J.EQ.-2147483648) GOTO 1000 !861031 01033 00743 . . . . . . 01034 00744 . . . . . ENDIF 01035 00744 . . . . . 01036 00745 . . . . . TMP_SW_VALUE(1,SW_VALUE_CHAIN(1,NSW)+NVAL-1)=J 01037 00745 . . . . ...FIN 01038 00746 . . . . (I.EQ.-1 .OR. I.EQ.-11 .OR. I.EQ.-21) !861031 FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00024 CSIGO,CSIGO=CSIGO 01039 00746 C . . . . . 01040 00746 C . . . . . OCTAL INTEGER*2, *1 or *4 01041 00746 C . . . . . 01042 00747 . . . . . DECODE(I_END_VAL-I_STRT_VAL+1,4,LINE(I_STRT_VAL),ERR=1000)J 01043 00748 4 . . . . . FORMAT(O20) !861031 01044 00748 . . . . . 01045 00748 C . . . . . Most negative number is illegal; also check if in range 01046 00748 . . . . . 01047 00749 . . . . . IF (I.EQ.-1) THEN !861031 01048 00750 . . . . . . IF (J.LT.-32767 .OR. J.GT.32767) GOTO 1000 !861031 01049 00750 . . . . . . 01050 00751 . . . . . ELSEIF (I.EQ.-11) THEN !861031 01051 00752 . . . . . . IF (J.LT.-127 .OR. J.GT.127) GOTO 1000 !861031 01052 00752 . . . . . . 01053 00753 . . . . . ELSE !861031 01054 00754 . . . . . . IF (J.EQ.-2147483648) GOTO 1000 !861031 01055 00754 . . . . . . 01056 00755 . . . . . ENDIF 01057 00755 . . . . . 01058 00756 . . . . . TMP_SW_VALUE(1,SW_VALUE_CHAIN(1,NSW)+NVAL-1)=J 01059 00756 . . . . ...FIN 01060 00757 . . . . (I.EQ.-2 .OR. I.EQ.-12 .OR. I.EQ.-22) !861031 01061 00757 C . . . . . 01062 00757 C . . . . . HEX INTEGER*2, *1, or *4 01063 00757 C . . . . . 01064 00758 . . . . . DECODE(I_END_VAL-I_STRT_VAL+1,15,LINE(I_STRT_VAL),ERR=1000)J 01065 00759 15 . . . . . FORMAT(Z20) !861031 01066 00759 . . . . . 01067 00759 C . . . . . Most negative number is illegal; also check if in range 01068 00759 . . . . . 01069 00760 . . . . . IF (I.EQ.-1) THEN !861031 01070 00761 . . . . . . IF (J.LT.-32767 .OR. J.GT.32767) GOTO 1000 !861031 01071 00761 . . . . . . 01072 00762 . . . . . ELSEIF (I.EQ.-11) THEN !861031 01073 00763 . . . . . . IF (J.LT.-127 .OR. J.GT.127) GOTO 1000 !861031 01074 00763 . . . . . . 01075 00764 . . . . . ELSE !861031 01076 00765 . . . . . . IF (J.EQ.-2147483648) GOTO 1000 !861031 01077 00765 . . . . . . 01078 00766 . . . . . ENDIF 01079 00766 . . . . . 01080 00767 . . . . . TMP_SW_VALUE(1,SW_VALUE_CHAIN(1,NSW)+NVAL-1)=J 01081 00767 . . . . ...FIN 01082 00768 . . . . (OTHERWISE) !861031 01083 00768 C . . . . . 01084 00768 C . . . . . REAL*4 (F floating) or REAL*8 (D floating) 01085 00768 C . . . . . 01086 00769 . . . . . DECODE(I_END_VAL-I_STRT_VAL+1,16,LINE(I_STRT_VAL),ERR=1000)RR 01087 00770 16 . . . . . FORMAT(F20.0) !861031 01088 00770 . . . . . 01089 00771 . . . . . TMP_SW_VALUE_RR(SW_VALUE_CHAIN(1,NSW)+NVAL-1)=RR !861031 01090 00771 . . . . ...FIN!otherwise !861031 01091 00771 . . . . 01092 00772 . . . ...FIN!conditional 01093 00773 . . . IF(.FALSE.) FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00025 CSIGO,CSIGO=CSIGO 01094 00773 C . . . . 01095 00773 C . . . . CONVERSION ERROR FOR INTEGER VALUES 01096 00773 C . . . . 01097 00774 1000 . . . . LOC_ERROR=I_END_VAL 01098 00776 . . . . REPORT-SEMANTIC-ERROR 01099 00776 . . . ...FIN 01100 00778 . . ...FIN 01101 00779 . ...FIN 01102 00780 ...FIN ---------------------------------------- 01103 00782 TO RETURN-FILE-SPEC-POINTERS 01104 00782 C . 01105 00782 C . HERE WE RETURN INDICIES FOR VARIOUS PARTS OF FILE SPECIFIER 01106 00782 C . 01107 00783 . IF (NODIND_ADDR.NE.0) !861031 01108 00784 . . CALL LIB$MOVC3 (4,TMP_NODIND(1),%VAL(NODIND_ADDR)) !861031 01109 00784 . ...FIN!if !861031 01110 00786 . IF (DEVIND_ADDR.NE.0) !851015 01111 00787 . . CALL LIB$MOVC3 (4,TMP_DEVIND(1),%VAL(DEVIND_ADDR)) 01112 00787 . ...FIN!if !851015 01113 00789 . IF (UICIND_ADDR.NE.0) !851015 01114 00790 . . CALL LIB$MOVC3 (4,TMP_UICIND(1),%VAL(UICIND_ADDR)) 01115 00790 . ...FIN!if !851015 01116 00792 . IF (FILIND_ADDR.NE.0) !851015 01117 00793 . . CALL LIB$MOVC3 (4,TMP_FILIND(1),%VAL(FILIND_ADDR)) 01118 00793 . ...FIN!if !851015 01119 00794 ...FIN!to return-file-spec-pointers ---------------------------------------- 01120 00796 TO RETURN-SW-STATUS-AND-VALUES 01121 00796 C . 01122 00796 C . 1ST RETURN SW STATUSES 01123 00796 C . 01124 00797 . DO (I=1,NUM_SW_DFN) 01125 00798 . . CALL LIB$MOVC3 (2,TMP_SW_STATE(I),%VAL(SW_STATE_ADDR(I))) 01126 00798 . ...FIN 01127 00799 C . 01128 00799 C . NEXT RETURN SW VALUES 01129 00799 C . 01130 00800 . IF(NUM_SW_VAL_DFN.GT.0) 01131 00801 . . DO (I=1,NUM_SW_VAL_DFN) 01132 00802 . . . J = SW_VALUE_LENGTH(I) !861031 01133 00802 . . . 01134 00803 . . . IF (J.EQ.0 .OR. J.EQ.-1 .OR. J.EQ.-2) THEN !861031 01135 00804 . . . . CALL LIB$MOVC3 (2,TMP_SW_VALUE(1,I),%VAL(SW_VALUE_ADDR(I)))!I*2 01136 00804 . . . . 01137 00805 . . . ELSEIF (J.EQ.-10 .OR. J.EQ.-11 .OR. J.EQ.-12) THEN !861031 01138 00806 . . . . CALL LIB$MOVC3 (1,TMP_SW_VALUE(1,I),%VAL(SW_VALUE_ADDR(I)))!I*1 01139 00806 . . . . 01140 00807 . . . ELSEIF (J.EQ.-20 .OR. J.EQ.-21 .OR. J.EQ.-22) THEN !861031 01141 00808 . . . . CALL LIB$MOVC3 (4,TMP_SW_VALUE(1,I),%VAL(SW_VALUE_ADDR(I)))!I*4 01142 00808 . . . . FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00026 CSIGO,CSIGO=CSIGO 01143 00809 . . . ELSEIF (J.EQ.-30) THEN !861031 01144 00810 . . . . CALL LIB$MOVC3 (4,TMP_SW_VALUE(1,I),%VAL(SW_VALUE_ADDR(I)))!R*4 01145 00810 . . . . 01146 00811 . . . ELSEIF (J.EQ.-40) THEN !861031 01147 00812 . . . . CALL LIB$MOVC3 (8,TMP_SW_VALUE(1,I),%VAL(SW_VALUE_ADDR(I)))!R*8 01148 00812 . . . . 01149 00813 . . . ELSE 01150 00813 C . . . . 01151 00813 C . . . . ASCII STRING; MAY NEED TO NULL EXTEND OR TRUNCATE IT 01152 00813 C . . . . 01153 00815 . . . . WHEN(TMP_SW_VALUE(1,I).EQ.0)J=0 01154 00818 . . . ELSE J=TMP_SW_VALUE(2,I)-TMP_SW_VALUE(1,I)+1 01155 00819 . . . . CALL LIB$MOVC5 (J,LINE(TMP_SW_VALUE(1,I)),0, 01156 00820 1. . . . SW_VALUE_LENGTH(I),%VAL(SW_VALUE_ADDR(I))) 01157 00821 . . . ENDIF 01158 00821 . . . 01159 00821 . . ...FIN 01160 00822 . ...FIN 01161 00823 ...FIN ---------------------------------------- 01162 00825 TO RETURN-FLAGS 01163 00825 C . 01164 00825 C . HERE RETURN VARIOUS STATUS FLAGS 01165 00825 C . 01166 00826 . IF (MORE_ADDR.NE.0) !851015 01167 00827 . . CALL LIB$MOVC3 (2,TMP_MORE,%VAL(MORE_ADDR)) 01168 00827 . ...FIN!if !851015 01169 00829 . IF (WILD_ADDR.NE.0) !851015 01170 00830 . . CALL LIB$MOVC3 (2,TMP_WILD,%VAL(WILD_ADDR)) 01171 00830 . ...FIN!if !851015 01172 00832 . IF (EQUAL_ADDR.NE.0) !851015 01173 00833 . . CALL LIB$MOVC3 (2,TMP_EQUAL,%VAL(EQUAL_ADDR)) 01174 00833 . ...FIN!if !851015 01175 00834 ...FIN 01176 00836 END ---------------------------------------- PROCEDURE CROSS-REFERENCE TABLE 00589 CHECK-DEVICE-SYNTAX 00547 00706 CHECK-FILE-SYNTAX 00549 00339 CHECK-FOR-EQUAL-SIGN 00252 00552 CHECK-NODE-SYNTAX 00546 00860 CHECK-SWITCH-SYNTAX FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00027 CSIGO,CSIGO=CSIGO 00550 00538 CHECK-SYNTAX 00264 00617 CHECK-UIC-SYNTAX 00548 00321 COMPRESS-LINE 00251 00478 EXTRACT-FILE-SPEC 00263 00875 EXTRACT-SWS-AND-VALUES 00265 00467 FIND-A-SLASH 00262 00885 00380 GET-NEXT-SUBSTRING 00258 00892 GET-SWITCH-NAME 00888 00948 GET-SWITCH-VALUES 00889 00362 LOOK-FOR-CHAR 00346 00355 00402 00417 00431 00445 00475 00486 00499 00510 00515 00624 00713 00717 00899 00972 00308 PROCESS-MORE 00249 00939 REPORT-SEMANTIC-ERROR 00912 00931 00962 01098 00372 REPORT-SYNTAX-ERROR 00358 00519 00566 00585 00613 00641 00659 00677 00701 00721 00735 00768 00783 00813 00837 00855 00870 01103 RETURN-FILE-SPEC-POINTERS 00271 01162 RETURN-FLAGS 00273 01120 RETURN-SW-STATUS-AND-VALUES 00272 00279 SET-INTERNAL-VALUES-TO-DEFAULTS 00245 FLECS VERSION 860214 2-DEC-87 06:36:18 PAGE 00028 CSIGO,CSIGO=CSIGO (FLECS VERSION 22.38)