{"action":"created","issue":{"url":"https://api.github.com/repos/bobthecow/psysh/issues/391","repository_url":"https://api.github.com/repos/bobthecow/psysh","labels_url":"https://api.github.com/repos/bobthecow/psysh/issues/391/labels{/name}","comments_url":"https://api.github.com/repos/bobthecow/psysh/issues/391/comments","events_url":"https://api.github.com/repos/bobthecow/psysh/issues/391/events","html_url":"https://github.com/bobthecow/psysh/pull/391","id":238296432,"number":391,"title":"Add Doc support for constants.","user":{"login":"RyanNerd","id":10543911,"avatar_url":"https://avatars2.githubusercontent.com/u/10543911?v=4","gravatar_id":"","url":"https://api.github.com/users/RyanNerd","html_url":"https://github.com/RyanNerd","followers_url":"https://api.github.com/users/RyanNerd/followers","following_url":"https://api.github.com/users/RyanNerd/following{/other_user}","gists_url":"https://api.github.com/users/RyanNerd/gists{/gist_id}","starred_url":"https://api.github.com/users/RyanNerd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RyanNerd/subscriptions","organizations_url":"https://api.github.com/users/RyanNerd/orgs","repos_url":"https://api.github.com/users/RyanNerd/repos","events_url":"https://api.github.com/users/RyanNerd/events{/privacy}","received_events_url":"https://api.github.com/users/RyanNerd/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2017-06-24T05:28:01Z","updated_at":"2018-05-29T15:19:41Z","closed_at":"2018-05-29T15:19:41Z","author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/bobthecow/psysh/pulls/391","html_url":"https://github.com/bobthecow/psysh/pull/391","diff_url":"https://github.com/bobthecow/psysh/pull/391.diff","patch_url":"https://github.com/bobthecow/psysh/pull/391.patch"},"body":"Closes #384\r\n\r\nThis follows similar conventions to the existing `doc` process:\r\n\r\n* To allow for multi-language support the constants are maintained in its own SQLite database named `php_constants.sqlite`. Since system constants are not _atomically_ generated as part of PHP's manual builder process these have been added by hand to the database (English only right now).\r\n\r\n* The 'doc keyword' command will now check if the keyword is a system constant (e.g. PHP_VERSION)\r\nor a \"magic\" constant (e.g. __DIR__) if either of these is true then the documentation will be\r\nread from the `php_constants` database and presented as output similar to how language constructs or innate functions are output.\r\n\r\nNote: Because of the lack of reflection for these constants the output makes limited use of the reflection templating engine. I tried to \"hack\" the reflection helpers (like what is being done for language constructs such as `echo`) but this only proved an exercise in frustration."},"comment":{"url":"https://api.github.com/repos/bobthecow/psysh/issues/comments/392816644","html_url":"https://github.com/bobthecow/psysh/pull/391#issuecomment-392816644","issue_url":"https://api.github.com/repos/bobthecow/psysh/issues/391","id":392816644,"user":{"login":"bobthecow","id":53660,"avatar_url":"https://avatars1.githubusercontent.com/u/53660?v=4","gravatar_id":"","url":"https://api.github.com/users/bobthecow","html_url":"https://github.com/bobthecow","followers_url":"https://api.github.com/users/bobthecow/followers","following_url":"https://api.github.com/users/bobthecow/following{/other_user}","gists_url":"https://api.github.com/users/bobthecow/gists{/gist_id}","starred_url":"https://api.github.com/users/bobthecow/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bobthecow/subscriptions","organizations_url":"https://api.github.com/users/bobthecow/orgs","repos_url":"https://api.github.com/users/bobthecow/repos","events_url":"https://api.github.com/users/bobthecow/events{/privacy}","received_events_url":"https://api.github.com/users/bobthecow/received_events","type":"User","site_admin":false},"created_at":"2018-05-29T15:19:40Z","updated_at":"2018-05-29T15:19:40Z","author_association":"OWNER","body":"Sorry for the huge delay. v1.3.0 manual files now include all the constants (class constants, magic constants, normal constants).\r\n\r\nI just pushed a change to `develop` to add support to the `doc` command. So as of the next release, it'll show documentation for constants if you've got a new enough manual db :) "}}
{"actor":{"display_login":"bobthecow"}}