{"id":21806858,"url":"https://github.com/roguh/coolnoise","last_synced_at":"2025-03-21T08:13:08.483Z","repository":{"id":89927807,"uuid":"68482723","full_name":"roguh/coolnoise","owner":"roguh","description":"Parser and generator for programs written in the Classroom Object-Oriented Language. Eases testing of lexer and parser.","archived":false,"fork":false,"pushed_at":"2016-10-03T15:50:31.000Z","size":43,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-26T04:42:08.533Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Cool","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/roguh.png","metadata":{"files":{"readme":"README.markdown","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-09-17T23:06:35.000Z","updated_at":"2019-09-11T20:09:36.000Z","dependencies_parsed_at":"2023-06-12T15:15:45.915Z","dependency_job_id":null,"html_url":"https://github.com/roguh/coolnoise","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/roguh%2Fcoolnoise","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/roguh%2Fcoolnoise/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/roguh%2Fcoolnoise/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/roguh%2Fcoolnoise/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/roguh","download_url":"https://codeload.github.com/roguh/coolnoise/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244759961,"owners_count":20505716,"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-27T12:30:59.520Z","updated_at":"2025-03-21T08:13:08.462Z","avatar_url":"https://github.com/roguh.png","language":"Cool","funding_links":[],"categories":[],"sub_categories":[],"readme":"# COOLNOISE\nThis Haskell code implements a parser and a generator for programs written in the \n[COOL language](http://theory.stanford.edu/~aiken/software/cool/cool.html).\n\n| File           | Purpose                                                 |\n|----------------|---------------------------------------------------------|\n| `countCool.hs` | Counts the number of COOL expressions of a given depth. |\n\n## Installation and Compilation\nThis project uses [stack](http://docs.haskellstack.org/en/stable/README/) and\nthe Haskell LTS 7.0 distribution. [Read these download and installation\ninstructions for stack.](https://docs.haskellstack.org/en/stable/install_and_upgrade/)\n\nIf you have not installed GHC 8.0.1 yet, run \n\n```\nstack setup\n```\n\nThis command will download all dependencies and compile the project:\n\n```\nstack build\n```\n\n## Examples\n### Lexer\n\nAfter compiling the program, run the following command to see the help file:\n\n```\nstack exec coolnoise-exe -- --help\n```\n\nUse the `--file` option to lex a file:\n\n```\nstack exec coolnoise-exe -- --file cool_examples/hello_world.cl\n```\n\nYou can also run the lexer on a string with the `--input` option:\n\n```\nstack exec coolnoise-exe -- --input '(* sample *) main() : SELF_TYPE { out_string(\"HI\") };' \n```\n\n### Parser\n\n### Generator\n\n## Tests\n\nNone yet.\n\n## Benchmarks\n\nTo benchmark the lexer, run\n\n```\nstack build \nstack exec bench-cli -- --output benchmark.html \n```\n\nOpen `benchmark.html` in a browser to see the results.\n\n## Number of Expressions\n\nThere are at least 224,974,626 possible COOL untyped expression\nthat have depth of 4, and contain at most 7 subexpressions\n(for example, a let-expression that binds 6 variables contains 7 subexpressions).\nThis table summarizes results with the same number of subexpressions:\n\n| Depth | Number of COOL Expressions (not type checked) |\n|-------|----------------------------|\n| 0     | 6\n| 1     | \u003e= 747\n| 2     | \u003e= 36,978\n| 3     | \u003e= 2,884,290\n| 4     | \u003e= 224,974,626\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Froguh%2Fcoolnoise","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Froguh%2Fcoolnoise","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Froguh%2Fcoolnoise/lists"}