DisposaBoy / GoSublime

A Golang plugin collection for SublimeText 3, providing code completion and other IDE-like features.
MIT License
3.42k stars 302 forks source link

interface snippets #494

Open juliusba opened 10 years ago

juliusba commented 10 years ago

Awesome plugin! Is it possible to add auto completion for interface methods?

Functionality: Whenever one types the name of an interface and presses enter, all the methods in the interface are filled in, and it is ready to take in the name of the type that implements the interface.

DisposaBoy commented 10 years ago

maybe at some point in the future

mrkafk commented 10 years ago

It seems like go-oracle might support this: "What are the possible concrete types of this interface value?"

https://docs.google.com/document/d/1SLk36YRjjMgKqe490mSRzOPYEDe0Y_WQNRv-EiFYUyw/view

OneOfOne commented 10 years ago

I've forked GoSublime-next (and sent a pull request, of course) and implemented this specific feature.

https://github.com/OneOfOne/GoSublime-next