aboutsummaryrefslogtreecommitdiff
path: root/src/scanners.h
blob: aa5c00d13c1a15ae4e459544ef05226b1267a69b (plain)
  1. #include "cmark.h"
  2. #include "chunk.h"
  3. #ifdef __cplusplus
  4. extern "C" {
  5. #endif
  6. int _scan_at(int (*scanner)(const unsigned char *), chunk *c, int offset);
  7. int _scan_autolink_uri(const unsigned char *p);
  8. int _scan_autolink_email(const unsigned char *p);
  9. int _scan_html_tag(const unsigned char *p);
  10. int _scan_html_block_tag(const unsigned char *p);
  11. int _scan_link_url(const unsigned char *p);
  12. int _scan_link_title(const unsigned char *p);
  13. int _scan_spacechars(const unsigned char *p);
  14. int _scan_atx_header_start(const unsigned char *p);
  15. int _scan_setext_header_line(const unsigned char *p);
  16. int _scan_hrule(const unsigned char *p);
  17. int _scan_open_code_fence(const unsigned char *p);
  18. int _scan_close_code_fence(const unsigned char *p);
  19. int _scan_entity(const unsigned char *p);
  20. #define scan_autolink_uri(c, n) _scan_at(&_scan_autolink_uri, c, n)
  21. #define scan_autolink_email(c, n) _scan_at(&_scan_autolink_email, c, n)
  22. #define scan_html_tag(c, n) _scan_at(&_scan_html_tag, c, n)
  23. #define scan_html_block_tag(c, n) _scan_at(&_scan_html_block_tag, c, n)
  24. #define scan_link_url(c, n) _scan_at(&_scan_link_url, c, n)
  25. #define scan_link_title(c, n) _scan_at(&_scan_link_title, c, n)
  26. #define scan_spacechars(c, n) _scan_at(&_scan_spacechars, c, n)
  27. #define scan_atx_header_start(c, n) _scan_at(&_scan_atx_header_start, c, n)
  28. #define scan_setext_header_line(c, n) _scan_at(&_scan_setext_header_line, c, n)
  29. #define scan_hrule(c, n) _scan_at(&_scan_hrule, c, n)
  30. #define scan_open_code_fence(c, n) _scan_at(&_scan_open_code_fence, c, n)
  31. #define scan_close_code_fence(c, n) _scan_at(&_scan_close_code_fence, c, n)
  32. #define scan_entity(c, n) _scan_at(&_scan_entity, c, n)
  33. #ifdef __cplusplus
  34. }
  35. #endif