From 9fd33f4864310c017a1013f8d18635c1e784f0ab Mon Sep 17 00:00:00 2001 From: mryouse Date: Fri, 29 Jul 2022 19:56:22 +0000 Subject: have builtins return :nil when appropriate --- neb/structs.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'neb/structs.py') diff --git a/neb/structs.py b/neb/structs.py index 2423a69..db71aa0 100644 --- a/neb/structs.py +++ b/neb/structs.py @@ -169,6 +169,11 @@ class List: def __str__(self): return "(" + " ".join(f"{arg}" for arg in self.args) + ")" +class Nil(List): + def __init__(self): + self.args = [] + self.type_ = ALL_TYPES[":nil"] + # function things class Arg: -- cgit v1.2.3