{"id":15907768,"url":"https://github.com/fatescript/compiler","last_synced_at":"2026-01-11T13:04:11.726Z","repository":{"id":161419323,"uuid":"56640919","full_name":"FateScript/compiler","owner":"FateScript","description":null,"archived":false,"fork":false,"pushed_at":"2016-05-12T04:30:22.000Z","size":1202,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-02T23:42:10.326Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Yacc","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/FateScript.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-04-20T00:01:35.000Z","updated_at":"2024-08-15T07:28:09.000Z","dependencies_parsed_at":"2023-05-24T06:30:43.547Z","dependency_job_id":null,"html_url":"https://github.com/FateScript/compiler","commit_stats":{"total_commits":6,"total_committers":1,"mean_commits":6.0,"dds":0.0,"last_synced_commit":"0e5100018e4839baad6b2743a0b92f2ff64a034a"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/FateScript/compiler","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FateScript%2Fcompiler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FateScript%2Fcompiler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FateScript%2Fcompiler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FateScript%2Fcompiler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FateScript","download_url":"https://codeload.github.com/FateScript/compiler/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FateScript%2Fcompiler/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28304264,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-11T11:18:18.743Z","status":"ssl_error","status_checked_at":"2026-01-11T11:07:56.842Z","response_time":60,"last_error":"SSL_read: 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":[],"created_at":"2024-10-06T14:03:19.203Z","updated_at":"2026-01-11T13:04:11.711Z","avatar_url":"https://github.com/FateScript.png","language":"Yacc","funding_links":[],"categories":[],"sub_categories":[],"readme":"# compiler\n\n###  词法分析器  \n\n词法分析器使用lex生成，采用的环境是ubuntu 14.04，需要预装flex，如果没有flex，可以通过sudo apt-get install flex获得\n\n如果要一步步生成所需文件，则需按照如下步骤：\n\n * 在终端运行  flex  lexcial_analyser.l，会生成lex.yy.c 文件  \n * 在终端运行  gcc  lex.yy.c  -o  analyser  -ll，会生成analyser二进制程序(在windows下用gcc lex.yy.c -o analyser即可，无需加ll选项)  \n * 运行  ./analyser  demon  (demon为所需要进行词法分析的c源文件)，结果会生成在token.txt  ,并且如果词法分析过程出现错误，则终端会显示No，并且指出哪一行程序的哪一个部分会有错误。如果没有问题，则在屏幕上输出yes  \n\n### 语法分析器  \n\n语法分析器位于syntax文件夹中，用lex与yacc进行生成，如果需要一步步生成所需文件，按如下步骤进行：  \n\n * 在终端运行 flex lexcial.l，生成lex.yy.c文件  \n * 终端运行yacc -d syntax.y，生成y.tab.h与y.tab.c文件  \n * 运行gcc y.tab.h y.tab.c lex.yy.c -o analyser生成analyser二进制文件  \n * 运行./analyser demon （demon为所需要进行词法分析的文件），如果不存在语法错误，则会输出Parse complete.否则输出Parse failed并且会报出第一个出现语法错误的地方  \n * 注意：语法分析与词法分析过程不包含预处理过程  \n\n#### 声明  \n词法分析与语法分析采用C99标准写成，具体内容可以查看C99.pdf  \n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffatescript%2Fcompiler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffatescript%2Fcompiler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffatescript%2Fcompiler/lists"}