Write C in Bun
In the next version of Bun You can compile and run C in JavaScript cursed idea: what if we let you write C in Bun Show this thread import { cc } from "bun:ffi"; const { hello } = cc/* c */ ` #include <stdio.h> extern int hello() { printf("hello world\n"); return 0; } ` .link("c") .compiler({ hello: { returns: "int" } }); hello();
A screenshot of a post announcing that the next version of Bun will let developers compile and run C code directly in JavaScript. The joke is the deliberately cursed interoperation between JavaScript and C, shown through a hybrid code snippet that imports a C function and compiles embedded C code. It is shared as a reaction to overcomplicated programming ideas and unusual language interoperability. EN: A screenshot of a post announcing that the next version of Bun will let developers compile and run C code directly in JavaScript. The joke is the deliberately cursed interoperation between JavaScript and C, shown through a hybrid code snippet that imports a C function and compiles embedded C code. It is shared as a reaction to overcomplicated programming ideas and unusual language interoperability.
- @gentoomemes / 13330 2024-09-14
- Type
- image
- Size
- 637×800 · 63.3 KiB
- Mood
- саркастичный, абсурдный
- Language
- en
- Added