{"id":20144938,"url":"https://github.com/eskry/cppchips","last_synced_at":"2026-04-29T13:32:07.077Z","repository":{"id":65419228,"uuid":"591697236","full_name":"eSkry/cppchips","owner":"eSkry","description":"C++17 Code Generator","archived":false,"fork":false,"pushed_at":"2023-01-23T18:52:31.000Z","size":38,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-03T00:11:52.272Z","etag":null,"topics":["codegenerator","cpp"],"latest_commit_sha":null,"homepage":"","language":"Python","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/eSkry.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2023-01-21T15:23:20.000Z","updated_at":"2023-01-22T13:29:01.000Z","dependencies_parsed_at":"2023-02-12T17:01:00.026Z","dependency_job_id":null,"html_url":"https://github.com/eSkry/cppchips","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/eSkry/cppchips","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eSkry%2Fcppchips","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eSkry%2Fcppchips/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eSkry%2Fcppchips/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eSkry%2Fcppchips/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eSkry","download_url":"https://codeload.github.com/eSkry/cppchips/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eSkry%2Fcppchips/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259727153,"owners_count":22902183,"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":["codegenerator","cpp"],"created_at":"2024-11-13T22:12:51.028Z","updated_at":"2026-04-29T13:32:07.030Z","avatar_url":"https://github.com/eSkry.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cppchips: C++17 code generator\n\n#### :exclamation: Early development stage :vertical_traffic_light:\n\n![a](https://img.shields.io/github/commit-activity/y/eSkry/cppchips?style=flat-square) ![license](https://img.shields.io/github/license/eSkry/cppchips?style=flat-square)\n\n--------------------------------------\n\n#### :capital_abcd: Languages: **EN** [RU](docs/README.ru.md)\n\n#### :four_leaf_clover: Supported C++ constructions\n- **class** and **struct**.\n- **class constructors**.\n- **class member fields** - with autogeneration getter and setter.\n- **initializer list** in constructor (withoout initialize base class).\n- **class member functions**.\n- **virtual** functions and **override in child classes**.\n- simple functions, variables.\n- **method overloading**\n\n\n## :rocket: Simple start\n\n**cppchips input**:\n```python\nfrom src.cppchips import *\n\nanimalClass = CppClass('Animal')\nanimalClass.private \\\n                .add_variable(CppString(), 'var1') \\\n\nanimalClass.public \\\n                .add_virtual_method('say', CppVoid(), [], 'std::cout \u003c\u003c \"---\\\\n\";', noexcept=True) \\\n                .add_virtual_method('pay', CppInt(), [CppVariable(CppDouble(), 'cost')], '// pay to win!') \\\n                .add_constructor() \\\n                .add_getter('var1') \\\n                .add_setter('var1')\n\nprint(animalClass.gen_definition_str())\n\n\ncatClass = CppClass('Cat')\ncatClass.add_base_class(animalClass).public \\\n                                    .add_override_method('say') \\\n                                    .add_constructor() \\\n                                    .add_override_method('pay')\n\nprint(catClass.gen_definition_str())\n```\n\n**C++ result**:\n```cpp\nclass Animal {\npublic:\n  Animal() {}\n  virtual void say() noexcept { std::cout \u003c\u003c \"---\\n\"; }\n  virtual int pay(double cost) {\n    // pay to win!\n  }\n  auto \u0026getvar1() noexcept { return mvar1; }\n  const auto \u0026getvar1() const noexcept { return mvar1; }\n  void setvar1(const std::string \u0026avar1) { mvar1 = avar1; }\n\nprivate:\n  std::string mvar1;\n};\n\nclass Cat : public Animal {\npublic:\n  Cat() {}\n  void say() noexcept override {}\n  int pay(double cost) override { return {}; }\n};\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feskry%2Fcppchips","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feskry%2Fcppchips","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feskry%2Fcppchips/lists"}