Herb C Reference
All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
pretty_print.c File Reference
#include "include/pretty_print.h"
#include "include/analyzed_ruby.h"
#include "include/ast_node.h"
#include "include/ast_nodes.h"
#include "include/ast_pretty_print.h"
#include "include/buffer.h"
#include "include/errors.h"
#include "include/token_struct.h"
#include "include/util.h"
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>

Functions

void pretty_print_indent (buffer_T *buffer, const size_t indent)
 
void pretty_print_newline (const size_t indent, const size_t relative_indent, buffer_T *buffer)
 
void pretty_print_label (const char *name, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_quoted_property (const char *name, const char *value, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_boolean_property (const char *name, bool value, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_property (const char *name, const char *value, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_size_t_property (size_t value, const char *name, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_array (const char *name, array_T *array, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_errors (AST_NODE_T *node, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_location (location_T *location, buffer_T *buffer)
 
void pretty_print_position_property (position_T *position, const char *name, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_token_property (token_T *token, const char *name, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_string_property (const char *string, const char *name, const size_t indent, const size_t relative_indent, const bool last_property, buffer_T *buffer)
 
void pretty_print_analyed_ruby (analyzed_ruby_T *analyzed, const char *source)
 

Function Documentation

◆ pretty_print_indent()

void pretty_print_indent ( buffer_T buffer,
const size_t  indent 
)

◆ pretty_print_newline()

void pretty_print_newline ( const size_t  indent,
const size_t  relative_indent,
buffer_T buffer 
)

◆ pretty_print_label()

void pretty_print_label ( const char *  name,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_quoted_property()

void pretty_print_quoted_property ( const char *  name,
const char *  value,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_boolean_property()

void pretty_print_boolean_property ( const char *  name,
bool  value,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_property()

void pretty_print_property ( const char *  name,
const char *  value,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_size_t_property()

void pretty_print_size_t_property ( size_t  value,
const char *  name,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_array()

void pretty_print_array ( const char *  name,
array_T array,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_errors()

void pretty_print_errors ( AST_NODE_T node,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_location()

void pretty_print_location ( location_T location,
buffer_T buffer 
)

◆ pretty_print_position_property()

void pretty_print_position_property ( position_T position,
const char *  name,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_token_property()

void pretty_print_token_property ( token_T token,
const char *  name,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_string_property()

void pretty_print_string_property ( const char *  string,
const char *  name,
const size_t  indent,
const size_t  relative_indent,
const bool  last_property,
buffer_T buffer 
)

◆ pretty_print_analyed_ruby()

void pretty_print_analyed_ruby ( analyzed_ruby_T analyzed,
const char *  source 
)