summaryrefslogtreecommitdiffhomepage
path: root/examples/box.c
diff options
context:
space:
mode:
authorTyge Løvset <[email protected]>2021-12-22 12:35:36 +0100
committerTyge Løvset <[email protected]>2021-12-22 12:35:36 +0100
commit79c83eba7933f49e766dbeb85f9c40ee17e06edf (patch)
treee43a84d18b79956a8e22b9403358811b6865f344 /examples/box.c
parent7a30e2853792870a1d85087861e46a1ae1ca6b0e (diff)
downloadSTC-modified-79c83eba7933f49e766dbeb85f9c40ee17e06edf.tar.gz
STC-modified-79c83eba7933f49e766dbeb85f9c40ee17e06edf.zip
Renamed csptr to carc. i_key/val_ref renamed to i_key/val_sptr. Change inspired by Rust Arc/Rc. cbox name is taken from Rust Box type.
Diffstat (limited to 'examples/box.c')
-rw-r--r--examples/box.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/examples/box.c b/examples/box.c
index ae10a89f..d97545b6 100644
--- a/examples/box.c
+++ b/examples/box.c
@@ -28,10 +28,9 @@ void Person_drop(Person* p) {
#include <stc/cbox.h>
#define i_type Persons
-#define i_val_ref PBox // binds PBox_cmp, ...
+#define i_val_sptr PBox // informs that PBox is a smart pointer.
#include <stc/cvec.h>
-
int main()
{
c_auto (Persons, vec)