Ruby 1.9.2p136(2010-12-25revision30365)

- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

Data Structures | Defines | Typedefs | Enumerations | Functions

# ext/syck/syck.h File Reference

`#include <stdio.h>`
`#include <stdlib.h>`
`#include <ctype.h>`
`#include "ruby/st.h"`
Include dependency graph for syck.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Data Structures
struct | _syck_node
struct | _syck_file
struct | _syck_str
struct | _syck_level
struct | _syck_parser
struct | _syck_emitter
struct | _syck_emitter_node
## Defines
#define | SYCK_YAML_MAJOR 1
#define | SYCK_YAML_MINOR 0
#define | YAML_DOMAIN "yaml.org,2002"
#define | ASSERT(f) ((void)0)
#define | NULL (void *)0
#define | ALLOC_CT 8
#define | SYCK_BUFFERSIZE 4096
#define | S_ALLOC_N(type, n) (type*)malloc(sizeof(type)*(n))
#define | S_ALLOC(type) (type*)malloc(sizeof(type))
#define | S_REALLOC_N(var, type, n) (var)=(type*)realloc((char*)(var),sizeof(type)*(n))
#define | S_FREE(n) if (n) { free(n); n = NULL; }
#define | S_ALLOCA_N(type, n) (type*)alloca(sizeof(type)*(n))
#define | S_MEMZERO(p, type, n) memset((p), 0, sizeof(type)*(n))
#define | S_MEMCPY(p1, p2, type, n) memcpy((p1), (p2), sizeof(type)*(n))
#define | S_MEMMOVE(p1, p2, type, n) memmove((p1), (p2), sizeof(type)*(n))
#define | S_MEMCMP(p1, p2, type, n) memcmp((p1), (p2), sizeof(type)*(n))
#define | BLOCK_FOLD 10
#define | BLOCK_LIT 20
#define | BLOCK_PLAIN 30
#define | NL_CHOMP 40
#define | NL_KEEP 50
#define | SYMID unsigned long
## Typedefs
typedef long | st_data_t
typedef struct _syck_node | SyckNode
typedef struct _syck_parser | SyckParser
typedef struct _syck_file | SyckIoFile
typedef struct _syck_str | SyckIoStr
typedef struct _syck_level | SyckLevel
typedef SYMID(* | SyckNodeHandler )(SyckParser *, SyckNode *)
typedef void(* | SyckErrorHandler )(SyckParser *, const char *)
typedef SyckNode *(* | SyckBadAnchorHandler )(SyckParser *, char *)
typedef long(* | SyckIoFileRead )(char *, SyckIoFile *, long, long)
typedef long(* | SyckIoStrRead )(char *, SyckIoStr *, long, long)
typedef struct _syck_emitter | SyckEmitter
typedef struct _syck_emitter_node | SyckEmitterNode
typedef void(* | SyckOutputHandler )(SyckEmitter *, char *, long)
typedef void(* | SyckEmitterHandler )(SyckEmitter *, st_data_t)
## Enumerations
enum | syck_kind_tag { syck_map_kind, syck_seq_kind, syck_str_kind }
enum | map_part { map_key, map_value }
enum | map_style { map_none, map_inline }
enum | seq_style { seq_none, seq_inline }
enum | scalar_style { scalar_none, scalar_1quote, scalar_2quote, scalar_fold, scalar_literal, scalar_plain }
enum | syck_io_type { syck_io_str, syck_io_file }
enum | syck_parser_input { syck_yaml_utf8, syck_yaml_utf16, syck_yaml_utf32, syck_bytecode_utf8 }
enum | syck_level_status { syck_lvl_header, syck_lvl_doc, syck_lvl_open, syck_lvl_seq, syck_lvl_map, syck_lvl_block, syck_lvl_str, syck_lvl_iseq, syck_lvl_imap, syck_lvl_end, syck_lvl_pause, syck_lvl_anctag, syck_lvl_mapx, syck_lvl_seqx }
enum | doc_stage { doc_open, doc_processing }
## Functions
SYMID | syck_hdlr_add_node (SyckParser *, SyckNode *)
SyckNode * | syck_hdlr_add_anchor (SyckParser *, char *, SyckNode *)
void | syck_hdlr_remove_anchor (SyckParser *, char *)
SyckNode * | syck_hdlr_get_anchor (SyckParser *, char *)
void | syck_add_transfer (char *, SyckNode *, int)
char * | syck_xprivate (const char *, int)
char * | syck_taguri (const char *, const char *, int)
int | syck_tagcmp (const char *, const char *)
int | syck_add_sym (SyckParser *, void *)
int | syck_lookup_sym (SyckParser *, SYMID, void **)
int | syck_try_implicit (SyckNode *)
char * | syck_type_id_to_uri (const char *)
void | try_tag_implicit (SyckNode *, int)
const char * | syck_match_implicit (const char *, size_t)
char * | syck_strndup (const char *, long)
long | syck_io_file_read (char *, SyckIoFile *, long, long)
long | syck_io_str_read (char *, SyckIoStr *, long, long)
char * | syck_base64enc (char *, long)
char * | syck_base64dec (char *, long)
SyckEmitter * | syck_new_emitter (void)
SYMID | syck_emitter_mark_node (SyckEmitter *, st_data_t)
void | syck_emitter_ignore_id (SyckEmitter *, SYMID)
void | syck_output_handler (SyckEmitter *, SyckOutputHandler)
void | syck_emitter_handler (SyckEmitter *, SyckEmitterHandler)
void | syck_free_emitter (SyckEmitter *)
void | syck_emitter_clear (SyckEmitter *)
void | syck_emitter_write (SyckEmitter *, const char *, long)
void | syck_emitter_escape (SyckEmitter *, const char *, long)
void | syck_emitter_flush (SyckEmitter *, long)
void | syck_emit (SyckEmitter *, st_data_t)
void | syck_emit_scalar (SyckEmitter *, const char *, enum scalar_style, int, int, char, const char *, long)
void | syck_emit_1quoted (SyckEmitter *, int, const char *, long)
void | syck_emit_2quoted (SyckEmitter *, int, const char *, long)
void | syck_emit_folded (SyckEmitter *, int, char, const char *, long)
void | syck_emit_literal (SyckEmitter *, char, const char *, long)
void | syck_emit_seq (SyckEmitter *, const char *, enum seq_style)
void | syck_emit_item (SyckEmitter *, st_data_t)
void | syck_emit_map (SyckEmitter *, const char *, enum map_style)
void | syck_emit_end (SyckEmitter *)
void | syck_emit_tag (SyckEmitter *, const char *, const char *)
void | syck_emit_indent (SyckEmitter *)
SyckLevel * | syck_emitter_current_level (SyckEmitter *)
SyckLevel * | syck_emitter_parent_level (SyckEmitter *)
void | syck_emitter_pop_level (SyckEmitter *)
void | syck_emitter_add_level (SyckEmitter *, int, enum syck_level_status)
void | syck_emitter_reset_levels (SyckEmitter *)
SyckParser * | syck_new_parser (void)
void | syck_free_parser (SyckParser *)
void | syck_parser_set_root_on_error (SyckParser *, SYMID)
void | syck_parser_implicit_typing (SyckParser *, int)
void | syck_parser_taguri_expansion (SyckParser *, int)
int | syck_scan_scalar (int, const char *, long)
void | syck_parser_handler (SyckParser *, SyckNodeHandler)
void | syck_parser_error_handler (SyckParser *, SyckErrorHandler)
void | syck_parser_bad_anchor_handler (SyckParser *, SyckBadAnchorHandler)
void | syck_parser_set_input_type (SyckParser *, enum syck_parser_input)
void | syck_parser_file (SyckParser *, FILE *, SyckIoFileRead)
void | syck_parser_str (SyckParser *, char *, long, SyckIoStrRead)
void | syck_parser_str_auto (SyckParser *, char *, SyckIoStrRead)
SyckLevel * | syck_parser_current_level (SyckParser *)
void | syck_parser_add_level (SyckParser *, int, enum syck_level_status)
void | syck_parser_pop_level (SyckParser *)
void | free_any_io (SyckParser *)
long | syck_parser_read (SyckParser *)
long | syck_parser_readlen (SyckParser *, long)
SYMID | syck_parse (SyckParser *)
void | syck_default_error_handler (SyckParser *, const char *)
SYMID | syck_yaml2byte_handler (SyckParser *, SyckNode *)
char * | syck_yaml2byte (char *)
SyckNode * | syck_alloc_map (void)
SyckNode * | syck_alloc_seq (void)
SyckNode * | syck_alloc_str (void)
void | syck_free_node (SyckNode *)
void | syck_free_members (SyckNode *)
SyckNode * | syck_new_str (const char *, enum scalar_style)
SyckNode * | syck_new_str2 (const char *, long, enum scalar_style)
void | syck_replace_str (SyckNode *, char *, enum scalar_style)
void | syck_replace_str2 (SyckNode *, char *, long, enum scalar_style)
void | syck_str_blow_away_commas (SyckNode *)
char * | syck_str_read (SyckNode *)
SyckNode * | syck_new_map (SYMID, SYMID)
void | syck_map_empty (SyckNode *)
void | syck_map_add (SyckNode *, SYMID, SYMID)
SYMID | syck_map_read (SyckNode *, enum map_part, long)
void | syck_map_assign (SyckNode *, enum map_part, long, SYMID)
long | syck_map_count (SyckNode *)
void | syck_map_update (SyckNode *, SyckNode *)
SyckNode * | syck_new_seq (SYMID)
void | syck_seq_empty (SyckNode *)
void | syck_seq_add (SyckNode *, SYMID)
void | syck_seq_assign (SyckNode *, long, SYMID)
SYMID | syck_seq_read (SyckNode *, long)
long | syck_seq_count (SyckNode *)
void | syckerror (const char *)
int | syckparse (void *)
int | sycklex (union YYSTYPE *, SyckParser *)

## Define Documentation

#define ALLOC_CT 8

Definition at line 45 of file syck.h.

Referenced by syck_alloc_map(), syck_alloc_seq(), syck_emitter_add_level(), syck_map_add(), syck_map_empty(), syck_map_update(), syck_new_emitter(), syck_new_parser(), syck_parser_add_level(), syck_seq_add(), and syck_seq_empty().

#define ASSERT | ( |  | f | ) | ((void)0)

Definition at line 38 of file syck.h.

Referenced by free_any_io(), rb_syck_io_str_read(), syck_emitter_add_level(), syck_emitter_pop_level(), syck_emitter_write(), syck_io_file_read(), syck_io_str_read(), syck_map_add(), syck_map_assign(), syck_map_count(), syck_map_empty(), syck_map_read(), syck_map_update(), syck_move_tokens(), syck_parse(), syck_parser_add_level(), syck_parser_bad_anchor_handler(), syck_parser_error_handler(), syck_parser_file(), syck_parser_handler(), syck_parser_pop_level(), syck_parser_read(), syck_parser_readlen(), syck_parser_set_input_type(), syck_parser_str(), syck_seq_add(), syck_seq_assign(), syck_seq_count(), syck_seq_empty(), syck_seq_read(), and syck_str_read().

#define BLOCK_FOLD 10

Definition at line 59 of file syck.h.

Referenced by sycklex_yaml_utf8().

#define BLOCK_LIT 20

Definition at line 60 of file syck.h.

Referenced by sycklex_yaml_utf8().

#define BLOCK_PLAIN 30

Definition at line 61 of file syck.h.

#define NL_CHOMP 40

Definition at line 62 of file syck.h.

Referenced by syck_emit_folded(), syck_emit_literal(), syck_emit_scalar(), and sycklex_yaml_utf8().

#define NL_KEEP 50

Definition at line 63 of file syck.h.

Referenced by syck_emit_folded(), syck_emit_literal(), syck_emit_scalar(), and sycklex_yaml_utf8().

#define NULL (void *)0

Definition at line 42 of file syck.h.

#define S_ALLOC | ( |  | type | ) | (type*)malloc(sizeof(type))

Definition at line 48 of file syck.h.

Referenced by bytestring_alloc(), syck_alloc_map(), syck_alloc_node(), syck_alloc_seq(), syck_alloc_str(), syck_emitter_s_alloc(), syck_new_emitter(), syck_new_parser(), syck_parser_file(), syck_parser_s_alloc(), and syck_parser_str().

#define S_ALLOC_N | ( |  | type,
|  |  | n
| ) |  | (type*)malloc(sizeof(type)*(n))

Definition at line 47 of file syck.h.

Referenced by bytestring_alloc(), get_inline(), syck_alloc_map(), syck_alloc_seq(), syck_base64enc(), syck_emit(), syck_emit_indent(), syck_emit_item(), syck_emitter_clear(), syck_emitter_mark_node(), syck_map_empty(), syck_new_emitter(), syck_new_parser(), syck_new_str2(), syck_parser_reset_cursor(), syck_replace_str2(), syck_seq_empty(), syck_strndup(), syck_taguri(), syck_type_id_to_uri(), syck_xprivate(), syck_yaml2byte(), syck_yaml2byte_handler(), sycklex_bytecode_utf8(), and sycklex_yaml_utf8().

#define S_ALLOCA_N | ( |  | type,
|  |  | n
| ) |  | (type*)alloca(sizeof(type)*(n))

Definition at line 52 of file syck.h.

Referenced by rb_syck_compile(), and syck_set_ivars().

#define S_FREE | ( |  | n | ) | if (n) { free(n); n = NULL; }

Definition at line 50 of file syck.h.

Referenced by free_any_io(), rb_syck_free_emitter(), rb_syck_free_parser(), syck_add_transfer(), syck_emit(), syck_emit_item(), syck_emit_scalar(), syck_free_emitter(), syck_free_members(), syck_free_node(), syck_free_parser(), syck_hdlr_get_anchor(), syck_map_empty(), syck_node_type_id_set(), syck_replace_str2(), syck_resolver_tagurize(), syck_seq_empty(), syck_st_free_anchors(), syck_st_free_syms(), syck_tagcmp(), syck_type_id_to_uri(), syck_yaml2byte_handler(), and try_tag_implicit().

#define S_MEMCMP | ( |  | p1,
|  |  | p2,
|  |  | type,
|  |  | n
| ) |  | memcmp((p1), (p2), sizeof(type)*(n))

Definition at line 57 of file syck.h.

#define S_MEMCPY | ( |  | p1,
|  |  | p2,
|  |  | type,
|  |  | n
| ) |  | memcpy((p1), (p2), sizeof(type)*(n))

Definition at line 55 of file syck.h.

Referenced by syck_emitter_write(), syck_io_str_read(), syck_strndup(), and sycklex_bytecode_utf8().

#define S_MEMMOVE | ( |  | p1,
|  |  | p2,
|  |  | type,
|  |  | n
| ) |  | memmove((p1), (p2), sizeof(type)*(n))

Definition at line 56 of file syck.h.

Referenced by syck_move_tokens().

#define S_MEMZERO | ( |  | p,
|  |  | type,
|  |  | n
| ) |  | memset((p), 0, sizeof(type)*(n))

Definition at line 54 of file syck.h.

Referenced by syck_emit(), syck_emitter_clear(), syck_emitter_mark_node(), syck_emitter_s_alloc(), syck_new_parser(), syck_parser_reset_cursor(), syck_parser_s_alloc(), and syck_strndup().

#define S_REALLOC_N | ( |  | var,
|  |  | type,
|  |  | n
| ) |  | (var)=(type*)realloc((char*)(var),sizeof(type)*(n))

Definition at line 49 of file syck.h.

Referenced by bytestring_append(), bytestring_extend(), syck_emitter_add_level(), syck_map_add(), syck_map_update(), syck_parser_add_level(), and syck_seq_add().

#define SYCK_BUFFERSIZE 4096

Definition at line 46 of file syck.h.

Referenced by syck_new_emitter(), syck_new_parser(), and syck_parser_read().

#define SYCK_YAML_MAJOR 1

Definition at line 12 of file syck.h.

Referenced by syck_emit().

#define SYCK_YAML_MINOR 0

Definition at line 13 of file syck.h.

Referenced by syck_emit().

#define SYMID unsigned long

Definition at line 72 of file syck.h.

Referenced by rb_syck_compile(), syck_add_sym(), syck_alloc_map(), syck_alloc_seq(), syck_emit(), syck_emitter_emit(), syck_emitter_mark_node(), syck_hdlr_add_node(), syck_map_add(), syck_map_empty(), syck_map_update(), syck_seq_add(), syck_seq_empty(), syck_yaml2byte(), and syck_yaml2byte_handler().

#define YAML_DOMAIN "yaml.org,2002"

Definition at line 15 of file syck.h.

Referenced by syck_emit_scalar(), syck_emit_tag(), syck_type_id_to_uri(), sycklex_yaml_utf8(), try_tag_implicit(), and yyparse().

## Typedef Documentation

typedef long st_data_t

Definition at line 69 of file syck.h.

typedef SyckNode*(* SyckBadAnchorHandler)(SyckParser *, char *)

Definition at line 155 of file syck.h.

typedef struct _syck_emitter SyckEmitter

Definition at line 265 of file syck.h.

typedef void(* SyckEmitterHandler)(SyckEmitter *, st_data_t)

Definition at line 269 of file syck.h.

typedef struct _syck_emitter_node SyckEmitterNode

Definition at line 266 of file syck.h.

typedef void(* SyckErrorHandler)(SyckParser *, const char *)

Definition at line 154 of file syck.h.

typedef struct _syck_file SyckIoFile

Definition at line 149 of file syck.h.

typedef long(* SyckIoFileRead)(char *, SyckIoFile *, long, long)

Definition at line 156 of file syck.h.

typedef struct _syck_str SyckIoStr

Definition at line 150 of file syck.h.

typedef long(* SyckIoStrRead)(char *, SyckIoStr *, long, long)

Definition at line 157 of file syck.h.

typedef struct _syck_level SyckLevel

Definition at line 151 of file syck.h.

typedef struct _syck_node SyckNode

Definition at line 74 of file syck.h.

typedef SYMID(* SyckNodeHandler)(SyckParser *, SyckNode *)

Definition at line 153 of file syck.h.

typedef void(* SyckOutputHandler)(SyckEmitter *, char *, long)

Definition at line 268 of file syck.h.

typedef struct _syck_parser SyckParser

Definition at line 148 of file syck.h.

## Enumeration Type Documentation

enum doc_stage

Enumerator:

  doc_open |
  doc_processing |

Definition at line 271 of file syck.h.

enum map_part

Enumerator:

  map_key |
  map_value |

Definition at line 82 of file syck.h.

enum map_style

Enumerator:

  map_none |
  map_inline |

Definition at line 87 of file syck.h.

enum scalar_style

Enumerator:

  scalar_none |
  scalar_1quote |
  scalar_2quote |
  scalar_fold |
  scalar_literal |
  scalar_plain |

Definition at line 97 of file syck.h.

enum seq_style

Enumerator:

  seq_none |
  seq_inline |

Definition at line 92 of file syck.h.

enum syck_io_type

Enumerator:

  syck_io_str |
  syck_io_file |

Definition at line 159 of file syck.h.

enum syck_kind_tag

Enumerator:

  syck_map_kind |
  syck_seq_kind |
  syck_str_kind |

Definition at line 76 of file syck.h.

enum syck_level_status

Enumerator:

  syck_lvl_header |
  syck_lvl_doc |
  syck_lvl_open |
  syck_lvl_seq |
  syck_lvl_map |
  syck_lvl_block |
  syck_lvl_str |
  syck_lvl_iseq |
  syck_lvl_imap |
  syck_lvl_end |
  syck_lvl_pause |
  syck_lvl_anctag |
  syck_lvl_mapx |
  syck_lvl_seqx |

Definition at line 171 of file syck.h.

enum syck_parser_input

Enumerator:

  syck_yaml_utf8 |
  syck_yaml_utf16 |
  syck_yaml_utf32 |
  syck_bytecode_utf8 |

Definition at line 164 of file syck.h.

## Function Documentation

void free_any_io | ( | SyckParser * |  | ) |

Definition at line 400 of file syck.c.

References ASSERT, _syck_parser::file, _syck_parser::io, _syck_parser::io_type, NULL, S_FREE, _syck_parser::str, syck_io_file, and syck_io_str.

Referenced by syck_free_parser(), syck_parser_file(), and syck_parser_str().

int syck_add_sym | ( | SyckParser * | ,
|  | void * |
| ) |  |

Definition at line 180 of file syck.c.

References id, NULL, st_table::num_entries, st_init_numtable, st_insert, SYMID, and _syck_parser::syms.

Referenced by syck_yaml2byte_handler().

void syck_add_transfer | ( | char * | ,
|  | SyckNode * | ,
|  | int |
| ) |  |

Definition at line 129 of file handler.c.

References NULL, S_FREE, syck_type_id_to_uri(), and _syck_node::type_id.

Referenced by yyparse().

SyckNode* syck_alloc_map | ( | void |  | ) |

Definition at line 48 of file node.c.

References ALLOC_CT, _syck_node::data, map_none, _syck_node::pairs, S_ALLOC, S_ALLOC_N, syck_alloc_node(), syck_map_kind, and SYMID.

Referenced by syck_map_alloc(), syck_new_map(), syck_node_transform(), and yyparse().

SyckNode* syck_alloc_seq | ( | void |  | ) |

Definition at line 67 of file node.c.

References ALLOC_CT, _syck_node::data, _syck_node::list, S_ALLOC, S_ALLOC_N, seq_none, syck_alloc_node(), syck_seq_kind, and SYMID.

Referenced by syck_new_seq(), syck_node_transform(), syck_seq_alloc(), and yyparse().

SyckNode* syck_alloc_str | ( | void |  | ) |

Definition at line 85 of file node.c.

References _syck_node::data, NULL, S_ALLOC, scalar_none, _syck_node::str, syck_alloc_node(), and syck_str_kind.

Referenced by syck_new_str2(), syck_scalar_alloc(), sycklex_bytecode_utf8(), and sycklex_yaml_utf8().

char* syck_base64dec | ( | char * | ,
|  | long |
| ) |  |

Definition at line 60 of file emitter.c.

References b64_table, len, and syck_strndup().

char* syck_base64enc | ( | char * | ,
|  | long |
| ) |  |

Definition at line 29 of file emitter.c.

References b64_table, and S_ALLOC_N.

void syck_default_error_handler | ( | SyckParser * | ,
|  | const char * |
| ) |  |

Definition at line 517 of file syck.c.

References _syck_parser::cursor, _syck_parser::linect, _syck_parser::lineptr, and PRIdPTRDIFF.

Referenced by syckerror().

void syck_emit | ( | SyckEmitter * | ,
|  | st_data_t |
| ) |  |

Definition at line 356 of file emitter.c.

References _syck_emitter::anchored, _syck_emitter::anchors, _syck_level::anctag, doc_open, doc_processing, _syck_emitter::emitter_handler, free, _syck_emitter::headless, _syck_emitter::indent, _syck_emitter::lvl_idx, _syck_emitter::markers, NULL, S_ALLOC_N, S_FREE, S_MEMZERO, _syck_level::spaces, st_init_numtable, st_insert, st_lookup, _syck_emitter::stage, syck_emitter_add_level(), syck_emitter_current_level(), syck_emitter_pop_level(), syck_emitter_write(), syck_lvl_open, SYCK_YAML_MAJOR, SYCK_YAML_MINOR, SYMID, _syck_emitter::use_header, and _syck_emitter::use_version.

Referenced by syck_emit_item(), and syck_emitter_emit().

void syck_emit_1quoted | ( | SyckEmitter * | ,
|  | int | ,
|  | const char * | ,
|  | long |
| ) |  |

Definition at line 806 of file emitter.c.

References syck_emit_indent(), and syck_emitter_write().

Referenced by syck_emit_scalar().

void syck_emit_2quoted | ( | SyckEmitter * | ,
|  | int | ,
|  | const char * | ,
|  | long |
| ) |  |

Definition at line 854 of file emitter.c.

References syck_emit_indent(), syck_emitter_escape(), and syck_emitter_write().

Referenced by syck_emit_scalar().

void syck_emit_end | ( | SyckEmitter * |  | ) |

Definition at line 1152 of file emitter.c.

References _syck_level::ncount, _syck_level::status, syck_emitter_current_level(), syck_emitter_parent_level(), syck_emitter_write(), syck_lvl_imap, syck_lvl_iseq, syck_lvl_map, syck_lvl_mapx, and syck_lvl_seq.

Referenced by rb_syck_emitter_handler().

void syck_emit_folded | ( | SyckEmitter * | ,
|  | int | ,
|  | char | ,
|  | const char * | ,
|  | long |
| ) |  |

Definition at line 951 of file emitter.c.

References _syck_emitter::best_width, NL_CHOMP, NL_KEEP, syck_emit_indent(), and syck_emitter_write().

Referenced by syck_emit_scalar().

void syck_emit_indent | ( | SyckEmitter * |  | ) |

Definition at line 491 of file emitter.c.

References _syck_emitter::buffer, _syck_emitter::bufpos, free, _syck_emitter::marker, S_ALLOC_N, _syck_level::spaces, syck_emitter_current_level(), and syck_emitter_write().

Referenced by syck_emit_1quoted(), syck_emit_2quoted(), syck_emit_folded(), syck_emit_item(), and syck_emit_literal().

void syck_emit_item | ( | SyckEmitter * | ,
|  | st_data_t |
| ) |  |

Definition at line 1044 of file emitter.c.

References _syck_level::anctag, _syck_level::ncount, S_ALLOC_N, S_FREE, _syck_level::spaces, _syck_level::status, syck_emit(), syck_emit_indent(), syck_emitter_current_level(), syck_emitter_parent_level(), syck_emitter_write(), syck_lvl_imap, syck_lvl_iseq, syck_lvl_map, syck_lvl_mapx, and syck_lvl_seq.

Referenced by rb_syck_emitter_handler().

void syck_emit_literal | ( | SyckEmitter * | ,
|  | char | ,
|  | const char * | ,
|  | long |
| ) |  |

Definition at line 915 of file emitter.c.

References len, NL_CHOMP, NL_KEEP, syck_emit_indent(), and syck_emitter_write().

Referenced by syck_emit_scalar().

void syck_emit_map | ( | SyckEmitter * | ,
|  | const char * | ,
|  | enum | map_style
| ) |  |

Definition at line 1022 of file emitter.c.

References map_inline, _syck_level::ncount, _syck_level::status, syck_emit_tag(), syck_emitter_current_level(), syck_emitter_parent_level(), syck_emitter_write(), syck_lvl_imap, syck_lvl_iseq, syck_lvl_map, and syck_lvl_mapx.

Referenced by rb_syck_emitter_handler().

void syck_emit_scalar | ( | SyckEmitter * | ,
|  | const char * | ,
|  | enum | scalar_style,
|  | int | ,
|  | int | ,
|  | char | ,
|  | const char * | ,
|  | long |
| ) |  |

Definition at line 641 of file emitter.c.

References _syck_emitter::explicit_typing, _syck_emitter::indent, _syck_level::ncount, NL_CHOMP, NL_KEEP, NULL, S_FREE, scalar_1quote, scalar_2quote, scalar_fold, scalar_literal, scalar_none, scalar_plain, SCAN_DOCSEP, SCAN_FLOWMAP, SCAN_FLOWSEQ, SCAN_INDENTED, SCAN_INDIC_C, SCAN_INDIC_S, SCAN_MANYNL_E, SCAN_NEWLINE, SCAN_NONL_E, SCAN_NONPRINT, SCAN_WHITEEDGE, _syck_level::spaces, _syck_level::status, _syck_emitter::style, syck_emit_1quoted(), syck_emit_2quoted(), syck_emit_folded(), syck_emit_literal(), syck_emit_tag(), syck_emitter_current_level(), syck_emitter_parent_level(), syck_emitter_write(), syck_lvl_imap, syck_lvl_iseq, syck_lvl_map, syck_lvl_mapx, syck_match_implicit(), syck_scan_scalar(), syck_tagcmp(), syck_taguri(), and YAML_DOMAIN.

Referenced by rb_syck_emitter_handler().

void syck_emit_seq | ( | SyckEmitter * | ,
|  | const char * | ,
|  | enum | seq_style
| ) |  |

Definition at line 1000 of file emitter.c.

References _syck_level::ncount, seq_inline, _syck_level::status, syck_emit_tag(), syck_emitter_current_level(), syck_emitter_parent_level(), syck_emitter_write(), syck_lvl_imap, syck_lvl_iseq, syck_lvl_map, syck_lvl_mapx, and syck_lvl_seq.

Referenced by rb_syck_emitter_handler().

void syck_emit_tag | ( | SyckEmitter * | ,
|  | const char * | ,
|  | const char * |
| ) |  |

Definition at line 440 of file emitter.c.

References _syck_level::anctag, _syck_emitter::explicit_typing, NULL, syck_emitter_current_level(), syck_emitter_write(), syck_tagcmp(), and YAML_DOMAIN.

Referenced by syck_emit_map(), syck_emit_scalar(), and syck_emit_seq().

void syck_emitter_add_level | ( | SyckEmitter * | ,
|  | int | ,
|  | enum | syck_level_status
| ) |  |

Definition at line 201 of file emitter.c.

References ALLOC_CT, _syck_level::anctag, ASSERT, _syck_level::domain, len, _syck_emitter::levels, _syck_emitter::lvl_capa, _syck_emitter::lvl_idx, _syck_level::ncount, NULL, S_REALLOC_N, _syck_level::spaces, _syck_level::status, and syck_strndup().

Referenced by syck_emit().

void syck_emitter_clear | ( | SyckEmitter * |  | ) |

Definition at line 268 of file emitter.c.

References _syck_emitter::buffer, _syck_emitter::bufpos, _syck_emitter::bufsize, _syck_emitter::marker, NULL, S_ALLOC_N, and S_MEMZERO.

Referenced by syck_emitter_write().

SyckLevel* syck_emitter_current_level | ( | SyckEmitter * |  | ) |

Definition at line 177 of file emitter.c.

References _syck_emitter::levels, and _syck_emitter::lvl_idx.

Referenced by syck_emit(), syck_emit_end(), syck_emit_indent(), syck_emit_item(), syck_emit_map(), syck_emit_scalar(), syck_emit_seq(), and syck_emit_tag().

void syck_emitter_escape | ( | SyckEmitter * | ,
|  | const char * | ,
|  | long |
| ) |  |

Definition at line 776 of file emitter.c.

References hex_table, len, and syck_emitter_write().

Referenced by syck_emit_2quoted().

void syck_emitter_flush | ( | SyckEmitter * | ,
|  | long |
| ) |  |

Definition at line 322 of file emitter.c.

References _syck_emitter::buffer, _syck_emitter::bufpos, _syck_emitter::bufsize, _syck_emitter::marker, and _syck_emitter::output_handler.

Referenced by syck_emitter_emit(), and syck_emitter_write().

void syck_emitter_handler | ( | SyckEmitter * | ,
|  | SyckEmitterHandler |
| ) |  |

Definition at line 239 of file emitter.c.

References _syck_emitter::emitter_handler.

Referenced by syck_emitter_s_alloc().

void syck_emitter_ignore_id | ( | SyckEmitter * | ,
|  | SYMID |
| ) |  |

SYMID syck_emitter_mark_node | ( | SyckEmitter * | ,
|  | st_data_t |
| ) |  |

Definition at line 1193 of file emitter.c.

References _syck_emitter::anchor_format, _syck_emitter::anchors, DEFAULT_ANCHOR_FORMAT, _syck_emitter::markers, NULL, st_table::num_entries, S_ALLOC_N, S_MEMZERO, st_init_numtable, st_insert, st_lookup, and SYMID.

Referenced by syck_emitter_emit().

SyckLevel* syck_emitter_parent_level | ( | SyckEmitter * |  | ) |

Definition at line 183 of file emitter.c.

References _syck_emitter::levels, and _syck_emitter::lvl_idx.

Referenced by syck_emit_end(), syck_emit_item(), syck_emit_map(), syck_emit_scalar(), and syck_emit_seq().

void syck_emitter_pop_level | ( | SyckEmitter * |  | ) |

Definition at line 189 of file emitter.c.

References ASSERT, _syck_level::domain, free, _syck_emitter::levels, _syck_emitter::lvl_idx, and NULL.

Referenced by syck_emit(), and syck_emitter_reset_levels().

void syck_emitter_reset_levels | ( | SyckEmitter * |  | ) |

Definition at line 220 of file emitter.c.

References _syck_level::anctag, _syck_level::domain, _syck_emitter::levels, _syck_emitter::lvl_idx, _syck_level::ncount, _syck_level::spaces, _syck_level::status, syck_emitter_pop_level(), syck_lvl_header, and syck_strndup().

Referenced by syck_free_emitter(), and syck_new_emitter().

void syck_emitter_write | ( | SyckEmitter * | ,
|  | const char * | ,
|  | long |
| ) |  |

Definition at line 284 of file emitter.c.

References ASSERT, _syck_emitter::buffer, _syck_emitter::bufsize, len, _syck_emitter::marker, NULL, S_MEMCPY, syck_emitter_clear(), and syck_emitter_flush().

Referenced by syck_emit(), syck_emit_1quoted(), syck_emit_2quoted(), syck_emit_end(), syck_emit_folded(), syck_emit_indent(), syck_emit_item(), syck_emit_literal(), syck_emit_map(), syck_emit_scalar(), syck_emit_seq(), syck_emit_tag(), and syck_emitter_escape().

void syck_free_emitter | ( | SyckEmitter * |  | ) |

Definition at line 251 of file emitter.c.

References _syck_emitter::buffer, _syck_level::domain, _syck_emitter::levels, NULL, S_FREE, syck_emitter_reset_levels(), and syck_emitter_st_free().

Referenced by rb_syck_free_emitter().

void syck_free_members | ( | SyckNode * |  | ) |

Definition at line 370 of file node.c.

References _syck_node::data, _syck_node::kind, _syck_node::list, NULL, _syck_node::pairs, S_FREE, _syck_node::str, syck_map_kind, syck_seq_kind, and syck_str_kind.

Referenced by syck_free_node().

void syck_free_node | ( | SyckNode * |  | ) |

Definition at line 31 of file node.c.

References _syck_node::anchor, NULL, S_FREE, syck_free_members(), and _syck_node::type_id.

Referenced by syck_hdlr_add_anchor(), syck_hdlr_add_node(), syck_hdlr_remove_anchor(), syck_map_alloc(), syck_node_transform(), syck_scalar_alloc(), syck_seq_alloc(), syck_st_free_nodes(), and yyparse().

void syck_free_parser | ( | SyckParser * |  | ) |

Definition at line 249 of file syck.c.

References _syck_parser::buffer, _syck_level::domain, free_any_io(), _syck_parser::levels, NULL, S_FREE, st_foreach, st_free_table, syck_parser_reset_levels(), syck_st_free(), syck_st_free_syms(), and _syck_parser::syms.

Referenced by rb_syck_compile(), rb_syck_free_parser(), and syck_yaml2byte().

SyckNode* syck_hdlr_add_anchor | ( | SyckParser * | ,
|  | char * | ,
|  | SyckNode * |
| ) |  |

Definition at line 31 of file handler.c.

References _syck_node::anchor, _syck_parser::anchors, bad, _syck_parser::bad_anchors, _syck_parser::handler, _syck_node::id, _syck_node::kind, NULL, st_init_strtable, st_insert, st_lookup, syck_free_node(), and syck_str_kind.

Referenced by yyparse().

SYMID syck_hdlr_add_node | ( | SyckParser * | ,
|  | SyckNode * |
| ) |  |

Definition at line 13 of file handler.c.

References _syck_node::anchor, _syck_parser::handler, _syck_node::id, id, NULL, syck_free_node(), and SYMID.

Referenced by apply_seq_in_map(), and yyparse().

SyckNode* syck_hdlr_get_anchor | ( | SyckParser * | ,
|  | char * |
| ) |  |

Definition at line 83 of file handler.c.

References _syck_node::anchor, _syck_parser::anchors, _syck_parser::bad_anchor_handler, _syck_parser::bad_anchors, NULL, S_FREE, st_init_strtable, st_insert, and st_lookup.

Referenced by yyparse().

void syck_hdlr_remove_anchor | ( | SyckParser * | ,
|  | char * |
| ) |  |

Definition at line 64 of file handler.c.

References _syck_parser::anchors, NULL, st_delete, st_init_strtable, st_insert, and syck_free_node().

Referenced by sycklex_bytecode_utf8(), and sycklex_yaml_utf8().

long syck_io_file_read | ( | char * | ,
|  | SyckIoFile * | ,
|  | long | ,
|  | long |
| ) |  |

Definition at line 46 of file syck.c.

References ASSERT, len, NULL, and _syck_file::ptr.

Referenced by syck_parser_file().

long syck_io_str_read | ( | char * | ,
|  | SyckIoStr * | ,
|  | long | ,
|  | long |
| ) |  |

Definition at line 64 of file syck.c.

References ASSERT, _syck_str::end, len, NULL, _syck_str::ptr, and S_MEMCPY.

Referenced by syck_parser_str().

int syck_lookup_sym | ( | SyckParser * | ,
|  | SYMID | ,
|  | void ** |
| ) |  |

Definition at line 193 of file syck.c.

References emitter_xtra::data, NULL, st_lookup, and _syck_parser::syms.

Referenced by rb_syck_compile(), syck_yaml2byte(), and syck_yaml2byte_handler().

void syck_map_add | ( | SyckNode * | ,
|  | SYMID | ,
|  | SYMID |
| ) |  |

Definition at line 197 of file node.c.

References ALLOC_CT, ASSERT, _syck_node::data, NULL, _syck_node::pairs, S_REALLOC_N, and SYMID.

Referenced by syck_map_add_m(), syck_map_initialize(), syck_map_value_set(), syck_new_map(), and syck_node_transform().

void syck_map_assign | ( | SyckNode * | ,
|  | enum | map_part,
|  | long | ,
|  | SYMID |
| ) |  |

Definition at line 259 of file node.c.

References ASSERT, _syck_node::data, id, map_key, NULL, and _syck_node::pairs.

Referenced by apply_seq_in_map().

long syck_map_count | ( | SyckNode * |  | ) |

Definition at line 251 of file node.c.

References ASSERT, _syck_node::data, NULL, and _syck_node::pairs.

Referenced by apply_seq_in_map(), and syck_genericresolver_node_import().

void syck_map_empty | ( | SyckNode * |  | ) |

Definition at line 181 of file node.c.

References ALLOC_CT, ASSERT, _syck_node::data, _syck_node::list, NULL, _syck_node::pairs, S_ALLOC_N, S_FREE, and SYMID.

Referenced by syck_map_value_set().

SYMID syck_map_read | ( | SyckNode * | ,
|  | enum | map_part,
|  | long |
| ) |  |

Definition at line 277 of file node.c.

References ASSERT, _syck_node::data, map_key, NULL, and _syck_node::pairs.

Referenced by rb_syck_emitter_handler(), syck_genericresolver_node_import(), syck_node_mark(), syck_node_transform(), syck_resolver_node_import(), syck_yaml2byte_handler(), and yaml_org_handler().

void syck_map_update | ( | SyckNode * | ,
|  | SyckNode * |
| ) |  |

Definition at line 219 of file node.c.

References ALLOC_CT, ASSERT, _syck_node::data, NULL, _syck_node::pairs, S_REALLOC_N, and SYMID.

Referenced by yyparse().

const char* syck_match_implicit | ( | const char * | ,
|  | size_t |
| ) |  |

Definition at line 48 of file implicit.c.

References len, YYCTYPE, YYCURSOR, YYFILL, YYLIMIT, and YYMARKER.

Referenced by syck_defaultresolver_detect_implicit(), syck_emit_scalar(), and try_tag_implicit().

SyckEmitter* syck_new_emitter | ( | void |  | ) |

Definition at line 108 of file emitter.c.

References ALLOC_CT, _syck_emitter::anchor_format, _syck_emitter::anchored, _syck_emitter::anchors, _syck_emitter::best_width, _syck_emitter::bonus, _syck_emitter::buffer, _syck_emitter::bufpos, _syck_emitter::bufsize, doc_open, _syck_emitter::emitter_handler, _syck_emitter::explicit_typing, _syck_emitter::headless, _syck_emitter::indent, _syck_emitter::level, _syck_emitter::levels, _syck_emitter::lvl_capa, _syck_emitter::lvl_idx, _syck_emitter::marker, _syck_emitter::markers, NULL, _syck_emitter::output_handler, S_ALLOC, S_ALLOC_N, scalar_none, _syck_emitter::sort_keys, _syck_emitter::stage, _syck_emitter::style, SYCK_BUFFERSIZE, syck_emitter_reset_levels(), _syck_emitter::use_header, and _syck_emitter::use_version.

Referenced by syck_emitter_s_alloc().

SyckNode* syck_new_map | ( | SYMID | ,
|  | SYMID |
| ) |  |

Definition at line 170 of file node.c.

References syck_alloc_map(), and syck_map_add().

Referenced by rb_syck_bad_anchor_handler(), and yyparse().

SyckParser* syck_new_parser | ( | void |  | ) |

Definition at line 157 of file syck.c.

References ALLOC_CT, _syck_parser::anchors, _syck_parser::bad_anchors, _syck_parser::buffer, _syck_parser::bufsize, _syck_parser::implicit_typing, _syck_parser::input_type, _syck_parser::io, _syck_parser::io_type, _syck_parser::levels, _syck_parser::lvl_capa, _syck_parser::lvl_idx, NULL, S_ALLOC, S_ALLOC_N, S_MEMZERO, _syck_parser::str, SYCK_BUFFERSIZE, syck_io_str, syck_parser_reset_levels(), syck_yaml_utf8, _syck_parser::syms, and _syck_parser::taguri_expansion.

Referenced by rb_syck_compile(), syck_parser_s_alloc(), and syck_yaml2byte().

SyckNode* syck_new_seq | ( | SYMID |  | ) |

Definition at line 295 of file node.c.

References syck_alloc_seq(), and syck_seq_add().

Referenced by yyparse().

SyckNode* syck_new_str | ( | const char * | ,
|  | enum | scalar_style
| ) |  |

Definition at line 102 of file node.c.

References syck_new_str2().

SyckNode* syck_new_str2 | ( | const char * | ,
|  | long | ,
|  | enum | scalar_style
| ) |  |

Definition at line 108 of file node.c.

References _syck_node::data, len, S_ALLOC_N, _syck_node::str, and syck_alloc_str().

Referenced by syck_new_str(), and syck_node_transform().

void syck_output_handler | ( | SyckEmitter * | ,
|  | SyckOutputHandler |
| ) |  |

Definition at line 245 of file emitter.c.

References _syck_emitter::output_handler.

Referenced by syck_emitter_s_alloc().

SYMID syck_parse | ( | SyckParser * |  | ) |

Definition at line 506 of file syck.c.

References ASSERT, NULL, _syck_parser::root, syck_parser_reset_levels(), syck_st_free(), and syckparse().

Referenced by rb_syck_compile(), syck_parser_load(), syck_parser_load_documents(), and syck_yaml2byte().

void syck_parser_add_level | ( | SyckParser * | ,
|  | int | ,
|  | enum | syck_level_status
| ) |  |

Definition at line 382 of file syck.c.

References ALLOC_CT, ASSERT, _syck_level::domain, len, _syck_parser::levels, _syck_parser::lvl_capa, _syck_parser::lvl_idx, _syck_level::ncount, NULL, S_REALLOC_N, _syck_level::spaces, _syck_level::status, and syck_strndup().

void syck_parser_bad_anchor_handler | ( | SyckParser * | ,
|  | SyckBadAnchorHandler |
| ) |  |

Definition at line 304 of file syck.c.

References ASSERT, _syck_parser::bad_anchor_handler, and NULL.

Referenced by syck_set_model().

SyckLevel* syck_parser_current_level | ( | SyckParser * |  | ) |

Definition at line 364 of file syck.c.

References _syck_parser::levels, and _syck_parser::lvl_idx.

void syck_parser_error_handler | ( | SyckParser * | ,
|  | SyckErrorHandler |
| ) |  |

Definition at line 297 of file syck.c.

References ASSERT, _syck_parser::error_handler, and NULL.

Referenced by rb_syck_compile(), syck_set_model(), and syck_yaml2byte().

void syck_parser_file | ( | SyckParser * | ,
|  | FILE * | ,
|  | SyckIoFileRead |
| ) |  |

Definition at line 318 of file syck.c.

References ASSERT, _syck_parser::file, free_any_io(), _syck_parser::io, _syck_parser::io_type, NULL, _syck_file::ptr, _syck_file::read, S_ALLOC, syck_io_file, syck_io_file_read(), and syck_parser_reset_cursor().

void syck_parser_handler | ( | SyckParser * | ,
|  | SyckNodeHandler |
| ) |  |

Definition at line 278 of file syck.c.

References ASSERT, _syck_parser::handler, and NULL.

Referenced by rb_syck_compile(), syck_set_model(), and syck_yaml2byte().

void syck_parser_implicit_typing | ( | SyckParser * | ,
|  | int |
| ) |  |

Definition at line 285 of file syck.c.

References _syck_parser::implicit_typing.

Referenced by rb_syck_compile(), syck_set_model(), and syck_yaml2byte().

void syck_parser_pop_level | ( | SyckParser * |  | ) |

Definition at line 370 of file syck.c.

References ASSERT, _syck_level::domain, free, _syck_parser::levels, _syck_parser::lvl_idx, and NULL.

Referenced by syck_parser_reset_levels().

long syck_parser_read | ( | SyckParser * |  | ) |

Definition at line 462 of file syck.c.

References ASSERT, _syck_parser::buffer, _syck_parser::file, _syck_parser::io, _syck_parser::io_type, len, NULL, _syck_file::read, _syck_str::read, _syck_parser::str, SYCK_BUFFERSIZE, syck_check_limit(), syck_io_file, syck_io_str, and syck_move_tokens().

Referenced by sycklex_bytecode_utf8(), and sycklex_yaml_utf8().

long syck_parser_readlen | ( | SyckParser * | ,
|  | long |
| ) |  |

Definition at line 484 of file syck.c.

References ASSERT, _syck_parser::buffer, _syck_parser::file, _syck_parser::io, _syck_parser::io_type, len, NULL, _syck_file::read, _syck_str::read, _syck_parser::str, syck_check_limit(), syck_io_file, syck_io_str, and syck_move_tokens().

void syck_parser_set_input_type | ( | SyckParser * | ,
|  | enum | syck_parser_input
| ) |  |

Definition at line 311 of file syck.c.

References ASSERT, _syck_parser::input_type, and NULL.

Referenced by syck_set_model().

void syck_parser_set_root_on_error | ( | SyckParser * | ,
|  | SYMID |
| ) |  |

Definition at line 148 of file syck.c.

References _syck_parser::root_on_error.

Referenced by syck_parser_s_alloc().

void syck_parser_str | ( | SyckParser * | ,
|  | char * | ,
|  | long | ,
|  | SyckIoStrRead |
| ) |  |

Definition at line 337 of file syck.c.

References ASSERT, _syck_str::beg, _syck_str::end, free_any_io(), _syck_parser::io, _syck_parser::io_type, len, NULL, _syck_str::ptr, _syck_str::read, S_ALLOC, _syck_parser::str, syck_io_str, syck_io_str_read(), and syck_parser_reset_cursor().

Referenced by syck_parser_assign_io(), and syck_parser_str_auto().

void syck_parser_str_auto | ( | SyckParser * | ,
|  | char * | ,
|  | SyckIoStrRead |
| ) |  |

Definition at line 358 of file syck.c.

References syck_parser_str().

Referenced by syck_yaml2byte().

void syck_parser_taguri_expansion | ( | SyckParser * | ,
|  | int |
| ) |  |

Definition at line 291 of file syck.c.

References _syck_parser::taguri_expansion.

Referenced by rb_syck_compile(), syck_set_model(), and syck_yaml2byte().

void syck_replace_str | ( | SyckNode * | ,
|  | char * | ,
|  | enum | scalar_style
| ) |  |

Definition at line 123 of file node.c.

References syck_replace_str2().

void syck_replace_str2 | ( | SyckNode * | ,
|  | char * | ,
|  | long | ,
|  | enum | scalar_style
| ) |  |

Definition at line 129 of file node.c.

References _syck_node::data, len, NULL, S_ALLOC_N, S_FREE, and _syck_node::str.

Referenced by syck_replace_str().

int syck_scan_scalar | ( | int | ,
|  | const char * | ,
|  | long |
| ) |  |

Definition at line 541 of file emitter.c.

References len, SCAN_DOCSEP, SCAN_DOUBLEQ, SCAN_FLOWMAP, SCAN_FLOWSEQ, SCAN_INDENTED, SCAN_INDIC_C, SCAN_INDIC_S, SCAN_MANYNL_E, SCAN_NEWLINE, SCAN_NONE, SCAN_NONL_E, SCAN_NONPRINT, SCAN_SINGLEQ, SCAN_WHITEEDGE, and SCAN_WIDE.

Referenced by syck_emit_scalar().

void syck_seq_add | ( | SyckNode * | ,
|  | SYMID |
| ) |  |

Definition at line 320 of file node.c.

References ALLOC_CT, ASSERT, _syck_node::data, _syck_node::list, NULL, S_REALLOC_N, and SYMID.

Referenced by syck_new_seq(), syck_node_transform(), syck_seq_add_m(), syck_seq_value_set(), and yyparse().

void syck_seq_assign | ( | SyckNode * | ,
|  | long | ,
|  | SYMID |
| ) |  |

Definition at line 348 of file node.c.

References ASSERT, _syck_node::data, id, _syck_node::list, and NULL.

long syck_seq_count | ( | SyckNode * |  | ) |

Definition at line 340 of file node.c.

References ASSERT, _syck_node::data, _syck_node::list, and NULL.

Referenced by syck_genericresolver_node_import().

void syck_seq_empty | ( | SyckNode * |  | ) |

Definition at line 306 of file node.c.

References ALLOC_CT, ASSERT, _syck_node::data, _syck_node::list, NULL, S_ALLOC_N, S_FREE, and SYMID.

Referenced by syck_seq_value_set().

SYMID syck_seq_read | ( | SyckNode * | ,
|  | long |
| ) |  |

Definition at line 359 of file node.c.

References ASSERT, _syck_node::data, _syck_node::list, and NULL.

Referenced by rb_syck_emitter_handler(), syck_genericresolver_node_import(), syck_node_mark(), syck_node_transform(), syck_resolver_node_import(), syck_yaml2byte_handler(), and yaml_org_handler().

void syck_str_blow_away_commas | ( | SyckNode * |  | ) |

Definition at line 145 of file node.c.

References _syck_node::data, memmove(), and _syck_node::str.

Referenced by yaml_org_handler().

char* syck_str_read | ( | SyckNode * |  | ) |

Definition at line 163 of file node.c.

References ASSERT, _syck_node::data, NULL, and _syck_node::str.

char* syck_strndup | ( | const char * | ,
|  | long |
| ) |  |

Definition at line 34 of file syck.c.

References S_ALLOC_N, S_MEMCPY, and S_MEMZERO.

Referenced by rb_syck_bad_anchor_handler(), syck_base64dec(), syck_emitter_add_level(), syck_emitter_reset_levels(), syck_node_transform(), syck_node_type_id_set(), syck_parser_add_level(), syck_parser_reset_levels(), syck_scalar_value_set(), syck_tagcmp(), syck_type_id_to_uri(), sycklex_bytecode_utf8(), sycklex_yaml_utf8(), try_tag_implicit(), and yyparse().

int syck_tagcmp | ( | const char * | ,
|  | const char * |
| ) |  |

Definition at line 1588 of file implicit.c.

References NULL, S_FREE, strstr(), and syck_strndup().

Referenced by syck_emit_scalar(), and syck_emit_tag().

char* syck_taguri | ( | const char * | ,
|  | const char * | ,
|  | int |
| ) |  |

Definition at line 157 of file handler.c.

References S_ALLOC_N.

Referenced by syck_emit_scalar(), syck_type_id_to_uri(), sycklex_yaml_utf8(), try_tag_implicit(), and yyparse().

int syck_try_implicit | ( | SyckNode * |  | ) |

Definition at line 169 of file handler.c.

char* syck_type_id_to_uri | ( | const char * |  | ) |

Definition at line 1612 of file implicit.c.

References S_ALLOC_N, S_FREE, syck_strndup(), syck_taguri(), syck_xprivate(), YAML_DOMAIN, YYCTYPE, YYCURSOR, YYFILL, YYLIMIT, and YYMARKER.

Referenced by syck_add_transfer(), and syck_resolver_tagurize().

char* syck_xprivate | ( | const char * | ,
|  | int |
| ) |  |

Definition at line 147 of file handler.c.

References S_ALLOC_N.

Referenced by syck_type_id_to_uri().

char* syck_yaml2byte | ( | char * |  | ) |

Definition at line 217 of file yaml2byte.c.

References bytestring_t::buffer, NULL, S_ALLOC_N, syck_free_parser(), syck_lookup_sym(), syck_new_parser(), syck_parse(), syck_parser_error_handler(), syck_parser_handler(), syck_parser_implicit_typing(), syck_parser_str_auto(), syck_parser_taguri_expansion(), syck_yaml2byte_handler(), and SYMID.

SYMID syck_yaml2byte_handler | ( | SyckParser * | ,
|  | SyckNode * |
| ) |  |

Definition at line 118 of file yaml2byte.c.

References _syck_node::anchor, assert, bytestring_alloc(), bytestring_append(), bytestring_extend(), _syck_node::data, _syck_node::kind, _syck_node::list, map_key, map_value, NULL, _syck_node::pairs, S_ALLOC_N, S_FREE, _syck_node::str, syck_add_sym(), syck_lookup_sym(), syck_map_kind, syck_map_read(), syck_seq_kind, syck_seq_read(), syck_str_kind, SYMID, _syck_node::type_id, YAMLBYTE_ANCHOR, YAMLBYTE_CONTINUE, YAMLBYTE_END_BRANCH, YAMLBYTE_MAPPING, YAMLBYTE_NEWLINE, YAMLBYTE_NULLCHAR, YAMLBYTE_SCALAR, YAMLBYTE_SEQUENCE, and YAMLBYTE_TRANSFER.

Referenced by rb_syck_compile(), and syck_yaml2byte().

void syckerror | ( | const char * |  | ) |

Definition at line 2716 of file token.c.

References _syck_parser::error_handler, NULL, _syck_parser::root, _syck_parser::root_on_error, and syck_default_error_handler().

Referenced by sycklex().

int sycklex | ( | union YYSTYPE * | ,
|  | SyckParser * |
| ) |  |

Definition at line 252 of file token.c.

References _syck_parser::input_type, syck_bytecode_utf8, syck_yaml_utf16, syck_yaml_utf32, syck_yaml_utf8, syckerror(), sycklex_bytecode_utf8(), sycklex_yaml_utf8(), and YAML_DOCSEP.

int syckparse | ( | void * |  | ) |

Referenced by syck_parse().

void try_tag_implicit | ( | SyckNode * | ,
|  | int |
| ) |  |

Definition at line 21 of file implicit.c.

References _syck_node::data, _syck_node::kind, NULL, S_FREE, _syck_node::str, syck_map_kind, syck_match_implicit(), syck_seq_kind, syck_str_kind, syck_strndup(), syck_taguri(), _syck_node::type_id, and YAML_DOMAIN.

Referenced by sycklex_bytecode_utf8(), and yyparse().