Blender  V3.3
BLI_dynstr.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later
2  * Copyright 2001-2002 NaN Holding BV. All rights reserved. */
3 
4 #pragma once
5 
16 #include <stdarg.h>
17 
18 #include "BLI_compiler_attrs.h"
19 
20 #ifdef __cplusplus
21 extern "C" {
22 #endif
23 
24 struct DynStr;
25 
27 typedef struct DynStr DynStr;
28 
41 
48 void BLI_dynstr_append(DynStr *__restrict ds, const char *cstr) ATTR_NONNULL();
56 void BLI_dynstr_nappend(DynStr *__restrict ds, const char *cstr, int len) ATTR_NONNULL();
57 
64 void BLI_dynstr_appendf(DynStr *__restrict ds, const char *__restrict format, ...)
66 void BLI_dynstr_vappendf(DynStr *__restrict ds, const char *__restrict format, va_list args)
67  ATTR_PRINTF_FORMAT(2, 0) ATTR_NONNULL(1, 2);
68 
92 void BLI_dynstr_get_cstring_ex(const DynStr *__restrict ds, char *__restrict rets) ATTR_NONNULL();
93 
106 
107 #ifdef __cplusplus
108 }
109 #endif
#define ATTR_WARN_UNUSED_RESULT
#define ATTR_MALLOC
DynStr * BLI_dynstr_new(void) ATTR_MALLOC ATTR_WARN_UNUSED_RESULT
Definition: BLI_dynstr.c:50
void ATTR_NONNULL(1, 2)
void BLI_dynstr_nappend(DynStr *__restrict ds, const char *cstr, int len) ATTR_NONNULL()
Definition: BLI_dynstr.c:94
int BLI_dynstr_get_len(const DynStr *ds) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
Definition: BLI_dynstr.c:235
char * BLI_dynstr_get_cstring(const DynStr *ds) ATTR_MALLOC ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
Definition: BLI_dynstr.c:256
void BLI_dynstr_vappendf(DynStr *__restrict ds, const char *__restrict format, va_list args) ATTR_PRINTF_FORMAT(2
void BLI_dynstr_clear(DynStr *ds) ATTR_NONNULL()
Definition: BLI_dynstr.c:263
void BLI_dynstr_free(DynStr *ds) ATTR_NONNULL()
Definition: BLI_dynstr.c:281
DynStr * BLI_dynstr_new_memarena(void) ATTR_MALLOC ATTR_WARN_UNUSED_RESULT
Definition: BLI_dynstr.c:60
void BLI_dynstr_appendf(DynStr *__restrict ds, const char *__restrict format,...) ATTR_PRINTF_FORMAT(2
void BLI_dynstr_get_cstring_ex(const DynStr *__restrict ds, char *__restrict rets) ATTR_NONNULL()
Definition: BLI_dynstr.c:240
void BLI_dynstr_append(DynStr *__restrict ds, const char *cstr) ATTR_NONNULL()
Definition: BLI_dynstr.c:75
size_t ATTR_PRINTF_FORMAT(3, 4)
int len
Definition: draw_manager.c:108
format
Definition: logImageCore.h:38