C
C This file is issued from the MODULEF library, but has been 
C subsequently modified
C
      SUBROUTINE FONDOP(NITEM, INFIXE, IPRIOR)
C ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
C           S.P. FONDOP          (FONCTIONS INTERPRETEES)
C           -----------
C ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
C BUT :
C     DECRIRE UN OPERATEUR
C
C PARAMETRES D ENTREE :
C     NITEM   : NUMERO DE CODE DE L ITEM
C
C PARAMETRES DE SORTIE :
C     INFIXE  : 0 OPERATEUR PREFIXE, 1 OPERATEUR INFIXE
C     IPRIOR  : PRIORITE DE L OPERATEUR
C ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
C PROGRAMMEUR : PATRICK LAUG ; INRIA (3) 954 90 20 POSTE 508
C ......................................................................
      DIMENSION MPRIOR(11)
      DATA MPRIOR /2,2,3,3,5,1,1,1,1,1,1/
C
C BRANCHEMENT SELON LA CATEGORIE DE L'OPERATEUR
      GOTO (400,410,420), NITEM/1000 -39
C
C CODE (40 000 + I) : SEPARATEUR
  400 INFIXE = 0
      IPRIOR = 0
      RETURN
C
C CODE (41 000 + I) : OPERATEUR UNAIRE
  410 INFIXE = 0
      IF (NITEM .LE. 41 002) THEN
         IPRIOR = 4
      ELSE
         IPRIOR = 6
      END IF
      RETURN
C
C CODE (42 000 + I) : OPERATEUR BINAIRE
C A)  OPERATEUR BINAIRE INFIXE
C     PRIORITE    + 2    - 2    * 3    / 3    ** 5
  420 IF (NITEM .LE. 42 011) THEN
         INFIXE = 1
         IPRIOR = MPRIOR(NITEM - 42 000)
C
C B)  OPERATEUR BINAIRE PREFIXE
      ELSE
         INFIXE = 0
         IPRIOR = 6
      END IF
      END
