Implement OBLISTs
[muddle-interpreter.git] / src / read.c
index b8570f3778f09fa13f134a1a2af088d00e1cce9e..0f6a63d840108567ed2180c37dbe70afca1b5df0 100644 (file)
@@ -18,6 +18,7 @@ License along with this file. If not, see
 
 #include "read.h"
 #include "object.h"
+#include "oblist.h"
 
 #include <assert.h>
 #include <stdio.h>
@@ -262,7 +263,7 @@ read_token (const char *p, reader_stack * st)
        n = count_pname (p);
        if (n > 0)
          {
-           (--(st->pos))->atom = new_atom (0);
+           (--(st->pos))->atom = oblist_find_or_insert (root, p, n);
            st->framelen++;
            return p + n;
          }