{"id":15022312,"url":"https://github.com/php/pecl-php-parsekit","last_synced_at":"2026-01-11T05:33:28.610Z","repository":{"id":7217758,"uuid":"8524650","full_name":"php/pecl-php-parsekit","owner":"php","description":"PHP Opcode Analyser","archived":true,"fork":false,"pushed_at":"2013-03-02T20:56:27.000Z","size":143,"stargazers_count":15,"open_issues_count":0,"forks_count":8,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-04-13T21:53:28.868Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://pecl.php.net/package/parsekit","language":"C","has_issues":false,"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/php.png","metadata":{"files":{"readme":"README","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}},"created_at":"2013-03-02T18:04:32.000Z","updated_at":"2024-04-09T20:23:02.000Z","dependencies_parsed_at":"2022-09-04T22:52:27.338Z","dependency_job_id":null,"html_url":"https://github.com/php/pecl-php-parsekit","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php%2Fpecl-php-parsekit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php%2Fpecl-php-parsekit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php%2Fpecl-php-parsekit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php%2Fpecl-php-parsekit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/php","download_url":"https://codeload.github.com/php/pecl-php-parsekit/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":219875528,"owners_count":16554685,"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":[],"created_at":"2024-09-24T19:57:46.758Z","updated_at":"2025-10-03T22:30:50.118Z","avatar_url":"https://github.com/php.png","language":"C","readme":"parsekit: PHP Opcode Analyser\n\nProvides a userspace interpretation of the opcodes \ngenerated by the Zend engine compiler built into PHP.\n\nThis extension is meant for development and debug \npurposes only and contains some code which is \npotentially non-threadsafe.\n\nThis extension exports two functions \n(parsekit_compile_string(string phpcode[, array \u0026errors]) \nand parsekit_compile_file(string filename[, array \u0026errors])) \nwhich will attempt to compile one or more blocks of PHP \ncode into Zend opcodes.  \n\nThe output of these functions is an n-depth hash containing \nthe main block of code's oparray at its root, with \nfunction_table and class_table elements to hold any functions \nor classes declared within the compiled code.\n\nIn order to accomplish these compilation steps within \nthe context of an active execution, some potentially unsafe\nmethods are used.\n\n1) Compilation modifies EG(function_table) and EG(class_table),\n   after compilation completes, parsekit pops these functions\n   and classes off the end of these stacks.\n\n2) To avoid parse errors in supplied code causing a zend_bailout(),\n   parsekit replaces zend_error_cb with a wrapper which passes E_CORE_ERROR\n   or any error which occurs outside of parsekit_compile_*() onto\n   the original zend_error_cb.  If another module which replaced\n   zend_error_cb were to be loaded prior to parsekit, then unloaded\n   after parsekit's startup, but prior to parsekit's shutdown, then\n   the global value zend_error_cb could become populated with an\n   invalid function pointer.\n\nThe moral of the story:  Use this at your own risk.\n\nThis extension also exports constant entries for all class types,\nfunction types, node types, and opcodes.  While a name collision\nwould be unexpected, all constants are prefixed with PARSEKIT_\njust to be safe.\n\nExample:\n\n#define ZEND_NOP\t0\n\nExported as:\n\nREGISTER_LONG_CONSTANT(\"PARSEKIT_ZEND_NOP\",\t0, CONST_CS | CONST_PERSISTENT);\n\nFor examples on usage, refer to the examples subdirectory in this package.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphp%2Fpecl-php-parsekit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphp%2Fpecl-php-parsekit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphp%2Fpecl-php-parsekit/lists"}