diff options
author | Vicent Marti <[email protected]> | 2014-09-03 03:40:23 +0200 |
---|---|---|
committer | Vicent Marti <[email protected]> | 2014-09-09 03:39:15 +0200 |
commit | a7314deae649646f1f7ce5ede972641b5b62538c (patch) | |
tree | c958536337ab5cbc96d247725e0dd35fdc02b998 /src/stmd.h | |
parent | 7e12fdba0c9a444a3cfc29c520e2f2caa57a8232 (diff) |
338/103
Diffstat (limited to 'src/stmd.h')
-rw-r--r-- | src/stmd.h | 16 |
1 files changed, 7 insertions, 9 deletions
@@ -1,17 +1,15 @@ +#ifndef _STDMD_H_ +#define _STDMD_H_ + #include <stdbool.h> #include <stdio.h> #include "buffer.h" +#include "chunk.h" #include "uthash.h" #define VERSION "0.1" #define CODE_INDENT 4 -typedef struct { - const unsigned char *data; - int len; - int alloc; -} chunk; - typedef struct Inline { enum { INL_STRING, INL_SOFTBREAK, INL_LINEBREAK, INL_CODE, INL_RAW_HTML, INL_ENTITY, INL_EMPH, INL_STRONG, INL_LINK, INL_IMAGE } tag; @@ -79,7 +77,6 @@ typedef struct Block { struct Block* parent; struct Block* top; gh_buf string_content; - int string_pos; inl* inline_content; union { struct ListData list_data; @@ -91,10 +88,10 @@ typedef struct Block { struct Block * prev; } block; -inl* parse_inlines(gh_buf *input, int input_pos, reference** refmap); +inl* parse_inlines(gh_buf *input, reference** refmap); void free_inlines(inl* e); -int parse_reference(gh_buf *input, int input_pos, reference** refmap); +int parse_reference(gh_buf *input, reference** refmap); void free_reference(reference *ref); void free_reference_map(reference **refmap); @@ -117,3 +114,4 @@ void inlines_to_html(gh_buf *html, inl *b); void utf8proc_case_fold(gh_buf *dest, const unsigned char *str, int len); +#endif |