Skip to content

Commit

Permalink
Merge pull request #27 from petrknap/root-exception
Browse files Browse the repository at this point in the history
Created root exception
  • Loading branch information
petrknap authored Nov 9, 2024
2 parents 9789749 + 89f8570 commit 8b85434
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 3 deletions.
14 changes: 14 additions & 0 deletions src/Exception/Exception.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?php

declare(strict_types=1);

namespace PetrKnap\Optional\Exception;

use Throwable;

/**
* @internal root exception
*/
interface Exception extends Throwable
{
}
4 changes: 1 addition & 3 deletions src/Exception/OptionalException.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@

namespace PetrKnap\Optional\Exception;

use Throwable;

interface OptionalException extends Throwable
interface OptionalException extends Exception
{
}
3 changes: 3 additions & 0 deletions src/Exception/TypedOptionalException.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@

namespace PetrKnap\Optional\Exception;

/**
* @todo extend {@see Exception}, not {@see OptionalException}
*/
interface TypedOptionalException extends OptionalException
{
}

0 comments on commit 8b85434

Please sign in to comment.