|
1 | 1 | # Changelog |
2 | 2 |
|
| 3 | +## Version 1.0.0 |
| 4 | + |
| 5 | +- `Zval::reference()` returns a reference instead of a dereferenced pointer. |
| 6 | +- Added `ZendHashTable::iter()` - note this is changing in a future version. |
| 7 | +- `ClassBuilder::extends()` now takes a reference rather than a pointer to match the |
| 8 | +return type of `ClassEntry::exception()`. |
| 9 | +- `ClassEntry::build()` now returns a reference - same reason as above. |
| 10 | +- Improve library 'safety' by removing `unwrap` calls: |
| 11 | + - `.build()` returns `Result` on `FunctionBuilder`, `ClassBuilder` and `ModuleBuilder`. |
| 12 | + - `.property()` and `.constant()` return `Result` on `ClassBuilder`. |
| 13 | + - `.register_constant()` returns `Result`. |
| 14 | + - `.try_call()` on callables now return `Result` rather than `Option`. |
| 15 | + - `throw()` and `throw_with_code()` now returns `Result`. |
| 16 | + - `new()` and `new_interned()` on `ZendString` now returns a `Result`. |
| 17 | + - For `ZendHashTable`: |
| 18 | + - `insert()`, `insert_at_index()` now returns a `Result<HashTableInsertResult>`, where `Err` failed, |
| 19 | + `Ok(Ok)` inserts successfully without overwrite, and `Ok(OkWithOverwrite(&Zval))` inserts successfully |
| 20 | + with overwrite. |
| 21 | + - `push()` now returns a `Result`. |
| 22 | + - Converting from a `Vec` or `HashMap` to a `ZendHashTable` is fallible, so it now implementes `TryFrom` as |
| 23 | + opposed to `From`. |
| 24 | + - For `Zval`: |
| 25 | + - `set_string()` now returns a `Result`, and takes a second parameter (persistent). |
| 26 | + - `set_persistent_string()` has now been removed in favour of `set_string()`. |
| 27 | + - `set_interned_string()` also returns a `Result`. |
| 28 | + - `set_array()` now only takes a `ZendHashTable`, you must convert your `Vec` or `HashMap` |
| 29 | + by calling `try_into()` and handling the error. |
| 30 | + |
3 | 31 | ## Version 0.0.7 |
4 | 32 |
|
5 | 33 | - Added support for thread-safe PHP (@davidcole1340) #37 |
|
0 commit comments