filelist.h
来自「编译原理的作业 编译器」· C头文件 代码 · 共 30 行
H
30 行
#ifndef FILELIST_H_
#define FILELIST_H_
#include "config.h"
class FileList
{
public:
static FileList& GetInstance()
{
if (_instance == NULL)
{
_instance = new FileList();
return *_instance;
}
return *_instance;
}
char _buffer[LISTFILE_LENGTH];
int _curPos;
int _cerrs;
static const char* ValueType[];
private:
FileList()
:_curPos(0), _cerrs(0)
{}
static FileList* _instance;
};
#endif