Skip to content

[bug] TypeScript: func_start regex misses generic functions #2219

Closed

Description

@squid-protocol

During a sweep of the tri-comparison ledger, we found that the TypeScript func_start regex fails to extract functions with generic type parameters.

Example from fp-ts/pipeable.ts:

export function pipeable<F extends URIS3, I>(

Tree-sitter and Ctags correctly extract this, but GitGalaxy drops it, likely because the regex doesn't tolerate the <...> type block before the argument list.

Activity

  1. added
    bug
    core-engine
    on Aug 24, 2026
  2. squid-protocol commented on Aug 24, 2026

    @squid-protocol
    OwnerAuthor

    Closing: My investigation was incorrect. The reported pipeable instances are TypeScript function overloads (signatures) without bodies. GitGalaxy correctly matches the name but intentionally discards it as body-less, whereas Ctags and Tree-sitter blindly extract every signature as a separate function. The actual implementation at line 2520 is successfully extracted by GitGalaxy. No defect exists.

  3. added this to the v2.4.9 milestone on Aug 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugcore-engine

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions