ext/commonmarker/cmark/src/render.c in commonmarker-0.14.3 vs ext/commonmarker/cmark/src/render.c in commonmarker-0.14.4
- old
+ new
@@ -16,11 +16,12 @@
if (renderer->need_cr < 2) {
renderer->need_cr = 2;
}
}
-static void S_out(cmark_renderer *renderer, const char *source, bool wrap,
+static void S_out(cmark_renderer *renderer, cmark_node *node,
+ const char *source, bool wrap,
cmark_escaping escape) {
int length = (int)strlen(source);
unsigned char nextc;
int32_t c;
int i = 0;
@@ -95,11 +96,11 @@
// we need to escape a potential list marker after
// a digit:
renderer->begin_content =
renderer->begin_content && cmark_isdigit((char)c) == 1;
} else {
- (renderer->outc)(renderer, escape, c, nextc);
+ (renderer->outc)(renderer, node, escape, c, nextc);
renderer->begin_line = false;
renderer->begin_content =
renderer->begin_content && cmark_isdigit((char)c) == 1;
}
@@ -141,10 +142,11 @@
cmark_utf8proc_encode_char(c, renderer->buffer);
renderer->column += 1;
}
char *cmark_render(cmark_mem *mem, cmark_node *root, int options, int width,
- void (*outc)(cmark_renderer *, cmark_escaping, int32_t,
+ void (*outc)(cmark_renderer *, cmark_node *,
+ cmark_escaping, int32_t,
unsigned char),
int (*render_node)(cmark_renderer *renderer,
cmark_node *node,
cmark_event_type ev_type, int options)) {
cmark_strbuf pref = CMARK_BUF_INIT(mem);