{"id":22116315,"url":"https://github.com/jmid/camljoos0","last_synced_at":"2025-03-24T05:41:27.203Z","repository":{"id":19536926,"uuid":"22784804","full_name":"jmid/camljoos0","owner":"jmid","description":"A simple compiler for a small subset of Java 1.3","archived":false,"fork":false,"pushed_at":"2014-08-14T08:39:34.000Z","size":164,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-01-29T11:27:25.858Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"OCaml","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/jmid.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}},"created_at":"2014-08-09T11:26:59.000Z","updated_at":"2019-07-21T04:01:20.000Z","dependencies_parsed_at":"2022-08-24T03:30:51.961Z","dependency_job_id":null,"html_url":"https://github.com/jmid/camljoos0","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/jmid%2Fcamljoos0","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jmid%2Fcamljoos0/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jmid%2Fcamljoos0/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jmid%2Fcamljoos0/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jmid","download_url":"https://codeload.github.com/jmid/camljoos0/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245217790,"owners_count":20579297,"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-12-01T12:26:43.588Z","updated_at":"2025-03-24T05:41:27.183Z","avatar_url":"https://github.com/jmid.png","language":"OCaml","funding_links":[],"categories":[],"sub_categories":[],"readme":"Joos0 compiler\n==============\n\nThis is a simple compiler for a small subset of the Java(tm)\nprogramming language. The supported language, Joos0, is the smallest\nof a hierarchy of Java 1.3 subsets. For more language details and an\noverview of the hierarchy, see\n[https://services.brics.dk/java/courseadmin/dOvs2012/pages/The+Joos+Languages].\n\nThe compiler emits Java bytecode in the Jasmin format. You'll need to\ninstall the Jasmin assembler to turn the emitted .j files into .class\nfiles. For more information on Jasmin, see http://jasmin.sourceforge.net/.\n\nTo build the compiler you'll also need to install the Menhir parser\ngenerator, see http://gallium.inria.fr/~fpottier/menhir/.\n\nThe compiler was developed as part of (a previous version of) the\nundergraduate compiler course at Aarhus University.\n\n\nTo build:\n---------\n\n    $ make\n\n\nTo run:\n-------\n\nExample 1:\n\n    $ ./joos0 tests/IntegerToString.java \n    [...]\n    $ jasmin tests/IntegerToString.j\n    $ java -classpath . IntegerToString\n    Enter a number: 42\n    In base 8 that is: 52\n\n(hence the program tests/IntegerToString.java compiles with the Joos0\ncompiler, the output can be assembled with Jasmin, and the resulting\noutput run on the JVM)\n\n\n\nExample 2:\n\n    $ ./joos0 tests/Cons.java tests/ConsMain.java\n    [...]\n    $ jasmin tests/Cons.j tests/ConsMain.j\n    $ java -classpath . ConsMain\n    truefalse\n\n(hence the compiler supports programs that span multiple files)\n\n\n\nExample 3:\n\n    $ ./joos0 tests/ClassName2.java \n    [...]\n    Error at tests/ClassName2.java: line 3, col 11\n        public A() throws Exception { }\n    \n    Constructor must have the same name as its enclosing class\n\n(hence the program is properly rejected by the compiler with an error message)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjmid%2Fcamljoos0","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjmid%2Fcamljoos0","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjmid%2Fcamljoos0/lists"}