Skip to content

Deptrac doesn't recognize scalar type int<0, max> #1502

Description

@jorgsowa

I have the following class

<?php

namespace Module\Contract;

final readonly class A
{
    /**
     * @param int<0, max> $maxRetry
     */
    public function __construct(
        public int $maxRetry) {}
}

Deptrac detects a violation:
Error: Module\Contract\A has uncovered dependency on Module\Contract\max (Module)

The problem happens with Deptrac 4.1. I'm working with 4.0 and everything is fine. I suspect it's because of the update of phpstan/phpdoc-parser #1494

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions