This commit is contained in:
2026-05-18 07:07:24 -06:00
parent 11bfd20e5d
commit 4ef6788029
5 changed files with 103 additions and 3 deletions
+18
View File
@@ -1,4 +1,5 @@
#include <stdio.h>
#include <gc.h>
#include "gyehoek.h"
SCM scm_newline () {
@@ -14,3 +15,20 @@ SCM scm_write (SCM x) {
}
return SCM_PACK(NULL);
}
SCM scm_words (scm_t_bits word_0, uint32_t n_words) {
scm_t_bits *r = GC_malloc (n_words * sizeof (scm_t_bits));
r[0] = word_0;
return SCM_PACK (r);
}
SCM scm_from_utf8_string (const char *str, size_t len) {
SCM r = scm_words (scm_tc7_string, 3);
const char *s = GC_malloc (len);
SCM_SET_CELL_WORD (r, 1, len);
SCM_SET_CELL_WORD (r, 2, s);
return r;
}
SCM scm_from_utf8_symbol (const char *s) {
}