{"id":19186810,"url":"https://github.com/donydchen/dragon-front","last_synced_at":"2026-02-14T21:31:55.676Z","repository":{"id":95783558,"uuid":"50679289","full_name":"donydchen/Dragon-Front","owner":"donydchen","description":"The comment for A Complete Front End of the dragon book.","archived":false,"fork":false,"pushed_at":"2017-03-02T08:52:51.000Z","size":1925,"stargazers_count":3,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-10T01:14:04.483Z","etag":null,"topics":["compiler","dragon-book","java"],"latest_commit_sha":null,"homepage":"","language":"Java","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/donydchen.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":"2016-01-29T17:39:17.000Z","updated_at":"2023-04-20T13:04:52.000Z","dependencies_parsed_at":"2023-03-26T13:34:23.793Z","dependency_job_id":null,"html_url":"https://github.com/donydchen/Dragon-Front","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/donydchen/Dragon-Front","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/donydchen%2FDragon-Front","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/donydchen%2FDragon-Front/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/donydchen%2FDragon-Front/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/donydchen%2FDragon-Front/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/donydchen","download_url":"https://codeload.github.com/donydchen/Dragon-Front/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/donydchen%2FDragon-Front/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29456235,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-14T21:29:27.764Z","status":"ssl_error","status_checked_at":"2026-02-14T21:28:11.111Z","response_time":53,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["compiler","dragon-book","java"],"created_at":"2024-11-09T11:16:48.897Z","updated_at":"2026-02-14T21:31:55.671Z","avatar_url":"https://github.com/donydchen.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Dragon-Front\n\nTHE COMMENT FOR *A COMPLETE FRONT END* OF THE DRAGON BOOK      \n2015 SYSU COMPILER PROJECT 4     \n\n\n##文件结构简介\n\n* **bin:** 由eclipse自动生成的可执行文件\n* **doc:** javadoc生成的注解文档，使用命令：`javadoc inter/*.java lexer/*.java main/*.java parser/*.java symbols/*.java -d ../doc -encoding UTF-8 -charset UTF-8`\n* **ref:** 其中*CompilerAppendixA.pdf*是龙书附录A，而*documents.pdf*则是编译器源码的分析与注解\n* **src:** 完整编译器前端的源码，含注释\n* **uml:** 编译器前端类的类图，包含jpg档和uxf档，其中uxf档请使用[UMLet](http://www.umlet.com/)打开\n\n\n##编译器识别语言的文法\n\n```\nprogram -\u003e block\nblock -\u003e { decls stmts }\ndecls -\u003e decl decls | epsilon\ndecl -\u003e type id\ntype -\u003e basic dims\ndims -\u003e [ num ] dims | epsilon\nstmts -\u003e stmt stmts | epsilon\n\nstmt -\u003e ;\n      | if ( bool ) stmt \n      | if ( bool ) stmt else stmt\n      | while ( bool ) stmt\n      | do stmt while ( bool ) ;\n      | break ;\n      | block\n      | assign\nassign -\u003e id offset = bool ;\noffset -\u003e [ bool ] offset | epsilon\n\nbool -\u003e join | join || bool\njoin -\u003e equality | equality \u0026\u0026 join\nequality -\u003e rel | rel == equality | rel != equality\nrel -\u003e expr \n     | expr \u003c expr | expr \u003c= expr \n     | expr \u003e= expr | expr \u003e expr\nexpr -\u003e term | term + expr | term - expr\nterm -\u003e unary | unary * term | unary / term\nunary -\u003e - unary | ! unary | factor\nfactor -\u003e ( bool ) | num | real | true | false | id offset\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdonydchen%2Fdragon-front","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdonydchen%2Fdragon-front","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdonydchen%2Fdragon-front/lists"}