-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #516 from nextcloud/add/php-ds
Add php-ds polyfill
- Loading branch information
Showing
26 changed files
with
3,397 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# Change Log | ||
All notable changes to this project will be documented in this file. | ||
This project adheres to [Semantic Versioning](http://semver.org/). | ||
|
||
## [1.3.0] - 2020-10-13 | ||
### Changed | ||
- Implement ArrayAccess consistently | ||
### Fixed | ||
- Return types were incorrectly nullable in some cases | ||
- Deque capacity was inconsistent with the extension | ||
|
||
## [1.2.0] - 2017-08-03 | ||
### Changed | ||
- Minor capacity updates | ||
|
||
## [1.1.1] - 2016-08-09 | ||
### Fixed | ||
- `Stack` and `Queue` array access should throw `OutOfBoundsException`, not `Error`. | ||
|
||
### Improved | ||
- Added a lot of docblock comments that were missing. | ||
|
||
## [1.1.0] - 2016-08-04 | ||
### Added | ||
- `Pair::copy` | ||
|
||
## [1.0.3] - 2016-08-01 | ||
### Added | ||
- `Set::merge` | ||
|
||
## [1.0.2] - 2016-07-31 | ||
### Added | ||
- `Map::putAll` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Contributing | ||
|
||
Contributions are accepted via [pull requests](https://github.com/php-ds/ext/pulls). If you would like to report a bug, please create an [issue](https://github.com/php-ds/ext/issues) instead. | ||
|
||
## Issues | ||
|
||
- **How to reproduce** - Provide an easy way to reproduce the bug. This makes it easier for others to debug. | ||
|
||
- **Platform details** - Specify your platform and your PHP version, eg. "PHP 7.0.2 on Ubuntu 14.04 64x". | ||
|
||
## Pull Requests | ||
|
||
- **Add tests** - Your patch won't be accepted if it doesn't have tests where appropriate. | ||
|
||
- **Document any change in behaviour** - Make sure the README and any other relevant documentation updated. | ||
|
||
- **One pull request per feature** - If you want to do more than one thing, send multiple pull requests. | ||
|
||
- **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please squash them before submitting. | ||
|
||
- **Coding style** - Try to match the style of the rest of the source wherever possible. Your patch won't be accepted if the style is significantly different. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
The MIT License (MIT) | ||
Copyright (c) 2016 Rudi Theunissen | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a | ||
copy of this software and associated documentation files (the "Software"), | ||
to deal in the Software without restriction, including without limitation | ||
the rights to use, copy, modify, merge, publish, distribute, sublicense, | ||
and/or sell copies of the Software, and to permit persons to whom the | ||
Software is furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in | ||
all copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES | ||
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. | ||
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, | ||
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, | ||
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH | ||
THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# Data Structures for PHP 7 | ||
|
||
[![Build Status](https://travis-ci.org/php-ds/polyfill.svg?branch=master)](https://travis-ci.org/php-ds/polyfill) | ||
[![Code Coverage](https://scrutinizer-ci.com/g/php-ds/polyfill/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/php-ds/polyfill/?branch=master) | ||
[![Packagist](https://img.shields.io/packagist/v/php-ds/php-ds.svg)](https://packagist.org/packages/php-ds/php-ds) | ||
|
||
This is a compatibility polyfill for the [extension](https://github.com/php-ds/extension). You should include this package as a dependency of your project | ||
to ensure that your codebase would still be functional in an environment where the extension is not installed. The polyfill will not be loaded if the extension is installed and enabled. | ||
|
||
## Install | ||
|
||
```bash | ||
composer require php-ds/php-ds | ||
``` | ||
|
||
You can also *require* that the extension be installed using `ext-ds`. | ||
|
||
## Test | ||
|
||
``` | ||
composer install | ||
composer test | ||
``` | ||
|
||
Make sure that the *ds* extension is not enabled, as the polyfill will not be loaded if it is. | ||
The test output will indicate whether the extension is active. | ||
|
||
## Contributing | ||
|
||
Please see [CONTRIBUTING](CONTRIBUTING.md) for more information. | ||
|
||
### Credits | ||
|
||
- [Rudi Theunissen](https://github.com/rtheunissen) | ||
- [Joe Watkins](https://github.com/krakjoe) | ||
|
||
### License | ||
|
||
The MIT License (MIT). Please see [LICENSE](LICENSE.md) for more information. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
{ | ||
"name": "php-ds/php-ds", | ||
"license": "MIT", | ||
"keywords": ["php", "ds", "data structures", "polyfill"], | ||
"authors": [ | ||
{ | ||
"name": "Rudi Theunissen", | ||
"email": "rudolf.theunissen@gmail.com" | ||
} | ||
], | ||
"require": { | ||
"php": ">=7.0.0", | ||
"ext-json": "*" | ||
}, | ||
"require-dev": { | ||
"php-ds/tests": "^1.3" | ||
}, | ||
"provide": { | ||
"ext-ds": "1.3.0" | ||
}, | ||
"suggest": { | ||
"ext-ds": "to improve performance and reduce memory usage" | ||
}, | ||
"scripts": { | ||
"test": "phpunit" | ||
}, | ||
"autoload": { | ||
"psr-4" : { | ||
"Ds\\": "src" | ||
} | ||
} | ||
} |
Oops, something went wrong.