home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-385-Vol-1of3.iso / i / iritsm3s.zip / irit / inptprsg.h < prev    next >
C/C++ Source or Header  |  1991-03-16  |  2KB  |  66 lines

  1. /*****************************************************************************
  2. *   "Irit" - the 3d polygonal solid modeller.                     *
  3. *                                         *
  4. * Written by:  Gershon Elber                Ver 0.2, Mar. 1990   *
  5. ******************************************************************************
  6. * General, Visible to others, definitions for the Input Parser module.         *
  7. *****************************************************************************/
  8.  
  9. #ifndef    INPT_PRSR_GH
  10. #define    INPT_PRSR_GH
  11.  
  12. /*****************************************************************************
  13. * Error    numbers    as located during the parsing process:                 *
  14. *****************************************************************************/
  15. typedef enum {
  16.     IPE_NO_ERR = 0,
  17.  
  18.     IP_ERR_WRONG_SYNTAX,
  19.     IP_ERR_PARAM_EXPECT,
  20.     IP_ERR_ONE_OPERAND,
  21.     IP_ERR_TWO_OPERAND,
  22.     IP_ERR_STACK_OV,
  23.     IP_ERR_PARAM_MATCH,
  24.     IP_ERR_UNDEF_TOKEN,
  25.     IP_ERR_UNDEF_FUNC,
  26.     IP_ERR_NAME_TOO_LONG,
  27.     IP_ERR_PARAM_FUNC,
  28.     IP_ERR_NO_PARAM_FUNC,
  29.  
  30. /*****************************************************************************
  31. * Error    as located during the evaluation process:                 *
  32. *****************************************************************************/
  33.  
  34.     IE_ERR_FATAL_ERROR,
  35.     IE_ERR_DIV_BY_ZERO,
  36.     IE_ERR_NO_OBJ_METHOD,
  37.     IE_ERR_TYPE_MISMATCH,
  38.     IE_ERR_ASSIGN_LEFT_OP,
  39.     IE_ERR_MIXED_OBJ,
  40.     IE_ERR_UNDEF_OBJECT,
  41.     IE_ERR_NO_ASSIGNMENT,
  42.     IE_ERR_FP_ERROR,
  43.     IE_ERR_NUM_PRM_MISMATCH,
  44.     IE_ERR_MAT_POWER,
  45.     IE_ERR_FREE_SIMPLE,
  46.     IE_ERR_MODIF_ITER_VAR,
  47.     IE_ERR_BOOLEAN_ERR,
  48.     IE_ERR_LIST_TOO_LONG,
  49.     IE_ERR_DATA_PRSR_ERROR
  50. } InptPrsrEvalErrType;
  51.  
  52. /*****************************************************************************
  53. * The global (visible to others) function prototypes:                 *
  54. *****************************************************************************/
  55. int InputParser(void);
  56. /* If the above returns NULL object the following might be called to find    */
  57. /* What went wrong (In the parsing stage, or in the evaluation stage.         */
  58. InptPrsrEvalErrType InptPrsrParseError(char **Message);
  59. InptPrsrEvalErrType InptPrsrEvalError(char **Message);
  60.  
  61. void FileInclude(char *FileName);  /* Used to insert files on include stack. */
  62.  
  63. void AliasReset(void);                /* Reset the aliases buffer. */
  64.  
  65. #endif    /* INPT_PRSR_GH */
  66.