@@ -91,22 +91,6 @@ struct string_list *string_split(const char *str, const char *delim);
9191bool string_split_noalloc (struct string_list * list ,
9292 const char * str , const char * delim );
9393
94- /**
95- * string_separate:
96- * @str : string to turn into a string list
97- * @delim : delimiter character to use for separating the string.
98- *
99- * Creates a new string list based on string @str, delimited by @delim.
100- * Includes empty strings - i.e. two adjacent delimiters will resolve
101- * to a string list element of "".
102- *
103- * @return New string list if successful, otherwise NULL.
104- **/
105- struct string_list * string_separate (char * str , const char * delim );
106-
107- bool string_separate_noalloc (struct string_list * list ,
108- char * str , const char * delim );
109-
11094bool string_list_deinitialize (struct string_list * list );
11195
11296bool string_list_initialize (struct string_list * list );
@@ -137,25 +121,6 @@ struct string_list *string_list_new(void);
137121bool string_list_append (struct string_list * list , const char * elem ,
138122 union string_list_elem_attr attr );
139123
140- /**
141- * string_list_append_n:
142- * @list : pointer to string list
143- * @elem : element to add to the string list
144- * @length : read at most this many bytes from elem
145- * @attr : attributes of new element.
146- *
147- * Appends a new element to the string list.
148- *
149- * Hidden non-leaf function cost:
150- * - Calls string_list_capacity()
151- * - Calls malloc
152- * - Calls strlcpy
153- *
154- * @return true if successful, otherwise false.
155- **/
156- bool string_list_append_n (struct string_list * list , const char * elem ,
157- unsigned length , union string_list_elem_attr attr );
158-
159124/**
160125 * string_list_free
161126 * @list : pointer to string list object
@@ -200,19 +165,15 @@ void string_list_join_concat_special(char *s, size_t len,
200165 const struct string_list * list , const char * delim );
201166
202167/**
203- * string_list_set :
168+ * string_list_capacity :
204169 * @list : pointer to string list
205- * @idx : index of element in string list
206- * @str : value for the element.
170+ * @cap : new capacity for string list.
207171 *
208- * Set value of element inside string list.
172+ * Change maximum capacity of string list's size .
209173 *
210- * Hidden non-leaf function cost:
211- * - Calls free
212- * - Calls strdup
174+ * @return true if successful, otherwise false.
213175 **/
214- void string_list_set (struct string_list * list , unsigned idx ,
215- const char * str );
176+ bool string_list_capacity (struct string_list * list , size_t cap );
216177
217178struct string_list * string_list_clone (const struct string_list * src );
218179
0 commit comments