6 ms·
So it's possible to port C compiler to PDF. Compiler is already done https://github.com/Mati365/ts-c-compiler https://github.com/Mati365/ts-c-compiler. We can r
by mati365 2y ago
So it's possible to port C compiler to PDF. Compiler is already done https://github.com/Mati365/ts-c-compiler https://github.com/Mati365/ts-c-compiler. We can run DOS in PDF basically..
- ohnoAmsorry 2y ago[flagged]
- drdeca 2y agoHuh? Did you comment this in reply to something other than what you intended to reply to?
- mati365 2y agoThese 'tricks' are exactly what makes programming the passion I love. Thanks for capturing the difference between coding for joy and coding for a paycheck so succinctly. Also, it's not a wrapper—it's a full parser and compiler.
- bowmessage 2y agoAdobe Acrobat DOOM Pro™
- mati365 2y agoWhat about running Adobe Acrobat in Adobe Acrobat?
- lxgr 2y agoThat's how it inevitably goes with Turing completeness :) The real achievement here arguably isn't running code (that's provided by the PDF spec and implementations), but managing to hook it up to user input/output in an ergonomic-enough way to play Tetris.
- segasaturn 2y agoThe mention of Turing Completeness got me curious, so I looked something up. Behold, a C compiler written in Lambda Calculus: https://github.com/woodrush/lambda-8cc https://github.com/woodrush/lambda-8cc
- lxgr 2y agoAmazing, thank you! The PDF [1] containing the Lambda calculus term manages to hang/glitch/crash both Firefox's and macOS Preview's PDF renderer, which in itself is quite the achievement in portability. Update: Nevermind, Firefox handles it perfectly, it just (probably wisely) disables seamless scrolling and I have to use the "next/previous" page buttons manually. macOS got there after a minute or two of loading with no UI indications. [1] https://woodrush.github.io/lambda-8cc.pdf https://woodrush.github.io/lambda-8cc.pdf
- openrisk 2y agoBut will it also compile when printed out on paper?
- deleted 2y ago[deleted]