From 159317b7bc4ba60b418a5f34eb5fb2b0d9dd0e10 Mon Sep 17 00:00:00 2001 From: "Fletcher T. Penney" Date: Thu, 2 Mar 2017 09:23:03 -0500 Subject: [PATCH] ADDED: Add prelim code for handling abbreviations --- .../include/libMultiMarkdown.h | 3 + Sources/libMultiMarkdown/mmd.c | 20 +- Sources/libMultiMarkdown/mmd.h | 1 + Sources/libMultiMarkdown/parser.c | 844 ++-- Sources/libMultiMarkdown/parser.h | 19 +- Sources/libMultiMarkdown/parser.out | 688 +-- Sources/libMultiMarkdown/parser.y | 3 + Sources/libMultiMarkdown/scanners.c | 3829 +++++++++-------- Sources/libMultiMarkdown/scanners.h | 1 + Sources/libMultiMarkdown/scanners.re | 14 + Sources/libMultiMarkdown/writer.c | 214 +- Sources/libMultiMarkdown/writer.h | 12 + tests/MMD6Tests/Abbreviations.text | 17 + 13 files changed, 3032 insertions(+), 2633 deletions(-) create mode 100644 tests/MMD6Tests/Abbreviations.text diff --git a/Sources/libMultiMarkdown/include/libMultiMarkdown.h b/Sources/libMultiMarkdown/include/libMultiMarkdown.h index 7768577..9e68df5 100644 --- a/Sources/libMultiMarkdown/include/libMultiMarkdown.h +++ b/Sources/libMultiMarkdown/include/libMultiMarkdown.h @@ -122,6 +122,7 @@ enum token_types { BLOCK_CODE_INDENTED, BLOCK_DEFLIST, BLOCK_DEFINITION, + BLOCK_DEF_ABBREVIATION, BLOCK_DEF_CITATION, BLOCK_DEF_FOOTNOTE, BLOCK_DEF_LINK, @@ -176,6 +177,7 @@ enum token_types { PAIR_ANGLE, PAIR_BACKTICK, PAIR_BRACKET, + PAIR_BRACKET_ABBREVIATION, PAIR_BRACKET_FOOTNOTE, PAIR_BRACKET_CITATION, PAIR_BRACKET_IMAGE, @@ -199,6 +201,7 @@ enum token_types { BRACKET_LEFT, BRACKET_RIGHT, + BRACKET_ABBREVIATION_LEFT, BRACKET_FOOTNOTE_LEFT, BRACKET_CITATION_LEFT, BRACKET_IMAGE_LEFT, diff --git a/Sources/libMultiMarkdown/mmd.c b/Sources/libMultiMarkdown/mmd.c index 51317ca..6f26a94 100644 --- a/Sources/libMultiMarkdown/mmd.c +++ b/Sources/libMultiMarkdown/mmd.c @@ -99,6 +99,7 @@ mmd_engine * mmd_engine_create(DString * d, unsigned long extensions) { e->language = LC_EN; e->quotes_lang = ENGLISH; + e->abbreviation_stack = stack_new(0); e->citation_stack = stack_new(0); e->definition_stack = stack_new(0); e->footnote_stack = stack_new(0); @@ -132,7 +133,8 @@ mmd_engine * mmd_engine_create(DString * d, unsigned long extensions) { } token_pair_engine_add_pairing(e->pairings2, BRACKET_VARIABLE_LEFT, BRACKET_RIGHT, PAIR_BRACKET_VARIABLE, PAIRING_ALLOW_EMPTY | PAIRING_PRUNE_MATCH); - + token_pair_engine_add_pairing(e->pairings2, BRACKET_ABBREVIATION_LEFT, BRACKET_RIGHT, PAIR_BRACKET_ABBREVIATION, PAIRING_ALLOW_EMPTY | PAIRING_PRUNE_MATCH); + token_pair_engine_add_pairing(e->pairings2, BRACKET_IMAGE_LEFT, BRACKET_RIGHT, PAIR_BRACKET_IMAGE, PAIRING_ALLOW_EMPTY | PAIRING_PRUNE_MATCH); token_pair_engine_add_pairing(e->pairings2, PAREN_LEFT, PAREN_RIGHT, PAIR_PAREN, PAIRING_ALLOW_EMPTY | PAIRING_PRUNE_MATCH); token_pair_engine_add_pairing(e->pairings2, ANGLE_LEFT, ANGLE_RIGHT, PAIR_ANGLE, PAIRING_ALLOW_EMPTY | PAIRING_PRUNE_MATCH); @@ -221,7 +223,9 @@ void mmd_engine_free(mmd_engine * e, bool freeDString) { // Pointers to blocks that are freed elsewhere stack_free(e->definition_stack); stack_free(e->header_stack); + stack_free(e->abbreviation_stack); + // Citations need to be freed while (e->citation_stack->size) { footnote_free(stack_pop(e->citation_stack)); @@ -454,6 +458,17 @@ void mmd_assign_line_type(mmd_engine * e, token * line) { break; } case STAR: + if (!(e->extensions & EXT_COMPATIBILITY)) { + if (line->child->next && line->child->next->type == BRACKET_LEFT) { + // Possible Abbreviation definition + if (scan_ref_abbreviation(&source[line->child->start])) { + line->type = LINE_DEF_ABBREVIATION; + line->child->type = TEXT_EMPTY; + line->child->next->type = BRACKET_ABBREVIATION_LEFT; + break; + } + } + } case UL: // Could this be a horizontal rule? t = line->child->next; @@ -899,6 +914,7 @@ void mmd_pair_tokens_in_block(token * block, token_pair_engine * e, stack * s) { case BLOCK_BLOCKQUOTE: case BLOCK_DEFLIST: case BLOCK_DEFINITION: + case BLOCK_DEF_ABBREVIATION: case BLOCK_DEF_CITATION: case BLOCK_DEF_FOOTNOTE: case BLOCK_DEF_LINK: @@ -968,6 +984,7 @@ void mmd_assign_ambidextrous_tokens_in_block(mmd_engine * e, token * block, cons t->type = BLOCK_PARA; case DOC_START_TOKEN: case BLOCK_BLOCKQUOTE: + case BLOCK_DEF_ABBREVIATION: case BLOCK_DEFLIST: case BLOCK_DEFINITION: case BLOCK_H1: @@ -1664,6 +1681,7 @@ void strip_line_tokens_from_block(mmd_engine * e, token * block) { case LINE_ATX_6: case LINE_BLOCKQUOTE: case LINE_CONTINUATION: + case LINE_DEF_ABBREVIATION: case LINE_DEF_CITATION: case LINE_DEF_FOOTNOTE: case LINE_DEF_LINK: diff --git a/Sources/libMultiMarkdown/mmd.h b/Sources/libMultiMarkdown/mmd.h index 0ea1b4b..5d9da75 100644 --- a/Sources/libMultiMarkdown/mmd.h +++ b/Sources/libMultiMarkdown/mmd.h @@ -77,6 +77,7 @@ struct mmd_engine { token_pair_engine * pairings2; token_pair_engine * pairings3; + stack * abbreviation_stack; stack * citation_stack; stack * definition_stack; stack * header_stack; diff --git a/Sources/libMultiMarkdown/parser.c b/Sources/libMultiMarkdown/parser.c index a448304..08e3eda 100644 --- a/Sources/libMultiMarkdown/parser.c +++ b/Sources/libMultiMarkdown/parser.c @@ -92,7 +92,7 @@ #endif /************* Begin control #defines *****************************************/ #define YYCODETYPE unsigned char -#define YYNOCODE 81 +#define YYNOCODE 83 #define YYACTIONTYPE unsigned short int #define ParseTOKENTYPE token * typedef union { @@ -108,15 +108,15 @@ typedef union { #define ParseARG_STORE yypParser->engine = engine #define YYFALLBACK 1 #define YYNSTATE 41 -#define YYNRULE 129 +#define YYNRULE 131 #define YY_MAX_SHIFT 40 -#define YY_MIN_SHIFTREDUCE 131 -#define YY_MAX_SHIFTREDUCE 259 -#define YY_MIN_REDUCE 260 -#define YY_MAX_REDUCE 388 -#define YY_ERROR_ACTION 389 -#define YY_ACCEPT_ACTION 390 -#define YY_NO_ACTION 391 +#define YY_MIN_SHIFTREDUCE 133 +#define YY_MAX_SHIFTREDUCE 263 +#define YY_MIN_REDUCE 264 +#define YY_MAX_REDUCE 394 +#define YY_ERROR_ACTION 395 +#define YY_ACCEPT_ACTION 396 +#define YY_NO_ACTION 397 /************* End control #defines *******************************************/ /* Define the yytestcase() macro to be a no-op if is not already defined @@ -188,90 +188,90 @@ typedef union { ** yy_default[] Default action for each state. ** *********** Begin parsing tables **********************************************/ -#define YY_ACTTAB_COUNT (256) +#define YY_ACTTAB_COUNT (258) static const YYACTIONTYPE yy_action[] = { - /* 0 */ 390, 1, 133, 30, 143, 144, 145, 146, 40, 148, - /* 10 */ 29, 27, 37, 35, 28, 13, 155, 156, 157, 39, - /* 20 */ 208, 12, 12, 27, 34, 34, 214, 258, 32, 32, - /* 30 */ 25, 254, 24, 23, 39, 37, 35, 211, 7, 251, - /* 40 */ 38, 214, 14, 14, 260, 140, 258, 229, 15, 258, - /* 50 */ 254, 217, 218, 254, 243, 134, 135, 136, 137, 138, - /* 60 */ 139, 222, 6, 5, 3, 2, 16, 250, 209, 141, - /* 70 */ 4, 229, 231, 234, 237, 232, 235, 238, 249, 140, - /* 80 */ 31, 31, 15, 258, 229, 217, 218, 254, 243, 134, - /* 90 */ 135, 136, 137, 138, 139, 222, 6, 5, 3, 2, - /* 100 */ 16, 33, 33, 141, 4, 229, 231, 234, 237, 232, - /* 110 */ 235, 238, 249, 132, 30, 143, 144, 145, 146, 40, - /* 120 */ 148, 29, 27, 37, 35, 28, 13, 155, 156, 157, - /* 130 */ 183, 241, 242, 179, 27, 239, 36, 36, 26, 32, - /* 140 */ 32, 25, 201, 24, 23, 21, 37, 35, 189, 7, - /* 150 */ 176, 38, 159, 14, 14, 188, 240, 184, 186, 182, - /* 160 */ 185, 187, 241, 242, 26, 164, 239, 8, 39, 8, - /* 170 */ 12, 12, 158, 4, 224, 9, 9, 17, 17, 217, - /* 180 */ 218, 166, 166, 169, 26, 223, 5, 240, 180, 177, - /* 190 */ 178, 181, 26, 203, 204, 9, 9, 17, 17, 172, - /* 200 */ 196, 165, 165, 9, 9, 17, 17, 241, 242, 170, - /* 210 */ 170, 239, 244, 6, 206, 26, 245, 4, 207, 207, - /* 220 */ 191, 172, 262, 217, 218, 262, 26, 158, 18, 18, - /* 230 */ 262, 262, 240, 173, 174, 175, 26, 10, 10, 19, - /* 240 */ 19, 26, 197, 190, 262, 262, 262, 11, 11, 20, - /* 250 */ 20, 262, 192, 158, 22, 22, + /* 0 */ 396, 1, 135, 30, 145, 146, 147, 148, 149, 40, + /* 10 */ 151, 29, 27, 37, 35, 28, 13, 158, 159, 160, + /* 20 */ 39, 211, 12, 12, 27, 233, 220, 221, 262, 32, + /* 30 */ 32, 25, 258, 24, 23, 217, 37, 35, 262, 7, + /* 40 */ 186, 38, 258, 14, 14, 264, 142, 175, 182, 15, + /* 50 */ 262, 212, 220, 221, 258, 247, 136, 137, 138, 139, + /* 60 */ 140, 141, 225, 6, 5, 3, 2, 16, 34, 34, + /* 70 */ 143, 231, 4, 233, 235, 238, 241, 236, 239, 242, + /* 80 */ 253, 142, 220, 221, 15, 262, 179, 220, 221, 258, + /* 90 */ 247, 136, 137, 138, 139, 140, 141, 225, 6, 5, + /* 100 */ 3, 2, 16, 193, 21, 143, 231, 4, 233, 235, + /* 110 */ 238, 241, 236, 239, 242, 253, 134, 30, 145, 146, + /* 120 */ 147, 148, 149, 40, 151, 29, 27, 37, 35, 28, + /* 130 */ 13, 158, 159, 160, 217, 245, 246, 39, 27, 243, + /* 140 */ 214, 31, 31, 32, 32, 25, 192, 24, 23, 204, + /* 150 */ 37, 35, 167, 7, 191, 38, 233, 14, 14, 33, + /* 160 */ 33, 244, 187, 189, 185, 188, 190, 245, 246, 26, + /* 170 */ 26, 243, 8, 39, 8, 12, 12, 36, 36, 161, + /* 180 */ 9, 9, 17, 17, 162, 248, 169, 169, 227, 249, + /* 190 */ 26, 255, 172, 244, 183, 180, 181, 184, 26, 226, + /* 200 */ 4, 9, 9, 17, 17, 5, 199, 168, 168, 9, + /* 210 */ 9, 17, 17, 245, 246, 173, 173, 243, 26, 6, + /* 220 */ 254, 209, 194, 26, 210, 210, 206, 207, 175, 10, + /* 230 */ 10, 19, 19, 26, 200, 161, 18, 18, 266, 244, + /* 240 */ 176, 177, 178, 26, 11, 11, 20, 20, 266, 195, + /* 250 */ 266, 4, 266, 266, 266, 161, 22, 22, }; static const YYCODETYPE yy_lookahead[] = { - /* 0 */ 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, - /* 10 */ 46, 47, 48, 49, 50, 51, 52, 53, 54, 76, - /* 20 */ 77, 78, 79, 59, 64, 65, 6, 5, 64, 65, - /* 30 */ 66, 9, 68, 69, 76, 71, 72, 79, 74, 6, - /* 40 */ 76, 6, 78, 79, 0, 1, 5, 27, 4, 5, - /* 50 */ 9, 7, 8, 9, 10, 11, 12, 13, 14, 15, - /* 60 */ 16, 17, 18, 19, 20, 21, 22, 34, 27, 25, - /* 70 */ 26, 27, 28, 29, 30, 31, 32, 33, 34, 1, - /* 80 */ 55, 56, 4, 5, 27, 7, 8, 9, 10, 11, - /* 90 */ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, - /* 100 */ 22, 55, 56, 25, 26, 27, 28, 29, 30, 31, - /* 110 */ 32, 33, 34, 38, 39, 40, 41, 42, 43, 44, - /* 120 */ 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, - /* 130 */ 67, 2, 3, 67, 59, 6, 55, 56, 44, 64, - /* 140 */ 65, 66, 73, 68, 69, 59, 71, 72, 59, 74, - /* 150 */ 67, 76, 58, 78, 79, 70, 27, 28, 29, 30, - /* 160 */ 31, 32, 2, 3, 44, 63, 6, 75, 76, 77, - /* 170 */ 78, 79, 56, 26, 6, 55, 56, 57, 58, 7, - /* 180 */ 8, 61, 62, 65, 44, 17, 19, 27, 28, 29, - /* 190 */ 30, 31, 44, 2, 3, 55, 56, 57, 58, 27, - /* 200 */ 72, 61, 62, 55, 56, 57, 58, 2, 3, 61, - /* 210 */ 62, 6, 6, 18, 5, 44, 10, 26, 9, 9, - /* 220 */ 71, 27, 80, 7, 8, 80, 44, 56, 57, 58, - /* 230 */ 80, 80, 27, 28, 29, 30, 44, 55, 56, 57, - /* 240 */ 58, 44, 60, 27, 80, 80, 80, 55, 56, 57, - /* 250 */ 58, 80, 60, 56, 57, 58, + /* 0 */ 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, + /* 10 */ 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, + /* 20 */ 78, 79, 80, 81, 61, 28, 7, 8, 5, 66, + /* 30 */ 67, 68, 9, 70, 71, 6, 73, 74, 5, 76, + /* 40 */ 69, 78, 9, 80, 81, 0, 1, 28, 69, 4, + /* 50 */ 5, 28, 7, 8, 9, 10, 11, 12, 13, 14, + /* 60 */ 15, 16, 17, 18, 19, 20, 21, 22, 66, 67, + /* 70 */ 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, + /* 80 */ 35, 1, 7, 8, 4, 5, 69, 7, 8, 9, + /* 90 */ 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, + /* 100 */ 20, 21, 22, 28, 61, 25, 26, 27, 28, 29, + /* 110 */ 30, 31, 32, 33, 34, 35, 39, 40, 41, 42, + /* 120 */ 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, + /* 130 */ 53, 54, 55, 56, 6, 2, 3, 78, 61, 6, + /* 140 */ 81, 57, 58, 66, 67, 68, 61, 70, 71, 75, + /* 150 */ 73, 74, 65, 76, 72, 78, 28, 80, 81, 57, + /* 160 */ 58, 28, 29, 30, 31, 32, 33, 2, 3, 46, + /* 170 */ 46, 6, 77, 78, 79, 80, 81, 57, 58, 58, + /* 180 */ 57, 58, 59, 60, 60, 6, 63, 64, 6, 10, + /* 190 */ 46, 6, 67, 28, 29, 30, 31, 32, 46, 17, + /* 200 */ 27, 57, 58, 59, 60, 19, 74, 63, 64, 57, + /* 210 */ 58, 59, 60, 2, 3, 63, 64, 6, 46, 18, + /* 220 */ 35, 5, 73, 46, 9, 9, 2, 3, 28, 57, + /* 230 */ 58, 59, 60, 46, 62, 58, 59, 60, 82, 28, + /* 240 */ 29, 30, 31, 46, 57, 58, 59, 60, 82, 62, + /* 250 */ 82, 27, 82, 82, 82, 58, 59, 60, }; -#define YY_SHIFT_USE_DFLT (256) +#define YY_SHIFT_USE_DFLT (258) #define YY_SHIFT_COUNT (40) -#define YY_SHIFT_MIN (0) -#define YY_SHIFT_MAX (216) -static const unsigned short int yy_shift_ofst[] = { - /* 0 */ 78, 44, 20, 20, 20, 20, 20, 22, 22, 20, - /* 10 */ 20, 20, 41, 191, 22, 35, 35, 57, 57, 57, - /* 20 */ 57, 35, 57, 129, 160, 205, 172, 216, 33, 206, - /* 30 */ 168, 35, 147, 35, 147, 167, 35, 195, 209, 210, - /* 40 */ 194, +#define YY_SHIFT_MIN (-3) +#define YY_SHIFT_MAX (224) +static const short yy_shift_ofst[] = { + /* 0 */ 80, 45, 128, 128, 128, 128, 128, 33, 33, 128, + /* 10 */ 128, 128, 23, 224, 33, 29, 29, -3, -3, -3, + /* 20 */ -3, 29, -3, 133, 165, 211, 19, 75, 185, 179, + /* 30 */ 182, 29, 173, 29, 173, 186, 29, 201, 216, 215, + /* 40 */ 200, }; -#define YY_REDUCE_USE_DFLT (-58) +#define YY_REDUCE_USE_DFLT (-59) #define YY_REDUCE_COUNT (37) -#define YY_REDUCE_MIN (-57) +#define YY_REDUCE_MIN (-58) #define YY_REDUCE_MAX (197) static const short yy_reduce_ofst[] = { - /* 0 */ -36, 75, 120, 140, 148, 182, 192, 92, -57, 171, - /* 10 */ 197, 197, -42, -40, -42, 25, 46, 94, 94, 94, - /* 20 */ 94, 81, 94, 63, 66, 83, 86, 89, 69, 85, - /* 30 */ 102, 116, 118, 116, 118, 128, 116, 149, + /* 0 */ -37, 77, 123, 144, 152, 172, 187, 95, -58, 177, + /* 10 */ 197, 197, 59, 2, 59, 84, 102, 124, 124, 124, + /* 20 */ 124, 120, 124, -29, -21, 17, 43, 85, 74, 82, + /* 30 */ 87, 121, 125, 121, 125, 132, 121, 149, }; static const YYACTIONTYPE yy_default[] = { - /* 0 */ 389, 389, 355, 354, 300, 329, 324, 382, 334, 348, - /* 10 */ 327, 322, 339, 283, 341, 381, 356, 350, 292, 328, - /* 20 */ 323, 290, 291, 365, 362, 359, 345, 279, 282, 278, - /* 30 */ 271, 331, 388, 296, 297, 281, 289, 280, 386, 386, - /* 40 */ 276, + /* 0 */ 395, 395, 360, 359, 305, 334, 329, 388, 339, 353, + /* 10 */ 332, 327, 344, 288, 346, 387, 361, 355, 297, 333, + /* 20 */ 328, 295, 296, 371, 368, 365, 350, 284, 287, 283, + /* 30 */ 275, 336, 394, 301, 302, 286, 294, 285, 392, 392, + /* 40 */ 281, }; /********** End of lemon-generated parsing tables *****************************/ @@ -407,20 +407,21 @@ static const char *const yyTokenName[] = { "LINE_ATX_2", "LINE_ATX_3", "LINE_ATX_4", "LINE_ATX_5", "LINE_ATX_6", "LINE_BLOCKQUOTE", "LINE_LIST_BULLETED", "LINE_LIST_ENUMERATED", "LINE_DEF_CITATION", "LINE_DEF_FOOTNOTE", "LINE_DEF_LINK", "LINE_FENCE_BACKTICK", - "LINE_FENCE_BACKTICK_START", "LINE_TOC", "LINE_DEFINITION", "LINE_EMPTY", - "LINE_FENCE_BACKTICK_3", "LINE_FENCE_BACKTICK_4", "LINE_FENCE_BACKTICK_5", "LINE_FENCE_BACKTICK_START_3", - "LINE_FENCE_BACKTICK_START_4", "LINE_FENCE_BACKTICK_START_5", "LINE_META", "error", - "doc", "blocks", "block", "blockquote", - "def_citation", "def_footnote", "def_link", "definition_block", - "empty", "fenced_block", "html_block", "indented_code", - "list_bullet", "list_enum", "meta_block", "para", - "setext_1", "setext_2", "table", "chunk", - "chunk_line", "nested_chunks", "nested_chunk", "indented_line", - "ext_chunk", "opt_ext_chunk", "tail", "quote_line", - "defs", "def", "fenced_3", "fenced_line", - "fenced_4", "fenced_5", "html_line", "item_bullet", - "item_enum", "meta_line", "table_header", "table_body", - "header_rows", "table_section", "all_rows", "row", + "LINE_FENCE_BACKTICK_START", "LINE_TOC", "LINE_DEF_ABBREVIATION", "LINE_DEFINITION", + "LINE_EMPTY", "LINE_FENCE_BACKTICK_3", "LINE_FENCE_BACKTICK_4", "LINE_FENCE_BACKTICK_5", + "LINE_FENCE_BACKTICK_START_3", "LINE_FENCE_BACKTICK_START_4", "LINE_FENCE_BACKTICK_START_5", "LINE_META", + "error", "doc", "blocks", "block", + "blockquote", "def_abbreviation", "def_citation", "def_footnote", + "def_link", "definition_block", "empty", "fenced_block", + "html_block", "indented_code", "list_bullet", "list_enum", + "meta_block", "para", "setext_1", "setext_2", + "table", "chunk", "chunk_line", "nested_chunks", + "nested_chunk", "indented_line", "ext_chunk", "opt_ext_chunk", + "tail", "quote_line", "defs", "def", + "fenced_3", "fenced_line", "fenced_4", "fenced_5", + "html_line", "item_bullet", "item_enum", "meta_line", + "table_header", "table_body", "header_rows", "table_section", + "all_rows", "row", }; #endif /* NDEBUG */ @@ -440,123 +441,125 @@ static const char *const yyRuleName[] = { /* 9 */ "block ::= LINE_HR", /* 10 */ "block ::= LINE_TOC", /* 11 */ "block ::= blockquote", - /* 12 */ "block ::= def_citation", - /* 13 */ "block ::= def_footnote", - /* 14 */ "block ::= def_link", - /* 15 */ "block ::= definition_block", - /* 16 */ "block ::= empty", - /* 17 */ "block ::= fenced_block", - /* 18 */ "block ::= html_block", - /* 19 */ "block ::= indented_code", - /* 20 */ "block ::= list_bullet", - /* 21 */ "block ::= list_enum", - /* 22 */ "block ::= meta_block", - /* 23 */ "block ::= para", - /* 24 */ "block ::= setext_1", - /* 25 */ "block ::= setext_2", - /* 26 */ "block ::= table", - /* 27 */ "chunk ::= chunk chunk_line", - /* 28 */ "nested_chunks ::= nested_chunks nested_chunk", - /* 29 */ "nested_chunk ::= empty indented_line chunk", - /* 30 */ "nested_chunk ::= empty indented_line", - /* 31 */ "ext_chunk ::= chunk nested_chunks", - /* 32 */ "opt_ext_chunk ::= chunk nested_chunks", - /* 33 */ "blockquote ::= blockquote quote_line", - /* 34 */ "def_citation ::= LINE_DEF_CITATION tail", - /* 35 */ "def_footnote ::= LINE_DEF_FOOTNOTE tail", - /* 36 */ "def_link ::= LINE_DEF_LINK chunk", - /* 37 */ "definition_block ::= para defs", - /* 38 */ "defs ::= defs def", - /* 39 */ "def ::= LINE_DEFINITION tail", - /* 40 */ "def ::= LINE_DEFINITION", - /* 41 */ "empty ::= empty LINE_EMPTY", - /* 42 */ "fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_3", - /* 43 */ "fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_4", - /* 44 */ "fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_5", - /* 45 */ "fenced_3 ::= fenced_3 fenced_line", - /* 46 */ "fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_4", - /* 47 */ "fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_5", - /* 48 */ "fenced_4 ::= fenced_4 fenced_line", - /* 49 */ "fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_3", - /* 50 */ "fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_START_3", - /* 51 */ "fenced_block ::= fenced_5 LINE_FENCE_BACKTICK_5", - /* 52 */ "fenced_5 ::= fenced_5 fenced_line", - /* 53 */ "fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_3", - /* 54 */ "fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_3", - /* 55 */ "fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_4", - /* 56 */ "fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_4", - /* 57 */ "html_block ::= html_block html_line", - /* 58 */ "indented_code ::= indented_code indented_line", - /* 59 */ "indented_code ::= indented_code LINE_EMPTY", - /* 60 */ "list_bullet ::= list_bullet item_bullet", - /* 61 */ "item_bullet ::= LINE_LIST_BULLETED ext_chunk", - /* 62 */ "item_bullet ::= LINE_LIST_BULLETED chunk", - /* 63 */ "item_bullet ::= LINE_LIST_BULLETED nested_chunks", - /* 64 */ "item_bullet ::= LINE_LIST_BULLETED", - /* 65 */ "list_enum ::= list_enum item_enum", - /* 66 */ "item_enum ::= LINE_LIST_ENUMERATED ext_chunk", - /* 67 */ "item_enum ::= LINE_LIST_ENUMERATED chunk", - /* 68 */ "item_enum ::= LINE_LIST_ENUMERATED nested_chunks", - /* 69 */ "item_enum ::= LINE_LIST_ENUMERATED", - /* 70 */ "meta_block ::= meta_block meta_line", - /* 71 */ "para ::= LINE_PLAIN chunk", - /* 72 */ "setext_1 ::= para LINE_SETEXT_1", - /* 73 */ "setext_2 ::= para LINE_SETEXT_2", - /* 74 */ "table ::= table_header table_body", - /* 75 */ "table_header ::= header_rows LINE_TABLE_SEPARATOR", - /* 76 */ "header_rows ::= header_rows LINE_TABLE", - /* 77 */ "table_body ::= table_body table_section", - /* 78 */ "table_section ::= all_rows LINE_EMPTY", - /* 79 */ "table_section ::= all_rows", - /* 80 */ "all_rows ::= all_rows row", - /* 81 */ "para ::= all_rows", - /* 82 */ "chunk ::= chunk_line", - /* 83 */ "chunk_line ::= LINE_CONTINUATION", - /* 84 */ "nested_chunks ::= nested_chunk", - /* 85 */ "nested_chunk ::= empty", - /* 86 */ "indented_line ::= LINE_INDENTED_TAB", - /* 87 */ "indented_line ::= LINE_INDENTED_SPACE", - /* 88 */ "opt_ext_chunk ::= chunk", - /* 89 */ "tail ::= opt_ext_chunk", - /* 90 */ "tail ::= nested_chunks", - /* 91 */ "blockquote ::= LINE_BLOCKQUOTE", - /* 92 */ "quote_line ::= LINE_BLOCKQUOTE", - /* 93 */ "quote_line ::= LINE_CONTINUATION", - /* 94 */ "def_citation ::= LINE_DEF_CITATION", - /* 95 */ "def_footnote ::= LINE_DEF_FOOTNOTE", - /* 96 */ "def_link ::= LINE_DEF_LINK", - /* 97 */ "defs ::= def", - /* 98 */ "empty ::= LINE_EMPTY", - /* 99 */ "fenced_block ::= fenced_3", - /* 100 */ "fenced_3 ::= LINE_FENCE_BACKTICK_3", - /* 101 */ "fenced_3 ::= LINE_FENCE_BACKTICK_START_3", - /* 102 */ "fenced_block ::= fenced_4", - /* 103 */ "fenced_4 ::= LINE_FENCE_BACKTICK_4", - /* 104 */ "fenced_4 ::= LINE_FENCE_BACKTICK_START_4", - /* 105 */ "fenced_block ::= fenced_5", - /* 106 */ "fenced_5 ::= LINE_FENCE_BACKTICK_5", - /* 107 */ "fenced_5 ::= LINE_FENCE_BACKTICK_START_5", - /* 108 */ "fenced_line ::= LINE_CONTINUATION", - /* 109 */ "fenced_line ::= LINE_EMPTY", - /* 110 */ "fenced_line ::= LINE_SETEXT_1", - /* 111 */ "fenced_line ::= LINE_SETEXT_2", - /* 112 */ "html_block ::= LINE_HTML", - /* 113 */ "html_line ::= LINE_CONTINUATION", - /* 114 */ "html_line ::= LINE_HTML", - /* 115 */ "indented_code ::= indented_line", - /* 116 */ "list_bullet ::= item_bullet", - /* 117 */ "list_enum ::= item_enum", - /* 118 */ "meta_block ::= LINE_META", - /* 119 */ "meta_line ::= LINE_META", - /* 120 */ "meta_line ::= LINE_CONTINUATION", - /* 121 */ "para ::= LINE_PLAIN", - /* 122 */ "table ::= table_header", - /* 123 */ "header_rows ::= LINE_TABLE", - /* 124 */ "table_body ::= table_section", - /* 125 */ "all_rows ::= row", - /* 126 */ "row ::= header_rows", - /* 127 */ "row ::= LINE_TABLE_SEPARATOR", - /* 128 */ "para ::= defs", + /* 12 */ "block ::= def_abbreviation", + /* 13 */ "block ::= def_citation", + /* 14 */ "block ::= def_footnote", + /* 15 */ "block ::= def_link", + /* 16 */ "block ::= definition_block", + /* 17 */ "block ::= empty", + /* 18 */ "block ::= fenced_block", + /* 19 */ "block ::= html_block", + /* 20 */ "block ::= indented_code", + /* 21 */ "block ::= list_bullet", + /* 22 */ "block ::= list_enum", + /* 23 */ "block ::= meta_block", + /* 24 */ "block ::= para", + /* 25 */ "block ::= setext_1", + /* 26 */ "block ::= setext_2", + /* 27 */ "block ::= table", + /* 28 */ "chunk ::= chunk chunk_line", + /* 29 */ "nested_chunks ::= nested_chunks nested_chunk", + /* 30 */ "nested_chunk ::= empty indented_line chunk", + /* 31 */ "nested_chunk ::= empty indented_line", + /* 32 */ "ext_chunk ::= chunk nested_chunks", + /* 33 */ "opt_ext_chunk ::= chunk nested_chunks", + /* 34 */ "blockquote ::= blockquote quote_line", + /* 35 */ "def_citation ::= LINE_DEF_CITATION tail", + /* 36 */ "def_footnote ::= LINE_DEF_FOOTNOTE tail", + /* 37 */ "def_link ::= LINE_DEF_LINK chunk", + /* 38 */ "definition_block ::= para defs", + /* 39 */ "defs ::= defs def", + /* 40 */ "def ::= LINE_DEFINITION tail", + /* 41 */ "def ::= LINE_DEFINITION", + /* 42 */ "empty ::= empty LINE_EMPTY", + /* 43 */ "fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_3", + /* 44 */ "fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_4", + /* 45 */ "fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_5", + /* 46 */ "fenced_3 ::= fenced_3 fenced_line", + /* 47 */ "fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_4", + /* 48 */ "fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_5", + /* 49 */ "fenced_4 ::= fenced_4 fenced_line", + /* 50 */ "fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_3", + /* 51 */ "fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_START_3", + /* 52 */ "fenced_block ::= fenced_5 LINE_FENCE_BACKTICK_5", + /* 53 */ "fenced_5 ::= fenced_5 fenced_line", + /* 54 */ "fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_3", + /* 55 */ "fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_3", + /* 56 */ "fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_4", + /* 57 */ "fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_4", + /* 58 */ "html_block ::= html_block html_line", + /* 59 */ "indented_code ::= indented_code indented_line", + /* 60 */ "indented_code ::= indented_code LINE_EMPTY", + /* 61 */ "list_bullet ::= list_bullet item_bullet", + /* 62 */ "item_bullet ::= LINE_LIST_BULLETED ext_chunk", + /* 63 */ "item_bullet ::= LINE_LIST_BULLETED chunk", + /* 64 */ "item_bullet ::= LINE_LIST_BULLETED nested_chunks", + /* 65 */ "item_bullet ::= LINE_LIST_BULLETED", + /* 66 */ "list_enum ::= list_enum item_enum", + /* 67 */ "item_enum ::= LINE_LIST_ENUMERATED ext_chunk", + /* 68 */ "item_enum ::= LINE_LIST_ENUMERATED chunk", + /* 69 */ "item_enum ::= LINE_LIST_ENUMERATED nested_chunks", + /* 70 */ "item_enum ::= LINE_LIST_ENUMERATED", + /* 71 */ "meta_block ::= meta_block meta_line", + /* 72 */ "para ::= LINE_PLAIN chunk", + /* 73 */ "setext_1 ::= para LINE_SETEXT_1", + /* 74 */ "setext_2 ::= para LINE_SETEXT_2", + /* 75 */ "table ::= table_header table_body", + /* 76 */ "table_header ::= header_rows LINE_TABLE_SEPARATOR", + /* 77 */ "header_rows ::= header_rows LINE_TABLE", + /* 78 */ "table_body ::= table_body table_section", + /* 79 */ "table_section ::= all_rows LINE_EMPTY", + /* 80 */ "table_section ::= all_rows", + /* 81 */ "all_rows ::= all_rows row", + /* 82 */ "para ::= all_rows", + /* 83 */ "chunk ::= chunk_line", + /* 84 */ "chunk_line ::= LINE_CONTINUATION", + /* 85 */ "nested_chunks ::= nested_chunk", + /* 86 */ "nested_chunk ::= empty", + /* 87 */ "indented_line ::= LINE_INDENTED_TAB", + /* 88 */ "indented_line ::= LINE_INDENTED_SPACE", + /* 89 */ "opt_ext_chunk ::= chunk", + /* 90 */ "tail ::= opt_ext_chunk", + /* 91 */ "tail ::= nested_chunks", + /* 92 */ "blockquote ::= LINE_BLOCKQUOTE", + /* 93 */ "quote_line ::= LINE_BLOCKQUOTE", + /* 94 */ "quote_line ::= LINE_CONTINUATION", + /* 95 */ "def_citation ::= LINE_DEF_CITATION", + /* 96 */ "def_footnote ::= LINE_DEF_FOOTNOTE", + /* 97 */ "def_link ::= LINE_DEF_LINK", + /* 98 */ "def_abbreviation ::= LINE_DEF_ABBREVIATION", + /* 99 */ "defs ::= def", + /* 100 */ "empty ::= LINE_EMPTY", + /* 101 */ "fenced_block ::= fenced_3", + /* 102 */ "fenced_3 ::= LINE_FENCE_BACKTICK_3", + /* 103 */ "fenced_3 ::= LINE_FENCE_BACKTICK_START_3", + /* 104 */ "fenced_block ::= fenced_4", + /* 105 */ "fenced_4 ::= LINE_FENCE_BACKTICK_4", + /* 106 */ "fenced_4 ::= LINE_FENCE_BACKTICK_START_4", + /* 107 */ "fenced_block ::= fenced_5", + /* 108 */ "fenced_5 ::= LINE_FENCE_BACKTICK_5", + /* 109 */ "fenced_5 ::= LINE_FENCE_BACKTICK_START_5", + /* 110 */ "fenced_line ::= LINE_CONTINUATION", + /* 111 */ "fenced_line ::= LINE_EMPTY", + /* 112 */ "fenced_line ::= LINE_SETEXT_1", + /* 113 */ "fenced_line ::= LINE_SETEXT_2", + /* 114 */ "html_block ::= LINE_HTML", + /* 115 */ "html_line ::= LINE_CONTINUATION", + /* 116 */ "html_line ::= LINE_HTML", + /* 117 */ "indented_code ::= indented_line", + /* 118 */ "list_bullet ::= item_bullet", + /* 119 */ "list_enum ::= item_enum", + /* 120 */ "meta_block ::= LINE_META", + /* 121 */ "meta_line ::= LINE_META", + /* 122 */ "meta_line ::= LINE_CONTINUATION", + /* 123 */ "para ::= LINE_PLAIN", + /* 124 */ "table ::= table_header", + /* 125 */ "header_rows ::= LINE_TABLE", + /* 126 */ "table_body ::= table_section", + /* 127 */ "all_rows ::= row", + /* 128 */ "row ::= header_rows", + /* 129 */ "row ::= LINE_TABLE_SEPARATOR", + /* 130 */ "para ::= defs", }; #endif /* NDEBUG */ @@ -753,7 +756,7 @@ static unsigned int yy_find_shift_action( yyTracePrompt, yyTokenName[iLookAhead], yyTokenName[iFallback]); } #endif - // assert( yyFallback[iFallback]==0 ); /* Fallback loop must terminate */ + assert( yyFallback[iFallback]==0 ); /* Fallback loop must terminate */ iLookAhead = iFallback; continue; } @@ -905,135 +908,137 @@ static const struct { YYCODETYPE lhs; /* Symbol on the left-hand side of the rule */ unsigned char nrhs; /* Number of right-hand side symbols in the rule */ } yyRuleInfo[] = { - { 36, 1 }, - { 37, 2 }, { 37, 1 }, + { 38, 2 }, { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 38, 1 }, - { 55, 2 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, + { 39, 1 }, { 57, 2 }, - { 58, 3 }, - { 58, 2 }, + { 59, 2 }, + { 60, 3 }, { 60, 2 }, - { 61, 2 }, - { 39, 2 }, + { 62, 2 }, + { 63, 2 }, { 40, 2 }, - { 41, 2 }, { 42, 2 }, { 43, 2 }, - { 64, 2 }, - { 65, 2 }, - { 65, 1 }, { 44, 2 }, { 45, 2 }, - { 45, 2 }, - { 45, 2 }, { 66, 2 }, - { 45, 2 }, - { 45, 2 }, - { 68, 2 }, - { 68, 2 }, - { 68, 2 }, - { 45, 2 }, - { 69, 2 }, - { 69, 2 }, - { 69, 2 }, - { 69, 2 }, - { 69, 2 }, + { 67, 2 }, + { 67, 1 }, { 46, 2 }, { 47, 2 }, { 47, 2 }, - { 48, 2 }, + { 47, 2 }, + { 68, 2 }, + { 47, 2 }, + { 47, 2 }, + { 70, 2 }, + { 70, 2 }, + { 70, 2 }, + { 47, 2 }, { 71, 2 }, { 71, 2 }, { 71, 2 }, - { 71, 1 }, + { 71, 2 }, + { 71, 2 }, + { 48, 2 }, + { 49, 2 }, { 49, 2 }, - { 72, 2 }, - { 72, 2 }, - { 72, 2 }, - { 72, 1 }, { 50, 2 }, + { 73, 2 }, + { 73, 2 }, + { 73, 2 }, + { 73, 1 }, { 51, 2 }, + { 74, 2 }, + { 74, 2 }, + { 74, 2 }, + { 74, 1 }, { 52, 2 }, { 53, 2 }, { 54, 2 }, - { 74, 2 }, + { 55, 2 }, + { 56, 2 }, { 76, 2 }, - { 75, 2 }, - { 77, 2 }, - { 77, 1 }, { 78, 2 }, - { 51, 1 }, - { 55, 1 }, - { 56, 1 }, + { 77, 2 }, + { 79, 2 }, + { 79, 1 }, + { 80, 2 }, + { 53, 1 }, { 57, 1 }, { 58, 1 }, { 59, 1 }, - { 59, 1 }, + { 60, 1 }, + { 61, 1 }, { 61, 1 }, - { 62, 1 }, - { 62, 1 }, - { 39, 1 }, - { 63, 1 }, { 63, 1 }, + { 64, 1 }, + { 64, 1 }, { 40, 1 }, - { 41, 1 }, + { 65, 1 }, + { 65, 1 }, { 42, 1 }, - { 64, 1 }, + { 43, 1 }, { 44, 1 }, - { 45, 1 }, - { 66, 1 }, + { 41, 1 }, { 66, 1 }, - { 45, 1 }, + { 46, 1 }, + { 47, 1 }, { 68, 1 }, { 68, 1 }, - { 45, 1 }, - { 69, 1 }, - { 69, 1 }, - { 67, 1 }, - { 67, 1 }, - { 67, 1 }, - { 67, 1 }, - { 46, 1 }, + { 47, 1 }, { 70, 1 }, { 70, 1 }, { 47, 1 }, + { 71, 1 }, + { 71, 1 }, + { 69, 1 }, + { 69, 1 }, + { 69, 1 }, + { 69, 1 }, { 48, 1 }, + { 72, 1 }, + { 72, 1 }, { 49, 1 }, { 50, 1 }, - { 73, 1 }, - { 73, 1 }, { 51, 1 }, - { 54, 1 }, - { 76, 1 }, + { 52, 1 }, + { 75, 1 }, { 75, 1 }, + { 53, 1 }, + { 56, 1 }, { 78, 1 }, - { 79, 1 }, - { 79, 1 }, - { 51, 1 }, + { 77, 1 }, + { 80, 1 }, + { 81, 1 }, + { 81, 1 }, + { 53, 1 }, }; static void yy_accept(yyParser*); /* Forward Declaration */ @@ -1114,7 +1119,7 @@ static void yy_reduce( break; case 2: /* blocks ::= block */ { - engine->root = yymsp[0].minor.yy0; + engine->root = yymsp[0].minor.yy0; // In case the first block is metadata and we just want to know if it exists strip_line_tokens_from_block(engine, yymsp[0].minor.yy0); #ifndef NDEBUG fprintf(stderr, "First block %d\n", yymsp[0].minor.yy0->type); @@ -1159,211 +1164,216 @@ static void yy_reduce( { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_BLOCKQUOTE); recursive_parse_blockquote(engine, yylhsminor.yy0); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 12: /* block ::= def_citation */ + case 12: /* block ::= def_abbreviation */ +{ yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_DEF_ABBREVIATION); stack_push(engine->definition_stack, yylhsminor.yy0); } + yymsp[0].minor.yy0 = yylhsminor.yy0; + break; + case 13: /* block ::= def_citation */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_DEF_CITATION); stack_push(engine->definition_stack, yylhsminor.yy0); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 13: /* block ::= def_footnote */ + case 14: /* block ::= def_footnote */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_DEF_FOOTNOTE); stack_push(engine->definition_stack, yylhsminor.yy0); recursive_parse_indent(engine, yylhsminor.yy0); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 14: /* block ::= def_link */ + case 15: /* block ::= def_link */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_DEF_LINK); stack_push(engine->definition_stack, yylhsminor.yy0); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 15: /* block ::= definition_block */ + case 16: /* block ::= definition_block */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_DEFLIST); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 16: /* block ::= empty */ + case 17: /* block ::= empty */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_EMPTY); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 17: /* block ::= fenced_block */ + case 18: /* block ::= fenced_block */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_CODE_FENCED); yymsp[0].minor.yy0->child->type = CODE_FENCE; } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 18: /* block ::= html_block */ + case 19: /* block ::= html_block */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_HTML); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 19: /* block ::= indented_code */ + case 20: /* block ::= indented_code */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_CODE_INDENTED); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 20: /* block ::= list_bullet */ + case 21: /* block ::= list_bullet */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_LIST_BULLETED); is_list_loose(yylhsminor.yy0); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 21: /* block ::= list_enum */ + case 22: /* block ::= list_enum */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_LIST_ENUMERATED); is_list_loose(yylhsminor.yy0); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 22: /* block ::= meta_block */ + case 23: /* block ::= meta_block */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_META); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 23: /* block ::= para */ + case 24: /* block ::= para */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_PARA); is_para_html(engine, yylhsminor.yy0); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 24: /* block ::= setext_1 */ + case 25: /* block ::= setext_1 */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_SETEXT_1); if (!(engine->extensions & EXT_NO_LABELS)) stack_push(engine->header_stack, yylhsminor.yy0); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 25: /* block ::= setext_2 */ + case 26: /* block ::= setext_2 */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_SETEXT_2); if (!(engine->extensions & EXT_NO_LABELS)) stack_push(engine->header_stack, yylhsminor.yy0); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 26: /* block ::= table */ + case 27: /* block ::= table */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_TABLE); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 27: /* chunk ::= chunk chunk_line */ - case 28: /* nested_chunks ::= nested_chunks nested_chunk */ yytestcase(yyruleno==28); - case 31: /* ext_chunk ::= chunk nested_chunks */ yytestcase(yyruleno==31); - case 32: /* opt_ext_chunk ::= chunk nested_chunks */ yytestcase(yyruleno==32); - case 33: /* blockquote ::= blockquote quote_line */ yytestcase(yyruleno==33); - case 34: /* def_citation ::= LINE_DEF_CITATION tail */ yytestcase(yyruleno==34); - case 35: /* def_footnote ::= LINE_DEF_FOOTNOTE tail */ yytestcase(yyruleno==35); - case 36: /* def_link ::= LINE_DEF_LINK chunk */ yytestcase(yyruleno==36); - case 38: /* defs ::= defs def */ yytestcase(yyruleno==38); - case 41: /* empty ::= empty LINE_EMPTY */ yytestcase(yyruleno==41); - case 45: /* fenced_3 ::= fenced_3 fenced_line */ yytestcase(yyruleno==45); - case 48: /* fenced_4 ::= fenced_4 fenced_line */ yytestcase(yyruleno==48); - case 49: /* fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_3 */ yytestcase(yyruleno==49); - case 50: /* fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_START_3 */ yytestcase(yyruleno==50); - case 52: /* fenced_5 ::= fenced_5 fenced_line */ yytestcase(yyruleno==52); - case 53: /* fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_3 */ yytestcase(yyruleno==53); - case 54: /* fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_3 */ yytestcase(yyruleno==54); - case 55: /* fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_4 */ yytestcase(yyruleno==55); - case 56: /* fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_4 */ yytestcase(yyruleno==56); - case 57: /* html_block ::= html_block html_line */ yytestcase(yyruleno==57); - case 58: /* indented_code ::= indented_code indented_line */ yytestcase(yyruleno==58); - case 59: /* indented_code ::= indented_code LINE_EMPTY */ yytestcase(yyruleno==59); - case 60: /* list_bullet ::= list_bullet item_bullet */ yytestcase(yyruleno==60); - case 65: /* list_enum ::= list_enum item_enum */ yytestcase(yyruleno==65); - case 70: /* meta_block ::= meta_block meta_line */ yytestcase(yyruleno==70); - case 71: /* para ::= LINE_PLAIN chunk */ yytestcase(yyruleno==71); - case 72: /* setext_1 ::= para LINE_SETEXT_1 */ yytestcase(yyruleno==72); - case 73: /* setext_2 ::= para LINE_SETEXT_2 */ yytestcase(yyruleno==73); - case 74: /* table ::= table_header table_body */ yytestcase(yyruleno==74); - case 76: /* header_rows ::= header_rows LINE_TABLE */ yytestcase(yyruleno==76); - case 77: /* table_body ::= table_body table_section */ yytestcase(yyruleno==77); - case 80: /* all_rows ::= all_rows row */ yytestcase(yyruleno==80); + case 28: /* chunk ::= chunk chunk_line */ + case 29: /* nested_chunks ::= nested_chunks nested_chunk */ yytestcase(yyruleno==29); + case 32: /* ext_chunk ::= chunk nested_chunks */ yytestcase(yyruleno==32); + case 33: /* opt_ext_chunk ::= chunk nested_chunks */ yytestcase(yyruleno==33); + case 34: /* blockquote ::= blockquote quote_line */ yytestcase(yyruleno==34); + case 35: /* def_citation ::= LINE_DEF_CITATION tail */ yytestcase(yyruleno==35); + case 36: /* def_footnote ::= LINE_DEF_FOOTNOTE tail */ yytestcase(yyruleno==36); + case 37: /* def_link ::= LINE_DEF_LINK chunk */ yytestcase(yyruleno==37); + case 39: /* defs ::= defs def */ yytestcase(yyruleno==39); + case 42: /* empty ::= empty LINE_EMPTY */ yytestcase(yyruleno==42); + case 46: /* fenced_3 ::= fenced_3 fenced_line */ yytestcase(yyruleno==46); + case 49: /* fenced_4 ::= fenced_4 fenced_line */ yytestcase(yyruleno==49); + case 50: /* fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_3 */ yytestcase(yyruleno==50); + case 51: /* fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_START_3 */ yytestcase(yyruleno==51); + case 53: /* fenced_5 ::= fenced_5 fenced_line */ yytestcase(yyruleno==53); + case 54: /* fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_3 */ yytestcase(yyruleno==54); + case 55: /* fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_3 */ yytestcase(yyruleno==55); + case 56: /* fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_4 */ yytestcase(yyruleno==56); + case 57: /* fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_4 */ yytestcase(yyruleno==57); + case 58: /* html_block ::= html_block html_line */ yytestcase(yyruleno==58); + case 59: /* indented_code ::= indented_code indented_line */ yytestcase(yyruleno==59); + case 60: /* indented_code ::= indented_code LINE_EMPTY */ yytestcase(yyruleno==60); + case 61: /* list_bullet ::= list_bullet item_bullet */ yytestcase(yyruleno==61); + case 66: /* list_enum ::= list_enum item_enum */ yytestcase(yyruleno==66); + case 71: /* meta_block ::= meta_block meta_line */ yytestcase(yyruleno==71); + case 72: /* para ::= LINE_PLAIN chunk */ yytestcase(yyruleno==72); + case 73: /* setext_1 ::= para LINE_SETEXT_1 */ yytestcase(yyruleno==73); + case 74: /* setext_2 ::= para LINE_SETEXT_2 */ yytestcase(yyruleno==74); + case 75: /* table ::= table_header table_body */ yytestcase(yyruleno==75); + case 77: /* header_rows ::= header_rows LINE_TABLE */ yytestcase(yyruleno==77); + case 78: /* table_body ::= table_body table_section */ yytestcase(yyruleno==78); + case 81: /* all_rows ::= all_rows row */ yytestcase(yyruleno==81); { yylhsminor.yy0 = yymsp[-1].minor.yy0; token_chain_append(yymsp[-1].minor.yy0, yymsp[0].minor.yy0); } yymsp[-1].minor.yy0 = yylhsminor.yy0; break; - case 29: /* nested_chunk ::= empty indented_line chunk */ + case 30: /* nested_chunk ::= empty indented_line chunk */ { yylhsminor.yy0 = yymsp[-2].minor.yy0; token_chain_append(yymsp[-2].minor.yy0, yymsp[-1].minor.yy0); token_chain_append(yymsp[-2].minor.yy0, yymsp[0].minor.yy0); yymsp[-1].minor.yy0->type = LINE_CONTINUATION; } yymsp[-2].minor.yy0 = yylhsminor.yy0; break; - case 30: /* nested_chunk ::= empty indented_line */ + case 31: /* nested_chunk ::= empty indented_line */ { yylhsminor.yy0 = yymsp[-1].minor.yy0; token_chain_append(yymsp[-1].minor.yy0, yymsp[0].minor.yy0); yymsp[0].minor.yy0->type = LINE_CONTINUATION; } yymsp[-1].minor.yy0 = yylhsminor.yy0; break; - case 37: /* definition_block ::= para defs */ + case 38: /* definition_block ::= para defs */ { yylhsminor.yy0 = yymsp[-1].minor.yy0; token_chain_append(yymsp[-1].minor.yy0, yymsp[0].minor.yy0); yymsp[-1].minor.yy0->type = BLOCK_TERM; } yymsp[-1].minor.yy0 = yylhsminor.yy0; break; - case 39: /* def ::= LINE_DEFINITION tail */ + case 40: /* def ::= LINE_DEFINITION tail */ { yylhsminor.yy0 = token_new_parent(yymsp[-1].minor.yy0, BLOCK_DEFINITION); token_chain_append(yymsp[-1].minor.yy0, yymsp[0].minor.yy0); recursive_parse_indent(engine, yylhsminor.yy0); } yymsp[-1].minor.yy0 = yylhsminor.yy0; break; - case 40: /* def ::= LINE_DEFINITION */ + case 41: /* def ::= LINE_DEFINITION */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_DEFINITION); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 42: /* fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_3 */ - case 43: /* fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_4 */ yytestcase(yyruleno==43); - case 44: /* fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_5 */ yytestcase(yyruleno==44); - case 46: /* fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_4 */ yytestcase(yyruleno==46); - case 47: /* fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_5 */ yytestcase(yyruleno==47); - case 51: /* fenced_block ::= fenced_5 LINE_FENCE_BACKTICK_5 */ yytestcase(yyruleno==51); + case 43: /* fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_3 */ + case 44: /* fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_4 */ yytestcase(yyruleno==44); + case 45: /* fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_5 */ yytestcase(yyruleno==45); + case 47: /* fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_4 */ yytestcase(yyruleno==47); + case 48: /* fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_5 */ yytestcase(yyruleno==48); + case 52: /* fenced_block ::= fenced_5 LINE_FENCE_BACKTICK_5 */ yytestcase(yyruleno==52); { yylhsminor.yy0 = yymsp[-1].minor.yy0; token_chain_append(yymsp[-1].minor.yy0, yymsp[0].minor.yy0); yymsp[0].minor.yy0->child->type = CODE_FENCE; } yymsp[-1].minor.yy0 = yylhsminor.yy0; break; - case 61: /* item_bullet ::= LINE_LIST_BULLETED ext_chunk */ - case 63: /* item_bullet ::= LINE_LIST_BULLETED nested_chunks */ yytestcase(yyruleno==63); - case 66: /* item_enum ::= LINE_LIST_ENUMERATED ext_chunk */ yytestcase(yyruleno==66); - case 68: /* item_enum ::= LINE_LIST_ENUMERATED nested_chunks */ yytestcase(yyruleno==68); + case 62: /* item_bullet ::= LINE_LIST_BULLETED ext_chunk */ + case 64: /* item_bullet ::= LINE_LIST_BULLETED nested_chunks */ yytestcase(yyruleno==64); + case 67: /* item_enum ::= LINE_LIST_ENUMERATED ext_chunk */ yytestcase(yyruleno==67); + case 69: /* item_enum ::= LINE_LIST_ENUMERATED nested_chunks */ yytestcase(yyruleno==69); { yylhsminor.yy0 = token_new_parent(yymsp[-1].minor.yy0, BLOCK_LIST_ITEM); token_chain_append(yymsp[-1].minor.yy0, yymsp[0].minor.yy0); recursive_parse_list_item(engine, yylhsminor.yy0); } yymsp[-1].minor.yy0 = yylhsminor.yy0; break; - case 62: /* item_bullet ::= LINE_LIST_BULLETED chunk */ - case 67: /* item_enum ::= LINE_LIST_ENUMERATED chunk */ yytestcase(yyruleno==67); + case 63: /* item_bullet ::= LINE_LIST_BULLETED chunk */ + case 68: /* item_enum ::= LINE_LIST_ENUMERATED chunk */ yytestcase(yyruleno==68); { yylhsminor.yy0 = token_new_parent(yymsp[-1].minor.yy0, BLOCK_LIST_ITEM_TIGHT); token_chain_append(yymsp[-1].minor.yy0, yymsp[0].minor.yy0); recursive_parse_list_item(engine, yylhsminor.yy0); } yymsp[-1].minor.yy0 = yylhsminor.yy0; break; - case 64: /* item_bullet ::= LINE_LIST_BULLETED */ - case 69: /* item_enum ::= LINE_LIST_ENUMERATED */ yytestcase(yyruleno==69); + case 65: /* item_bullet ::= LINE_LIST_BULLETED */ + case 70: /* item_enum ::= LINE_LIST_ENUMERATED */ yytestcase(yyruleno==70); { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_LIST_ITEM_TIGHT); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 75: /* table_header ::= header_rows LINE_TABLE_SEPARATOR */ + case 76: /* table_header ::= header_rows LINE_TABLE_SEPARATOR */ { yylhsminor.yy0 = token_new_parent(yymsp[-1].minor.yy0, BLOCK_TABLE_HEADER); token_chain_append(yymsp[-1].minor.yy0, yymsp[0].minor.yy0); } yymsp[-1].minor.yy0 = yylhsminor.yy0; break; - case 78: /* table_section ::= all_rows LINE_EMPTY */ + case 79: /* table_section ::= all_rows LINE_EMPTY */ { yylhsminor.yy0 = token_new_parent(yymsp[-1].minor.yy0, BLOCK_TABLE_SECTION); token_chain_append(yymsp[-1].minor.yy0, yymsp[0].minor.yy0); } yymsp[-1].minor.yy0 = yylhsminor.yy0; break; - case 79: /* table_section ::= all_rows */ + case 80: /* table_section ::= all_rows */ { yylhsminor.yy0 = token_new_parent(yymsp[0].minor.yy0, BLOCK_TABLE_SECTION); } yymsp[0].minor.yy0 = yylhsminor.yy0; break; - case 81: /* para ::= all_rows */ + case 82: /* para ::= all_rows */ { yylhsminor.yy0 = yymsp[0].minor.yy0; } yymsp[0].minor.yy0 = yylhsminor.yy0; break; default: - /* (82) chunk ::= chunk_line (OPTIMIZED OUT) */ assert(yyruleno!=82); - /* (83) chunk_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==83); - /* (84) nested_chunks ::= nested_chunk (OPTIMIZED OUT) */ assert(yyruleno!=84); - /* (85) nested_chunk ::= empty */ yytestcase(yyruleno==85); - /* (86) indented_line ::= LINE_INDENTED_TAB */ yytestcase(yyruleno==86); - /* (87) indented_line ::= LINE_INDENTED_SPACE */ yytestcase(yyruleno==87); - /* (88) opt_ext_chunk ::= chunk */ yytestcase(yyruleno==88); - /* (89) tail ::= opt_ext_chunk (OPTIMIZED OUT) */ assert(yyruleno!=89); - /* (90) tail ::= nested_chunks */ yytestcase(yyruleno==90); - /* (91) blockquote ::= LINE_BLOCKQUOTE */ yytestcase(yyruleno==91); - /* (92) quote_line ::= LINE_BLOCKQUOTE */ yytestcase(yyruleno==92); - /* (93) quote_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==93); - /* (94) def_citation ::= LINE_DEF_CITATION */ yytestcase(yyruleno==94); - /* (95) def_footnote ::= LINE_DEF_FOOTNOTE */ yytestcase(yyruleno==95); - /* (96) def_link ::= LINE_DEF_LINK */ yytestcase(yyruleno==96); - /* (97) defs ::= def (OPTIMIZED OUT) */ assert(yyruleno!=97); - /* (98) empty ::= LINE_EMPTY */ yytestcase(yyruleno==98); - /* (99) fenced_block ::= fenced_3 */ yytestcase(yyruleno==99); - /* (100) fenced_3 ::= LINE_FENCE_BACKTICK_3 */ yytestcase(yyruleno==100); - /* (101) fenced_3 ::= LINE_FENCE_BACKTICK_START_3 */ yytestcase(yyruleno==101); - /* (102) fenced_block ::= fenced_4 */ yytestcase(yyruleno==102); - /* (103) fenced_4 ::= LINE_FENCE_BACKTICK_4 */ yytestcase(yyruleno==103); - /* (104) fenced_4 ::= LINE_FENCE_BACKTICK_START_4 */ yytestcase(yyruleno==104); - /* (105) fenced_block ::= fenced_5 */ yytestcase(yyruleno==105); - /* (106) fenced_5 ::= LINE_FENCE_BACKTICK_5 */ yytestcase(yyruleno==106); - /* (107) fenced_5 ::= LINE_FENCE_BACKTICK_START_5 */ yytestcase(yyruleno==107); - /* (108) fenced_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==108); - /* (109) fenced_line ::= LINE_EMPTY */ yytestcase(yyruleno==109); - /* (110) fenced_line ::= LINE_SETEXT_1 */ yytestcase(yyruleno==110); - /* (111) fenced_line ::= LINE_SETEXT_2 */ yytestcase(yyruleno==111); - /* (112) html_block ::= LINE_HTML */ yytestcase(yyruleno==112); - /* (113) html_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==113); - /* (114) html_line ::= LINE_HTML */ yytestcase(yyruleno==114); - /* (115) indented_code ::= indented_line (OPTIMIZED OUT) */ assert(yyruleno!=115); - /* (116) list_bullet ::= item_bullet (OPTIMIZED OUT) */ assert(yyruleno!=116); - /* (117) list_enum ::= item_enum (OPTIMIZED OUT) */ assert(yyruleno!=117); - /* (118) meta_block ::= LINE_META */ yytestcase(yyruleno==118); - /* (119) meta_line ::= LINE_META */ yytestcase(yyruleno==119); - /* (120) meta_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==120); - /* (121) para ::= LINE_PLAIN */ yytestcase(yyruleno==121); - /* (122) table ::= table_header */ yytestcase(yyruleno==122); - /* (123) header_rows ::= LINE_TABLE */ yytestcase(yyruleno==123); - /* (124) table_body ::= table_section (OPTIMIZED OUT) */ assert(yyruleno!=124); - /* (125) all_rows ::= row (OPTIMIZED OUT) */ assert(yyruleno!=125); - /* (126) row ::= header_rows */ yytestcase(yyruleno==126); - /* (127) row ::= LINE_TABLE_SEPARATOR */ yytestcase(yyruleno==127); - /* (128) para ::= defs */ yytestcase(yyruleno==128); + /* (83) chunk ::= chunk_line (OPTIMIZED OUT) */ assert(yyruleno!=83); + /* (84) chunk_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==84); + /* (85) nested_chunks ::= nested_chunk (OPTIMIZED OUT) */ assert(yyruleno!=85); + /* (86) nested_chunk ::= empty */ yytestcase(yyruleno==86); + /* (87) indented_line ::= LINE_INDENTED_TAB */ yytestcase(yyruleno==87); + /* (88) indented_line ::= LINE_INDENTED_SPACE */ yytestcase(yyruleno==88); + /* (89) opt_ext_chunk ::= chunk */ yytestcase(yyruleno==89); + /* (90) tail ::= opt_ext_chunk (OPTIMIZED OUT) */ assert(yyruleno!=90); + /* (91) tail ::= nested_chunks */ yytestcase(yyruleno==91); + /* (92) blockquote ::= LINE_BLOCKQUOTE */ yytestcase(yyruleno==92); + /* (93) quote_line ::= LINE_BLOCKQUOTE */ yytestcase(yyruleno==93); + /* (94) quote_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==94); + /* (95) def_citation ::= LINE_DEF_CITATION */ yytestcase(yyruleno==95); + /* (96) def_footnote ::= LINE_DEF_FOOTNOTE */ yytestcase(yyruleno==96); + /* (97) def_link ::= LINE_DEF_LINK */ yytestcase(yyruleno==97); + /* (98) def_abbreviation ::= LINE_DEF_ABBREVIATION */ yytestcase(yyruleno==98); + /* (99) defs ::= def (OPTIMIZED OUT) */ assert(yyruleno!=99); + /* (100) empty ::= LINE_EMPTY */ yytestcase(yyruleno==100); + /* (101) fenced_block ::= fenced_3 */ yytestcase(yyruleno==101); + /* (102) fenced_3 ::= LINE_FENCE_BACKTICK_3 */ yytestcase(yyruleno==102); + /* (103) fenced_3 ::= LINE_FENCE_BACKTICK_START_3 */ yytestcase(yyruleno==103); + /* (104) fenced_block ::= fenced_4 */ yytestcase(yyruleno==104); + /* (105) fenced_4 ::= LINE_FENCE_BACKTICK_4 */ yytestcase(yyruleno==105); + /* (106) fenced_4 ::= LINE_FENCE_BACKTICK_START_4 */ yytestcase(yyruleno==106); + /* (107) fenced_block ::= fenced_5 */ yytestcase(yyruleno==107); + /* (108) fenced_5 ::= LINE_FENCE_BACKTICK_5 */ yytestcase(yyruleno==108); + /* (109) fenced_5 ::= LINE_FENCE_BACKTICK_START_5 */ yytestcase(yyruleno==109); + /* (110) fenced_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==110); + /* (111) fenced_line ::= LINE_EMPTY */ yytestcase(yyruleno==111); + /* (112) fenced_line ::= LINE_SETEXT_1 */ yytestcase(yyruleno==112); + /* (113) fenced_line ::= LINE_SETEXT_2 */ yytestcase(yyruleno==113); + /* (114) html_block ::= LINE_HTML */ yytestcase(yyruleno==114); + /* (115) html_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==115); + /* (116) html_line ::= LINE_HTML */ yytestcase(yyruleno==116); + /* (117) indented_code ::= indented_line (OPTIMIZED OUT) */ assert(yyruleno!=117); + /* (118) list_bullet ::= item_bullet (OPTIMIZED OUT) */ assert(yyruleno!=118); + /* (119) list_enum ::= item_enum (OPTIMIZED OUT) */ assert(yyruleno!=119); + /* (120) meta_block ::= LINE_META */ yytestcase(yyruleno==120); + /* (121) meta_line ::= LINE_META */ yytestcase(yyruleno==121); + /* (122) meta_line ::= LINE_CONTINUATION */ yytestcase(yyruleno==122); + /* (123) para ::= LINE_PLAIN */ yytestcase(yyruleno==123); + /* (124) table ::= table_header */ yytestcase(yyruleno==124); + /* (125) header_rows ::= LINE_TABLE */ yytestcase(yyruleno==125); + /* (126) table_body ::= table_section (OPTIMIZED OUT) */ assert(yyruleno!=126); + /* (127) all_rows ::= row (OPTIMIZED OUT) */ assert(yyruleno!=127); + /* (128) row ::= header_rows */ yytestcase(yyruleno==128); + /* (129) row ::= LINE_TABLE_SEPARATOR */ yytestcase(yyruleno==129); + /* (130) para ::= defs */ yytestcase(yyruleno==130); break; /********** End reduce actions ************************************************/ }; diff --git a/Sources/libMultiMarkdown/parser.h b/Sources/libMultiMarkdown/parser.h index 3d6d5e0..8ad7feb 100644 --- a/Sources/libMultiMarkdown/parser.h +++ b/Sources/libMultiMarkdown/parser.h @@ -23,12 +23,13 @@ #define LINE_FENCE_BACKTICK 23 #define LINE_FENCE_BACKTICK_START 24 #define LINE_TOC 25 -#define LINE_DEFINITION 26 -#define LINE_EMPTY 27 -#define LINE_FENCE_BACKTICK_3 28 -#define LINE_FENCE_BACKTICK_4 29 -#define LINE_FENCE_BACKTICK_5 30 -#define LINE_FENCE_BACKTICK_START_3 31 -#define LINE_FENCE_BACKTICK_START_4 32 -#define LINE_FENCE_BACKTICK_START_5 33 -#define LINE_META 34 +#define LINE_DEF_ABBREVIATION 26 +#define LINE_DEFINITION 27 +#define LINE_EMPTY 28 +#define LINE_FENCE_BACKTICK_3 29 +#define LINE_FENCE_BACKTICK_4 30 +#define LINE_FENCE_BACKTICK_5 31 +#define LINE_FENCE_BACKTICK_START_3 32 +#define LINE_FENCE_BACKTICK_START_4 33 +#define LINE_FENCE_BACKTICK_START_5 34 +#define LINE_META 35 diff --git a/Sources/libMultiMarkdown/parser.out b/Sources/libMultiMarkdown/parser.out index 23e970c..1d9a8a0 100644 --- a/Sources/libMultiMarkdown/parser.out +++ b/Sources/libMultiMarkdown/parser.out @@ -11,6 +11,7 @@ State 0: block ::= * LINE_HR block ::= * LINE_TOC block ::= * blockquote + block ::= * def_abbreviation block ::= * def_citation block ::= * def_footnote block ::= * def_link @@ -36,6 +37,7 @@ State 0: def_footnote ::= * LINE_DEF_FOOTNOTE def_link ::= * LINE_DEF_LINK chunk def_link ::= * LINE_DEF_LINK + def_abbreviation ::= * LINE_DEF_ABBREVIATION definition_block ::= * para defs defs ::= * defs def defs ::= * def @@ -104,52 +106,54 @@ State 0: LINE_HR shift-reduce 9 block ::= LINE_HR LINE_PLAIN shift 15 - LINE_TABLE_SEPARATOR shift-reduce 127 row ::= LINE_TABLE_SEPARATOR - LINE_INDENTED_TAB shift-reduce 86 indented_line ::= LINE_INDENTED_TAB - LINE_INDENTED_SPACE shift-reduce 87 indented_line ::= LINE_INDENTED_SPACE - LINE_TABLE shift-reduce 123 header_rows ::= LINE_TABLE - LINE_HTML shift-reduce 112 html_block ::= LINE_HTML + LINE_TABLE_SEPARATOR shift-reduce 129 row ::= LINE_TABLE_SEPARATOR + LINE_INDENTED_TAB shift-reduce 87 indented_line ::= LINE_INDENTED_TAB + LINE_INDENTED_SPACE shift-reduce 88 indented_line ::= LINE_INDENTED_SPACE + LINE_TABLE shift-reduce 125 header_rows ::= LINE_TABLE + LINE_HTML shift-reduce 114 html_block ::= LINE_HTML LINE_ATX_1 shift-reduce 3 block ::= LINE_ATX_1 LINE_ATX_2 shift-reduce 4 block ::= LINE_ATX_2 LINE_ATX_3 shift-reduce 5 block ::= LINE_ATX_3 LINE_ATX_4 shift-reduce 6 block ::= LINE_ATX_4 LINE_ATX_5 shift-reduce 7 block ::= LINE_ATX_5 LINE_ATX_6 shift-reduce 8 block ::= LINE_ATX_6 - LINE_BLOCKQUOTE shift-reduce 91 blockquote ::= LINE_BLOCKQUOTE + LINE_BLOCKQUOTE shift-reduce 92 blockquote ::= LINE_BLOCKQUOTE LINE_LIST_BULLETED shift 6 LINE_LIST_ENUMERATED shift 5 LINE_DEF_CITATION shift 3 LINE_DEF_FOOTNOTE shift 2 LINE_DEF_LINK shift 16 LINE_TOC shift-reduce 10 block ::= LINE_TOC + LINE_DEF_ABBREVIATION shift-reduce 98 def_abbreviation ::= LINE_DEF_ABBREVIATION LINE_DEFINITION shift 4 - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_FENCE_BACKTICK_3 shift-reduce 100 fenced_3 ::= LINE_FENCE_BACKTICK_3 - LINE_FENCE_BACKTICK_4 shift-reduce 103 fenced_4 ::= LINE_FENCE_BACKTICK_4 - LINE_FENCE_BACKTICK_5 shift-reduce 106 fenced_5 ::= LINE_FENCE_BACKTICK_5 - LINE_FENCE_BACKTICK_START_3 shift-reduce 101 fenced_3 ::= LINE_FENCE_BACKTICK_START_3 - LINE_FENCE_BACKTICK_START_4 shift-reduce 104 fenced_4 ::= LINE_FENCE_BACKTICK_START_4 - LINE_FENCE_BACKTICK_START_5 shift-reduce 107 fenced_5 ::= LINE_FENCE_BACKTICK_START_5 - LINE_META shift-reduce 118 meta_block ::= LINE_META + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_FENCE_BACKTICK_3 shift-reduce 102 fenced_3 ::= LINE_FENCE_BACKTICK_3 + LINE_FENCE_BACKTICK_4 shift-reduce 105 fenced_4 ::= LINE_FENCE_BACKTICK_4 + LINE_FENCE_BACKTICK_5 shift-reduce 108 fenced_5 ::= LINE_FENCE_BACKTICK_5 + LINE_FENCE_BACKTICK_START_3 shift-reduce 103 fenced_3 ::= LINE_FENCE_BACKTICK_START_3 + LINE_FENCE_BACKTICK_START_4 shift-reduce 106 fenced_4 ::= LINE_FENCE_BACKTICK_START_4 + LINE_FENCE_BACKTICK_START_5 shift-reduce 109 fenced_5 ::= LINE_FENCE_BACKTICK_START_5 + LINE_META shift-reduce 120 meta_block ::= LINE_META doc accept blocks shift 1 block shift-reduce 2 blocks ::= block blockquote shift 30 - def_citation shift-reduce 12 block ::= def_citation - def_footnote shift-reduce 13 block ::= def_footnote - def_link shift-reduce 14 block ::= def_link - definition_block shift-reduce 15 block ::= definition_block + def_abbreviation shift-reduce 12 block ::= def_abbreviation + def_citation shift-reduce 13 block ::= def_citation + def_footnote shift-reduce 14 block ::= def_footnote + def_link shift-reduce 15 block ::= def_link + definition_block shift-reduce 16 block ::= definition_block empty shift 40 - fenced_block shift-reduce 17 block ::= fenced_block + fenced_block shift-reduce 18 block ::= fenced_block html_block shift 29 indented_code shift 27 list_bullet shift 37 list_enum shift 35 meta_block shift 28 para shift 13 - setext_1 shift-reduce 24 block ::= setext_1 - setext_2 shift-reduce 25 block ::= setext_2 - table shift-reduce 26 block ::= table + setext_1 shift-reduce 25 block ::= setext_1 + setext_2 shift-reduce 26 block ::= setext_2 + table shift-reduce 27 block ::= table indented_line shift 27 /* because indented_line==indented_code */ defs shift 32 def shift 32 /* because def==defs */ @@ -175,6 +179,7 @@ State 1: block ::= * LINE_HR block ::= * LINE_TOC block ::= * blockquote + block ::= * def_abbreviation block ::= * def_citation block ::= * def_footnote block ::= * def_link @@ -200,6 +205,7 @@ State 1: def_footnote ::= * LINE_DEF_FOOTNOTE def_link ::= * LINE_DEF_LINK chunk def_link ::= * LINE_DEF_LINK + def_abbreviation ::= * LINE_DEF_ABBREVIATION definition_block ::= * para defs defs ::= * defs def defs ::= * def @@ -269,50 +275,52 @@ State 1: $ reduce 0 doc ::= blocks LINE_HR shift-reduce 9 block ::= LINE_HR LINE_PLAIN shift 15 - LINE_TABLE_SEPARATOR shift-reduce 127 row ::= LINE_TABLE_SEPARATOR - LINE_INDENTED_TAB shift-reduce 86 indented_line ::= LINE_INDENTED_TAB - LINE_INDENTED_SPACE shift-reduce 87 indented_line ::= LINE_INDENTED_SPACE - LINE_TABLE shift-reduce 123 header_rows ::= LINE_TABLE - LINE_HTML shift-reduce 112 html_block ::= LINE_HTML + LINE_TABLE_SEPARATOR shift-reduce 129 row ::= LINE_TABLE_SEPARATOR + LINE_INDENTED_TAB shift-reduce 87 indented_line ::= LINE_INDENTED_TAB + LINE_INDENTED_SPACE shift-reduce 88 indented_line ::= LINE_INDENTED_SPACE + LINE_TABLE shift-reduce 125 header_rows ::= LINE_TABLE + LINE_HTML shift-reduce 114 html_block ::= LINE_HTML LINE_ATX_1 shift-reduce 3 block ::= LINE_ATX_1 LINE_ATX_2 shift-reduce 4 block ::= LINE_ATX_2 LINE_ATX_3 shift-reduce 5 block ::= LINE_ATX_3 LINE_ATX_4 shift-reduce 6 block ::= LINE_ATX_4 LINE_ATX_5 shift-reduce 7 block ::= LINE_ATX_5 LINE_ATX_6 shift-reduce 8 block ::= LINE_ATX_6 - LINE_BLOCKQUOTE shift-reduce 91 blockquote ::= LINE_BLOCKQUOTE + LINE_BLOCKQUOTE shift-reduce 92 blockquote ::= LINE_BLOCKQUOTE LINE_LIST_BULLETED shift 6 LINE_LIST_ENUMERATED shift 5 LINE_DEF_CITATION shift 3 LINE_DEF_FOOTNOTE shift 2 LINE_DEF_LINK shift 16 LINE_TOC shift-reduce 10 block ::= LINE_TOC + LINE_DEF_ABBREVIATION shift-reduce 98 def_abbreviation ::= LINE_DEF_ABBREVIATION LINE_DEFINITION shift 4 - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_FENCE_BACKTICK_3 shift-reduce 100 fenced_3 ::= LINE_FENCE_BACKTICK_3 - LINE_FENCE_BACKTICK_4 shift-reduce 103 fenced_4 ::= LINE_FENCE_BACKTICK_4 - LINE_FENCE_BACKTICK_5 shift-reduce 106 fenced_5 ::= LINE_FENCE_BACKTICK_5 - LINE_FENCE_BACKTICK_START_3 shift-reduce 101 fenced_3 ::= LINE_FENCE_BACKTICK_START_3 - LINE_FENCE_BACKTICK_START_4 shift-reduce 104 fenced_4 ::= LINE_FENCE_BACKTICK_START_4 - LINE_FENCE_BACKTICK_START_5 shift-reduce 107 fenced_5 ::= LINE_FENCE_BACKTICK_START_5 - LINE_META shift-reduce 118 meta_block ::= LINE_META + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_FENCE_BACKTICK_3 shift-reduce 102 fenced_3 ::= LINE_FENCE_BACKTICK_3 + LINE_FENCE_BACKTICK_4 shift-reduce 105 fenced_4 ::= LINE_FENCE_BACKTICK_4 + LINE_FENCE_BACKTICK_5 shift-reduce 108 fenced_5 ::= LINE_FENCE_BACKTICK_5 + LINE_FENCE_BACKTICK_START_3 shift-reduce 103 fenced_3 ::= LINE_FENCE_BACKTICK_START_3 + LINE_FENCE_BACKTICK_START_4 shift-reduce 106 fenced_4 ::= LINE_FENCE_BACKTICK_START_4 + LINE_FENCE_BACKTICK_START_5 shift-reduce 109 fenced_5 ::= LINE_FENCE_BACKTICK_START_5 + LINE_META shift-reduce 120 meta_block ::= LINE_META block shift-reduce 1 blocks ::= blocks block blockquote shift 30 - def_citation shift-reduce 12 block ::= def_citation - def_footnote shift-reduce 13 block ::= def_footnote - def_link shift-reduce 14 block ::= def_link - definition_block shift-reduce 15 block ::= definition_block + def_abbreviation shift-reduce 12 block ::= def_abbreviation + def_citation shift-reduce 13 block ::= def_citation + def_footnote shift-reduce 14 block ::= def_footnote + def_link shift-reduce 15 block ::= def_link + definition_block shift-reduce 16 block ::= definition_block empty shift 40 - fenced_block shift-reduce 17 block ::= fenced_block + fenced_block shift-reduce 18 block ::= fenced_block html_block shift 29 indented_code shift 27 list_bullet shift 37 list_enum shift 35 meta_block shift 28 para shift 13 - setext_1 shift-reduce 24 block ::= setext_1 - setext_2 shift-reduce 25 block ::= setext_2 - table shift-reduce 26 block ::= table + setext_1 shift-reduce 25 block ::= setext_1 + setext_2 shift-reduce 26 block ::= setext_2 + table shift-reduce 27 block ::= table indented_line shift 27 /* because indented_line==indented_code */ defs shift 32 def shift 32 /* because def==defs */ @@ -340,21 +348,21 @@ State 2: tail ::= * opt_ext_chunk tail ::= * nested_chunks def_footnote ::= LINE_DEF_FOOTNOTE * tail - (95) def_footnote ::= LINE_DEF_FOOTNOTE * + (96) def_footnote ::= LINE_DEF_FOOTNOTE * empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 95 ** Parsing conflict ** + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 96 ** Parsing conflict ** empty shift 26 chunk shift 9 chunk_line shift 9 /* because chunk_line==chunk */ nested_chunks shift 17 nested_chunk shift 17 /* because nested_chunk==nested_chunks */ - opt_ext_chunk shift-reduce 35 def_footnote ::= LINE_DEF_FOOTNOTE tail /* because opt_ext_chunk==tail */ - tail shift-reduce 35 def_footnote ::= LINE_DEF_FOOTNOTE tail - {default} reduce 95 def_footnote ::= LINE_DEF_FOOTNOTE + opt_ext_chunk shift-reduce 36 def_footnote ::= LINE_DEF_FOOTNOTE tail /* because opt_ext_chunk==tail */ + tail shift-reduce 36 def_footnote ::= LINE_DEF_FOOTNOTE tail + {default} reduce 96 def_footnote ::= LINE_DEF_FOOTNOTE State 3: chunk ::= * chunk chunk_line @@ -370,21 +378,21 @@ State 3: tail ::= * opt_ext_chunk tail ::= * nested_chunks def_citation ::= LINE_DEF_CITATION * tail - (94) def_citation ::= LINE_DEF_CITATION * + (95) def_citation ::= LINE_DEF_CITATION * empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 94 ** Parsing conflict ** + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 95 ** Parsing conflict ** empty shift 26 chunk shift 9 chunk_line shift 9 /* because chunk_line==chunk */ nested_chunks shift 17 nested_chunk shift 17 /* because nested_chunk==nested_chunks */ - opt_ext_chunk shift-reduce 34 def_citation ::= LINE_DEF_CITATION tail /* because opt_ext_chunk==tail */ - tail shift-reduce 34 def_citation ::= LINE_DEF_CITATION tail - {default} reduce 94 def_citation ::= LINE_DEF_CITATION + opt_ext_chunk shift-reduce 35 def_citation ::= LINE_DEF_CITATION tail /* because opt_ext_chunk==tail */ + tail shift-reduce 35 def_citation ::= LINE_DEF_CITATION tail + {default} reduce 95 def_citation ::= LINE_DEF_CITATION State 4: chunk ::= * chunk chunk_line @@ -400,21 +408,21 @@ State 4: tail ::= * opt_ext_chunk tail ::= * nested_chunks def ::= LINE_DEFINITION * tail - (40) def ::= LINE_DEFINITION * + (41) def ::= LINE_DEFINITION * empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 40 ** Parsing conflict ** + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 41 ** Parsing conflict ** empty shift 26 chunk shift 9 chunk_line shift 9 /* because chunk_line==chunk */ nested_chunks shift 17 nested_chunk shift 17 /* because nested_chunk==nested_chunks */ - opt_ext_chunk shift-reduce 39 def ::= LINE_DEFINITION tail /* because opt_ext_chunk==tail */ - tail shift-reduce 39 def ::= LINE_DEFINITION tail - {default} reduce 40 def ::= LINE_DEFINITION + opt_ext_chunk shift-reduce 40 def ::= LINE_DEFINITION tail /* because opt_ext_chunk==tail */ + tail shift-reduce 40 def ::= LINE_DEFINITION tail + {default} reduce 41 def ::= LINE_DEFINITION State 5: chunk ::= * chunk chunk_line @@ -431,18 +439,18 @@ State 5: item_enum ::= LINE_LIST_ENUMERATED * ext_chunk item_enum ::= LINE_LIST_ENUMERATED * chunk item_enum ::= LINE_LIST_ENUMERATED * nested_chunks - (69) item_enum ::= LINE_LIST_ENUMERATED * + (70) item_enum ::= LINE_LIST_ENUMERATED * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 69 ** Parsing conflict ** + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 70 ** Parsing conflict ** empty shift 26 chunk shift 10 chunk_line shift 10 /* because chunk_line==chunk */ nested_chunks shift 19 nested_chunk shift 19 /* because nested_chunk==nested_chunks */ - ext_chunk shift-reduce 66 item_enum ::= LINE_LIST_ENUMERATED ext_chunk - {default} reduce 69 item_enum ::= LINE_LIST_ENUMERATED + ext_chunk shift-reduce 67 item_enum ::= LINE_LIST_ENUMERATED ext_chunk + {default} reduce 70 item_enum ::= LINE_LIST_ENUMERATED State 6: chunk ::= * chunk chunk_line @@ -459,22 +467,22 @@ State 6: item_bullet ::= LINE_LIST_BULLETED * ext_chunk item_bullet ::= LINE_LIST_BULLETED * chunk item_bullet ::= LINE_LIST_BULLETED * nested_chunks - (64) item_bullet ::= LINE_LIST_BULLETED * + (65) item_bullet ::= LINE_LIST_BULLETED * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 64 ** Parsing conflict ** + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 65 ** Parsing conflict ** empty shift 26 chunk shift 11 chunk_line shift 11 /* because chunk_line==chunk */ nested_chunks shift 20 nested_chunk shift 20 /* because nested_chunk==nested_chunks */ - ext_chunk shift-reduce 61 item_bullet ::= LINE_LIST_BULLETED ext_chunk - {default} reduce 64 item_bullet ::= LINE_LIST_BULLETED + ext_chunk shift-reduce 62 item_bullet ::= LINE_LIST_BULLETED ext_chunk + {default} reduce 65 item_bullet ::= LINE_LIST_BULLETED State 7: table ::= table_header * table_body - (122) table ::= table_header * + (124) table ::= table_header * header_rows ::= * header_rows LINE_TABLE header_rows ::= * LINE_TABLE table_body ::= * table_body table_section @@ -486,19 +494,19 @@ State 7: row ::= * header_rows row ::= * LINE_TABLE_SEPARATOR - LINE_TABLE_SEPARATOR shift-reduce 127 row ::= LINE_TABLE_SEPARATOR - LINE_TABLE_SEPARATOR reduce 122 ** Parsing conflict ** - LINE_TABLE shift-reduce 123 header_rows ::= LINE_TABLE - LINE_TABLE reduce 122 ** Parsing conflict ** + LINE_TABLE_SEPARATOR shift-reduce 129 row ::= LINE_TABLE_SEPARATOR + LINE_TABLE_SEPARATOR reduce 124 ** Parsing conflict ** + LINE_TABLE shift-reduce 125 header_rows ::= LINE_TABLE + LINE_TABLE reduce 124 ** Parsing conflict ** table_body shift 8 header_rows shift 39 table_section shift 8 /* because table_section==table_body */ all_rows shift 12 row shift 12 /* because row==all_rows */ - {default} reduce 122 table ::= table_header + {default} reduce 124 table ::= table_header State 8: - (74) table ::= table_header table_body * + (75) table ::= table_header table_body * header_rows ::= * header_rows LINE_TABLE header_rows ::= * LINE_TABLE table_body ::= table_body * table_section @@ -509,15 +517,15 @@ State 8: row ::= * header_rows row ::= * LINE_TABLE_SEPARATOR - LINE_TABLE_SEPARATOR shift-reduce 127 row ::= LINE_TABLE_SEPARATOR - LINE_TABLE_SEPARATOR reduce 74 ** Parsing conflict ** - LINE_TABLE shift-reduce 123 header_rows ::= LINE_TABLE - LINE_TABLE reduce 74 ** Parsing conflict ** + LINE_TABLE_SEPARATOR shift-reduce 129 row ::= LINE_TABLE_SEPARATOR + LINE_TABLE_SEPARATOR reduce 75 ** Parsing conflict ** + LINE_TABLE shift-reduce 125 header_rows ::= LINE_TABLE + LINE_TABLE reduce 75 ** Parsing conflict ** header_rows shift 39 - table_section shift-reduce 77 table_body ::= table_body table_section + table_section shift-reduce 78 table_body ::= table_body table_section all_rows shift 12 row shift 12 /* because row==all_rows */ - {default} reduce 74 table ::= table_header table_body + {default} reduce 75 table ::= table_header table_body State 9: chunk ::= chunk * chunk_line @@ -528,18 +536,18 @@ State 9: nested_chunk ::= * empty indented_line nested_chunk ::= * empty opt_ext_chunk ::= chunk * nested_chunks - (88) opt_ext_chunk ::= chunk * + (89) opt_ext_chunk ::= chunk * empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 88 ** Parsing conflict ** + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 89 ** Parsing conflict ** empty shift 26 - chunk_line shift-reduce 27 chunk ::= chunk chunk_line + chunk_line shift-reduce 28 chunk ::= chunk chunk_line nested_chunks shift 18 nested_chunk shift 18 /* because nested_chunk==nested_chunks */ - {default} reduce 88 opt_ext_chunk ::= chunk + {default} reduce 89 opt_ext_chunk ::= chunk State 10: chunk ::= chunk * chunk_line @@ -552,16 +560,16 @@ State 10: ext_chunk ::= chunk * nested_chunks empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - (67) item_enum ::= LINE_LIST_ENUMERATED chunk * + (68) item_enum ::= LINE_LIST_ENUMERATED chunk * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 67 ** Parsing conflict ** + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 68 ** Parsing conflict ** empty shift 26 - chunk_line shift-reduce 27 chunk ::= chunk chunk_line + chunk_line shift-reduce 28 chunk ::= chunk chunk_line nested_chunks shift 22 nested_chunk shift 22 /* because nested_chunk==nested_chunks */ - {default} reduce 67 item_enum ::= LINE_LIST_ENUMERATED chunk + {default} reduce 68 item_enum ::= LINE_LIST_ENUMERATED chunk State 11: chunk ::= chunk * chunk_line @@ -574,38 +582,38 @@ State 11: ext_chunk ::= chunk * nested_chunks empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - (62) item_bullet ::= LINE_LIST_BULLETED chunk * + (63) item_bullet ::= LINE_LIST_BULLETED chunk * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 62 ** Parsing conflict ** + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 63 ** Parsing conflict ** empty shift 26 - chunk_line shift-reduce 27 chunk ::= chunk chunk_line + chunk_line shift-reduce 28 chunk ::= chunk chunk_line nested_chunks shift 22 nested_chunk shift 22 /* because nested_chunk==nested_chunks */ - {default} reduce 62 item_bullet ::= LINE_LIST_BULLETED chunk + {default} reduce 63 item_bullet ::= LINE_LIST_BULLETED chunk State 12: header_rows ::= * header_rows LINE_TABLE header_rows ::= * LINE_TABLE table_section ::= all_rows * LINE_EMPTY - (79) table_section ::= all_rows * + (80) table_section ::= all_rows * all_rows ::= all_rows * row row ::= * header_rows row ::= * LINE_TABLE_SEPARATOR - LINE_TABLE_SEPARATOR shift-reduce 127 row ::= LINE_TABLE_SEPARATOR - LINE_TABLE_SEPARATOR reduce 79 ** Parsing conflict ** - LINE_TABLE shift-reduce 123 header_rows ::= LINE_TABLE - LINE_TABLE reduce 79 ** Parsing conflict ** - LINE_EMPTY shift-reduce 78 table_section ::= all_rows LINE_EMPTY - LINE_EMPTY reduce 79 ** Parsing conflict ** + LINE_TABLE_SEPARATOR shift-reduce 129 row ::= LINE_TABLE_SEPARATOR + LINE_TABLE_SEPARATOR reduce 80 ** Parsing conflict ** + LINE_TABLE shift-reduce 125 header_rows ::= LINE_TABLE + LINE_TABLE reduce 80 ** Parsing conflict ** + LINE_EMPTY shift-reduce 79 table_section ::= all_rows LINE_EMPTY + LINE_EMPTY reduce 80 ** Parsing conflict ** header_rows shift 39 - row shift-reduce 80 all_rows ::= all_rows row - {default} reduce 79 table_section ::= all_rows + row shift-reduce 81 all_rows ::= all_rows row + {default} reduce 80 table_section ::= all_rows State 13: - (23) block ::= para * + (24) block ::= para * definition_block ::= para * defs defs ::= * defs def defs ::= * def @@ -614,13 +622,13 @@ State 13: setext_1 ::= para * LINE_SETEXT_1 setext_2 ::= para * LINE_SETEXT_2 - LINE_SETEXT_1 shift-reduce 72 setext_1 ::= para LINE_SETEXT_1 - LINE_SETEXT_2 shift-reduce 73 setext_2 ::= para LINE_SETEXT_2 + LINE_SETEXT_1 shift-reduce 73 setext_1 ::= para LINE_SETEXT_1 + LINE_SETEXT_2 shift-reduce 74 setext_2 ::= para LINE_SETEXT_2 LINE_DEFINITION shift 4 - LINE_DEFINITION reduce 23 ** Parsing conflict ** + LINE_DEFINITION reduce 24 ** Parsing conflict ** defs shift 34 def shift 34 /* because def==defs */ - {default} reduce 23 block ::= para + {default} reduce 24 block ::= para State 14: header_rows ::= * header_rows LINE_TABLE @@ -628,69 +636,69 @@ State 14: all_rows ::= all_rows * row row ::= * header_rows row ::= * LINE_TABLE_SEPARATOR - (81) para ::= all_rows * + (82) para ::= all_rows * - LINE_TABLE_SEPARATOR shift-reduce 127 row ::= LINE_TABLE_SEPARATOR - LINE_TABLE_SEPARATOR reduce 81 ** Parsing conflict ** - LINE_TABLE shift-reduce 123 header_rows ::= LINE_TABLE - LINE_TABLE reduce 81 ** Parsing conflict ** + LINE_TABLE_SEPARATOR shift-reduce 129 row ::= LINE_TABLE_SEPARATOR + LINE_TABLE_SEPARATOR reduce 82 ** Parsing conflict ** + LINE_TABLE shift-reduce 125 header_rows ::= LINE_TABLE + LINE_TABLE reduce 82 ** Parsing conflict ** header_rows shift 39 - row shift-reduce 80 all_rows ::= all_rows row - {default} reduce 81 para ::= all_rows + row shift-reduce 81 all_rows ::= all_rows row + {default} reduce 82 para ::= all_rows State 15: chunk ::= * chunk chunk_line chunk ::= * chunk_line chunk_line ::= * LINE_CONTINUATION para ::= LINE_PLAIN * chunk - (121) para ::= LINE_PLAIN * + (123) para ::= LINE_PLAIN * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION chunk shift 31 chunk_line shift 31 /* because chunk_line==chunk */ - {default} reduce 121 para ::= LINE_PLAIN + {default} reduce 123 para ::= LINE_PLAIN State 16: chunk ::= * chunk chunk_line chunk ::= * chunk_line chunk_line ::= * LINE_CONTINUATION def_link ::= LINE_DEF_LINK * chunk - (96) def_link ::= LINE_DEF_LINK * + (97) def_link ::= LINE_DEF_LINK * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION chunk shift 33 chunk_line shift 33 /* because chunk_line==chunk */ - {default} reduce 96 def_link ::= LINE_DEF_LINK + {default} reduce 97 def_link ::= LINE_DEF_LINK State 17: nested_chunks ::= nested_chunks * nested_chunk nested_chunk ::= * empty indented_line chunk nested_chunk ::= * empty indented_line nested_chunk ::= * empty - (90) tail ::= nested_chunks * + (91) tail ::= nested_chunks * empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 90 ** Parsing conflict ** + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 91 ** Parsing conflict ** empty shift 26 - nested_chunk shift-reduce 28 nested_chunks ::= nested_chunks nested_chunk - {default} reduce 90 tail ::= nested_chunks + nested_chunk shift-reduce 29 nested_chunks ::= nested_chunks nested_chunk + {default} reduce 91 tail ::= nested_chunks State 18: nested_chunks ::= nested_chunks * nested_chunk nested_chunk ::= * empty indented_line chunk nested_chunk ::= * empty indented_line nested_chunk ::= * empty - (32) opt_ext_chunk ::= chunk nested_chunks * + (33) opt_ext_chunk ::= chunk nested_chunks * empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 32 ** Parsing conflict ** + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 33 ** Parsing conflict ** empty shift 26 - nested_chunk shift-reduce 28 nested_chunks ::= nested_chunks nested_chunk - {default} reduce 32 opt_ext_chunk ::= chunk nested_chunks + nested_chunk shift-reduce 29 nested_chunks ::= nested_chunks nested_chunk + {default} reduce 33 opt_ext_chunk ::= chunk nested_chunks State 19: nested_chunks ::= nested_chunks * nested_chunk @@ -699,13 +707,13 @@ State 19: nested_chunk ::= * empty empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - (68) item_enum ::= LINE_LIST_ENUMERATED nested_chunks * + (69) item_enum ::= LINE_LIST_ENUMERATED nested_chunks * - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 68 ** Parsing conflict ** + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 69 ** Parsing conflict ** empty shift 26 - nested_chunk shift-reduce 28 nested_chunks ::= nested_chunks nested_chunk - {default} reduce 68 item_enum ::= LINE_LIST_ENUMERATED nested_chunks + nested_chunk shift-reduce 29 nested_chunks ::= nested_chunks nested_chunk + {default} reduce 69 item_enum ::= LINE_LIST_ENUMERATED nested_chunks State 20: nested_chunks ::= nested_chunks * nested_chunk @@ -714,44 +722,44 @@ State 20: nested_chunk ::= * empty empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - (63) item_bullet ::= LINE_LIST_BULLETED nested_chunks * + (64) item_bullet ::= LINE_LIST_BULLETED nested_chunks * - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 63 ** Parsing conflict ** + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 64 ** Parsing conflict ** empty shift 26 - nested_chunk shift-reduce 28 nested_chunks ::= nested_chunks nested_chunk - {default} reduce 63 item_bullet ::= LINE_LIST_BULLETED nested_chunks + nested_chunk shift-reduce 29 nested_chunks ::= nested_chunks nested_chunk + {default} reduce 64 item_bullet ::= LINE_LIST_BULLETED nested_chunks State 21: chunk ::= * chunk chunk_line chunk ::= * chunk_line chunk_line ::= * LINE_CONTINUATION nested_chunk ::= empty indented_line * chunk - (30) nested_chunk ::= empty indented_line * + (31) nested_chunk ::= empty indented_line * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION chunk shift 36 chunk_line shift 36 /* because chunk_line==chunk */ - {default} reduce 30 nested_chunk ::= empty indented_line + {default} reduce 31 nested_chunk ::= empty indented_line State 22: nested_chunks ::= nested_chunks * nested_chunk nested_chunk ::= * empty indented_line chunk nested_chunk ::= * empty indented_line nested_chunk ::= * empty - (31) ext_chunk ::= chunk nested_chunks * + (32) ext_chunk ::= chunk nested_chunks * empty ::= * empty LINE_EMPTY empty ::= * LINE_EMPTY - LINE_EMPTY shift-reduce 98 empty ::= LINE_EMPTY - LINE_EMPTY reduce 31 ** Parsing conflict ** + LINE_EMPTY shift-reduce 100 empty ::= LINE_EMPTY + LINE_EMPTY reduce 32 ** Parsing conflict ** empty shift 26 - nested_chunk shift-reduce 28 nested_chunks ::= nested_chunks nested_chunk - {default} reduce 31 ext_chunk ::= chunk nested_chunks + nested_chunk shift-reduce 29 nested_chunks ::= nested_chunks nested_chunk + {default} reduce 32 ext_chunk ::= chunk nested_chunks State 23: fenced_block ::= fenced_5 * LINE_FENCE_BACKTICK_5 - (105) fenced_block ::= fenced_5 * + (107) fenced_block ::= fenced_5 * fenced_5 ::= fenced_5 * fenced_line fenced_5 ::= fenced_5 * LINE_FENCE_BACKTICK_3 fenced_5 ::= fenced_5 * LINE_FENCE_BACKTICK_START_3 @@ -762,28 +770,28 @@ State 23: fenced_line ::= * LINE_SETEXT_1 fenced_line ::= * LINE_SETEXT_2 - LINE_SETEXT_1 shift-reduce 110 fenced_line ::= LINE_SETEXT_1 - LINE_SETEXT_2 shift-reduce 111 fenced_line ::= LINE_SETEXT_2 - LINE_CONTINUATION shift-reduce 108 fenced_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 109 fenced_line ::= LINE_EMPTY - LINE_EMPTY reduce 105 ** Parsing conflict ** - LINE_FENCE_BACKTICK_3 shift-reduce 53 fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_3 - LINE_FENCE_BACKTICK_3 reduce 105 ** Parsing conflict ** - LINE_FENCE_BACKTICK_4 shift-reduce 55 fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_4 - LINE_FENCE_BACKTICK_4 reduce 105 ** Parsing conflict ** - LINE_FENCE_BACKTICK_5 shift-reduce 51 fenced_block ::= fenced_5 LINE_FENCE_BACKTICK_5 - LINE_FENCE_BACKTICK_5 reduce 105 ** Parsing conflict ** - LINE_FENCE_BACKTICK_START_3 shift-reduce 54 fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_3 - LINE_FENCE_BACKTICK_START_3 reduce 105 ** Parsing conflict ** - LINE_FENCE_BACKTICK_START_4 shift-reduce 56 fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_4 - LINE_FENCE_BACKTICK_START_4 reduce 105 ** Parsing conflict ** - fenced_line shift-reduce 52 fenced_5 ::= fenced_5 fenced_line - {default} reduce 105 fenced_block ::= fenced_5 + LINE_SETEXT_1 shift-reduce 112 fenced_line ::= LINE_SETEXT_1 + LINE_SETEXT_2 shift-reduce 113 fenced_line ::= LINE_SETEXT_2 + LINE_CONTINUATION shift-reduce 110 fenced_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 111 fenced_line ::= LINE_EMPTY + LINE_EMPTY reduce 107 ** Parsing conflict ** + LINE_FENCE_BACKTICK_3 shift-reduce 54 fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_3 + LINE_FENCE_BACKTICK_3 reduce 107 ** Parsing conflict ** + LINE_FENCE_BACKTICK_4 shift-reduce 56 fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_4 + LINE_FENCE_BACKTICK_4 reduce 107 ** Parsing conflict ** + LINE_FENCE_BACKTICK_5 shift-reduce 52 fenced_block ::= fenced_5 LINE_FENCE_BACKTICK_5 + LINE_FENCE_BACKTICK_5 reduce 107 ** Parsing conflict ** + LINE_FENCE_BACKTICK_START_3 shift-reduce 55 fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_3 + LINE_FENCE_BACKTICK_START_3 reduce 107 ** Parsing conflict ** + LINE_FENCE_BACKTICK_START_4 shift-reduce 57 fenced_5 ::= fenced_5 LINE_FENCE_BACKTICK_START_4 + LINE_FENCE_BACKTICK_START_4 reduce 107 ** Parsing conflict ** + fenced_line shift-reduce 53 fenced_5 ::= fenced_5 fenced_line + {default} reduce 107 fenced_block ::= fenced_5 State 24: fenced_block ::= fenced_4 * LINE_FENCE_BACKTICK_4 fenced_block ::= fenced_4 * LINE_FENCE_BACKTICK_5 - (102) fenced_block ::= fenced_4 * + (104) fenced_block ::= fenced_4 * fenced_4 ::= fenced_4 * fenced_line fenced_4 ::= fenced_4 * LINE_FENCE_BACKTICK_3 fenced_4 ::= fenced_4 * LINE_FENCE_BACKTICK_START_3 @@ -792,103 +800,103 @@ State 24: fenced_line ::= * LINE_SETEXT_1 fenced_line ::= * LINE_SETEXT_2 - LINE_SETEXT_1 shift-reduce 110 fenced_line ::= LINE_SETEXT_1 - LINE_SETEXT_2 shift-reduce 111 fenced_line ::= LINE_SETEXT_2 - LINE_CONTINUATION shift-reduce 108 fenced_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 109 fenced_line ::= LINE_EMPTY - LINE_EMPTY reduce 102 ** Parsing conflict ** - LINE_FENCE_BACKTICK_3 shift-reduce 49 fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_3 - LINE_FENCE_BACKTICK_3 reduce 102 ** Parsing conflict ** - LINE_FENCE_BACKTICK_4 shift-reduce 46 fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_4 - LINE_FENCE_BACKTICK_4 reduce 102 ** Parsing conflict ** - LINE_FENCE_BACKTICK_5 shift-reduce 47 fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_5 - LINE_FENCE_BACKTICK_5 reduce 102 ** Parsing conflict ** - LINE_FENCE_BACKTICK_START_3 shift-reduce 50 fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_START_3 - LINE_FENCE_BACKTICK_START_3 reduce 102 ** Parsing conflict ** - fenced_line shift-reduce 48 fenced_4 ::= fenced_4 fenced_line - {default} reduce 102 fenced_block ::= fenced_4 + LINE_SETEXT_1 shift-reduce 112 fenced_line ::= LINE_SETEXT_1 + LINE_SETEXT_2 shift-reduce 113 fenced_line ::= LINE_SETEXT_2 + LINE_CONTINUATION shift-reduce 110 fenced_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 111 fenced_line ::= LINE_EMPTY + LINE_EMPTY reduce 104 ** Parsing conflict ** + LINE_FENCE_BACKTICK_3 shift-reduce 50 fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_3 + LINE_FENCE_BACKTICK_3 reduce 104 ** Parsing conflict ** + LINE_FENCE_BACKTICK_4 shift-reduce 47 fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_4 + LINE_FENCE_BACKTICK_4 reduce 104 ** Parsing conflict ** + LINE_FENCE_BACKTICK_5 shift-reduce 48 fenced_block ::= fenced_4 LINE_FENCE_BACKTICK_5 + LINE_FENCE_BACKTICK_5 reduce 104 ** Parsing conflict ** + LINE_FENCE_BACKTICK_START_3 shift-reduce 51 fenced_4 ::= fenced_4 LINE_FENCE_BACKTICK_START_3 + LINE_FENCE_BACKTICK_START_3 reduce 104 ** Parsing conflict ** + fenced_line shift-reduce 49 fenced_4 ::= fenced_4 fenced_line + {default} reduce 104 fenced_block ::= fenced_4 State 25: fenced_block ::= fenced_3 * LINE_FENCE_BACKTICK_3 fenced_block ::= fenced_3 * LINE_FENCE_BACKTICK_4 fenced_block ::= fenced_3 * LINE_FENCE_BACKTICK_5 - (99) fenced_block ::= fenced_3 * + (101) fenced_block ::= fenced_3 * fenced_3 ::= fenced_3 * fenced_line fenced_line ::= * LINE_CONTINUATION fenced_line ::= * LINE_EMPTY fenced_line ::= * LINE_SETEXT_1 fenced_line ::= * LINE_SETEXT_2 - LINE_SETEXT_1 shift-reduce 110 fenced_line ::= LINE_SETEXT_1 - LINE_SETEXT_2 shift-reduce 111 fenced_line ::= LINE_SETEXT_2 - LINE_CONTINUATION shift-reduce 108 fenced_line ::= LINE_CONTINUATION - LINE_EMPTY shift-reduce 109 fenced_line ::= LINE_EMPTY - LINE_EMPTY reduce 99 ** Parsing conflict ** - LINE_FENCE_BACKTICK_3 shift-reduce 42 fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_3 - LINE_FENCE_BACKTICK_3 reduce 99 ** Parsing conflict ** - LINE_FENCE_BACKTICK_4 shift-reduce 43 fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_4 - LINE_FENCE_BACKTICK_4 reduce 99 ** Parsing conflict ** - LINE_FENCE_BACKTICK_5 shift-reduce 44 fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_5 - LINE_FENCE_BACKTICK_5 reduce 99 ** Parsing conflict ** - fenced_line shift-reduce 45 fenced_3 ::= fenced_3 fenced_line - {default} reduce 99 fenced_block ::= fenced_3 + LINE_SETEXT_1 shift-reduce 112 fenced_line ::= LINE_SETEXT_1 + LINE_SETEXT_2 shift-reduce 113 fenced_line ::= LINE_SETEXT_2 + LINE_CONTINUATION shift-reduce 110 fenced_line ::= LINE_CONTINUATION + LINE_EMPTY shift-reduce 111 fenced_line ::= LINE_EMPTY + LINE_EMPTY reduce 101 ** Parsing conflict ** + LINE_FENCE_BACKTICK_3 shift-reduce 43 fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_3 + LINE_FENCE_BACKTICK_3 reduce 101 ** Parsing conflict ** + LINE_FENCE_BACKTICK_4 shift-reduce 44 fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_4 + LINE_FENCE_BACKTICK_4 reduce 101 ** Parsing conflict ** + LINE_FENCE_BACKTICK_5 shift-reduce 45 fenced_block ::= fenced_3 LINE_FENCE_BACKTICK_5 + LINE_FENCE_BACKTICK_5 reduce 101 ** Parsing conflict ** + fenced_line shift-reduce 46 fenced_3 ::= fenced_3 fenced_line + {default} reduce 101 fenced_block ::= fenced_3 State 26: nested_chunk ::= empty * indented_line chunk nested_chunk ::= empty * indented_line - (85) nested_chunk ::= empty * + (86) nested_chunk ::= empty * indented_line ::= * LINE_INDENTED_TAB indented_line ::= * LINE_INDENTED_SPACE empty ::= empty * LINE_EMPTY - LINE_INDENTED_TAB shift-reduce 86 indented_line ::= LINE_INDENTED_TAB - LINE_INDENTED_TAB reduce 85 ** Parsing conflict ** - LINE_INDENTED_SPACE shift-reduce 87 indented_line ::= LINE_INDENTED_SPACE - LINE_INDENTED_SPACE reduce 85 ** Parsing conflict ** - LINE_EMPTY shift-reduce 41 empty ::= empty LINE_EMPTY - LINE_EMPTY reduce 85 ** Parsing conflict ** + LINE_INDENTED_TAB shift-reduce 87 indented_line ::= LINE_INDENTED_TAB + LINE_INDENTED_TAB reduce 86 ** Parsing conflict ** + LINE_INDENTED_SPACE shift-reduce 88 indented_line ::= LINE_INDENTED_SPACE + LINE_INDENTED_SPACE reduce 86 ** Parsing conflict ** + LINE_EMPTY shift-reduce 42 empty ::= empty LINE_EMPTY + LINE_EMPTY reduce 86 ** Parsing conflict ** indented_line shift 21 - {default} reduce 85 nested_chunk ::= empty + {default} reduce 86 nested_chunk ::= empty State 27: - (19) block ::= indented_code * + (20) block ::= indented_code * indented_line ::= * LINE_INDENTED_TAB indented_line ::= * LINE_INDENTED_SPACE indented_code ::= indented_code * indented_line indented_code ::= indented_code * LINE_EMPTY - LINE_INDENTED_TAB shift-reduce 86 indented_line ::= LINE_INDENTED_TAB - LINE_INDENTED_TAB reduce 19 ** Parsing conflict ** - LINE_INDENTED_SPACE shift-reduce 87 indented_line ::= LINE_INDENTED_SPACE - LINE_INDENTED_SPACE reduce 19 ** Parsing conflict ** - LINE_EMPTY shift-reduce 59 indented_code ::= indented_code LINE_EMPTY - LINE_EMPTY reduce 19 ** Parsing conflict ** - indented_line shift-reduce 58 indented_code ::= indented_code indented_line - {default} reduce 19 block ::= indented_code + LINE_INDENTED_TAB shift-reduce 87 indented_line ::= LINE_INDENTED_TAB + LINE_INDENTED_TAB reduce 20 ** Parsing conflict ** + LINE_INDENTED_SPACE shift-reduce 88 indented_line ::= LINE_INDENTED_SPACE + LINE_INDENTED_SPACE reduce 20 ** Parsing conflict ** + LINE_EMPTY shift-reduce 60 indented_code ::= indented_code LINE_EMPTY + LINE_EMPTY reduce 20 ** Parsing conflict ** + indented_line shift-reduce 59 indented_code ::= indented_code indented_line + {default} reduce 20 block ::= indented_code State 28: - (22) block ::= meta_block * + (23) block ::= meta_block * meta_block ::= meta_block * meta_line meta_line ::= * LINE_META meta_line ::= * LINE_CONTINUATION - LINE_CONTINUATION shift-reduce 120 meta_line ::= LINE_CONTINUATION - LINE_META shift-reduce 119 meta_line ::= LINE_META - LINE_META reduce 22 ** Parsing conflict ** - meta_line shift-reduce 70 meta_block ::= meta_block meta_line - {default} reduce 22 block ::= meta_block + LINE_CONTINUATION shift-reduce 122 meta_line ::= LINE_CONTINUATION + LINE_META shift-reduce 121 meta_line ::= LINE_META + LINE_META reduce 23 ** Parsing conflict ** + meta_line shift-reduce 71 meta_block ::= meta_block meta_line + {default} reduce 23 block ::= meta_block State 29: - (18) block ::= html_block * + (19) block ::= html_block * html_block ::= html_block * html_line html_line ::= * LINE_CONTINUATION html_line ::= * LINE_HTML - LINE_CONTINUATION shift-reduce 113 html_line ::= LINE_CONTINUATION - LINE_HTML shift-reduce 114 html_line ::= LINE_HTML - LINE_HTML reduce 18 ** Parsing conflict ** - html_line shift-reduce 57 html_block ::= html_block html_line - {default} reduce 18 block ::= html_block + LINE_CONTINUATION shift-reduce 115 html_line ::= LINE_CONTINUATION + LINE_HTML shift-reduce 116 html_line ::= LINE_HTML + LINE_HTML reduce 19 ** Parsing conflict ** + html_line shift-reduce 58 html_block ::= html_block html_line + {default} reduce 19 block ::= html_block State 30: (11) block ::= blockquote * @@ -896,54 +904,54 @@ State 30: quote_line ::= * LINE_BLOCKQUOTE quote_line ::= * LINE_CONTINUATION - LINE_CONTINUATION shift-reduce 93 quote_line ::= LINE_CONTINUATION - LINE_BLOCKQUOTE shift-reduce 92 quote_line ::= LINE_BLOCKQUOTE + LINE_CONTINUATION shift-reduce 94 quote_line ::= LINE_CONTINUATION + LINE_BLOCKQUOTE shift-reduce 93 quote_line ::= LINE_BLOCKQUOTE LINE_BLOCKQUOTE reduce 11 ** Parsing conflict ** - quote_line shift-reduce 33 blockquote ::= blockquote quote_line + quote_line shift-reduce 34 blockquote ::= blockquote quote_line {default} reduce 11 block ::= blockquote State 31: chunk ::= chunk * chunk_line chunk_line ::= * LINE_CONTINUATION - (71) para ::= LINE_PLAIN chunk * + (72) para ::= LINE_PLAIN chunk * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - chunk_line shift-reduce 27 chunk ::= chunk chunk_line - {default} reduce 71 para ::= LINE_PLAIN chunk + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + chunk_line shift-reduce 28 chunk ::= chunk chunk_line + {default} reduce 72 para ::= LINE_PLAIN chunk State 32: defs ::= defs * def def ::= * LINE_DEFINITION tail def ::= * LINE_DEFINITION - (128) para ::= defs * + (130) para ::= defs * LINE_DEFINITION shift 4 - LINE_DEFINITION reduce 128 ** Parsing conflict ** - def shift-reduce 38 defs ::= defs def - {default} reduce 128 para ::= defs + LINE_DEFINITION reduce 130 ** Parsing conflict ** + def shift-reduce 39 defs ::= defs def + {default} reduce 130 para ::= defs State 33: chunk ::= chunk * chunk_line chunk_line ::= * LINE_CONTINUATION - (36) def_link ::= LINE_DEF_LINK chunk * + (37) def_link ::= LINE_DEF_LINK chunk * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - chunk_line shift-reduce 27 chunk ::= chunk chunk_line - {default} reduce 36 def_link ::= LINE_DEF_LINK chunk + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + chunk_line shift-reduce 28 chunk ::= chunk chunk_line + {default} reduce 37 def_link ::= LINE_DEF_LINK chunk State 34: - (37) definition_block ::= para defs * + (38) definition_block ::= para defs * defs ::= defs * def def ::= * LINE_DEFINITION tail def ::= * LINE_DEFINITION LINE_DEFINITION shift 4 - LINE_DEFINITION reduce 37 ** Parsing conflict ** - def shift-reduce 38 defs ::= defs def - {default} reduce 37 definition_block ::= para defs + LINE_DEFINITION reduce 38 ** Parsing conflict ** + def shift-reduce 39 defs ::= defs def + {default} reduce 38 definition_block ::= para defs State 35: - (21) block ::= list_enum * + (22) block ::= list_enum * list_enum ::= list_enum * item_enum item_enum ::= * LINE_LIST_ENUMERATED ext_chunk item_enum ::= * LINE_LIST_ENUMERATED chunk @@ -951,21 +959,21 @@ State 35: item_enum ::= * LINE_LIST_ENUMERATED LINE_LIST_ENUMERATED shift 5 - LINE_LIST_ENUMERATED reduce 21 ** Parsing conflict ** - item_enum shift-reduce 65 list_enum ::= list_enum item_enum - {default} reduce 21 block ::= list_enum + LINE_LIST_ENUMERATED reduce 22 ** Parsing conflict ** + item_enum shift-reduce 66 list_enum ::= list_enum item_enum + {default} reduce 22 block ::= list_enum State 36: chunk ::= chunk * chunk_line chunk_line ::= * LINE_CONTINUATION - (29) nested_chunk ::= empty indented_line chunk * + (30) nested_chunk ::= empty indented_line chunk * - LINE_CONTINUATION shift-reduce 83 chunk_line ::= LINE_CONTINUATION - chunk_line shift-reduce 27 chunk ::= chunk chunk_line - {default} reduce 29 nested_chunk ::= empty indented_line chunk + LINE_CONTINUATION shift-reduce 84 chunk_line ::= LINE_CONTINUATION + chunk_line shift-reduce 28 chunk ::= chunk chunk_line + {default} reduce 30 nested_chunk ::= empty indented_line chunk State 37: - (20) block ::= list_bullet * + (21) block ::= list_bullet * list_bullet ::= list_bullet * item_bullet item_bullet ::= * LINE_LIST_BULLETED ext_chunk item_bullet ::= * LINE_LIST_BULLETED chunk @@ -973,36 +981,36 @@ State 37: item_bullet ::= * LINE_LIST_BULLETED LINE_LIST_BULLETED shift 6 - LINE_LIST_BULLETED reduce 20 ** Parsing conflict ** - item_bullet shift-reduce 60 list_bullet ::= list_bullet item_bullet - {default} reduce 20 block ::= list_bullet + LINE_LIST_BULLETED reduce 21 ** Parsing conflict ** + item_bullet shift-reduce 61 list_bullet ::= list_bullet item_bullet + {default} reduce 21 block ::= list_bullet State 38: table_header ::= header_rows * LINE_TABLE_SEPARATOR header_rows ::= header_rows * LINE_TABLE - (126) row ::= header_rows * + (128) row ::= header_rows * - LINE_TABLE_SEPARATOR shift-reduce 75 table_header ::= header_rows LINE_TABLE_SEPARATOR - LINE_TABLE_SEPARATOR reduce 126 ** Parsing conflict ** - LINE_TABLE shift-reduce 76 header_rows ::= header_rows LINE_TABLE - LINE_TABLE reduce 126 ** Parsing conflict ** - {default} reduce 126 row ::= header_rows + LINE_TABLE_SEPARATOR shift-reduce 76 table_header ::= header_rows LINE_TABLE_SEPARATOR + LINE_TABLE_SEPARATOR reduce 128 ** Parsing conflict ** + LINE_TABLE shift-reduce 77 header_rows ::= header_rows LINE_TABLE + LINE_TABLE reduce 128 ** Parsing conflict ** + {default} reduce 128 row ::= header_rows State 39: header_rows ::= header_rows * LINE_TABLE - (126) row ::= header_rows * + (128) row ::= header_rows * - LINE_TABLE shift-reduce 76 header_rows ::= header_rows LINE_TABLE - LINE_TABLE reduce 126 ** Parsing conflict ** - {default} reduce 126 row ::= header_rows + LINE_TABLE shift-reduce 77 header_rows ::= header_rows LINE_TABLE + LINE_TABLE reduce 128 ** Parsing conflict ** + {default} reduce 128 row ::= header_rows State 40: - (16) block ::= empty * + (17) block ::= empty * empty ::= empty * LINE_EMPTY - LINE_EMPTY shift-reduce 41 empty ::= empty LINE_EMPTY - LINE_EMPTY reduce 16 ** Parsing conflict ** - {default} reduce 16 block ::= empty + LINE_EMPTY shift-reduce 42 empty ::= empty LINE_EMPTY + LINE_EMPTY reduce 17 ** Parsing conflict ** + {default} reduce 17 block ::= empty ---------------------------------------------------- Symbols: @@ -1032,57 +1040,59 @@ Symbols: 23: LINE_FENCE_BACKTICK 24: LINE_FENCE_BACKTICK_START 25: LINE_TOC - 26: LINE_DEFINITION - 27: LINE_EMPTY - 28: LINE_FENCE_BACKTICK_3 - 29: LINE_FENCE_BACKTICK_4 - 30: LINE_FENCE_BACKTICK_5 - 31: LINE_FENCE_BACKTICK_START_3 - 32: LINE_FENCE_BACKTICK_START_4 - 33: LINE_FENCE_BACKTICK_START_5 - 34: LINE_META - 35: error: - 36: doc: LINE_HR LINE_PLAIN LINE_TABLE_SEPARATOR LINE_INDENTED_TAB LINE_INDENTED_SPACE LINE_TABLE LINE_HTML LINE_ATX_1 LINE_ATX_2 LINE_ATX_3 LINE_ATX_4 LINE_ATX_5 LINE_ATX_6 LINE_BLOCKQUOTE LINE_LIST_BULLETED LINE_LIST_ENUMERATED LINE_DEF_CITATION LINE_DEF_FOOTNOTE LINE_DEF_LINK LINE_TOC LINE_DEFINITION LINE_EMPTY LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_3 LINE_FENCE_BACKTICK_START_4 LINE_FENCE_BACKTICK_START_5 LINE_META - 37: blocks: LINE_HR LINE_PLAIN LINE_TABLE_SEPARATOR LINE_INDENTED_TAB LINE_INDENTED_SPACE LINE_TABLE LINE_HTML LINE_ATX_1 LINE_ATX_2 LINE_ATX_3 LINE_ATX_4 LINE_ATX_5 LINE_ATX_6 LINE_BLOCKQUOTE LINE_LIST_BULLETED LINE_LIST_ENUMERATED LINE_DEF_CITATION LINE_DEF_FOOTNOTE LINE_DEF_LINK LINE_TOC LINE_DEFINITION LINE_EMPTY LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_3 LINE_FENCE_BACKTICK_START_4 LINE_FENCE_BACKTICK_START_5 LINE_META - 38: block: LINE_HR LINE_PLAIN LINE_TABLE_SEPARATOR LINE_INDENTED_TAB LINE_INDENTED_SPACE LINE_TABLE LINE_HTML LINE_ATX_1 LINE_ATX_2 LINE_ATX_3 LINE_ATX_4 LINE_ATX_5 LINE_ATX_6 LINE_BLOCKQUOTE LINE_LIST_BULLETED LINE_LIST_ENUMERATED LINE_DEF_CITATION LINE_DEF_FOOTNOTE LINE_DEF_LINK LINE_TOC LINE_DEFINITION LINE_EMPTY LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_3 LINE_FENCE_BACKTICK_START_4 LINE_FENCE_BACKTICK_START_5 LINE_META - 39: blockquote: LINE_BLOCKQUOTE - 40: def_citation: LINE_DEF_CITATION - 41: def_footnote: LINE_DEF_FOOTNOTE - 42: def_link: LINE_DEF_LINK - 43: definition_block: LINE_PLAIN LINE_TABLE_SEPARATOR LINE_TABLE LINE_DEFINITION - 44: empty: LINE_EMPTY - 45: fenced_block: LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_3 LINE_FENCE_BACKTICK_START_4 LINE_FENCE_BACKTICK_START_5 - 46: html_block: LINE_HTML - 47: indented_code: LINE_INDENTED_TAB LINE_INDENTED_SPACE - 48: list_bullet: LINE_LIST_BULLETED - 49: list_enum: LINE_LIST_ENUMERATED - 50: meta_block: LINE_META - 51: para: LINE_PLAIN LINE_TABLE_SEPARATOR LINE_TABLE LINE_DEFINITION - 52: setext_1: LINE_PLAIN LINE_TABLE_SEPARATOR LINE_TABLE LINE_DEFINITION - 53: setext_2: LINE_PLAIN LINE_TABLE_SEPARATOR LINE_TABLE LINE_DEFINITION - 54: table: LINE_TABLE - 55: chunk: LINE_CONTINUATION - 56: chunk_line: LINE_CONTINUATION - 57: nested_chunks: LINE_EMPTY - 58: nested_chunk: LINE_EMPTY - 59: indented_line: LINE_INDENTED_TAB LINE_INDENTED_SPACE - 60: ext_chunk: LINE_CONTINUATION - 61: opt_ext_chunk: LINE_CONTINUATION - 62: tail: LINE_CONTINUATION LINE_EMPTY - 63: quote_line: LINE_CONTINUATION LINE_BLOCKQUOTE - 64: defs: LINE_DEFINITION - 65: def: LINE_DEFINITION - 66: fenced_3: LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_START_3 - 67: fenced_line: LINE_SETEXT_1 LINE_SETEXT_2 LINE_CONTINUATION LINE_EMPTY - 68: fenced_4: LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_START_4 - 69: fenced_5: LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_5 - 70: html_line: LINE_CONTINUATION LINE_HTML - 71: item_bullet: LINE_LIST_BULLETED - 72: item_enum: LINE_LIST_ENUMERATED - 73: meta_line: LINE_CONTINUATION LINE_META - 74: table_header: LINE_TABLE - 75: table_body: LINE_TABLE_SEPARATOR LINE_TABLE - 76: header_rows: LINE_TABLE - 77: table_section: LINE_TABLE_SEPARATOR LINE_TABLE - 78: all_rows: LINE_TABLE_SEPARATOR LINE_TABLE - 79: row: LINE_TABLE_SEPARATOR LINE_TABLE + 26: LINE_DEF_ABBREVIATION + 27: LINE_DEFINITION + 28: LINE_EMPTY + 29: LINE_FENCE_BACKTICK_3 + 30: LINE_FENCE_BACKTICK_4 + 31: LINE_FENCE_BACKTICK_5 + 32: LINE_FENCE_BACKTICK_START_3 + 33: LINE_FENCE_BACKTICK_START_4 + 34: LINE_FENCE_BACKTICK_START_5 + 35: LINE_META + 36: error: + 37: doc: LINE_HR LINE_PLAIN LINE_TABLE_SEPARATOR LINE_INDENTED_TAB LINE_INDENTED_SPACE LINE_TABLE LINE_HTML LINE_ATX_1 LINE_ATX_2 LINE_ATX_3 LINE_ATX_4 LINE_ATX_5 LINE_ATX_6 LINE_BLOCKQUOTE LINE_LIST_BULLETED LINE_LIST_ENUMERATED LINE_DEF_CITATION LINE_DEF_FOOTNOTE LINE_DEF_LINK LINE_TOC LINE_DEF_ABBREVIATION LINE_DEFINITION LINE_EMPTY LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_3 LINE_FENCE_BACKTICK_START_4 LINE_FENCE_BACKTICK_START_5 LINE_META + 38: blocks: LINE_HR LINE_PLAIN LINE_TABLE_SEPARATOR LINE_INDENTED_TAB LINE_INDENTED_SPACE LINE_TABLE LINE_HTML LINE_ATX_1 LINE_ATX_2 LINE_ATX_3 LINE_ATX_4 LINE_ATX_5 LINE_ATX_6 LINE_BLOCKQUOTE LINE_LIST_BULLETED LINE_LIST_ENUMERATED LINE_DEF_CITATION LINE_DEF_FOOTNOTE LINE_DEF_LINK LINE_TOC LINE_DEF_ABBREVIATION LINE_DEFINITION LINE_EMPTY LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_3 LINE_FENCE_BACKTICK_START_4 LINE_FENCE_BACKTICK_START_5 LINE_META + 39: block: LINE_HR LINE_PLAIN LINE_TABLE_SEPARATOR LINE_INDENTED_TAB LINE_INDENTED_SPACE LINE_TABLE LINE_HTML LINE_ATX_1 LINE_ATX_2 LINE_ATX_3 LINE_ATX_4 LINE_ATX_5 LINE_ATX_6 LINE_BLOCKQUOTE LINE_LIST_BULLETED LINE_LIST_ENUMERATED LINE_DEF_CITATION LINE_DEF_FOOTNOTE LINE_DEF_LINK LINE_TOC LINE_DEF_ABBREVIATION LINE_DEFINITION LINE_EMPTY LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_3 LINE_FENCE_BACKTICK_START_4 LINE_FENCE_BACKTICK_START_5 LINE_META + 40: blockquote: LINE_BLOCKQUOTE + 41: def_abbreviation: LINE_DEF_ABBREVIATION + 42: def_citation: LINE_DEF_CITATION + 43: def_footnote: LINE_DEF_FOOTNOTE + 44: def_link: LINE_DEF_LINK + 45: definition_block: LINE_PLAIN LINE_TABLE_SEPARATOR LINE_TABLE LINE_DEFINITION + 46: empty: LINE_EMPTY + 47: fenced_block: LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_3 LINE_FENCE_BACKTICK_START_4 LINE_FENCE_BACKTICK_START_5 + 48: html_block: LINE_HTML + 49: indented_code: LINE_INDENTED_TAB LINE_INDENTED_SPACE + 50: list_bullet: LINE_LIST_BULLETED + 51: list_enum: LINE_LIST_ENUMERATED + 52: meta_block: LINE_META + 53: para: LINE_PLAIN LINE_TABLE_SEPARATOR LINE_TABLE LINE_DEFINITION + 54: setext_1: LINE_PLAIN LINE_TABLE_SEPARATOR LINE_TABLE LINE_DEFINITION + 55: setext_2: LINE_PLAIN LINE_TABLE_SEPARATOR LINE_TABLE LINE_DEFINITION + 56: table: LINE_TABLE + 57: chunk: LINE_CONTINUATION + 58: chunk_line: LINE_CONTINUATION + 59: nested_chunks: LINE_EMPTY + 60: nested_chunk: LINE_EMPTY + 61: indented_line: LINE_INDENTED_TAB LINE_INDENTED_SPACE + 62: ext_chunk: LINE_CONTINUATION + 63: opt_ext_chunk: LINE_CONTINUATION + 64: tail: LINE_CONTINUATION LINE_EMPTY + 65: quote_line: LINE_CONTINUATION LINE_BLOCKQUOTE + 66: defs: LINE_DEFINITION + 67: def: LINE_DEFINITION + 68: fenced_3: LINE_FENCE_BACKTICK_3 LINE_FENCE_BACKTICK_START_3 + 69: fenced_line: LINE_SETEXT_1 LINE_SETEXT_2 LINE_CONTINUATION LINE_EMPTY + 70: fenced_4: LINE_FENCE_BACKTICK_4 LINE_FENCE_BACKTICK_START_4 + 71: fenced_5: LINE_FENCE_BACKTICK_5 LINE_FENCE_BACKTICK_START_5 + 72: html_line: LINE_CONTINUATION LINE_HTML + 73: item_bullet: LINE_LIST_BULLETED + 74: item_enum: LINE_LIST_ENUMERATED + 75: meta_line: LINE_CONTINUATION LINE_META + 76: table_header: LINE_TABLE + 77: table_body: LINE_TABLE_SEPARATOR LINE_TABLE + 78: header_rows: LINE_TABLE + 79: table_section: LINE_TABLE_SEPARATOR LINE_TABLE + 80: all_rows: LINE_TABLE_SEPARATOR LINE_TABLE + 81: row: LINE_TABLE_SEPARATOR LINE_TABLE diff --git a/Sources/libMultiMarkdown/parser.y b/Sources/libMultiMarkdown/parser.y index 60cc871..b1abf81 100644 --- a/Sources/libMultiMarkdown/parser.y +++ b/Sources/libMultiMarkdown/parser.y @@ -112,6 +112,7 @@ block(A) ::= LINE_TOC(B). { A = token_new_parent(B, BLOCK_TOC); } // Multi-line blocks block(A) ::= blockquote(B). { A = token_new_parent(B, BLOCK_BLOCKQUOTE); recursive_parse_blockquote(engine, A); } +block(A) ::= def_abbreviation(B). { A = token_new_parent(B, BLOCK_DEF_ABBREVIATION); stack_push(engine->definition_stack, A); } block(A) ::= def_citation(B). { A = token_new_parent(B, BLOCK_DEF_CITATION); stack_push(engine->definition_stack, A); } block(A) ::= def_footnote(B). { A = token_new_parent(B, BLOCK_DEF_FOOTNOTE); stack_push(engine->definition_stack, A); recursive_parse_indent(engine, A); } block(A) ::= def_link(B). { A = token_new_parent(B, BLOCK_DEF_LINK); stack_push(engine->definition_stack, A); } @@ -196,6 +197,8 @@ def_footnote ::= LINE_DEF_FOOTNOTE. def_link(A) ::= LINE_DEF_LINK(B) chunk(C). { A = B; token_chain_append(B, C); } def_link ::= LINE_DEF_LINK. +def_abbreviation ::= LINE_DEF_ABBREVIATION. + // Definition lists // Lemon's LALR(1) parser can't properly allow for detecting consecutive definition blocks and concatenating them, diff --git a/Sources/libMultiMarkdown/scanners.c b/Sources/libMultiMarkdown/scanners.c index d80a386..6fddf63 100644 --- a/Sources/libMultiMarkdown/scanners.c +++ b/Sources/libMultiMarkdown/scanners.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.14.3 on Thu Feb 16 19:37:08 2017 */ +/* Generated by re2c 0.14.3 on Thu Mar 2 09:19:45 2017 */ /** MultiMarkdown 6 -- Lightweight markup processor to produce HTML, LaTeX, and more. @@ -3440,7 +3440,7 @@ yy140: } -size_t scan_ref_citation(const char * c) { +size_t scan_ref_abbreviation(const char * c) { const char * marker = NULL; const char * start = c; @@ -3451,7 +3451,7 @@ size_t scan_ref_citation(const char * c) { switch (yych) { case '\n': goto yy144; case ' ': goto yy145; - case '[': goto yy146; + case '*': goto yy146; default: goto yy147; } yy144: @@ -3460,13 +3460,13 @@ yy145: yych = *(marker = ++c); switch (yych) { case ' ': goto yy157; - case '[': goto yy158; + case '*': goto yy158; default: goto yy144; } yy146: yych = *(marker = ++c); switch (yych) { - case '#': goto yy148; + case '[': goto yy148; default: goto yy144; } yy147: @@ -3521,26 +3521,27 @@ yy157: yych = *++c; switch (yych) { case ' ': goto yy159; - case '[': goto yy158; + case '*': goto yy158; default: goto yy149; } yy158: yych = *++c; switch (yych) { - case '#': goto yy148; + case '[': goto yy148; default: goto yy149; } yy159: ++c; switch ((yych = *c)) { - case '[': goto yy158; + case '*': goto yy158; default: goto yy149; } } } -size_t scan_ref_foot(const char * c) { + +size_t scan_ref_citation(const char * c) { const char * marker = NULL; const char * start = c; @@ -3566,7 +3567,7 @@ yy163: yy164: yych = *(marker = ++c); switch (yych) { - case '^': goto yy166; + case '#': goto yy166; default: goto yy162; } yy165: @@ -3627,7 +3628,7 @@ yy175: yy176: yych = *++c; switch (yych) { - case '^': goto yy166; + case '#': goto yy166; default: goto yy167; } yy177: @@ -3640,15 +3641,13 @@ yy177: } - -size_t scan_ref_link_no_attributes(const char * c) { +size_t scan_ref_foot(const char * c) { const char * marker = NULL; const char * start = c; { char yych; - unsigned int yyaccept = 0; yych = *c; switch (yych) { case '\n': goto yy180; @@ -3659,962 +3658,1064 @@ size_t scan_ref_link_no_attributes(const char * c) { yy180: { return 0; } yy181: - yyaccept = 0; yych = *(marker = ++c); switch (yych) { - case ' ': goto yy317; - case '[': goto yy318; + case ' ': goto yy193; + case '[': goto yy194; default: goto yy180; } yy182: + yych = *(marker = ++c); + switch (yych) { + case '^': goto yy184; + default: goto yy180; + } +yy183: + yych = *++c; + goto yy180; +yy184: + yych = *++c; + switch (yych) { + case ']': goto yy185; + default: goto yy187; + } +yy185: + c = marker; + goto yy180; +yy186: + ++c; + yych = *c; +yy187: + switch (yych) { + case 0x00: + case '\n': + case '\r': goto yy185; + case ']': goto yy188; + default: goto yy186; + } +yy188: + yych = *++c; + switch (yych) { + case ':': goto yy189; + default: goto yy185; + } +yy189: + yych = *++c; + switch (yych) { + case 0x00: + case '\n': + case '\r': goto yy185; + default: goto yy190; + } +yy190: + ++c; + yych = *c; + switch (yych) { + case 0x00: + case '\n': + case '\r': goto yy192; + default: goto yy190; + } +yy192: + { return (size_t)( c - start ); } +yy193: + yych = *++c; + switch (yych) { + case ' ': goto yy195; + case '[': goto yy194; + default: goto yy185; + } +yy194: + yych = *++c; + switch (yych) { + case '^': goto yy184; + default: goto yy185; + } +yy195: + ++c; + switch ((yych = *c)) { + case '[': goto yy194; + default: goto yy185; + } +} + +} + + +size_t scan_ref_link_no_attributes(const char * c) { + const char * marker = NULL; + const char * start = c; + + +{ + char yych; + unsigned int yyaccept = 0; + yych = *c; + switch (yych) { + case '\n': goto yy198; + case ' ': goto yy199; + case '[': goto yy200; + default: goto yy201; + } +yy198: + { return 0; } +yy199: + yyaccept = 0; + yych = *(marker = ++c); + switch (yych) { + case ' ': goto yy335; + case '[': goto yy336; + default: goto yy198; + } +yy200: yyaccept = 0; yych = *(marker = ++c); switch (yych) { case 0x00: case '\n': case '\r': - case ']': goto yy180; - default: goto yy184; + case ']': goto yy198; + default: goto yy202; } -yy183: +yy201: yych = *++c; - goto yy180; -yy184: + goto yy198; +yy202: ++c; yych = *c; -yy185: +yy203: switch (yych) { case 0x00: case '\n': - case '\r': goto yy186; - case ']': goto yy187; - default: goto yy184; + case '\r': goto yy204; + case ']': goto yy205; + default: goto yy202; } -yy186: +yy204: c = marker; if (yyaccept == 0) { - goto yy180; + goto yy198; } else { - goto yy200; + goto yy218; } -yy187: +yy205: yych = *++c; switch (yych) { - case ':': goto yy188; - default: goto yy186; + case ':': goto yy206; + default: goto yy204; } -yy188: +yy206: ++c; yych = *c; switch (yych) { - case 0x00: goto yy186; + case 0x00: goto yy204; case '\t': - case ' ': goto yy188; - case '\n': goto yy190; - case '\r': goto yy192; - case '<': goto yy193; - default: goto yy195; + case ' ': goto yy206; + case '\n': goto yy208; + case '\r': goto yy210; + case '<': goto yy211; + default: goto yy213; } -yy190: +yy208: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy186; + case '\r': goto yy204; case '\t': - case ' ': goto yy190; - case '<': goto yy193; - default: goto yy195; + case ' ': goto yy208; + case '<': goto yy211; + default: goto yy213; } -yy192: +yy210: yych = *++c; switch (yych) { case 0x00: - case '\r': goto yy186; + case '\r': goto yy204; case '\t': case '\n': - case ' ': goto yy190; - case '<': goto yy193; - default: goto yy195; + case ' ': goto yy208; + case '<': goto yy211; + default: goto yy213; } -yy193: +yy211: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy197; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy290; - case '\'': goto yy292; - case '(': goto yy294; - case '>': goto yy195; - default: goto yy193; + case ' ': goto yy215; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy308; + case '\'': goto yy310; + case '(': goto yy312; + case '>': goto yy213; + default: goto yy211; } -yy195: +yy213: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy197; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy203; - case '\'': goto yy205; - case '(': goto yy207; - default: goto yy195; + case ' ': goto yy215; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy221; + case '\'': goto yy223; + case '(': goto yy225; + default: goto yy213; } -yy197: +yy215: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy197; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy219; - case '\'': goto yy221; - case '(': goto yy223; - default: goto yy186; + case ' ': goto yy215; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy237; + case '\'': goto yy239; + case '(': goto yy241; + default: goto yy204; } -yy199: +yy217: ++c; -yy200: +yy218: { return (size_t)( c - start ); } -yy201: +yy219: yyaccept = 1; yych = *(marker = ++c); switch (yych) { - case '"': goto yy219; - case '\'': goto yy221; - case '(': goto yy223; - default: goto yy200; + case '"': goto yy237; + case '\'': goto yy239; + case '(': goto yy241; + default: goto yy218; } -yy202: +yy220: yyaccept = 1; yych = *(marker = ++c); switch (yych) { - case '\n': goto yy201; - case '"': goto yy219; - case '\'': goto yy221; - case '(': goto yy223; - default: goto yy200; + case '\n': goto yy219; + case '"': goto yy237; + case '\'': goto yy239; + case '(': goto yy241; + default: goto yy218; } -yy203: +yy221: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy288; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy276; - case '\'': goto yy266; - case '(': goto yy211; - default: goto yy203; + case ' ': goto yy306; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy294; + case '\'': goto yy284; + case '(': goto yy229; + default: goto yy221; } -yy205: +yy223: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy286; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy266; - case '\'': goto yy228; - case '(': goto yy213; - default: goto yy205; + case ' ': goto yy304; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy284; + case '\'': goto yy246; + case '(': goto yy231; + default: goto yy223; } -yy207: +yy225: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy209; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy211; - case '\'': goto yy213; - case ')': goto yy215; - default: goto yy207; + case ' ': goto yy227; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy229; + case '\'': goto yy231; + case ')': goto yy233; + default: goto yy225; } -yy209: +yy227: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy209; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy256; - case '\'': goto yy240; - case ')': goto yy225; - default: goto yy223; + case ' ': goto yy227; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy274; + case '\'': goto yy258; + case ')': goto yy243; + default: goto yy241; } -yy211: +yy229: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy278; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy280; - case '\'': goto yy232; - case ')': goto yy276; - default: goto yy211; + case ' ': goto yy296; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy298; + case '\'': goto yy250; + case ')': goto yy294; + default: goto yy229; } -yy213: +yy231: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy230; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy232; - case '\'': goto yy234; - case ')': goto yy228; - default: goto yy213; + case ' ': goto yy248; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy250; + case '\'': goto yy252; + case ')': goto yy246; + default: goto yy231; } -yy215: +yy233: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy216; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy203; - case '\'': goto yy205; - case '(': goto yy207; - default: goto yy195; + case ' ': goto yy234; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy221; + case '\'': goto yy223; + case '(': goto yy225; + default: goto yy213; } -yy216: +yy234: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy216; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy219; - case '\'': goto yy221; - case '(': goto yy223; - default: goto yy186; + case ' ': goto yy234; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy237; + case '\'': goto yy239; + case '(': goto yy241; + default: goto yy204; } -yy218: +yy236: yyaccept = 1; yych = *(marker = ++c); switch (yych) { - case '\n': goto yy201; - case '"': goto yy219; - case '\'': goto yy221; - case '(': goto yy223; - default: goto yy200; + case '\n': goto yy219; + case '"': goto yy237; + case '\'': goto yy239; + case '(': goto yy241; + default: goto yy218; } -yy219: +yy237: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy186; - case '"': goto yy225; - default: goto yy219; + case '\r': goto yy204; + case '"': goto yy243; + default: goto yy237; } -yy221: +yy239: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy186; - case '\'': goto yy225; - default: goto yy221; + case '\r': goto yy204; + case '\'': goto yy243; + default: goto yy239; } -yy223: +yy241: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy186; - case ')': goto yy225; - default: goto yy223; + case '\r': goto yy204; + case ')': goto yy243; + default: goto yy241; } -yy225: +yy243: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy199; + case '\n': goto yy217; case '\t': - case ' ': goto yy225; - case '\r': goto yy227; - default: goto yy186; + case ' ': goto yy243; + case '\r': goto yy245; + default: goto yy204; } -yy227: +yy245: yych = *++c; switch (yych) { - case '\n': goto yy199; - default: goto yy200; + case '\n': goto yy217; + default: goto yy218; } -yy228: +yy246: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy274; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy266; - case '\'': goto yy228; - case '(': goto yy213; - default: goto yy205; + case ' ': goto yy292; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy284; + case '\'': goto yy246; + case '(': goto yy231; + default: goto yy223; } -yy230: +yy248: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy230; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy242; - case '\'': goto yy244; - case ')': goto yy238; - default: goto yy240; + case ' ': goto yy248; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy260; + case '\'': goto yy262; + case ')': goto yy256; + default: goto yy258; } -yy232: +yy250: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy260; - case '\n': goto yy201; - case '\r': goto yy202; + case ' ': goto yy278; + case '\n': goto yy219; + case '\r': goto yy220; case '"': - case '\'': goto yy258; - case ')': goto yy262; - default: goto yy232; + case '\'': goto yy276; + case ')': goto yy280; + default: goto yy250; } -yy234: +yy252: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy236; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy232; - case '\'': goto yy234; - case ')': goto yy228; - default: goto yy213; + case ' ': goto yy254; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy250; + case '\'': goto yy252; + case ')': goto yy246; + default: goto yy231; } -yy236: +yy254: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy236; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy242; - case '\'': goto yy244; - case ')': goto yy238; - default: goto yy240; + case ' ': goto yy254; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy260; + case '\'': goto yy262; + case ')': goto yy256; + default: goto yy258; } -yy238: +yy256: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy199; + case '\n': goto yy217; case '\t': - case ' ': goto yy238; - case '\r': goto yy227; - case '\'': goto yy225; - default: goto yy221; + case ' ': goto yy256; + case '\r': goto yy245; + case '\'': goto yy243; + default: goto yy239; } -yy240: +yy258: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy186; - case '\'': goto yy246; - case ')': goto yy238; - default: goto yy240; + case '\r': goto yy204; + case '\'': goto yy264; + case ')': goto yy256; + default: goto yy258; } -yy242: +yy260: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy186; - case '"': goto yy244; - case '\'': goto yy248; - case ')': goto yy250; - default: goto yy242; + case '\r': goto yy204; + case '"': goto yy262; + case '\'': goto yy266; + case ')': goto yy268; + default: goto yy260; } -yy244: +yy262: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy199; + case '\n': goto yy217; case '\t': - case ' ': goto yy244; - case '\r': goto yy227; - case '\'': goto yy246; - case ')': goto yy238; - default: goto yy240; + case ' ': goto yy262; + case '\r': goto yy245; + case '\'': goto yy264; + case ')': goto yy256; + default: goto yy258; } -yy246: +yy264: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy199; + case '\n': goto yy217; case '\t': - case ' ': goto yy246; - case '\r': goto yy227; - case ')': goto yy225; - default: goto yy223; + case ' ': goto yy264; + case '\r': goto yy245; + case ')': goto yy243; + default: goto yy241; } -yy248: +yy266: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy199; + case '\n': goto yy217; case '\t': - case ' ': goto yy248; - case '\r': goto yy227; - case '"': goto yy246; - case ')': goto yy252; - default: goto yy256; + case ' ': goto yy266; + case '\r': goto yy245; + case '"': goto yy264; + case ')': goto yy270; + default: goto yy274; } -yy250: +yy268: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy199; + case '\n': goto yy217; case '\t': - case ' ': goto yy250; - case '\r': goto yy227; - case '"': goto yy238; - case '\'': goto yy252; - default: goto yy254; + case ' ': goto yy268; + case '\r': goto yy245; + case '"': goto yy256; + case '\'': goto yy270; + default: goto yy272; } -yy252: +yy270: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy199; + case '\n': goto yy217; case '\t': - case ' ': goto yy252; - case '\r': goto yy227; - case '"': goto yy225; - default: goto yy219; + case ' ': goto yy270; + case '\r': goto yy245; + case '"': goto yy243; + default: goto yy237; } -yy254: +yy272: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy186; - case '"': goto yy238; - case '\'': goto yy252; - default: goto yy254; + case '\r': goto yy204; + case '"': goto yy256; + case '\'': goto yy270; + default: goto yy272; } -yy256: +yy274: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy186; - case '"': goto yy246; - case ')': goto yy252; - default: goto yy256; + case '\r': goto yy204; + case '"': goto yy264; + case ')': goto yy270; + default: goto yy274; } -yy258: +yy276: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy272; - case '\n': goto yy201; - case '\r': goto yy218; + case ' ': goto yy290; + case '\n': goto yy219; + case '\r': goto yy236; case '"': - case '\'': goto yy258; - case ')': goto yy262; - default: goto yy232; + case '\'': goto yy276; + case ')': goto yy280; + default: goto yy250; } -yy260: +yy278: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy260; - case '\n': goto yy201; - case '\r': goto yy202; + case ' ': goto yy278; + case '\n': goto yy219; + case '\r': goto yy220; case '"': - case '\'': goto yy270; - case ')': goto yy250; - default: goto yy242; + case '\'': goto yy288; + case ')': goto yy268; + default: goto yy260; } -yy262: +yy280: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy264; - case '\n': goto yy201; - case '\r': goto yy218; + case ' ': goto yy282; + case '\n': goto yy219; + case '\r': goto yy236; case '"': - case '\'': goto yy262; - case '(': goto yy232; - default: goto yy266; + case '\'': goto yy280; + case '(': goto yy250; + default: goto yy284; } -yy264: +yy282: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy264; - case '\n': goto yy201; - case '\r': goto yy218; + case ' ': goto yy282; + case '\n': goto yy219; + case '\r': goto yy236; case '"': - case '\'': goto yy250; - case '(': goto yy242; - default: goto yy254; + case '\'': goto yy268; + case '(': goto yy260; + default: goto yy272; } -yy266: +yy284: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy268; - case '\n': goto yy201; - case '\r': goto yy202; + case ' ': goto yy286; + case '\n': goto yy219; + case '\r': goto yy220; case '"': - case '\'': goto yy262; - case '(': goto yy232; - default: goto yy266; + case '\'': goto yy280; + case '(': goto yy250; + default: goto yy284; } -yy268: +yy286: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy268; - case '\n': goto yy201; - case '\r': goto yy202; + case ' ': goto yy286; + case '\n': goto yy219; + case '\r': goto yy220; case '"': - case '\'': goto yy250; - case '(': goto yy242; - default: goto yy254; + case '\'': goto yy268; + case '(': goto yy260; + default: goto yy272; } -yy270: +yy288: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy199; + case '\n': goto yy217; case '\t': - case ' ': goto yy270; - case '\r': goto yy227; - case '"': goto yy244; - case '\'': goto yy248; - case ')': goto yy250; - default: goto yy242; + case ' ': goto yy288; + case '\r': goto yy245; + case '"': goto yy262; + case '\'': goto yy266; + case ')': goto yy268; + default: goto yy260; } -yy272: +yy290: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy272; - case '\n': goto yy201; - case '\r': goto yy218; + case ' ': goto yy290; + case '\n': goto yy219; + case '\r': goto yy236; case '"': - case '\'': goto yy270; - case ')': goto yy250; - default: goto yy242; + case '\'': goto yy288; + case ')': goto yy268; + default: goto yy260; } -yy274: +yy292: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy274; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy254; - case '\'': goto yy238; - case '(': goto yy240; - default: goto yy221; + case ' ': goto yy292; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy272; + case '\'': goto yy256; + case '(': goto yy258; + default: goto yy239; } -yy276: +yy294: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy284; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy276; - case '\'': goto yy266; - case '(': goto yy211; - default: goto yy203; + case ' ': goto yy302; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy294; + case '\'': goto yy284; + case '(': goto yy229; + default: goto yy221; } -yy278: +yy296: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy278; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy248; - case '\'': goto yy242; - case ')': goto yy252; - default: goto yy256; + case ' ': goto yy296; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy266; + case '\'': goto yy260; + case ')': goto yy270; + default: goto yy274; } -yy280: +yy298: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy282; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy280; - case '\'': goto yy232; - case ')': goto yy276; - default: goto yy211; + case ' ': goto yy300; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy298; + case '\'': goto yy250; + case ')': goto yy294; + default: goto yy229; } -yy282: +yy300: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy282; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy248; - case '\'': goto yy242; - case ')': goto yy252; - default: goto yy256; + case ' ': goto yy300; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy266; + case '\'': goto yy260; + case ')': goto yy270; + default: goto yy274; } -yy284: +yy302: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy284; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy252; - case '\'': goto yy254; - case '(': goto yy256; - default: goto yy219; + case ' ': goto yy302; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy270; + case '\'': goto yy272; + case '(': goto yy274; + default: goto yy237; } -yy286: +yy304: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy286; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy254; - case '\'': goto yy238; - case '(': goto yy240; - default: goto yy221; + case ' ': goto yy304; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy272; + case '\'': goto yy256; + case '(': goto yy258; + default: goto yy239; } -yy288: +yy306: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy288; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy252; - case '\'': goto yy254; - case '(': goto yy256; - default: goto yy219; + case ' ': goto yy306; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy270; + case '\'': goto yy272; + case '(': goto yy274; + default: goto yy237; } -yy290: +yy308: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy288; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy313; - case '\'': goto yy311; - case '(': goto yy296; - case '>': goto yy203; - default: goto yy290; + case ' ': goto yy306; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy331; + case '\'': goto yy329; + case '(': goto yy314; + case '>': goto yy221; + default: goto yy308; } -yy292: +yy310: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy286; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy311; - case '\'': goto yy301; - case '(': goto yy298; - case '>': goto yy205; - default: goto yy292; + case ' ': goto yy304; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy329; + case '\'': goto yy319; + case '(': goto yy316; + case '>': goto yy223; + default: goto yy310; } -yy294: +yy312: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy209; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy296; - case '\'': goto yy298; - case ')': goto yy300; - case '>': goto yy207; - default: goto yy294; + case ' ': goto yy227; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy314; + case '\'': goto yy316; + case ')': goto yy318; + case '>': goto yy225; + default: goto yy312; } -yy296: +yy314: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy278; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy315; - case '\'': goto yy303; - case ')': goto yy313; - case '>': goto yy211; - default: goto yy296; + case ' ': goto yy296; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy333; + case '\'': goto yy321; + case ')': goto yy331; + case '>': goto yy229; + default: goto yy314; } -yy298: +yy316: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy230; - case '\n': goto yy201; - case '\r': goto yy202; - case '"': goto yy303; - case '\'': goto yy305; - case ')': goto yy301; - case '>': goto yy213; - default: goto yy298; + case ' ': goto yy248; + case '\n': goto yy219; + case '\r': goto yy220; + case '"': goto yy321; + case '\'': goto yy323; + case ')': goto yy319; + case '>': goto yy231; + default: goto yy316; } -yy300: +yy318: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy216; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy290; - case '\'': goto yy292; - case '(': goto yy294; - case '>': goto yy195; - default: goto yy193; + case ' ': goto yy234; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy308; + case '\'': goto yy310; + case '(': goto yy312; + case '>': goto yy213; + default: goto yy211; } -yy301: +yy319: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy274; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy311; - case '\'': goto yy301; - case '(': goto yy298; - case '>': goto yy205; - default: goto yy292; + case ' ': goto yy292; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy329; + case '\'': goto yy319; + case '(': goto yy316; + case '>': goto yy223; + default: goto yy310; } -yy303: +yy321: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy260; - case '\n': goto yy201; - case '\r': goto yy202; + case ' ': goto yy278; + case '\n': goto yy219; + case '\r': goto yy220; case '"': - case '\'': goto yy307; - case ')': goto yy309; - case '>': goto yy232; - default: goto yy303; + case '\'': goto yy325; + case ')': goto yy327; + case '>': goto yy250; + default: goto yy321; } -yy305: +yy323: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy236; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy303; - case '\'': goto yy305; - case ')': goto yy301; - case '>': goto yy213; - default: goto yy298; + case ' ': goto yy254; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy321; + case '\'': goto yy323; + case ')': goto yy319; + case '>': goto yy231; + default: goto yy316; } -yy307: +yy325: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy272; - case '\n': goto yy201; - case '\r': goto yy218; + case ' ': goto yy290; + case '\n': goto yy219; + case '\r': goto yy236; case '"': - case '\'': goto yy307; - case ')': goto yy309; - case '>': goto yy232; - default: goto yy303; + case '\'': goto yy325; + case ')': goto yy327; + case '>': goto yy250; + default: goto yy321; } -yy309: +yy327: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy264; - case '\n': goto yy201; - case '\r': goto yy218; + case ' ': goto yy282; + case '\n': goto yy219; + case '\r': goto yy236; case '"': - case '\'': goto yy309; - case '(': goto yy303; - case '>': goto yy266; - default: goto yy311; + case '\'': goto yy327; + case '(': goto yy321; + case '>': goto yy284; + default: goto yy329; } -yy311: +yy329: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy268; - case '\n': goto yy201; - case '\r': goto yy202; + case ' ': goto yy286; + case '\n': goto yy219; + case '\r': goto yy220; case '"': - case '\'': goto yy309; - case '(': goto yy303; - case '>': goto yy266; - default: goto yy311; + case '\'': goto yy327; + case '(': goto yy321; + case '>': goto yy284; + default: goto yy329; } -yy313: +yy331: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy284; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy313; - case '\'': goto yy311; - case '(': goto yy296; - case '>': goto yy203; - default: goto yy290; + case ' ': goto yy302; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy331; + case '\'': goto yy329; + case '(': goto yy314; + case '>': goto yy221; + default: goto yy308; } -yy315: +yy333: ++c; yych = *c; switch (yych) { - case 0x00: goto yy199; + case 0x00: goto yy217; case '\t': - case ' ': goto yy282; - case '\n': goto yy201; - case '\r': goto yy218; - case '"': goto yy315; - case '\'': goto yy303; - case ')': goto yy313; - case '>': goto yy211; - default: goto yy296; + case ' ': goto yy300; + case '\n': goto yy219; + case '\r': goto yy236; + case '"': goto yy333; + case '\'': goto yy321; + case ')': goto yy331; + case '>': goto yy229; + default: goto yy314; } -yy317: +yy335: yych = *++c; switch (yych) { - case ' ': goto yy319; - case '[': goto yy318; - default: goto yy186; + case ' ': goto yy337; + case '[': goto yy336; + default: goto yy204; } -yy318: +yy336: yych = *++c; switch (yych) { - case ']': goto yy186; - default: goto yy185; + case ']': goto yy204; + default: goto yy203; } -yy319: +yy337: ++c; switch ((yych = *c)) { - case '[': goto yy318; - default: goto yy186; + case '[': goto yy336; + default: goto yy204; } } @@ -4630,89 +4731,89 @@ size_t scan_ref_link(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy322; - case ' ': goto yy323; - case '[': goto yy324; - default: goto yy325; + case '\n': goto yy340; + case ' ': goto yy341; + case '[': goto yy342; + default: goto yy343; } -yy322: +yy340: { return 0; } -yy323: +yy341: yych = *(marker = ++c); switch (yych) { - case ' ': goto yy334; - case '[': goto yy335; - default: goto yy322; + case ' ': goto yy352; + case '[': goto yy353; + default: goto yy340; } -yy324: +yy342: yych = *(marker = ++c); switch (yych) { case 0x00: case '\n': case '\r': - case ']': goto yy322; - default: goto yy326; + case ']': goto yy340; + default: goto yy344; } -yy325: +yy343: yych = *++c; - goto yy322; -yy326: + goto yy340; +yy344: ++c; yych = *c; -yy327: +yy345: switch (yych) { case 0x00: case '\n': - case '\r': goto yy328; - case ']': goto yy329; - default: goto yy326; + case '\r': goto yy346; + case ']': goto yy347; + default: goto yy344; } -yy328: +yy346: c = marker; - goto yy322; -yy329: + goto yy340; +yy347: yych = *++c; switch (yych) { - case ':': goto yy330; - default: goto yy328; + case ':': goto yy348; + default: goto yy346; } -yy330: +yy348: yych = *++c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy328; - default: goto yy331; + case '\r': goto yy346; + default: goto yy349; } -yy331: +yy349: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy333; - default: goto yy331; + case '\r': goto yy351; + default: goto yy349; } -yy333: +yy351: { return (size_t)( c - start ); } -yy334: +yy352: yych = *++c; switch (yych) { - case ' ': goto yy336; - case '[': goto yy335; - default: goto yy328; + case ' ': goto yy354; + case '[': goto yy353; + default: goto yy346; } -yy335: +yy353: yych = *++c; switch (yych) { - case ']': goto yy328; - default: goto yy327; + case ']': goto yy346; + default: goto yy345; } -yy336: +yy354: ++c; switch ((yych = *c)) { - case '[': goto yy335; - default: goto yy328; + case '[': goto yy353; + default: goto yy346; } } @@ -4728,17 +4829,17 @@ size_t scan_html(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy339; - case '<': goto yy340; - default: goto yy341; + case '\n': goto yy357; + case '<': goto yy358; + default: goto yy359; } -yy339: +yy357: { return 0; } -yy340: +yy358: yych = *(marker = ++c); switch (yych) { - case '!': goto yy342; - case '/': goto yy344; + case '!': goto yy360; + case '/': goto yy362; case 'A': case 'B': case 'C': @@ -4790,22 +4891,22 @@ yy340: case 'w': case 'x': case 'y': - case 'z': goto yy345; - default: goto yy339; + case 'z': goto yy363; + default: goto yy357; } -yy341: +yy359: yych = *++c; - goto yy339; -yy342: + goto yy357; +yy360: yych = *++c; switch (yych) { - case '-': goto yy373; - default: goto yy343; + case '-': goto yy391; + default: goto yy361; } -yy343: +yy361: c = marker; - goto yy339; -yy344: + goto yy357; +yy362: yych = *++c; switch (yych) { case 'A': @@ -4859,17 +4960,17 @@ yy344: case 'w': case 'x': case 'y': - case 'z': goto yy369; - default: goto yy343; + case 'z': goto yy387; + default: goto yy361; } -yy345: +yy363: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy349; - case '\n': goto yy351; - case '\r': goto yy353; + case ' ': goto yy367; + case '\n': goto yy369; + case '\r': goto yy371; case '-': case '0': case '1': @@ -4880,11 +4981,11 @@ yy345: case '6': case '7': case '8': - case '9': goto yy345; - case '/': goto yy358; + case '9': goto yy363; + case '/': goto yy376; case ':': - case '_': goto yy354; - case '>': goto yy356; + case '_': goto yy372; + case '>': goto yy374; case 'A': case 'B': case 'C': @@ -4936,17 +5037,17 @@ yy345: case 'w': case 'x': case 'y': - case 'z': goto yy347; - default: goto yy343; + case 'z': goto yy365; + default: goto yy361; } -yy347: +yy365: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy349; - case '\n': goto yy351; - case '\r': goto yy353; + case ' ': goto yy367; + case '\n': goto yy369; + case '\r': goto yy371; case '-': case '0': case '1': @@ -5009,24 +5110,24 @@ yy347: case 'w': case 'x': case 'y': - case 'z': goto yy347; + case 'z': goto yy365; case '.': case ':': - case '_': goto yy354; - case '/': goto yy358; - case '=': goto yy359; - case '>': goto yy356; - default: goto yy343; + case '_': goto yy372; + case '/': goto yy376; + case '=': goto yy377; + case '>': goto yy374; + default: goto yy361; } -yy349: +yy367: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy349; - case '\n': goto yy351; - case '\r': goto yy353; - case '/': goto yy358; + case ' ': goto yy367; + case '\n': goto yy369; + case '\r': goto yy371; + case '/': goto yy376; case ':': case 'A': case 'B': @@ -5080,16 +5181,16 @@ yy349: case 'w': case 'x': case 'y': - case 'z': goto yy354; - case '>': goto yy356; - default: goto yy343; + case 'z': goto yy372; + case '>': goto yy374; + default: goto yy361; } -yy351: +yy369: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy351; + case ' ': goto yy369; case ':': case 'A': case 'B': @@ -5143,16 +5244,16 @@ yy351: case 'w': case 'x': case 'y': - case 'z': goto yy354; - default: goto yy343; + case 'z': goto yy372; + default: goto yy361; } -yy353: +yy371: ++c; yych = *c; switch (yych) { case '\t': case '\n': - case ' ': goto yy351; + case ' ': goto yy369; case ':': case 'A': case 'B': @@ -5206,10 +5307,10 @@ yy353: case 'w': case 'x': case 'y': - case 'z': goto yy354; - default: goto yy343; + case 'z': goto yy372; + default: goto yy361; } -yy354: +yy372: ++c; yych = *c; switch (yych) { @@ -5278,27 +5379,27 @@ yy354: case 'w': case 'x': case 'y': - case 'z': goto yy354; - case '=': goto yy359; - default: goto yy343; + case 'z': goto yy372; + case '=': goto yy377; + default: goto yy361; } -yy356: +yy374: ++c; { return (size_t)( c - start ); } -yy358: +yy376: yych = *++c; switch (yych) { - case '>': goto yy356; - default: goto yy343; + case '>': goto yy374; + default: goto yy361; } -yy359: +yy377: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy359; - case '"': goto yy361; - case '\'': goto yy363; + case ' ': goto yy377; + case '"': goto yy379; + case '\'': goto yy381; case '.': case '0': case '1': @@ -5361,37 +5462,37 @@ yy359: case 'w': case 'x': case 'y': - case 'z': goto yy365; - default: goto yy343; + case 'z': goto yy383; + default: goto yy361; } -yy361: +yy379: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy343; - case '"': goto yy349; - default: goto yy361; + case '\r': goto yy361; + case '"': goto yy367; + default: goto yy379; } -yy363: +yy381: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy343; - case '\'': goto yy349; - default: goto yy363; + case '\r': goto yy361; + case '\'': goto yy367; + default: goto yy381; } -yy365: +yy383: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy349; - case '\n': goto yy351; - case '\r': goto yy353; + case ' ': goto yy367; + case '\n': goto yy369; + case '\r': goto yy371; case '.': case '0': case '1': @@ -5402,11 +5503,11 @@ yy365: case '6': case '7': case '8': - case '9': goto yy365; - case '/': goto yy358; + case '9': goto yy383; + case '/': goto yy376; case ':': - case '_': goto yy354; - case '>': goto yy356; + case '_': goto yy372; + case '>': goto yy374; case 'A': case 'B': case 'C': @@ -5458,20 +5559,20 @@ yy365: case 'w': case 'x': case 'y': - case 'z': goto yy367; - default: goto yy343; + case 'z': goto yy385; + default: goto yy361; } -yy367: +yy385: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy349; - case '\n': goto yy351; - case '\r': goto yy353; + case ' ': goto yy367; + case '\n': goto yy369; + case '\r': goto yy371; case '-': case ':': - case '_': goto yy354; + case '_': goto yy372; case '.': case '0': case '1': @@ -5534,18 +5635,18 @@ yy367: case 'w': case 'x': case 'y': - case 'z': goto yy367; - case '/': goto yy358; - case '=': goto yy359; - case '>': goto yy356; - default: goto yy343; + case 'z': goto yy385; + case '/': goto yy376; + case '=': goto yy377; + case '>': goto yy374; + default: goto yy361; } -yy369: +yy387: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy371; + case ' ': goto yy389; case '-': case '0': case '1': @@ -5608,58 +5709,58 @@ yy369: case 'w': case 'x': case 'y': - case 'z': goto yy369; - case '>': goto yy356; - default: goto yy343; + case 'z': goto yy387; + case '>': goto yy374; + default: goto yy361; } -yy371: +yy389: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy371; - case '>': goto yy356; - default: goto yy343; + case ' ': goto yy389; + case '>': goto yy374; + default: goto yy361; } -yy373: +yy391: yych = *++c; switch (yych) { - case '-': goto yy374; - default: goto yy343; + case '-': goto yy392; + default: goto yy361; } -yy374: +yy392: yych = *++c; switch (yych) { - case '-': goto yy343; - default: goto yy376; + case '-': goto yy361; + default: goto yy394; } -yy375: +yy393: ++c; yych = *c; -yy376: +yy394: switch (yych) { case 0x00: - case '>': goto yy343; - case '-': goto yy377; - default: goto yy375; + case '>': goto yy361; + case '-': goto yy395; + default: goto yy393; } -yy377: +yy395: ++c; yych = *c; switch (yych) { case 0x00: - case '>': goto yy343; - case '-': goto yy378; - default: goto yy375; + case '>': goto yy361; + case '-': goto yy396; + default: goto yy393; } -yy378: +yy396: ++c; yych = *c; switch (yych) { - case 0x00: goto yy343; - case '-': goto yy378; - case '>': goto yy356; - default: goto yy375; + case 0x00: goto yy361; + case '-': goto yy396; + case '>': goto yy374; + default: goto yy393; } } @@ -5675,71 +5776,71 @@ size_t scan_html_comment(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy382; - case '<': goto yy383; - default: goto yy384; + case '\n': goto yy400; + case '<': goto yy401; + default: goto yy402; } -yy382: +yy400: { return 0; } -yy383: +yy401: yych = *(marker = ++c); switch (yych) { - case '!': goto yy385; - default: goto yy382; + case '!': goto yy403; + default: goto yy400; } -yy384: +yy402: yych = *++c; - goto yy382; -yy385: + goto yy400; +yy403: yych = *++c; switch (yych) { - case '-': goto yy387; - default: goto yy386; + case '-': goto yy405; + default: goto yy404; } -yy386: +yy404: c = marker; - goto yy382; -yy387: + goto yy400; +yy405: yych = *++c; switch (yych) { - case '-': goto yy388; - default: goto yy386; + case '-': goto yy406; + default: goto yy404; } -yy388: +yy406: yych = *++c; switch (yych) { - case '-': goto yy386; - default: goto yy390; + case '-': goto yy404; + default: goto yy408; } -yy389: +yy407: ++c; yych = *c; -yy390: +yy408: switch (yych) { case 0x00: - case '>': goto yy386; - case '-': goto yy391; - default: goto yy389; + case '>': goto yy404; + case '-': goto yy409; + default: goto yy407; } -yy391: +yy409: ++c; yych = *c; switch (yych) { case 0x00: - case '>': goto yy386; - case '-': goto yy392; - default: goto yy389; + case '>': goto yy404; + case '-': goto yy410; + default: goto yy407; } -yy392: +yy410: ++c; yych = *c; switch (yych) { - case 0x00: goto yy386; - case '-': goto yy392; - case '>': goto yy394; - default: goto yy389; + case 0x00: goto yy404; + case '-': goto yy410; + case '>': goto yy412; + default: goto yy407; } -yy394: +yy412: ++c; { return (size_t)( c - start ); } } @@ -5756,130 +5857,130 @@ size_t scan_html_block(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy398; - case '<': goto yy399; - default: goto yy400; + case '\n': goto yy416; + case '<': goto yy417; + default: goto yy418; } -yy398: +yy416: { return 0; } -yy399: +yy417: yych = *(marker = ++c); switch (yych) { - case '/': goto yy401; + case '/': goto yy419; case 'A': - case 'a': goto yy404; + case 'a': goto yy422; case 'B': - case 'b': goto yy405; + case 'b': goto yy423; case 'C': - case 'c': goto yy406; + case 'c': goto yy424; case 'D': - case 'd': goto yy407; + case 'd': goto yy425; case 'F': - case 'f': goto yy408; + case 'f': goto yy426; case 'H': - case 'h': goto yy409; + case 'h': goto yy427; case 'I': - case 'i': goto yy410; + case 'i': goto yy428; case 'L': - case 'l': goto yy411; + case 'l': goto yy429; case 'M': - case 'm': goto yy412; + case 'm': goto yy430; case 'N': - case 'n': goto yy413; + case 'n': goto yy431; case 'O': - case 'o': goto yy414; + case 'o': goto yy432; case 'P': - case 'p': goto yy403; + case 'p': goto yy421; case 'S': - case 's': goto yy415; + case 's': goto yy433; case 'T': - case 't': goto yy416; + case 't': goto yy434; case 'U': - case 'u': goto yy417; + case 'u': goto yy435; case 'V': - case 'v': goto yy418; - default: goto yy398; + case 'v': goto yy436; + default: goto yy416; } -yy400: +yy418: yych = *++c; - goto yy398; -yy401: + goto yy416; +yy419: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy404; + case 'a': goto yy422; case 'B': - case 'b': goto yy405; + case 'b': goto yy423; case 'C': - case 'c': goto yy406; + case 'c': goto yy424; case 'D': - case 'd': goto yy407; + case 'd': goto yy425; case 'F': - case 'f': goto yy408; + case 'f': goto yy426; case 'H': - case 'h': goto yy409; + case 'h': goto yy427; case 'I': - case 'i': goto yy410; + case 'i': goto yy428; case 'L': - case 'l': goto yy411; + case 'l': goto yy429; case 'M': - case 'm': goto yy412; + case 'm': goto yy430; case 'N': - case 'n': goto yy413; + case 'n': goto yy431; case 'O': - case 'o': goto yy414; + case 'o': goto yy432; case 'P': - case 'p': goto yy403; + case 'p': goto yy421; case 'S': - case 's': goto yy415; + case 's': goto yy433; case 'T': - case 't': goto yy416; + case 't': goto yy434; case 'U': - case 'u': goto yy417; + case 'u': goto yy435; case 'V': - case 'v': goto yy418; - default: goto yy402; + case 'v': goto yy436; + default: goto yy420; } -yy402: +yy420: c = marker; - goto yy398; -yy403: + goto yy416; +yy421: yych = *++c; switch (yych) { - case '/': goto yy430; - case '>': goto yy431; + case '/': goto yy448; + case '>': goto yy449; case 'R': - case 'r': goto yy550; - default: goto yy424; + case 'r': goto yy568; + default: goto yy442; } -yy404: +yy422: yych = *++c; switch (yych) { case 'D': - case 'd': goto yy539; + case 'd': goto yy557; case 'R': - case 'r': goto yy538; + case 'r': goto yy556; case 'S': - case 's': goto yy537; - default: goto yy402; + case 's': goto yy555; + default: goto yy420; } -yy405: +yy423: yych = *++c; switch (yych) { case 'L': - case 'l': goto yy529; - default: goto yy402; + case 'l': goto yy547; + default: goto yy420; } -yy406: +yy424: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy522; + case 'a': goto yy540; case 'E': - case 'e': goto yy521; - default: goto yy402; + case 'e': goto yy539; + default: goto yy420; } -yy407: +yy425: yych = *++c; switch (yych) { case 'D': @@ -5887,23 +5988,23 @@ yy407: case 'T': case 'd': case 'l': - case 't': goto yy422; + case 't': goto yy440; case 'I': - case 'i': goto yy520; - default: goto yy402; + case 'i': goto yy538; + default: goto yy420; } -yy408: +yy426: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy496; + case 'i': goto yy514; case 'O': - case 'o': goto yy495; + case 'o': goto yy513; case 'R': - case 'r': goto yy494; - default: goto yy402; + case 'r': goto yy512; + default: goto yy420; } -yy409: +yy427: yych = *++c; switch (yych) { case '1': @@ -5913,122 +6014,122 @@ yy409: case '5': case '6': case 'R': - case 'r': goto yy422; + case 'r': goto yy440; case 'E': - case 'e': goto yy487; + case 'e': goto yy505; case 'G': - case 'g': goto yy486; - default: goto yy402; + case 'g': goto yy504; + default: goto yy420; } -yy410: +yy428: yych = *++c; switch (yych) { case 'S': - case 's': goto yy481; - default: goto yy402; + case 's': goto yy499; + default: goto yy420; } -yy411: +yy429: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy422; - default: goto yy402; + case 'i': goto yy440; + default: goto yy420; } -yy412: +yy430: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy478; + case 'a': goto yy496; case 'E': - case 'e': goto yy477; - default: goto yy402; + case 'e': goto yy495; + default: goto yy420; } -yy413: +yy431: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy466; + case 'a': goto yy484; case 'O': - case 'o': goto yy465; - default: goto yy402; + case 'o': goto yy483; + default: goto yy420; } -yy414: +yy432: yych = *++c; switch (yych) { case 'L': - case 'l': goto yy422; + case 'l': goto yy440; case 'U': - case 'u': goto yy461; - default: goto yy402; + case 'u': goto yy479; + default: goto yy420; } -yy415: +yy433: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy456; - default: goto yy402; + case 'e': goto yy474; + default: goto yy420; } -yy416: +yy434: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy446; + case 'a': goto yy464; case 'B': - case 'b': goto yy445; + case 'b': goto yy463; case 'D': case 'R': case 'd': - case 'r': goto yy422; + case 'r': goto yy440; case 'F': - case 'f': goto yy444; + case 'f': goto yy462; case 'H': - case 'h': goto yy443; - default: goto yy402; + case 'h': goto yy461; + default: goto yy420; } -yy417: +yy435: yych = *++c; switch (yych) { case 'L': - case 'l': goto yy422; - default: goto yy402; + case 'l': goto yy440; + default: goto yy420; } -yy418: +yy436: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy419; - default: goto yy402; + case 'i': goto yy437; + default: goto yy420; } -yy419: +yy437: yych = *++c; switch (yych) { case 'D': - case 'd': goto yy420; - default: goto yy402; + case 'd': goto yy438; + default: goto yy420; } -yy420: +yy438: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy421; - default: goto yy402; + case 'e': goto yy439; + default: goto yy420; } -yy421: +yy439: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy422; - default: goto yy402; + case 'o': goto yy440; + default: goto yy420; } -yy422: +yy440: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy423; - case '\n': goto yy425; - case '\r': goto yy427; - case '/': goto yy430; + case ' ': goto yy441; + case '\n': goto yy443; + case '\r': goto yy445; + case '/': goto yy448; case ':': case 'A': case 'B': @@ -6082,19 +6183,19 @@ yy422: case 'w': case 'x': case 'y': - case 'z': goto yy428; - case '>': goto yy431; - default: goto yy402; + case 'z': goto yy446; + case '>': goto yy449; + default: goto yy420; } -yy423: +yy441: ++c; yych = *c; -yy424: +yy442: switch (yych) { case '\t': - case ' ': goto yy423; - case '\n': goto yy425; - case '\r': goto yy427; + case ' ': goto yy441; + case '\n': goto yy443; + case '\r': goto yy445; case ':': case 'A': case 'B': @@ -6148,15 +6249,15 @@ yy424: case 'w': case 'x': case 'y': - case 'z': goto yy428; - default: goto yy402; + case 'z': goto yy446; + default: goto yy420; } -yy425: +yy443: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy425; + case ' ': goto yy443; case ':': case 'A': case 'B': @@ -6210,16 +6311,16 @@ yy425: case 'w': case 'x': case 'y': - case 'z': goto yy428; - default: goto yy402; + case 'z': goto yy446; + default: goto yy420; } -yy427: +yy445: ++c; yych = *c; switch (yych) { case '\t': case '\n': - case ' ': goto yy425; + case ' ': goto yy443; case ':': case 'A': case 'B': @@ -6273,13 +6374,13 @@ yy427: case 'w': case 'x': case 'y': - case 'z': goto yy428; - default: goto yy402; + case 'z': goto yy446; + default: goto yy420; } -yy428: +yy446: ++c; yych = *c; -yy429: +yy447: switch (yych) { case '-': case '.': @@ -6346,27 +6447,27 @@ yy429: case 'w': case 'x': case 'y': - case 'z': goto yy428; - case '=': goto yy433; - default: goto yy402; + case 'z': goto yy446; + case '=': goto yy451; + default: goto yy420; } -yy430: +yy448: yych = *++c; switch (yych) { - case '>': goto yy431; - default: goto yy402; + case '>': goto yy449; + default: goto yy420; } -yy431: +yy449: ++c; { return (size_t)( c - start ); } -yy433: +yy451: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy433; - case '"': goto yy435; - case '\'': goto yy437; + case ' ': goto yy451; + case '"': goto yy453; + case '\'': goto yy455; case '.': case '0': case '1': @@ -6429,37 +6530,37 @@ yy433: case 'w': case 'x': case 'y': - case 'z': goto yy439; - default: goto yy402; + case 'z': goto yy457; + default: goto yy420; } -yy435: +yy453: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy402; - case '"': goto yy422; - default: goto yy435; + case '\r': goto yy420; + case '"': goto yy440; + default: goto yy453; } -yy437: +yy455: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy402; - case '\'': goto yy422; - default: goto yy437; + case '\r': goto yy420; + case '\'': goto yy440; + default: goto yy455; } -yy439: +yy457: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy423; - case '\n': goto yy425; - case '\r': goto yy427; + case ' ': goto yy441; + case '\n': goto yy443; + case '\r': goto yy445; case '.': case '0': case '1': @@ -6470,11 +6571,11 @@ yy439: case '6': case '7': case '8': - case '9': goto yy439; - case '/': goto yy430; + case '9': goto yy457; + case '/': goto yy448; case ':': - case '_': goto yy428; - case '>': goto yy431; + case '_': goto yy446; + case '>': goto yy449; case 'A': case 'B': case 'C': @@ -6526,20 +6627,20 @@ yy439: case 'w': case 'x': case 'y': - case 'z': goto yy441; - default: goto yy402; + case 'z': goto yy459; + default: goto yy420; } -yy441: +yy459: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy423; - case '\n': goto yy425; - case '\r': goto yy427; + case ' ': goto yy441; + case '\n': goto yy443; + case '\r': goto yy445; case '-': case ':': - case '_': goto yy428; + case '_': goto yy446; case '.': case '0': case '1': @@ -6602,99 +6703,99 @@ yy441: case 'w': case 'x': case 'y': - case 'z': goto yy441; - case '/': goto yy430; - case '=': goto yy433; - case '>': goto yy431; - default: goto yy402; + case 'z': goto yy459; + case '/': goto yy448; + case '=': goto yy451; + case '>': goto yy449; + default: goto yy420; } -yy443: +yy461: yych = *++c; switch (yych) { - case '/': goto yy430; - case '>': goto yy431; + case '/': goto yy448; + case '>': goto yy449; case 'E': - case 'e': goto yy453; - default: goto yy424; + case 'e': goto yy471; + default: goto yy442; } -yy444: +yy462: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy451; - default: goto yy402; + case 'o': goto yy469; + default: goto yy420; } -yy445: +yy463: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy449; - default: goto yy402; + case 'o': goto yy467; + default: goto yy420; } -yy446: +yy464: yych = *++c; switch (yych) { case 'B': - case 'b': goto yy447; - default: goto yy402; + case 'b': goto yy465; + default: goto yy420; } -yy447: +yy465: yych = *++c; switch (yych) { case 'L': - case 'l': goto yy448; - default: goto yy402; + case 'l': goto yy466; + default: goto yy420; } -yy448: +yy466: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy422; - default: goto yy402; + case 'e': goto yy440; + default: goto yy420; } -yy449: +yy467: yych = *++c; switch (yych) { case 'D': - case 'd': goto yy450; - default: goto yy402; + case 'd': goto yy468; + default: goto yy420; } -yy450: +yy468: yych = *++c; switch (yych) { case 'Y': - case 'y': goto yy422; - default: goto yy402; + case 'y': goto yy440; + default: goto yy420; } -yy451: +yy469: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy452; - default: goto yy402; + case 'o': goto yy470; + default: goto yy420; } -yy452: +yy470: yych = *++c; switch (yych) { case 'T': - case 't': goto yy422; - default: goto yy402; + case 't': goto yy440; + default: goto yy420; } -yy453: +yy471: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy454; - default: goto yy429; + case 'a': goto yy472; + default: goto yy447; } -yy454: +yy472: yych = *++c; switch (yych) { case 'D': - case 'd': goto yy455; - default: goto yy429; + case 'd': goto yy473; + default: goto yy447; } -yy455: +yy473: yych = *++c; switch (yych) { case '-': @@ -6708,686 +6809,686 @@ yy455: case '6': case '7': case '8': - case '9': goto yy428; - case '/': goto yy430; - case '=': goto yy433; - case '>': goto yy431; - default: goto yy424; + case '9': goto yy446; + case '/': goto yy448; + case '=': goto yy451; + case '>': goto yy449; + default: goto yy442; } -yy456: +yy474: yych = *++c; switch (yych) { case 'C': - case 'c': goto yy457; - default: goto yy402; + case 'c': goto yy475; + default: goto yy420; } -yy457: +yy475: yych = *++c; switch (yych) { case 'T': - case 't': goto yy458; - default: goto yy402; + case 't': goto yy476; + default: goto yy420; } -yy458: +yy476: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy459; - default: goto yy402; + case 'i': goto yy477; + default: goto yy420; } -yy459: +yy477: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy460; - default: goto yy402; + case 'o': goto yy478; + default: goto yy420; } -yy460: +yy478: yych = *++c; switch (yych) { case 'N': - case 'n': goto yy422; - default: goto yy402; + case 'n': goto yy440; + default: goto yy420; } -yy461: +yy479: yych = *++c; switch (yych) { case 'T': - case 't': goto yy462; - default: goto yy402; + case 't': goto yy480; + default: goto yy420; } -yy462: +yy480: yych = *++c; switch (yych) { case 'P': - case 'p': goto yy463; - default: goto yy402; + case 'p': goto yy481; + default: goto yy420; } -yy463: +yy481: yych = *++c; switch (yych) { case 'U': - case 'u': goto yy464; - default: goto yy402; + case 'u': goto yy482; + default: goto yy420; } -yy464: +yy482: yych = *++c; switch (yych) { case 'T': - case 't': goto yy422; - default: goto yy402; + case 't': goto yy440; + default: goto yy420; } -yy465: +yy483: yych = *++c; switch (yych) { case 'F': - case 'f': goto yy467; + case 'f': goto yy485; case 'S': - case 's': goto yy468; - default: goto yy402; + case 's': goto yy486; + default: goto yy420; } -yy466: +yy484: yych = *++c; switch (yych) { case 'V': - case 'v': goto yy422; - default: goto yy402; + case 'v': goto yy440; + default: goto yy420; } -yy467: +yy485: yych = *++c; switch (yych) { case 'R': - case 'r': goto yy473; - default: goto yy402; + case 'r': goto yy491; + default: goto yy420; } -yy468: +yy486: yych = *++c; switch (yych) { case 'C': - case 'c': goto yy469; - default: goto yy402; + case 'c': goto yy487; + default: goto yy420; } -yy469: +yy487: yych = *++c; switch (yych) { case 'R': - case 'r': goto yy470; - default: goto yy402; + case 'r': goto yy488; + default: goto yy420; } -yy470: +yy488: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy471; - default: goto yy402; + case 'i': goto yy489; + default: goto yy420; } -yy471: +yy489: yych = *++c; switch (yych) { case 'P': - case 'p': goto yy472; - default: goto yy402; + case 'p': goto yy490; + default: goto yy420; } -yy472: +yy490: yych = *++c; switch (yych) { case 'T': - case 't': goto yy422; - default: goto yy402; + case 't': goto yy440; + default: goto yy420; } -yy473: +yy491: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy474; - default: goto yy402; + case 'a': goto yy492; + default: goto yy420; } -yy474: +yy492: yych = *++c; switch (yych) { case 'M': - case 'm': goto yy475; - default: goto yy402; + case 'm': goto yy493; + default: goto yy420; } -yy475: +yy493: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy476; - default: goto yy402; + case 'e': goto yy494; + default: goto yy420; } -yy476: +yy494: yych = *++c; switch (yych) { case 'S': - case 's': goto yy422; - default: goto yy402; + case 's': goto yy440; + default: goto yy420; } -yy477: +yy495: yych = *++c; switch (yych) { case 'N': - case 'n': goto yy480; - default: goto yy402; + case 'n': goto yy498; + default: goto yy420; } -yy478: +yy496: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy479; - default: goto yy402; + case 'i': goto yy497; + default: goto yy420; } -yy479: +yy497: yych = *++c; switch (yych) { case 'N': - case 'n': goto yy422; - default: goto yy402; + case 'n': goto yy440; + default: goto yy420; } -yy480: +yy498: yych = *++c; switch (yych) { case 'U': - case 'u': goto yy422; - default: goto yy402; + case 'u': goto yy440; + default: goto yy420; } -yy481: +yy499: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy482; - default: goto yy402; + case 'i': goto yy500; + default: goto yy420; } -yy482: +yy500: yych = *++c; switch (yych) { case 'N': - case 'n': goto yy483; - default: goto yy402; + case 'n': goto yy501; + default: goto yy420; } -yy483: +yy501: yych = *++c; switch (yych) { case 'D': - case 'd': goto yy484; - default: goto yy402; + case 'd': goto yy502; + default: goto yy420; } -yy484: +yy502: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy485; - default: goto yy402; + case 'e': goto yy503; + default: goto yy420; } -yy485: +yy503: yych = *++c; switch (yych) { case 'X': - case 'x': goto yy422; - default: goto yy402; + case 'x': goto yy440; + default: goto yy420; } -yy486: +yy504: yych = *++c; switch (yych) { case 'R': - case 'r': goto yy491; - default: goto yy402; + case 'r': goto yy509; + default: goto yy420; } -yy487: +yy505: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy488; - default: goto yy402; + case 'a': goto yy506; + default: goto yy420; } -yy488: +yy506: yych = *++c; switch (yych) { case 'D': - case 'd': goto yy489; - default: goto yy402; + case 'd': goto yy507; + default: goto yy420; } -yy489: +yy507: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy490; - default: goto yy402; + case 'e': goto yy508; + default: goto yy420; } -yy490: +yy508: yych = *++c; switch (yych) { case 'R': - case 'r': goto yy422; - default: goto yy402; + case 'r': goto yy440; + default: goto yy420; } -yy491: +yy509: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy492; - default: goto yy402; + case 'o': goto yy510; + default: goto yy420; } -yy492: +yy510: yych = *++c; switch (yych) { case 'U': - case 'u': goto yy493; - default: goto yy402; + case 'u': goto yy511; + default: goto yy420; } -yy493: +yy511: yych = *++c; switch (yych) { case 'P': - case 'p': goto yy422; - default: goto yy402; + case 'p': goto yy440; + default: goto yy420; } -yy494: +yy512: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy515; - default: goto yy402; + case 'a': goto yy533; + default: goto yy420; } -yy495: +yy513: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy511; + case 'o': goto yy529; case 'R': - case 'r': goto yy512; - default: goto yy402; + case 'r': goto yy530; + default: goto yy420; } -yy496: +yy514: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy497; + case 'e': goto yy515; case 'G': - case 'g': goto yy498; - default: goto yy402; + case 'g': goto yy516; + default: goto yy420; } -yy497: +yy515: yych = *++c; switch (yych) { case 'L': - case 'l': goto yy507; - default: goto yy402; + case 'l': goto yy525; + default: goto yy420; } -yy498: +yy516: yych = *++c; switch (yych) { case 'C': - case 'c': goto yy500; + case 'c': goto yy518; case 'U': - case 'u': goto yy499; - default: goto yy402; + case 'u': goto yy517; + default: goto yy420; } -yy499: +yy517: yych = *++c; switch (yych) { case 'R': - case 'r': goto yy506; - default: goto yy402; + case 'r': goto yy524; + default: goto yy420; } -yy500: +yy518: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy501; - default: goto yy402; + case 'a': goto yy519; + default: goto yy420; } -yy501: +yy519: yych = *++c; switch (yych) { case 'P': - case 'p': goto yy502; - default: goto yy402; + case 'p': goto yy520; + default: goto yy420; } -yy502: +yy520: yych = *++c; switch (yych) { case 'T': - case 't': goto yy503; - default: goto yy402; + case 't': goto yy521; + default: goto yy420; } -yy503: +yy521: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy504; - default: goto yy402; + case 'i': goto yy522; + default: goto yy420; } -yy504: +yy522: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy505; - default: goto yy402; + case 'o': goto yy523; + default: goto yy420; } -yy505: +yy523: yych = *++c; switch (yych) { case 'N': - case 'n': goto yy422; - default: goto yy402; + case 'n': goto yy440; + default: goto yy420; } -yy506: +yy524: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy422; - default: goto yy402; + case 'e': goto yy440; + default: goto yy420; } -yy507: +yy525: yych = *++c; switch (yych) { case 'D': - case 'd': goto yy508; - default: goto yy402; + case 'd': goto yy526; + default: goto yy420; } -yy508: +yy526: yych = *++c; switch (yych) { case 'S': - case 's': goto yy509; - default: goto yy402; + case 's': goto yy527; + default: goto yy420; } -yy509: +yy527: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy510; - default: goto yy402; + case 'e': goto yy528; + default: goto yy420; } -yy510: +yy528: yych = *++c; switch (yych) { case 'T': - case 't': goto yy422; - default: goto yy402; + case 't': goto yy440; + default: goto yy420; } -yy511: +yy529: yych = *++c; switch (yych) { case 'T': - case 't': goto yy513; - default: goto yy402; + case 't': goto yy531; + default: goto yy420; } -yy512: +yy530: yych = *++c; switch (yych) { case 'M': - case 'm': goto yy422; - default: goto yy402; + case 'm': goto yy440; + default: goto yy420; } -yy513: +yy531: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy514; - default: goto yy402; + case 'e': goto yy532; + default: goto yy420; } -yy514: +yy532: yych = *++c; switch (yych) { case 'R': - case 'r': goto yy422; - default: goto yy402; + case 'r': goto yy440; + default: goto yy420; } -yy515: +yy533: yych = *++c; switch (yych) { case 'M': - case 'm': goto yy516; - default: goto yy402; + case 'm': goto yy534; + default: goto yy420; } -yy516: +yy534: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy517; - default: goto yy402; + case 'e': goto yy535; + default: goto yy420; } -yy517: +yy535: yych = *++c; switch (yych) { case 'S': - case 's': goto yy518; - default: goto yy402; + case 's': goto yy536; + default: goto yy420; } -yy518: +yy536: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy519; - default: goto yy402; + case 'e': goto yy537; + default: goto yy420; } -yy519: +yy537: yych = *++c; switch (yych) { case 'T': - case 't': goto yy422; - default: goto yy402; + case 't': goto yy440; + default: goto yy420; } -yy520: +yy538: yych = *++c; switch (yych) { case 'R': case 'V': case 'r': - case 'v': goto yy422; - default: goto yy402; + case 'v': goto yy440; + default: goto yy420; } -yy521: +yy539: yych = *++c; switch (yych) { case 'N': - case 'n': goto yy526; - default: goto yy402; + case 'n': goto yy544; + default: goto yy420; } -yy522: +yy540: yych = *++c; switch (yych) { case 'N': - case 'n': goto yy523; - default: goto yy402; + case 'n': goto yy541; + default: goto yy420; } -yy523: +yy541: yych = *++c; switch (yych) { case 'V': - case 'v': goto yy524; - default: goto yy402; + case 'v': goto yy542; + default: goto yy420; } -yy524: +yy542: yych = *++c; switch (yych) { case 'A': - case 'a': goto yy525; - default: goto yy402; + case 'a': goto yy543; + default: goto yy420; } -yy525: +yy543: yych = *++c; switch (yych) { case 'S': - case 's': goto yy422; - default: goto yy402; + case 's': goto yy440; + default: goto yy420; } -yy526: +yy544: yych = *++c; switch (yych) { case 'T': - case 't': goto yy527; - default: goto yy402; + case 't': goto yy545; + default: goto yy420; } -yy527: +yy545: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy528; - default: goto yy402; + case 'e': goto yy546; + default: goto yy420; } -yy528: +yy546: yych = *++c; switch (yych) { case 'R': - case 'r': goto yy422; - default: goto yy402; + case 'r': goto yy440; + default: goto yy420; } -yy529: +yy547: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy530; - default: goto yy402; + case 'o': goto yy548; + default: goto yy420; } -yy530: +yy548: yych = *++c; switch (yych) { case 'C': - case 'c': goto yy531; - default: goto yy402; + case 'c': goto yy549; + default: goto yy420; } -yy531: +yy549: yych = *++c; switch (yych) { case 'K': - case 'k': goto yy532; - default: goto yy402; + case 'k': goto yy550; + default: goto yy420; } -yy532: +yy550: yych = *++c; switch (yych) { case 'Q': - case 'q': goto yy533; - default: goto yy402; + case 'q': goto yy551; + default: goto yy420; } -yy533: +yy551: yych = *++c; switch (yych) { case 'U': - case 'u': goto yy534; - default: goto yy402; + case 'u': goto yy552; + default: goto yy420; } -yy534: +yy552: yych = *++c; switch (yych) { case 'O': - case 'o': goto yy535; - default: goto yy402; + case 'o': goto yy553; + default: goto yy420; } -yy535: +yy553: yych = *++c; switch (yych) { case 'T': - case 't': goto yy536; - default: goto yy402; + case 't': goto yy554; + default: goto yy420; } -yy536: +yy554: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy422; - default: goto yy402; + case 'e': goto yy440; + default: goto yy420; } -yy537: +yy555: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy548; - default: goto yy402; + case 'i': goto yy566; + default: goto yy420; } -yy538: +yy556: yych = *++c; switch (yych) { case 'T': - case 't': goto yy544; - default: goto yy402; + case 't': goto yy562; + default: goto yy420; } -yy539: +yy557: yych = *++c; switch (yych) { case 'D': - case 'd': goto yy540; - default: goto yy402; + case 'd': goto yy558; + default: goto yy420; } -yy540: +yy558: yych = *++c; switch (yych) { case 'R': - case 'r': goto yy541; - default: goto yy402; + case 'r': goto yy559; + default: goto yy420; } -yy541: +yy559: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy542; - default: goto yy402; + case 'e': goto yy560; + default: goto yy420; } -yy542: +yy560: yych = *++c; switch (yych) { case 'S': - case 's': goto yy543; - default: goto yy402; + case 's': goto yy561; + default: goto yy420; } -yy543: +yy561: yych = *++c; switch (yych) { case 'S': - case 's': goto yy422; - default: goto yy402; + case 's': goto yy440; + default: goto yy420; } -yy544: +yy562: yych = *++c; switch (yych) { case 'I': - case 'i': goto yy545; - default: goto yy402; + case 'i': goto yy563; + default: goto yy420; } -yy545: +yy563: yych = *++c; switch (yych) { case 'C': - case 'c': goto yy546; - default: goto yy402; + case 'c': goto yy564; + default: goto yy420; } -yy546: +yy564: yych = *++c; switch (yych) { case 'L': - case 'l': goto yy547; - default: goto yy402; + case 'l': goto yy565; + default: goto yy420; } -yy547: +yy565: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy422; - default: goto yy402; + case 'e': goto yy440; + default: goto yy420; } -yy548: +yy566: yych = *++c; switch (yych) { case 'D': - case 'd': goto yy549; - default: goto yy402; + case 'd': goto yy567; + default: goto yy420; } -yy549: +yy567: yych = *++c; switch (yych) { case 'E': - case 'e': goto yy422; - default: goto yy402; + case 'e': goto yy440; + default: goto yy420; } -yy550: +yy568: ++c; switch ((yych = *c)) { case 'E': - case 'e': goto yy455; - default: goto yy429; + case 'e': goto yy473; + default: goto yy447; } } @@ -7403,17 +7504,17 @@ size_t scan_html_line(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy553; - case '<': goto yy554; - default: goto yy555; + case '\n': goto yy571; + case '<': goto yy572; + default: goto yy573; } -yy553: +yy571: { return 0; } -yy554: +yy572: yych = *(marker = ++c); switch (yych) { - case '!': goto yy556; - case '/': goto yy558; + case '!': goto yy574; + case '/': goto yy576; case 'A': case 'B': case 'C': @@ -7465,22 +7566,22 @@ yy554: case 'w': case 'x': case 'y': - case 'z': goto yy559; - default: goto yy553; + case 'z': goto yy577; + default: goto yy571; } -yy555: +yy573: yych = *++c; - goto yy553; -yy556: + goto yy571; +yy574: yych = *++c; switch (yych) { - case '-': goto yy590; - default: goto yy557; + case '-': goto yy608; + default: goto yy575; } -yy557: +yy575: c = marker; - goto yy553; -yy558: + goto yy571; +yy576: yych = *++c; switch (yych) { case 'A': @@ -7534,17 +7635,17 @@ yy558: case 'w': case 'x': case 'y': - case 'z': goto yy586; - default: goto yy557; + case 'z': goto yy604; + default: goto yy575; } -yy559: +yy577: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy563; - case '\n': goto yy565; - case '\r': goto yy567; + case ' ': goto yy581; + case '\n': goto yy583; + case '\r': goto yy585; case '-': case '0': case '1': @@ -7555,11 +7656,11 @@ yy559: case '6': case '7': case '8': - case '9': goto yy559; - case '/': goto yy572; + case '9': goto yy577; + case '/': goto yy590; case ':': - case '_': goto yy568; - case '>': goto yy570; + case '_': goto yy586; + case '>': goto yy588; case 'A': case 'B': case 'C': @@ -7611,17 +7712,17 @@ yy559: case 'w': case 'x': case 'y': - case 'z': goto yy561; - default: goto yy557; + case 'z': goto yy579; + default: goto yy575; } -yy561: +yy579: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy563; - case '\n': goto yy565; - case '\r': goto yy567; + case ' ': goto yy581; + case '\n': goto yy583; + case '\r': goto yy585; case '-': case '0': case '1': @@ -7684,24 +7785,24 @@ yy561: case 'w': case 'x': case 'y': - case 'z': goto yy561; + case 'z': goto yy579; case '.': case ':': - case '_': goto yy568; - case '/': goto yy572; - case '=': goto yy576; - case '>': goto yy570; - default: goto yy557; + case '_': goto yy586; + case '/': goto yy590; + case '=': goto yy594; + case '>': goto yy588; + default: goto yy575; } -yy563: +yy581: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy563; - case '\n': goto yy565; - case '\r': goto yy567; - case '/': goto yy572; + case ' ': goto yy581; + case '\n': goto yy583; + case '\r': goto yy585; + case '/': goto yy590; case ':': case 'A': case 'B': @@ -7755,16 +7856,16 @@ yy563: case 'w': case 'x': case 'y': - case 'z': goto yy568; - case '>': goto yy570; - default: goto yy557; + case 'z': goto yy586; + case '>': goto yy588; + default: goto yy575; } -yy565: +yy583: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy565; + case ' ': goto yy583; case ':': case 'A': case 'B': @@ -7818,16 +7919,16 @@ yy565: case 'w': case 'x': case 'y': - case 'z': goto yy568; - default: goto yy557; + case 'z': goto yy586; + default: goto yy575; } -yy567: +yy585: ++c; yych = *c; switch (yych) { case '\t': case '\n': - case ' ': goto yy565; + case ' ': goto yy583; case ':': case 'A': case 'B': @@ -7881,10 +7982,10 @@ yy567: case 'w': case 'x': case 'y': - case 'z': goto yy568; - default: goto yy557; + case 'z': goto yy586; + default: goto yy575; } -yy568: +yy586: ++c; yych = *c; switch (yych) { @@ -7953,44 +8054,44 @@ yy568: case 'w': case 'x': case 'y': - case 'z': goto yy568; - case '=': goto yy576; - default: goto yy557; + case 'z': goto yy586; + case '=': goto yy594; + default: goto yy575; } -yy570: +yy588: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy570; - case '\n': goto yy573; - case '\r': goto yy575; - default: goto yy557; + case ' ': goto yy588; + case '\n': goto yy591; + case '\r': goto yy593; + default: goto yy575; } -yy572: +yy590: yych = *++c; switch (yych) { - case '>': goto yy570; - default: goto yy557; + case '>': goto yy588; + default: goto yy575; } -yy573: +yy591: ++c; -yy574: +yy592: { return (size_t)( c - start ); } -yy575: +yy593: yych = *++c; switch (yych) { - case '\n': goto yy573; - default: goto yy574; + case '\n': goto yy591; + default: goto yy592; } -yy576: +yy594: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy576; - case '"': goto yy578; - case '\'': goto yy580; + case ' ': goto yy594; + case '"': goto yy596; + case '\'': goto yy598; case '.': case '0': case '1': @@ -8053,37 +8154,37 @@ yy576: case 'w': case 'x': case 'y': - case 'z': goto yy582; - default: goto yy557; + case 'z': goto yy600; + default: goto yy575; } -yy578: +yy596: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy557; - case '"': goto yy563; - default: goto yy578; + case '\r': goto yy575; + case '"': goto yy581; + default: goto yy596; } -yy580: +yy598: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy557; - case '\'': goto yy563; - default: goto yy580; + case '\r': goto yy575; + case '\'': goto yy581; + default: goto yy598; } -yy582: +yy600: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy563; - case '\n': goto yy565; - case '\r': goto yy567; + case ' ': goto yy581; + case '\n': goto yy583; + case '\r': goto yy585; case '.': case '0': case '1': @@ -8094,11 +8195,11 @@ yy582: case '6': case '7': case '8': - case '9': goto yy582; - case '/': goto yy572; + case '9': goto yy600; + case '/': goto yy590; case ':': - case '_': goto yy568; - case '>': goto yy570; + case '_': goto yy586; + case '>': goto yy588; case 'A': case 'B': case 'C': @@ -8150,20 +8251,20 @@ yy582: case 'w': case 'x': case 'y': - case 'z': goto yy584; - default: goto yy557; + case 'z': goto yy602; + default: goto yy575; } -yy584: +yy602: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy563; - case '\n': goto yy565; - case '\r': goto yy567; + case ' ': goto yy581; + case '\n': goto yy583; + case '\r': goto yy585; case '-': case ':': - case '_': goto yy568; + case '_': goto yy586; case '.': case '0': case '1': @@ -8226,18 +8327,18 @@ yy584: case 'w': case 'x': case 'y': - case 'z': goto yy584; - case '/': goto yy572; - case '=': goto yy576; - case '>': goto yy570; - default: goto yy557; + case 'z': goto yy602; + case '/': goto yy590; + case '=': goto yy594; + case '>': goto yy588; + default: goto yy575; } -yy586: +yy604: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy588; + case ' ': goto yy606; case '-': case '0': case '1': @@ -8300,58 +8401,58 @@ yy586: case 'w': case 'x': case 'y': - case 'z': goto yy586; - case '>': goto yy570; - default: goto yy557; + case 'z': goto yy604; + case '>': goto yy588; + default: goto yy575; } -yy588: +yy606: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy588; - case '>': goto yy570; - default: goto yy557; + case ' ': goto yy606; + case '>': goto yy588; + default: goto yy575; } -yy590: +yy608: yych = *++c; switch (yych) { - case '-': goto yy591; - default: goto yy557; + case '-': goto yy609; + default: goto yy575; } -yy591: +yy609: yych = *++c; switch (yych) { - case '-': goto yy557; - default: goto yy593; + case '-': goto yy575; + default: goto yy611; } -yy592: +yy610: ++c; yych = *c; -yy593: +yy611: switch (yych) { case 0x00: - case '>': goto yy557; - case '-': goto yy594; - default: goto yy592; + case '>': goto yy575; + case '-': goto yy612; + default: goto yy610; } -yy594: +yy612: ++c; yych = *c; switch (yych) { case 0x00: - case '>': goto yy557; - case '-': goto yy595; - default: goto yy592; + case '>': goto yy575; + case '-': goto yy613; + default: goto yy610; } -yy595: +yy613: ++c; yych = *c; switch (yych) { - case 0x00: goto yy557; - case '-': goto yy595; - case '>': goto yy570; - default: goto yy592; + case 0x00: goto yy575; + case '-': goto yy613; + case '>': goto yy588; + default: goto yy610; } } @@ -8367,108 +8468,108 @@ size_t scan_fence_start(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy599; - case ' ': goto yy600; + case '\n': goto yy617; + case ' ': goto yy618; case '`': - case '~': goto yy601; - default: goto yy602; + case '~': goto yy619; + default: goto yy620; } -yy599: +yy617: { return 0; } -yy600: +yy618: yych = *(marker = ++c); switch (yych) { - case ' ': goto yy614; + case ' ': goto yy632; case '`': - case '~': goto yy615; - default: goto yy599; + case '~': goto yy633; + default: goto yy617; } -yy601: +yy619: yych = *(marker = ++c); switch (yych) { case '`': - case '~': goto yy603; - default: goto yy599; + case '~': goto yy621; + default: goto yy617; } -yy602: +yy620: yych = *++c; - goto yy599; -yy603: + goto yy617; +yy621: yych = *++c; switch (yych) { case '`': - case '~': goto yy605; - default: goto yy604; + case '~': goto yy623; + default: goto yy622; } -yy604: +yy622: c = marker; - goto yy599; -yy605: + goto yy617; +yy623: ++c; yych = *c; switch (yych) { case 0x00: case '\n': case '\r': - case '\'': goto yy604; - case '`': goto yy605; - case '~': goto yy609; - default: goto yy607; + case '\'': goto yy622; + case '`': goto yy623; + case '~': goto yy627; + default: goto yy625; } -yy607: +yy625: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy611; - case '\r': goto yy613; + case '\n': goto yy629; + case '\r': goto yy631; case '\'': - case '`': goto yy604; - default: goto yy607; + case '`': goto yy622; + default: goto yy625; } -yy609: +yy627: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy611; - case '\r': goto yy613; - case '\'': goto yy604; - case '`': goto yy605; - case '~': goto yy609; - default: goto yy607; + case '\n': goto yy629; + case '\r': goto yy631; + case '\'': goto yy622; + case '`': goto yy623; + case '~': goto yy627; + default: goto yy625; } -yy611: +yy629: ++c; -yy612: +yy630: { return (size_t)( c - start ); } -yy613: +yy631: yych = *++c; switch (yych) { - case '\n': goto yy611; - default: goto yy612; + case '\n': goto yy629; + default: goto yy630; } -yy614: +yy632: yych = *++c; switch (yych) { - case ' ': goto yy616; + case ' ': goto yy634; case '`': - case '~': goto yy615; - default: goto yy604; + case '~': goto yy633; + default: goto yy622; } -yy615: +yy633: yych = *++c; switch (yych) { case '`': - case '~': goto yy603; - default: goto yy604; + case '~': goto yy621; + default: goto yy622; } -yy616: +yy634: ++c; switch ((yych = *c)) { case '`': - case '~': goto yy615; - default: goto yy604; + case '~': goto yy633; + default: goto yy622; } } @@ -8484,97 +8585,97 @@ size_t scan_fence_end(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy619; - case ' ': goto yy620; + case '\n': goto yy637; + case ' ': goto yy638; case '`': - case '~': goto yy621; - default: goto yy622; + case '~': goto yy639; + default: goto yy640; } -yy619: +yy637: { return 0; } -yy620: +yy638: yych = *(marker = ++c); switch (yych) { - case ' ': goto yy632; + case ' ': goto yy650; case '`': - case '~': goto yy633; - default: goto yy619; + case '~': goto yy651; + default: goto yy637; } -yy621: +yy639: yych = *(marker = ++c); switch (yych) { case '`': - case '~': goto yy623; - default: goto yy619; + case '~': goto yy641; + default: goto yy637; } -yy622: +yy640: yych = *++c; - goto yy619; -yy623: + goto yy637; +yy641: yych = *++c; switch (yych) { case '`': - case '~': goto yy625; - default: goto yy624; + case '~': goto yy643; + default: goto yy642; } -yy624: +yy642: c = marker; - goto yy619; -yy625: + goto yy637; +yy643: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy629; + case '\n': goto yy647; case '\t': - case ' ': goto yy627; - case '\r': goto yy631; + case ' ': goto yy645; + case '\r': goto yy649; case '`': - case '~': goto yy625; - default: goto yy624; + case '~': goto yy643; + default: goto yy642; } -yy627: +yy645: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy629; + case '\n': goto yy647; case '\t': - case ' ': goto yy627; - case '\r': goto yy631; - default: goto yy624; + case ' ': goto yy645; + case '\r': goto yy649; + default: goto yy642; } -yy629: +yy647: ++c; -yy630: +yy648: { return (size_t)( c - start ); } -yy631: +yy649: yych = *++c; switch (yych) { - case '\n': goto yy629; - default: goto yy630; + case '\n': goto yy647; + default: goto yy648; } -yy632: +yy650: yych = *++c; switch (yych) { - case ' ': goto yy634; + case ' ': goto yy652; case '`': - case '~': goto yy633; - default: goto yy624; + case '~': goto yy651; + default: goto yy642; } -yy633: +yy651: yych = *++c; switch (yych) { case '`': - case '~': goto yy623; - default: goto yy624; + case '~': goto yy641; + default: goto yy642; } -yy634: +yy652: ++c; switch ((yych = *c)) { case '`': - case '~': goto yy633; - default: goto yy624; + case '~': goto yy651; + default: goto yy642; } } @@ -8590,7 +8691,7 @@ size_t scan_meta_line(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy637; + case '\n': goto yy655; case '0': case '1': case '2': @@ -8652,15 +8753,15 @@ size_t scan_meta_line(const char * c) { case 'w': case 'x': case 'y': - case 'z': goto yy638; - default: goto yy639; + case 'z': goto yy656; + default: goto yy657; } -yy637: +yy655: { return 0; } -yy638: +yy656: yych = *(marker = ++c); switch (yych) { - case '\t': goto yy643; + case '\t': goto yy661; case ' ': case '!': case '"': @@ -8738,18 +8839,18 @@ yy638: case 'w': case 'x': case 'y': - case 'z': goto yy640; - case ':': goto yy645; - default: goto yy637; + case 'z': goto yy658; + case ':': goto yy663; + default: goto yy655; } -yy639: +yy657: yych = *++c; - goto yy637; -yy640: + goto yy655; +yy658: ++c; yych = *c; switch (yych) { - case '\t': goto yy643; + case '\t': goto yy661; case ' ': case '!': case '"': @@ -8827,48 +8928,48 @@ yy640: case 'w': case 'x': case 'y': - case 'z': goto yy640; - case ':': goto yy645; - default: goto yy642; + case 'z': goto yy658; + case ':': goto yy663; + default: goto yy660; } -yy642: +yy660: c = marker; - goto yy637; -yy643: + goto yy655; +yy661: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy643; - case ':': goto yy645; - default: goto yy642; + case ' ': goto yy661; + case ':': goto yy663; + default: goto yy660; } -yy645: +yy663: yych = *++c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy642; - default: goto yy646; + case '\r': goto yy660; + default: goto yy664; } -yy646: +yy664: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy648; - case '\r': goto yy650; - default: goto yy646; + case '\n': goto yy666; + case '\r': goto yy668; + default: goto yy664; } -yy648: +yy666: ++c; -yy649: +yy667: { return (size_t)( c - start ); } -yy650: +yy668: ++c; switch ((yych = *c)) { - case '\n': goto yy648; - default: goto yy649; + case '\n': goto yy666; + default: goto yy667; } } @@ -8883,7 +8984,7 @@ size_t scan_meta_key(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy653; + case '\n': goto yy671; case '0': case '1': case '2': @@ -8945,24 +9046,24 @@ size_t scan_meta_key(const char * c) { case 'w': case 'x': case 'y': - case 'z': goto yy654; - default: goto yy656; + case 'z': goto yy672; + default: goto yy674; } -yy653: +yy671: { return 0; } -yy654: +yy672: ++c; yych = *c; - goto yy658; -yy655: + goto yy676; +yy673: { return (size_t)( c - start ); } -yy656: +yy674: yych = *++c; - goto yy653; -yy657: + goto yy671; +yy675: ++c; yych = *c; -yy658: +yy676: switch (yych) { case ' ': case '!': @@ -9041,8 +9142,8 @@ yy658: case 'w': case 'x': case 'y': - case 'z': goto yy657; - default: goto yy655; + case 'z': goto yy675; + default: goto yy673; } } @@ -9058,71 +9159,71 @@ size_t scan_definition(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy661; - case ' ': goto yy662; - case ':': goto yy663; - default: goto yy664; + case '\n': goto yy679; + case ' ': goto yy680; + case ':': goto yy681; + default: goto yy682; } -yy661: +yy679: { return 0; } -yy662: +yy680: yych = *(marker = ++c); switch (yych) { - case ' ': goto yy669; - case ':': goto yy671; - default: goto yy661; + case ' ': goto yy687; + case ':': goto yy689; + default: goto yy679; } -yy663: +yy681: yych = *++c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy661; - default: goto yy666; + case '\r': goto yy679; + default: goto yy684; } -yy664: +yy682: yych = *++c; - goto yy661; -yy665: + goto yy679; +yy683: ++c; yych = *c; -yy666: +yy684: switch (yych) { case 0x00: case '\n': - case '\r': goto yy667; + case '\r': goto yy685; case '\t': - case ' ': goto yy665; - default: goto yy668; + case ' ': goto yy683; + default: goto yy686; } -yy667: +yy685: { return (size_t)( c - start ); } -yy668: +yy686: yych = *++c; - goto yy667; -yy669: + goto yy685; +yy687: yych = *++c; switch (yych) { - case ' ': goto yy672; - case ':': goto yy671; - default: goto yy670; + case ' ': goto yy690; + case ':': goto yy689; + default: goto yy688; } -yy670: +yy688: c = marker; - goto yy661; -yy671: + goto yy679; +yy689: yych = *++c; switch (yych) { case 0x00: case '\n': - case '\r': goto yy670; - default: goto yy666; + case '\r': goto yy688; + default: goto yy684; } -yy672: +yy690: ++c; switch ((yych = *c)) { - case ':': goto yy671; - default: goto yy670; + case ':': goto yy689; + default: goto yy688; } } @@ -9143,14 +9244,14 @@ size_t scan_table_separator(const char * c) { case '+': case '-': case ':': - case '=': goto yy677; - case '\n': goto yy675; - case '|': goto yy676; - default: goto yy678; + case '=': goto yy695; + case '\n': goto yy693; + case '|': goto yy694; + default: goto yy696; } -yy675: +yy693: { return 0; } -yy676: +yy694: yych = *(marker = ++c); switch (yych) { case 0x00: @@ -9162,10 +9263,10 @@ yy676: case '-': case ':': case '=': - case '|': goto yy688; - default: goto yy675; + case '|': goto yy706; + default: goto yy693; } -yy677: +yy695: yych = *(marker = ++c); switch (yych) { case '\t': @@ -9173,33 +9274,33 @@ yy677: case '+': case '-': case ':': - case '=': goto yy682; - case '|': goto yy679; - default: goto yy675; + case '=': goto yy700; + case '|': goto yy697; + default: goto yy693; } -yy678: +yy696: yych = *++c; - goto yy675; -yy679: + goto yy693; +yy697: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy684; + case '\n': goto yy702; case '\t': case ' ': case '+': case '-': case ':': case '=': - case '|': goto yy679; - case '\r': goto yy686; - default: goto yy681; + case '|': goto yy697; + case '\r': goto yy704; + default: goto yy699; } -yy681: +yy699: c = marker; - goto yy675; -yy682: + goto yy693; +yy700: ++c; yych = *c; switch (yych) { @@ -9208,36 +9309,36 @@ yy682: case '+': case '-': case ':': - case '=': goto yy682; - case '|': goto yy679; - default: goto yy681; + case '=': goto yy700; + case '|': goto yy697; + default: goto yy699; } -yy684: +yy702: ++c; -yy685: +yy703: { return (size_t)( c - start ); } -yy686: +yy704: yych = *++c; switch (yych) { - case '\n': goto yy684; - default: goto yy685; + case '\n': goto yy702; + default: goto yy703; } -yy687: +yy705: ++c; yych = *c; -yy688: +yy706: switch (yych) { case 0x00: - case '\n': goto yy684; + case '\n': goto yy702; case '\t': case ' ': case '+': case '-': case ':': case '=': - case '|': goto yy687; - case '\r': goto yy686; - default: goto yy681; + case '|': goto yy705; + case '\r': goto yy704; + default: goto yy699; } } @@ -9253,234 +9354,234 @@ size_t scan_alignment_string(const char * c) { yych = *c; switch (yych) { case '\t': - case ' ': goto yy692; - case '\n': goto yy691; + case ' ': goto yy710; + case '\n': goto yy709; case '-': - case '=': goto yy694; - case ':': goto yy693; - default: goto yy695; + case '=': goto yy712; + case ':': goto yy711; + default: goto yy713; } -yy691: +yy709: { return 0; } -yy692: +yy710: yych = *(marker = ++c); switch (yych) { case '\t': - case ' ': goto yy734; + case ' ': goto yy752; case '-': - case '=': goto yy698; - case ':': goto yy733; - default: goto yy691; + case '=': goto yy716; + case ':': goto yy751; + default: goto yy709; } -yy693: +yy711: yych = *(marker = ++c); switch (yych) { case '-': - case '=': goto yy710; - default: goto yy691; + case '=': goto yy728; + default: goto yy709; } -yy694: +yy712: yych = *(marker = ++c); switch (yych) { case '-': - case '=': goto yy698; - case ':': goto yy696; - default: goto yy691; + case '=': goto yy716; + case ':': goto yy714; + default: goto yy709; } -yy695: +yy713: yych = *++c; - goto yy691; -yy696: + goto yy709; +yy714: yych = *++c; switch (yych) { - case '+': goto yy705; - default: goto yy701; + case '+': goto yy723; + default: goto yy719; } -yy697: +yy715: c = marker; - goto yy691; -yy698: + goto yy709; +yy716: ++c; yych = *c; switch (yych) { case '-': - case '=': goto yy698; - case ':': goto yy696; - default: goto yy697; + case '=': goto yy716; + case ':': goto yy714; + default: goto yy715; } -yy700: +yy718: ++c; yych = *c; -yy701: +yy719: switch (yych) { case 0x00: case '\n': - case '|': goto yy702; + case '|': goto yy720; case '\t': - case ' ': goto yy700; - case '\r': goto yy704; - default: goto yy697; + case ' ': goto yy718; + case '\r': goto yy722; + default: goto yy715; } -yy702: +yy720: ++c; -yy703: +yy721: { return ALIGN_RIGHT; } -yy704: +yy722: yych = *++c; switch (yych) { - case '\n': goto yy702; - default: goto yy703; + case '\n': goto yy720; + default: goto yy721; } -yy705: +yy723: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '|': goto yy707; + case '|': goto yy725; case '\t': - case ' ': goto yy705; - case '\r': goto yy709; - default: goto yy697; + case ' ': goto yy723; + case '\r': goto yy727; + default: goto yy715; } -yy707: +yy725: ++c; -yy708: +yy726: { return ALIGN_WRAP | ALIGN_RIGHT; } -yy709: +yy727: yych = *++c; switch (yych) { - case '\n': goto yy707; - default: goto yy708; + case '\n': goto yy725; + default: goto yy726; } -yy710: +yy728: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '|': goto yy714; + case '|': goto yy732; case '\t': - case ' ': goto yy712; - case '\r': goto yy716; - case '+': goto yy718; + case ' ': goto yy730; + case '\r': goto yy734; + case '+': goto yy736; case '-': - case '=': goto yy710; - case ':': goto yy717; - default: goto yy697; + case '=': goto yy728; + case ':': goto yy735; + default: goto yy715; } -yy712: +yy730: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '|': goto yy714; + case '|': goto yy732; case '\t': - case ' ': goto yy712; - case '\r': goto yy716; - default: goto yy697; + case ' ': goto yy730; + case '\r': goto yy734; + default: goto yy715; } -yy714: +yy732: ++c; -yy715: +yy733: { return ALIGN_LEFT; } -yy716: +yy734: yych = *++c; switch (yych) { - case '\n': goto yy714; - default: goto yy715; + case '\n': goto yy732; + default: goto yy733; } -yy717: +yy735: yych = *++c; switch (yych) { - case '+': goto yy723; - default: goto yy726; + case '+': goto yy741; + default: goto yy744; } -yy718: +yy736: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '|': goto yy720; + case '|': goto yy738; case '\t': - case ' ': goto yy718; - case '\r': goto yy722; - default: goto yy697; + case ' ': goto yy736; + case '\r': goto yy740; + default: goto yy715; } -yy720: +yy738: ++c; -yy721: +yy739: { return ALIGN_WRAP | ALIGN_LEFT; } -yy722: +yy740: yych = *++c; switch (yych) { - case '\n': goto yy720; - default: goto yy721; + case '\n': goto yy738; + default: goto yy739; } -yy723: +yy741: ++c; yych = *c; switch (yych) { case 0x00: case '\n': - case '|': goto yy730; + case '|': goto yy748; case '\t': - case ' ': goto yy723; - case '\r': goto yy732; - default: goto yy697; + case ' ': goto yy741; + case '\r': goto yy750; + default: goto yy715; } -yy725: +yy743: ++c; yych = *c; -yy726: +yy744: switch (yych) { case 0x00: case '\n': - case '|': goto yy727; + case '|': goto yy745; case '\t': - case ' ': goto yy725; - case '\r': goto yy729; - default: goto yy697; + case ' ': goto yy743; + case '\r': goto yy747; + default: goto yy715; } -yy727: +yy745: ++c; -yy728: +yy746: { return ALIGN_CENTER; } -yy729: +yy747: yych = *++c; switch (yych) { - case '\n': goto yy727; - default: goto yy728; + case '\n': goto yy745; + default: goto yy746; } -yy730: +yy748: ++c; -yy731: +yy749: { return ALIGN_WRAP | ALIGN_CENTER; } -yy732: +yy750: yych = *++c; switch (yych) { - case '\n': goto yy730; - default: goto yy731; + case '\n': goto yy748; + default: goto yy749; } -yy733: +yy751: yych = *++c; switch (yych) { case '-': - case '=': goto yy710; - default: goto yy697; + case '=': goto yy728; + default: goto yy715; } -yy734: +yy752: ++c; yych = *c; switch (yych) { case '\t': - case ' ': goto yy734; + case ' ': goto yy752; case '-': - case '=': goto yy698; - case ':': goto yy733; - default: goto yy697; + case '=': goto yy716; + case ':': goto yy751; + default: goto yy715; } } @@ -9498,49 +9599,49 @@ size_t scan_destination(const char * c) { case 0x00: case '\t': case '\r': - case ' ': goto yy742; - case '\n': goto yy738; - case '<': goto yy739; - default: goto yy741; + case ' ': goto yy760; + case '\n': goto yy756; + case '<': goto yy757; + default: goto yy759; } -yy738: +yy756: { return 0; } -yy739: +yy757: ++c; yych = *c; - goto yy746; -yy740: + goto yy764; +yy758: { return (size_t)( c - start ); } -yy741: +yy759: yych = *++c; - goto yy744; -yy742: + goto yy762; +yy760: yych = *++c; - goto yy738; -yy743: + goto yy756; +yy761: ++c; yych = *c; -yy744: +yy762: switch (yych) { case 0x00: case '\t': case '\n': case '\r': - case ' ': goto yy740; - default: goto yy743; + case ' ': goto yy758; + default: goto yy761; } -yy745: +yy763: ++c; yych = *c; -yy746: +yy764: switch (yych) { case 0x00: case '\t': case '\n': case '\r': - case ' ': goto yy740; - case '>': goto yy743; - default: goto yy745; + case ' ': goto yy758; + case '>': goto yy761; + default: goto yy763; } } @@ -9556,79 +9657,79 @@ size_t scan_title(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy749; - case '"': goto yy750; - case '\'': goto yy751; - case '(': goto yy752; - default: goto yy753; + case '\n': goto yy767; + case '"': goto yy768; + case '\'': goto yy769; + case '(': goto yy770; + default: goto yy771; } -yy749: +yy767: { return 0; } -yy750: +yy768: yych = *(marker = ++c); switch (yych) { case 0x00: case '\n': - case '\r': goto yy749; - default: goto yy762; + case '\r': goto yy767; + default: goto yy780; } -yy751: +yy769: yych = *(marker = ++c); switch (yych) { case 0x00: case '\n': - case '\r': goto yy749; - default: goto yy760; + case '\r': goto yy767; + default: goto yy778; } -yy752: +yy770: yych = *(marker = ++c); switch (yych) { case 0x00: case '\n': - case '\r': goto yy749; - default: goto yy755; + case '\r': goto yy767; + default: goto yy773; } -yy753: +yy771: yych = *++c; - goto yy749; -yy754: + goto yy767; +yy772: ++c; yych = *c; -yy755: +yy773: switch (yych) { case 0x00: case '\n': - case '\r': goto yy756; - case ')': goto yy757; - default: goto yy754; + case '\r': goto yy774; + case ')': goto yy775; + default: goto yy772; } -yy756: +yy774: c = marker; - goto yy749; -yy757: + goto yy767; +yy775: ++c; { return (size_t)( c - start ); } -yy759: +yy777: ++c; yych = *c; -yy760: +yy778: switch (yych) { case 0x00: case '\n': - case '\r': goto yy756; - case '\'': goto yy757; - default: goto yy759; + case '\r': goto yy774; + case '\'': goto yy775; + default: goto yy777; } -yy761: +yy779: ++c; yych = *c; -yy762: +yy780: switch (yych) { case 0x00: case '\n': - case '\r': goto yy756; - case '"': goto yy757; - default: goto yy761; + case '\r': goto yy774; + case '"': goto yy775; + default: goto yy779; } } @@ -9643,106 +9744,106 @@ size_t scan_setext(const char * c) { char yych; yych = *c; switch (yych) { - case '\n': goto yy765; - case ' ': goto yy766; - case '-': goto yy768; - case '=': goto yy767; - default: goto yy769; + case '\n': goto yy783; + case ' ': goto yy784; + case '-': goto yy786; + case '=': goto yy785; + default: goto yy787; } -yy765: +yy783: { return 0; } -yy766: +yy784: yych = *(marker = ++c); switch (yych) { - case ' ': goto yy781; - case '-': goto yy782; - case '=': goto yy783; - default: goto yy765; + case ' ': goto yy799; + case '-': goto yy800; + case '=': goto yy801; + default: goto yy783; } -yy767: +yy785: yych = *(marker = ++c); switch (yych) { - case '=': goto yy776; - default: goto yy765; + case '=': goto yy794; + default: goto yy783; } -yy768: +yy786: yych = *(marker = ++c); switch (yych) { - case '-': goto yy770; - default: goto yy765; + case '-': goto yy788; + default: goto yy783; } -yy769: +yy787: yych = *++c; - goto yy765; -yy770: + goto yy783; +yy788: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy773; - case '\r': goto yy775; - case '-': goto yy770; - default: goto yy772; + case '\n': goto yy791; + case '\r': goto yy793; + case '-': goto yy788; + default: goto yy790; } -yy772: +yy790: c = marker; - goto yy765; -yy773: + goto yy783; +yy791: ++c; -yy774: +yy792: { return (size_t)( c - start ); } -yy775: +yy793: yych = *++c; switch (yych) { - case '\n': goto yy773; - default: goto yy774; + case '\n': goto yy791; + default: goto yy792; } -yy776: +yy794: ++c; yych = *c; switch (yych) { case 0x00: - case '\n': goto yy778; - case '\r': goto yy780; - case '=': goto yy776; - default: goto yy772; + case '\n': goto yy796; + case '\r': goto yy798; + case '=': goto yy794; + default: goto yy790; } -yy778: +yy796: ++c; -yy779: +yy797: { return (size_t)( c - start ); } -yy780: +yy798: yych = *++c; switch (yych) { - case '\n': goto yy778; - default: goto yy779; + case '\n': goto yy796; + default: goto yy797; } -yy781: +yy799: yych = *++c; switch (yych) { - case ' ': goto yy784; - case '-': goto yy782; - case '=': goto yy783; - default: goto yy772; + case ' ': goto yy802; + case '-': goto yy800; + case '=': goto yy801; + default: goto yy790; } -yy782: +yy800: yych = *++c; switch (yych) { - case '-': goto yy770; - default: goto yy772; + case '-': goto yy788; + default: goto yy790; } -yy783: +yy801: yych = *++c; switch (yych) { - case '=': goto yy776; - default: goto yy772; + case '=': goto yy794; + default: goto yy790; } -yy784: +yy802: ++c; switch ((yych = *c)) { - case '-': goto yy782; - case '=': goto yy783; - default: goto yy772; + case '-': goto yy800; + case '=': goto yy801; + default: goto yy790; } } diff --git a/Sources/libMultiMarkdown/scanners.h b/Sources/libMultiMarkdown/scanners.h index ea0f672..f06b676 100644 --- a/Sources/libMultiMarkdown/scanners.h +++ b/Sources/libMultiMarkdown/scanners.h @@ -84,6 +84,7 @@ size_t scan_html_line(const char * c); size_t scan_key(const char * c); size_t scan_meta_key(const char * c); size_t scan_meta_line(const char * c); +size_t scan_ref_abbreviation(const char * c); size_t scan_ref_citation(const char * c); size_t scan_ref_foot(const char * c); size_t scan_ref_link(const char * c); diff --git a/Sources/libMultiMarkdown/scanners.re b/Sources/libMultiMarkdown/scanners.re index ad1d274..03559e5 100644 --- a/Sources/libMultiMarkdown/scanners.re +++ b/Sources/libMultiMarkdown/scanners.re @@ -89,6 +89,8 @@ label = [^\]\n\r\x00]+; finish_line = [^\n\r\x00]+; + ref_abbr = non_indent '*[' label ']' ':' finish_line; + ref_citation = non_indent '[#' label ']' ':' finish_line; ref_foot = non_indent '[^' label ']' ':' finish_line; @@ -153,6 +155,7 @@ setext_1 = non_indent '='{2,} nl_eof; setext_2 = non_indent '-'{2,} nl_eof; + */ @@ -232,6 +235,17 @@ size_t scan_url(const char * c) { } +size_t scan_ref_abbreviation(const char * c) { + const char * marker = NULL; + const char * start = c; + +/*!re2c + ref_abbr { return (size_t)( c - start ); } + .? { return 0; } +*/ +} + + size_t scan_ref_citation(const char * c) { const char * marker = NULL; const char * start = c; diff --git a/Sources/libMultiMarkdown/writer.c b/Sources/libMultiMarkdown/writer.c index 2db2d4b..8b9679a 100644 --- a/Sources/libMultiMarkdown/writer.c +++ b/Sources/libMultiMarkdown/writer.c @@ -80,6 +80,8 @@ void store_link(scratch_pad * scratch, link * l); void store_metadata(scratch_pad * scratch, meta * m); +void store_abbreviation(scratch_pad * scratch, abbr * a); +void abbreviation_free(abbr * a); /// strndup not available on all platforms static char * my_strndup(const char * source, size_t n) { @@ -182,6 +184,17 @@ scratch_pad * scratch_pad_new(mmd_engine * e, short format) { store_metadata(p, m); } + + // Store abbreviations in a hash for rapid retrieval when exporting + p->abbreviation_hash = NULL; + abbr * a; + + for (int i = 0; i < e->abbreviation_stack->size; ++i) + { + a = stack_peek_index(e->abbreviation_stack, i); + + store_abbreviation(p, a); + } } return p; @@ -241,6 +254,14 @@ void scratch_pad_free(scratch_pad * scratch) { //meta_free(m); } + // Free abbreviation hash + abbr * a, * a_tmp; + + HASH_ITER(hh, scratch->abbreviation_hash, a, a_tmp) { + HASH_DEL(scratch->abbreviation_hash, a); // Remove item from hash + abbreviation_free(a); + } + free(scratch); } @@ -410,12 +431,12 @@ char * clean_string(const char * str, bool lowercase) { } -char * clean_string_from_token(const char * source, token * t, bool lowercase) { +char * clean_string_from_range(const char * source, size_t start, size_t len, bool lowercase) { char * clean = NULL; DString * raw = d_string_new(""); - d_string_append_c_array(raw, &source[t->start], t->len); + d_string_append_c_array(raw, &source[start], len); clean = clean_string(raw->str, lowercase); @@ -425,6 +446,11 @@ char * clean_string_from_token(const char * source, token * t, bool lowercase) { } +char * clean_string_from_token(const char * source, token * t, bool lowercase) { + return clean_string_from_range(source, t->start, t->len, lowercase); +} + + char * clean_inside_pair(const char * source, token * t, bool lowercase) { char * text = text_inside_pair(source, t); @@ -649,6 +675,17 @@ void store_metadata(scratch_pad * scratch, meta * m) { } +void store_abbreviation(scratch_pad * scratch, abbr * a) { + abbr * temp; + + HASH_FIND_STR(scratch->abbreviation_hash, a->abbr, temp); + + if (!temp) { + HASH_ADD_KEYPTR(hh, scratch->abbreviation_hash, a->abbr, strlen(a->abbr), a); + } +} + + void link_free(link * l) { free(l->label_text); free(l->clean_text); @@ -974,6 +1011,28 @@ char * extract_metadata(scratch_pad * scratch, const char * target) { } +abbr * abbr_new(const char * source, token * label, token * content) { + abbr * a = malloc(sizeof(abbr)); + + if (a) { + a->abbr = text_inside_pair(source, label); + a->abbr_len = strlen(a->abbr); + a->expansion = clean_string_from_range(source, content->start, content->len, false); + a->expansion_len = strlen(a->expansion); + } + + return a; +} + +void abbreviation_free(abbr * a) { + if (a) { + free(a->abbr); + free(a->expansion); + free(a); + } +} + + bool definition_extract(mmd_engine * e, token ** remainder) { char * source = e->dstr->str; token * label = NULL; @@ -1109,7 +1168,7 @@ bool definition_extract(mmd_engine * e, token ** remainder) { void process_definition_block(mmd_engine * e, token * block) { footnote * f; - + abbr * a; token * label = block->child; if (label->type == BLOCK_PARA) @@ -1133,6 +1192,10 @@ void process_definition_block(mmd_engine * e, token * block) { case BLOCK_DEF_LINK: definition_extract(e, &(block->child)); break; + case BLOCK_DEF_ABBREVIATION: + a = abbr_new(e->dstr->str, label->next, label->next->next->next); + stack_push(e->abbreviation_stack, a); + break; default: fprintf(stderr, "proceess %d\n", block->type); } @@ -1336,6 +1399,147 @@ void process_metadata_stack(mmd_engine * e, scratch_pad * scratch) { scratch->base_header_level = header_level; } +/// kmp from http://stackoverflow.com/questions/8584644/strstr-for-a-string-that-is-not-null-terminated +/// Search for a string within certain bounds (so we don't go past the end of the token) +int *kmp_borders(char * needle, size_t nlen){ + if (!needle) return NULL; + int i, j, *borders = malloc((nlen+1)*sizeof(*borders)); + if (!borders) return NULL; + i = 0; + j = -1; + borders[i] = j; + while((size_t)i < nlen){ + while(j >= 0 && needle[i] != needle[j]){ + j = borders[j]; + } + ++i; + ++j; + borders[i] = j; + } + return borders; +} + +char * kmp_search(const char * haystack, size_t haylen, char * needle, size_t nlen, int * borders){ + size_t max_index = haylen-nlen, i = 0, j = 0; + while(i <= max_index){ + while(j < nlen && *haystack && needle[j] == *haystack){ + ++j; + ++haystack; + } + if (j == nlen){ + return haystack-nlen; + } + if (!(*haystack)){ + return NULL; + } + if (j == 0){ + ++haystack; + ++i; + } else { + do{ + i += j - (size_t)borders[j]; + j = borders[j]; + }while(j > 0 && needle[j] != *haystack); + } + } + return NULL; +} + +char * sstrnstr(const char * haystack, char * needle, size_t haylen){ + if (!haystack || !needle){ + return NULL; + } + size_t nlen = strlen(needle); + if (haylen < nlen){ + return NULL; + } + int *borders = kmp_borders(needle, nlen); + if (!borders){ + return NULL; + } + char *match = kmp_search(haystack, haylen, needle, nlen, borders); + free(borders); + return match; +} + + +/// Search a text node for abbreviation matches +/// TODO: This is an inefficient algorithm, searching +/// each node once for *each* abbreviation. A more +/// advanced algorithm would search for all abbreviations +/// simultaneously but require more setup (e.g. Aho-Corasick) +void abbr_search_text(mmd_engine * e, token * t) { + const char * str = &e->dstr->str[t->start]; + + char * match; + abbr * a; + + for (int i = 0; i < e->abbreviation_stack->size; ++i) + { + a = stack_peek_index(e->abbreviation_stack, i); + + match = sstrnstr(str, a->abbr, t->len); + + if (match) { + fprintf(stderr, "Found match '%s' -> '%s' at %lu\n", a->abbr, a->expansion, match - e->dstr->str); + } + } +} + + +/// Determine which nodes to descend into to search for abbreviations +void abbr_search(mmd_engine * e, token * t) { + while (t) { + switch (t->type) { + case TEXT_PLAIN: + abbr_search_text(e, t); + break; + case DOC_START_TOKEN: + case BLOCK_LIST_BULLETED: + case BLOCK_LIST_BULLETED_LOOSE: + case BLOCK_LIST_ENUMERATED: + case BLOCK_LIST_ENUMERATED_LOOSE: + abbr_search(e, t->child); + break; + case BLOCK_PARA: + case BLOCK_H1: + case BLOCK_H2: + case BLOCK_H3: + case BLOCK_H4: + case BLOCK_H5: + case BLOCK_H6: + case BLOCK_LIST_ITEM_TIGHT: + case BLOCK_LIST_ITEM: + case BLOCK_SETEXT_1: + case BLOCK_SETEXT_2: + case BLOCK_TABLE: + case BLOCK_TABLE_HEADER: + case BLOCK_TABLE_SECTION: + abbr_search_text(e, t); + break; + default: + break; + } + + t = t->next; + } +} + + +void process_abbreviation_stack(mmd_engine * e, scratch_pad * scratch) { + abbr * a; + + // Describe which abbreviations we are searching for + for (int i = 0; i < e->abbreviation_stack->size; ++i) + { + a = stack_peek_index(e->abbreviation_stack, i); + + fprintf(stderr, "Check for abbreviation: '%s'\n", a->abbr); + } + + abbr_search(e, e->root); +} + void mmd_export_token_tree(DString * out, mmd_engine * e, short format) { @@ -1351,6 +1555,9 @@ void mmd_export_token_tree(DString * out, mmd_engine * e, short format) { // Process metadata process_metadata_stack(e, scratch); + // Process abbreviations + // process_abbreviation_stack(e, scratch); + switch (scratch->output_format) { case FORMAT_BEAMER: @@ -1464,6 +1671,7 @@ void parse_brackets(const char * source, scratch_pad * scratch, token * bracket, case PAIR_BRACKET_CITATION: case PAIR_BRACKET_FOOTNOTE: case PAIR_BRACKET_VARIABLE: + case PAIR_BRACKET_ABBREVIATION: *final_link = NULL; return; } diff --git a/Sources/libMultiMarkdown/writer.h b/Sources/libMultiMarkdown/writer.h index 68d9134..8133238 100644 --- a/Sources/libMultiMarkdown/writer.h +++ b/Sources/libMultiMarkdown/writer.h @@ -93,6 +93,8 @@ typedef struct { struct fn_holder * citation_hash; short citation_being_printed; + struct abbr * abbreviation_hash; + short language; short quotes_lang; @@ -162,6 +164,16 @@ struct meta { typedef struct meta meta; +struct abbr { + char * abbr; + size_t abbr_len; + char * expansion; + size_t expansion_len; + UT_hash_handle hh; +}; + +typedef struct abbr abbr; + /// Temporary storage while exporting parse tree to output format scratch_pad * scratch_pad_new(mmd_engine * e, short format); diff --git a/tests/MMD6Tests/Abbreviations.text b/tests/MMD6Tests/Abbreviations.text new file mode 100644 index 0000000..6cf3c5a --- /dev/null +++ b/tests/MMD6Tests/Abbreviations.text @@ -0,0 +1,17 @@ +foo + +bar + +foo bar + +foobar + +foo +bar + +5 + +*[foo]: FOO +*[bar]: BAR +*[foobar]: FOOBAR +*[foo bar]: FOO BAR -- 2.40.0