NAME
/home/quirinpa/site/external/libbud/src/cx-lsp.c - Pure-C Language Server Protocol (LSP) proxy for .cx files over clangd.
SYNOPSIS
#include 'cx_lsp_internal.h'
#include <ttypt/iso_json.h>
#include <ctype.h>
#include <errno.h>
#include <poll.h>
#include <signal.h>
#include <stdarg.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <unistd.h>
Detailed Description
Pure-C Language Server Protocol (LSP) proxy for .cx files over clangd.
Architecture:
- Calls cx_transpile() in-process (<1 ms) with `emit_lines = 0, recover = 1` so `clangd` operates on a deterministic shadow `.cx.c` document whose exact byte coordinates map 1-to-1 with `.cx` via `cx_span`.
- Serves HTML/native tag and `component` prop completions directly when the cursor is inside a JSX tag/attribute name outside `{...}`.
- Forwards all C semantics (`hover`, `completion` inside `{}`/closures, `definition`, `references`, `signatureHelp`, `publishDiagnostics`) to unmodified `clangd`, remapping URIs and ranges `.cx <-> .c.
- Zero external runtime dependencies beyond libc, POSIX poll/fork/pipe, and cx_transpile.o`.
Author
Generated automatically by Doxygen for bud from the source code.