Skip to content
This repository was archived by the owner on Jan 12, 2024. It is now read-only.
This repository was archived by the owner on Jan 12, 2024. It is now read-only.

Q# Code Action on adding documentation for operation is broken for @EntryPoint() decorated ones #1223

Open
@ricardo-espinoza

Description

@ricardo-espinoza

Describe the bug

In both Visual Studio and Visual Studio Code, there is a CodeAction that suggests adding documentation to Q# operations. This action becomes unavailable when the corresponding operation is decorated with @EntryPoint().

To Reproduce

  1. Start from a Q# project with a code file with contents as shown below.
  2. Select the operation name.
  3. Invoke Code Actions through the corresponding IDE (VS or VS Code).
  4. Observe if a code action is recommended.

Expected behavior

A code action indicating "Add documentation for..." should be shown to the user.

This repro goes away if the @EntryPoint() decorator is removed.

System information

  • This reproes on QDK since at least 0.15.2103.133969 (released on March 30th, 2021).
  • Using Windows 10 (19043.1288) and .NET 3.1.20
  • VS 16.11.5 and VSC 1.61.2

Sample Q# File

namespace vscp {

    open Microsoft.Quantum.Canon;
    open Microsoft.Quantum.Intrinsic;
    
    @EntryPoint()
    operation SayHello() : Unit {
        Message("Hello quantum world!");
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: editorExtensions for Visual Studio and Visual Studio CodebugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions