diff --git a/content/posts/newsletter-012/index.md b/content/posts/newsletter-012/index.md index b7674922c..2f47b6c52 100644 --- a/content/posts/newsletter-012/index.md +++ b/content/posts/newsletter-012/index.md @@ -243,6 +243,38 @@ tokio), all but a few worked out-of-the-box! [vulkan-renderer-prototype-video]: https://www.youtube.com/watch?v=Ks_HQbejHE4 [moltenvk]: https://github.com/KhronosGroup/MoltenVK +### [Langcraft] + +[Langcraft] is the Minecraft LLVM target you've never wanted. + +Langcraft started as a dare to the `#lang-dev` channel of the Rust +Community Discord to be able to parse Rust code in Minecraft. +Naturally, it grew into a full code generator that can translate +most LLVM IR to +[Minecraft data packs](https://minecraft.gamepedia.com/Data_Pack), +the game's deliberately-limited in-game scripting language. Langcraft +is entirely language independent, so any language with an LLVM-based +compiler can (with the right API bindings) run in Minecraft. Currently +bindings to both C and Rust exist. While not as visually impressive as +a redstone computer, Langcraft does stretch the bounds of the game quite +a bit, using jukeboxes for memory, armor stands to represent pointers, +and rearranging compiled code to make it run in the bounds of the data +packs' fixed instruction limit. + +This is all, naturally, entirely useless. The project is also still +heavily work-in-progress and does not pretend to be stable, but it is +usable. A handwritten interpreter for a Rust-like language has already +been demonstrated running, and even more complex projects like [CHIP-8 +emulators](https://github.com/Dhole/chip8-rs.git) function (albeit at +extremely slow speed). + +You can watch a [video of Rust interpreter running Fizzbuzz][langcraft-video]: + +[![youtube preview](longcraft-video.jpeg)][langcraft-video] + +[Langcraft]: https://github.com/SuperTails/langcraft +[langcraft-video]: https://youtube.com/watch?v=Cx0w5Wn9pPU + ## Popular Workgroup Issues in Github diff --git a/content/posts/newsletter-012/longcraft-video.jpeg b/content/posts/newsletter-012/longcraft-video.jpeg new file mode 100644 index 000000000..8d74fc603 Binary files /dev/null and b/content/posts/newsletter-012/longcraft-video.jpeg differ