improvements to the lexer

master
Allen Webster 2016-08-30 15:30:41 -04:00
parent 1ea3523483
commit 9d2384b3b9
17 changed files with 946 additions and 1492 deletions

View File

@ -3,6 +3,10 @@
#define FCODER_CUSTOM_H #define FCODER_CUSTOM_H
#include <stdint.h> #include <stdint.h>
// TODO(allen): We need to eliminate our dependence on this
// in the custom side.
#include <string.h>
#include "4coder_version.h" #include "4coder_version.h"
#include "4coder_keycodes.h" #include "4coder_keycodes.h"

View File

@ -55,65 +55,63 @@
#define DIRECTORY_CD_SIG(n) bool32 n(Application_Links *app, char *dir, int32_t *len, int32_t capacity, char *rel_path, int32_t rel_len) #define DIRECTORY_CD_SIG(n) bool32 n(Application_Links *app, char *dir, int32_t *len, int32_t capacity, char *rel_path, int32_t rel_len)
#define GET_4ED_PATH_SIG(n) bool32 n(Application_Links *app, char *out, int32_t capacity) #define GET_4ED_PATH_SIG(n) bool32 n(Application_Links *app, char *out, int32_t capacity)
#define SHOW_MOUSE_CURSOR_SIG(n) void n(Application_Links *app, Mouse_Cursor_Show_Type show) #define SHOW_MOUSE_CURSOR_SIG(n) void n(Application_Links *app, Mouse_Cursor_Show_Type show)
extern "C"{ typedef EXEC_COMMAND_SIG(Exec_Command_Function);
typedef EXEC_COMMAND_SIG(Exec_Command_Function); typedef EXEC_SYSTEM_COMMAND_SIG(Exec_System_Command_Function);
typedef EXEC_SYSTEM_COMMAND_SIG(Exec_System_Command_Function); typedef CLIPBOARD_POST_SIG(Clipboard_Post_Function);
typedef CLIPBOARD_POST_SIG(Clipboard_Post_Function); typedef CLIPBOARD_COUNT_SIG(Clipboard_Count_Function);
typedef CLIPBOARD_COUNT_SIG(Clipboard_Count_Function); typedef CLIPBOARD_INDEX_SIG(Clipboard_Index_Function);
typedef CLIPBOARD_INDEX_SIG(Clipboard_Index_Function); typedef GET_BUFFER_COUNT_SIG(Get_Buffer_Count_Function);
typedef GET_BUFFER_COUNT_SIG(Get_Buffer_Count_Function); typedef GET_BUFFER_FIRST_SIG(Get_Buffer_First_Function);
typedef GET_BUFFER_FIRST_SIG(Get_Buffer_First_Function); typedef GET_BUFFER_NEXT_SIG(Get_Buffer_Next_Function);
typedef GET_BUFFER_NEXT_SIG(Get_Buffer_Next_Function); typedef GET_BUFFER_SIG(Get_Buffer_Function);
typedef GET_BUFFER_SIG(Get_Buffer_Function); typedef GET_BUFFER_BY_NAME_SIG(Get_Buffer_By_Name_Function);
typedef GET_BUFFER_BY_NAME_SIG(Get_Buffer_By_Name_Function); typedef BUFFER_BOUNDARY_SEEK_SIG(Buffer_Boundary_Seek_Function);
typedef BUFFER_BOUNDARY_SEEK_SIG(Buffer_Boundary_Seek_Function); typedef BUFFER_READ_RANGE_SIG(Buffer_Read_Range_Function);
typedef BUFFER_READ_RANGE_SIG(Buffer_Read_Range_Function); typedef BUFFER_REPLACE_RANGE_SIG(Buffer_Replace_Range_Function);
typedef BUFFER_REPLACE_RANGE_SIG(Buffer_Replace_Range_Function); typedef BUFFER_COMPUTE_CURSOR_SIG(Buffer_Compute_Cursor_Function);
typedef BUFFER_COMPUTE_CURSOR_SIG(Buffer_Compute_Cursor_Function); typedef BUFFER_BATCH_EDIT_SIG(Buffer_Batch_Edit_Function);
typedef BUFFER_BATCH_EDIT_SIG(Buffer_Batch_Edit_Function); typedef BUFFER_SET_SETTING_SIG(Buffer_Set_Setting_Function);
typedef BUFFER_SET_SETTING_SIG(Buffer_Set_Setting_Function); typedef BUFFER_AUTO_INDENT_SIG(Buffer_Auto_Indent_Function);
typedef BUFFER_AUTO_INDENT_SIG(Buffer_Auto_Indent_Function); typedef CREATE_BUFFER_SIG(Create_Buffer_Function);
typedef CREATE_BUFFER_SIG(Create_Buffer_Function); typedef SAVE_BUFFER_SIG(Save_Buffer_Function);
typedef SAVE_BUFFER_SIG(Save_Buffer_Function); typedef KILL_BUFFER_SIG(Kill_Buffer_Function);
typedef KILL_BUFFER_SIG(Kill_Buffer_Function); typedef GET_VIEW_FIRST_SIG(Get_View_First_Function);
typedef GET_VIEW_FIRST_SIG(Get_View_First_Function); typedef GET_VIEW_NEXT_SIG(Get_View_Next_Function);
typedef GET_VIEW_NEXT_SIG(Get_View_Next_Function); typedef GET_VIEW_SIG(Get_View_Function);
typedef GET_VIEW_SIG(Get_View_Function); typedef GET_ACTIVE_VIEW_SIG(Get_Active_View_Function);
typedef GET_ACTIVE_VIEW_SIG(Get_Active_View_Function); typedef OPEN_VIEW_SIG(Open_View_Function);
typedef OPEN_VIEW_SIG(Open_View_Function); typedef CLOSE_VIEW_SIG(Close_View_Function);
typedef CLOSE_VIEW_SIG(Close_View_Function); typedef SET_ACTIVE_VIEW_SIG(Set_Active_View_Function);
typedef SET_ACTIVE_VIEW_SIG(Set_Active_View_Function); typedef VIEW_SET_SETTING_SIG(View_Set_Setting_Function);
typedef VIEW_SET_SETTING_SIG(View_Set_Setting_Function); typedef VIEW_SET_SPLIT_PROPORTION_SIG(View_Set_Split_Proportion_Function);
typedef VIEW_SET_SPLIT_PROPORTION_SIG(View_Set_Split_Proportion_Function); typedef VIEW_COMPUTE_CURSOR_SIG(View_Compute_Cursor_Function);
typedef VIEW_COMPUTE_CURSOR_SIG(View_Compute_Cursor_Function); typedef VIEW_SET_CURSOR_SIG(View_Set_Cursor_Function);
typedef VIEW_SET_CURSOR_SIG(View_Set_Cursor_Function); typedef VIEW_SET_SCROLL_SIG(View_Set_Scroll_Function);
typedef VIEW_SET_SCROLL_SIG(View_Set_Scroll_Function); typedef VIEW_SET_MARK_SIG(View_Set_Mark_Function);
typedef VIEW_SET_MARK_SIG(View_Set_Mark_Function); typedef VIEW_SET_HIGHLIGHT_SIG(View_Set_Highlight_Function);
typedef VIEW_SET_HIGHLIGHT_SIG(View_Set_Highlight_Function); typedef VIEW_SET_BUFFER_SIG(View_Set_Buffer_Function);
typedef VIEW_SET_BUFFER_SIG(View_Set_Buffer_Function); typedef VIEW_POST_FADE_SIG(View_Post_Fade_Function);
typedef VIEW_POST_FADE_SIG(View_Post_Fade_Function); typedef GET_USER_INPUT_SIG(Get_User_Input_Function);
typedef GET_USER_INPUT_SIG(Get_User_Input_Function); typedef GET_COMMAND_INPUT_SIG(Get_Command_Input_Function);
typedef GET_COMMAND_INPUT_SIG(Get_Command_Input_Function); typedef GET_MOUSE_STATE_SIG(Get_Mouse_State_Function);
typedef GET_MOUSE_STATE_SIG(Get_Mouse_State_Function); typedef START_QUERY_BAR_SIG(Start_Query_Bar_Function);
typedef START_QUERY_BAR_SIG(Start_Query_Bar_Function); typedef END_QUERY_BAR_SIG(End_Query_Bar_Function);
typedef END_QUERY_BAR_SIG(End_Query_Bar_Function); typedef PRINT_MESSAGE_SIG(Print_Message_Function);
typedef PRINT_MESSAGE_SIG(Print_Message_Function); typedef CHANGE_THEME_SIG(Change_Theme_Function);
typedef CHANGE_THEME_SIG(Change_Theme_Function); typedef CHANGE_FONT_SIG(Change_Font_Function);
typedef CHANGE_FONT_SIG(Change_Font_Function); typedef BUFFER_SET_FONT_SIG(Buffer_Set_Font_Function);
typedef BUFFER_SET_FONT_SIG(Buffer_Set_Font_Function); typedef SET_THEME_COLORS_SIG(Set_Theme_Colors_Function);
typedef SET_THEME_COLORS_SIG(Set_Theme_Colors_Function); typedef GET_THEME_COLORS_SIG(Get_Theme_Colors_Function);
typedef GET_THEME_COLORS_SIG(Get_Theme_Colors_Function); typedef DIRECTORY_GET_HOT_SIG(Directory_Get_Hot_Function);
typedef DIRECTORY_GET_HOT_SIG(Directory_Get_Hot_Function); typedef GET_FILE_LIST_SIG(Get_File_List_Function);
typedef GET_FILE_LIST_SIG(Get_File_List_Function); typedef FREE_FILE_LIST_SIG(Free_File_List_Function);
typedef FREE_FILE_LIST_SIG(Free_File_List_Function); typedef MEMORY_ALLOCATE_SIG(Memory_Allocate_Function);
typedef MEMORY_ALLOCATE_SIG(Memory_Allocate_Function); typedef MEMORY_SET_PROTECTION_SIG(Memory_Set_Protection_Function);
typedef MEMORY_SET_PROTECTION_SIG(Memory_Set_Protection_Function); typedef MEMORY_FREE_SIG(Memory_Free_Function);
typedef MEMORY_FREE_SIG(Memory_Free_Function); typedef FILE_EXISTS_SIG(File_Exists_Function);
typedef FILE_EXISTS_SIG(File_Exists_Function); typedef DIRECTORY_CD_SIG(Directory_CD_Function);
typedef DIRECTORY_CD_SIG(Directory_CD_Function); typedef GET_4ED_PATH_SIG(Get_4ed_Path_Function);
typedef GET_4ED_PATH_SIG(Get_4ed_Path_Function); typedef SHOW_MOUSE_CURSOR_SIG(Show_Mouse_Cursor_Function);
typedef SHOW_MOUSE_CURSOR_SIG(Show_Mouse_Cursor_Function);
}
struct Application_Links{ struct Application_Links{
void *memory; void *memory;
int32_t memory_size; int32_t memory_size;

View File

@ -95,7 +95,7 @@ parse_error(String line, Jump_Location *location,
int32_t colon_pos2 = find_s_char(line, colon_pos1+1, ':'); int32_t colon_pos2 = find_s_char(line, colon_pos1+1, ':');
int32_t colon_pos3 = find_s_char(line, colon_pos2+1, ':'); int32_t colon_pos3 = find_s_char(line, colon_pos2+1, ':');
if (colon_pos3 < line.size){ if (colon_pos3+1 < line.size && line.str[colon_pos3+1] == ' '){
String filename = substr(line, 0, colon_pos1); String filename = substr(line, 0, colon_pos1);
String line_number = substr(line, colon_pos1+1, colon_pos2 - colon_pos1 - 1); String line_number = substr(line, colon_pos1+1, colon_pos2 - colon_pos1 - 1);
String column_number = substr(line, colon_pos2+1, colon_pos3 - colon_pos2 - 1); String column_number = substr(line, colon_pos2+1, colon_pos3 - colon_pos2 - 1);
@ -120,7 +120,7 @@ parse_error(String line, Jump_Location *location,
colon_pos2 = find_s_char(line, colon_pos1+1, ':'); colon_pos2 = find_s_char(line, colon_pos1+1, ':');
if (colon_pos2 < line.size){ if (colon_pos2+1 < line.size && line.str[colon_pos2+1] == ' '){
String filename = substr(line, 0, colon_pos1); String filename = substr(line, 0, colon_pos1);
String line_number = substr(line, colon_pos1+1, colon_pos2 - colon_pos1 - 1); String line_number = substr(line, colon_pos1+1, colon_pos2 - colon_pos1 - 1);

View File

@ -78,9 +78,9 @@ This is a very week general purpose allocator system.
It should only be used for infrequent large allocations (4K+). It should only be used for infrequent large allocations (4K+).
*/ */
#include <stdint.h> //#include <stdint.h>
#include <assert.h> //#include <assert.h>
#include <string.h> //#include <string.h>
enum{ enum{
MEM_BUBBLE_FLAG_INIT = 0x0, MEM_BUBBLE_FLAG_INIT = 0x0,
@ -159,29 +159,34 @@ general_memory_open(General_Memory *general, void *memory, int32_t size){
insert_bubble2(&general->free_sentinel, first); insert_bubble2(&general->free_sentinel, first);
} }
#ifdef Assert
static int32_t static int32_t
general_memory_check(General_Memory *general){ general_memory_check(General_Memory *general){
Bubble *sentinel = &general->sentinel; Bubble *sentinel = &general->sentinel;
for (Bubble *bubble = sentinel->next; for (Bubble *bubble = sentinel->next;
bubble != sentinel; bubble != sentinel;
bubble = bubble->next){ bubble = bubble->next){
assert(bubble); Assert(bubble);
Bubble *next = bubble->next; Bubble *next = bubble->next;
assert(bubble == next->prev); Assert(bubble == next->prev);
if (next != sentinel && bubble->prev != sentinel){ if (next != sentinel && bubble->prev != sentinel){
assert(bubble->next > bubble); Assert(bubble->next > bubble);
assert(bubble > bubble->prev); Assert(bubble > bubble->prev);
char *end_ptr = (char*)(bubble + 1) + bubble->size; char *end_ptr = (char*)(bubble + 1) + bubble->size;
char *next_ptr = (char*)next; char *next_ptr = (char*)next;
(void)(end_ptr); (void)(end_ptr);
(void)(next_ptr); (void)(next_ptr);
assert(end_ptr == next_ptr); Assert(end_ptr == next_ptr);
} }
} }
return(1); return(1);
} }
#else
static int32_t
general_memory_check(General_Memory *general){}
#endif
#define BUBBLE_MIN_SIZE 1024 #define BUBBLE_MIN_SIZE 1024
@ -221,8 +226,6 @@ general_memory_allocate(General_Memory *general, int32_t size){
inline void inline void
general_memory_do_merge(Bubble *left, Bubble *right){ general_memory_do_merge(Bubble *left, Bubble *right){
assert(left->next == right);
assert(right->prev == left);
left->size += sizeof(Bubble) + right->size; left->size += sizeof(Bubble) + right->size;
remove_bubble(right); remove_bubble(right);
remove_bubble2(right); remove_bubble2(right);
@ -238,7 +241,6 @@ general_memory_attempt_merge(Bubble *left, Bubble *right){
static void static void
general_memory_free(General_Memory *general, void *memory){ general_memory_free(General_Memory *general, void *memory){
Bubble *bubble = ((Bubble*)memory) - 1; Bubble *bubble = ((Bubble*)memory) - 1;
assert(bubble->flags == MEM_BUBBLE_USED);
bubble->flags = 0; bubble->flags = 0;
remove_bubble2(bubble); remove_bubble2(bubble);

7
4coder_os_custom_api.h Normal file
View File

@ -0,0 +1,7 @@
#define MEMORY_ALLOCATE_SIG(n) void* n(Application_Links *app, int32_t size)
#define MEMORY_SET_PROTECTION_SIG(n) bool32 n(Application_Links *app, void *ptr, int32_t size, Memory_Protect_Flags flags)
#define MEMORY_FREE_SIG(n) void n(Application_Links *app, void *mem, int32_t size)
#define FILE_EXISTS_SIG(n) bool32 n(Application_Links *app, char *filename, int32_t len)
#define DIRECTORY_CD_SIG(n) bool32 n(Application_Links *app, char *dir, int32_t *len, int32_t capacity, char *rel_path, int32_t rel_len)
#define GET_4ED_PATH_SIG(n) bool32 n(Application_Links *app, char *out, int32_t capacity)
#define SHOW_MOUSE_CURSOR_SIG(n) void n(Application_Links *app, Mouse_Cursor_Show_Type show)

View File

@ -4,6 +4,10 @@
#ifndef FCPP_NEW_LEXER_INC #ifndef FCPP_NEW_LEXER_INC
#define FCPP_NEW_LEXER_INC #define FCPP_NEW_LEXER_INC
#ifndef Assert
# define Assert(n) do{ if (!(n)) *(int*)0 = 0xA11E; }while(0)
#endif
#ifndef FCPP_LINK #ifndef FCPP_LINK
# define FCPP_LINK static # define FCPP_LINK static
#endif #endif
@ -23,13 +27,40 @@ struct String_List{
int32_t count; int32_t count;
}; };
struct Sub_Match_List_Result{
int32_t index;
int32_t new_pos;
};
#define lexer_string_list(x) {x, (sizeof(x)/sizeof(*(x)))} #define lexer_string_list(x) {x, (sizeof(x)/sizeof(*(x)))}
static String_And_Flag preprop_strings[] = {
{"include", CPP_PP_INCLUDE},
{"INCLUDE", CPP_PP_INCLUDE},
{"ifndef", CPP_PP_IFNDEF},
{"IFNDEF", CPP_PP_IFNDEF},
{"define", CPP_PP_DEFINE},
{"DEFINE", CPP_PP_DEFINE},
{"import", CPP_PP_IMPORT},
{"IMPORT", CPP_PP_IMPORT},
{"pragma", CPP_PP_PRAGMA},
{"PRAGMA", CPP_PP_PRAGMA},
{"undef", CPP_PP_UNDEF},
{"UNDEF", CPP_PP_UNDEF},
{"endif", CPP_PP_ENDIF},
{"ENDIF", CPP_PP_ENDIF},
{"error", CPP_PP_ERROR},
{"ERROR", CPP_PP_ERROR},
{"ifdef", CPP_PP_IFDEF},
{"IFDEF", CPP_PP_IFDEF},
{"using", CPP_PP_USING},
{"USING", CPP_PP_USING},
{"else", CPP_PP_ELSE},
{"ELSE", CPP_PP_ELSE},
{"elif", CPP_PP_ELIF},
{"ELIF", CPP_PP_ELIF},
{"line", CPP_PP_LINE},
{"LINE", CPP_PP_LINE},
{"if", CPP_PP_IF},
{"IF", CPP_PP_IF},
};
static String_List preprops = lexer_string_list(preprop_strings);
static String_And_Flag keyword_strings[] = { static String_And_Flag keyword_strings[] = {
{"true", CPP_TOKEN_BOOLEAN_CONSTANT}, {"true", CPP_TOKEN_BOOLEAN_CONSTANT},
{"false", CPP_TOKEN_BOOLEAN_CONSTANT}, {"false", CPP_TOKEN_BOOLEAN_CONSTANT},
@ -121,23 +152,21 @@ static String_And_Flag keyword_strings[] = {
}; };
static String_List keywords = lexer_string_list(keyword_strings); static String_List keywords = lexer_string_list(keyword_strings);
FCPP_LINK Sub_Match_List_Result FCPP_LINK int32_t
sub_match_list(char *chunk, int32_t size, int32_t pos, String_List list, int32_t sub_size){ sub_match_list(char *chunk, int32_t size, String_List list, int32_t sub_size){
Sub_Match_List_Result result; int32_t result = 0;
String str_main; String str_main = {0};
char *str_check; char *str_check = 0;
int32_t i,l; int32_t i = 0, l = 0;
result.index = -1; result = -1;
result.new_pos = pos; str_main = make_string(chunk, size);
str_main = make_string(chunk + pos, size - pos);
if (sub_size > 0){ if (sub_size > 0){
str_main = substr(str_main, 0, sub_size); str_main = substr(str_main, 0, sub_size);
for (i = 0; i < list.count; ++i){ for (i = 0; i < list.count; ++i){
str_check = list.data[i].str; str_check = list.data[i].str;
if (match_sc(str_main, str_check)){ if (match_sc(str_main, str_check)){
result.index = i; result = i;
result.new_pos = pos + sub_size;
break; break;
} }
} }
@ -146,13 +175,13 @@ sub_match_list(char *chunk, int32_t size, int32_t pos, String_List list, int32_t
for (i = 0; i < list.count; ++i){ for (i = 0; i < list.count; ++i){
str_check = list.data[i].str; str_check = list.data[i].str;
if (match_part_scl(str_main, str_check, &l)){ if (match_part_scl(str_main, str_check, &l)){
result.index = i; result = i;
result.new_pos = pos + l;
break; break;
} }
} }
} }
return result;
return(result);
} }
@ -332,7 +361,7 @@ struct Lex_Data{
int32_t chunk_pos; int32_t chunk_pos;
Lex_FSM fsm; Lex_FSM fsm;
Whitespace_FSM wfsm; unsigned char white_done;
unsigned char pp_state; unsigned char pp_state;
unsigned char completed; unsigned char completed;
@ -351,12 +380,12 @@ lex_data_init(char *tb){
#define DrCase(PC) case PC: goto resumespot_##PC #define DrCase(PC) case PC: goto resumespot_##PC
#define DrYield(PC, n) {\ #define DrYield(PC, n) { \
token_stack_out->count = token_i;\ token_stack_out->count = token_i; \
*S_ptr = S; S_ptr->__pc__ = PC; return(n); resumespot_##PC:; } *S_ptr = S; S_ptr->__pc__ = PC; return(n); resumespot_##PC:; }
#define DrReturn(n) {\ #define DrReturn(n) { \
token_stack_out->count = token_i;\ token_stack_out->count = token_i; \
*S_ptr = S; S_ptr->__pc__ = -1; return(n); } *S_ptr = S; S_ptr->__pc__ = -1; return(n); }
enum Lex_Result{ enum Lex_Result{
@ -389,29 +418,26 @@ cpp_lex_nonalloc(Lex_Data *S_ptr,
DrCase(3); DrCase(3);
DrCase(4); DrCase(4);
DrCase(5); DrCase(5);
DrCase(6);
DrCase(7); DrCase(7);
} }
for (;;){ for (;;){
S.wfsm.white_done = 0; S.white_done = 0;
S.wfsm.pp_state = S.pp_state;
for(;;){ for(;;){
for (; S.wfsm.pp_state < LSPP_count && S.pos < end_pos;){ for (; S.pp_state < LSPP_count && S.pos < end_pos;){
c = chunk[S.pos++]; c = chunk[S.pos++];
int32_t i = S.wfsm.pp_state + whitespace_fsm_eq_classes[c]; int32_t i = S.pp_state + whitespace_fsm_eq_classes[c];
S.wfsm.pp_state = whitespace_fsm_table[i]; S.pp_state = whitespace_fsm_table[i];
} }
S.wfsm.white_done = (S.wfsm.pp_state >= LSPP_count); S.white_done = (S.pp_state >= LSPP_count);
if (S.wfsm.white_done == 0){ if (S.white_done == 0){
S.chunk_pos += size; S.chunk_pos += size;
DrYield(4, LexNeedChunk); DrYield(4, LexNeedChunk);
} }
else break; else break;
} }
--S.pos; --S.pos;
S.pp_state = S.wfsm.pp_state;
if (S.pp_state >= LSPP_count){ if (S.pp_state >= LSPP_count){
S.pp_state -= LSPP_count; S.pp_state -= LSPP_count;
} }
@ -500,14 +526,16 @@ cpp_lex_nonalloc(Lex_Data *S_ptr,
} }
else{ else{
S.pos_overide = S.pos; S.pos_overide = S.pos;
S.wfsm.white_done = 0; S.white_done = 0;
for (;;){ for (;;){
for (; S.wfsm.white_done == 0 && S.pos < end_pos;){ for (; S.white_done == 0 && S.pos < end_pos;){
c = chunk[S.pos++]; c = chunk[S.pos++];
if (!(c == ' ' || c == '\t' || c == '\r' || c == '\v' || c == '\f')) S.wfsm.white_done = 1; if (!(c == ' ' || c == '\t' || c == '\r' || c == '\v' || c == '\f')){
S.white_done = 1;
}
} }
if (S.wfsm.white_done == 0){ if (S.white_done == 0){
S.chunk_pos += size; S.chunk_pos += size;
DrYield(1, LexNeedChunk); DrYield(1, LexNeedChunk);
} }
@ -543,11 +571,10 @@ cpp_lex_nonalloc(Lex_Data *S_ptr,
} }
} }
Sub_Match_List_Result sub_match; int32_t sub_match = sub_match_list(S.tb, S.tb_pos, keywords, word_size);
sub_match = sub_match_list(S.tb, S.tb_pos, 0, keywords, word_size);
if (sub_match.index != -1){ if (sub_match != -1){
String_And_Flag data = keywords.data[sub_match.index]; String_And_Flag data = keywords.data[sub_match];
S.token.type = (Cpp_Token_Type)data.flags; S.token.type = (Cpp_Token_Type)data.flags;
S.token.flags = CPP_TFLAG_IS_KEYWORD; S.token.flags = CPP_TFLAG_IS_KEYWORD;
} }
@ -568,34 +595,32 @@ cpp_lex_nonalloc(Lex_Data *S_ptr,
} }
break; break;
case LS_ppdef:
case LS_pp: case LS_pp:
{ {
S.fsm.directive_state = LSDIR_default;
S.fsm.emit_token = 0;
for (;;){
for (; S.fsm.directive_state < LSDIR_count && S.pos < end_pos;){
c = chunk[S.pos++];
S.fsm.directive_state = pp_directive_table[S.fsm.directive_state + pp_directive_eq_classes[c]];
}
S.fsm.emit_token = (S.fsm.int_state >= LSDIR_count);
if (S.fsm.emit_token == 0){
S.chunk_pos += size;
DrYield(6, LexNeedChunk);
}
else break;
}
--S.pos; --S.pos;
Cpp_Token_Type type = (Cpp_Token_Type)(S.fsm.directive_state - pp_directive_terminal_base); int32_t word_size = S.pos - S.token_start;
S.token.type = type; int32_t pos = S.tb_pos-1;
if (type == CPP_TOKEN_JUNK){ int32_t i = 1;
S.token.flags = 0; for (;i < pos; ++i){
if (S.tb[i] != ' '){
break;
}
} }
else{
int32_t sub_match = sub_match_list(S.tb+i, pos-i, preprops, word_size);
if (sub_match != -1){
String_And_Flag data = preprops.data[sub_match];
S.token.type = (Cpp_Token_Type)data.flags;
S.token.flags = CPP_TFLAG_PP_DIRECTIVE; S.token.flags = CPP_TFLAG_PP_DIRECTIVE;
S.pp_state = (unsigned char)cpp_pp_directive_to_state(S.token.type); S.pp_state = (unsigned char)cpp_pp_directive_to_state(S.token.type);
} }
else{
S.token.type = CPP_TOKEN_JUNK;
S.token.flags = 0;
}
}break; }break;
case LS_number: case LS_number:

View File

@ -15,6 +15,7 @@ enum Lex_State{
LS_identifier, LS_identifier,
LS_pound, LS_pound,
LS_pp, LS_pp,
LS_ppdef,
LS_char, LS_char,
LS_char_multiline, LS_char_multiline,
LS_char_slashed, LS_char_slashed,
@ -88,11 +89,6 @@ enum Lex_PP_State{
LSPP_count LSPP_count
}; };
struct Whitespace_FSM{
uint8_t pp_state;
uint8_t white_done;
};
struct Lex_FSM{ struct Lex_FSM{
uint8_t state; uint8_t state;
union{ union{

View File

@ -24,300 +24,307 @@ uint8_t int_fsm_table[] = {
}; };
uint8_t multiline_state_table[] = { uint8_t multiline_state_table[] = {
0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
}; };
uint16_t main_fsm_eq_classes[] = { uint16_t main_fsm_eq_classes[] = {
0,39,39,39,39,39,39,39,39,39,78,117,117,117,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,156,195,234,273,312,351,390,273,273,429,468,273,507,546,585,624,663,663,663,663,663,663,663,663,663,702,273,741,780,819,273,273,858,858,858,858,858,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,273,936,273,975,897,39,858,858,858,858,1014,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,1053,897,897,273,1092,273,273,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39, 0,40,40,40,40,40,40,40,40,40,80,120,120,120,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,160,200,240,280,320,360,400,280,280,440,480,280,520,560,600,640,680,680,680,680,680,680,680,680,680,720,280,760,800,840,280,280,880,880,880,880,880,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,280,960,280,1000,1040,40,880,880,880,880,1080,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,1120,920,920,280,1160,280,280,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,
}; };
const int32_t num_main_fsm_eq_classes = 29; const int32_t num_main_fsm_eq_classes = 30;
uint8_t main_fsm_table[] = { uint8_t main_fsm_table[] = {
39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77, 40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,
0,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3,43,44, 5,46,47, 8,49,50,51,52,53,54,55,56,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44,45,46, 6,48,49, 9,51,52,53,54,55,56,57,58,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3, 4, 5, 6, 7, 8, 9,49,50,51,52,53,54,55,17,18,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 7, 8, 9,10,51,52,53,54,55,56,57,18,19,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
37,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 38,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
7,40,41, 3, 4, 5, 4,46,47, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 8,41,42, 3,44, 5, 6, 5,48,49, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
42,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 3,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
34,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 35,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
29,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 30,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
4,40,41, 3,43,44, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 5,41,42, 3,44,45,46, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
33,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,19,17,17,20,20,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 34,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,20,18,18,21,21,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 32,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
27,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,14,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 28,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,15,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
21,40,41, 3, 4, 5, 4, 7, 8, 7,12,12,51,52,53,54,55,17,17,19,19,22,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 22,41,42, 3,44, 5, 6, 5, 8, 9, 8,13,13,53,54,55,56,57,18,18,20,20,23,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
16,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,17,17,17,19,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 17,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,18,18,18,20,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
11, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 12, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
10, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 11, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
32,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 33,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
23,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,24,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 24,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,25,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
36,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 37,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
25,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,26,65,28,67,68,69,70,71,72,73,74,75,76,38, 26,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,27,67,29,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 6, 6, 4, 9, 9, 7,49,50,51,52,53,54,55,18,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 7, 7, 5,10,10, 8,51,52,53,54,55,56,57,19,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
35,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 36,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,13,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,15,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,14,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
30,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,16,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
}; };
uint16_t pp_include_fsm_eq_classes[] = { uint16_t pp_include_fsm_eq_classes[] = {
0,39,39,39,39,39,39,39,39,39,78,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,117,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,156,39,195,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39, 0,40,40,40,40,40,40,40,40,40,80,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,120,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,160,40,200,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,
}; };
const int32_t num_pp_include_fsm_eq_classes = 6; const int32_t num_pp_include_fsm_eq_classes = 6;
uint8_t pp_include_fsm_table[] = { uint8_t pp_include_fsm_table[] = {
39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77, 40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,
3, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38, 3, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,
3,42,42,42, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38, 3,43,43,43, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,
1,40, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38, 1,41, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,
2, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38, 2, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,
3, 1,41, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38, 3, 1,42, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,
}; };
uint16_t pp_macro_fsm_eq_classes[] = { uint16_t pp_macro_fsm_eq_classes[] = {
0,39,39,39,39,39,39,39,39,39,78,117,117,117,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,156,195,234,273,312,351,390,273,273,429,468,273,507,546,585,624,663,663,663,663,663,663,663,663,663,702,273,741,780,819,273,273,858,858,858,858,858,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,273,936,273,975,897,39,858,858,858,858,1014,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,1053,897,897,273,1092,273,273,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39, 0,40,40,40,40,40,40,40,40,40,80,120,120,120,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,160,200,240,280,320,360,400,280,280,440,480,280,520,560,600,640,680,680,680,680,680,680,680,680,680,720,280,760,800,840,280,280,880,880,880,880,880,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,280,960,280,1000,1040,40,880,880,880,880,1080,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,1120,920,920,280,1160,280,280,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,
}; };
const int32_t num_pp_macro_fsm_eq_classes = 29; const int32_t num_pp_macro_fsm_eq_classes = 30;
uint8_t pp_macro_fsm_table[] = { uint8_t pp_macro_fsm_table[] = {
39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77, 40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,
0,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3,43,44, 5,46,47, 8,49,50,51,52,53,54,55,56,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44,45,46, 6,48,49, 9,51,52,53,54,55,56,57,58,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3, 4, 5, 6, 7, 8, 9,49,50,51,52,53,54,55,17,18,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 7, 8, 9,10,51,52,53,54,55,56,57,18,19,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
37,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 38,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
7,40,41, 3, 4, 5, 4,46,47, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 8,41,42, 3,44, 5, 6, 5,48,49, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
2,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 2,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
34,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 35,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
29,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 30,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
4,40,41, 3,43,44, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 5,41,42, 3,44,45,46, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
33,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,19,17,17,20,20,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 34,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,20,18,18,21,21,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 32,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
27,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,14,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 28,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,15,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
21,40,41, 3, 4, 5, 4, 7, 8, 7,12,12,51,52,53,54,55,17,17,19,19,22,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 22,41,42, 3,44, 5, 6, 5, 8, 9, 8,13,13,53,54,55,56,57,18,18,20,20,23,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
16,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,17,17,17,19,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 17,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,18,18,18,20,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
11, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 12, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
10, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 11, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
32,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 33,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
23,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,24,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 24,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,25,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
36,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 37,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
25,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,26,65,28,67,68,69,70,71,72,73,74,75,76,38, 26,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,27,67,29,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 6, 6, 4, 9, 9, 7,49,50,51,52,53,54,55,18,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 7, 7, 5,10,10, 8,51,52,53,54,55,56,57,19,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
35,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 36,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,13,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,15,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,14,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
30,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,16,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
}; };
uint16_t pp_identifier_fsm_eq_classes[] = { uint16_t pp_identifier_fsm_eq_classes[] = {
0,39,39,39,39,39,39,39,39,39,78,117,117,117,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,156,195,234,273,312,351,390,273,273,429,468,273,507,546,585,624,663,663,663,663,663,663,663,663,663,702,273,741,780,819,273,273,858,858,858,858,858,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,273,936,273,975,897,39,858,858,858,858,1014,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,1053,897,897,273,1092,273,273,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39, 0,40,40,40,40,40,40,40,40,40,80,120,120,120,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,160,200,240,280,320,360,400,280,280,440,480,280,520,560,600,640,680,680,680,680,680,680,680,680,680,720,280,760,800,840,280,280,880,880,880,880,880,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,280,960,280,1000,1040,40,880,880,880,880,1080,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,1120,920,920,280,1160,280,280,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,
}; };
const int32_t num_pp_identifier_fsm_eq_classes = 29; const int32_t num_pp_identifier_fsm_eq_classes = 30;
uint8_t pp_identifier_fsm_table[] = { uint8_t pp_identifier_fsm_table[] = {
39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77, 40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,
0,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3,43,44, 5,46,47, 8,49,50,51,52,53,54,55,56,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44,45,46, 6,48,49, 9,51,52,53,54,55,56,57,58,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3, 4, 5, 6, 7, 8, 9,49,50,51,52,53,54,55,17,18,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 7, 8, 9,10,51,52,53,54,55,56,57,18,19,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
37,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 38,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
7,40,41, 3, 4, 5, 4,46,47, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 8,41,42, 3,44, 5, 6, 5,48,49, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
2,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 2,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
34,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 35,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
29,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 30,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
4,40,41, 3,43,44, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 5,41,42, 3,44,45,46, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
33,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,19,17,17,20,20,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 34,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,20,18,18,21,21,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 32,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
27,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,14,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 28,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,15,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
21,40,41, 3, 4, 5, 4, 7, 8, 7,12,12,51,52,53,54,55,17,17,19,19,22,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 22,41,42, 3,44, 5, 6, 5, 8, 9, 8,13,13,53,54,55,56,57,18,18,20,20,23,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
16,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,17,17,17,19,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 17,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,18,18,18,20,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
11, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 12, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
10, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 11, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
32,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 33,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
23,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,24,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 24,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,25,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
36,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 37,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
25,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,26,65,28,67,68,69,70,71,72,73,74,75,76,38, 26,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,27,67,29,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 6, 6, 4, 9, 9, 7,49,50,51,52,53,54,55,18,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 7, 7, 5,10,10, 8,51,52,53,54,55,56,57,19,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
35,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 36,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,13,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,15,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,14,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
30,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,16,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
}; };
uint16_t pp_body_if_fsm_eq_classes[] = { uint16_t pp_body_if_fsm_eq_classes[] = {
0,39,39,39,39,39,39,39,39,39,78,117,117,117,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,156,195,234,273,312,351,390,273,273,429,468,273,507,546,585,624,663,663,663,663,663,663,663,663,663,702,273,741,780,819,273,273,858,858,858,858,858,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,273,936,273,975,897,39,858,858,858,858,1014,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,1053,897,897,273,1092,273,273,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39, 0,40,40,40,40,40,40,40,40,40,80,120,120,120,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,160,200,240,280,320,360,400,280,280,440,480,280,520,560,600,640,680,680,680,680,680,680,680,680,680,720,280,760,800,840,280,280,880,880,880,880,880,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,280,960,280,1000,1040,40,880,880,880,880,1080,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,1120,920,920,280,1160,280,280,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,
}; };
const int32_t num_pp_body_if_fsm_eq_classes = 29; const int32_t num_pp_body_if_fsm_eq_classes = 30;
uint8_t pp_body_if_fsm_table[] = { uint8_t pp_body_if_fsm_table[] = {
39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77, 40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,
0,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3,43,44, 5,46,47, 8,49,50,51,52,53,54,55,56,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44,45,46, 6,48,49, 9,51,52,53,54,55,56,57,58,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3, 4, 5, 6, 7, 8, 9,49,50,51,52,53,54,55,17,18,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 7, 8, 9,10,51,52,53,54,55,56,57,18,19,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
37,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 38,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
7,40,41, 3, 4, 5, 4,46,47, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 8,41,42, 3,44, 5, 6, 5,48,49, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
2,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 2,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
34,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 35,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
29,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 30,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
4,40,41, 3,43,44, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 5,41,42, 3,44,45,46, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
33,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,19,17,17,20,20,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 34,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,20,18,18,21,21,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 32,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
27,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,14,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 28,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,15,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
21,40,41, 3, 4, 5, 4, 7, 8, 7,12,12,51,52,53,54,55,17,17,19,19,22,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 22,41,42, 3,44, 5, 6, 5, 8, 9, 8,13,13,53,54,55,56,57,18,18,20,20,23,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
16,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,17,17,17,19,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 17,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,18,18,18,20,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
11, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 12, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
10, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 11, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
32,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 33,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
23,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,24,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 24,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,25,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
36,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 37,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
25,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,26,65,28,67,68,69,70,71,72,73,74,75,76,38, 26,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,27,67,29,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 6, 6, 4, 9, 9, 7,49,50,51,52,53,54,55,18,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 7, 7, 5,10,10, 8,51,52,53,54,55,56,57,19,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
35,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 36,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,13,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,15,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,14,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
30,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,16,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
}; };
uint16_t pp_body_fsm_eq_classes[] = { uint16_t pp_body_fsm_eq_classes[] = {
0,39,39,39,39,39,39,39,39,39,78,117,117,117,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,156,195,234,273,312,351,390,273,273,429,468,273,507,546,585,624,663,663,663,663,663,663,663,663,663,702,273,741,780,819,273,273,858,858,858,858,858,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,273,936,273,975,897,39,858,858,858,858,1014,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,1053,897,897,273,1092,273,273,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39, 0,40,40,40,40,40,40,40,40,40,80,120,120,120,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,160,200,240,280,320,360,400,280,280,440,480,280,520,560,600,640,680,680,680,680,680,680,680,680,680,720,280,760,800,840,280,280,880,880,880,880,880,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,280,960,280,1000,1040,40,880,880,880,880,1080,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,1120,920,920,280,1160,280,280,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,
}; };
const int32_t num_pp_body_fsm_eq_classes = 29; const int32_t num_pp_body_fsm_eq_classes = 30;
uint8_t pp_body_fsm_table[] = { uint8_t pp_body_fsm_table[] = {
39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77, 40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,
0,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3,43,44, 5,46,47, 8,49,50,51,52,53,54,55,56,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44,45,46, 6,48,49, 9,51,52,53,54,55,56,57,58,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3, 4, 5, 6, 7, 8, 9,49,50,51,52,53,54,55,17,18,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 7, 8, 9,10,51,52,53,54,55,56,57,18,19,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
37,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 38,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
7,40,41, 3, 4, 5, 4,46,47, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 8,41,42, 3,44, 5, 6, 5,48,49, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
2,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 2,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
34,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 35,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
29,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 30,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
4,40,41, 3,43,44, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 5,41,42, 3,44,45,46, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
33,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,19,17,17,20,20,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 34,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,20,18,18,21,21,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 32,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
27,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,14,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 28,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,15,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
21,40,41, 3, 4, 5, 4, 7, 8, 7,12,12,51,52,53,54,55,17,17,19,19,22,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 22,41,42, 3,44, 5, 6, 5, 8, 9, 8,13,13,53,54,55,56,57,18,18,20,20,23,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
16,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,17,17,17,19,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 17,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,18,18,18,20,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
11, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 12, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
10, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 11, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
32,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 33,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
23,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,24,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 24,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,25,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
36,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 37,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
25,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,26,65,28,67,68,69,70,71,72,73,74,75,76,38, 26,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,27,67,29,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 6, 6, 4, 9, 9, 7,49,50,51,52,53,54,55,18,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 7, 7, 5,10,10, 8,51,52,53,54,55,56,57,19,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
35,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 36,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,13,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,15,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,14,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
30,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,16,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
}; };
uint16_t pp_number_fsm_eq_classes[] = { uint16_t pp_number_fsm_eq_classes[] = {
0,39,39,39,39,39,39,39,39,39,78,117,117,117,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,156,195,234,273,312,351,390,273,273,429,468,273,507,546,585,624,663,663,663,663,663,663,663,663,663,702,273,741,780,819,273,273,858,858,858,858,858,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,273,936,273,975,897,39,858,858,858,858,1014,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,1053,897,897,273,1092,273,273,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39, 0,40,40,40,40,40,40,40,40,40,80,120,120,120,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,160,200,240,280,320,360,400,280,280,440,480,280,520,560,600,640,680,680,680,680,680,680,680,680,680,720,280,760,800,840,280,280,880,880,880,880,880,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,280,960,280,1000,1040,40,880,880,880,880,1080,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,1120,920,920,280,1160,280,280,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,
}; };
const int32_t num_pp_number_fsm_eq_classes = 29; const int32_t num_pp_number_fsm_eq_classes = 30;
uint8_t pp_number_fsm_table[] = { uint8_t pp_number_fsm_table[] = {
39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77, 40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,
0,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3,43,44, 5,46,47, 8,49,50,51,52,53,54,55,56,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44,45,46, 6,48,49, 9,51,52,53,54,55,56,57,58,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3, 4, 5, 6, 7, 8, 9,49,50,51,52,53,54,55,17,18,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 7, 8, 9,10,51,52,53,54,55,56,57,18,19,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
37,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 38,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
7,40,41, 3, 4, 5, 4,46,47, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 8,41,42, 3,44, 5, 6, 5,48,49, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
2,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 2,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
34,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 35,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
29,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 30,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
4,40,41, 3,43,44, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 5,41,42, 3,44,45,46, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
33,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,19,17,17,20,20,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 34,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,20,18,18,21,21,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 32,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
27,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,14,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 28,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,15,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
21,40,41, 3, 4, 5, 4, 7, 8, 7,12,12,51,52,53,54,55,17,17,19,19,22,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 22,41,42, 3,44, 5, 6, 5, 8, 9, 8,13,13,53,54,55,56,57,18,18,20,20,23,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
16,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,17,17,17,19,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 17,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,18,18,18,20,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
11, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 12, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
10, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 11, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
32,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 33,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
23,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,24,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 24,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,25,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
36,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 37,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
25,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,26,65,28,67,68,69,70,71,72,73,74,75,76,38, 26,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,27,67,29,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 6, 6, 4, 9, 9, 7,49,50,51,52,53,54,55,18,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 7, 7, 5,10,10, 8,51,52,53,54,55,56,57,19,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
35,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 36,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,13,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,15,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,14,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
30,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,16,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
}; };
uint16_t pp_error_fsm_eq_classes[] = { uint16_t pp_error_fsm_eq_classes[] = {
0,39,39,39,39,39,39,39,39,39,78,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39, 0,40,40,40,40,40,40,40,40,40,80,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,
}; };
const int32_t num_pp_error_fsm_eq_classes = 3; const int32_t num_pp_error_fsm_eq_classes = 3;
uint8_t pp_error_fsm_table[] = { uint8_t pp_error_fsm_table[] = {
39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77, 40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,
38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38,38, 39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,
77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77, 79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,
}; };
uint16_t pp_junk_fsm_eq_classes[] = { uint16_t pp_junk_fsm_eq_classes[] = {
0,39,39,39,39,39,39,39,39,39,78,117,117,117,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,156,195,234,273,312,351,390,273,273,429,468,273,507,546,585,624,663,663,663,663,663,663,663,663,663,702,273,741,780,819,273,273,858,858,858,858,858,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,273,936,273,975,897,39,858,858,858,858,1014,858,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,897,1053,897,897,273,1092,273,273,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39,39, 0,40,40,40,40,40,40,40,40,40,80,120,120,120,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,160,200,240,280,320,360,400,280,280,440,480,280,520,560,600,640,680,680,680,680,680,680,680,680,680,720,280,760,800,840,280,280,880,880,880,880,880,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,280,960,280,1000,1040,40,880,880,880,880,1080,880,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,920,1120,920,920,280,1160,280,280,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,
}; };
const int32_t num_pp_junk_fsm_eq_classes = 29; const int32_t num_pp_junk_fsm_eq_classes = 30;
uint8_t pp_junk_fsm_table[] = { uint8_t pp_junk_fsm_table[] = {
39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77, 40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,
0,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3,43,44, 5,46,47, 8,49,50,51,52,53,54,55,56,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44,45,46, 6,48,49, 9,51,52,53,54,55,56,57,58,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
0,40,41, 3, 4, 5, 6, 7, 8, 9,49,50,51,52,53,54,55,17,18,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 0,41,42, 3,44, 5, 6, 7, 8, 9,10,51,52,53,54,55,56,57,18,19,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
37,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 38,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
7,40,41, 3, 4, 5, 4,46,47, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 8,41,42, 3,44, 5, 6, 5,48,49, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
2,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 2,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
34,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 35,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
29,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 30,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
4,40,41, 3,43,44, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 5,41,42, 3,44,45,46, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
33,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,19,17,17,20,20,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 34,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,20,18,18,21,21,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 32,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
27,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,14,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 28,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,15,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
21,40,41, 3, 4, 5, 4, 7, 8, 7,12,12,51,52,53,54,55,17,17,19,19,22,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 22,41,42, 3,44, 5, 6, 5, 8, 9, 8,13,13,53,54,55,56,57,18,18,20,20,23,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
16,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,17,17,17,19,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 17,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,18,18,18,20,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
11, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 12, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
10, 1,41, 3, 4, 5, 4, 7, 8, 7,10,10,12,14,14,15,55,17,17,19,19,12,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 11, 1,42, 3,44, 5, 6, 5, 8, 9, 8,11,11,13,15,15,16,57,18,18,20,20,13,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
32,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 33,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
23,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,24,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 24,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,25,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
36,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 37,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
25,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,26,65,28,67,68,69,70,71,72,73,74,75,76,38, 26,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,27,67,29,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
39,40,41, 3, 6, 6, 4, 9, 9, 7,49,50,51,52,53,54,55,18,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 40,41,42, 3,44, 7, 7, 5,10,10, 8,51,52,53,54,55,56,57,19,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
35,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 36,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,50,13,52,53,15,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
1, 1,41, 3, 4, 5, 4, 7, 8, 7,49,15,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,52,14,54,55,16,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
30,40,41, 3, 4, 5, 4, 7, 8, 7,49,50,51,52,53,54,55,17,17,19,19,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,38, 1, 1,42, 4, 4, 5, 6, 5, 8, 9, 8,51,16,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
31,41,42, 3,44, 5, 6, 5, 8, 9, 8,51,52,53,54,55,56,57,18,18,20,20,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,39,
}; };
uint16_t * get_eq_classes[] = { uint16_t * get_eq_classes[] = {
@ -344,52 +351,3 @@ pp_error_fsm_table,
pp_junk_fsm_table, pp_junk_fsm_table,
}; };
uint16_t pp_directive_eq_classes[] = {
0, 0, 0, 0, 0, 0, 0, 0, 0,119, 0,119,119,119, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,119, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,238, 0,357,476,595,714,833, 0,952, 0, 0,1071,1190,1309,1428,1547, 0,1666,1785,1904,2023, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,2142, 0,2261,2380,2499,2618,2737, 0,2856, 0, 0,2975,3094,3213,3332,3451, 0,3570,3689,3808,3927, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
};
const int32_t num_pp_directive_eq_classes = 34;
uint8_t pp_directive_table[] = {
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
0,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,67,200,200,70,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,35,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
4,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,41,200,200,200,38,200,202,42,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,81,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,103,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
10,200,200,200,56,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,39,202,200,45,43,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,60,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,82,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,111,200,208,209,200,200,214,200,118,214,
200,200,33,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,44,207,46,206,200,200,200,212,200,200,200,200,203,57,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,83,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,105,210,200,200,211,200,112,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,68,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,86,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
2,200,200,200,200,200,200,200,200,200,200,200,116,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,58,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,84,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,110,104,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
12,200,200,200,200,200,200,200,200,200,102,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,36,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,34,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,69,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,32,200,200,200,200,200,79,200,100,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,40,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,59,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,85,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,117,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,48,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,107,200,211,200,200,208,209,200,200,214,200,200,214,
6,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,47,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,66,200,200,200,101,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,49,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,106,200,200,200,210,200,108,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,200,80,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,109,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,50,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
8,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,37,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,62,200,200,65,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,16,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
3,200,200,200,200,200,200,200,200,200,200,200,200,200,22,200,200,200,19,200,202,23,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,73,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,90,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
9,200,200,51,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,20,202,200,26,24,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,55,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,74,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,98,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,115,214,200,200,214,
200,14,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,25,207,27,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,52,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,75,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,92,210,200,200,211,200,99,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,63,200,200,215,200,200,200,200,215,200,200,200,200,204,200,78,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
1,200,200,200,200,200,200,200,200,200,200,113,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,53,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,76,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,97,91,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
11,200,200,200,200,200,200,200,200,89,200,200,200,200,205,200,17,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,15,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,64,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,13,200,200,200,200,200,71,200,87,200,200,200,200,21,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,54,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,77,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,114,200,214,200,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,29,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,94,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
5,200,200,200,200,200,200,200,200,200,200,200,200,200,205,28,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,61,200,200,200,88,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,30,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,93,200,200,200,210,200,95,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,72,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,96,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
200,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,31,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
7,200,200,200,200,200,200,200,200,200,200,200,200,200,205,200,200,18,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,205,200,200,200,200,200,202,200,200,200,200,207,200,206,200,200,200,212,200,200,200,200,203,200,200,200,200,203,200,200,200,200,215,200,200,200,200,215,200,200,200,200,204,200,200,213,200,200,200,200,204,200,200,213,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,200,200,200,210,200,200,211,200,200,208,209,200,200,214,200,200,214,
};
uint8_t LSDIR_default = 0;
uint8_t LSDIR_count = 119;
uint8_t pp_directive_terminal_base = 200;

1
4ed.h
View File

@ -47,7 +47,6 @@ struct Key_Summary{
inline Key_Event_Data inline Key_Event_Data
get_single_key(Key_Summary *summary, i32 index){ get_single_key(Key_Summary *summary, i32 index){
Assert(index >= 0 && index < summary->count);
Key_Event_Data key; Key_Event_Data key;
key = summary->keys[index]; key = summary->keys[index];
return key; return key;

View File

@ -17,14 +17,19 @@
#define BUFFER_EXPERIMENT_SCALPEL 0 #define BUFFER_EXPERIMENT_SCALPEL 0
#include "4ed_meta.h" #include "4ed_defines.h"
#include "4ed_math.h" #include "4ed_math.h"
#include "4ed_system.h" #include "4ed_system.h"
#include "4ed_rendering.h" #include "4ed_rendering.h"
#include "4ed.h" #include "4ed.h"
// TODO(allen): can I get away from this one?
#include <assert.h>
#define FCPP_FORBID_MALLOC
#include "4cpp_lexer.h" #include "4cpp_lexer.h"
#include "4coder_table.cpp" #include "4coder_table.cpp"

View File

@ -7,8 +7,8 @@
* *
*/ */
#ifndef FRED_META_H #ifndef FRED_DEFINES_H
#define FRED_META_H #define FRED_DEFINES_H
#include <string.h> #include <string.h>
#include <stdint.h> #include <stdint.h>

View File

@ -1,23 +1,25 @@
/* /*
* Mr. 4th Dimention - Allen Webster * Mr. 4th Dimention - Allen Webster
* *
* 25.02.2016 * 25.02.2016
* *
* File editing view for 4coder * File editing view for 4coder
* *
*/ */
// TOP // TOP
#include "4ed_meta.h" #include "4coder_version.h"
#include "internal_4coder_string.cpp"
#include "4cpp_lexer_types.h" #include "internal_4coder_string.cpp"
#define FCPP_LEXER_IMPLEMENTATION #define FCPP_LEXER_IMPLEMENTATION
#include "4cpp_lexer.h" #include "4cpp_lexer.h"
#include "4coder_version.h" #include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <assert.h>
#include "4coder_mem.h" #include "4coder_mem.h"
@ -84,11 +86,6 @@ void to_camel(char *src, char *dst){
*dst = 0; *dst = 0;
} }
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <assert.h>
void struct_begin(FILE *file, char *name){ void struct_begin(FILE *file, char *name){
fprintf(file, "struct %s{\n", name); fprintf(file, "struct %s{\n", name);
} }
@ -146,13 +143,14 @@ char *keys_that_need_codes[] = {
"f16", "f16",
}; };
char* generate_keycode_enum(){ void
generate_keycode_enum(){
FILE *file; FILE *file;
char *filename = "4coder_keycodes.h"; char *filename_keycodes = "4coder_keycodes.h";
int32_t i, count; int32_t i, count;
unsigned char code = 1; unsigned char code = 1;
file = fopen(filename, "wb"); file = fopen(filename_keycodes, "wb");
fprintf(file, "enum Key_Code_Names{\n"); fprintf(file, "enum Key_Code_Names{\n");
count = ArrayCount(keys_that_need_codes); count = ArrayCount(keys_that_need_codes);
for (i = 0; i < count; i){ for (i = 0; i < count; i){
@ -191,7 +189,6 @@ char* generate_keycode_enum(){
); );
fclose(file); fclose(file);
return(filename);
} }
////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////
@ -258,8 +255,8 @@ char style_index_function_end[] =
char style_case[] = " case Stag_%s: result = &s->%s_color; break;\n"; char style_case[] = " case Stag_%s: result = &s->%s_color; break;\n";
char style_info_case[] = " case Stag_%s: result = &s->file_info_style.%s_color; break;\n"; char style_info_case[] = " case Stag_%s: result = &s->file_info_style.%s_color; break;\n";
char* generate_style(){ void
char *filename = "4coder_style.h & 4ed_style.h"; generate_style(){
char filename_4coder[] = "4coder_style.h"; char filename_4coder[] = "4coder_style.h";
char filename_4ed[] = "4ed_style.h"; char filename_4ed[] = "4ed_style.h";
FILE *file; FILE *file;
@ -325,10 +322,9 @@ char* generate_style(){
} }
fclose(file); fclose(file);
return(filename);
} }
#if 1
////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////
typedef struct Argument_Breakdown{ typedef struct Argument_Breakdown{
int32_t count; int32_t count;
@ -346,12 +342,12 @@ typedef struct Documentation{
String *see_also; String *see_also;
} Documentation; } Documentation;
struct App_API{ typedef struct App_API{
String *macros; String *macros;
String *public_name; String *public_name;
}; } App_API;
struct Function_Set{ typedef struct Function_Set{
String *name; String *name;
String *ret; String *ret;
String *args; String *args;
@ -361,45 +357,45 @@ struct Function_Set{
String *doc_string; String *doc_string;
int32_t *is_macro; int32_t *is_macro;
int32_t *valid; int32_t *valid;
Argument_Breakdown *breakdown; Argument_Breakdown *breakdown;
Documentation *doc; Documentation *doc;
}; } Function_Set;
struct Typedef_Set{ typedef struct Typedef_Set{
String *type; String *type;
String *name; String *name;
String *doc_string; String *doc_string;
}; } Typedef_Set;
struct Struct_Member{ typedef struct Struct_Member{
String name; String name;
String type; String type;
String type_postfix; String type_postfix;
String doc_string; String doc_string;
Struct_Member *first_child; Struct_Member *first_child;
Struct_Member *next_sibling; Struct_Member *next_sibling;
}; } Struct_Member;
struct Struct_Set{ typedef struct Struct_Set{
Struct_Member *structs; Struct_Member *structs;
}; } Struct_Set;
struct Enum_Member{ typedef struct Enum_Member{
String name; String name;
String value; String value;
String doc_string; String doc_string;
Enum_Member *next; Enum_Member *next;
}; } Enum_Member;
struct Enum_Set{ typedef struct Enum_Set{
String *name; String *name;
String *type; String *type;
Enum_Member **first_member; Enum_Member **first_member;
String *doc_string; String *doc_string;
}; } Enum_Set;
void void
zero_index(Function_Set fnc_set, int32_t sig_count){ zero_index(Function_Set fnc_set, int32_t sig_count){
@ -435,9 +431,7 @@ String
get_first_line(String source){ get_first_line(String source){
String line = {0}; String line = {0};
int32_t pos = find_s_char(source, 0, '\n'); int32_t pos = find_s_char(source, 0, '\n');
line = substr(source, 0, pos); line = substr(source, 0, pos);
return(line); return(line);
} }
@ -472,9 +466,9 @@ is_comment(String str){
return(result); return(result);
} }
struct Parse{ typedef struct Parse{
Cpp_Token_Stack tokens; Cpp_Token_Stack tokens;
}; } Parse;
static int32_t static int32_t
check_and_fix_docs(String *lexeme){ check_and_fix_docs(String *lexeme){
@ -1762,21 +1756,20 @@ print_function_docs(FILE *file, Partition *part, String name, String doc_string)
print_see_also(file, doc); print_see_also(file, doc);
} }
char* void
generate_custom_headers(){ generate_custom_headers(){
#define API_H "4coder_custom_api.h" #define API_H "4coder_custom_api.h"
#define OS_API_H "4ed_os_custom_api.h"
#define API_DOC "4coder_API.html" #define API_DOC "4coder_API.html"
#define STRING_H "4coder_string.h" #define STRING_H "4coder_string.h"
int32_t size = Mbytes(512); int32_t size = (512 << 20);
void *mem = malloc(size); void *mem = malloc(size);
memset(mem, 0, size); memset(mem, 0, size);
Partition part_ = make_part(mem, size); Partition part_ = make_part(mem, size);
Partition *part = &part_; Partition *part = &part_;
char *filename = API_H " & " API_DOC " & " STRING_H;
String string_code = file_dump("internal_4coder_string.cpp"); String string_code = file_dump("internal_4coder_string.cpp");
Cpp_Token_Stack string_tokens = {0}; Cpp_Token_Stack string_tokens = {0};
@ -1914,6 +1907,7 @@ generate_custom_headers(){
Function_Set function_set = allocate_function_set(line_count); Function_Set function_set = allocate_function_set(line_count);
App_API app_function_set = allocate_app_api(line_count); App_API app_function_set = allocate_app_api(line_count);
int32_t sig_count = 0; int32_t sig_count = 0;
int32_t sig_count_per_file[2];
for (int32_t J = 0; J < 2; ++J){ for (int32_t J = 0; J < 2; ++J){
String *code = &code_data[J]; String *code = &code_data[J];
@ -1942,6 +1936,8 @@ generate_custom_headers(){
} }
} }
} }
++sig_count_per_file[J] = sig_count;
} }
for (int32_t i = 0; i < sig_count; ++i){ for (int32_t i = 0; i < sig_count; ++i){
@ -1967,7 +1963,32 @@ generate_custom_headers(){
} }
// NOTE(allen): Header // NOTE(allen): Header
FILE *file = fopen(API_H, "wb"); FILE *file = fopen(OS_API_H, "wb");
int32_t main_api_count = sig_count_per_file[0];
for (int32_t i = main_api_count; i < sig_count; ++i){
String ret_string = function_set.ret[i];
String args_string = function_set.args[i];
String macro_string = app_function_set.macros[i];
fprintf(file, "#define %.*s(n) %.*s n%.*s\n",
macro_string.size, macro_string.str,
ret_string.size, ret_string.str,
args_string.size, args_string.str);
}
for (int32_t i = main_api_count; i < sig_count; ++i){
String name_string = function_set.name[i];
String macro_string = app_function_set.macros[i];
fprintf(file, "typedef %.*s(%.*s_Function);\n",
macro_string.size, macro_string.str,
name_string.size, name_string.str);
}
fclose(file);
file = fopen(API_H, "wb");
for (int32_t i = 0; i < sig_count; ++i){ for (int32_t i = 0; i < sig_count; ++i){
String ret_string = function_set.ret[i]; String ret_string = function_set.ret[i];
@ -1977,20 +1998,17 @@ generate_custom_headers(){
fprintf(file, "#define %.*s(n) %.*s n%.*s\n", fprintf(file, "#define %.*s(n) %.*s n%.*s\n",
macro_string.size, macro_string.str, macro_string.size, macro_string.str,
ret_string.size, ret_string.str, ret_string.size, ret_string.str,
args_string.size, args_string.str args_string.size, args_string.str);
);
} }
fprintf(file, "extern \"C\"{\n");
for (int32_t i = 0; i < sig_count; ++i){ for (int32_t i = 0; i < sig_count; ++i){
String name_string = function_set.name[i]; String name_string = function_set.name[i];
String macro_string = app_function_set.macros[i]; String macro_string = app_function_set.macros[i];
fprintf(file, " typedef %.*s(%.*s_Function);\n", fprintf(file, "typedef %.*s(%.*s_Function);\n",
macro_string.size, macro_string.str, macro_string.size, macro_string.str,
name_string.size, name_string.str); name_string.size, name_string.str);
} }
fprintf(file, "}\n");
fprintf(file, "struct Application_Links{\n"); fprintf(file, "struct Application_Links{\n");
fprintf(file, fprintf(file,
@ -2131,7 +2149,7 @@ generate_custom_headers(){
Cpp_Token *token = tokens; Cpp_Token *token = tokens;
for (int32_t i = 0; i < count; ++i, ++token){ for (int32_t i = 0; i < count; ++i, ++token){
Assert(i == (i32)(token - tokens)); Assert(i == (int32_t)(token - tokens));
if (!(token->flags & CPP_TFLAG_PP_BODY) && if (!(token->flags & CPP_TFLAG_PP_BODY) &&
(token->type == CPP_TOKEN_KEY_TYPE_DECLARATION || (token->type == CPP_TOKEN_KEY_TYPE_DECLARATION ||
token->type == CPP_TOKEN_IDENTIFIER)){ token->type == CPP_TOKEN_IDENTIFIER)){
@ -2209,7 +2227,7 @@ generate_custom_headers(){
enum_set.doc_string[enum_index] = doc_string; enum_set.doc_string[enum_index] = doc_string;
++enum_index; ++enum_index;
} }
i = (i32)(token - tokens); i = (int32_t)(token - tokens);
}break; }break;
case 4: //FLAGENUM case 4: //FLAGENUM
@ -2232,7 +2250,7 @@ generate_custom_headers(){
flag_set.doc_string[flag_index] = doc_string; flag_set.doc_string[flag_index] = doc_string;
++flag_index; ++flag_index;
} }
i = (i32)(token - tokens); i = (int32_t)(token - tokens);
}break; }break;
} }
} }
@ -2641,9 +2659,9 @@ generate_custom_headers(){
{ {
fprintf(file, fprintf(file,
"<div><i>\n" "<div><i>\n"
"Coming Soon" "Coming Soon"
"</i><div>\n"); "</i><div>\n");
} }
#undef MAJOR_SECTION #undef MAJOR_SECTION
@ -3081,16 +3099,13 @@ generate_custom_headers(){
fclose(file); fclose(file);
} }
return(filename);
} }
#endif
int main(int argc, char **argv){ int main(int argc, char **argv){
char *filename = 0; generate_keycode_enum();
generate_style();
filename = generate_keycode_enum(); generate_custom_headers();
filename = generate_style();
filename = generate_custom_headers();
} }
// BOTTOM // BOTTOM

14
4ed_os_custom_api.h Normal file
View File

@ -0,0 +1,14 @@
#define MEMORY_ALLOCATE_SIG(n) void* n(Application_Links *app, int32_t size)
#define MEMORY_SET_PROTECTION_SIG(n) bool32 n(Application_Links *app, void *ptr, int32_t size, Memory_Protect_Flags flags)
#define MEMORY_FREE_SIG(n) void n(Application_Links *app, void *mem, int32_t size)
#define FILE_EXISTS_SIG(n) bool32 n(Application_Links *app, char *filename, int32_t len)
#define DIRECTORY_CD_SIG(n) bool32 n(Application_Links *app, char *dir, int32_t *len, int32_t capacity, char *rel_path, int32_t rel_len)
#define GET_4ED_PATH_SIG(n) bool32 n(Application_Links *app, char *out, int32_t capacity)
#define SHOW_MOUSE_CURSOR_SIG(n) void n(Application_Links *app, Mouse_Cursor_Show_Type show)
typedef MEMORY_ALLOCATE_SIG(Memory_Allocate_Function);
typedef MEMORY_SET_PROTECTION_SIG(Memory_Set_Protection_Function);
typedef MEMORY_FREE_SIG(Memory_Free_Function);
typedef FILE_EXISTS_SIG(File_Exists_Function);
typedef DIRECTORY_CD_SIG(Directory_CD_Function);
typedef GET_4ED_PATH_SIG(Get_4ed_Path_Function);
typedef SHOW_MOUSE_CURSOR_SIG(Show_Mouse_Cursor_Function);

View File

@ -283,6 +283,7 @@ int main(int argc, char **argv){
} }
#endif #endif
#if 1
{ {
BEGIN_TIME_SECTION(); BEGIN_TIME_SECTION();
build(OPTS | DEBUG_INFO, cdir, "4ed_metagen.cpp", build(OPTS | DEBUG_INFO, cdir, "4ed_metagen.cpp",
@ -320,6 +321,7 @@ int main(int argc, char **argv){
BUILD_DIR, "4ed", 0); BUILD_DIR, "4ed", 0);
END_TIME_SECTION("build 4ed"); END_TIME_SECTION("build 4ed");
} }
#endif
return(error_state); return(error_state);
} }

File diff suppressed because it is too large Load Diff

View File

@ -16,7 +16,7 @@ FSTRING_BEGIN
#endif #endif
#if defined(FSTRING_IMPLEMENTATION) && defined(FSTRING_GUARD) #if defined(FSTRING_IMPLEMENTATION) && defined(FSTRING_GUARD)
#undef FSTRING_IMPLEMENTATION # undef FSTRING_IMPLEMENTATION
#endif #endif
#include <stdint.h> #include <stdint.h>

View File

@ -10,21 +10,54 @@
// TOP // TOP
#if FRED_SUPER #if FRED_SUPER
# include "4coder_custom.h"
# include "4ed_defines.h"
# define FSTRING_IMPLEMENTATION
# define FSTRING_C
# include "4coder_string.h"
#include "4coder_version.h"
# include "4coder_keycodes.h"
# include "4coder_style.h"
# include "4coder_rect.h"
# include <assert.h>
# include "4coder_mem.h"
// TODO(allen): This is duplicated from 4coder_custom.h
// I need to work out a way to avoid this.
#define VIEW_ROUTINE_SIG(name) void name(struct Application_Links *app, int32_t view_id)
#define GET_BINDING_DATA(name) int32_t name(void *data, int32_t size)
#define _GET_VERSION_SIG(n) int32_t n(int32_t maj, int32_t min, int32_t patch)
typedef VIEW_ROUTINE_SIG(View_Routine_Function);
typedef GET_BINDING_DATA(Get_Binding_Data_Function);
typedef _GET_VERSION_SIG(_Get_Version_Function);
struct Custom_API{
View_Routine_Function *view_routine;
Get_Binding_Data_Function *get_bindings;
_Get_Version_Function *get_alpha_4coder_version;
};
typedef void Custom_Command_Function;
#include "4coder_types.h"
struct Application_Links;
# include "4ed_os_custom_api.h"
//# include "4coder_custom.h"
#else #else
# include "4coder_default_bindings.cpp" # include "4coder_default_bindings.cpp"
# define FSTRING_IMPLEMENTATION
# define FSTRING_C
# include "4coder_string.h"
#endif #endif
#define FSTRING_IMPLEMENTATION
#define FSTRING_C
#include "4coder_string.h"
#include "4ed_meta.h"
//
// Instead of including 4coder_custom.h
//
#include "4ed_math.h" #include "4ed_math.h"
#include "4ed_system.h" #include "4ed_system.h"
@ -230,36 +263,6 @@ Win32Ptr(void *h){
return(result); return(result);
} }
//
// Rudimentary Timing
//
#define WIN32_TIMING 0
#if FRED_INTERNAL && WIN32_TIMING
inline void
show_debug_timing(char *function, DWORD64 total){
char output[512];
String out = make_fixed_width_string(output);
append(&out, function);
append(&out, ' ');
append_u64_to_str(&out, (u64)(total));
append(&out, '\n');
terminate_with_null(&out);
OutputDebugStringA(output);
}
#define TEST_TIME_B() DWORD64 start = __rdtsc()
#define TEST_TIME_E() DWORD64 total = __rdtsc() - start; show_debug_timing(__FUNCTION__, total)
#else
#define TEST_TIME_B()
#define TEST_TIME_E()
#endif
// //
// Memory (not exposed to application, but needed in system_shared.cpp) // Memory (not exposed to application, but needed in system_shared.cpp)
@ -587,7 +590,6 @@ Sys_Cancel_Job_Sig(system_cancel_job){
i32 cancel_cv = group->cancel_cv0 + thread_index; i32 cancel_cv = group->cancel_cv0 + thread_index;
Thread_Context *thread = group->threads + thread_index; Thread_Context *thread = group->threads + thread_index;
system_acquire_lock(cancel_lock); system_acquire_lock(cancel_lock);
thread->cancel = 1; thread->cancel = 1;