shithub: rgbds

Download patch

ref: 21e50eeff1bac67817406cc9df8e5dce5712eb6e
parent: fd4cec93cd5d50bb478655f488a0a8420f96fdd0
author: ISSOtm <eldredhabert0@gmail.com>
date: Mon Oct 5 22:54:08 EDT 2020

Have lexer not require <unistd.h> on MSVC

Required for `open`, `close`, `read`, and `STDIN_FILENO`,
which are defined elsewhere on MSVC.

--- a/src/asm/lexer.c
+++ b/src/asm/lexer.c
@@ -19,7 +19,9 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
+#ifndef _MSC_VER
 #include <unistd.h>
+#endif
 
 #include "extern/utf8decoder.h"
 #include "platform.h" /* For `ssize_t` */