mirror of
https://github.com/janet-lang/janet
synced 2025-11-19 08:45:11 +00:00
Get dst to compile on windows
This commit is contained in:
@@ -103,6 +103,11 @@
|
||||
*
|
||||
*/
|
||||
|
||||
/* On Windows, have a minimal implementation */
|
||||
#ifdef WIN32
|
||||
|
||||
#else
|
||||
|
||||
#include <termios.h>
|
||||
#include <unistd.h>
|
||||
#include <stdlib.h>
|
||||
@@ -1197,3 +1202,5 @@ int linenoiseHistoryLoad(const char *filename) {
|
||||
fclose(fp);
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -169,8 +169,10 @@ int main(int argc, char **argv) {
|
||||
if (!fileRead || (flags & DST_CLIENT_REPL)) {
|
||||
DstContext ctxt;
|
||||
dst_context_repl(&ctxt, env);
|
||||
#ifndef DST_WINDOWS
|
||||
ctxt.read_chunk = linenoiseread;
|
||||
linenoiseSetMultiLine(1);
|
||||
#endif
|
||||
puts(replsplash);
|
||||
status = dst_context_run(&ctxt, DST_PARSEFLAG_SOURCEMAP);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user