Skip to content

Commit 1554fc4

Browse files
feature #224 Add polyfill for PHP8's Stringable (nicolas-grekas)
This PR was merged into the 1.15-dev branch. Discussion ---------- Add polyfill for PHP8's Stringable - [x] Should wait for https://wiki.php.net/rfc/stringable to be approved before merging. Commits ------- 260a76c Add polyfill for PHP8's Stringable
2 parents 8c69b16 + 260a76c commit 1554fc4

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# 1.15.0
22

33
* added `preg_last_error_msg()` to the PHP 8 polyfill
4+
* added interface `Stringable` to the PHP 8 polyfill
45

56
# 1.14.0
67

src/Php80/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
Symfony Polyfill / Php80
22
========================
33

4-
This component provides functions added to PHP 8.0 core:
4+
This component provides features added to PHP 8.0 core:
55

6+
- `Stringable` interface
67
- [`fdiv`](https://php.net/fdiv)
78
- `ValueError` class
89
- `FILTER_VALIDATE_BOOL` constant
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
interface Stringable
4+
{
5+
/**
6+
* @return string
7+
*/
8+
public function __toString();
9+
}

0 commit comments

Comments
 (0)