From a9c0f215e3e98c165de07d9661595b0dd64cc4fb Mon Sep 17 00:00:00 2001 From: Tyge Lovset Date: Tue, 19 Apr 2022 21:15:49 +0200 Subject: Renamed cbox_new/carc_new to cbox_make/carc_make. Disabled container emplace on arcbox elements. --- docs/cbox_api.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/cbox_api.md') diff --git a/docs/cbox_api.md b/docs/cbox_api.md index 0faea829..f1e93e62 100644 --- a/docs/cbox_api.md +++ b/docs/cbox_api.md @@ -9,7 +9,7 @@ When declaring a container of **cbox** values, define `i_val_arcbox` with the cbox type instead of defining `i_val`. This will auto-set `i_valdrop`, `i_valfrom`, and `i_cmp` using functions defined by the specified **cbox**. -For containers, make sure to pass the result of create functions like *cbox_X_new()* **only** to +For containers, make sure to pass the result of create functions like *cbox_X_make()* **only** to *insert()*, *push_back()*, and *push()* functions. Use the *emplace()* functions in order to auto-*clone* an already existing/owned cbox element. @@ -35,7 +35,7 @@ compare the pointer addresses when used. Additionally, `c_no_clone` or `i_is_fwd ## Methods ```c cbox_X cbox_X_init(); // return an empty cbox -cbox_X cbox_X_new(i_valraw raw); // like cbox_X_from(), but create owned value from raw. +cbox_X cbox_X_make(i_valraw raw); // like cbox_X_from(), but create owned value from raw. // NB! available only if i_valraw is defined. cbox_X cbox_X_from(i_val val); // allocate new heap object with val. Take ownership of val. cbox_X cbox_X_from_ptr(i_val* p); // create a cbox from a pointer. Takes ownership of p. -- cgit v1.2.3