{"id":27072773,"url":"https://github.com/evangipson/lsharpc","last_synced_at":"2025-04-05T23:33:45.379Z","repository":{"id":280338776,"uuid":"941663673","full_name":"evangipson/lsharpc","owner":"evangipson","description":"The compiler and runtime for L#.","archived":false,"fork":false,"pushed_at":"2025-03-10T17:11:14.000Z","size":93,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-10T18:27:39.365Z","etag":null,"topics":["abstract-syntax-tree","bytecode","c","code-generation","compiler","runtime","tokenization","virtual-machine"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/evangipson.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"publiccode":null,"codemeta":null}},"created_at":"2025-03-02T20:10:03.000Z","updated_at":"2025-03-10T17:11:19.000Z","dependencies_parsed_at":"2025-03-02T21:23:00.032Z","dependency_job_id":"e63a371a-4048-405e-a5d6-963481415f18","html_url":"https://github.com/evangipson/lsharpc","commit_stats":null,"previous_names":["evangipson/lsharpc"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evangipson%2Flsharpc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evangipson%2Flsharpc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evangipson%2Flsharpc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evangipson%2Flsharpc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/evangipson","download_url":"https://codeload.github.com/evangipson/lsharpc/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247415826,"owners_count":20935384,"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":["abstract-syntax-tree","bytecode","c","code-generation","compiler","runtime","tokenization","virtual-machine"],"created_at":"2025-04-05T23:33:44.788Z","updated_at":"2025-04-05T23:33:45.373Z","avatar_url":"https://github.com/evangipson.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# L#\nL# (\"L Sharp\") is a programming language initially written in C. It has a few goals in mind:\n\n- L# is intended to be easy-to-write, easy-to-read, immutable by default, general-purpose, extensible, platform-agnostic programming language\n- The language is intended to interoperate with other systems and languages\n- The language does not allow code that would violate any memory safety; memory should not be a concern of the programmer\n- The language does not enforce any specific architecture or structure (with spaces, folders, groupings of files, or brackets), rather, the programmer decides and implements how they see fit\n- L# applications are intended to be economical with regard to memory and processing, the language is intended to compete directly on performance and size with C or assembly language\n\nIf you're curious, you can read more about it in the [L# language spec](spec) included in this repo.\n\n## Syntax\n\nHere is a sample of some [simple L# source code](./examples/simple-print.ls):\n\n```lsharp\nnumber temperature = 98.5 + 1\n\n/* the info, debug, warning, and error functions are built-in to L# */\ninfo('temperature variable set!')\ndebug('temperature is 99.5.')\nwarning('temperature cannot be changed.')\nerror('done running.')\n```\n\nWhen compiling and running this file, the output will look like this:\n\n![A screenshot of console output of a simple L# program.](assets/simple-lsharp-output.png)\n\n## Getting Started\n1. Clone or fork the repo\n1. Navigate to project root\n1. Use the [makefile](makefile) to compile or clean the project\n    - `make` compiles both the compiler and the runtime\n    - `make compiler` compiles the compiler\n    - `make runtime` compiles the runtime\n    - `make tests` compiles the unit tests for the program\n    - `make clean` removes all build artifacts, docs, and the compiled program\n    - `make docs` generates and launches the documentation\n    - `make rebuild` runs `make clean` then `make`\n1. Run `bin/lsc examples/simple.ls` to compile the simple L# source code into a bytecode program file\n1. Run `bin/lsr program.lbc` to run the bytecode file\n\n## Architecture\nThe compiler will read the L# file, tokenize the source code, then break the tokens into an abstract syntax tree.\n\nThe abstract syntax tree is then translated to bytecode instructions through code generation, which will create an .lbc (L# bytecode) file.\n\nThe .lbc file is then run by the LVM (L# virtual machine) which produces the output of the program.\n\n## Todo\n- Finish L# language spec\n- Finish L# VSCode extension\n- Create a release of the L# compiler in this repository\n- Create an L# compiler in L#","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevangipson%2Flsharpc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fevangipson%2Flsharpc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevangipson%2Flsharpc/lists"}