Skip to content

Commit 42ca75b

Browse files
committed
Adding type-hints and extending Throwable for exception interfaces
1 parent 2cc4a01 commit 42ca75b

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
}
1313
],
1414
"require": {
15-
"php": ">=5.3.0"
15+
"php": ">=7.2.0"
1616
},
1717
"autoload": {
1818
"psr-4": {
@@ -21,7 +21,7 @@
2121
},
2222
"extra": {
2323
"branch-alias": {
24-
"dev-master": "1.0.x-dev"
24+
"dev-master": "1.1.x-dev"
2525
}
2626
}
2727
}

src/ContainerExceptionInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88
/**
99
* Base interface representing a generic exception in a container.
1010
*/
11-
interface ContainerExceptionInterface
11+
interface ContainerExceptionInterface extends \Throwable
1212
{
1313
}

src/ContainerInterface.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ interface ContainerInterface
2020
*
2121
* @return mixed Entry.
2222
*/
23-
public function get($id);
23+
public function get(string $id);
2424

2525
/**
2626
* Returns true if the container can return an entry for the given identifier.
@@ -33,5 +33,5 @@ public function get($id);
3333
*
3434
* @return bool
3535
*/
36-
public function has($id);
36+
public function has(string $id);
3737
}

0 commit comments

Comments
 (0)