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
* Started work on guide, added types
* Rewrite argument parser to allow referencs
Primarly so that `&str` is a valid parameter type.
* Remove generic `Into<String>` conversion to exception
* Worked on guide, added macros
* Build guide when building docs
* Allow manual trigger of docs build
* `cargo fmt`
-**Easy to use:** The built-in macros can abstract away the need to interact with the Zend API, such as Rust-type function parameter abstracting away interacting with Zend values.
35
-
-**Lightweight:** You don't have to use the built-in helper macros. It's possible to write your own glue code around your own functions.
36
-
-**Extensible:** Implement `IntoZval` and `FromZval` for your own custom types, allowing the type to be used as function parameters and return types.
35
+
-**Easy to use:** The built-in macros can abstract away the need to interact
36
+
with the Zend API, such as Rust-type function parameter abstracting away
37
+
interacting with Zend values.
38
+
-**Lightweight:** You don't have to use the built-in helper macros. It's
39
+
possible to write your own glue code around your own functions.
40
+
-**Extensible:** Implement `IntoZval` and `FromZval` for your own custom types,
41
+
allowing the type to be used as function parameters and return types.
37
42
38
43
## Goals
39
44
40
45
Our main goal is to **make extension development easier.**
41
46
42
-
- Writing extensions in C can be tedious, and with the Zend APIs limited documentation can be intimidating.
43
-
- Rust's modern language features and feature-full standard library are big improvements on C.
44
-
- Abstracting away the raw Zend APIs allows extensions to be developed faster and with more confidence.
45
-
- Abstractions also allow us to support future (and potentially past) versions of PHP without significant changes to extension code.
47
+
- Writing extensions in C can be tedious, and with the Zend APIs limited
48
+
documentation can be intimidating.
49
+
- Rust's modern language features and feature-full standard library are big
50
+
improvements on C.
51
+
- Abstracting away the raw Zend APIs allows extensions to be developed faster
52
+
and with more confidence.
53
+
- Abstractions also allow us to support future (and potentially past) versions
54
+
of PHP without significant changes to extension code.
46
55
47
56
## Documentation
48
57
49
-
The project is documented in-line, so viewing the `cargo` documentation is the best resource at the moment.
58
+
The project is documented in-line, so viewing the `cargo` documentation is the
59
+
best resource at the moment.
50
60
51
-
We are currently unable to deploy our documentation to `docs.rs` due to the crate requiring PHP 8.0, which is unavailable in the default Ubuntu repositories.
52
-
Documentation can be viewed [here](https://davidcole1340.github.io/ext-php-rs/). It is generated from the latest `master` branch. Documentation will be moved to `docs.rs` when Ubuntu updates its repositories to PHP 8.0.
61
+
We are currently unable to deploy our documentation to `docs.rs` due to the
62
+
crate requiring PHP 8.0, which is unavailable in the default Ubuntu
63
+
repositories. Documentation can be viewed
64
+
[here](https://davidcole1340.github.io/ext-php-rs/). It is generated from the
65
+
latest `master` branch. Documentation will be moved to `docs.rs` when Ubuntu
66
+
updates its repositories to PHP 8.0.
53
67
54
68
## Requirements
55
69
56
70
- PHP 8.0 or later
57
-
- No support is planned for lower versions.
71
+
- No support is planned for lower versions.
58
72
- Linux or Darwin-based OS
59
73
- Rust - no idea which version
60
74
- Clang 3.9 or greater
@@ -64,20 +78,26 @@ See the following links for the dependency crate requirements:
This project only works for PHP >= 8.0 (for now). Due to the fact that the PHP extension system relies heavily on C macros (which cannot be exported to Rust easily), structs have to be hard coded in.
83
+
This project only works for PHP >= 8.0 (for now). Due to the fact that the PHP
84
+
extension system relies heavily on C macros (which cannot be exported to Rust
85
+
easily), structs have to be hard coded in.
71
86
72
87
Check out one of the example projects:
73
88
74
-
-[ext-skel](example/skel) - Testbed for testing the library. Check out previous commits as well to see what else is possible.
Work-in-progress extension to use the Opus library in PHP.
77
95
78
96
## Contributions
79
97
80
-
Contributions are very much welcome. I am a novice Rust developer and any suggestions are wanted and welcome. Feel free to file issues and PRs through Github.
98
+
Contributions are very much welcome. I am a novice Rust developer and any
99
+
suggestions are wanted and welcome. Feel free to file issues and PRs through
100
+
Github.
81
101
82
102
Contributions welcome include:
83
103
@@ -98,9 +118,8 @@ dual licensed as above, without any additional terms or conditions.
98
118
99
119
Licensed under either of
100
120
101
-
* Apache License, Version 2.0
102
-
([LICENSE_APACHE](LICENSE_APACHE) or http://www.apache.org/licenses/LICENSE-2.0)
103
-
* MIT license
104
-
([LICENSE_MIT](LICENSE_MIT) or http://opensource.org/licenses/MIT)
121
+
- Apache License, Version 2.0 ([LICENSE_APACHE](LICENSE_APACHE) or
122
+
http://www.apache.org/licenses/LICENSE-2.0)
123
+
- MIT license ([LICENSE_MIT](LICENSE_MIT) or http://opensource.org/licenses/MIT)
0 commit comments