Fix some read errors
This commit is contained in:
@ -444,3 +444,6 @@
|
|||||||
(t (print obj)))
|
(t (print obj)))
|
||||||
(when newline
|
(when newline
|
||||||
(println)))
|
(println)))
|
||||||
|
|
||||||
|
(breakpoint)
|
||||||
|
'
|
||||||
|
@ -486,6 +486,9 @@ static LispVal *read_internal(struct ReadState *state) {
|
|||||||
case '\'': {
|
case '\'': {
|
||||||
popc(state); // '
|
popc(state); // '
|
||||||
LispVal *tail = read_internal(state);
|
LispVal *tail = read_internal(state);
|
||||||
|
if (!tail) {
|
||||||
|
READ_ERROR(state, 1, "quote not quoting anything");
|
||||||
|
}
|
||||||
LispVal *res = Fpair(Qquote, Fpair(tail, Qnil));
|
LispVal *res = Fpair(Qquote, Fpair(tail, Qnil));
|
||||||
refcount_unref(tail);
|
refcount_unref(tail);
|
||||||
refcount_unref(TAIL(res));
|
refcount_unref(TAIL(res));
|
||||||
|
Reference in New Issue
Block a user