{"id":23127718,"url":"https://github.com/daniele-rapagnani/melon","last_synced_at":"2025-08-17T05:31:12.960Z","repository":{"id":40282027,"uuid":"285039882","full_name":"daniele-rapagnani/melon","owner":"daniele-rapagnani","description":"The Melon programming language","archived":false,"fork":false,"pushed_at":"2022-11-10T13:14:11.000Z","size":1922,"stargazers_count":34,"open_issues_count":22,"forks_count":2,"subscribers_count":2,"default_branch":"develop","last_synced_at":"2023-04-19T06:51:40.318Z","etag":null,"topics":["bytecode","embeddable-scripting-language","game-development","hacktoberfest","interpreter","language","lua","melon","programming-language","scripting-language","wren"],"latest_commit_sha":null,"homepage":"https://daniele-rapagnani.github.io/melon/","language":"C++","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/daniele-rapagnani.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-08-04T16:39:30.000Z","updated_at":"2023-03-04T11:30:57.000Z","dependencies_parsed_at":"2023-01-22T11:16:25.072Z","dependency_job_id":null,"html_url":"https://github.com/daniele-rapagnani/melon","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daniele-rapagnani%2Fmelon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daniele-rapagnani%2Fmelon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daniele-rapagnani%2Fmelon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daniele-rapagnani%2Fmelon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/daniele-rapagnani","download_url":"https://codeload.github.com/daniele-rapagnani/melon/tar.gz/refs/heads/develop","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230091585,"owners_count":18171528,"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":["bytecode","embeddable-scripting-language","game-development","hacktoberfest","interpreter","language","lua","melon","programming-language","scripting-language","wren"],"created_at":"2024-12-17T09:14:35.263Z","updated_at":"2024-12-17T09:14:35.832Z","avatar_url":"https://github.com/daniele-rapagnani.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Melon is a small and modern programming language\n#### CI Status\n\n[![Actions Status](https://github.com/daniele-rapagnani/melon/workflows/macOS/badge.svg)](https://github.com/daniele-rapagnani/melon/actions)\n[![Actions Status](https://github.com/daniele-rapagnani/melon/workflows/Linux/badge.svg)](https://github.com/daniele-rapagnani/melon/actions)\n[![Actions Status](https://github.com/daniele-rapagnani/melon/workflows/Windows/badge.svg)](https://github.com/daniele-rapagnani/melon/actions)\n[![Actions Status](https://github.com/daniele-rapagnani/melon/workflows/Emscripten/badge.svg)](https://github.com/daniele-rapagnani/melon/actions)\n\n#### What's Melon?\n\nMelon attempts to combine the best features of popular high-level languages in something that feels modern but is still small and light enough to be easy to embed in your project.\nIt's inspired mainly by ES6 JavaScript, Lua, Wren, Python and Ruby.\n\nIt looks like this:\n```javascript\nlet Language = {\n    create = |name|  =\u003e {\n        return { name = name } @ Language;\n    },\n    \n    getName = -\u003e {\n        return this.name;\n    }\n};\n\nlet Melon = {\n    create = =\u003e {\n        return { } @ Melon;\n    },\n    \n    helloWorld = -\u003e {\n        io.print(\"Hello world \" .. this-\u003egetName() .. \"!\");\n    }\n} @ Language.create(\"Melon\");\n\nlet melon = Melon.create();\nmelon-\u003ehelloWorld();\n```\n\n# Features\n\n* A simple but functional **module system**\n* Good for **soft realtime** applications such as games: it sports an **incremental generational GC**\n* Native **integer** and **array** types allow for faster code\n* Support for **bytecode** generation, you don't need to distribute your source files\n* Full support for **operator overloading** using **ES6-style symbols**\n* **Prototype based**: doesn't enforce the OOP paradigm while still making it possible\n* **Dynamic typing** without implicit conversions: lower chance of unintended behaviour\n* Entirely written in **C**, the number of dependencies can be counted on one hand\n* Extensive **unit tests** for both the VM and language\n\n# Where to start\nMelon is very young and there's still no documentation available. \nAt the moment you can get a taste for the language by browsing the [unit tests][ut].\n\n# Platforms\n\nMelon supports the following platforms:\n\n* macOS\n* Linux (32/64bit)\n* Windows (MinGW-w64, 32/64bit)\n* Emscripten\n\n# Compiling\nMelon uses CMake so you can use the standard way of building CMake projects:\n\n```sh\nmkdir build \u0026\u0026 cd build\ncmake ..\nmake\n```\n\n## Emscripten\n\nJust run CMake with `emcmake` and you are good to go:\n\n```sh\nmkdir build \u0026\u0026 cd build\nemcmake cmake ..\nmake\n```\n\n## MinGW\n\nIn order to link Melon and its binaries with MinGW-w64 you'll need the **lld** linker.\nYou can install it on MSYS2 with: `pacman -S mingw-w64-x86_64-lld` or `pacman -S mingw-w64-i686-lld` depending on your architecture.\n\n# Disclaimer\nMelon is still in **alpha** and it's certainly not ready for production!\nIn the unlikely event that you are considering it for your project, please keep in mind that development is very active and nothing is written in stone at the moment.\n\n[ut]: https://github.com/daniele-rapagnani/melon/tree/develop/tests/fixtures/vm/language","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdaniele-rapagnani%2Fmelon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdaniele-rapagnani%2Fmelon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdaniele-rapagnani%2Fmelon/lists"}