⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 crs.h

📁 C/C++词法语法分析程序
💻 H
字号:
/**********************************************************
**   SCAN_H.FRM
**   Coco/R C Support Frames.
**   Author: Frankie Arzu <farzu@uvg.edu.gt>
**
**   Jun 12, 1996   Version 1.06
**      Many fixes and suggestions thanks to
**      Pat Terry <cspt@cs.ru.ac.za>
**   Oct 11, 1997   Version 1.07 (No change)
**   Mar 13, 1998   Version 1.08 (No change)
**********************************************************/

#ifndef SCAN_HEADER_INCLUDE
#define SCAN_HEADER_INCLUDE

#include "crc.h"

#define  TAB_CHAR  9
#define  LF_CHAR   10
#define  CR_CHAR   13
#define  EOF_CHAR  0

#define  TAB_SIZE  8

extern int  S_src;         /* source file */
extern int  S_Line, S_Col; /* line and column of current symbol */
extern int  S_Len;         /* length of current symbol */
extern long S_Pos;         /* file position of current symbol */
extern int  S_NextLine;    /* line of lookahead symbol */
extern int  S_NextCol;     /* column of lookahead symbol */
extern int  S_NextLen;     /* length of lookahead symbol */
extern long S_NextPos;     /* file position of lookahead symbol */
extern int  S_CurrLine;    /* current input line (may be higher than line) */
extern long S_lineStart;   /* start position of current line */

int S_Get();
/* Gets next symbol from source file */

void S_Reset();
/* Reads and stores source file internally */
/* Assert: S_src has been opened */

void S_GetString(long pos, int len, char *s, int max);
/* Retrieves exact string of max length len at position pos in source file */

void S_GetName(long pos, int len, char *s, int max);
/* Retrieves an string of max length len at position pos in source file.  Each
   character in the string will be capitalized if IGNORE CASE is specified */

unsigned char S_CurrentCh(long pos);
/* Returns current character at specified file position */

#endif /* SCAN_HEADER_INCLUDE */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -