diff options
| author | Mistivia <i@mistivia.com> | 2025-06-19 22:02:56 +0800 |
|---|---|---|
| committer | Mistivia <i@mistivia.com> | 2025-06-19 22:02:56 +0800 |
| commit | b7faf6f020743afb1c06161bc1696f66e0b788e0 (patch) | |
| tree | 261b4638c9545f14858cd8eed0ea9703cbdacec7 /src/sexp.h | |
| parent | 8e51de8109a682068b4e7ac5f57adf8e450b1415 (diff) | |
add userfunc
Diffstat (limited to 'src/sexp.h')
| -rw-r--r-- | src/sexp.h | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -24,6 +24,10 @@ typedef struct { SExpRef env; } SExpFunc; +struct interp; +typedef struct interp Interp; +typedef SExpRef (*LispUserFunc)(Interp *interp, SExpRef args); + typedef struct { SExpRef args; SExpRef body; @@ -53,6 +57,7 @@ typedef enum { kUserDataSExp, kPairSExp, kFuncSExp, + kUserFuncSExp, kEnvSExp, kBindingSExp, kMacroSExp, @@ -71,6 +76,7 @@ struct sexp { const void *userdata; SExpPair pair; SExpFunc func; + LispUserFunc userfunc; SExpEnv env; SExpBinding binding; SExpMacro macro; |
