{"action":"created","issue":{"url":"https://api.github.com/repos/php/php-src/issues/1698","labels_url":"https://api.github.com/repos/php/php-src/issues/1698/labels{/name}","comments_url":"https://api.github.com/repos/php/php-src/issues/1698/comments","events_url":"https://api.github.com/repos/php/php-src/issues/1698/events","html_url":"https://github.com/php/php-src/pull/1698","id":124107630,"number":1698,"title":"Add enum support","user":{"login":"bwoebi","id":3154871,"avatar_url":"https://avatars.githubusercontent.com/u/3154871?v=3","gravatar_id":"","url":"https://api.github.com/users/bwoebi","html_url":"https://github.com/bwoebi","followers_url":"https://api.github.com/users/bwoebi/followers","following_url":"https://api.github.com/users/bwoebi/following{/other_user}","gists_url":"https://api.github.com/users/bwoebi/gists{/gist_id}","starred_url":"https://api.github.com/users/bwoebi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bwoebi/subscriptions","organizations_url":"https://api.github.com/users/bwoebi/orgs","repos_url":"https://api.github.com/users/bwoebi/repos","events_url":"https://api.github.com/users/bwoebi/events{/privacy}","received_events_url":"https://api.github.com/users/bwoebi/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-12-28T18:57:22Z","updated_at":"2015-12-28T19:15:34Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/php/php-src/pulls/1698","html_url":"https://github.com/php/php-src/pull/1698","diff_url":"https://github.com/php/php-src/pull/1698.diff","patch_url":"https://github.com/php/php-src/pull/1698.patch"},"body":"RFC: https://wiki.php.net/rfc/enum\r\n\r\nEnums are based on a class entry (in order to allow future class-like features like methods etc.).\r\nEnums are designed to be fast and not refcounted. (We're using an uint32_t class_handle as we need also some space for the enum value handle.)\r\nNote that enum values are designed to not have mutable state, they won't have properties etc., so no need for an extra individual structure like objects have.\r\n\r\nIn case we ever need another mechanism, we'll just need to change the code accessing the underlying storage; the essential enum functions (equality, name, ce, add) are properly abstracted away into inline functions."},"comment":{"url":"https://api.github.com/repos/php/php-src/issues/comments/167631027","html_url":"https://github.com/php/php-src/pull/1698#issuecomment-167631027","issue_url":"https://api.github.com/repos/php/php-src/issues/1698","id":167631027,"user":{"login":"bwoebi","id":3154871,"avatar_url":"https://avatars.githubusercontent.com/u/3154871?v=3","gravatar_id":"","url":"https://api.github.com/users/bwoebi","html_url":"https://github.com/bwoebi","followers_url":"https://api.github.com/users/bwoebi/followers","following_url":"https://api.github.com/users/bwoebi/following{/other_user}","gists_url":"https://api.github.com/users/bwoebi/gists{/gist_id}","starred_url":"https://api.github.com/users/bwoebi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bwoebi/subscriptions","organizations_url":"https://api.github.com/users/bwoebi/orgs","repos_url":"https://api.github.com/users/bwoebi/repos","events_url":"https://api.github.com/users/bwoebi/events{/privacy}","received_events_url":"https://api.github.com/users/bwoebi/received_events","type":"User","site_admin":false},"created_at":"2015-12-28T19:15:34Z","updated_at":"2015-12-28T19:15:34Z","body":"@TazeTSchnitzel switches usually have a default branch where incompatible things should go to… If they don't have it yet, time to add it now."}}