Create a simple, Pascal like, string to help create messages for the parser. Added a function in the Parser that accepts many TokenTypes and reports the list of types if a sync is required.
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
#ifndef PSTRING_H
|
||||
#define PSTRING_H
|
||||
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
typedef struct pstring PString;
|
||||
|
||||
PString* CreateString(void);
|
||||
void StringAppend(const char* text, PString* string);
|
||||
void StringFree(PString* string);
|
||||
void StringTruncate(PString* string);
|
||||
char* StringToCString(PString* string);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user