SShortSingh.
Back to feed

Developer builds Polish-keyword programming language, gains deep Ruby insights

0
·55 views

A Ruby developer spent 18 months building AlexScript, a fully featured interpreted scripting language whose keywords are written in Polish, his first language. The project grew from a weekend experiment into a language with a standard library, async/await support, a debugger, and a self-hosted web framework. Building the interpreter revealed several Ruby performance nuances, including that Ruby's throw/catch is far more efficient than raise/rescue for non-local exits like function returns. The developer also discovered that scanning UTF-8 strings character by character causes accidentally quadratic performance, fixable by using getbyte and byteslice for O(1) byte access. A unified method dispatch table — rather than separate registries for native and user-defined methods — further simplified the interpreter's architecture and improved lookup efficiency.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingHacker News ·

Researchers Formalize the US Tax Code Using the Lean Proof Assistant

A blog post from Lexifina describes an effort to formalize parts of the US tax code using Lean, a programming language and proof assistant. The approach aims to express tax rules in a precise, machine-checkable form. The source material is a brief Hacker News entry linking to the original post, which received 6 points and no comments at the time of retrieval. The available text does not provide detailed findings, scope, or results of the project. Further specifics would need to be checked against the full Lexifina article.

0
ProgrammingHacker News ·

PyPI Launches Redesigned Project Pages With Clearer Security Signals

The Python Package Index (PyPI) has released updated project pages featuring more visible security indicators. The redesign is now live for all users visiting package listings. The changes aim to help developers more easily assess the security status of packages before installing them. The announcement was published on PyPI's official blog and drew attention on Hacker News, where it received 31 points and two comments.

0
ProgrammingDEV Community ·

Assembly Language for Beginners: Learning How Programs Talk to the CPU

Assembly is the lowest-level programming language people still write by hand, a readable layer over the machine code a CPU executes. The article argues that learning it reveals how computers work, covering registers, memory, and the stack, and explains why some high-level code runs faster or slower than expected. It presents a tiny x86-64 program that exits with code 42 to show how simple the instructions are. The author suggests starting with NASM on Linux or an online assembler, then building up to programs that print text and add numbers. While useful for students, embedded developers, and security researchers, the piece notes Assembly is slow to write and tied to one architecture, so it is not suited for everyday app development.

0
ProgrammingDEV Community ·

AquaSort: A Browser Puzzle Game of Pouring and Sorting Colored Liquids

AquaSort is a small, self-contained browser game in which players pour colored liquids between tubes until each color occupies a single vessel. The rules are simple enough to learn in about ten seconds, and levels have no end, with difficulty rising through more colors, locked tubes, and star ratings for efficient moves. The game also offers a daily challenge, achievements, a skin collection, and cloud saving of progress. It was built as a single canvas codebase without an engine and is distributed through the Playgama Bridge SDK to roughly a dozen portals. The game is free, requires no signup, works on mobile, and supports 14 languages.