{"id":24016655,"url":"https://github.com/burning-eggs/whim","last_synced_at":"2026-06-11T18:31:33.290Z","repository":{"id":230152681,"uuid":"405918111","full_name":"burning-eggs/whim","owner":"burning-eggs","description":"Stack-based programming language inspired by Forth.","archived":false,"fork":false,"pushed_at":"2021-09-14T09:02:40.000Z","size":33,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-08T08:52:06.049Z","etag":null,"topics":["no-dependencies","programming-language","python","whim"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/burning-eggs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-09-13T09:54:05.000Z","updated_at":"2021-09-14T09:02:43.000Z","dependencies_parsed_at":"2024-03-28T05:39:23.302Z","dependency_job_id":"5c3daf6d-28d1-4d39-bcfd-7baedb1cbb2b","html_url":"https://github.com/burning-eggs/whim","commit_stats":null,"previous_names":["burning-eggs/whim"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/burning-eggs%2Fwhim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/burning-eggs%2Fwhim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/burning-eggs%2Fwhim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/burning-eggs%2Fwhim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/burning-eggs","download_url":"https://codeload.github.com/burning-eggs/whim/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240738118,"owners_count":19849549,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["no-dependencies","programming-language","python","whim"],"created_at":"2025-01-08T08:52:11.857Z","updated_at":"2026-06-11T18:31:33.278Z","avatar_url":"https://github.com/burning-eggs.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# whim\n\n Stack based programming language inspired by Forth.\n \n **QUICK DISCLAIMER: COMPILING .whm FILES CURRENTLY DOESNT WORK ON WINDOWS.** \n\n Whim is planned to be\n - [x] Compiled\n - [x] Native\n - [x] Stack-Based\n - [ ] Turing-Complete\n - [ ] Statically Typed\n - [ ] Self-Hosted\n\n## Example\n\n Simple program that prints numbers from 10 to 1 in descending order:\n\n ```whim\n 10 while dup 0 \u003e do\n     dup .\n    1 -\n end\n ```\n\n## Quick Start\n\n### Simulation\n\n Simulating a `.whm` simply interprets the program.\n\n ```console\n $ cat program.whm\n 50 50 + .\n $ ./whim.py sim program.whm\n 100\n ```\n\n### Compiling\n\n Compiling a `.whm` file generates assembly code and compiles it with [nasm](https://www.nasm.us), and then links it with [GNU ld](https://www.gnu.org/software/binutils/). Make sure you have both available in your `$PATH`.\n\n ```console\n $ cat program.whm\n 30 30 + .\n $ ./whim.py com program.whm\n [COMPILE] Generating 'program.asm'\n [CMD] nasm -felf64 program.asm\n [CMD] ld -o program.asm program.o\n [CMD] rm -rf program.o\n $ ./program.asm\n 60\n ```\n\n## Language Reference\n\n This is what the language supports so far. **Since the language is a work in progress, the exact set of operations is subject to change.**\n\n### Stack Manipulation\n\n - `\u003cinteger\u003e` - push an integer onto the stack. Right now the integer is anything that can be parsed by the [int](https://docs.python.org/3/library/functions.html#int) function.\n\n - `dup` - duplicate an element on top of the stack.\n\n - `.` - print the element on top of the stack and remove it from the stack.\n\n### Comparison\n\n - `=` - checks if two elements on top of the stack are equal. Removes the element from the stack and pushes `1` if they are equal, `0` if not.\n\n - `\u003e` - checks if the element below the top element is greater than the top element.\n## Badges\n\n [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fburning-eggs%2Fwhim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fburning-eggs%2Fwhim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fburning-eggs%2Fwhim/lists"}