From 1777b78f88ddf2089e51ad110e4390a30d25b0fe Mon Sep 17 00:00:00 2001 From: Shinya Sato Date: Sun, 17 Oct 2021 18:15:58 +0900 Subject: v0.4.2 --- src/inpla.y | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'src/inpla.y') diff --git a/src/inpla.y b/src/inpla.y index 0089333..ff65f39 100644 --- a/src/inpla.y +++ b/src/inpla.y @@ -7,6 +7,8 @@ #include #include +#include "linenoise/linenoise.h" + #include "ast.h" #include "id_table.h" #include "name_table.h" @@ -46,8 +48,8 @@ int ActiveThreadNum=0; //#define YYDEBUG 1 -#define VERSION "0.4.1" -#define BUILT_DATE "22 Sept. 2021" +#define VERSION "0.4.2" +#define BUILT_DATE "16 Oct. 2021" extern FILE *yyin; @@ -1117,6 +1119,7 @@ void puts_term(VALUE ptr) { Puts_list_element++; if (Puts_list_element > PUTS_ELEMENTS_NUM) { printf("...]"); + Puts_list_element=0; break; } @@ -1331,7 +1334,7 @@ void freeAgentRec(VALUE ptr) { } else { if (BASIC(ptr)->id == ID_CONS) { if (IS_FIXNUM(AGENT(ptr)->port[0])) { - VALUE port1 = AGENT(ptr)->port[0]; + VALUE port1 = AGENT(ptr)->port[1]; freeAgent(ptr); ptr = port1; goto loop; } @@ -7574,6 +7577,7 @@ int main(int argc, char *argv[]) } + linenoiseHistoryLoad(".inpla.history.txt"); // the main loop of parsing and execution while(1) { -- cgit v1.2.3