      SUBROUTINE PC.PARSE.ALT(S,OBJ)
*PRE-COMPILER
*
*DEV TRIAL RT
*BASIC
*N
*     PRECISION 6
*
************************************************************************
************************************************************************
***                                                                  ***
*** PICK PARSING PRE-COMPILER SYSTEM                                 ***
***                                                                  ***
*** COPYRIGHT 1988 MODULAR SOFTWARE                                  ***
***                P.O. BOX 204                                      ***
***                ATLANTA, GA  30291                                ***
***                (404) 964 - 7171                                  ***
***                                                                  ***
*** THIS PROGRAM IS PROPRIETARY TO MODULAR SOFTWARE AND MAY NOT BE   ***
*** USED, COPIED, EXAMINED, OR DISCLOSED WITHOUT A VALID LICENSE     ***
*** FROM MODULAR SOFTWARE.                                           ***
***                                                                  ***
************************************************************************
************************************************************************
*
*
* Pre-compiler parse routine
*
*
* PRE-COMPILE parsing routine
*
*    This version of the routine does not process escape syntax!
*
*    Multiple statements are returned at seperate ATTRIBUTES of OBJ
*
*    The statement label is returned in value 2
*    The statement itself is returned in value 1
*
      $INCLUDE PC.COMMON
*
      SEP = '(),+-/*!^:<>#=@; '
*
      O = ''
      OBJ = ''
      STMT.NO = 1
      C.FLG = NO
      NO.PAR = 0
*
      C$$$=TRIM(S)[LEN(TRIM(S)),1]
      S=S[1,INDEX(S,C$$$,COUNT(S,C$$$))]
*
      STRIP.SPACE = YES
*
      C = 1
      LOOP
         CH = S[C,1]
         C = C + 1
      UNTIL CH = '' OR C.FLG DO
         IF STRIP.SPACE THEN
            LOOP WHILE CH = ' ' DO
               CH = S[C,1]
               C = C + 1
            REPEAT
            STRIP.SPACE = NO
         END
*
         IF CH = '"' OR CH = "'" OR CH = '\' THEN
            GOSUB 100
*
            IF TRIM(OBJ<STMT.NO,1,DCOUNT(OBJ<STMT.NO,1>,SVM)>) <> '' THEN
               OBJ<STMT.NO,1,-1> = ' '
            END
*
            SS = S[C,32000]
            T = INDEX(SS,CH,1)
            IF T THEN
               O = CH : SS[1,T]
               C = C + T
            END ELSE
               O = CH : SS
               C = LEN(S) + 1
            END
            GOSUB 100
            CH = S[C,1]
            C = C + 1
         END
*
         IF CH <> '' THEN
            IF INDEX(SEP,CH,1) THEN
               GOSUB 100
               BEGIN CASE
                  CASE CH = ';' AND NOT(NO.PAR)
                     T = DCOUNT(OBJ<STMT.NO,1>,SVM)
                     IF OBJ<STMT.NO,1,T> = ' ' THEN
                        OBJ = DELETE(OBJ,STMT.NO,1,T)
                     END
                     R.STR = S[C,32000]
                     BEGIN CASE
                        CASE TRIM(R.STR)[1,1] = '*'
                           C.FLG = YES
                        CASE TRIM(R.STR)[1,1] = '!'
                           C.FLG = YES
                        CASE TRIM(R.STR)[1,1] = 'REM'
                           C.FLG = YES
                     END CASE
*
                     GOSUB 200
*
                     STMT.NO = STMT.NO + 1
                     STRIP.SPACE = YES
                  CASE YES
                     NO.PAR = NO.PAR + ( CH = '(' ) - ( CH = ')' )
                     OBJ<STMT.NO,1,-1> = CH
                     IF CH = ' ' THEN STRIP.SPACE = YES
               END CASE
            END ELSE
               O = O : CH
            END
         END
      REPEAT
*
      GOSUB 100
*
      GOSUB 200
*
      RETURN
*
100 *
*
      IF O <> '' THEN
         OBJ<STMT.NO,1,-1> = O
         O = ''
      END
*
      RETURN
*
200 * CHECK LAST STATEMENT FOR COMMENT
*
      W = OBJ<STMT.NO,1,1>
      IF W MATCHES '1N0N' THEN
         OBJ<STMT.NO,2> = W
         OBJ = DELETE(OBJ,STMT.NO,1,1)
         W = OBJ<STMT.NO,1,1>
         IF W = ' ' THEN
            OBJ = DELETE(OBJ,STMT.NO,1,1)
            W = OBJ<STMT.NO,1,1>
         END
         BEGIN CASE
            CASE W = '*'
               OBJ<STMT.NO,1> = 'NULL'
               C.FLG = YES
            CASE W = '!'
               OBJ<STMT.NO,1> = 'NULL'
               C.FLG = YES
            CASE W[1,3] = 'REM'
               OBJ<STMT.NO,1> = 'NULL'
               C.FLG = YES
         END CASE
      END ELSE
         T = INDEX('REM',W,1)
         IF T THEN
            W = W[1,T-1]
            IF W MATCHES '1N0N' THEN
               OBJ<STMT.NO,2> = W
               OBJ<STMT.NO,1> = '*'
               C.FLG = YES
            END
         END
      END
*
      RETURN
*
      CW = '(C) Copyright 1985-1989 Modular Software.  All rights reserved.'
   END
