From 405da5f84b072ea97b69359454899f45d92d24b6 Mon Sep 17 00:00:00 2001 From: Albert Cervin Date: Wed, 22 May 2024 00:00:29 +0200 Subject: WIP LSP client This contains the start of an LSP client. Nothing (except starting the LSP server) works at the moment and the feature is disabled by default. --- src/dged/process.h | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 src/dged/process.h (limited to 'src/dged/process.h') diff --git a/src/dged/process.h b/src/dged/process.h new file mode 100644 index 0000000..cefec8c --- /dev/null +++ b/src/dged/process.h @@ -0,0 +1,35 @@ +#ifndef _PROCESS_H +#define _PROCESS_H + +#include +#include + +#ifdef _WIN32 +typedef HANDLE fd_t; +#else +typedef int fd_t; +#endif + +struct platform_process; +struct process { + uint64_t id; + fd_t stdin; + fd_t stdout; + fd_t stderr; + struct platform_process *impl; +}; + +struct process_create_result { + bool ok; + const char *error_message; +}; + +struct process_create_result process_create(char *const command[], + struct process *result); + +void process_destroy(struct process *p); + +bool process_running(const struct process *p); +bool process_kill(const struct process *p); + +#endif -- cgit v1.2.3