From 9a2264d523254d52ba56c7cb6585dc9cc1b55390 Mon Sep 17 00:00:00 2001 From: SerafimArts Date: Sun, 28 Jul 2024 13:43:00 +0000 Subject: [PATCH] Add PHP 8.4 (alpha build) tests support --- src/PositionFactory.php | 5 ++--- src/PositionFactoryTrait.php | 24 ++++++++++++------------ 2 files changed, 14 insertions(+), 15 deletions(-) diff --git a/src/PositionFactory.php b/src/PositionFactory.php index 7c3fb63..4acaa36 100644 --- a/src/PositionFactory.php +++ b/src/PositionFactory.php @@ -27,14 +27,13 @@ final class PositionFactory implements PositionFactoryInterface /** * @var int<1, max> - * * @psalm-readonly-allow-private-mutation */ private int $chunkSize = self::DEFAULT_CHUNK_SIZE; /** - * @param int<1, max> $chunkSize the chunk size used while non-blocking - * reading the file inside the {@see \Fiber} context + * @param int<1, max> $chunkSize The chunk size used while non-blocking + * reading the file inside the {@see \Fiber} context. */ public function __construct( int $chunkSize = self::DEFAULT_CHUNK_SIZE diff --git a/src/PositionFactoryTrait.php b/src/PositionFactoryTrait.php index 5b146dc..e816605 100644 --- a/src/PositionFactoryTrait.php +++ b/src/PositionFactoryTrait.php @@ -56,13 +56,13 @@ public static function getSourceFactory(): SourceFactoryInterface * An alternative factory function of the * {@see PositionFactoryInterface::createFromPosition()} method. * - * @param int<1, max> $line expected line value of the position in the - * passed source instance - * @param int<1, max> $column expected column value of the position in the - * passed source instance + * @param int<1, max> $line Expected line value of the position in the + * passed source instance. + * @param int<1, max> $column Expected column value of the position in the + * passed source instance. * - * @throws SourceExceptionInterface in case of an error in creating the - * source object + * @throws SourceExceptionInterface In case of an error in creating the + * source object. */ public static function fromPosition( $source, @@ -95,8 +95,8 @@ public static function start(): PositionInterface * An alternative factory function of the * {@see PositionFactoryInterface::createAtEnding()} method. * - * @throws SourceExceptionInterface in case of an error in creating the - * source object + * @throws SourceExceptionInterface In case of an error in creating the + * source object. */ public static function end($source): PositionInterface { @@ -115,11 +115,11 @@ public static function end($source): PositionInterface * An alternative factory function of the * {@see PositionFactoryInterface::createFromOffset()} method. * - * @param int<0, max> $offset expected offset of the position in the passed - * source instance + * @param int<0, max> $offset Expected offset of the position in the passed + * source instance. * - * @throws SourceExceptionInterface in case of an error in creating the - * source object + * @throws SourceExceptionInterface In case of an error in creating the + * source object. */ public static function fromOffset( $source,