{"id":16724543,"url":"https://github.com/yunwei37/tryc","last_synced_at":"2026-03-02T08:31:16.362Z","repository":{"id":42517677,"uuid":"260636088","full_name":"yunwei37/tryC","owner":"yunwei37","description":"Write a tiny interpreter by C language in 500+ lines ","archived":false,"fork":false,"pushed_at":"2022-03-23T14:22:42.000Z","size":377,"stargazers_count":136,"open_issues_count":0,"forks_count":15,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-07-18T02:17:56.057Z","etag":null,"topics":["c","compile","compiler","compiler-design","interpreter"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/yunwei37.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}},"created_at":"2020-05-02T07:27:23.000Z","updated_at":"2025-05-19T10:58:37.000Z","dependencies_parsed_at":"2022-08-29T13:42:10.213Z","dependency_job_id":null,"html_url":"https://github.com/yunwei37/tryC","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/yunwei37/tryC","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yunwei37%2FtryC","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yunwei37%2FtryC/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yunwei37%2FtryC/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yunwei37%2FtryC/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/yunwei37","download_url":"https://codeload.github.com/yunwei37/tryC/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yunwei37%2FtryC/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29995912,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-02T01:47:34.672Z","status":"online","status_checked_at":"2026-03-02T02:00:07.342Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["c","compile","compiler","compiler-design","interpreter"],"created_at":"2024-10-12T22:45:40.718Z","updated_at":"2026-03-02T08:31:16.335Z","avatar_url":"https://github.com/yunwei37.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tryC - a small interpreter written by C\n\ntryC is a very simple interpreter made by hand in C language, about 570 lines:\n\nUse `recursive descent method` for grammatical analysis, do not explicitly build a grammar tree, generate intermediate code or target code; interpret and execute at the same time as grammatical analysis.\n\nThe try language implemented by tryC: \n\n- `Dynamic types`, supported data types: `double-precision floating-point numbers`, `character types`, `strings`, `arrays of floating-point numbers`;\n- Support the definition of `functions` and `variables`, recursive call of functions, nested scope;\n\ntryC是一个用c语言手搓的非常简单的解释器，大约570行：\n\n采用递归下降法进行语法分析，不显式构建语法树，不生成中间代码或目标代码，在语法分析的同时进行解释执行；\n\ntryC实现的try语言：\n- 动态类型，支持的数据类型：双精度浮点数、字符型、字符串、浮点数数组\n- 支持函数和变量的定义、函数的递归调用、嵌套作用域\n\n### files：\n\nsource：tryC.c\n\nexample：test.try\n\n### build and run：\n\nbuild:\n\n    gcc -o tryc tryC.c\n\nusage: \n    \n    tryc [-d] filename\n\n## documents in Chinese\n\n[用c语言手搓一个600行的类c语言解释器: 给编程初学者的解释器教程（1）- 目标和前言](https://blog.csdn.net/qq_42779423/article/details/105938297)\n\n[用c语言手搓一个600行的类c语言解释器: 给编程初学者的解释器教程（2）- 简介和设计](https://blog.csdn.net/qq_42779423/article/details/105939788)\n\n[用c语言手搓一个600行的类c语言解释器: 给编程初学者的解释器教程（3）- 词法分析](https://blog.csdn.net/qq_42779423/article/details/105948289)\n\n[用c语言手搓一个600行的类c语言解释器: 给编程初学者的解释器教程（4）- 语法分析1：EBNF和递归下降文法](https://blog.csdn.net/qq_42779423/article/details/105954353)\n\n[用c语言手搓一个600行的类c语言解释器: 给编程初学者的解释器教程（5）- 语法分析2: tryC的语法分析实现](https://blog.csdn.net/qq_42779423/article/details/105954455)\n\n[用c语言手搓一个600行的类c语言解释器: 给编程初学者的解释器教程（6）- 语义分析：符号表和变量、函数](https://blog.csdn.net/qq_42779423/article/details/105979594)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyunwei37%2Ftryc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyunwei37%2Ftryc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyunwei37%2Ftryc/lists"}