#include <stdarg.h>#include <malloc.h>#include <stdio.h>#include <string.h>#include "vstring.h"#include "errors.h"

Go to the source code of this file.
Defines | |
| #define | USE_STANDARD_TYPES |
| #define | MAX(a, b) ((a>=b)?a:b) |
| #define | vstr_max(v) ((v).max+0) |
| #define | set_vstr_max(v, m) (v).max = m |
| #define | set_vstr_len(v, l) (v).len = l |
| #define | set_vstr_str(v, s) (v).str = s |
Functions/Subroutines | |
| static void | Realloc_Vstring (vstring *v, int newlen) |
| vstring | vstr_begin (int len) |
| void | vstr_end (vstring v) |
| vstring | vstr_append (vstring v, const char c) |
| vstring | vstr_concat (vstring v, const char *s) |
| int | vstr_sprintf (vstring *v, int index, const char *format,...) |
Variables | |
| static vstring | current_vstring = {0,0,NULL} |
| #define set_vstr_len | ( | v, | |||
| l | ) | (v).len = l |
Definition at line 55 of file vstring.c.
Referenced by vstr_begin(), vstr_concat(), vstr_end(), and vstr_sprintf().
| #define set_vstr_max | ( | v, | |||
| m | ) | (v).max = m |
| #define set_vstr_str | ( | v, | |||
| s | ) | (v).str = s |
| #define vstr_max | ( | v | ) | ((v).max+0) |
Definition at line 53 of file vstring.c.
Referenced by Realloc_Vstring(), vstr_append(), vstr_begin(), vstr_concat(), and vstr_sprintf().
Definition at line 61 of file vstring.c.
References MAX, realloc, set_vstr_max, set_vstr_str, vstr_max, and vstr_str.
Referenced by vstr_append(), vstr_begin(), vstr_concat(), and vstr_sprintf().
Definition at line 106 of file vstring.c.
References vstring::len, Realloc_Vstring(), vstring::str, vstr_len, and vstr_max.
Referenced by r_assemble_list().
| vstring vstr_begin | ( | int | len | ) |
Definition at line 79 of file vstring.c.
References DevWarn, malloc, Realloc_Vstring(), set_vstr_len, set_vstr_max, set_vstr_str, vstr_len, and vstr_max.
Referenced by ErrMsg_Report_Nonuser(), ErrMsg_Report_User(), and r_assemble_list().
Definition at line 118 of file vstring.c.
References Realloc_Vstring(), set_vstr_len, strcpy, strlen(), vstr_len, vstr_max, and vstr_str.
Referenced by CGEMIT_Relocs_In_Asm(), ErrMsg_Report_Nonuser(), ErrMsg_Report_User(), print_prefetch_info(), put_TN_comment(), r_apply_l_const(), and r_assemble_list().
Definition at line 97 of file vstring.c.
References set_vstr_len, and vstring::str.
Referenced by ErrMsg_Report_Nonuser(), ErrMsg_Report_User(), and r_assemble_list().
| int vstr_sprintf | ( | vstring * | v, | |
| int | index, | |||
| const char * | format, | |||
| ... | ||||
| ) |
Definition at line 136 of file vstring.c.
References Fatal_Error(), len, p, Realloc_Vstring(), set_vstr_len, vstring::str, strlen(), va_arg, va_end, va_start, vsprintf(), vstr_len, and vstr_max.
Referenced by ErrMsg_Report_Nonuser(), ErrMsg_Report_User(), put_TN_comment(), r_apply_l_const(), and r_assemble_list().
vstring current_vstring = {0,0,NULL} [static] |
1.5.6