Skip to content

Visual Studio hangs/crashes when hovering over a nonexistent union case pattern #11667

Closed

Description

@Happypig375

Visual Studio hangs/crashes when hovering over a nonexistent union case pattern.

Repro steps

  1. Clone this repo's main (currently 4ce381b)
  2. Run build.cmd
  3. Open FSharp.Compiler.Service.sln
  4. Under project FSharp.Compiler.Service, ParserAndUntypedAST\SyntaxTree.fsi, line 1138, change Named to Name
  5. In ParserAndUntypedAST\SyntaxTree.fs, line 979, change Named to Name
  6. In ParserAndUntypedAST\FsYaccOutput\pars.fs, line 5747, hover over Named
  7. If Visual Studio doesn't hang, wait until type information fully loads
  8. Visual Studio hangs (16.10.1) or crashes after a while (16.11p1)

Expected behavior

Visual Studio does not hang or crash.

Actual behavior

Visual Studio hangs (16.10.1) or crashes after a while (16.11p1).

Known workarounds

Nope.

Related information

Provide any related information (optional):

  • Operating system: Windows 10
  • .NET Runtime kind (.NET Core, .NET Framework, Mono): N/A
  • Editing Tools (e.g. Visual Studio Version, Visual Studio): Visual Studio 16.10.1 / 16.11 preview 1

Activity

  1. added
    Impact-High
    on Jul 7, 2021
  2. added
    Impact-Medium
    and removed
    Impact-High
    on Aug 25, 2021
  3. added
    Area-LangService-ToolTips
    and removed on Apr 5, 2022
  4. added this to the Backlog milestone on Oct 19, 2022
  5. 0101 commented on Jan 25, 2023

    @0101
    Contributor

    This still reproduces. However it seems to only happen specifically in the generated pars.fs. Could be some edge case either related to the contents of the file or possibly to how it's included in the project.

    Debugging shows StackOverflow exception which could indeed be the root cause
    image

    let rec (|Sequentials|_|) expr =

  6. self-assigned this
    on Jan 26, 2023
  7. modified the milestones: Backlog, January-2023 on Jan 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Area-LangService-ToolTipsBugImpact-Medium

Type

No type

Projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions