Skip to content
Navigation Menu
Sign in
Products
Platform
GitHub
Repository hosting, code review, and collaboration
Copilot
AI coding agent for tasks, projects, and automated work
Build & Ship
Actions
CI/CD and automation
Code Quality
Quality analysis, fixes, and enforcement
Codespaces
Cloud development environments
Secure
Code Security
Vulnerability detection and remediation
Secret Protection
Secret scanning and leak prevention
All Features
Developers
Learn
Documentation
Training
Certifications
Build
Build with Copilot
Customize Copilot
Integrations
Explore
Trending repos
GitHub Sponsors
Developer articles
Changelog
Changelog
Your source for the latest features, improvements, and fixes across GitHub products, all in one place.
Businesses
By Stage
Enterprises
Team
Startups
Nonprofits
By Industry
Healthcare
Financial services
Manufacturing
Government
See all industries
Evaluate GitHub
Why GitHub
Customer Stories
Business insights
Trust Center
Add-ons
GitHub Advanced Security
Enterprise-grade code security
Copilot for business
Enterprise-grade AI features
Premium Support
Enterprise-grade 24/7 support
Resources
Learn & Connect
Documentation
Resource center
Blog
Events & webinars
Community Forum
Customer Stories
Integrations
Support
Customer support
Training
GitHub Status
Company
About
Partners
Changelog
GitHub Universe
GitHub Universe
The event for developers, by developers — talks, workshops, and what’s next for GitHub.
Pricing
Search
/
Sign in
Sign up
Appearance settings
You signed in with another tab or window.
Reload
to refresh your session.
You signed out in another tab or window.
Reload
to refresh your session.
You switched accounts on another tab or window.
Reload
to refresh your session.
Dismiss alert
{{ message }}
chung-leong
zpx
Repository navigation
Code
Issues
2
(2)
Pull requests
Discussions
Actions
Projects
Wiki
Security and quality
Insights
More
items
Home
Jump to bottom
Chung Leong edited this page
Nov 17, 2026
·
13 revisions
Tutorials
Creating a zstd PHP extension in under ten minutes
Creating a roaring bitmap extension
Creating a PHP extension with the help of AI
User Guide
Installing Zig
Bootstrapping a new extension
Defining functions
Receiving arguments
Optional arguments
Strings
Objects and arrays
Instances of custom classes
Union types
Named arguments
References
Variadic functions
Returning values
Strings
Arrays
Plain objects
Instances of custom classes
Tuples
Outputting data
Allocating memory
Defining constants
Defining custom classes
Getters and setters
Object initialization
Object deinitialization
Instance methods
Static methods
Exporting classes and enums from within a class
Defining enumerations
Defining ini entries
Reporting errors
Performing tasks at startup and shutdown
Packaging extension
Customizing build menu
Wiki pages
Pages
20
Loading
Home
Tutorials
User Guide
Loading
Allocating memory
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Bootstrapping a new extension
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Creating a PHP extension with the help of AI
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Creating a roaring bitmap extension
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Creating a zstd PHP extension in under ten minutes
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Customizing build menu
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Defining constants
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Defining custom classes
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Defining enumerations
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Defining functions
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Defining ini entries
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Exporting classes and enums from within a class
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Installing Zig
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Outputting data
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Packaging extension
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Performing tasks at startup and shutdown
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Receiving arguments
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Reporting errors
Uh oh!
There was an error while loading.
Please reload this page
.
Loading
Returning values
Uh oh!
There was an error while loading.
Please reload this page
.
Show 5 more pages…
Clone this wiki locally
You can’t perform that action at this time.