Skip to content
This repository has been archived by the owner on Jul 15, 2023. It is now read-only.

Method Suggestion #168

Closed
klaidliadon opened this issue Dec 22, 2015 · 2 comments
Closed

Method Suggestion #168

klaidliadon opened this issue Dec 22, 2015 · 2 comments

Comments

@klaidliadon
Copy link

When you write func in a package the suggestion list show also a method constructor for each type in the package that produces the following output:

func (p *PkgType) Method(){

}

Pressing tab should focus in order:

  1. the * to remove the pointer sign
  2. the Method to change the name
  3. In the parenthesis to change the argument
  4. After the parenthesis to change the return type
  5. In the method body
@lukehoban
Copy link
Contributor

I like the idea of this. I noticed that GoSublime has a similar feature.

It should be possible to add this on top of the same "smart snippets" infrastructure that was added in f8508b4.

grooveygr added a commit to grooveygr/vscode-go that referenced this issue Nov 26, 2017
grooveygr added a commit to grooveygr/vscode-go that referenced this issue Nov 26, 2017
ramya-rao-a pushed a commit that referenced this issue Dec 16, 2017
* Complete method receivers of types in namespace #168

* tuned suggestion naming

* use filterText for better labeling
@ramya-rao-a
Copy link
Contributor

This feature is now out in the latest update of the Go extension (0.6.70)

@vscodebot vscodebot bot locked and limited conversation to collaborators Feb 2, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants