{"id":20745899,"url":"https://github.com/isc30/generic_optional","last_synced_at":"2026-06-08T14:32:19.408Z","repository":{"id":92561449,"uuid":"142500741","full_name":"isc30/generic_optional","owner":"isc30","description":"enables reference types for std::optional","archived":false,"fork":false,"pushed_at":"2018-08-24T08:23:59.000Z","size":9,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-11T12:52:19.141Z","etag":null,"topics":["cpp","optional"],"latest_commit_sha":null,"homepage":"","language":"C++","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/isc30.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":"2018-07-26T22:36:36.000Z","updated_at":"2020-10-19T11:06:04.000Z","dependencies_parsed_at":"2023-04-12T07:46:30.080Z","dependency_job_id":null,"html_url":"https://github.com/isc30/generic_optional","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/isc30/generic_optional","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/isc30%2Fgeneric_optional","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/isc30%2Fgeneric_optional/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/isc30%2Fgeneric_optional/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/isc30%2Fgeneric_optional/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/isc30","download_url":"https://codeload.github.com/isc30/generic_optional/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/isc30%2Fgeneric_optional/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34067348,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-08T02:00:07.615Z","response_time":111,"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":["cpp","optional"],"created_at":"2024-11-17T07:23:17.747Z","updated_at":"2026-06-08T14:32:19.392Z","avatar_url":"https://github.com/isc30.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# generic_optional\u0026lt;T\u0026gt;\n\nCompile-time wrapper over `std::optional\u003cT\u003e` that enables optional reference types.\n\n### How it works\n\nFor non-reference types:\n- `generic_optional\u003cint\u003e` \u0026rarr; (deduces to) \u0026rarr; `optional\u003cint\u003e`\n\nFor reference types:\n- `generic_optional\u003cconst int\u0026\u003e` \u0026rarr;  (deduces to) \u0026rarr; `optional\u003creference_wrapper\u003cconst int\u003e\u003e`\n\n### Usage\n\nUse `generic_optional\u003cT\u003e` instead of `optional\u003cT\u003e` in the declaration.\n\n### Example\n\n```cpp\ngeneric_optional\u003cint\u003e number;\ngeneric_optional\u003cconst int\u0026\u003e number_cref;\nint test_value = 33;\n\nnumber = test_value;\nnumber_cref = test_value;\n\ntest_value = 111;\n    \nassert(number == 33);\nassert(number_cref == 111);\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fisc30%2Fgeneric_optional","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fisc30%2Fgeneric_optional","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fisc30%2Fgeneric_optional/lists"}