summaryrefslogtreecommitdiff
path: root/starts/meaning-vm/level-0/concept.cpp
diff options
context:
space:
mode:
authorolpc user <olpc@xo-5d-f7-86.localdomain>2019-11-24 19:23:37 -0800
committerolpc user <olpc@xo-5d-f7-86.localdomain>2019-11-24 19:23:37 -0800
commitcd03e291664cb102bde61d86a15f0add11809766 (patch)
tree9afb4bc872236b95debd5e20daf00797c563c666 /starts/meaning-vm/level-0/concept.cpp
parentdbbed1e4e1d4b3f268c71236c89f1d673fa0c165 (diff)
downloadstandingwithresilience-cd03e291664cb102bde61d86a15f0add11809766.tar.gz
standingwithresilience-cd03e291664cb102bde61d86a15f0add11809766.zip
messy but works. rushing to get this done with may have been a poor investment.
Diffstat (limited to 'starts/meaning-vm/level-0/concept.cpp')
-rw-r--r--starts/meaning-vm/level-0/concept.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/starts/meaning-vm/level-0/concept.cpp b/starts/meaning-vm/level-0/concept.cpp
index 579cca8..dace7df 100644
--- a/starts/meaning-vm/level-0/concept.cpp
+++ b/starts/meaning-vm/level-0/concept.cpp
@@ -12,7 +12,7 @@ ref concept::id()
void concept::link(ref const & type, ref const & target)
{
- links.insert({type.ptr, target.ptr});
+ links.insert({type, target});
}
void concept::unlink(ref const & type, ref const & target)
@@ -43,7 +43,7 @@ void concept::unlink(ref const & type)
bool concept::linked(ref const & type) const
{
- return links.count(type.ptr) > 0;
+ return links.count(type) > 0;
}
bool concept::linked(ref const & type, ref const & target) const
@@ -71,7 +71,7 @@ concept::array concept::getAll(ref const & type) const
ref concept::get(ref const & type) const
{
- auto result = links.equal_range(type.ptr);
+ auto result = links.equal_range(type);
if (result.first == result.second) {
throw no_such_link_type(selfref, type);
}