tisp

tiny lisp
git clone git://edryd.org/tisp
Log | Files | Refs | LICENSE

commit 342c41a85d826c9516f775c249aa38dee351d695
parent 5776d3ce089594b93954b02a04ba52dac38a1660
Author: Ed van Bruggen <edvb@uw.edu>
Date:   Sun, 12 Aug 2018 15:29:51 -0700

Remove linenoise hints

Diffstat:
config.def.h | 1-
main.c | 20--------------------
2 files changed, 0 insertions(+), 21 deletions(-)

diff --git a/config.def.h b/config.def.h @@ -1,2 +1 @@ -#define SHOW_HINTS 1 #define USE_LINENOISE 1 /* TODO implement */ diff --git a/main.c b/main.c @@ -14,24 +14,6 @@ char *argv0; -char * -hints(const char *buf, int *color, int *bold) -{ - struct { char *match, *hint; int color, bold; } hint[] = { - { "(lambda", " (args) body)", 35, 0 }, - { "(define", " var exp)", 35, 0 }, - { NULL, NULL, 0, 0 } - }; - for (int i = 0; hint[i].match; i++) { - if (!strcasecmp(buf, hint[i].match)) { - *color = hint[i].color; - *bold = hint[i].bold; - return hint[i].hint; - } - } - return NULL; -} - static Val read_val(Env env, Str cmd) { @@ -40,8 +22,6 @@ read_val(Env env, Str cmd) if (cmd->d) return tisp_read(env, cmd); - if (SHOW_HINTS) - linenoiseSetHintsCallback(hints); if (!(str.d = linenoise("> "))) return NULL; linenoiseHistoryAdd(str.d);