about summary refs log tree commit diff stats
path: root/033exclusive_container.cc
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2015-11-06 11:31:37 -0800
committerKartik K. Agaram <vc@akkartik.com>2015-11-06 11:31:37 -0800
commit12f304a333ecee6326a8111e0d8e1c494ee92087 (patch)
tree5af25c6e5988ae686889f8f462de7d39cc8aad3f /033exclusive_container.cc
parent795f5244abc9b9f26ff621fd1997db427289d2ba (diff)
downloadmu-12f304a333ecee6326a8111e0d8e1c494ee92087.tar.gz
2378
Now we're starting to run up against the misbehavior introduced by
generics: Type tries to insert rows for type ingredients. That is a
no-no.
Diffstat (limited to '033exclusive_container.cc')
-rw-r--r--033exclusive_container.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/033exclusive_container.cc b/033exclusive_container.cc
index bf14d9d7..7bf8cca8 100644
--- a/033exclusive_container.cc
+++ b/033exclusive_container.cc
@@ -8,7 +8,7 @@
 //: We'll use this container as a running example, with two number elements.
 {
 type_ordinal tmp = put(Type_ordinal, "number-or-point", Next_type_ordinal++);
-get(Type, tmp).size = 2;
+get_or_insert(Type, tmp).size = 2;
 get(Type, tmp).kind = EXCLUSIVE_CONTAINER;
 get(Type, tmp).name = "number-or-point";
 get(Type, tmp).elements.push_back(new type_tree(number));