{"id":20250007,"url":"https://github.com/bafs/the-super-tiny-compiler-php","last_synced_at":"2026-05-10T01:27:00.782Z","repository":{"id":149400139,"uuid":"55184174","full_name":"BafS/the-super-tiny-compiler-php","owner":"BafS","description":":snowman: Possibly the smallest compiler ever (PHP version)","archived":false,"fork":false,"pushed_at":"2016-03-31T21:29:02.000Z","size":15,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-14T02:35:08.916Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"cc-by-4.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BafS.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,"publiccode":null,"codemeta":null}},"created_at":"2016-03-31T21:28:55.000Z","updated_at":"2016-03-31T21:29:03.000Z","dependencies_parsed_at":null,"dependency_job_id":"3a521e41-74e6-4a94-a90d-7dc6fa4e7c7a","html_url":"https://github.com/BafS/the-super-tiny-compiler-php","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BafS%2Fthe-super-tiny-compiler-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BafS%2Fthe-super-tiny-compiler-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BafS%2Fthe-super-tiny-compiler-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BafS%2Fthe-super-tiny-compiler-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BafS","download_url":"https://codeload.github.com/BafS/the-super-tiny-compiler-php/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241696136,"owners_count":20004748,"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":[],"created_at":"2024-11-14T09:56:34.260Z","updated_at":"2026-05-10T01:26:55.742Z","avatar_url":"https://github.com/BafS.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ca href=\"super-tiny-compiler.php\"\u003e\u003cimg width=\"731\" alt=\"THE SUPER TINY COMPILER\" src=\"https://cloud.githubusercontent.com/assets/952783/14171276/ed7bf716-f6e6-11e5-96df-80a031c2769d.png\"/\u003e\u003c/a\u003e\n\n***Welcome to The Super Tiny Compiler! (PHP version)***\n\n**Disclamer** This is a port from Javascript to PHP of this project:  [thejameskyle/the-super-tiny-compiler](https://github.com/thejameskyle/the-super-tiny-compiler).\n\nThis is an ultra-simplified example of all the major pieces of a modern compiler\nwritten in easy to read PHP.\n\nReading through the guided code will help you learn about how *most* compilers\nwork from end to end.\n\n### [Want to jump into the code? Click here](super-tiny-compiler.php)\n\nTo run the code:\n```php\n\u003c?php\nrequire 'super-tiny-compiler.php';\n\ntry {\n  echo compiler('(add (subtract 4 2) 2)') . \"\\n\";\n} catch (Exception $e) {\n  echo $e-\u003egetMessage() . \"\\n\";\n}\n```\n\n---\n\n[![cc-by-4.0](https://licensebuttons.net/l/by/4.0/80x15.png)](http://creativecommons.org/licenses/by/4.0/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbafs%2Fthe-super-tiny-compiler-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbafs%2Fthe-super-tiny-compiler-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbafs%2Fthe-super-tiny-compiler-php/lists"}