Skip to content

Find refs/get occurrences on type parameter of recursively defined type causes stack overflow #4977

Closed
@DanielRosenwasser

Description

@DanielRosenwasser
interface I< [|T|] > extends I< [|T|] > {
}

Find all refs gets a stack overflow:

Description:

getDocumentHighlights('C:\Users\drosen\AppData\Local\Temp\~vsB119.ts', 25)

StackTrace:

Error: Out of stack space
   at isExpressionWithTypeArgumentsInClassExtendsClause (:6812:9)
   at isTypeNode (:5336:17)
   at getTypeOfNode (:25658:13)
   at getPropertySymbolFromTypeReference (:46637:25)
   at forEach (:865:17)
   at Anonymous function (:46630:29)
   at forEach (:865:17)
   at getPropertySymbolsFromBaseTypes (:46624:21)
   at getPropertySymbolFromTypeReference (:46644:29)
   at forEach (:865:17)
   at Anonymous function (:46630:29)
   at forEach (:865:17)
   at getPropertySymbolsFromBaseTypes (:46624:21)
   at getPropertySymbolFromTypeReference (:46644:29)
   at forEach (:865:17)
   at Anonymous function (:46630:29)
   at forEach (:865:17)
   at getPropertySymbolsFromBaseTypes (:46624:21)
   at getPropertySymbolFromTypeReference (:46644:29)
   at forEach (:865:17)
   at Anonymous function (:46630:29)
   at forEach (:865:17)
   at getPropertySymb......

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScriptEffort: ModerateRequires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".FixedA PR has been merged for this issueHelp WantedYou can do this

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions