{"id":18805657,"url":"https://github.com/phorward/xpl","last_synced_at":"2025-06-23T11:37:10.017Z","repository":{"id":82166104,"uuid":"92503796","full_name":"phorward/xpl","owner":"phorward","description":"An eXample Programming Language","archived":false,"fork":false,"pushed_at":"2018-12-20T14:19:17.000Z","size":18,"stargazers_count":11,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-21T00:52:37.063Z","etag":null,"topics":["c-like","compiler","embeddable","language","programming-language","scripting-language","toy-language"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/phorward.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":"2017-05-26T11:20:59.000Z","updated_at":"2025-06-01T04:03:00.000Z","dependencies_parsed_at":null,"dependency_job_id":"afe9624d-c100-49b7-9db7-a95485de93ba","html_url":"https://github.com/phorward/xpl","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/phorward/xpl","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phorward%2Fxpl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phorward%2Fxpl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phorward%2Fxpl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phorward%2Fxpl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/phorward","download_url":"https://codeload.github.com/phorward/xpl/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phorward%2Fxpl/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261470053,"owners_count":23163211,"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":["c-like","compiler","embeddable","language","programming-language","scripting-language","toy-language"],"created_at":"2024-11-07T22:44:38.210Z","updated_at":"2025-06-23T11:37:04.992Z","avatar_url":"https://github.com/phorward.png","language":"C","readme":"# xpl\n\n**xpl**: *eXample Programming Language*.\n\n## About\n\n**xpl** is a tiny toy programming language that is implemented in the course of the [UniCC Parser Generator](https://github.com/phorward/unicc)'s User Manual.\nPlease check out the [User's Manual](http://phorward.info/download/unicc/unicc.pdf) for implementation details.\n\n## Features\n\n- C-like language [syntax](https://github.com/phorward/xpl/blob/master/xpl.par)\n- Arithmetic and conditional expressions\n- Dynamically typed\n- 3 data-types: integer, float, string\n- Simple control structures (conditionals, iterations)\n- 6 build-in functions for simple data manipulation routines and input/output facilities: exit(), print(), prompt(), integer(), float(), string() \n\n## Building\n\nTo build `xpl`, you need UniCC and any C-compiler. The provided Makefile should do all the rest for you, when `unicc` is in the PATH.\n\n## Example\n\nThe \"99 bottles of beer\" program implemented in xpl.\n\n```c\nif( ( bottles = prompt( \"Enter number of bottles [default=99]\" ) ) == \"\" )\n    bottles = 99;\n\nif( integer( bottles ) \u003c= 0 )\n{\n    print( \"Sorry, but the input '\" + bottles + \"' is invalid.\" );\n    exit( 1 );\n}\n\nwhile( bottles \u003e 0 )\n{\n    if( bottles \u003e 1 )\n        print( bottles + \" bottles of beer on the wall, \" +\n                bottles + \" bottles of beer.\" );\n    else\n        print( \"One bottle of beer on the wall, one bottle of beer.\" );\n\n    print( \"Take one down, pass it around.\" );\n\n    if( ( bottles = bottles - 1 ) == 0 )\n        print( \"No more bottles of beer on the wall.\" );\n    else if( bottles == 1 )\n        print( \"One more bottle of beer on the wall.\" );\n    else\n        print( bottles + \" more bottles of beer on the wall.\" );\n}\n```\n\nRun it after building with\n\n```bash\n./xpl 99bottles.xpl\n```\n\n## Credits\n\n*xpl* is developed and maintained by [Jan Max Meyer](https://github.com/phorward/), Phorward Software Technologies.\n\n## License\n\nxpl is under the WTFPL.\n","funding_links":[],"categories":["Uncategorized"],"sub_categories":["Uncategorized"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphorward%2Fxpl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphorward%2Fxpl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphorward%2Fxpl/lists"}