Detect `clock_gettime` and `clock_getres` for winpthreads
[ruby.git] / prism / prettyprint.h
blob5a52b2b6b8eb43ace9b07be3e2d5ac58fc273552
1 /**
2 * @file prettyprint.h
4 * An AST node pretty-printer.
5 */
6 #ifndef PRISM_PRETTYPRINT_H
7 #define PRISM_PRETTYPRINT_H
9 #include "prism/defines.h"
11 #ifdef PRISM_EXCLUDE_PRETTYPRINT
13 void pm_prettyprint(void);
15 #else
17 #include <stdio.h>
19 #include "prism/ast.h"
20 #include "prism/parser.h"
21 #include "prism/util/pm_buffer.h"
23 /**
24 * Pretty-prints the AST represented by the given node to the given buffer.
26 * @param output_buffer The buffer to write the pretty-printed AST to.
27 * @param parser The parser that parsed the AST.
28 * @param node The root node of the AST to pretty-print.
30 PRISM_EXPORTED_FUNCTION void pm_prettyprint(pm_buffer_t *output_buffer, const pm_parser_t *parser, const pm_node_t *node);
32 #endif
34 #endif