| 590 | } |
| 591 | |
| 592 | int cmark_node_set_on_enter(cmark_node *node, const char *on_enter) { |
| 593 | if (node == NULL) { |
| 594 | return 0; |
| 595 | } |
| 596 | |
| 597 | switch (node->type) { |
| 598 | case CMARK_NODE_CUSTOM_INLINE: |
| 599 | case CMARK_NODE_CUSTOM_BLOCK: |
| 600 | cmark_set_cstr(node->mem, &node->as.custom.on_enter, on_enter); |
| 601 | return 1; |
| 602 | default: |
| 603 | break; |
| 604 | } |
| 605 | |
| 606 | return 0; |
| 607 | } |
| 608 | |
| 609 | const char *cmark_node_get_on_exit(cmark_node *node) { |
| 610 | if (node == NULL) { |
no test coverage detected