summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2014-12-14 08:18:27 -0800
committerJohn MacFarlane <jgm@berkeley.edu>2014-12-14 08:18:27 -0800
commit66e986ec02c417ba9387dbf906381bba598c3f00 (patch)
treee0b5b7d693010e18846fbe210338ed90ae6761b2
parent6df2047d90d81e6269a37e7e6843211edf4ba3c6 (diff)
Rename CMARK_NODE_INLINE_CODE -> CMARK_NODE_CODE.
-rw-r--r--api_test/main.c6
-rw-r--r--man/man3/cmark.32
-rw-r--r--src/cmark.h4
-rw-r--r--src/html.c4
-rw-r--r--src/inlines.c2
-rw-r--r--src/iterator.c2
-rw-r--r--src/man.c4
-rw-r--r--src/node.c8
-rw-r--r--src/print.c2
9 files changed, 17 insertions, 17 deletions
diff --git a/api_test/main.c b/api_test/main.c
index 42cc70d..f380b5c 100644
--- a/api_test/main.c
+++ b/api_test/main.c
@@ -26,7 +26,7 @@ static const cmark_node_type node_types[] = {
CMARK_NODE_TEXT,
CMARK_NODE_SOFTBREAK,
CMARK_NODE_LINEBREAK,
- CMARK_NODE_INLINE_CODE,
+ CMARK_NODE_CODE,
CMARK_NODE_INLINE_HTML,
CMARK_NODE_EMPH,
CMARK_NODE_STRONG,
@@ -426,7 +426,7 @@ hierarchy(test_batch_runner *runner)
(1 << CMARK_NODE_TEXT) |
(1 << CMARK_NODE_SOFTBREAK) |
(1 << CMARK_NODE_LINEBREAK) |
- (1 << CMARK_NODE_INLINE_CODE) |
+ (1 << CMARK_NODE_CODE) |
(1 << CMARK_NODE_INLINE_HTML) |
(1 << CMARK_NODE_EMPH) |
(1 << CMARK_NODE_STRONG) |
@@ -445,7 +445,7 @@ hierarchy(test_batch_runner *runner)
test_content(runner, CMARK_NODE_TEXT, 0);
test_content(runner, CMARK_NODE_SOFTBREAK, 0);
test_content(runner, CMARK_NODE_LINEBREAK, 0);
- test_content(runner, CMARK_NODE_INLINE_CODE, 0);
+ test_content(runner, CMARK_NODE_CODE, 0);
test_content(runner, CMARK_NODE_INLINE_HTML, 0);
test_content(runner, CMARK_NODE_EMPH, all_inlines);
test_content(runner, CMARK_NODE_STRONG, all_inlines);
diff --git a/man/man3/cmark.3 b/man/man3/cmark.3
index 589ffe1..0a281ed 100644
--- a/man/man3/cmark.3
+++ b/man/man3/cmark.3
@@ -1,4 +1,4 @@
-.TH cmark 3 "December 13, 2014" "LOCAL" "Library Functions Manual"
+.TH cmark 3 "December 14, 2014" "LOCAL" "Library Functions Manual"
.SH
NAME
.PP
diff --git a/src/cmark.h b/src/cmark.h
index 9de1037..d08d939 100644
--- a/src/cmark.h
+++ b/src/cmark.h
@@ -54,7 +54,7 @@ typedef enum {
CMARK_NODE_TEXT,
CMARK_NODE_SOFTBREAK,
CMARK_NODE_LINEBREAK,
- CMARK_NODE_INLINE_CODE,
+ CMARK_NODE_CODE,
CMARK_NODE_INLINE_HTML,
CMARK_NODE_EMPH,
CMARK_NODE_STRONG,
@@ -423,7 +423,7 @@ char *cmark_render_man(cmark_node *root);
#define NODE_TEXT CMARK_NODE_TEXT
#define NODE_SOFTBREAK CMARK_NODE_SOFTBREAK
#define NODE_LINEBREAK CMARK_NODE_LINEBREAK
- #define NODE_INLINE_CODE CMARK_NODE_INLINE_CODE
+ #define NODE_CODE CMARK_NODE_CODE
#define NODE_INLINE_HTML CMARK_NODE_INLINE_HTML
#define NODE_EMPH CMARK_NODE_EMPH
#define NODE_STRONG CMARK_NODE_STRONG
diff --git a/src/html.c b/src/html.c
index f719405..a77cd21 100644
--- a/src/html.c
+++ b/src/html.c
@@ -59,7 +59,7 @@ S_render_node(cmark_node *node, cmark_event_type ev_type, void *vstate)
if (state->plain != NULL) {
switch(node->type) {
case CMARK_NODE_TEXT:
- case CMARK_NODE_INLINE_CODE:
+ case CMARK_NODE_CODE:
case CMARK_NODE_INLINE_HTML:
escape_html(html, node->as.literal.data,
node->as.literal.len);
@@ -197,7 +197,7 @@ S_render_node(cmark_node *node, cmark_event_type ev_type, void *vstate)
strbuf_putc(html, '\n');
break;
- case CMARK_NODE_INLINE_CODE:
+ case CMARK_NODE_CODE:
strbuf_puts(html, "<code>");
escape_html(html, node->as.literal.data, node->as.literal.len);
strbuf_puts(html, "</code>");
diff --git a/src/inlines.c b/src/inlines.c
index 2b6f788..9ca2501 100644
--- a/src/inlines.c
+++ b/src/inlines.c
@@ -16,7 +16,7 @@
// Macros for creating various kinds of simple.
#define make_str(s) make_literal(CMARK_NODE_TEXT, s)
-#define make_code(s) make_literal(CMARK_NODE_INLINE_CODE, s)
+#define make_code(s) make_literal(CMARK_NODE_CODE, s)
#define make_raw_html(s) make_literal(CMARK_NODE_INLINE_HTML, s)
#define make_linebreak() make_simple(CMARK_NODE_LINEBREAK)
#define make_softbreak() make_simple(CMARK_NODE_SOFTBREAK)
diff --git a/src/iterator.c b/src/iterator.c
index a9e6d20..6ebc9af 100644
--- a/src/iterator.c
+++ b/src/iterator.c
@@ -40,7 +40,7 @@ int S_is_leaf(cmark_node *node)
case CMARK_NODE_TEXT:
case CMARK_NODE_SOFTBREAK:
case CMARK_NODE_LINEBREAK:
- case CMARK_NODE_INLINE_CODE:
+ case CMARK_NODE_CODE:
case CMARK_NODE_INLINE_HTML:
return 1;
default:
diff --git a/src/man.c b/src/man.c
index b86c7e6..3058b25 100644
--- a/src/man.c
+++ b/src/man.c
@@ -58,7 +58,7 @@ S_render_node(cmark_node *node, cmark_event_type ev_type, void *vstate)
if (state->plain != NULL) {
switch(node->type) {
case CMARK_NODE_TEXT:
- case CMARK_NODE_INLINE_CODE:
+ case CMARK_NODE_CODE:
case CMARK_NODE_INLINE_HTML:
escape_man(man, node->as.literal.data,
node->as.literal.len);
@@ -174,7 +174,7 @@ S_render_node(cmark_node *node, cmark_event_type ev_type, void *vstate)
strbuf_putc(man, '\n');
break;
- case CMARK_NODE_INLINE_CODE:
+ case CMARK_NODE_CODE:
strbuf_puts(man, "\\f[C]");
escape_man(man, node->as.literal.data, node->as.literal.len);
strbuf_puts(man, "\\f[]");
diff --git a/src/node.c b/src/node.c
index ab3771b..276ed46 100644
--- a/src/node.c
+++ b/src/node.c
@@ -45,7 +45,7 @@ void S_free_nodes(cmark_node *e)
break;
case NODE_TEXT:
case NODE_INLINE_HTML:
- case NODE_INLINE_CODE:
+ case NODE_CODE:
chunk_free(&e->as.literal);
break;
case NODE_LINK:
@@ -105,7 +105,7 @@ S_type_string(cmark_node *node)
case CMARK_NODE_TEXT: return "TEXT";
case CMARK_NODE_SOFTBREAK: return "SOFTBREAK";
case CMARK_NODE_LINEBREAK: return "LINEBREAK";
- case CMARK_NODE_INLINE_CODE: return "INLINE_CODE";
+ case CMARK_NODE_CODE: return "CODE";
case CMARK_NODE_INLINE_HTML: return "INLINE_HTML";
case CMARK_NODE_EMPH: return "EMPH";
case CMARK_NODE_STRONG: return "STRONG";
@@ -187,7 +187,7 @@ cmark_node_get_string_content(cmark_node *node) {
case NODE_TEXT:
case NODE_INLINE_HTML:
- case NODE_INLINE_CODE:
+ case NODE_CODE:
return chunk_to_cstr(&node->as.literal);
default:
@@ -211,7 +211,7 @@ cmark_node_set_string_content(cmark_node *node, const char *content) {
case NODE_TEXT:
case NODE_INLINE_HTML:
- case NODE_INLINE_CODE:
+ case NODE_CODE:
chunk_set_cstr(&node->as.literal, content);
return 1;
diff --git a/src/print.c b/src/print.c
index 9384a0b..951d238 100644
--- a/src/print.c
+++ b/src/print.c
@@ -99,7 +99,7 @@ static void render_nodes(strbuf* buffer, cmark_node* node, int indent)
case NODE_SOFTBREAK:
strbuf_printf(buffer, "softbreak\n");
break;
- case NODE_INLINE_CODE:
+ case NODE_CODE:
strbuf_printf(buffer, "code ");
print_str(buffer, node->as.literal.data, node->as.literal.len);
strbuf_putc(buffer, '\n');